Skip to content

Overview

Team endpoints manage the members of your Contox organization. Team members share access to projects based on their assigned roles and project visibility settings.

List team members

Retrieves all members of your team.

GET /api/team

Response

json
[
  {
    "id": "member_abc123",
    "userId": "user_xyz789",
    "name": "Jane Doe",
    "email": "jane@example.com",
    "role": "owner",
    "joinedAt": "2025-01-15T10:30:00Z"
  },
  {
    "id": "member_def456",
    "userId": "user_uvw321",
    "name": "John Smith",
    "email": "john@example.com",
    "role": "member",
    "joinedAt": "2025-01-18T09:00:00Z"
  }
]

Invite team member

Sends an invitation to add a new member to your team.

POST /api/team

Request body

FieldTypeRequiredDescription
emailstringYesEmail address of the user to invite
rolestringNo"admin" or "member" (default: "member")

Example

bash
curl -X POST https://contox.dev/api/team \
  -H "Authorization: Bearer contox_sk_yourkey" \
  -H "Content-Type: application/json" \
  -d '{"email": "newmember@example.com", "role": "member"}'

Response

json
{
  "id": "member_ghi789",
  "email": "newmember@example.com",
  "role": "member",
  "status": "invited",
  "invitedAt": "2025-01-20T14:00:00Z"
}

Remove team member

Removes a member from your team.

DELETE /api/team/[memberId]

Parameters

ParameterTypeLocationDescription
memberIdstringPathThe member ID to remove

Example

bash
curl -X DELETE https://contox.dev/api/team/member_def456 \
  -H "Authorization: Bearer contox_sk_yourkey"

Response

Returns 204 No Content on success.

Roles and permissions

RoleDescriptionPermissions
ownerTeam creatorFull access to all resources, billing, and team management
adminTeam administratorManage projects, members, and settings
memberRegular memberRead and write access to assigned projects

See Team Collaboration Guide for detailed RBAC information.

Notes

  • Only owners and admins can invite or remove team members
  • The team owner cannot be removed
  • Removing a member revokes their access to all team projects immediately
  • Invited users receive an email and must accept the invitation

Next steps