A valid request URL is required to generate request examples{
"relations": [],
"success": true,
"message": "Relations retrieved successfully"
}{
"detail": {
"success": true,
"message": "Error occurred",
"error_code": "<string>"
}
}{
"detail": {
"success": true,
"message": "Error occurred",
"error_code": "<string>"
}
}{
"detail": {
"success": true,
"message": "Error occurred",
"error_code": "<string>"
}
}{
"detail": {
"success": true,
"message": "Error occurred",
"error_code": "<string>"
}
}{
"detail": {
"success": true,
"message": "Error occurred",
"error_code": "<string>"
}
}{
"detail": {
"success": true,
"message": "Error occurred",
"error_code": "<string>"
}
}{
"detail": {
"success": true,
"message": "Error occurred",
"error_code": "<string>"
}
}Graph Relations By Source Id
Retrieve relations for a specific source.
Use this endpoint to fetch all relations associated with a specific source. This is useful when you need to understand the relationships between entities within a source.
Provide the source ID in the request body along with your tenant information to get the relations for that source.
A valid request URL is required to generate request examples{
"relations": [],
"success": true,
"message": "Relations retrieved successfully"
}{
"detail": {
"success": true,
"message": "Error occurred",
"error_code": "<string>"
}
}{
"detail": {
"success": true,
"message": "Error occurred",
"error_code": "<string>"
}
}{
"detail": {
"success": true,
"message": "Error occurred",
"error_code": "<string>"
}
}{
"detail": {
"success": true,
"message": "Error occurred",
"error_code": "<string>"
}
}{
"detail": {
"success": true,
"message": "Error occurred",
"error_code": "<string>"
}
}{
"detail": {
"success": true,
"message": "Error occurred",
"error_code": "<string>"
}
}{
"detail": {
"success": true,
"message": "Error occurred",
"error_code": "<string>"
}
}Try it button to try this API now in our playground. It’s the best way to check the full request and response in one place, customize your parameters, and generate ready-to-use code snippets.Examples
- API Request
- TypeScript
- Python (Sync)
curl -X 'GET' \
'https://api.usecortex.ai/list/graph-relations-by-id?source_id=source-123' \
-H 'accept: application/json'
const relations = await client.sources.getGraphRelations({
tenant_id: "tenant_1234",
source_id: "source_1234",
sub_tenant_id: "sub_tenant_4567"
});
# Async usage is similar, just use async_client and await
relations = client.sources.get_graph_relations(
tenant_id="tenant_1234",
source_id="source_1234",
sub_tenant_id="sub_tenant_4567"
)
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Query Parameters
The source ID to fetch relations for
"CortexDoc1234"
Unique identifier for the tenant/organization
"tenant_1234"
Optional sub-tenant identifier used to organize data within a tenant. If omitted, the default sub-tenant created during tenant setup will be used.
"sub_tenant_4567"
Response
Successful Response
List of relations retrieved
Triple with multiple evidence items from different chunks
Show child attributes
Show child attributes
[]
Indicates whether the request was successful
true
Response message describing the operation result