API Endpoints¶
Common API endpoints and example usage.
Nodes¶
List Nodes¶
GET /api/nodes
Optional query parameters:
- type — Filter by node type
- limit — Number of results (default: 100)
- offset — Pagination offset
Get Node¶
GET /api/nodes/{node_id}
Create Node¶
POST /api/nodes
Content-Type: application/json
{
"type": "project",
"properties": {
"title": "My Project",
"description": "Project description"
}
}
Update Node¶
PUT /api/nodes/{node_id}
Content-Type: application/json
{
"properties": {
"title": "Updated Title"
}
}
Delete Node¶
DELETE /api/nodes/{node_id}
Edges¶
List Edges¶
GET /api/edges
Create Edge¶
POST /api/edges
Content-Type: application/json
{
"type": "collaborates",
"source_id": "{node_id_1}",
"target_id": "{node_id_2}",
"properties": {
"description": "How they collaborate"
}
}
Authentication¶
Login¶
POST /api/auth/login
Content-Type: application/json
{
"username": "user",
"password": "password"
}
Response includes access_token.
Using Token¶
Include in request header:
Authorization: Bearer {access_token}
Schema¶
Get Schema¶
GET /api/schema
Returns complete platform schema.
Node Types¶
GET /api/schema/nodes
Edge Types¶
GET /api/schema/edges
More Examples¶
For complete and interactive examples, visit the API documentation at:
http://localhost:8000/docs
(when backend is running)
See Authentication for API access details.