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

# Download a Douyin video as MP4

> Use this operation to download the media of one public Douyin (抖音) video as an MP4 file link with normalized video metadata. Accepts douyin.com video URLs, iesdouyin share links, v.douyin.com short links, and bare numeric video IDs.



## OpenAPI

````yaml /api-reference/openapi.json post /v1/douyin/video/download
openapi: 3.1.0
info:
  description: >-
    Direct authenticated APIs for public social data, people data, transcripts,
    documents, text, and SEO. Send an API key as a Bearer token. Responses never
    include provider credentials or raw provider payloads.
  license:
    name: Proprietary
    url: https://agentbody.io
  title: AgentBody API
  version: '2026-09-15'
servers:
  - url: https://api.agentbody.io
security:
  - bearerAuth: []
paths:
  /v1/douyin/video/download:
    post:
      tags:
        - douyin
      summary: Download a Douyin video as MP4
      description: >-
        Use this operation to download the media of one public Douyin (抖音) video
        as an MP4 file link with normalized video metadata. Accepts douyin.com
        video URLs, iesdouyin share links, v.douyin.com short links, and bare
        numeric video IDs.
      operationId: post_v1_douyin_video_download
      parameters:
        - $ref: '#/components/parameters/IdempotencyKey'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DouyinVideoDownloadRequest'
        required: true
      responses:
        '200':
          $ref: '#/components/responses/DouyinVideoDownloadSuccess'
        '400':
          content:
            application/json:
              example:
                error:
                  code: INVALID_ARGUMENT
                  message: example error
              schema:
                additionalProperties: false
                properties:
                  error:
                    additionalProperties: false
                    properties:
                      code:
                        const: INVALID_ARGUMENT
                        type: string
                      message:
                        type: string
                    required:
                      - code
                      - message
                    type: object
                required:
                  - error
                type: object
          description: Correct the input; do not retry unchanged.
          headers:
            X-Request-Id:
              description: Gateway request identifier for support and audit.
              schema:
                format: uuid
                type: string
        '401':
          content:
            application/json:
              example:
                error:
                  code: UNAUTHENTICATED
                  message: example error
              schema:
                additionalProperties: false
                properties:
                  error:
                    additionalProperties: false
                    properties:
                      code:
                        const: UNAUTHENTICATED
                        type: string
                      message:
                        type: string
                    required:
                      - code
                      - message
                    type: object
                required:
                  - error
                type: object
          description: Configure a valid API key; do not retry unchanged.
          headers:
            X-Request-Id:
              description: Gateway request identifier for support and audit.
              schema:
                format: uuid
                type: string
        '409':
          content:
            application/json:
              example:
                error:
                  code: CONFLICT
                  message: example error
              schema:
                additionalProperties: false
                properties:
                  error:
                    additionalProperties: false
                    properties:
                      code:
                        const: CONFLICT
                        type: string
                      message:
                        type: string
                    required:
                      - code
                      - message
                    type: object
                required:
                  - error
                type: object
          description: Follow the documented Idempotency-Key behavior before retrying.
          headers:
            X-Request-Id:
              description: Gateway request identifier for support and audit.
              schema:
                format: uuid
                type: string
        '502':
          content:
            application/json:
              example:
                error:
                  code: UPSTREAM_INVALID_RESPONSE
                  message: example error
              schema:
                additionalProperties: false
                properties:
                  error:
                    additionalProperties: false
                    properties:
                      code:
                        const: UPSTREAM_INVALID_RESPONSE
                        type: string
                      message:
                        type: string
                    required:
                      - code
                      - message
                    type: object
                required:
                  - error
                type: object
          description: Retry with backoff, then report temporary unavailability.
          headers:
            X-Request-Id:
              description: Gateway request identifier for support and audit.
              schema:
                format: uuid
                type: string
        '503':
          content:
            application/json:
              example:
                error:
                  code: UPSTREAM_UNAVAILABLE
                  message: example error
              schema:
                additionalProperties: false
                properties:
                  error:
                    additionalProperties: false
                    properties:
                      code:
                        const: UPSTREAM_UNAVAILABLE
                        type: string
                      message:
                        type: string
                    required:
                      - code
                      - message
                    type: object
                required:
                  - error
                type: object
          description: Retry with backoff, then report temporary unavailability.
          headers:
            X-Request-Id:
              description: Gateway request identifier for support and audit.
              schema:
                format: uuid
                type: string
        '504':
          content:
            application/json:
              example:
                error:
                  code: UPSTREAM_TIMEOUT
                  message: example error
              schema:
                additionalProperties: false
                properties:
                  error:
                    additionalProperties: false
                    properties:
                      code:
                        const: UPSTREAM_TIMEOUT
                        type: string
                      message:
                        type: string
                    required:
                      - code
                      - message
                    type: object
                required:
                  - error
                type: object
          description: Retry with backoff, then report temporary unavailability.
          headers:
            X-Request-Id:
              description: Gateway request identifier for support and audit.
              schema:
                format: uuid
                type: string
components:
  parameters:
    IdempotencyKey:
      description: Optional key for safely retrying a billable write request.
      example: request-20260819-001
      in: header
      name: Idempotency-Key
      required: false
      schema:
        maxLength: 255
        minLength: 1
        type: string
  schemas:
    DouyinVideoDownloadRequest:
      additionalProperties: false
      properties:
        url:
          description: >-
            Public Douyin video URL (douyin.com video, iesdouyin share, or
            v.douyin.com short link) or bare numeric video ID.
          type: string
      required:
        - url
      type: object
    DouyinVideoDownloadResult:
      additionalProperties: false
      properties:
        author_name:
          type: string
        author_verified:
          type: boolean
        collect_count:
          format: int64
          type: integer
        comment_count:
          format: int64
          type: integer
        digg_count:
          format: int64
          type: integer
        duration_seconds:
          type: number
        id:
          type: string
        share_count:
          format: int64
          type: integer
        text:
          type: string
        title:
          type: string
        url:
          format: uri
          type: string
        video_content_type:
          type: string
        video_size_bytes:
          format: int64
          type: integer
        video_url:
          format: uri
          type: string
      required:
        - id
        - url
        - video_url
        - video_content_type
      type: object
  responses:
    DouyinVideoDownloadSuccess:
      content:
        application/json:
          example:
            author_name: 盗月社食遇记
            collect_count: 855021
            comment_count: 162235
            digg_count: 4037193
            duration_seconds: 1082.5
            id: '7577614489533680959'
            share_count: 5135670
            text: 这个贵州五线小城市…
            title: 贵州美食探店
            url: https://www.douyin.com/video/7577614489533680959
            video_content_type: video/mp4
            video_size_bytes: 215476832
            video_url: >-
              https://api.apify.com/v2/key-value-stores/example/records/7577614489533680959.mp4
          schema:
            $ref: '#/components/schemas/DouyinVideoDownloadResult'
      description: Downloaded Douyin media link and normalized public video metadata.
      headers:
        X-Request-Id:
          description: Gateway request identifier for support and audit.
          schema:
            format: uuid
            type: string
  securitySchemes:
    bearerAuth:
      scheme: bearer
      type: http

````