Build around
the work.
Start with model access, agent workflows or knowledge. Choose the integration path that fits your application.
In short:Un gateway compatibile con OpenAI per creare applicazioni di IA. Usa gli SDK ufficiali di OpenAI o semplici richieste HTTP con la tua chiave API Swfte.
application → model access → response
Model access
Connect your application to model access. Start by reviewing routing, authentication and usage requirements.
Explore ConnectFollow the published reference.
Read the SDK examples and integration guidance alongside the product you intend to use.
Open the developer referenceBefore your first integration
Agree the credential boundary, test inputs, failure handling and the usage you need to observe.
Discuss an integrationPlayground API interattivo
Testa le chiamate API in tempo reale con esempi di codice dal vivo e risultati istantanei.
curl https://api.swfte.com/agents/v2/gateway/chat/completions \
-H "Authorization: Bearer $SWFTE_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "openai:gpt-4o-mini",
"messages": [
{ "role": "user", "content": "Say hello in five words." }
]
}'Il tuo percorso di integrazione guidato
Inizia in pochi minuti con la nostra guida di integrazione passo dopo passo.
export SWFTE_API_KEY="sk-swfte-..."Create an API key
Open the Connect console, create an API key and keep it in an environment variable.
# pip install openai
import os
from openai import OpenAI
client = OpenAI(
base_url="https://api.swfte.com/agents/v2/gateway",
api_key=os.environ["SWFTE_API_KEY"],
)Point the OpenAI SDK at Swfte
The gateway is OpenAI-compatible. Install the official openai package and set the base URL.
response = client.chat.completions.create(
model="openai:gpt-4o-mini",
messages=[{"role": "user", "content": "Hello, world!"}],
)
print(response.choices[0].message.content)Make your first request
Use a mini model on the free plan. Any OpenAI-compatible client or plain curl works the same way.
Costruito per sviluppatori
Tutto ciò di cui hai bisogno per creare applicazioni AI di livello produttivo.
Definizioni TypeScript complete
con completamento automatico e controllo in fase di compilazione.
TypeScript, Python, Go, Ruby
e altro con parità completa delle funzionalità.
Streaming token per token
con supporto SSE e WebSocket.
Latenza, token, costi, errori
tracciati automaticamente.
Domande frequenti
Non esiste ancora un SDK Swfte dedicato. Il gateway è compatibile con OpenAI, quindi gli SDK ufficiali di OpenAI (Python, TypeScript e altri) funzionano impostando l'URL di base sul gateway Swfte, così come qualsiasi client HTTP.
Usa chiavi API memorizzate in variabili d'ambiente o passate direttamente all'SDK. Supportiamo OAuth2 per l'integrazione SSO aziendale e forniamo rotazione sicura delle chiavi.
Livello gratuito: 100 richieste/minuto. Pro: 1.000 richieste/minuto. Enterprise: Limiti personalizzati con capacità dedicata e gestione burst.
L'SDK fornisce classi di errore tipizzate con messaggi dettagliati. Tutti gli errori includono ID di richiesta per debug e supporto. Offriamo anche tentativi automatici con backoff esponenziale.
Sì! Tutti gli SDK supportano Server-Sent Events (SSE) per lo streaming in tempo reale. Puoi ricevere token man mano che vengono generati per UI reattive.
Pronto per iniziare a costruire?
Ottieni la tua chiave API e inizia a costruire in pochi minuti.