POST/organization/groups/{group_id}/users

Add a user to a group

Adds a user to a group in the organization. Supply the user's identifier in user_id to specify the membership to create. The response confirms the added user and the group they were added to.

  • IdempotentThe SDK sends Idempotency-Key, so a retried request is only applied once.

1 parameter · 1 body field
group_idstringrequired
The identifier of the group to update.

Identifies the user to add to the group.

user_idstringrequired
Identifier of the user to add to the group.

6 status codes
200Returns a confirmation containing the `group.user` object type, the added user's identifier, and the group's identifier.
objectstringrequired
Always `group.user`.
Allowed:group.user
user_idstringrequired
Identifier of the user that was added.
group_idstringrequired
Identifier of the group the user was added to.
400Returned when the request contains invalid parameters or an invalid body.
errorobjectrequired
403Returned when the authenticated user lacks the required permissions or the request does not use an admin API key.
errorobjectrequired
Details about the permission error.
404Returned when the group or user is not found in the organization, or the endpoint is unavailable.
errorobjectrequired
409Returned when the request conflicts with the current state of the group.
errorobjectrequired
429Returned when the request is rejected because a rate limit was exceeded.
errorobjectrequired

Error handling

A 400 is returned when the request parameters or body are invalid; a 403 when the authenticated user lacks permission or the request does not use an admin API key; a 404 when the group or user is not found or the endpoint is unavailable; a 409 when the request conflicts with the group's current state; and a 429 when the rate limit is exceeded. The group_id path parameter must identify the group. The body must include user_id identifying the user to add.