Skip to main content
POST
Create Access Relationship

Authentication and permissions

Token requirements: User-based token (OAuth) or Organization-scoped API key or Team-scoped API key. Send a bearer access token for one of these identities. The permissions and resource restrictions below also apply.
Permissions joined by + are all required; or separates alternatives. Full-access keys still cannot call endpoints marked unsupported. Team keys must allow every team checked by the request. OAuth access depends on the user’s roles and resource access.

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
subjectType
enum<string>
required

The kind of subject the relationship is on.

Available options:
ACCESS_RELATIONSHIP_SUBJECT_TYPE_UNSPECIFIED,
ACCESS_RELATIONSHIP_SUBJECT_TYPE_APP_INSTANCE,
ACCESS_RELATIONSHIP_SUBJECT_TYPE_RESOURCE,
ACCESS_RELATIONSHIP_SUBJECT_TYPE_ENTITLEMENT,
ACCESS_RELATIONSHIP_SUBJECT_TYPE_TEAM,
ACCESS_RELATIONSHIP_SUBJECT_TYPE_KNOWLEDGE_ITEM
subjectId
string
required

The ID of the subject (app_instance_id | resource_id | entitlement_id | team_id), disambiguated by subject_type.

relationshipType
enum<string>
required

The type of relationship.

Available options:
ACCESS_RELATIONSHIP_TYPE_UNSPECIFIED,
ACCESS_RELATIONSHIP_TYPE_OWNER
targetId
string
required

The ID of the target (user or group).

targetType
enum<string>
required

The type of the target.

Available options:
ACCESS_RELATIONSHIP_TARGET_TYPE_UNSPECIFIED,
ACCESS_RELATIONSHIP_TARGET_TYPE_USER,
ACCESS_RELATIONSHIP_TARGET_TYPE_GROUP

Response

200 - application/json

Success

data
data · object

The created access relationship.