Relationships


GET /{o}/{p}/envs/{envName}/relationships

List relationships

List relationships in this environment with optional filtering and pagination.

Auth: Bearer token required · Permission: data:read

Path parameters

NameTypeDescription
ostring
pstring
envNamestring

Responses

StatusDescriptionSchema
200RelationshipsRelationshipList

POST /{o}/{p}/envs/{envName}/relationships

Create a relationship

Auth: Bearer token required · Permission: data:write

Path parameters

NameTypeDescription
ostring
pstring
envNamestring

Request body (application/json)

FieldTypeDescription
kindRelationship(required)
relationshipTypestring(required)
fromstring(required)
tostring(required)
statestring
propertiesobject
labelsobject

Responses

StatusDescriptionSchema
201Created relationshipRelationship
403Cell-scope violationError
404RelationshipType or entity not foundError

GET /{o}/{p}/envs/{envName}/relationships/{id}

Get a relationship by id

Auth: Bearer token required · Permission: data:read

Path parameters

NameTypeDescription
ostring
pstring
envNamestring
idstring

Responses

StatusDescriptionSchema
200The relationshipRelationship
404Relationship not foundError

PUT /{o}/{p}/envs/{envName}/relationships/{id}

Update a relationship

Auth: Bearer token required · Permission: data:write

Path parameters

NameTypeDescription
ostring
pstring
envNamestring
idstring

Request body (application/json)

FieldTypeDescription
statestring
propertiesobject
labelsobject

Responses

StatusDescriptionSchema
200Updated relationshipRelationship
403Cell-scope violationError
404Relationship not foundError

DELETE /{o}/{p}/envs/{envName}/relationships/{id}

Delete a relationship

Auth: Bearer token required · Permission: data:write

Path parameters

NameTypeDescription
ostring
pstring
envNamestring
idstring

Responses

StatusDescriptionSchema
200Deletion resultDeletedById
404Relationship not foundError

PUT /{o}/{p}/envs/{envName}/relationships/{id}/state

Transition a relationship state

Auth: Bearer token required · Permission: data:write

Path parameters

NameTypeDescription
ostring
pstring
envNamestring
idstring

Request body (application/json)

FieldTypeDescription
statestring(required)

Responses

StatusDescriptionSchema
200Updated relationshipRelationship
404Relationship not foundError

POST /{o}/{p}/envs/{envName}/relationships/{id}/finalize-deletion

Force-finalize a relationship deletion

Skip the remaining grace period and immediately finalize a relationship scheduled for deletion.

Auth: Bearer token required · Permission: data:write

Path parameters

NameTypeDescription
ostring
pstring
envNamestring
idstring

Request body (application/json)

FieldTypeDescription
finalStatestring

Responses

StatusDescriptionSchema
200Finalized relationshipRelationship
404Relationship not foundError
409No scheduled grace periodError

Schemas

DeletedById

FieldTypeDescription
deletedtrue(required)
idstring(required)

Error

FieldTypeDescription
errorstring(required)
codestring

Relationship

FieldTypeDescription
statestring(required)
propertiesobject(required)
labelsobject(required)
idstring(uuid)(required)
relationshipTypeNamestring(required)
fromEntityIdstring(required)
toEntityIdstring(required)
envIdstring(uuid)(required)
orgIdstring(required)
projectIdstring(required)
createdAtstring | string(required)
updatedAtstring | string(required)

RelationshipList

Type: Relationship[]