API

Integrate Neural Flow visualizations into your own applications.

POST
/api/chat

Send a prompt and get a response with visualization data

API Key

Request Body

{
  "prompt": "Explain gravity",
  "model": "nemotron-3-ultra",
  "stream": false
}

Response

{
  "id": "msg_123",
  "content": "Gravity is a fundamental force...",
  "role": "assistant",
  "processing_steps": [
    {
      "id": "tokenize",
      "label": "Tokenizing",
      "status": "complete",
      "duration": 45.2,
      "timestamp": 1234567890
    },
    {
      "id": "embed",
      "label": "Embedding",
      "status": "complete",
      "duration": 52.1,
      "timestamp": 1234567890
    }
  ],
  "prompt_tokens": 12,
  "completion_tokens": 45,
  "latency": 810.3,
  "cost": 0.0032
}

Quick Start

Try the API right now with curl

Replace with your actual API endpoint:

curl -X POST https://api.neuralflow.dev/chat \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -d '{"prompt": "Explain gravity", "model": "nemotron-3-ultra"}'