https://api.deepinfra.com/v1/openai. GoModel routes these endpoints to it unchanged:
Configure
Create an API key in the DeepInfra dashboard and set:config.yaml:
Models
GoModel reads DeepInfra’s live/models listing, including each model’s kind
(chat, embedding, image, speech, transcription), context length, reasoning and
vision tags, and prices. Video generation models are left out because GoModel
has no video endpoint for DeepInfra. Model IDs contain a slash; use them
verbatim, or prefix the provider name to pin the route:
reasoning_effort and reasoning: {"effort": ...} are honored by
DeepInfra’s reasoning models, and none turns thinking off on hybrid models
such as Qwen3.
Behavior notes
- Responses are stateless. DeepInfra keeps no responses, so
store: truehas no upstream effect. With a GoModel response store configured,previous_response_idchains still work: the gateway replays the stored history before dispatch. Without one, DeepInfra rejectsprevious_response_idandconversationwith an invalid-request error. - Structured Responses output goes through chat. DeepInfra’s native
Responses endpoint rejects every
textsetting (text.format,text.verbosity), so GoModel serves those requests through chat completions, wherejson_schemaandjson_objectwork. - Speech defaults to MP3. DeepInfra answers WAV when
response_formatis omitted; GoModel sends OpenAI’s default (mp3) instead. Setresponse_formatexplicitly to get another format. - Image pricing is per image unit. DeepInfra lists image prices per image unit, and GoModel records that rate as the per-image price. Cost tracking is approximate for models DeepInfra bills by size or step count.
- Passthrough is opt-in. Add
deepinfratoENABLED_PASSTHROUGH_PROVIDERSto expose/p/deepinfra/..., which forwards any path under the base URL with the gateway’s DeepInfra key.