Skip to content

Endpoint Matrix ​

Base URL:

text
https://api.rout.my/v1
EndpointMethodBody shapeOutputNotes
GET /modelsGETnoneOpenAI-style model listUse this first to copy exact model IDs.
POST /chat/completionsPOSTmodel, messages, optional stream, tools, vision contentChat completion or SSE streamBest for OpenAI-compatible chat clients.
POST /responsesPOSTmodel, input, optional tools/stream-like fieldsResponses-style object or streamUseful when an app expects the newer Responses shape.
POST /embeddingsPOSTmodel, input, optional encoding_formatEmbedding listFor search, RAG, clustering, and semantic matching.
POST /systemonePOSTmodel, state, questionsanswers, usageNative TypeSafe: noul, choice, score; confidence and structured legend; no streaming.
/typesafe/v1/systemone, /typesafe/v1/modelsPOST, GETNative SDK prefix; inference/reseller keySystem One response / {models: [...]}SDK base URL: https://api.rout.my/typesafe.
POST /images/generationsPOSTmodel, prompt, optional n, size, quality, image_configdata[].url or data[].b64_jsonSingle-prompt image generation.
POST /images/editsPOSTmodel, prompt, images or multipart image, optional edit fieldsdata[].url or data[].b64_jsonOpenAI-style image editing through OpenAI-compatible providers.
POST /video/generationsPOSTmodel, prompt, optional unified video fields (duration, resolution, audio, quality, media inputs)Video generation responserout.my maps unified fields into provider-specific video options when supported.
GET https://api.rout.my/embed/image:{model}GETquery paramsRaw image bytesConvenient for embedding generated images in pages. This route is outside /v1.
POST /messagesPOSTAnthropic-style messages bodyAnthropic-compatible responseFor Anthropic-native clients.
POST https://api.rout.my/compatible/v1beta/models/{model}:generateContentPOSTGemini-style contentsGemini-compatible responseFor Gemini-compatible clients. This route is outside /v1; do not prepend the base URL above.

Compatibility Notes ​

Reserve quota resets ​

MethodEndpointAuthPurpose
GET/api/v1/user/quota-resetsUser JWTOwn reset balance, weekly allowance, and auto_reset_enabled
PUT/api/v1/user/quota-resetsUser JWTSave {auto_reset_enabled: boolean}; default is false; returns the saved flag
POST/api/v1/user/quota-resets/useUser JWTUse one available reset manually

Enabling automatic resets does not immediately spend a reset. When fewer than 100 daily tokens remain, the next quota-billed request uses one available reset and continues with the restored daily allowance. Weekly resets are used before gifted resets. Without an available reset, the usual quota error remains. Free models, Kimi fixed quota, reseller PAYG and trusted read-only requests do not consume automatic daily resets. The setting persists across daily/weekly resets.

Daily token transfers ​

MethodEndpointAuthPurpose
GET, POST/api/v1/user/token-transfersUser JWTRead own limits/history; send {recipient, amount, idempotency_key}
POST/api/v1/user/token-transfers/previewUser JWTPreview {recipient, amount} and confirm the exact recipient
PATCH/api/v1/user/token-transfers/preferencesUser JWTSet {receive_disabled}
GET, PUT/api/v1/admin/token-transfers/policyAdmin; CSRF for PUTRead/save policy with optimistic revision
GET/api/v1/admin/token-transfersAdminLatest 100 operations; optional user_id

Transfers refill spent daily tokens within the recipient's existing quota until 00:00 UTC. Sending/receiving and service-wide limits include pending operations and do not restart after quota resets. Received gifts cannot be forwarded that day. 202 means pending: retain the same payload and idempotency key when checking an uncertain outcome. The authenticated session selects the sender; an inference API key does not authorize these browser endpoints.

General ​

  • rout.my forwards model-specific fields when the selected provider supports them.
  • Unknown fields can be ignored or rejected depending on endpoint family and provider behavior.
  • For browser tools, keep keys user-supplied. Do not hardcode a shared key into public frontend code.
  • For retries, prefer exponential backoff on 429, 500, 502, and 503.

Routy support workspace ​

These endpoints use asynchronous jobs; they do not run an LLM inside the gateway. Request diagnosis checks the authenticated request owner in ClickHouse before creating a durable case. Stored request facts exclude raw payloads, provider mappings, credentials, IPs and upstream error bodies. A log that has not reached ClickHouse yet returns 404 and can be retried after analytics refreshes.

MethodPathAuthPurpose
GET, POST/api/v1/user/routy/casesUser JWTList own cases; create with {request_id, locale, question?}; reuse an open case for the same own request
GET/api/v1/user/routy/cases/{id}User JWT + ownerBounded transcript, request facts, structured card and published incident summary
POST/api/v1/user/routy/cases/{id}/messagesUser JWT + ownerAdd {content} and queue diagnosis or a private staff draft during handoff
POST/api/v1/user/routy/cases/{id}/{resolve,reopen,handoff,retry}User JWT + ownerResolve, reopen, request staff or retry a failed answer job
GET/api/v1/routy/casesAdminStaff workspace case list, cursor pagination
GET/api/v1/routy/cases/{id}AdminPrivate operator/bug drafts, case usage and transcript
POST/api/v1/routy/cases/{id}/{takeover,resume,resolve}Admin + CSRFPersistent staff hold and revision invalidation
POST/api/v1/routy/cases/{id}/messagesAdmin + CSRFExplicit reviewed in-app staff reply; dashboard cases only
POST/api/v1/routy/cases/{id}/{operator-draft,bug-draft}Admin + CSRFGenerate with {} or save reviewed {content}; no external publication
GET/api/v1/routy/incidentsAdminCandidate/confirmed incidents with independent affected-user and technical aggregates
POST/api/v1/routy/incidents/{id}Admin + CSRFUpdate {status?, public_summary?, publish?}; publication requires confirmed/resolved status and recorded technical corroboration
POST/api/v1/internal/support/routy/jobs/claimSUPPORT_BOT_TOKEN onlyClaim {limit:1..5, lease_seconds:30..300, worker_id}; max three attempts
POST/api/v1/internal/support/routy/jobs/{id}/completeSUPPORT_BOT_TOKEN + leaseCommit {lease_token, revision, content, card, evidence, usage, disposition}; stale answers are discarded, repeated results are idempotent
POST/api/v1/internal/support/routy/jobs/{id}/failSUPPORT_BOT_TOKEN + leaseBounded retry with {lease_token, error_code, retryable, usage?}
POST/api/v1/internal/support/routy/cases/discord/controlSUPPORT_BOT_TOKEN onlyRead fresh {staff_hold, case_id?, revision?} using {source_ref} immediately before Discord delivery; unknown channel returns false without creating state
POST/api/v1/internal/support/routy/cases/discordSUPPORT_BOT_TOKEN onlyUpsert scrubbed private Discord snapshot {source_ref, locale?, card?, staff_active?, messages}; source message IDs deduplicate intake; caller cannot assign an account owner

List responses are {cases, next_cursor?} and accept limit (1–100) and cursor. Detail responses are {case, messages, evidence, usage, history_truncated}. Message roles are user, assistant, staff; private drafts are not transcript messages. Case cards contain problem, facts, hypotheses, checks, missing, next_step, confidence. Facts preserve {field, value, evidence_ids, observed_at?, request_id?}; evidence references must accompany completion. Worker usage includes model_calls, tool_calls, input_tokens, output_tokens and nullable cost_usd; missing upstream prices remain unknown, not zero. User responses omit private drafts, account IDs and private incident aggregates. Staff takeover prevents an already running answer from publishing and persists across Discord snapshot refreshes until an explicit resume.

Request facts label coarse HTTP-only fallback text with error_detail_available: false and error_summary_source: "status_fallback". The client protocol stays empty when not known; upstream wire_profile is not a client endpoint.

API documentation for rout.my.