OpenAI-compatible API
Connect the OpenAI SDK to InferGate with a custom base URL, InferGate authentication and exact model IDs. Understand the compatibility boundary.
OpenAI-compatible describes a request and SDK integration pattern. InferGate is an independent service with its own account, key, billing and available model catalog.
What changes in an existing client
- Set base_url in Python or baseURL in Node.js to https://api.useinfergate.com/v1.
- Use an InferGate API key stored in an environment variable.
- Choose a model returned by your authenticated catalog.
- Test the endpoint and parameters you actually use before migrating traffic.
Verified starting point
curl --fail-with-body https://api.useinfergate.com/v1/responses \
-H "Authorization: Bearer $INFERGATE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"gpt-5.5","input":"Reply with one sentence about API design.","max_output_tokens":256}'Compatibility is endpoint-specific
The production acceptance verified the Responses endpoint in streaming and non-streaming modes for the four published models. Do not infer support for every OpenAI feature, tool, file workflow or optional parameter from SDK compatibility. Start with the documented request.
From account to first response
- Create an account or sign in to your existing account.
- Check wallet balance and create a server-side API key.
- List the models your key can access, then send one small request.
- Inspect the returned model, completion status and usage before increasing traffic.
Compatibility checklist by integration layer
| Layer | Configure for InferGate | Do not assume |
|---|---|---|
| Client | Python base_url or Node.js baseURL | Changing the model name alone changes providers |
| Authentication | InferGate Bearer key | A key from another service will work |
| Request | Verified Responses text format | Every SDK method is supported |
| Streaming | Responses event lifecycle | Chat chunk fields and Responses events are interchangeable |
Frequently asked questions
Is InferGate the official OpenAI service?
No. InferGate is independent. OpenAI-compatible describes the client and API integration pattern, not ownership, endorsement or identical service behavior.
Why does my request still reach another API host?
Inspect the actual base URL configured in the client instance that sends the request. Environment variables do not override an explicitly configured URL in every application. Keep credentials out of diagnostic logs.
Can I use a browser-side SDK instance?
Keep the InferGate key on your server. A browser bundle or publicly accessible environment variable can expose credentials; call your own backend from the browser.
Continue your integration
Review prepaid pricing · Read API documentation · Get Started