Prismatic API/Docs/API Endpoints
Documentation

API Endpoints

The public API exposes model discovery plus OpenAI-compatible, Gemini-compatible and Anthropic-compatible generation routes.

Core text generation

POST/v1/chat/completions
Chat Completions

OpenAI-compatible chat completions with optional streaming.

POST/v1/responses
Responses

OpenAI Responses-compatible input, instructions and tools through the same billing layer.

POST/v1/models/{model}:generateContent
Gemini generateContent v1

Gemini-compatible non-streaming generation. The {model} path segment is the Prismatic public model ID.

POST/v1beta/models/{model}:generateContent
Gemini generateContent v1beta

Beta-version Gemini-compatible non-streaming generation for clients that target the v1beta Gemini surface.

POST/v1/models/{model}:streamGenerateContent
Gemini streamGenerateContent v1

Gemini-compatible SSE streaming. Do not set stream: true on generateContent; use this endpoint instead.

POST/v1beta/models/{model}:streamGenerateContent
Gemini streamGenerateContent v1beta

Beta-version Gemini-compatible SSE streaming for clients that target the v1beta Gemini surface.

POST/v1/images/generations
Image generations

OpenAI-compatible image generation. Prismatic requires model so routing, plan access and billing are explicit.

POST/v1/videos
Video generations

OpenAI-compatible video generation. Prismatic requires model and routes only to providers marked with video support.

POST/v1/messages
Messages

Anthropic-compatible Messages endpoint for Claude-native clients and coding agents.

Models and token estimates

GET/v1/models
List models

Returns enabled public model IDs and metadata in the shape expected by the request protocol. A single canonical model can appear under multiple public IDs when aliases are configured.

GET/v1/models/{model_id}
Get model

Returns one enabled model by public ID or model_not_found when unavailable.

POST/v1/messages/count_tokens
Count tokens

Estimates input tokens for an Anthropic-style Messages payload before generation.

Account

Read the authenticated account's quota and wallet balance with the same API key used for generation.

GET/v1/account/quota
Account quota

Returns the account's subscription quota windows (5h / 7d rolling, or the daily window for daily-mode plans) with limit / used / remaining and reset times, plus the PAYG wallet balance in USD. plan, windows and daily are null when the account has no active subscription.

Bash
curl https://api.prismaticapi.com/v1/account/quota \
  -H "Authorization: Bearer $PRISMATIC_API_KEY"

Image generation example

Use an image-capable public model ID from GET /v1/models. The request consumes subscription quota or PAYG through the same billing checks as text generation.

curl https://api.prismaticapi.com/v1/images/generations   -H "Authorization: Bearer $PRISMATIC_API_KEY"   -H "Content-Type: application/json"   -d '{
    "model": "imagen-4",
    "prompt": "A clean product mockup on a neutral desk",
    "image_url": ["https://example.com/reference.png"],
    "negative_prompt": "clutter, text artifacts",
    "aspect_ratio": "16:9",
    "quality": "high",
    "style": "natural",
    "seed": 42,
    "response_format": "b64_json",
    "n": 1
  }'
import OpenAI from "openai";

const client = new OpenAI({
  apiKey: process.env.PRISMATIC_API_KEY,
  baseURL: "https://api.prismaticapi.com/v1"
});

const image = await client.images.generate({
  model: "imagen-4",
  prompt: "A clean product mockup on a neutral desk",
  image_url: "https://example.com/reference.png",
  negative_prompt: "clutter, text artifacts",
  aspect_ratio: "16:9",
  quality: "high",
  style: "natural",
  seed: 42,
  response_format: "b64_json",
  n: 1
});

Other surfaces

  • Audio, embeddings and moderation endpoints are not part of Prismatic v1 yet.
  • Do not configure clients to call unsupported routes until they are exposed by the API.
  • The dashboard remains the source of truth for account usage and billing views.