Skip to Content
The Ngamia platform API is in preview. Endpoints may change before general availability.
API referenceMembers and invites

Members and invites

Manage the people in a workspace and invite new ones.

List members (admin)

GET /v1/members

curl -X GET https://api.ngamia.com/v1/members \ -H "Authorization: Bearer $NGAMIA_TOKEN"

Response 200 fields

FieldTypeRequiredNotes
membersarray of object

Responses

StatusMeaning
200Current members
403The role or key scope does not allow this (forbidden).

Add a member or set their role (admin; owner for admin/owner roles)

PUT /v1/members/{user_id}

Adds the person (by KIDA user ID) if they are not a member yet. A workspace always keeps at least one owner. Demoting an admin or owner below admin revokes the API keys they created.

Parameters

ParameterInTypeNotes
user_idpathstringrequired

Request body (application/json)

FieldTypeRequiredNotes
roleowner | admin | developer | vieweryes
curl -X PUT https://api.ngamia.com/v1/members/<user_id> \ -H "Authorization: Bearer $NGAMIA_TOKEN" \ -H 'content-type: application/json' \ -d '{"role": "owner"}'

Responses

StatusMeaning
204Role set
400The request is invalid (invalid_request).
403The role or key scope does not allow this (forbidden).
409Conflicts with the current state, e.g. a stale version or a taken slug (conflict).

Remove a member (admin)

DELETE /v1/members/{user_id}

The person loses access at once (their existing tokens stop working) and cannot sign back in until re-invited. The API keys they created are revoked.

Parameters

ParameterInTypeNotes
user_idpathstringrequired
curl -X DELETE https://api.ngamia.com/v1/members/<user_id> \ -H "Authorization: Bearer $NGAMIA_TOKEN"

Responses

StatusMeaning
204Removed
403The role or key scope does not allow this (forbidden).
409Conflicts with the current state, e.g. a stale version or a taken slug (conflict).

List invites (admin)

GET /v1/invites

curl -X GET https://api.ngamia.com/v1/invites \ -H "Authorization: Bearer $NGAMIA_TOKEN"

Response 200 fields

FieldTypeRequiredNotes
invitesarray of object

Responses

StatusMeaning
200Invites, newest first (codes are never listed)

Create an invite (admin; owner for admin invites)

POST /v1/invites

Request body (application/json)

FieldTypeRequiredNotes
roleadmin | developer | vieweryes
expires_in_hoursintegermin 1, max 720, default 72
max_usesintegermin 1, max 1000, default 1
curl -X POST https://api.ngamia.com/v1/invites \ -H "Authorization: Bearer $NGAMIA_TOKEN" \ -H 'content-type: application/json' \ -d '{"role": "admin"}'

Response 201 fields

FieldTypeRequiredNotes
inviteobject
codestring

Responses

StatusMeaning
201Created. code is shown only here; share it privately.
403The role or key scope does not allow this (forbidden).

Revoke an invite (admin)

DELETE /v1/invites/{id}

Parameters

ParameterInTypeNotes
idpathstring (uuid)required
curl -X DELETE https://api.ngamia.com/v1/invites/<id> \ -H "Authorization: Bearer $NGAMIA_TOKEN"

Responses

StatusMeaning
204Revoked
404Not found in this workspace (not_found).
Last updated on