Overview
The Neode API allows you to programmatically store, query, and generate knowledge triples. Use it to build LLM memory systems, research tools, or any application that needs structured knowledge.
Base URL
For local development:
http://localhost:5173/api
Authentication
All API requests require authentication using a Bearer token or API key.
Bearer Token
Include your API key in the Authorization header:
curl https://neode.ai/api/triples \
-H "Authorization: Bearer YOUR_API_KEY"
Getting an API Key
Sign in to your Neode dashboard
Go to Settings → API Keys
Create a new API key
Copy and securely store your key
Keep your API key secret. Don’t commit it to version control or expose it in client-side code.
All POST/PUT requests should use JSON:
curl -X POST https://neode.ai/api/triples \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{"subject": "Tesla", "predicate": "founded_by", "object": "Elon Musk"}'
All responses return JSON with a consistent structure:
Success Response
{
"success" : true ,
"data" : { ... },
"count" : 10
}
Error Response
{
"success" : false ,
"error" : "Error message" ,
"details" : "Additional context"
}
HTTP Status Codes
Code Description 200Success 400Bad request - invalid parameters 401Unauthorized - invalid or missing API key 402Payment required - insufficient credits 404Not found - resource doesn’t exist 500Server error
Rate Limits
Standard : 100 requests per minute
Generation : 10 requests per minute (AI endpoints)
Rate limit headers are included in responses:
X-RateLimit-Limit: 100
X-RateLimit-Remaining: 95
X-RateLimit-Reset: 1706400000
Credits
AI generation endpoints consume credits:
Operation Credits Generate triples (without web search) 2¢ Generate triples (with web search) 5¢ Generate entity description 1¢
Check your balance at Settings → Billing .
When credits are insufficient, you’ll receive a 402 response:
{
"success" : false ,
"error" : "Insufficient credits" ,
"balance_cents" : 5 ,
"required_cents" : 10 ,
"buy_credits_url" : "https://neode.ai/dashboard/settings/billing"
}
API Endpoints
Triples Store and query knowledge facts
Entities Manage entities in your knowledge graph
Graphs Organize triples into graphs
Indexes Create and manage indexes
Generation AI-powered triple extraction
Embeddings Generate vector embeddings
SDKs and Libraries
Official SDKs coming soon. For now, use the REST API directly or with any HTTP client.
Example with fetch (JavaScript)
const neode = {
baseUrl: 'https://neode.ai/api' ,
apiKey: 'YOUR_API_KEY' ,
async request ( endpoint , options = {}) {
const response = await fetch ( ` ${ this . baseUrl }${ endpoint } ` , {
... options ,
headers: {
'Content-Type' : 'application/json' ,
'Authorization' : `Bearer ${ this . apiKey } ` ,
... options . headers
}
});
return response . json ();
},
async createTriple ( triple ) {
return this . request ( '/triples' , {
method: 'POST' ,
body: JSON . stringify ( triple )
});
},
async queryTriples ( params ) {
const query = new URLSearchParams ( params ). toString ();
return this . request ( `/triples? ${ query } ` );
}
};
Example with requests (Python)
import requests
class Neode :
def __init__ ( self , api_key ):
self .base_url = 'https://neode.ai/api'
self .headers = {
'Content-Type' : 'application/json' ,
'Authorization' : f 'Bearer { api_key } '
}
def create_triple ( self , triple ):
response = requests.post(
f ' { self .base_url } /triples' ,
headers = self .headers,
json = triple
)
return response.json()
def query_triples ( self , ** params ):
response = requests.get(
f ' { self .base_url } /triples' ,
headers = self .headers,
params = params
)
return response.json()
# Usage
neode = Neode( 'YOUR_API_KEY' )
result = neode.create_triple({
'subject' : 'Tesla' ,
'predicate' : 'founded_by' ,
'object' : 'Elon Musk' ,
'object_type' : 'entity' ,
'index_id' : 'YOUR_INDEX_ID'
})