# "Tạo tác vụ flux-kontext-apps/multi-image-kontext-max"

Nguồn: https://docs.openaihub.net/api-45208959/

> API origin: `https://api.openaihub.net`. Chọn đúng nhóm API và model. Thông số dưới đây là bản tham chiếu kỹ thuật; chưa phải kết quả kiểm thử từng endpoint bằng tài khoản của bạn.


## OpenAPI Specification

```yaml
openapi: 3.0.1
info:
  title: ''
  description: ''
  version: 1.0.0
paths:
  /replicate/v1/models/flux-kontext-apps/multi-image-kontext-max/predictions:
    post:
      summary: Tạo tác vụ flux-kontext-apps/multi-image-kontext-max
      deprecated: false
      description: >-
        Tài liệu chính thức:
        https://replicate.com/flux-kontext-apps/multi-image-kontext-max
      operationId: >-
        replicate_replicate_v1_models_flux_kontext_apps_multi_image_kontext_max_predictions
      tags:
        - OpenAiHub Việt Nam/OpenAiHub Tiếng Việt/Hình ảnh/Tổng hợp bản sao
        - Tái tạo
      parameters:
        - name: Authorization
          in: header
          description: Khóa API Bearer
          required: false
          example: Bearer {{YOUR_API_KEY}}
          schema:
            type: string
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                input:
                  type: object
                  required:
                    - prompt
                    - input_image_1
                    - input_image_2
                  properties:
                    aspect_ratio:
                      type: string
                      description: >-
                        Tỷ lệ khung hình của hình ảnh được tạo. Dùng
                        "match_input_image" để khớp với tỷ lệ khung hình của
                        hình ảnh đầu vào. Mặc định: "match_input_image"
                    input_image_1:
                      type: string
                      description: >-
                        Hình ảnh đầu vào đầu tiên. Phải ở định dạng jpeg, png,
                        gif hoặc webp.
                    input_image_2:
                      type: string
                      description: >-
                        Hình ảnh đầu vào thứ hai. Phải ở định dạng jpeg, png,
                        gif hoặc webp.
                    output_format:
                      type: string
                      description: >-
                        Định dạng đầu ra của hình ảnh được tạo. Giá trị mặc
                        định: "png".
                    prompt:
                      type: string
                      description: >-
                        Mô tả bằng văn bản về cách kết hợp hoặc biến đổi hai
                        hình ảnh đầu vào.
                    safety_tolerance:
                      type: integer
                      description: >-
                        Mức dung sai bảo mật, 0 là nghiêm ngặt nhất và 2 là lỏng
                        nhất. Hiện tại, 2 là mức tối đa được phép. Giá trị mặc
                        định: 2
                  description: Vui lòng cung cấp nội dung tài liệu cần dịch.
                  x-apifox-orders:
                    - aspect_ratio
                    - input_image_1
                    - input_image_2
                    - output_format
                    - prompt
                    - safety_tolerance
                  x-apidog-orders:
                    - aspect_ratio
                    - input_image_1
                    - input_image_2
                    - output_format
                    - prompt
                    - safety_tolerance
              x-apifox-orders:
                - input
              x-apidog-orders:
                - input
            examples:
              flux_kontext_appsmulti_image_kontext_max_single:
                value:
                  input:
                    aspect_ratio: '1:1'
                    input_image_1: >-
                      Vui lòng tải trực tiếp ảnh lên cuộc trò chuyện để tôi có
                      thể đọc và dịch nội dung, đồng thời giữ nguyên Markdown,
                      mã nguồn, định danh, URL, đường dẫn, chỗ giữ chỗ, cấu trúc
                      JSON và định dạng.
                    input_image_2: >-
                      https://replicate.delivery/pbxt/N5rSdTCgBqIRvbkedcfLfS5xTSEEOqMtX9FsR1hLK9JYryml/0_1.webp
                    output_format: png
                    prompt: Cho người phụ nữ mặc áo thun trắng có dòng chữ trên đó
                    safety_tolerance: 2
                summary: flux_kontext_appsmulti_image_kontext_max_single
                description: Tạo tác vụ flux-kontext-apps/multi-image-kontext-max
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
                required:
                  - id
                  - status
                properties:
                  created_at:
                    type: string
                    description: Thời gian tạo
                  data_removed:
                    type: boolean
                    description: Liệu dữ liệu nhạy cảm đã được loại bỏ hay chưa
                  error:
                    type: string
                    description: Thông báo lỗi
                    nullable: true
                  id:
                    type: string
                    description: ID tài nguyên hoặc tác vụ
                  input:
                    type: object
                    required:
                      - aspect_ratio
                      - input_image_1
                      - input_image_2
                      - output_format
                      - prompt
                      - safety_tolerance
                    properties:
                      aspect_ratio:
                        type: string
                        description: 'Tỷ lệ khung hình, ví dụ: 16:9, 9:16, 1:1'
                      input_image_1:
                        type: string
                        description: Hình ảnh đầu vào 1 (URL hoặc Base64)
                      input_image_2:
                        type: string
                        description: Hình ảnh đầu vào 2 (URL hoặc Base64)
                      output_format:
                        type: string
                        description: 'Định dạng đầu ra, ví dụ: png / jpeg / webp'
                      prompt:
                        type: string
                        description: Lời nhắc văn bản
                      safety_tolerance:
                        type: integer
                        description: Mức dung sai của bộ lọc an toàn
                    description: Vui lòng cung cấp nội dung tài liệu cần dịch.
                    x-apifox-orders:
                      - aspect_ratio
                      - input_image_1
                      - input_image_2
                      - output_format
                      - prompt
                      - safety_tolerance
                    x-apidog-orders:
                      - aspect_ratio
                      - input_image_1
                      - input_image_2
                      - output_format
                      - prompt
                      - safety_tolerance
                  logs:
                    type: string
                    description: Nhật ký chạy
                  model:
                    type: string
                    description: Tên mô hình / mã định danh mô hình
                  output:
                    type: string
                    description: Kết quả đầu ra
                    nullable: true
                  status:
                    type: string
                    description: Trạng thái
                  urls:
                    type: object
                    required:
                      - cancel
                      - get
                      - stream
                      - web
                    properties:
                      cancel:
                        type: string
                        description: URL để hủy tác vụ
                      get:
                        type: string
                        description: URL để truy vấn trạng thái tác vụ
                      stream:
                        type: string
                        description: Có truyền phát phản hồi hay không
                      web:
                        type: string
                        description: URL để xem tác vụ trong trình duyệt
                    description: Danh sách URL tài nguyên
                    x-apifox-orders:
                      - cancel
                      - get
                      - stream
                      - web
                    x-apidog-orders:
                      - cancel
                      - get
                      - stream
                      - web
                  version:
                    type: string
                    description: Phiên bản
                refName: >-
                  PostReplicateV1ModelsFluxKontextAppsMultiImageKontextMaxPredictionsResponse
                x-apifox-orders:
                  - created_at
                  - data_removed
                  - error
                  - id
                  - input
                  - logs
                  - model
                  - output
                  - status
                  - urls
                  - version
                x-apidog-orders:
                  - created_at
                  - data_removed
                  - error
                  - id
                  - input
                  - logs
                  - model
                  - output
                  - status
                  - urls
                  - version
              examples:
                example:
                  summary: example
                  value:
                    created_at: '2025-07-30T02:08:26.368Z'
                    data_removed: false
                    id: b6k38vmb01rme0crb4bbr2apw4
                    input:
                      aspect_ratio: '1:1'
                      input_image_1: >-
                        Vui lòng tải trực tiếp ảnh lên cuộc trò chuyện để tôi có
                        thể đọc và dịch nội dung, đồng thời giữ nguyên Markdown,
                        mã nguồn, định danh, URL, đường dẫn, chỗ giữ chỗ, cấu
                        trúc JSON và định dạng.
                      input_image_2: >-
                        https://replicate.delivery/pbxt/N5rSdTCgBqIRvbkedcfLfS5xTSEEOqMtX9FsR1hLK9JYryml/0_1.webp
                      output_format: png
                      prompt: Cho người phụ nữ mặc áo thun trắng có dòng chữ trên đó
                      safety_tolerance: 2
                    logs: ''
                    model: flux-kontext-apps/multi-image-kontext-max
                    status: starting
                    urls:
                      cancel: >-
                        https://api.replicate.com/v1/predictions/b6k38vmb01rme0crb4bbr2apw4/cancel
                      get: >-
                        Vui lòng dán nội dung tài liệu cần dịch; tôi không thể
                        truy cập trực tiếp URL API này.
                      stream: >-
                        https://stream.replicate.com/v1/files/bcwr-4lncowbqyyr5toyxguv6tr47ffpade3muguvemzik5let3hnlryq
                      web: >-
                        Vui lòng dán nội dung tài liệu cần dịch vào đây; tôi
                        không thể truy cập trực tiếp nội dung từ đường dẫn này.
                    version: ẩn
          headers: {}
          x-apidog-name: ''
        '400':
          description: Yêu cầu không hợp lệ hoặc xác thực thất bại
          content:
            application/json:
              schema:
                type: object
                required:
                  - error
                properties:
                  error:
                    type: object
                    required:
                      - message
                      - type
                    properties:
                      message:
                        type: string
                        description: Thông báo lỗi (thường kết thúc bằng mã yêu cầu)
                      type:
                        type: string
                        description: Loại lỗi; các lỗi cổng cục bộ thường là new_api_error
                        examples:
                          - new_api_error
                    x-apifox-orders:
                      - message
                      - type
                    x-apidog-orders:
                      - message
                      - type
                refName: NewApiError
                x-apifox-orders:
                  - error
                x-apidog-orders:
                  - error
              examples:
                example:
                  summary: example
                  value:
                    error:
                      message: >-
                        Yêu cầu không hợp lệ (mã yêu cầu:
                        20260805120000123456789AbCdEfGh)
                      type: new_api_error
          headers: {}
          x-apidog-name: Yêu cầu không hợp lệ hoặc xác thực thất bại
        '401':
          description: Khóa API bị thiếu hoặc không hợp lệ
          content:
            application/json:
              schema:
                type: object
                required:
                  - error
                properties:
                  error:
                    type: object
                    required:
                      - message
                      - type
                    properties:
                      message:
                        type: string
                        description: Thông báo lỗi (thường kết thúc bằng mã yêu cầu)
                      type:
                        type: string
                        description: Loại lỗi; các lỗi cổng cục bộ thường là new_api_error
                        examples:
                          - new_api_error
                    x-apifox-orders:
                      - message
                      - type
                    x-apidog-orders:
                      - message
                      - type
                refName: NewApiError
                x-apifox-orders:
                  - error
                x-apidog-orders:
                  - error
              examples:
                example:
                  summary: example
                  value:
                    error:
                      message: >-
                        Mã thông báo không hợp lệ (request id:
                        20260805120000123456789AbCdEfGh)
                      type: new_api_error
          headers: {}
          x-apidog-name: Khóa API bị thiếu hoặc không hợp lệ
      security: []
      x-apidog-folder: OpenAiHub Việt Nam/OpenAiHub Tiếng Việt/Hình ảnh/Tổng hợp bản sao
      x-apidog-status: released
      x-run-in-apidog: https://app.apidog.com/web/project/1218648/apis/api-45208959-run
components:
  schemas: {}
  securitySchemes: {}
servers:
  - url: https://api.openaihub.net
    description: Prod Env
security: []

```
