TokenisttTokenistt
PricingResourcesBlogDocsLegalAbout UsCareers
private beta · limited accessSign inStart free →
PricingResourcesBlogDocumentationLegalAbout UsCareers
Start free →Sign in
DocsAPI Reference
← Back
Getting Started
MCP Server
Integrations
Features
Reference

API Reference

The Tokenistt REST API lets you query usage data, configure workspaces, and receive webhooks — programmatically.

Base URL

https://api.tokenistt.com/v1

Authentication

# All requests require Bearer token
Authorization: Bearer <your-api-key>

Endpoints

GET /workspacesList all workspaces
GET /workspaces/:id/usageToken + spend stats for a workspace
GET /workspaces/:id/eventsRecent token events (paginated)
POST /workspaces/:id/policySet spend cap and alert config
GET /models/routingLive model routing distribution
GET /cache/reportCache hit rates and miss analysis
POST /optimizeAnalyze a prompt string (returns score + suggestions)

Example: query workspace spend

curl https://api.tokenistt.com/v1/workspaces/agents-platform/usage \
  -H "Authorization: Bearer tok_..." \
  -H "Content-Type: application/json"

# Response
{
  "workspace": "agents-platform",
  "period": "2026-06-01/2026-06-03",
  "tokens_in": 4820000,
  "tokens_out": 1230000,
  "spend_usd": 124.40,
  "savings_usd": 52.18,
  "cache_hit_rate": 0.34,
  "requests": 8_420
}