Nodedistro API Docs
Docs Usage Help Open Chat
API platform

Build with Nodedistro

Access leading AI models through one API, one key, and one prepaid developer balance.

Quickstart
curl https://ai.nodedistro.com/api/developer/chat \
  -H "Authorization: Bearer $NODEDISTRO_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"messages":[{"role":"user","content":"Hello!"}]}'
Self-hosted AI · NodeDistro Intelligence

Build with Nexus and Nova.

Use NodeDistro-hosted models through your existing developer API key, or connect directly to the Intelligence API with its own key.

Nexus 1 Nano · SmolLM3 3B foundationNova 1 · IBM Granite 2B foundation
The developer wallet uses USD. Direct Intelligence API credits count tokens and are a separate balance. Available models depend on the live workspace configuration.

Project overview

Developer API activity for the current billing month.

Default project
Credit balance$0.00Required for Developer API
Requests0This billing month
Tokens00 input / 0 output
Active keys00 total keys
Developer balance $0.00

Buy a pack or enter a custom amount (min $5).

Get started

Go from key to first response in minutes.

3 steps

API keys

Recently created credentials.

API endpoint

Use this base URL from your server.

Bearer API key required

Default project

API keys

Create and manage secret keys for this project.
Your secret API keys are listed below. Never expose a key in browser or client-side code.
NameKeyLifetime usageLast usedStatusActions

Default project

Playground

Prototype prompts and inspect live API responses.

Configuration

POST

Response

Ready
Run a request to see the model response, latency, tokens, and cost.

API reference

NodeDistro AI documentation

Updated November 27, 2026 · Implemented behavior and setup requirements · Gateway OpenAPI JSON

Build with the Nodedistro AI Chat API. One authenticated endpoint for model routing, optional web search, and account-level usage metering.

NodeDistro Intelligence

Run NodeDistro-hosted Nexus 1 Nano and Nova 1. Nexus uses HuggingFaceTB SmolLM3-3B; Nova uses IBM Granite 3.3 2B Instruct. Both credit their Apache-2.0 foundations. These are hosted models, not independently pretrained NodeDistro weights.

Through the NodeDistro AI developer API

Use your existing ndsk_ developer key and developer USD wallet. Select NodeDistro Intelligence in the playground. The server must have its Intelligence connection and upstream token balance configured.

curl https://ai.nodedistro.com/api/developer/chat \
  -H "Authorization: Bearer $NODEDISTRO_AI_KEY" \
  -H "Content-Type: application/json" \
  -d '{"provider":"nodedistro","model":"nodedistro-nova-1","webSearch":false,"messages":[{"role":"user","content":"Explain how an Express route works."}]}'

provider: "nodedistro" selects the Intelligence connection. Existing provider: "custom" requests remain compatible. Gateway responses use the documented content field.

Direct OpenAI-compatible API and streaming

Base URL: https://intelligence.nodedistro.com/service/v1. Create a separate key in Intelligence API keys. Direct keys are 64 hexadecimal characters; they are not NodeDistro AI ndsk_ keys. Keep both types on your server.

import os
from openai import OpenAI

client = OpenAI(
    base_url="https://intelligence.nodedistro.com/service/v1",
    api_key=os.environ["INTELLIGENCE_API_KEY"],
)
stream = client.chat.completions.create(
    model="nexus-1-nano",
    messages=[{"role": "user", "content": "Explain CUDA briefly."}],
    max_tokens=512,
    stream=True,
)
for chunk in stream:
    if chunk.choices:
        print(chunk.choices[0].delta.content or "", end="", flush=True)

Direct model IDs: nexus-1-nano and nova-1. Original nodedistro-smollm3-3b and nodedistro-nova-1 IDs remain supported. Query GET /v1/models for the installed catalog.

Credits, limits and availability

Direct API chat charges one Intelligence credit per reported input or output token, with no free starter balance. Use GET /v1/credits to inspect the balance. Owners allocate credits in Intelligence Billing. Specify max_tokens to limit the reserved amount. HTTP 402 means insufficient credits; the account also has a 100-request daily chat allowance. GPU cold starts can delay the first response.

Buying NodeDistro AI developer credits does not automatically add credits to the separate direct Intelligence token balance. See the Intelligence documentation and OpenAPI specification.

Developer quickstart

Make your first API request in minutes. Create a key, send chat messages, and read the assistant response.

Chat API

Send messages to /api/developer/chat with provider routing and optional web search.

View endpoint

API playground

Test the same request shape your application will call before shipping.

Authentication

The Nodedistro AI API uses API keys for authentication. Create and manage keys in the developer console. Keys begin with ndsk_.

Remember that your API key is a secret. Do not share it or embed it in client-side code. Store it only on your server and send it in the Authorization header.

Authorization: Bearer ndsk_your_key
Developer API access requires prepaid credits. Key revocations take effect on subsequent requests.

Prepaid credits

Calls to POST /api/developer/chat spend from your prepaid developer credit balance. Workspace chat continues to use your plan’s monthly included budget.

  • Shared wallet — one balance covers OpenAI (openai), Anthropic (anthropic), Google (gemini), and NodeDistro Intelligence (nodedistro).
  • Required balance — each request needs enough credits to cover the projected cost before the provider is called.
  • Add credits — purchase one-time packs ($10 / $25 / $50 / $100) or a custom amount (minimum $5) from the developer console Overview. Choose which vendor account Nodedistro should fund; your spendable balance stays shared.
  • Empty balance — the API returns 402 with code: "CREDITS_REQUIRED" and the remaining creditBalanceUsd.
in the developer console before integrating the API in production.

Chat > Completions

Create chat completion

Given a list of messages comprising a conversation, the model returns an assistant response.

POST /api/developer/chat
Base URL /api/developer/chat Content-Type application/json

Request body

All fields are JSON. messages is required. Set provider and model explicitly for predictable routing.

messagesarrayRequired

Ordered chat turns. Each item needs role (system, user, or assistant) and content.

providerstring

Provider ID such as openai, anthropic, gemini, or nodedistro. Intelligence also accepts the legacy custom ID. Responses can report the internal custom ID. Unavailable providers are rejected.

modelstring

Model ID for the selected provider. Use auto only when that provider supports automatic routing.

webSearchboolean

When true, the API may search the web before generating a response, subject to provider policy and configured search services. Retrieved pages can contain inaccurate information; inspect citations. Search failure details may appear under webSearch.error.

webBrowseboolean

URLs in the latest user message are read automatically. Follow-ups use a matching page name from recent user links, or the most recent link when no page is named. Set false to disable page reading, or true to also read a search result when no URL is supplied. This works independently of webSearch.

temperaturenumber

Controls randomness. Prefer lower values for deterministic application behavior.

Returns

Returns a chat completion object with assistant text and metering fields.

contentstring

Assistant response text.

providerstring

Provider used for the response.

modelstring

Model used for the response.

usageobject

Input, output, and total tokens plus estimated cost for this request.

monthlyUsageobject

Current billing-month usage and request totals for the account.

developerCreditBalanceUsdnumber

Remaining prepaid balance after this Developer API request.

webSearchobject | null

Search provider, results, page status, and errors when search ran.

Error codes

The NodeDistro AI gateway returns JSON with an error string and sometimes a machine-readable code. Direct Intelligence uses detail, which can be a string or validation-detail array.

400Invalid request — missing messages, unknown provider, or unsupported model.
401Unauthorized — missing, invalid, or revoked API key.
402Credits required — prepaid developer credit balance is too low (CREDITS_REQUIRED). Add credits in the developer console.
403Blocked — account suspended or request blocked by policy.
404Unknown model, missing resource, or a resource not owned by the account.
409Conflict, such as an upload offset mismatch or reused operation ID with different details.
413Request, upload chunk, or generated artifact exceeds its route limit.
422Validation failed. Check the selected model ID, message roles, nonempty text, and generation settings.
429Rate, daily allowance, or job quota exceeded. Avoid immediate repeated retries.
502Upstream provider or authentication failure. This can require operator configuration.
503Unavailable — selected provider is unavailable or not configured.
504Upstream timeout. Review incomplete responses before retrying.

Usage and limits

Developer API spend deducts prepaid credits. Workspace chat usage is tracked separately against your plan budget and refreshes at 12:00 AM UTC on the first day of each month.

  • Developer credits — prepaid wallet required for /api/developer/chat; returned as developerCreditBalanceUsd.
  • Included budget — plan allowance for workspace chat, returned as budgetUsd.
  • Key hygiene — revoke unused keys and rotate credentials after exposure.

Choose your API

NodeDistro AI and NodeDistro Intelligence are connected products with different authentication, response formats, and balances. Choose one integration path.

PathKey and endpointResponse and billing
NodeDistro AI gatewayndsk_ key · POST https://ai.nodedistro.com/api/developer/chatJSON content field · prepaid USD developer wallet
Direct Intelligence64-character hexadecimal key · POST https://intelligence.nodedistro.com/service/v1/chat/completionsOpenAI-compatible choices or SSE · token credits
Website app sessionsSign in through the websiteSession-only account, chat and connection features; not the developer-key API

Keep keys in server environment variables. Never put either key type into a public repository, mobile bundle, or public frontend. SDK libraries are clients; the Intelligence base URL directs requests to NodeDistro-hosted compute.

Models, context and reasoning

The live GET /api/providers catalog supplies gateway provider/model choices. It can reflect the signed-in plan. Direct GET /service/v1/models requires an Intelligence key and lists installed models and compatibility aliases.

  • Nexus 1 Nano: gateway ID nodedistro-smollm3-3b; direct alias nexus-1-nano. Foundation: HuggingFaceTB SmolLM3-3B.
  • Nova 1: gateway ID nodedistro-nova-1; direct alias nova-1. Foundation: IBM Granite 3.3 2B Instruct.
  • Old nd-code selections resolve to Nova 1. Old nd-core, nd-plus and nd-reason selections resolve to Nexus. They do not represent separate installed specialist models. Vision is not enabled by these aliases.

Both hosted chat models currently serve up to 65,536 total tokens, shared between input and output. max_tokens is an output ceiling, not a promise of answer length. Specify a smaller value to reduce direct-credit reservations.

Direct Intelligence supports reasoning_effort: none, low, medium, high, xhigh, max. Nexus enables its native thinking mode for medium and above. This does not guarantee reasoning support or equivalent behavior across models. The website uses provider-specific controls where supported.

The developer gateway currently reads messages, provider, model, temperature, webSearch, and webBrowse. It does not currently forward caller-supplied max_tokens, reasoning_effort, or stream. Use direct Intelligence when those controls are required.

Streaming and cancellation

Developer gateway: /api/developer/chat returns one JSON result. Do not parse it as an SSE stream or assume that adding stream: true enables streaming.

Direct Intelligence: set stream: true and read text/event-stream events. Each data: event contains a chat completion chunk; text appears in choices[0].delta.content. The stream ends with data: [DONE]. Network chunks may split or combine events and UTF-8 characters. Use an SDK or an incremental SSE parser.

curl -N https://intelligence.nodedistro.com/service/v1/chat/completions   -H "Authorization: Bearer $INTELLIGENCE_API_KEY"   -H "Content-Type: application/json"   -d '{"model":"nova-1","messages":[{"role":"user","content":"Explain Express briefly."}],"max_tokens":256,"stream":true,"stream_options":{"include_usage":true}}'

Usage-only events can have an empty choices array. Aborting a client request closes the connection, but interruption is not a guarantee of zero compute charges or an immediate credit refund. Missing usage can leave the direct token reservation pending operator review.

The signed-in NodeDistro AI chat UI uses an internal NDJSON stream and a private progress fallback. Those session-only routes are not the OpenAI-compatible API. Cold GPU starts may delay initial headers and tokens even when streaming works.

Motion 1 video and generated audio · Private beta

Restricted access: administrators/owners and explicitly whitelisted verified account emails only. This is enforced for creation, status and downloads. Administrators manage the whitelist at Video beta access. A shared server key does not automatically approve every chat customer.

Use the Motion Studio or the direct Intelligence API. Motion runs LTX-2 for synchronized video/audio, latent detail refinement and Real-ESRGAN enhancement. New jobs do not use CogVideoX or Kokoro, and do not fall back to an external video API.

Current output is five seconds at 24 fps: landscape 3840x2160 or portrait 2160x3840. This is AI-enhanced 4K, generated at lower resolution before enhancement. It is not direct native 4K generation and does not claim Higgsfield feature or quality parity.

curl https://intelligence.nodedistro.com/service/v1/videos   -H "Authorization: Bearer $INTELLIGENCE_API_KEY"   -H "Content-Type: application/json"   -d '{"prompt":"An orange robot walks through a sunlit garden.","narration":"Welcome to NodeDistro.","aspect_ratio":"landscape","camera":"dolly","style":"cinematic","seed":42}'

The 201 response contains a video_… job ID. Poll GET /v1/videos/{video_id} about every five seconds. Download GET /v1/videos/{video_id}/content only after status: completed. Other states are queued, in_progress and failed. Resources are private to their account.

  • Prompt: 1–2,000 characters. Optional narration: up to 180 characters.
  • Camera: static, dolly, orbit, drone. Style: cinematic, product, natural, animation.
  • Aspect: landscape or portrait. Seed: 0–2,147,483,647.
  • Voice compatibility values af_heart/am_adam provide female/male voice direction to LTX; they do not select Kokoro. Wording, camera movement and voice consistency can vary.
  • One accepted render per account per UTC day. Failed HTTP submissions release the slot; accepted render work retains the quota. No public video cancellation route is currently provided.

Video is not charged chat token credits. GPU, CPU/RAM and storage are billed separately to the workspace operator by Modal. The CAD $5 per-video target is not a published customer price or a billing guarantee. Approximately 93 GB of cached model weights incur storage charges. Long videos require an external editing/stitching workflow; a one-hour generation request is not supported.

Documents, generated files and real sources

Website chat can attach supported documents and retrieve relevant passages. Long prompts can be stored as attachments, but models still have context limits: attachment storage does not mean every word is read in every request.

NodeDistro AI chat can create DOCX/PPTX artifacts and read supported uploaded PDFs. PDF generation is available through the direct Intelligence artifact route described below. These are app workflows, not endpoints on the developer chat API. Direct Intelligence provides POST /v1/artifacts with format, title and content, followed by private GET /v1/artifacts/{artifact_id}. Supported formats are png, pdf, docx, pptx, xlsx, txt, md, py, js, ts; stored artifacts are limited to 1,900,000 bytes.

Direct chat can include source_urls with up to three public HTTPS URLs. Pages are retrieved and supplied as reference context with a retrieval timestamp and citation instructions. Private networks, unsupported formats and oversized pages are blocked. Retrieval failures stop that request. This is retrieval, not model training or guaranteed factual accuracy.

{"model":"nexus-1-nano","messages":[{"role":"user","content":"Summarize this documentation."}],"source_urls":["https://www.python.org/doc/"],"max_tokens":512}

Gateway webSearch and webBrowse are separate app features and depend on configured services. Direct Google search requires a Google API key and search engine ID configured by the operator; it must report unavailable when missing.

Endpoint directory

Gateway paths below use https://ai.nodedistro.com. Direct Intelligence paths use https://intelligence.nodedistro.com/service. Browser-session operations do not accept developer keys.

MethodPathAccess / behavior
GET/api/providersPublic provider catalog; signed-in visibility may differ
GET/api/developer/chatPublic endpoint description
POST/api/developer/chatndsk_ key; JSON chat result; developer USD wallet
GET / POST/api/developer/keysSigned-in account: list/create developer keys
DELETE/api/developer/keys/{id}Signed-in owner of key: revoke
POST/api/developer/credits/checkoutSigned-in account: create hosted Stripe Checkout
POST/api/developer/credits/confirmSigned-in account: confirm its paid Checkout session
GETIntelligence /v1/models, /v1/credits, /v1/usageSeparate Intelligence key; installed models and direct account metering
POSTIntelligence /v1/chat/completionsSeparate Intelligence key; JSON or SSE
POST / GETIntelligence /v1/videos…Separate Intelligence key; Motion jobs and private MP4
GETIntelligence /v1/training/jobs…Separate Intelligence key; owned/authorized job status

See the direct Intelligence OpenAPI reference for exact paths, body schemas, response formats and permissions. Unsupported embeddings, standalone completions and unimplemented model-management routes are not advertised as available.

GitHub, Gmail and Outlook connections

Open Connections while signed in. GitHub connects permitted personal or organization repositories; organization policies can restrict access. Enable individual repositories before agents may read or propose file changes.

GitHub file creation, modification and deletion, plus Gmail/Outlook sending, use a review queue. The user reviews and approves the exact action in Connections. The model cannot approve its own mutations or messages. Disconnecting a provider rejects pending actions. Concurrent file changes or ambiguous provider failures can require a new review.

OAuth client applications and an encryption secret must be configured first. Unconfigured providers remain unavailable; the code's presence does not mean the accounts are connected or that end-to-end OAuth setup has been verified. The /api/connections routes require the signed-in account session and are not callable using an ndsk_ key.

For operator callback URLs, scopes and secret names, see the repository's docs/account-connections.md. Never share client secrets or refresh tokens in prompts.

Troubleshooting and operating limits

  • 402: identify which API you called. Gateway errors refer to the developer USD wallet; direct errors refer to token credits. Buying one does not fund the other. Gateway requests also depend on the operator's upstream Intelligence token balance.
  • 422 / old nd-code: current compatibility routing maps this to Nova 1. Refresh the catalog and select an installed model. Check nonempty message content, supported roles and the direct 32,000-character per-message limit.
  • Long first response: a scale-to-zero worker may need to start and load weights. Streaming does not eliminate startup latency. Keeping an active worker warm incurs infrastructure charges.
  • Browser Failed to fetch: check the base URL, HTTPS and CORS. Direct bearer-authenticated /service/v1/* supports browser CORS, but production secrets still belong on your server. A third-party tester's proxy allowlist is controlled by that tester, not NodeDistro.
  • Stream finishes without [DONE]: treat it as interrupted. Retrying generation can consume additional credits; generation calls do not currently offer an idempotency key.
  • Video unavailable: inspect Studio/availability status, daily quota, job error and operator GPU billing. A failed render is not replaced with fake output.
  • Training permission required: direct training mutations require DEVELOPER, ADMIN or OWNER. Training uses the configured trainable worker foundation; selecting a chat GGUF model does not make it trainable automatically.
  • Model plans: proposed Nexus Pro/Ultra, Forge and Vision families are not installed models. Use the live catalog rather than assuming names imply available capabilities.

Supported workflows are versioned by the implemented routes. There is no promise of unlimited context, uninterrupted GPU capacity, automatic credit transfer, native 4K, or universal tool/reasoning support.

Add developer credits

One-time Stripe payment. Credits are shared across OpenAI, Anthropic, Google, and NodeDistro Intelligence on the Developer API.

Fund which provider account

Your USD wallet stays shared. For NodeDistro Intelligence, this choice records an operator-managed infrastructure funding request. It does not add direct Intelligence token credits.

Create API key

Name the environment or application that will use this key.

Save your API key

This is the only time the complete key will be shown.

Store it securely. You cannot recover this key after closing this window.