Skip to content
NimbusNexus

User groups

A user group is a named collection of users that can be granted roles together. Instead of granting reader on a project to fifteen engineers individually, you grant it to the backend-team group and add new engineers to the group. Grant the role with POST /api/v1/roles/grant, naming the group and the project, and add members with POST /api/v1/groups/grant.

Groups are scoped to a workspace. A user can belong to multiple groups; a group can hold roles in multiple projects within its workspace. Role assignments are additive — a user gets the union of every role granted directly to them plus every role granted to a group they belong to.

For small teams (under ~10 people) per-user grants are usually fine. Groups become the right answer somewhere between 10 and 50 users, when "audit who has access to project X" needs to be answerable in seconds and not by hand-checking 30 IAM entries.

What's next

  • Users — the things groups contain.
  • Roles — what gets granted to a group.
  • Workspaces — groups are scoped here.

Reference

GET/api/v1/groups/

List Groups

List groups in the caller's workspace, optionally filtered by user membership and search term.

Parameters

NameInTypeDescription
userquerystring | null—
searchquerystring | null—

Responses

  • 200Successful Response
  • 400Bad Request
  • 401Unauthorized
  • 403Forbidden
  • 404Not Found
  • 409Conflict
  • 422Validation error
  • 429Too Many Requests
  • 500Internal Server Error

Example

curl -X GET "https://api.nimbusnexus.net/api/v1/groups/" \
  -H "Authorization: Bearer $NIMBUS_KEY"
POST/api/v1/groups/

Create Group

Create a new group in the caller's workspace.

Request body

FieldTypeDescription
name*string—
descriptionstring | null—

Responses

  • 201Successful Response
  • 400Bad Request
  • 401Unauthorized
  • 403Forbidden
  • 404Not Found
  • 409Conflict
  • 422Validation error
  • 429Too Many Requests
  • 500Internal Server Error

Example

curl -X POST "https://api.nimbusnexus.net/api/v1/groups/" \
  -H "Authorization: Bearer $NIMBUS_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "name": "Example"
  }'
POST/api/v1/groups/grant

Grant Group

Add users to groups in a single batched call. Every group and user must be in the caller's workspace.

Request body

JSON body required.

Responses

  • 200Successful Response
  • 400Bad Request
  • 401Unauthorized
  • 403Forbidden
  • 404Not Found
  • 409Conflict
  • 422Validation error
  • 429Too Many Requests
  • 500Internal Server Error

Example

curl -X POST "https://api.nimbusnexus.net/api/v1/groups/grant" \
  -H "Authorization: Bearer $NIMBUS_KEY" \
  -H "Content-Type: application/json" \
  -d '[
    {
      "user_id": "<user_id>",
      "group_id": "<group_id>"
    }
  ]'
POST/api/v1/groups/revoke

Revoke Group

Remove users from groups in a single batched call. Every group and user must be in the caller's workspace.

Request body

JSON body required.

Responses

  • 200Successful Response
  • 400Bad Request
  • 401Unauthorized
  • 403Forbidden
  • 404Not Found
  • 409Conflict
  • 422Validation error
  • 429Too Many Requests
  • 500Internal Server Error

Example

curl -X POST "https://api.nimbusnexus.net/api/v1/groups/revoke" \
  -H "Authorization: Bearer $NIMBUS_KEY" \
  -H "Content-Type: application/json" \
  -d '[
    {
      "user_id": "<user_id>",
      "group_id": "<group_id>"
    }
  ]'
GET/api/v1/groups/{group_id}

Get Group

Retrieve a single group by ID, scoped to the caller's workspace.

Parameters

NameInTypeDescription
group_id*pathstring—

Responses

  • 200Successful Response
  • 400Bad Request
  • 401Unauthorized
  • 403Forbidden
  • 404Not Found
  • 409Conflict
  • 422Validation error
  • 429Too Many Requests
  • 500Internal Server Error

Example

curl -X GET "https://api.nimbusnexus.net/api/v1/groups/<group_id>" \
  -H "Authorization: Bearer $NIMBUS_KEY"
PATCH/api/v1/groups/{group_id}

Update Group

Update the name or description of an existing group within the caller's workspace.

Parameters

NameInTypeDescription
group_id*pathstring—

Request body

FieldTypeDescription
namestring | null—
descriptionstring | null—

Responses

  • 200Successful Response
  • 400Bad Request
  • 401Unauthorized
  • 403Forbidden
  • 404Not Found
  • 409Conflict
  • 422Validation error
  • 429Too Many Requests
  • 500Internal Server Error

Example

curl -X PATCH "https://api.nimbusnexus.net/api/v1/groups/<group_id>" \
  -H "Authorization: Bearer $NIMBUS_KEY" \
  -H "Content-Type: application/json" \
  -d '{}'
DELETE/api/v1/groups/{group_id}

Delete Group

Delete a group from the caller's workspace.

Parameters

NameInTypeDescription
group_id*pathstring—

Responses

  • 204Successful Response
  • 400Bad Request
  • 401Unauthorized
  • 403Forbidden
  • 404Not Found
  • 409Conflict
  • 422Validation error
  • 429Too Many Requests
  • 500Internal Server Error

Example

curl -X DELETE "https://api.nimbusnexus.net/api/v1/groups/<group_id>" \
  -H "Authorization: Bearer $NIMBUS_KEY"

Need to make a real call? Try these endpoints in the live Swagger UI →