API Documentation

Everything you need to integrate with PlanetGraph.

Authentication

All API requests require a Bearer token. Create an API key in your account settings and include it in the Authorization header.

curl -H "Authorization: Bearer YOUR_API_KEY" \
  https://planetgraph-api-570613127242.us-central1.run.app/api/v1/nodes

Nodes

Create, read, update, and delete graph nodes.

GET/api/v1/nodes

List all nodes with optional filtering by type, owner, status

POST/api/v1/nodes

Create a new node with a specified type

GET/api/v1/nodes/{id}

Get a single node by ID including properties and edges

PATCH/api/v1/nodes/{id}

Update a node type or status

DELETE/api/v1/nodes/{id}

Soft-delete a node (owner only)

Edges

Create and manage relationships between nodes.

GET/api/v1/edges

List edges with optional filtering

POST/api/v1/edges

Create a directed edge between two nodes

GET/api/v1/edges/{id}

Get a single edge by ID

DELETE/api/v1/edges/{id}

Delete an edge (owner only)

Properties

Manage properties on nodes and edges with granular access controls.

GET/api/v1/nodes/{id}/properties

List properties on a node with access-level info

POST/api/v1/nodes/{id}/properties

Add a property to a node

PATCH/api/v1/properties/{id}

Update a property value

DELETE/api/v1/properties/{id}

Delete a property (owner only)

POST/api/v1/properties/{id}/purchase

Purchase access to a locked property

Billing

Manage your token balance and view transaction history.

GET/api/v1/billing/balance

Get current token balance

POST/api/v1/billing/purchase

Purchase tokens

GET/api/v1/billing/transactions

List transaction history

Access Control

Define and manage access policies for your data.

GET/api/v1/access-policies

List your access policies

POST/api/v1/access-policies

Create a new access policy with pricing rules

PATCH/api/v1/access-policies/{id}

Update an access policy

DELETE/api/v1/access-policies/{id}

Delete an access policy

Queries

Execute Cypher queries and access query history.

POST/api/v1/query

Execute a Cypher query and return results

GET/api/v1/queries/history

Get your query execution history