BREAGEN Logo
Entity Management

Graph API Documentation

Overview

The Graph API Service provides endpoints for generating and managing organizational graphs, shareholder relationships, and Visual Link Analysis (VLA) functionality.

Endpoints

1. Shareholder Graph Creation

Initiate the process of creating a shareholder graph.

Endpoint: /v1/api/graph/shareholder
Method: POST
Content-Type: application/json

API Details

Resource URL/v1/api/graph/shareholder
Response FormatJSON
Requires AuthenticationYes
Rate LimitedYes
HTTPSYes

Request Body Parameters

ParameterTypeRequiredDescription
linkstringYesLink to the source data
source_namestringYesName of the source
entity_idstringYesUnique identifier for the entity
client_idstringYesClient identifier
levelsintegerYesNumber of levels to analyze
min_indirect_percentageintegerYesMinimum indirect percentage threshold
max_indirect_percentageintegerYesMaximum indirect percentage threshold
usernamestringYesUsername of the requester
session_idstringYesSession identifier

Example Request

curl -X 'POST' \
  'https://your-api-domain.com/v1/api/graph/shareholder' \
  -H 'accept: application/json' \
  -H 'Content-Type: application/json' \
  -d '{
    "link": "https://braegen.ai/data",
    "source_name": "Company Registry",
    "entity_id": "ENT123",
    "client_id": "CLIENT456",
    "levels": 3,
    "min_indirect_percentage": 10,
    "max_indirect_percentage": 100,
    "username": "john.doe",
    "session_id": "SESSION789"
  }'

2. Generated Graph Retrieval

Retrieve a generated graph using its request ID.

Endpoint: /v1/api/graphshareholder/{request_id}
Method: GET

API Details

Resource URL/v1/api/graphshareholder/{request_id}
Response FormatJSON
Requires AuthenticationYes
Rate LimitedYes
HTTPSYes

Path Parameters

ParameterTypeRequiredDescription
request_idstringYesUnique identifier of the graph request

3. VLA CSV Upload

Upload a CSV file for Visual Link Analysis.

Endpoint: /v1/api/vla/upload_csv
Method: POST
Content-Type: multipart/form-data

API Details

Resource URL/v1/api/vla/upload_csv
Response FormatJSON
Requires AuthenticationYes
Rate LimitedYes
HTTPSYes

Parameters

ParameterTypeLocationRequiredDescription
graph_namestringqueryYesName of the graph
filebinaryform-dataYesCSV file to upload

Example Request

curl -X 'POST' \
  'https://your-api-domain.com/v1/api/vla/upload_csv?graph_name=my_graph' \
  -H 'accept: application/json' \
  -H 'Content-Type: multipart/form-data' \
  -F '[email protected]'

4. Graph Type Retrieval

Get information about a specific graph type.

Endpoint: /v1/api/vla/graph_type
Method: GET

API Details

Resource URL/v1/api/vla/graph_type
Response FormatJSON
Requires AuthenticationYes
Rate LimitedYes
HTTPSYes

Query Parameters

ParameterTypeRequiredDescription
graph_idstringYesUnique identifier of the graph
graph_typestringYesType of the graph

Error Responses

Validation Error Response

{
	"detail": [
		{
			"loc": ["field_name"],
			"msg": "error message",
			"type": "error_type"
		}
	]
}

Response Codes

Status CodeDescription
200Successful operation
422Validation Error

Notes

  • File uploads must be in CSV format for VLA functionality
  • Graph levels should be specified as positive integers
  • Percentage thresholds should be between 0 and 100
  • Authentication details should be specified by the implementation
  • Rate limiting details should be specified by the implementation
  • Session IDs should be maintained throughout the graph generation process

On this page