PLANS / list-team-members-via-admin-api

Plans

List team members with the Admin API

Pull every member on the team with GET https://api.cursor.com/teams/members. Official reference: Admin API → Get Team Members.

Authenticate with a team Admin API key (Basic auth, key as username, empty password). See the API Overview for key creation, scopes, and shared rate-limit guidance.

Call

curl -X GET https://api.cursor.com/teams/members \
  -u YOUR_API_KEY:

Response

{
  "teamMembers": [
    {
      "id": "user_PDSPmvukpYgZEDXsoNirw3CFhy",
      "name": "Alex",
      "email": "developer@company.com",
      "role": "member",
      "isRemoved": false
    },
    {
      "id": "user_kljUvI0ASZORvSEXf9hV0ydcso",
      "name": "Sam",
      "email": "admin@company.com",
      "role": "owner",
      "isRemoved": false
    }
  ]
}
Field Meaning
id Encoded user ID (user_…). Same namespace as spend rows and remove-member
email Member email
name Display name
role Team role (for example member, owner)
isRemoved Whether the member has been removed from the team

How other Admin API routes use these IDs

  • POST /teams/remove-member accepts this id as userId (or the member's email)
  • POST /teams/spend returns the same user_… ids on each spend row
  • Directory-group and billing-group member routes also take user_… public ids

Numeric userId values from daily-usage rows are a different identifier space — do not pass them to remove-member or group membership calls.

Pitfalls

  • Treating daily-usage numeric userId as interchangeable with teamMembers[].id
  • Filtering out isRemoved: true rows when you still need offboarding history from this list
  • Skipping this call before bulk spend or remove-member scripts that need encoded ids