API Documentation

Everything you need to integrate with PlanetGraph.

Quick Start

Start with these prompts in your preferred coding agent, then iterate with follow-up questions.

Sign up to get your API key

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://api.planetgraph.ai/api/v1/nodes

Nodes

Create, read, update, and delete graph nodes.

GET/api/v1/nodes

List Nodes

POST/api/v1/nodes

Create Node

GET/api/v1/nodes/{node_id}

Get Node

PATCH/api/v1/nodes/{node_id}

Update Node

DELETE/api/v1/nodes/{node_id}

Delete Node

GET/api/v1/nodes/types

List Node Types

Edges

Create and manage relationships between nodes.

GET/api/v1/edges

List Edges

POST/api/v1/edges

Create Edge

GET/api/v1/edges/{edge_id}

Get Edge

PATCH/api/v1/edges/{edge_id}

Update Edge

DELETE/api/v1/edges/{edge_id}

Delete Edge

GET/api/v1/edges/by-node/{node_id}

List Edges For Node

Properties

Manage properties on nodes and edges with granular access controls.

POST/api/v1/admin/rotate-keys/{account_id}

Rotate Keys

GET/api/v1/edges/{edge_id}/properties

List Edge Properties

POST/api/v1/edges/{edge_id}/properties

Create Edge Property

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

List Node Properties

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

Create Node Property

PUT/api/v1/properties/{property_id}

Update Property

DELETE/api/v1/properties/{property_id}

Delete Property

Billing

Manage your token balance and view transaction history.

GET/api/v1/account/balance

Account Balance

POST/api/v1/account/purchase

Purchase Tokens

GET/api/v1/account/transactions

Account Transactions

POST/api/v1/admin/pricing

Create Pricing

GET/api/v1/pricing

Get Pricing

Access Control

Define and manage access policies for your data.

GET/api/v1/access-policies

List Access Policies

POST/api/v1/access-policies

Create Access Policy

PUT/api/v1/access-policies/{policy_id}

Update Access Policy

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

Delete Access Policy

PATCH/api/v1/feedback/{feedback_id}

Update Feedback

DELETE/api/v1/feedback/{feedback_id}

Delete Feedback

PATCH/api/v1/properties/{property_id}/access-policy

Assign Access Policy

GET/api/v1/properties/{property_id}/feedback

List Feedback

POST/api/v1/properties/{property_id}/feedback

Create Feedback

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

Purchase Property Access

Queries

Execute Cypher queries and access query history.

GET/api/v1/queries/history

Query History

POST/api/v1/query

Run Query