API Documentation

Everything you need to integrate CraftAI into your stack

Preview Documentation

The API is under active development. Endpoints below represent the planned specification.

Authentication

All requests require a Bearer token in the Authorization header:

Authorization: Bearer YOUR_API_KEY

Generate API keys from your CraftAI dashboard after account creation.

Workflows API

Create, execute, and monitor automated workflows.

Create Workflow

POST https://api.craftaiplatform.com/v1/workflows

Request Body

{
  "name": "data-pipeline-v1",
  "trigger": "webhook",
  "steps": [
    {
      "type": "transform",
      "model": "craftai-1",
      "config": { "format": "json" }
    },
    {
      "type": "route",
      "conditions": [
        { "field": "priority", "op": "gte", "value": 8 }
      ]
    }
  ],
  "output": "s3://my-bucket/processed/"
}

Response

{
  "id": "wf_a1b2c3d4",
  "status": "active",
  "created_at": "2026-03-01T10:00:00Z",
  "endpoint": "https://api.craftaiplatform.com/v1/workflows/wf_a1b2c3d4/trigger",
  "metrics": {
    "executions": 0,
    "avg_latency_ms": null
  }
}

Example (Python)

import requests

resp = requests.post(
    "https://api.craftaiplatform.com/v1/workflows",
    headers={
        "Authorization": "Bearer YOUR_API_KEY",
        "Content-Type": "application/json"
    },
    json={
        "name": "my-pipeline",
        "trigger": "cron",
        "steps": [{"type": "transform", "model": "craftai-1"}]
    }
)

print(resp.json())

Example (JavaScript)

const res = await fetch('https://api.craftaiplatform.com/v1/workflows', {
  method: 'POST',
  headers: {
    'Authorization': 'Bearer YOUR_API_KEY',
    'Content-Type': 'application/json'
  },
  body: JSON.stringify({
    name: 'my-pipeline',
    trigger: 'webhook',
    steps: [{ type: 'transform', model: 'craftai-1' }]
  })
});

const data = await res.json();
console.log(data);

Available Models

ModelDescriptionThroughputPrice
craftai-1General-purpose workflow engine2,000 rps$0.0004/call
craftai-1-fastLow-latency optimized5,000 rps$0.0007/call
craftai-1-proAdvanced reasoning & routing1,000 rps$0.0012/call

Rate Limits

PlanRequests/minBurst
Builder60100
Scale300500
EnterpriseCustomCustom

Error Codes

CodeDescription
200Success
400Bad Request - Invalid parameters
401Unauthorized - Invalid API key
429Rate limit exceeded
500Internal server error

Official SDKs

Auto-generated SDKs for popular languages:

Python

pip install craftai-sdkComing Soon

Node.js

npm install @craftai/sdkComing Soon

Go

go get craftai.dev/sdkComing Soon

Ready to Integrate?

Join the waitlist for early API access and sandbox environment.

Join Waitlist