Groups
List the instance's groups, filtered by owner (D6, D15, D44): owner_type root lists the instance's own groups, org the organizations', a resource type key that type's resources'; owner_id narrows to one owner's. Neither lists every group.
x-pontive-instance-id<token>Instance ID for the request
owner_type?stringroot, org, or the owning resource's type key
owner_id?stringOne owner's prefixed id: inst_, org_ or res_
search?stringMatches the name
external_id?stringAn identity provider's id for the group
page?integerPage number
limit?integerItems per page
sort?stringSort field; prefix with - for descending. Allowed: created_at, updated_at, name. Default: -created_at
OK
application/json- response
data?array<>object?stringpagination?Pagination is the page answered (api-route-review D9).
curl -X GET 'https://api.us.pontive.com/v1/groups'{ "data": [ { "created_at": "string", "external_id": "string", "id": "string", "member_count": 0, "metadata": { "property1": "string", "property2": "string" }, "name": "string", "object": "string", "owner_id": "string", "owner_type": "string", "updated_at": "string" } ], "object": "string", "pagination": { "limit": 0, "page": 0, "total": 0, "total_pages": 0 }}Create a group, owned by the instance root, an organization or a resource (D5, D6, D44): owner_type is root (the default), org or the owning resource's type key, owner_id its prefixed id (org_, res_; for root the inst_ id or empty). An instance group (root) holds any of the instance's users and is granted roles only on the instance root and resources in no organization; an organization's is a set of its members granted on the organization or its resources; a resource's holds its organization's members and is granted only on the resource and the resources beneath it.
x-pontive-instance-id<token>Instance ID for the request
Group
application/json- body
Group
external_id?stringExternalID is an identity provider's id for the group, unique in its owner.
metadata?Metadata replaces the group's metadata when set.
name*stringowner_id?stringOwnerID is the owner's prefixed id: org_ or res_; for root the inst_ id or empty.
owner_type?stringOwnerType is root (the default), org, or the owning resource's type key, which must be that resource's type.
Created
application/json- response
created_at?stringexternal_id?stringid?stringmember_count?integermetadata?Metadata replaces the group's metadata when set.
name?stringobject?stringowner_id?stringOwnerID is the owner's prefixed id: inst_, org_ or res_.
owner_type?stringOwnerType is the owner's resource-type key: root, org, or the owning resource's type key.
updated_at?stringcurl -X POST 'https://api.us.pontive.com/v1/groups' \ -H 'Content-Type: application/json' \ -d '{ "name": "string"}'{ "created_at": "string", "external_id": "string", "id": "string", "member_count": 0, "metadata": { "property1": "string", "property2": "string" }, "name": "string", "object": "string", "owner_id": "string", "owner_type": "string", "updated_at": "string"}x-pontive-instance-id<token>Instance ID for the request
group_id*stringGroup ID
OK
application/json- response
created_at?stringexternal_id?stringid?stringmember_count?integermetadata?Metadata replaces the group's metadata when set.
name?stringobject?stringowner_id?stringOwnerID is the owner's prefixed id: inst_, org_ or res_.
owner_type?stringOwnerType is the owner's resource-type key: root, org, or the owning resource's type key.
updated_at?stringcurl -X GET 'https://api.us.pontive.com/v1/groups/string'{ "created_at": "string", "external_id": "string", "id": "string", "member_count": 0, "metadata": { "property1": "string", "property2": "string" }, "name": "string", "object": "string", "owner_id": "string", "owner_type": "string", "updated_at": "string"}x-pontive-instance-id<token>Instance ID for the request
group_id*stringGroup ID
Changes
application/json- body
Changes
external_id?stringExternalID, when set, replaces it; an empty string clears it.
metadata?Metadata replaces the group's metadata when set.
name?stringOK
application/json- response
created_at?stringexternal_id?stringid?stringmember_count?integermetadata?Metadata replaces the group's metadata when set.
name?stringobject?stringowner_id?stringOwnerID is the owner's prefixed id: inst_, org_ or res_.
owner_type?stringOwnerType is the owner's resource-type key: root, org, or the owning resource's type key.
updated_at?stringcurl -X PATCH 'https://api.us.pontive.com/v1/groups/string' \ -H 'Content-Type: application/json' \ -d '{}'{ "created_at": "string", "external_id": "string", "id": "string", "member_count": 0, "metadata": { "property1": "string", "property2": "string" }, "name": "string", "object": "string", "owner_id": "string", "owner_type": "string", "updated_at": "string"}Delete a group with its members and grants. Its members lose what the group gave them.
x-pontive-instance-id<token>Instance ID for the request
group_id*stringGroup ID
No Content
curl -X DELETE 'https://api.us.pontive.com/v1/groups/string'x-pontive-instance-id<token>Instance ID for the request
group_id*stringGroup ID
search?stringMatches email and name
page?integerPage number
limit?integerItems per page
OK
application/json- response
data?array<>object?stringpagination?Pagination is the page answered (api-route-review D9).
curl -X GET 'https://api.us.pontive.com/v1/groups/string/members'{ "data": [ { "group_id": "string", "joined_at": "string", "object": "string", "user": { "email": "string", "email_verified": true, "family_name": "string", "given_name": "string", "id": "string", "name": "string", "picture": "string", "status": "string", "username": "string" } } ], "object": "string", "pagination": { "limit": 0, "page": 0, "total": 0, "total_pages": 0 }}Add users to a group. Each must be a member of the group's organization (user_not_in_organization); one already in the group is left as they are.
x-pontive-instance-id<token>Instance ID for the request
group_id*stringGroup ID
Users
application/json- body
Users
user_ids*array<string>Each must be a member of the group's organization; an instance group takes any of the instance's users.
OK
application/json- response
added?integerHow many were added; users already in the group are not counted.
curl -X POST 'https://api.us.pontive.com/v1/groups/string/members' \ -H 'Content-Type: application/json' \ -d '{ "user_ids": [ "string" ]}'{ "added": 0}x-pontive-instance-id<token>Instance ID for the request
group_id*stringGroup ID
user_id*stringUser ID
No Content
curl -X DELETE 'https://api.us.pontive.com/v1/groups/string/members/string'List the roles a group holds, per resource
x-pontive-instance-id<token>Instance ID for the request
group_id*stringGroup ID
page?integerPage number
limit?integerItems per page
OK
application/json- response
data?array<>object?stringpagination?Pagination is the page answered (api-route-review D9).
curl -X GET 'https://api.us.pontive.com/v1/groups/string/roles'{ "data": [ { "group_id": "string", "object": "string", "resource_id": "string", "resource_type": "string", "roles": [ "string" ] } ], "object": "string", "pagination": { "limit": 0, "page": 0, "total": 0, "total_pages": 0 }}Replace the roles a group holds on one resource — its organization, or a resource of it (resource_not_in_organization) — with roles of that resource's type. No roles removes the grant.
x-pontive-instance-id<token>Instance ID for the request
group_id*stringGroup ID
Grant
application/json- body
Grant
resource_id*stringResourceID is org_…, res_…, or for the root the instance id (inst_…) or the alias "root".
resource_type*stringroles?array<string>OK
application/json- response
group_id?stringobject?stringresource_id?stringresource_type?stringroles?array<string>curl -X PUT 'https://api.us.pontive.com/v1/groups/string/roles' \ -H 'Content-Type: application/json' \ -d '{ "resource_id": "string", "resource_type": "string"}'{ "group_id": "string", "object": "string", "resource_id": "string", "resource_type": "string", "roles": [ "string" ]}The groups holding roles on an organization itself, each with its roles there (api-route-review D43). A group holding roles only on the organization's resources is not listed; the groups the organization owns are GET /groups?owner_type=org&owner_id=….
x-pontive-instance-id<token>Instance ID for the request
organization*stringThe organization's id, or its slug
page?integerPage number
limit?integerItems per page
OK
application/json- response
data?array<>object?stringpagination?Pagination is the page answered (api-route-review D9).
curl -X GET 'https://api.us.pontive.com/v1/organizations/string/group-roles'{ "data": [ { "group_id": "string", "object": "string", "resource_id": "string", "resource_type": "string", "roles": [ "string" ] } ], "object": "string", "pagination": { "limit": 0, "page": 0, "total": 0, "total_pages": 0 }}The groups holding roles on a resource, whoever owns them, each with its roles there (api-route-review D43). The groups the resource owns are GET /groups?owner_type=&owner_id=….
x-pontive-instance-id<token>Instance ID for the request
resource_id*stringResource ID
page?integerPage number
limit?integerItems per page
OK
application/json- response
data?array<>object?stringpagination?Pagination is the page answered (api-route-review D9).
curl -X GET 'https://api.us.pontive.com/v1/resources/string/group-roles'{ "data": [ { "group_id": "string", "object": "string", "resource_id": "string", "resource_type": "string", "roles": [ "string" ] } ], "object": "string", "pagination": { "limit": 0, "page": 0, "total": 0, "total_pages": 0 }}The groups holding roles on the instance root, each with its roles there (api-route-review D43): the read edge from the other side of GET /groups/{group_id}/roles. The groups the root owns are GET /groups?owner_type=root.
x-pontive-instance-id<token>Instance ID for the request
page?integerPage number
limit?integerItems per page
OK
application/json- response
data?array<>object?stringpagination?Pagination is the page answered (api-route-review D9).
curl -X GET 'https://api.us.pontive.com/v1/root/group-roles'{ "data": [ { "group_id": "string", "object": "string", "resource_id": "string", "resource_type": "string", "roles": [ "string" ] } ], "object": "string", "pagination": { "limit": 0, "page": 0, "total": 0, "total_pages": 0 }}