Overview
In addition to our purpose-built code models, we host our set of preferred open-weight models for coding tasks. You can hit these models directly through our OpenAI-compatible API. For discounted reserve rates, reach out to info@relace.ai. All hosted models are served fromhttps://models.relace.ai and authenticate with your regular Relace API key — no separate setup, and any OpenAI SDK works by pointing it at our base URL.
Prerequisites
1
List Available Models
The live up to date model catalog is available from the Each entry in the returned
/models endpoint.data array includes the model id, context_length, per-token pricing, and supported sampling parameters and features.2
Call Chat Completions
Send requests to Tool calling, JSON mode, structured outputs, and the standard sampling parameters (
/v1/chat/completions with the model ID of your choice. The endpoint is OpenAI-compatible, so you can use the OpenAI SDK directly.temperature, top_p, stop, etc.) work as they do with any OpenAI-compatible provider.3
Stream Responses
Set
stream: true to receive tokens as they are generated. Token usage is always reported in the final chunk of the stream.