> For the complete documentation index, see [llms.txt](https://docs.cortex.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.cortex.io/api/readme/dependencies.md).

# Dependencies

Use these operations to interact with [dependencies](/ingesting-data-into-cortex/entities-overview/entities/adding-entities/dependencies.md) in Cortex.

### Required permissions

Your API key must have the `Edit entities` permission.

## Operations

## GET /api/v1/catalog/{callerTag}/dependencies

> Retrieve all dependencies for an entity

```json
{"openapi":"3.0.1","info":{"title":"Cortex API","version":"v1"},"tags":[{"name":"Dependencies"}],"servers":[{"url":"https://api.getcortexapp.com","description":"Cortex Cloud API host"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"bearerFormat":"JWT","description":"All requests to the Cortex API need to provide an `Authorization: Bearer <token>` header, where `<token>` is an API key created in the Settings page of your workspace.","scheme":"bearer","type":"http"}},"schemas":{"DependencyResponse":{"required":["calleeTag","calleeType","callerTag","callerType"],"type":"object","properties":{"calleeTag":{"type":"string","description":"Entity tag (x-cortex-tag) for the callee entity"},"calleeType":{"type":"string","description":"Type of the callee entity. Corresponds to the x-cortex-type field in the entity descriptor or ‘service’ for services."},"callerTag":{"type":"string","description":"Entity tag (x-cortex-tag) for the caller entity"},"callerType":{"type":"string","description":"Type of the caller entity. Corresponds to the x-cortex-type field in the entity descriptor or ‘service’ for services."},"description":{"type":"string"},"metadata":{"$ref":"#/components/schemas/JsonNode"},"method":{"type":"string","description":"Possible values: [GET, HEAD, POST, PUT, PATCH, DELETE, OPTIONS, TRACE]"},"path":{"type":"string"}}},"JsonNode":{"type":"object"},"ErrorResponse":{"required":["message","type"],"type":"object","properties":{"details":{"type":"string"},"errorCode":{"type":"string"},"gatewayHttpStatus":{"type":"integer","format":"int32"},"httpStatus":{"type":"integer","format":"int32"},"message":{"type":"string"},"requestId":{"type":"string"},"type":{"type":"string","enum":["INTEGRATION_MISSING","INTEGRATION_UNREGISTERED","INTEGRATION_UNSUPPORTED","INTEGRATION_GRAPHQL_ERROR","INTEGRATION_BAD_REQUEST","INTEGRATION_UNAUTHORIZED","INTEGRATION_FORBIDDEN","INTEGRATION_NOT_FOUND","INTEGRATION_UNPROCESSABLE_CONTENT","INTEGRATION_RATE_LIMITED","INTEGRATION_INTERNAL_ERROR","INTEGRATION_NOT_IMPLEMENTED","INTEGRATION_BAD_GATEWAY","INTEGRATION_UNAVAILABLE","INTEGRATION_GATEWAY_TIMEOUT","INTEGRATION_TIMED_OUT","INTEGRATION_CACHE_ERROR","INTEGRATION_UNHANDLED_HTTP_ERROR","INTEGRATION_UNHANDLED_EXCEPTION","INTEGRATION_UNEXPECTED_ERROR","ILLEGAL_ARGUMENT_ERROR","BAD_REQUEST","FORBIDDEN","NOT_FOUND","REQUEST_TIMEOUT","CONFLICT","UNHANDLED_EXCEPTION","UNCATEGORIZED","SERVICE_CREATOR","UNKNOWN_HOST","TOO_MANY_REQUESTS"]}}},"TooManyRequestsProblemDetail":{"required":["type","title","status"],"type":"object","properties":{"detail":{"type":"string"},"instance":{"type":"string","format":"uri-reference"},"retryAfter":{"minimum":0,"type":"integer","description":"The number of seconds until the rate limiting resets.","format":"int32"},"status":{"maximum":599,"minimum":100,"type":"integer","format":"int32","enum":[429]},"title":{"type":"string"},"type":{"type":"string","format":"uri-reference"}}}},"responses":{"TooManyRequests":{"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsProblemDetail"}}},"description":"The client has exceeded the rate limit by performing too many requests in a short period. Retry the request after a delay.","headers":{"Retry-After":{"description":"The number of seconds until the rate limiting resets.","schema":{"minimum":0,"type":"integer","format":"int32"}}}}}},"paths":{"/api/v1/catalog/{callerTag}/dependencies":{"get":{"operationId":"listDependenciesForEntity","parameters":[{"in":"path","name":"callerTag","required":true,"schema":{"type":"string"}},{"in":"query","name":"includeOutgoing","required":false,"schema":{"type":"boolean","default":true}},{"in":"query","name":"includeIncoming","required":false,"schema":{"type":"boolean","default":false}},{"description":"Number of results to return per page, between 1 and 1000. Default 250.","in":"query","name":"pageSize","required":true,"schema":{"type":"integer","format":"int32","default":250}},{"description":"Page number to return, 0-indexed. Default 0.","in":"query","name":"page","required":true,"schema":{"type":"integer","format":"int32","default":0}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DependencyResponse"}}},"description":"Successfully found entity dependencies"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Entity dependencies not found"},"429":{"$ref":"#/components/responses/TooManyRequests"}},"summary":"Retrieve all dependencies for an entity","tags":["Dependencies"]}}}}
```

## Retrieve dependency between entities

> If a dependency exists between the \`callee\` and the \`caller\`, returns metadata about the edge.

```json
{"openapi":"3.0.1","info":{"title":"Cortex API","version":"v1"},"tags":[{"name":"Dependencies"}],"servers":[{"url":"https://api.getcortexapp.com","description":"Cortex Cloud API host"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"bearerFormat":"JWT","description":"All requests to the Cortex API need to provide an `Authorization: Bearer <token>` header, where `<token>` is an API key created in the Settings page of your workspace.","scheme":"bearer","type":"http"}},"schemas":{"DependencyResponse":{"required":["calleeTag","calleeType","callerTag","callerType"],"type":"object","properties":{"calleeTag":{"type":"string","description":"Entity tag (x-cortex-tag) for the callee entity"},"calleeType":{"type":"string","description":"Type of the callee entity. Corresponds to the x-cortex-type field in the entity descriptor or ‘service’ for services."},"callerTag":{"type":"string","description":"Entity tag (x-cortex-tag) for the caller entity"},"callerType":{"type":"string","description":"Type of the caller entity. Corresponds to the x-cortex-type field in the entity descriptor or ‘service’ for services."},"description":{"type":"string"},"metadata":{"$ref":"#/components/schemas/JsonNode"},"method":{"type":"string","description":"Possible values: [GET, HEAD, POST, PUT, PATCH, DELETE, OPTIONS, TRACE]"},"path":{"type":"string"}}},"JsonNode":{"type":"object"},"ErrorResponse":{"required":["message","type"],"type":"object","properties":{"details":{"type":"string"},"errorCode":{"type":"string"},"gatewayHttpStatus":{"type":"integer","format":"int32"},"httpStatus":{"type":"integer","format":"int32"},"message":{"type":"string"},"requestId":{"type":"string"},"type":{"type":"string","enum":["INTEGRATION_MISSING","INTEGRATION_UNREGISTERED","INTEGRATION_UNSUPPORTED","INTEGRATION_GRAPHQL_ERROR","INTEGRATION_BAD_REQUEST","INTEGRATION_UNAUTHORIZED","INTEGRATION_FORBIDDEN","INTEGRATION_NOT_FOUND","INTEGRATION_UNPROCESSABLE_CONTENT","INTEGRATION_RATE_LIMITED","INTEGRATION_INTERNAL_ERROR","INTEGRATION_NOT_IMPLEMENTED","INTEGRATION_BAD_GATEWAY","INTEGRATION_UNAVAILABLE","INTEGRATION_GATEWAY_TIMEOUT","INTEGRATION_TIMED_OUT","INTEGRATION_CACHE_ERROR","INTEGRATION_UNHANDLED_HTTP_ERROR","INTEGRATION_UNHANDLED_EXCEPTION","INTEGRATION_UNEXPECTED_ERROR","ILLEGAL_ARGUMENT_ERROR","BAD_REQUEST","FORBIDDEN","NOT_FOUND","REQUEST_TIMEOUT","CONFLICT","UNHANDLED_EXCEPTION","UNCATEGORIZED","SERVICE_CREATOR","UNKNOWN_HOST","TOO_MANY_REQUESTS"]}}},"TooManyRequestsProblemDetail":{"required":["type","title","status"],"type":"object","properties":{"detail":{"type":"string"},"instance":{"type":"string","format":"uri-reference"},"retryAfter":{"minimum":0,"type":"integer","description":"The number of seconds until the rate limiting resets.","format":"int32"},"status":{"maximum":599,"minimum":100,"type":"integer","format":"int32","enum":[429]},"title":{"type":"string"},"type":{"type":"string","format":"uri-reference"}}}},"responses":{"TooManyRequests":{"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsProblemDetail"}}},"description":"The client has exceeded the rate limit by performing too many requests in a short period. Retry the request after a delay.","headers":{"Retry-After":{"description":"The number of seconds until the rate limiting resets.","schema":{"minimum":0,"type":"integer","format":"int32"}}}}}},"paths":{"/api/v1/catalog/{callerTag}/dependencies/{calleeTag}":{"get":{"description":"If a dependency exists between the `callee` and the `caller`, returns metadata about the edge.","operationId":"getDependency","parameters":[{"in":"path","name":"callerTag","required":true,"schema":{"type":"string"}},{"in":"path","name":"calleeTag","required":true,"schema":{"type":"string"}},{"in":"query","name":"method","required":false,"schema":{"type":"string"}},{"in":"query","name":"path","required":false,"schema":{"type":"string"}}],"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DependencyResponse"}}},"description":"Successfully found dependency"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid endpoint"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Dependency not found"},"429":{"$ref":"#/components/responses/TooManyRequests"}},"summary":"Retrieve dependency between entities","tags":["Dependencies"]}}}}
```

## POST /api/v1/catalog/{callerTag}/dependencies/{calleeTag}

> Create dependency from entity

```json
{"openapi":"3.0.1","info":{"title":"Cortex API","version":"v1"},"tags":[{"name":"Dependencies"}],"servers":[{"url":"https://api.getcortexapp.com","description":"Cortex Cloud API host"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"bearerFormat":"JWT","description":"All requests to the Cortex API need to provide an `Authorization: Bearer <token>` header, where `<token>` is an API key created in the Settings page of your workspace.","scheme":"bearer","type":"http"}},"schemas":{"DependencyCreateRequest":{"type":"object","properties":{"description":{"type":"string"},"metadata":{"$ref":"#/components/schemas/JsonNode"}}},"JsonNode":{"type":"object"},"DependencyResponse":{"required":["calleeTag","calleeType","callerTag","callerType"],"type":"object","properties":{"calleeTag":{"type":"string","description":"Entity tag (x-cortex-tag) for the callee entity"},"calleeType":{"type":"string","description":"Type of the callee entity. Corresponds to the x-cortex-type field in the entity descriptor or ‘service’ for services."},"callerTag":{"type":"string","description":"Entity tag (x-cortex-tag) for the caller entity"},"callerType":{"type":"string","description":"Type of the caller entity. Corresponds to the x-cortex-type field in the entity descriptor or ‘service’ for services."},"description":{"type":"string"},"metadata":{"$ref":"#/components/schemas/JsonNode"},"method":{"type":"string","description":"Possible values: [GET, HEAD, POST, PUT, PATCH, DELETE, OPTIONS, TRACE]"},"path":{"type":"string"}}},"ErrorResponse":{"required":["message","type"],"type":"object","properties":{"details":{"type":"string"},"errorCode":{"type":"string"},"gatewayHttpStatus":{"type":"integer","format":"int32"},"httpStatus":{"type":"integer","format":"int32"},"message":{"type":"string"},"requestId":{"type":"string"},"type":{"type":"string","enum":["INTEGRATION_MISSING","INTEGRATION_UNREGISTERED","INTEGRATION_UNSUPPORTED","INTEGRATION_GRAPHQL_ERROR","INTEGRATION_BAD_REQUEST","INTEGRATION_UNAUTHORIZED","INTEGRATION_FORBIDDEN","INTEGRATION_NOT_FOUND","INTEGRATION_UNPROCESSABLE_CONTENT","INTEGRATION_RATE_LIMITED","INTEGRATION_INTERNAL_ERROR","INTEGRATION_NOT_IMPLEMENTED","INTEGRATION_BAD_GATEWAY","INTEGRATION_UNAVAILABLE","INTEGRATION_GATEWAY_TIMEOUT","INTEGRATION_TIMED_OUT","INTEGRATION_CACHE_ERROR","INTEGRATION_UNHANDLED_HTTP_ERROR","INTEGRATION_UNHANDLED_EXCEPTION","INTEGRATION_UNEXPECTED_ERROR","ILLEGAL_ARGUMENT_ERROR","BAD_REQUEST","FORBIDDEN","NOT_FOUND","REQUEST_TIMEOUT","CONFLICT","UNHANDLED_EXCEPTION","UNCATEGORIZED","SERVICE_CREATOR","UNKNOWN_HOST","TOO_MANY_REQUESTS"]}}},"TooManyRequestsProblemDetail":{"required":["type","title","status"],"type":"object","properties":{"detail":{"type":"string"},"instance":{"type":"string","format":"uri-reference"},"retryAfter":{"minimum":0,"type":"integer","description":"The number of seconds until the rate limiting resets.","format":"int32"},"status":{"maximum":599,"minimum":100,"type":"integer","format":"int32","enum":[429]},"title":{"type":"string"},"type":{"type":"string","format":"uri-reference"}}}},"responses":{"TooManyRequests":{"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsProblemDetail"}}},"description":"The client has exceeded the rate limit by performing too many requests in a short period. Retry the request after a delay.","headers":{"Retry-After":{"description":"The number of seconds until the rate limiting resets.","schema":{"minimum":0,"type":"integer","format":"int32"}}}}}},"paths":{"/api/v1/catalog/{callerTag}/dependencies/{calleeTag}":{"post":{"operationId":"createDependency","parameters":[{"description":"The entity tag (x-cortex-tag) for the callee entity (\"from\" entity)","in":"path","name":"callerTag","required":true,"schema":{"type":"string"}},{"description":"The entity tag (x-cortex-tag) for the caller entity (\"to\" entity)","in":"path","name":"calleeTag","required":true,"schema":{"type":"string"}},{"description":"HTTP Method","in":"query","name":"method","required":false,"schema":{"type":"string"}},{"in":"query","name":"path","required":false,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DependencyCreateRequest"}}},"required":true},"responses":{"201":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DependencyResponse"}}},"description":"Successfully created dependency"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid endpoint"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Entity not found"},"429":{"$ref":"#/components/responses/TooManyRequests"}},"summary":"Create dependency from entity","tags":["Dependencies"]}}}}
```

## Create or update dependencies in bulk

> This API allows you to create multiple dependencies for multiple entities at once.

```json
{"openapi":"3.0.1","info":{"title":"Cortex API","version":"v1"},"tags":[{"name":"Dependencies"}],"servers":[{"url":"https://api.getcortexapp.com","description":"Cortex Cloud API host"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"bearerFormat":"JWT","description":"All requests to the Cortex API need to provide an `Authorization: Bearer <token>` header, where `<token>` is an API key created in the Settings page of your workspace.","scheme":"bearer","type":"http"}},"schemas":{"BulkDependencyRequest":{"required":["values"],"type":"object","properties":{"values":{"type":"object","additionalProperties":{"type":"array","description":"Map of `caller` service to dependencies","items":{"$ref":"#/components/schemas/BulkDependencyInnerRequest"}},"description":"Map of `caller` service to dependencies"}}},"BulkDependencyInnerRequest":{"required":["tag"],"type":"object","properties":{"description":{"type":"string"},"metadata":{"$ref":"#/components/schemas/JsonNode"},"method":{"type":"string"},"path":{"type":"string"},"tag":{"type":"string","description":"Entity tag (`x-cortex-tag`) for the `callee`"}},"description":"Map of `caller` service to dependencies"},"JsonNode":{"type":"object"},"BulkDependencyResponse":{"required":["values"],"type":"object","properties":{"values":{"type":"object","additionalProperties":{"type":"array","description":"Map of `caller` service to dependencies","items":{"$ref":"#/components/schemas/BulkDependencyInnerResponse"}},"description":"Map of `caller` service to dependencies"}}},"BulkDependencyInnerResponse":{"required":["tag"],"type":"object","properties":{"description":{"type":"string"},"metadata":{"$ref":"#/components/schemas/JsonNode"},"method":{"$ref":"#/components/schemas/HttpMethod"},"path":{"type":"string"},"tag":{"type":"string","description":"Entity tag (`x-cortex-tag`) for the `callee`"}},"description":"Map of `caller` service to dependencies"},"HttpMethod":{"type":"object"},"ErrorResponse":{"required":["message","type"],"type":"object","properties":{"details":{"type":"string"},"errorCode":{"type":"string"},"gatewayHttpStatus":{"type":"integer","format":"int32"},"httpStatus":{"type":"integer","format":"int32"},"message":{"type":"string"},"requestId":{"type":"string"},"type":{"type":"string","enum":["INTEGRATION_MISSING","INTEGRATION_UNREGISTERED","INTEGRATION_UNSUPPORTED","INTEGRATION_GRAPHQL_ERROR","INTEGRATION_BAD_REQUEST","INTEGRATION_UNAUTHORIZED","INTEGRATION_FORBIDDEN","INTEGRATION_NOT_FOUND","INTEGRATION_UNPROCESSABLE_CONTENT","INTEGRATION_RATE_LIMITED","INTEGRATION_INTERNAL_ERROR","INTEGRATION_NOT_IMPLEMENTED","INTEGRATION_BAD_GATEWAY","INTEGRATION_UNAVAILABLE","INTEGRATION_GATEWAY_TIMEOUT","INTEGRATION_TIMED_OUT","INTEGRATION_CACHE_ERROR","INTEGRATION_UNHANDLED_HTTP_ERROR","INTEGRATION_UNHANDLED_EXCEPTION","INTEGRATION_UNEXPECTED_ERROR","ILLEGAL_ARGUMENT_ERROR","BAD_REQUEST","FORBIDDEN","NOT_FOUND","REQUEST_TIMEOUT","CONFLICT","UNHANDLED_EXCEPTION","UNCATEGORIZED","SERVICE_CREATOR","UNKNOWN_HOST","TOO_MANY_REQUESTS"]}}},"TooManyRequestsProblemDetail":{"required":["type","title","status"],"type":"object","properties":{"detail":{"type":"string"},"instance":{"type":"string","format":"uri-reference"},"retryAfter":{"minimum":0,"type":"integer","description":"The number of seconds until the rate limiting resets.","format":"int32"},"status":{"maximum":599,"minimum":100,"type":"integer","format":"int32","enum":[429]},"title":{"type":"string"},"type":{"type":"string","format":"uri-reference"}}}},"responses":{"TooManyRequests":{"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsProblemDetail"}}},"description":"The client has exceeded the rate limit by performing too many requests in a short period. Retry the request after a delay.","headers":{"Retry-After":{"description":"The number of seconds until the rate limiting resets.","schema":{"minimum":0,"type":"integer","format":"int32"}}}}}},"paths":{"/api/v1/catalog/dependencies":{"put":{"description":"This API allows you to create multiple dependencies for multiple entities at once.","operationId":"createOrUpdateDependenciesInBulk","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkDependencyRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkDependencyResponse"}}},"description":"Successfully created / updated dependencies"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Cannot modify dependency that is defined in cortex.yaml"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Entity not found"},"429":{"$ref":"#/components/responses/TooManyRequests"}},"summary":"Create or update dependencies in bulk","tags":["Dependencies"]}}}}
```

## Update dependency between entities

> If a dependency exists between two entities, replace the metadata with the payload. \
> Note: This only supports dependencies created via the API.

```json
{"openapi":"3.0.1","info":{"title":"Cortex API","version":"v1"},"tags":[{"name":"Dependencies"}],"servers":[{"url":"https://api.getcortexapp.com","description":"Cortex Cloud API host"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"bearerFormat":"JWT","description":"All requests to the Cortex API need to provide an `Authorization: Bearer <token>` header, where `<token>` is an API key created in the Settings page of your workspace.","scheme":"bearer","type":"http"}},"schemas":{"DependencyUpdateRequest":{"required":["description","metadata"],"type":"object","properties":{"description":{"type":"string"},"metadata":{"$ref":"#/components/schemas/JsonNode"}}},"JsonNode":{"type":"object"},"DependencyResponse":{"required":["calleeTag","calleeType","callerTag","callerType"],"type":"object","properties":{"calleeTag":{"type":"string","description":"Entity tag (x-cortex-tag) for the callee entity"},"calleeType":{"type":"string","description":"Type of the callee entity. Corresponds to the x-cortex-type field in the entity descriptor or ‘service’ for services."},"callerTag":{"type":"string","description":"Entity tag (x-cortex-tag) for the caller entity"},"callerType":{"type":"string","description":"Type of the caller entity. Corresponds to the x-cortex-type field in the entity descriptor or ‘service’ for services."},"description":{"type":"string"},"metadata":{"$ref":"#/components/schemas/JsonNode"},"method":{"type":"string","description":"Possible values: [GET, HEAD, POST, PUT, PATCH, DELETE, OPTIONS, TRACE]"},"path":{"type":"string"}}},"ErrorResponse":{"required":["message","type"],"type":"object","properties":{"details":{"type":"string"},"errorCode":{"type":"string"},"gatewayHttpStatus":{"type":"integer","format":"int32"},"httpStatus":{"type":"integer","format":"int32"},"message":{"type":"string"},"requestId":{"type":"string"},"type":{"type":"string","enum":["INTEGRATION_MISSING","INTEGRATION_UNREGISTERED","INTEGRATION_UNSUPPORTED","INTEGRATION_GRAPHQL_ERROR","INTEGRATION_BAD_REQUEST","INTEGRATION_UNAUTHORIZED","INTEGRATION_FORBIDDEN","INTEGRATION_NOT_FOUND","INTEGRATION_UNPROCESSABLE_CONTENT","INTEGRATION_RATE_LIMITED","INTEGRATION_INTERNAL_ERROR","INTEGRATION_NOT_IMPLEMENTED","INTEGRATION_BAD_GATEWAY","INTEGRATION_UNAVAILABLE","INTEGRATION_GATEWAY_TIMEOUT","INTEGRATION_TIMED_OUT","INTEGRATION_CACHE_ERROR","INTEGRATION_UNHANDLED_HTTP_ERROR","INTEGRATION_UNHANDLED_EXCEPTION","INTEGRATION_UNEXPECTED_ERROR","ILLEGAL_ARGUMENT_ERROR","BAD_REQUEST","FORBIDDEN","NOT_FOUND","REQUEST_TIMEOUT","CONFLICT","UNHANDLED_EXCEPTION","UNCATEGORIZED","SERVICE_CREATOR","UNKNOWN_HOST","TOO_MANY_REQUESTS"]}}},"TooManyRequestsProblemDetail":{"required":["type","title","status"],"type":"object","properties":{"detail":{"type":"string"},"instance":{"type":"string","format":"uri-reference"},"retryAfter":{"minimum":0,"type":"integer","description":"The number of seconds until the rate limiting resets.","format":"int32"},"status":{"maximum":599,"minimum":100,"type":"integer","format":"int32","enum":[429]},"title":{"type":"string"},"type":{"type":"string","format":"uri-reference"}}}},"responses":{"TooManyRequests":{"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsProblemDetail"}}},"description":"The client has exceeded the rate limit by performing too many requests in a short period. Retry the request after a delay.","headers":{"Retry-After":{"description":"The number of seconds until the rate limiting resets.","schema":{"minimum":0,"type":"integer","format":"int32"}}}}}},"paths":{"/api/v1/catalog/{callerTag}/dependencies/{calleeTag}":{"put":{"description":"If a dependency exists between two entities, replace the metadata with the payload. \nNote: This only supports dependencies created via the API.","operationId":"updateDependency","parameters":[{"in":"path","name":"callerTag","required":true,"schema":{"type":"string"}},{"in":"path","name":"calleeTag","required":true,"schema":{"type":"string"}},{"in":"query","name":"method","required":false,"schema":{"type":"string"}},{"in":"query","name":"path","required":false,"schema":{"type":"string"}}],"requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DependencyUpdateRequest"}}},"required":true},"responses":{"200":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DependencyResponse"}}},"description":"Successfully updated dependency"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid endpoint"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Entity not found"},"429":{"$ref":"#/components/responses/TooManyRequests"}},"summary":"Update dependency between entities","tags":["Dependencies"]}}}}
```

## Delete dependency

> Deletes a single dependency edge between the \`caller\` and the \`callee\`. \
> Note: This is only supported for edges created via the API.

```json
{"openapi":"3.0.1","info":{"title":"Cortex API","version":"v1"},"tags":[{"name":"Dependencies"}],"servers":[{"url":"https://api.getcortexapp.com","description":"Cortex Cloud API host"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"bearerFormat":"JWT","description":"All requests to the Cortex API need to provide an `Authorization: Bearer <token>` header, where `<token>` is an API key created in the Settings page of your workspace.","scheme":"bearer","type":"http"}},"schemas":{"DependencyResponse":{"required":["calleeTag","calleeType","callerTag","callerType"],"type":"object","properties":{"calleeTag":{"type":"string","description":"Entity tag (x-cortex-tag) for the callee entity"},"calleeType":{"type":"string","description":"Type of the callee entity. Corresponds to the x-cortex-type field in the entity descriptor or ‘service’ for services."},"callerTag":{"type":"string","description":"Entity tag (x-cortex-tag) for the caller entity"},"callerType":{"type":"string","description":"Type of the caller entity. Corresponds to the x-cortex-type field in the entity descriptor or ‘service’ for services."},"description":{"type":"string"},"metadata":{"$ref":"#/components/schemas/JsonNode"},"method":{"type":"string","description":"Possible values: [GET, HEAD, POST, PUT, PATCH, DELETE, OPTIONS, TRACE]"},"path":{"type":"string"}}},"JsonNode":{"type":"object"},"ErrorResponse":{"required":["message","type"],"type":"object","properties":{"details":{"type":"string"},"errorCode":{"type":"string"},"gatewayHttpStatus":{"type":"integer","format":"int32"},"httpStatus":{"type":"integer","format":"int32"},"message":{"type":"string"},"requestId":{"type":"string"},"type":{"type":"string","enum":["INTEGRATION_MISSING","INTEGRATION_UNREGISTERED","INTEGRATION_UNSUPPORTED","INTEGRATION_GRAPHQL_ERROR","INTEGRATION_BAD_REQUEST","INTEGRATION_UNAUTHORIZED","INTEGRATION_FORBIDDEN","INTEGRATION_NOT_FOUND","INTEGRATION_UNPROCESSABLE_CONTENT","INTEGRATION_RATE_LIMITED","INTEGRATION_INTERNAL_ERROR","INTEGRATION_NOT_IMPLEMENTED","INTEGRATION_BAD_GATEWAY","INTEGRATION_UNAVAILABLE","INTEGRATION_GATEWAY_TIMEOUT","INTEGRATION_TIMED_OUT","INTEGRATION_CACHE_ERROR","INTEGRATION_UNHANDLED_HTTP_ERROR","INTEGRATION_UNHANDLED_EXCEPTION","INTEGRATION_UNEXPECTED_ERROR","ILLEGAL_ARGUMENT_ERROR","BAD_REQUEST","FORBIDDEN","NOT_FOUND","REQUEST_TIMEOUT","CONFLICT","UNHANDLED_EXCEPTION","UNCATEGORIZED","SERVICE_CREATOR","UNKNOWN_HOST","TOO_MANY_REQUESTS"]}}},"TooManyRequestsProblemDetail":{"required":["type","title","status"],"type":"object","properties":{"detail":{"type":"string"},"instance":{"type":"string","format":"uri-reference"},"retryAfter":{"minimum":0,"type":"integer","description":"The number of seconds until the rate limiting resets.","format":"int32"},"status":{"maximum":599,"minimum":100,"type":"integer","format":"int32","enum":[429]},"title":{"type":"string"},"type":{"type":"string","format":"uri-reference"}}}},"responses":{"TooManyRequests":{"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsProblemDetail"}}},"description":"The client has exceeded the rate limit by performing too many requests in a short period. Retry the request after a delay.","headers":{"Retry-After":{"description":"The number of seconds until the rate limiting resets.","schema":{"minimum":0,"type":"integer","format":"int32"}}}}}},"paths":{"/api/v1/catalog/{callerTag}/dependencies/{calleeTag}":{"delete":{"description":"Deletes a single dependency edge between the `caller` and the `callee`. \nNote: This is only supported for edges created via the API.","operationId":"deleteDependency","parameters":[{"in":"path","name":"callerTag","required":true,"schema":{"type":"string"}},{"in":"path","name":"calleeTag","required":true,"schema":{"type":"string"}},{"in":"query","name":"method","required":false,"schema":{"type":"string"}},{"in":"query","name":"path","required":false,"schema":{"type":"string"}}],"responses":{"204":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DependencyResponse"}}},"description":"Successfully deleted dependency"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Invalid endpoint"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Dependency not found"},"429":{"$ref":"#/components/responses/TooManyRequests"}},"summary":"Delete dependency","tags":["Dependencies"]}}}}
```

## Delete dependencies from entity

> Deletes any outgoing dependencies from the entity. Note: this only deletes dependencies that were created via the API.

```json
{"openapi":"3.0.1","info":{"title":"Cortex API","version":"v1"},"tags":[{"name":"Dependencies"}],"servers":[{"url":"https://api.getcortexapp.com","description":"Cortex Cloud API host"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"bearerFormat":"JWT","description":"All requests to the Cortex API need to provide an `Authorization: Bearer <token>` header, where `<token>` is an API key created in the Settings page of your workspace.","scheme":"bearer","type":"http"}},"schemas":{"DependencyResponse":{"required":["calleeTag","calleeType","callerTag","callerType"],"type":"object","properties":{"calleeTag":{"type":"string","description":"Entity tag (x-cortex-tag) for the callee entity"},"calleeType":{"type":"string","description":"Type of the callee entity. Corresponds to the x-cortex-type field in the entity descriptor or ‘service’ for services."},"callerTag":{"type":"string","description":"Entity tag (x-cortex-tag) for the caller entity"},"callerType":{"type":"string","description":"Type of the caller entity. Corresponds to the x-cortex-type field in the entity descriptor or ‘service’ for services."},"description":{"type":"string"},"metadata":{"$ref":"#/components/schemas/JsonNode"},"method":{"type":"string","description":"Possible values: [GET, HEAD, POST, PUT, PATCH, DELETE, OPTIONS, TRACE]"},"path":{"type":"string"}}},"JsonNode":{"type":"object"},"ErrorResponse":{"required":["message","type"],"type":"object","properties":{"details":{"type":"string"},"errorCode":{"type":"string"},"gatewayHttpStatus":{"type":"integer","format":"int32"},"httpStatus":{"type":"integer","format":"int32"},"message":{"type":"string"},"requestId":{"type":"string"},"type":{"type":"string","enum":["INTEGRATION_MISSING","INTEGRATION_UNREGISTERED","INTEGRATION_UNSUPPORTED","INTEGRATION_GRAPHQL_ERROR","INTEGRATION_BAD_REQUEST","INTEGRATION_UNAUTHORIZED","INTEGRATION_FORBIDDEN","INTEGRATION_NOT_FOUND","INTEGRATION_UNPROCESSABLE_CONTENT","INTEGRATION_RATE_LIMITED","INTEGRATION_INTERNAL_ERROR","INTEGRATION_NOT_IMPLEMENTED","INTEGRATION_BAD_GATEWAY","INTEGRATION_UNAVAILABLE","INTEGRATION_GATEWAY_TIMEOUT","INTEGRATION_TIMED_OUT","INTEGRATION_CACHE_ERROR","INTEGRATION_UNHANDLED_HTTP_ERROR","INTEGRATION_UNHANDLED_EXCEPTION","INTEGRATION_UNEXPECTED_ERROR","ILLEGAL_ARGUMENT_ERROR","BAD_REQUEST","FORBIDDEN","NOT_FOUND","REQUEST_TIMEOUT","CONFLICT","UNHANDLED_EXCEPTION","UNCATEGORIZED","SERVICE_CREATOR","UNKNOWN_HOST","TOO_MANY_REQUESTS"]}}},"TooManyRequestsProblemDetail":{"required":["type","title","status"],"type":"object","properties":{"detail":{"type":"string"},"instance":{"type":"string","format":"uri-reference"},"retryAfter":{"minimum":0,"type":"integer","description":"The number of seconds until the rate limiting resets.","format":"int32"},"status":{"maximum":599,"minimum":100,"type":"integer","format":"int32","enum":[429]},"title":{"type":"string"},"type":{"type":"string","format":"uri-reference"}}}},"responses":{"TooManyRequests":{"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsProblemDetail"}}},"description":"The client has exceeded the rate limit by performing too many requests in a short period. Retry the request after a delay.","headers":{"Retry-After":{"description":"The number of seconds until the rate limiting resets.","schema":{"minimum":0,"type":"integer","format":"int32"}}}}}},"paths":{"/api/v1/catalog/{callerTag}/dependencies":{"delete":{"description":"Deletes any outgoing dependencies from the entity. Note: this only deletes dependencies that were created via the API.","operationId":"deleteDependenciesFromEntity","parameters":[{"in":"path","name":"callerTag","required":true,"schema":{"type":"string"}}],"responses":{"204":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DependencyResponse"}}},"description":"Successfully deleted dependencies"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Caller not found"},"429":{"$ref":"#/components/responses/TooManyRequests"}},"summary":"Delete dependencies from entity","tags":["Dependencies"]}}}}
```

## DELETE /api/v1/catalog/dependencies

> Delete dependencies in bulk

```json
{"openapi":"3.0.1","info":{"title":"Cortex API","version":"v1"},"tags":[{"name":"Dependencies"}],"servers":[{"url":"https://api.getcortexapp.com","description":"Cortex Cloud API host"}],"security":[{"bearerAuth":[]}],"components":{"securitySchemes":{"bearerAuth":{"bearerFormat":"JWT","description":"All requests to the Cortex API need to provide an `Authorization: Bearer <token>` header, where `<token>` is an API key created in the Settings page of your workspace.","scheme":"bearer","type":"http"}},"schemas":{"BulkDependencyRequest":{"required":["values"],"type":"object","properties":{"values":{"type":"object","additionalProperties":{"type":"array","description":"Map of `caller` service to dependencies","items":{"$ref":"#/components/schemas/BulkDependencyInnerRequest"}},"description":"Map of `caller` service to dependencies"}}},"BulkDependencyInnerRequest":{"required":["tag"],"type":"object","properties":{"description":{"type":"string"},"metadata":{"$ref":"#/components/schemas/JsonNode"},"method":{"type":"string"},"path":{"type":"string"},"tag":{"type":"string","description":"Entity tag (`x-cortex-tag`) for the `callee`"}},"description":"Map of `caller` service to dependencies"},"JsonNode":{"type":"object"},"ErrorResponse":{"required":["message","type"],"type":"object","properties":{"details":{"type":"string"},"errorCode":{"type":"string"},"gatewayHttpStatus":{"type":"integer","format":"int32"},"httpStatus":{"type":"integer","format":"int32"},"message":{"type":"string"},"requestId":{"type":"string"},"type":{"type":"string","enum":["INTEGRATION_MISSING","INTEGRATION_UNREGISTERED","INTEGRATION_UNSUPPORTED","INTEGRATION_GRAPHQL_ERROR","INTEGRATION_BAD_REQUEST","INTEGRATION_UNAUTHORIZED","INTEGRATION_FORBIDDEN","INTEGRATION_NOT_FOUND","INTEGRATION_UNPROCESSABLE_CONTENT","INTEGRATION_RATE_LIMITED","INTEGRATION_INTERNAL_ERROR","INTEGRATION_NOT_IMPLEMENTED","INTEGRATION_BAD_GATEWAY","INTEGRATION_UNAVAILABLE","INTEGRATION_GATEWAY_TIMEOUT","INTEGRATION_TIMED_OUT","INTEGRATION_CACHE_ERROR","INTEGRATION_UNHANDLED_HTTP_ERROR","INTEGRATION_UNHANDLED_EXCEPTION","INTEGRATION_UNEXPECTED_ERROR","ILLEGAL_ARGUMENT_ERROR","BAD_REQUEST","FORBIDDEN","NOT_FOUND","REQUEST_TIMEOUT","CONFLICT","UNHANDLED_EXCEPTION","UNCATEGORIZED","SERVICE_CREATOR","UNKNOWN_HOST","TOO_MANY_REQUESTS"]}}},"TooManyRequestsProblemDetail":{"required":["type","title","status"],"type":"object","properties":{"detail":{"type":"string"},"instance":{"type":"string","format":"uri-reference"},"retryAfter":{"minimum":0,"type":"integer","description":"The number of seconds until the rate limiting resets.","format":"int32"},"status":{"maximum":599,"minimum":100,"type":"integer","format":"int32","enum":[429]},"title":{"type":"string"},"type":{"type":"string","format":"uri-reference"}}}},"responses":{"TooManyRequests":{"content":{"application/problem+json":{"schema":{"$ref":"#/components/schemas/TooManyRequestsProblemDetail"}}},"description":"The client has exceeded the rate limit by performing too many requests in a short period. Retry the request after a delay.","headers":{"Retry-After":{"description":"The number of seconds until the rate limiting resets.","schema":{"minimum":0,"type":"integer","format":"int32"}}}}}},"paths":{"/api/v1/catalog/dependencies":{"delete":{"operationId":"deleteDependenciesInBulk","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BulkDependencyRequest"}}},"required":true},"responses":{"204":{"description":"Successfully deleted dependencies"},"400":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Cannot modify dependency that is defined in cortex.yaml"},"404":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ErrorResponse"}}},"description":"Entity not found"},"429":{"$ref":"#/components/responses/TooManyRequests"}},"summary":"Delete dependencies in bulk","tags":["Dependencies"]}}}}
```
