Entity Relationship Types (Beta)
Use these operations to interact with entity relationship types in Cortex.
Required permissions
Create and Update Relationship Types: Your API key must have the Edit entities permission.
Your tenant must also have the Entity relationships feature enabled.
Operations
List paginated relationship types
Number of results to return per page, between 1 and 1000. Default 250.
250Page number to return, 0-indexed. Default 0.
0Successfully found entity relationship types
The client has exceeded the rate limit by performing too many requests in a short period. Retry the request after a delay.
GET /api/v1/relationship-types?pageSize=250&page=0 HTTP/1.1
Host: api.getcortexapp.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"page": 1,
"relationshipTypes": [
{
"allowCycles": false,
"definitionLocation": "BOTH",
"description": "Defines the component hierarchy",
"destinationLabelPlural": "Parts",
"destinationLabelSingular": "Part",
"destinationNamePlural": "text",
"destinationNameSingular": "text",
"destinationsFilter": {
"include": true,
"types": [
"text"
]
},
"inheritances": [
{
"inheritanceType": "NONE",
"parameterTag": "text"
}
],
"isCortexManaged": false,
"isSingleDestination": false,
"isSingleSource": false,
"name": "Component Hierarchy",
"sourceLabelPlural": "Components",
"sourceLabelSingular": "Component",
"sourceNamePlural": "text",
"sourceNameSingular": "text",
"sourcesFilter": {
"include": true,
"types": [
"text"
]
},
"tag": "component-hierarchy"
}
],
"total": 1,
"totalPages": 1
}Create a relationship type
Request to create or update a relationship type
Whether cyclical relationships are allowed
falseWhether to create a catalog page for this relationship type
falseDefines where a relationship can be configured in entity descriptors
BOTHPossible values: Optional description explaining the relationship type
Defines the component hierarchyPlural label for destinations in the relationship
PartsSingular label for destinations in the relationship
PartWhether an entity can have only one destination for this relationship type
falseWhether an entity can have only one source for this relationship type
falseHuman-readable name for the relationship type
Component HierarchyPlural label for sources in the relationship
ComponentsSingular label for sources in the relationship
ComponentUnique identifier tag for the relationship type
component-hierarchySuccessfully created relationship type
Validation error creating relationship type
The client has exceeded the rate limit by performing too many requests in a short period. Retry the request after a delay.
POST /api/v1/relationship-types HTTP/1.1
Host: api.getcortexapp.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 1395
"{\n \"name\": \"Component Hierarchy\",\n \"tag\": \"component-hierarchy\",\n \"description\": \"Defines the component hierarchy.\",\n \"definitionLocation\": \"BOTH\",\n \"isSingleSource\": true,\n \"sourcesFilter\": {\n \"include\": true,\n \"types\": [\"component\"]\n },\n \"isSingleDestination\": false,\n \"destinationsFilter\": {\n \"include\": true,\n \"types\": [\"service\", \"component]\n },\n \"inheritances\": [\n {\n \"parameterTag\": \"x-cortex-owners\",\n \"inheritanceType\": \"FALLBACK\"\n }\n ],\n \"allowCycles\": false,\n \"sourceLabelSingular\": \"Component\",\n \"sourceLabelPlural\": \"Components\",\n \"destinationLabelSingular\": \"Part\",\n \"destinationLabelPlural\": \"Parts\",\n \"createCatalog\": false\n }"{
"allowCycles": false,
"definitionLocation": "BOTH",
"description": "Defines the component hierarchy",
"destinationLabelPlural": "Parts",
"destinationLabelSingular": "Part",
"destinationNamePlural": "text",
"destinationNameSingular": "text",
"destinationsFilter": {
"include": true,
"types": [
"text"
]
},
"inheritances": [
{
"inheritanceType": "NONE",
"parameterTag": "text"
}
],
"isCortexManaged": false,
"isSingleDestination": false,
"isSingleSource": false,
"name": "Component Hierarchy",
"sourceLabelPlural": "Components",
"sourceLabelSingular": "Component",
"sourceNamePlural": "text",
"sourceNameSingular": "text",
"sourcesFilter": {
"include": true,
"types": [
"text"
]
},
"tag": "component-hierarchy"
}List details for a relationship type
Successfully found relationship type
Relationship type not found
The client has exceeded the rate limit by performing too many requests in a short period. Retry the request after a delay.
GET /api/v1/relationship-types/{relationshipTypeTag} HTTP/1.1
Host: api.getcortexapp.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
{
"allowCycles": false,
"definitionLocation": "BOTH",
"description": "Defines the component hierarchy",
"destinationLabelPlural": "Parts",
"destinationLabelSingular": "Part",
"destinationNamePlural": "text",
"destinationNameSingular": "text",
"destinationsFilter": {
"include": true,
"types": [
"text"
]
},
"inheritances": [
{
"inheritanceType": "NONE",
"parameterTag": "text"
}
],
"isCortexManaged": false,
"isSingleDestination": false,
"isSingleSource": false,
"name": "Component Hierarchy",
"sourceLabelPlural": "Components",
"sourceLabelSingular": "Component",
"sourceNamePlural": "text",
"sourceNameSingular": "text",
"sourcesFilter": {
"include": true,
"types": [
"text"
]
},
"tag": "component-hierarchy"
}Update relationship type
Request to create or update a relationship type
Whether cyclical relationships are allowed
falseWhether to create a catalog page for this relationship type
falseDefines where a relationship can be configured in entity descriptors
BOTHPossible values: Optional description explaining the relationship type
Defines the component hierarchyPlural label for destinations in the relationship
PartsSingular label for destinations in the relationship
PartWhether an entity can have only one destination for this relationship type
falseWhether an entity can have only one source for this relationship type
falseHuman-readable name for the relationship type
Component HierarchyPlural label for sources in the relationship
ComponentsSingular label for sources in the relationship
ComponentUnique identifier tag for the relationship type
component-hierarchySuccessfully updated relationship type
Validation error updating relationship type
The client has exceeded the rate limit by performing too many requests in a short period. Retry the request after a delay.
PUT /api/v1/relationship-types/{relationshipTypeTag} HTTP/1.1
Host: api.getcortexapp.com
Authorization: Bearer YOUR_SECRET_TOKEN
Content-Type: application/json
Accept: */*
Content-Length: 532
{
"allowCycles": false,
"createCatalog": false,
"definitionLocation": "BOTH",
"description": "Defines the component hierarchy",
"destinationLabelPlural": "Parts",
"destinationLabelSingular": "Part",
"destinationsFilter": {
"include": true,
"types": [
"text"
]
},
"inheritances": [
{
"inheritanceType": "NONE",
"parameterTag": "text"
}
],
"isSingleDestination": false,
"isSingleSource": false,
"name": "Component Hierarchy",
"sourceLabelPlural": "Components",
"sourceLabelSingular": "Component",
"sourcesFilter": {
"include": true,
"types": [
"text"
]
},
"tag": "component-hierarchy"
}{
"allowCycles": false,
"definitionLocation": "BOTH",
"description": "Defines the component hierarchy",
"destinationLabelPlural": "Parts",
"destinationLabelSingular": "Part",
"destinationNamePlural": "text",
"destinationNameSingular": "text",
"destinationsFilter": {
"include": true,
"types": [
"text"
]
},
"inheritances": [
{
"inheritanceType": "NONE",
"parameterTag": "text"
}
],
"isCortexManaged": false,
"isSingleDestination": false,
"isSingleSource": false,
"name": "Component Hierarchy",
"sourceLabelPlural": "Components",
"sourceLabelSingular": "Component",
"sourceNamePlural": "text",
"sourceNameSingular": "text",
"sourcesFilter": {
"include": true,
"types": [
"text"
]
},
"tag": "component-hierarchy"
}Delete a relationship type
Successfully deleted relationship type
No content
No Content
Validation error deleting relationship type
The client has exceeded the rate limit by performing too many requests in a short period. Retry the request after a delay.
DELETE /api/v1/relationship-types/{relationshipTypeTag} HTTP/1.1
Host: api.getcortexapp.com
Authorization: Bearer YOUR_SECRET_TOKEN
Accept: */*
No content
Last updated
Was this helpful?