Text models

Connect and verify Gemini 4 Carbon

Check the model ID, text requests, streaming, and recorded usage.

Verify the model route

Look up gemini-4-carbon in GET /v1/models and check its availability before sending a request.

Start with a short request

Send contents in the request body and verify the response shape. Use streamGenerateContent for SSE and record final usage after the stream closes.

Run a reproducible regression

Keep a small group of short tasks and another group of longer tasks. Record output completeness, tool calls, actual tokens, and billing IDs.

Example request

curl "https://api.apimodel.store/v1beta/models/gemini-4-carbon:generateContent" \
  -H "Authorization: Bearer $MODELPORT_API_KEY" \
  -H "Content-Type: application/json" \
  --data '{"contents":[{"role":"user","parts":[{"text":"List three acceptance checks for an offline notes app."}]}],"generationConfig":{"maxOutputTokens":256}}'

Models in this guide

Related guides and tools

Sources