Velaron.AI

DocsAPI reference

Responses

The OpenAI Responses shape, which the newer OpenAI SDKs use by default. Same key, same billing, same base URL.

POST/v1/responses

Node
import OpenAI from "openai";

const client = new OpenAI({ baseURL: "https://velaron.ai/v1", apiKey: process.env.KREDIT_KEY });
const response = await client.responses.create({
  model: "openai/gpt-4o",
  instructions: "Answer in one sentence.",
  input: "What does a Velaron.AI credit buy?",
});
console.log(response.output_text);

Request#

modelstring · required

A chat model id from GET /v1/models.

inputstring | array · required

A string or an array of input items, exactly as the OpenAI API defines them.

instructionsstring

Counted toward the input estimate for the balance check, then forwarded as is.

max_output_tokensinteger

Lowered by Velaron.AI when your balance cannot cover it, so an answer is never cut off by an empty balance halfway through.

streamboolean

Server-sent events. Usage is read from the response.completed event.

Response#

The provider's JSON plus the two billing headers on non-streamed answers. Cached input tokens reported in input_tokens_details.cached_tokens are billed at the model's cache price.

Errors come back in the OpenAI shape. A body without model and input answers 400 invalid_body with Send a JSON body with `model` and `input` (a string or an array of items).