English
  • 中文
  • English
English
  • 中文
  • English
官网
服务状态
English
  • 中文
  • English
    • Quickstart & Conventions
    • Images
      • GPT Image 2 / 2.5 / 2.6 Generation & Editing
      • Nano Banana Image Generation
      • Gemini Native Sync Image Generation
      • Seedream 5.0 Pro / 5.5 Image Generation
      • Midjourney Image Generation
    • Videos
      • Seedance 2 Video Generation
      • Omni Video Generation
      • Seedance 2.5 Video Generation
      • MiniMax H3 Video Generation
      • WAN 3.0 Video Generation
      • Muse Video Generation
      • Seedance Asset Registration
      • Gemini Omni 1.2 Flash Video Generation
      • Seedance Volcengine Native Video Generation
      • MAGI-2 Video Generation
    • Text Models
      • Claude Desktop (CC Switch) Setup Guide
      • Codex in ChatGPT Desktop Setup Guide
      • Gemini Text Models (Native Format)
      • Text & Chat APIs (OpenAI / Claude)
    • Audio
      • Gemini Text-to-Speech (TTS)

    Quickstart & Conventions

    LLM-friendly index: https://docs.brioi.com/english/llms.txt — pass this URL directly to AI coding assistants and agents.
    Brioi provides a unified API for text, image, video, and text-to-speech (TTS) generation. Before integrating, query the live model list with your API key to verify model availability.
    This page covers conventions shared across all endpoints. Where a model-specific guide differs from this page, the model-specific guide takes precedence.

    Getting Started#

    Base origin: https://vip.brioi.com
    Default authentication header: Authorization: Bearer YOUR_API_KEY
    Default content type: application/json (except multipart file-upload endpoints)
    Live model list: GET /v1/models
    Never expose your API key in client-side code, public repositories, or logs.

    Base URL by SDK & Client#

    Different SDKs automatically append their own path prefixes. Configure the exact Base URL shown below to avoid double-prefixing /v1/v1 and triggering 404 errors:
    Integration / ClientBase URLAuthentication
    Official OpenAI SDK / OpenAI-compatible clients / Codexhttps://vip.brioi.com/v1Authorization: Bearer YOUR_API_KEY
    Official Anthropic SDK / Claude Code / CC Switch (Claude)https://vip.brioi.com (omit /v1)x-api-key: YOUR_API_KEY or Bearer
    Google Gen AI SDK / Gemini CLIhttps://vip.brioi.com (omit /v1beta)x-goog-api-key: YOUR_API_KEY or Bearer
    Raw HTTP / cURLhttps://vip.brioi.com + full endpoint pathAs specified in each model guide

    API Key Groups & Model Visibility#

    The model value in every request must appear in the live GET /v1/models response for that API key (except Midjourney Image Generation, where operations are routed via /mj/* paths without a model field).
    When creating an API key, we recommend selecting the auto group by default—it covers mainstream text, general image/video, and Seedance per-second and Volcengine-native models. Models in dedicated groups require a key assigned to that group, such as Kimi, GLM, Grok, or Claude|对话 (chat-only Claude group); check the Model Marketplace and API Keys pages in the vip.brioi.com console for exact coverage.
    GET /v1/models returns text, image, video, and TTS models together. Image, video, and TTS models cannot be called via /v1/chat/completions—always use the dedicated endpoint documented for each model. Selecting non-text models in a standard chat client will fail.
    Send only the fields documented for the target model. Do not pass chat fields such as messages, temperature, top_p, or stream to image or video endpoints.

    Asynchronous Tasks#

    Asynchronous task paths and status enums are scoped by endpoint protocol. Task IDs cannot be mixed across protocols (for example, polling an image task ID at /v1/videos/{task_id} returns an error).
    Async Image API (/v1/images/async/*) and Unified Video API (/v1/videos) follow the two tables below.
    Seedance Volcengine Native Video Generation (/api/v3/contents/generations/tasks), Midjourney Image Generation (/mj/*), and Seedance Asset Registration (/v1/realperson) each use independent native task paths and status values—see their respective guides.

    Async Image Tasks (/v1/images/async/*)#

    ItemConvention
    Task IDtask_id from the creation response
    In progressSUBMITTED, IN_PROGRESS — continue polling
    SucceededSUCCESS — read images[].url
    FailedFAILURE — read fail_reason
    Poll interval3–5 seconds

    Video Tasks (/v1/videos)#

    ItemConvention
    Task IDid from the creation response, passed as {task_id} in the polling URL. Some responses also echo an identical task_id field for backward compatibility only.
    In progressqueued, in_progress — continue polling
    Succeededcompleted — read metadata.url
    Failedfailed — read error.code and error.message
    Poll interval5–10 seconds (unless a model guide specifies otherwise)
    Auxiliary fields in video polling responses vary by model. Clients should depend only on id, status, metadata.url, and error; fields such as object, model, progress, and seconds may be omitted. Some responses also include result_url with the same value as metadata.url, which can be used as a fallback. Treat any status value not listed above as in-progress and continue polling.

    Polling & Retries#

    Receiving HTTP 200, a task ID, or a non-terminal status from a creation endpoint means only that the task has entered the processing pipeline—not that media generation has completed.
    On a single poll timeout or transient 5xx error, retry polling with the same task ID rather than creating a new task.
    If the creation request itself times out or returns 5xx, verify whether the task was created before submitting a duplicate request.
    Do not treat a success status with an empty result URL as a deliverable completion; retain the task ID and raw response payload for troubleshooting.

    Input Media & Result URLs#

    Unless a model guide states otherwise, input assets must be publicly accessible direct HTTPS URLs that serve the raw media file without login, cookies, or custom headers.
    MIME types, file sizes, resolutions, durations, and asset counts must comply with the target model guide.
    Pre-signed input URLs must remain valid for the entire duration of task processing.
    Generated result URLs expire, after which polling responses may omit them. Download or copy output files to your own storage immediately once a task succeeds.

    Error Handling#

    HTTP StatusMeaning
    400Invalid request parameters or malformed JSON; also returned when a video task does not exist (code is task_not_exist)
    401Missing or invalid API key
    403Insufficient balance or key quota, or the API key lacks group/model permission
    404Async image task not found, or malformed URL path (such as duplicate /v1/v1)
    429Rate limit exceeded
    503Service temporarily unavailable
    500, 502Transient server or upstream error
    Synchronous endpoints and task creation requests typically return errors in this format:
    {
      "error": {
        "code": "error_code",
        "message": "Error description (request id: 2026xxxxxxxxxxxxxxxx)",
        "type": "new_api_error"
      }
    }
    Video task polling endpoints use the following error envelope:
    {
      "code": "task_not_exist",
      "message": "task_not_exist",
      "data": null
    }
    Every response includes the X-Oneapi-Request-Id header, and most error message strings append the same request ID. Record the request ID, task ID, and error message when troubleshooting—never log API keys or full sensitive media URLs.
    Modified at 2026-12-04 09:01:17
    Next
    GPT Image 2 / 2.5 / 2.6 Generation & Editing
    Built with