> ## Documentation Index
> Fetch the complete documentation index at: https://docs.anyfast.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Create Response

> Creates a model response using Doubao models. The `input` field accepts a plain string for simple text, or an array of message objects for multimodal content.

Multimodal content types: `input_text`, `input_image`, `input_video`, `input_file`.




## OpenAPI

````yaml api-reference/endpoints/openapi/doubao-responses/openapi.yaml POST /v1/responses
openapi: 3.1.0
info:
  title: ByteDance Doubao Compatible Endpoint — Responses
  description: Responses API compatible endpoint supporting Doubao models via Anyfast
  version: 1.0.0
servers:
  - url: https://www.anyfast.ai
security:
  - bearerAuth: []
paths:
  /v1/responses:
    post:
      summary: Create Response
      description: >
        Creates a model response using Doubao models. The `input` field accepts
        a plain string for simple text, or an array of message objects for
        multimodal content.


        Multimodal content types: `input_text`, `input_image`, `input_video`,
        `input_file`.
      operationId: createDoubaoResponse
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - model
                - input
              properties:
                model:
                  type: string
                  enum:
                    - doubao-seed-2.0-pro
                    - doubao-seed-2.0-code
                    - doubao-seed-2.0-lite
                    - doubao-seed-2.0-mini
                    - doubao-seed-1-8-251228
                    - doubao-seed-1-6-flash-250828
                    - doubao-seed-1-6-251015
                    - doubao-seed-1-6-lite-251015
                    - doubao-seed-1-6-vision-250815
                    - glm-4.7
                  description: The model to use.
                  example: doubao-seed-1-6-251015
                input:
                  type: array
                  description: >
                    Input messages. Each item has `role` and `content`. For
                    simple text you can also pass a plain string.


                    Content array item types:

                    - `input_text`: `{"type": "input_text", "text": "..."}`

                    - `input_image`: `{"type": "input_image", "image_url":
                    "https://..."}`

                    - `input_video`: `{"type": "input_video", "video_url":
                    "https://...", "fps": 1}`

                    - `input_file`: `{"type": "input_file", "file_url":
                    "https://..."}`
                  items:
                    type: object
                    required:
                      - role
                      - content
                    properties:
                      role:
                        type: string
                        enum:
                          - user
                          - assistant
                          - system
                        description: The role of the message author.
                        example: user
                      content:
                        type: array
                        description: Array of content parts.
                        items:
                          type: object
                          properties:
                            type:
                              type: string
                              enum:
                                - input_text
                                - input_image
                                - input_video
                                - input_file
                              description: Content part type.
                              example: input_text
                            text:
                              type: string
                              description: Text content (`input_text`).
                              example: What is in this image?
                            image_url:
                              type: string
                              description: Image URL or Base64 data URI (`input_image`).
                              example: https://example.com/photo.jpg
                            video_url:
                              type: string
                              description: Video URL or Base64 data URI (`input_video`).
                            fps:
                              type: number
                              minimum: 0.2
                              maximum: 5
                              default: 1
                              description: >-
                                Frame extraction rate for video (`input_video`).
                                Default: `1`.
                            file_url:
                              type: string
                              description: Document URL (`input_file`).
                            file_data:
                              type: string
                              description: Base64-encoded document data URI (`input_file`).
                            filename:
                              type: string
                              description: Filename, required with `file_data`.
                  example:
                    - role: user
                      content:
                        - type: input_image
                          image_url: >-
                            https://ark-project.tos-cn-beijing.volces.com/doc_image/ark_demo_img_1.png
                        - type: input_text
                          text: What is in this image?
                stream:
                  type: boolean
                  default: false
                  description: If true, stream partial response deltas using SSE.
                temperature:
                  type: number
                  minimum: 0
                  maximum: 2
                  default: 1
                  description: Sampling temperature.
                  example: 1
                top_p:
                  type: number
                  minimum: 0
                  maximum: 1
                  description: Nucleus sampling threshold.
                max_output_tokens:
                  type: integer
                  minimum: 1
                  description: Maximum number of output tokens.
                reasoning:
                  type: object
                  description: 'Configuration for reasoning. Example: `{"effort": "high"}`.'
                  properties:
                    effort:
                      type: string
                      enum:
                        - minimal
                        - low
                        - medium
                        - high
                      description: Reasoning effort level. Default is medium.
      responses:
        '200':
          description: Response generated successfully
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ResponseObject'
        '400':
          description: Invalid request
        '401':
          description: Unauthorized
        '429':
          description: Rate limit exceeded
components:
  schemas:
    ResponseObject:
      type: object
      properties:
        id:
          type: string
          example: resp_021774236829912
        object:
          type: string
          example: response
        created_at:
          type: integer
        completed_at:
          type: integer
        model:
          type: string
          example: doubao-seed-1-6-251015
        status:
          type: string
          enum:
            - completed
            - failed
            - in_progress
            - incomplete
          example: completed
        output:
          type: array
          items:
            type: object
            properties:
              type:
                type: string
                example: message
              role:
                type: string
                example: assistant
              status:
                type: string
                example: completed
              content:
                type: array
                items:
                  type: object
                  properties:
                    type:
                      type: string
                      example: output_text
                    text:
                      type: string
                      example: >-
                        The image contains 3 models: Doubao-Seed-1.8,
                        DeepSeek-V3.2, GLM-4.7.
        usage:
          type: object
          properties:
            input_tokens:
              type: integer
              example: 1355
            output_tokens:
              type: integer
              example: 87
            total_tokens:
              type: integer
              example: 1442
            output_tokens_details:
              type: object
              properties:
                reasoning_tokens:
                  type: integer
                  example: 53
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````