Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.qoder.com/llms.txt

Use this file to discover all available pages before exploring further.

About this document

For integrations that manage members and quotas outside the Qoder UI. Complete Get API Key first, then read Conventions.

Requirements

  • Valid API key: Authorization: Bearer <api_key>.
  • Key must belong to the target organization; caller permissions must allow the operation.

API list

1. List members

GET /v1/organizations/{organization_id}/members Paginated retrieval of organization members, with keyword search support.

Path parameters

ParameterTypeRequiredDescription
organization_idstringYesOrganization ID

Query parameters

ParameterTypeRequiredDescription
emailstringNoExact email lookup
includeDeletedstringNoSet to true to include removed members
maxResultsintegerNoPage size (default 20, max 100)
nextTokenstringNoPagination cursor

Success response (200 OK)

Default query (active members only):
{
  "members": [
    {
      "id": "member_abc123",
      "name": "Alice",
      "email": "alice@example.com",
      "role": "org_admin",
      "status": "ENABLED",
      "joinedAt": "2025-06-01T08:00:00Z"
    },
    {
      "id": "member_ghi789",
      "name": "Charlie",
      "role": "org_member",
      "status": "ENABLED",
      "joinedAt": "2025-07-10T14:30:00Z"
    }
  ],
  "maxResults": 20,
  "nextToken": "eyJwYWdlIjogMn0="
}
Some member records may not return the email field; treat it as optional during integration.
Including deleted members (**includeDeleted=true**):
{
  "members": [
    {
      "id": "member_abc123",
      "name": "Alice",
      "email": "alice@example.com",
      "role": "org_admin",
      "status": "ENABLED",
      "joinedAt": "2025-06-01T08:00:00Z"
    },
    {
      "id": "member_def456",
      "name": "Bob",
      "email": "bob@example.com",
      "role": "org_member",
      "status": "DELETED",
      "joinedAt": "2025-03-15T10:00:00Z",
      "deletedAt": "2026-02-01T12:00:00Z"
    }
  ],
  "maxResults": 20,
  "nextToken": ""
}
deletedAt is only returned for deleted members; active members do not include this field. An empty nextToken string indicates the last page.

Response fields

FieldTypeDescription
membersarrayMember list
members[].idstringMember ID
members[].namestringMember name
members[].emailstringMember email (may be empty)
members[].rolestringRole name (e.g., org_admin, org_member)
members[].statusstringMember status: ENABLED (active), DISABLED (suspended), UNACTIVATED (not activated), APPROVE_PENDING (pending approval), APPROVE_DECLINED (approval declined), DELETED (removed)
members[].joinedAtstringJoin time (ISO 8601)
members[].deletedAtstring or nullDeletion time (ISO 8601); not returned for active members
maxResultsint32Page size for this request
nextTokenstringNext-page cursor; empty means last page

2. Get member details

GET /v1/organizations/{organization_id}/members/{member_id} Retrieve detailed information for a single member.

Path parameters

ParameterTypeRequiredDescription
organization_idstringYesOrganization ID
member_idstringYesMember ID

Success response (200 OK)

Active member:
{
  "id": "member_abc123",
  "name": "Alice",
  "email": "alice@example.com",
  "role": "org_admin",
  "status": "ENABLED",
  "joinedAt": "2025-06-01T08:00:00Z"
}
Deleted member (**GetMember** automatically includes deleted members):
{
  "id": "member_def456",
  "name": "Bob",
  "email": "bob@example.com",
  "role": "org_member",
  "status": "DELETED",
  "joinedAt": "2025-03-15T10:00:00Z",
  "deletedAt": "2026-02-01T12:00:00Z"
}

Response fields

Same as the members[] fields in “List members”.

3. Get member statistics

GET /v1/organizations/{organization_id}/members/statistics Retrieve statistical data about organization members.

Path parameters

ParameterTypeRequiredDescription
organization_idstringYesOrganization ID

Success response (200 OK)

{
  "totalMembers": 50,
  "billableMembers": 45,
  "adminMembers": 3,
  "purchasedSeats": 100,
  "remainingSeats": 55
}

Response fields

FieldTypeDescription
totalMembersint32Total number of members
billableMembersint32Number of billable members
adminMembersint32Number of admins
purchasedSeatsint32Number of purchased seats
remainingSeatsint32Number of remaining seats

4. Delete member

DELETE /v1/organizations/{organization_id}/members/{member_id} Remove a member from the organization. Before removal, the system checks whether the member had usage in the current billing cycle.

Path parameters

ParameterTypeRequiredDescription
organization_idstringYesOrganization ID
member_idstringYesMember ID

Success response (200 OK)

Member has usage in the current cycle (seat release deferred to end of cycle):
{
  "id": "member_abc123",
  "hasBillingCycleUsage": true
}
Member has no usage in the current cycle (seat can be released immediately):
{
  "id": "member_abc123",
  "hasBillingCycleUsage": false
}

Response fields

FieldTypeDescription
idstringID of the deleted member
hasBillingCycleUsageboolWhether the member had usage in the current billing cycle (affects seat release timing)

Error responses

Member not in this team (404)
{
  "requestId": "req_abc123",
  "code": "UserNotTeamMember",
  "message": "User is not a member of this team"
}
Insufficient members (400)
{
  "requestId": "req_abc123",
  "code": "InsufficientMembers",
  "message": "The number of organization members cannot be less than the minimum requirement"
}

5. Get member quota

GET /v1/organizations/{organization_id}/members/{member_id}/quota Query the full usage details for a specified member, including plan quota, resource pack quota, total quota, and organization shared pack quota. Currently fixed to the big_model_credits dimension.

Path parameters

ParameterTypeRequiredDescription
organization_idstringYesOrganization ID
member_idstringYesMember ID

Success response (200 OK)

With organization shared pack, status normal:
{
  "userId": "user_abc123",
  "quotaKey": "big_model_credits",
  "planQuota": {
    "quotaSummary": {
      "usedValue": 350.5,
      "limitValue": 1000.0,
      "unit": "credits"
    }
  },
  "resourcePackageQuota": {
    "quotaSummary": {
      "usedValue": 100.0,
      "limitValue": 500.0,
      "unit": "credits"
    }
  },
  "totalQuota": {
    "quotaSummary": {
      "usedValue": 450.5,
      "limitValue": 1500.0,
      "unit": "credits"
    }
  },
  "sharedQuota": {
    "quotaSummary": {
      "usedValue": 200.0,
      "limitValue": 1000.0,
      "unit": "credits"
    }
  },
  "lastResetAt": "2026-03-01T00:00:00Z",
  "nextResetAt": "2026-04-01T00:00:00Z",
  "status": "active"
}
No organization shared pack, usage exceeded:
{
  "userId": "user_def456",
  "quotaKey": "big_model_credits",
  "planQuota": {
    "quotaSummary": {
      "usedValue": 1000.0,
      "limitValue": 1000.0,
      "unit": "credits"
    }
  },
  "totalQuota": {
    "quotaSummary": {
      "usedValue": 1000.0,
      "limitValue": 1000.0,
      "unit": "credits"
    }
  },
  "lastResetAt": "2026-03-01T00:00:00Z",
  "nextResetAt": "2026-04-01T00:00:00Z",
  "status": "restricted"
}
When the organization has no shared pack, sharedQuota is not returned; when the member has no resource pack, resourcePackageQuota is not returned. A status of restricted means the usage limit has been reached.

Response fields

FieldTypeDescription
userIdstringUser ID
quotaKeystringQuota dimension key
planQuotaobjectPlan quota information
resourcePackageQuotaobjectResource pack quota information
totalQuotaobjectTotal quota information (plan + resource pack)
sharedQuotaobject or nullOrganization shared pack quota (not returned if the member’s organization has no shared pack)
lastResetAtstringLast reset time (ISO 8601)
nextResetAtstringNext reset time (ISO 8601)
statusstringUser status: active or restricted
Quota summary fields
FieldTypeDescription
usedValuefloat64Amount used
limitValuefloat64Quota limit
unitstringUnit (e.g., credits)

6. Update member Add-On Cap

PUT /v1/organizations/{organization_id}/members/{member_id}/addon-cap Update a member’s Shared Add-On quota cap (based on Big Model Credits quota).

Path parameters

ParameterTypeRequiredDescription
organization_idstringYesOrganization ID
member_idstringYesMember ID

Request parameters (JSON)

FieldTypeRequiredValidationDescription
addOnCapint64 or nullYesNon-negative integer or nullQuota cap; null means unlimited, 0 means disabled

Request examples

Set a quota cap:
{
  "addOnCap": 1000
}
Set to unlimited:
{
  "addOnCap": null
}

Success response (200 OK)

{
  "memberId": "member_abc123",
  "email": "alice@example.com",
  "addOnCap": 1000
}
When unlimited:
{
  "memberId": "member_abc123",
  "email": "alice@example.com",
  "addOnCap": null
}

Response fields

FieldTypeDescription
memberIdstringMember ID
emailstringMember email
addOnCapint64 or nullCurrent quota cap; null means unlimited

Error responses

Invalid addOnCap format (400)
{
  "requestId": "req_abc123",
  "code": "InvalidAddOnCapFormat",
  "message": "Invalid addOnCap format"
}
Member not in this team (404)
{
  "requestId": "req_abc123",
  "code": "UserNotTeamMember",
  "message": "User is not a member of this team"
}

7. Batch update member Add-On Cap

POST /v1/organizations/{organization_id}/batchUpdateAddOnCap Batch update the Shared Add-On quota cap for specified members (based on Big Model Credits quota). Up to 100 members per request; all members are set to the same cap.

Path parameters

ParameterTypeRequiredDescription
organization_idstringYesOrganization ID

Request parameters (JSON)

FieldTypeRequiredValidationDescription
addOnCapint64 or nullYesNon-negative integer or nullQuota cap; null means unlimited, 0 means disabled
memberIdsstring[]Yes1–100 non-empty stringsList of member IDs to update

Request examples

Batch set quota cap:
{
  "addOnCap": 1000,
  "memberIds": ["member_abc123", "member_def456"]
}
Batch set to unlimited:
{
  "addOnCap": null,
  "memberIds": ["member_abc123"]
}

Success response (200 OK)

{
  "members": [
    {
      "memberId": "member_abc123",
      "previousAddOnCap": 500
    },
    {
      "memberId": "member_def456",
      "previousAddOnCap": null
    }
  ]
}
previousAddOnCap of null means the member previously had no limit (unlimited).

Response fields

FieldTypeDescription
membersarrayUpdate result list, in the same order as memberIds in the request
members[].memberIdstringMember ID
members[].previousAddOnCapint64 or nullPrevious quota cap; null means previously unlimited

Error responses

Invalid addOnCap format (400)
{
  "requestId": "req_abc123",
  "code": "InvalidAddOnCapFormat",
  "message": "Invalid addOnCap format"
}
memberIds is empty (400)
{
  "requestId": "req_abc123",
  "code": "BadRequest",
  "message": "memberIds must not be empty"
}
memberIds exceeds 100 (400)
{
  "requestId": "req_abc123",
  "code": "BadRequest",
  "message": "memberIds must not exceed 100"
}

8. Get member usage limit

GET /v1/organizations/{organization_id}/members/{member_id}/usage-limits/{quota_key} Query the usage limit configuration for a specified member under a given quota key.

Path parameters

ParameterTypeRequiredDescription
organization_idstringYesOrganization ID
member_idstringYesMember ID
quota_keystringYesQuota dimension key (e.g., big_model_credits)

Success response (200 OK)

Limit enabled:
{
  "id": "limit_abc123",
  "organizationId": "org_xxx",
  "userId": "user_abc123",
  "quotaKey": "big_model_credits",
  "limitValue": 1000.0,
  "usedValue": 350.5,
  "resetCycle": "monthly",
  "isActive": true,
  "lastResetAt": "2026-03-01T00:00:00Z",
  "nextResetAt": "2026-04-01T00:00:00Z"
}
Limit paused (**isActive: false**):
{
  "id": "limit_abc123",
  "organizationId": "org_xxx",
  "userId": "user_abc123",
  "quotaKey": "big_model_credits",
  "limitValue": 1000.0,
  "usedValue": 350.5,
  "resetCycle": "monthly",
  "isActive": false,
  "lastResetAt": "2026-03-01T00:00:00Z",
  "nextResetAt": "2026-04-01T00:00:00Z"
}
When isActive is false, the limit rule is not enforced, but the record is preserved and can be re-enabled at any time.

Response fields

FieldTypeDescription
idstringUsage limit record ID
organizationIdstringOrganization ID
userIdstringUser ID
quotaKeystringQuota dimension key
limitValuefloat64Usage cap value
usedValuefloat64Amount used
resetCyclestringReset cycle (e.g., monthly)
isActiveboolWhether enabled
lastResetAtstringLast reset time (ISO 8601)
nextResetAtstringNext reset time (ISO 8601)

9. Update member usage limit

PUT /v1/organizations/{organization_id}/members/{member_id}/usage-limits/{quota_key} Update the usage limit for a specified member under a given quota key. If the limit does not exist, it is automatically created.

Path parameters

ParameterTypeRequiredDescription
organization_idstringYesOrganization ID
member_idstringYesMember ID
quota_keystringYesQuota dimension key (e.g., big_model_credits)

Request parameters (JSON)

FieldTypeRequiredDescription
limitValuefloat64YesUsage cap value
resetCyclestringNoReset cycle (e.g., monthly)
isActiveboolNoWhether enabled

Request examples

Create or update full limit:
{
  "limitValue": 1000.0,
  "resetCycle": "monthly",
  "isActive": true
}
Adjust cap only (keep existing resetCycle and isActive):
{
  "limitValue": 2000.0
}
Pause limit (keep cap unchanged):
{
  "limitValue": 1000.0,
  "isActive": false
}

Success response (200 OK)

Same response format as “Get member usage limit”.

10. Remove member usage limit

DELETE /v1/organizations/{organization_id}/members/{member_id}/usage-limits/{quota_key} Remove the usage limit for a specified member under a given quota key, restoring unlimited status.

Path parameters

ParameterTypeRequiredDescription
organization_idstringYesOrganization ID
member_idstringYesMember ID
quota_keystringYesQuota dimension key (e.g., big_model_credits)

Success response (200 OK)

Same response format as “Get member usage limit”.

Error codes

Error codeHTTP statusDescription
BadRequest400Invalid request parameters (e.g., empty member_id, negative addOnCap)
InvalidAddOnCapFormat400Invalid addOnCap format
InsufficientMembers400Organization member count cannot be lower than the minimum requirement
Unauthorized401API key missing or invalid
Forbidden403No permission to access this organization
NotFound404Member not found
UserNotTeamMember404User is not a member of this team
InternalError500Internal server error
Error response shape: see Error responses in Conventions.

Usage examples

List members

curl -X GET "https://api.qoder.com/v1/organizations/org_xxx/members?maxResults=20" \
  -H "Authorization: Bearer <api_key>"

Search member by email

curl -X GET "https://api.qoder.com/v1/organizations/org_xxx/members?email=alice@example.com" \
  -H "Authorization: Bearer <api_key>"

List members (including removed)

curl -X GET "https://api.qoder.com/v1/organizations/org_xxx/members?includeDeleted=true" \
  -H "Authorization: Bearer <api_key>"

Get member details

curl -X GET "https://api.qoder.com/v1/organizations/org_xxx/members/member_abc123" \
  -H "Authorization: Bearer <api_key>"

Get member statistics

curl -X GET "https://api.qoder.com/v1/organizations/org_xxx/members/statistics" \
  -H "Authorization: Bearer <api_key>"

Delete member

curl -X DELETE "https://api.qoder.com/v1/organizations/org_xxx/members/member_abc123" \
  -H "Authorization: Bearer <api_key>"

Update member Add-On Cap

curl -X PUT "https://api.qoder.com/v1/organizations/org_xxx/members/member_abc123/addon-cap" \
  -H "Authorization: Bearer <api_key>" \
  -H "Content-Type: application/json" \
  -d '{
    "addOnCap": 1000
  }'

Get member quota

curl -X GET "https://api.qoder.com/v1/organizations/org_xxx/members/member_abc123/quota" \
  -H "Authorization: Bearer <api_key>"

Batch update member Add-On Cap

curl -X POST "https://api.qoder.com/v1/organizations/org_xxx/batchUpdateAddOnCap" \
  -H "Authorization: Bearer <api_key>" \
  -H "Content-Type: application/json" \
  -d '{
    "addOnCap": 1000,
    "memberIds": ["member_abc123", "member_def456"]
  }'

Get member usage limit

curl -X GET "https://api.qoder.com/v1/organizations/org_xxx/members/member_abc123/usage-limits/big_model_credits" \
  -H "Authorization: Bearer <api_key>"

Update member usage limit

curl -X PUT "https://api.qoder.com/v1/organizations/org_xxx/members/member_abc123/usage-limits/big_model_credits" \
  -H "Authorization: Bearer <api_key>" \
  -H "Content-Type: application/json" \
  -d '{
    "limitValue": 1000.0,
    "resetCycle": "monthly",
    "isActive": true
  }'

Remove member usage limit

curl -X DELETE "https://api.qoder.com/v1/organizations/org_xxx/members/member_abc123/usage-limits/big_model_credits" \
  -H "Authorization: Bearer <api_key>"