SDKs and frameworks

LangChain

LangChain’s OpenAI chat model takes a base URL, so ChatOpenAI reaches every model on Vioneer; for Claude, ChatAnthropic works too.

Python

LangChain · Python
# pip install langchain-openai
import os
from langchain_openai import ChatOpenAI

llm = ChatOpenAI(
    model="claude-sonnet-5-5",
    base_url="https://vioneer.xyz/api/v1",
    api_key=os.environ["VIONEER_API_KEY"],
)
print(llm.invoke("Write a haiku about the sea.").content)

Claude through ChatAnthropic

LangChain · Python
# pip install langchain-anthropic
import os
from langchain_anthropic import ChatAnthropic

llm = ChatAnthropic(
    model="claude-sonnet-5-5",
    base_url="https://vioneer.xyz/api",
    api_key=os.environ["VIONEER_API_KEY"],
)
print(llm.invoke("Write a haiku about the sea.").content)

JavaScript and TypeScript

LangChain · TypeScript
// npm install @langchain/openai
import { ChatOpenAI } from '@langchain/openai';

const llm = new ChatOpenAI({
  model: 'gpt-6.2-sol',
  apiKey: process.env.VIONEER_API_KEY,
  configuration: { baseURL: 'https://vioneer.xyz/api/v1' },
});

const reply = await llm.invoke('Write a haiku about the sea.');
console.log(reply.content);

Streaming and tool calling pass through as LangChain sends them, and LangGraph agents take the same model objects.

If something does not work

  • 401: the key is wrong, revoked or missing. Keys are shown once, when you create them; make a new one in the dashboard if in doubt.
  • 402: the account is out of credit. Top up and the next request goes through.
  • 403: the key is not allowed that model. Check its model allowlist under Keys.
  • 404 on a model: the id is not in the catalogue. Copy it from the price list.
  • 429: a rate or concurrency limit was hit. Wait for the retry-after seconds, or raise the key’s limit.

Every request, failed ones included, is listed in the dashboard’s activity log with its status and cost.