Perfect Corp V3.0 API

AI Avatar Generator API allows you to generate avatars from a source image using predefined templates and output count settings.

Operations 8

GET /s2s/v2.0/task/template/ai-avatar List predefined templates #
POST /s2s/v2.0/task/ai-avatar Run an AI Avatar task #
GET /s2s/v2.0/task/ai-avatar/{task_id} Check the status of the AI Avatar task #
POST /s2s/v2.0/task/cloth-v3 Run an AI Cloth V3 task #
GET /s2s/v2.0/task/cloth-v3/{task_id} Check the status of a AI Cloth V3 task #
GET /s2s/v2.0/task/template/ai-studio List predefined templates #
POST /s2s/v2.0/task/ai-studio Run an AI Studio task #
GET /s2s/v2.0/task/ai-studio/{task_id} Check the status of the AI Studio task #

Documentation

Specifications

Other Resources

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/perfect-corp-v3-0-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

perfect-corp-v3-0-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Perfect Corp V3.0 API
  version: ''
  contact:
    email: YouCamOnlineEditor_API@perfectcorp.com
  license:
    name: Privacy policy
    url: https://www.makeupar.com/perfectbeauty/youcam/privacy-policy-api
  termsOfService: https://www.makeupar.com/perfectbeauty/youcam/terms-of-service-api
  description: 'Operations tagged V3.0 across 3 of this provider''s published API definitions: perfect-corp-ai_avatar_generator-openapi.yml, perfect-corp-ai_clothes-openapi.yml, perfect-corp-ai_studio_generator-openapi.yml. Each path carries the servers of the definition it was published in.'
servers:
- url: https://yce-api-01.makeupar.com
tags:
- name: V3 0
  description: AI Avatar Generator API allows you to generate avatars from a source image using predefined templates and output count settings.
paths:
  /s2s/v2.0/task/template/ai-avatar:
    get:
      summary: List predefined templates
      tags:
      - V3 0
      security:
      - BearerAuthenticationV2: []
      parameters:
      - name: page_size
        in: query
        schema:
          type: integer
          example: 20
        description: Number of results to return in this page. Valid value should be between 1 and 20. Default 20.
      - name: starting_token
        in: query
        schema:
          type: string
          example: 73a3c9e69b89
        description: Token for current page. Start with `null` for the first page, and use `next_token` from the previous response to start next page
      responses:
        '200':
          $ref: '#/components/responses/TemplateResponse'
        '400':
          $ref: '#/components/responses/InvalidParameters'
        '401':
          $ref: '#/components/responses/InvalidApiKey'
      operationId: getS2sV20TaskTemplateAiAvatar
      x-operation-id-source: derived
    servers:
    - url: https://yce-api-01.makeupar.com
  /s2s/v2.0/task/ai-avatar:
    post:
      summary: Run an AI Avatar task
      description: 'AI tasks are asynchronous. Prefer webhook-based completion handling when the feature supports webhooks. Configure your webhook endpoint, verify webhook signatures, and use the received `task_id` to query the task result after a `success` or `error` notification. See the webhook integration guide for setup and verification details.


        If webhooks are not supported for the feature, or if your integration cannot use webhooks, implement polling. After starting an AI task, keep polling the task status endpoint at the given `polling_interval` until the task status is either `success` or `error`.


        Do not stop polling a running task for longer than the allowed polling window. If the task is not polled in time, the task may expire; a later status check can return `InvalidTaskId` even if processing finished, and the consumed units may still be charged.'
      tags:
      - V3 0
      security:
      - BearerAuthenticationV2: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              allOf:
              - $ref: '#/components/schemas/RunWithSingleTemplateAndSrcUrl'
              - $ref: '#/components/schemas/RunWithOutputCntCustom200'
      responses:
        '200':
          description: Successful execution of the task
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BasicRunTaskResponseV2'
        '400':
          description: Failed execution of task
          content:
            application/json:
              schema:
                allOf:
                - $ref: '#/components/schemas/RunError'
        '401':
          $ref: '#/components/responses/InvalidApiKey'
        '429':
          $ref: '#/components/responses/TooManyRequests'
      operationId: postS2sV20TaskAiAvatar
      x-operation-id-source: derived
    servers:
    - url: https://yce-api-01.makeupar.com
  /s2s/v2.0/task/ai-avatar/{task_id}:
    get:
      summary: Check the status of the AI Avatar task
      tags:
      - V3 0
      security:
      - BearerAuthenticationV2: []
      parameters:
      - name: task_id
        in: path
        required: true
        schema:
          type: string
          example: grH0CvsgXuAIHLUzD0V1Ol34hoet3R1tvdbtiVHrDb6_UqCLKIejAIajwxrhOAfe
        description: ID of task to check
      responses:
        '200':
          description: Successful check of the task status
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TaskStatusResponseMultiResV2'
        '400':
          $ref: '#/components/responses/InvalidTaskId'
        '401':
          $ref: '#/components/responses/InvalidApiKey'
        '500':
          $ref: '#/components/responses/TaskTimeout'
      operationId: getS2sV20TaskAiAvatarByTaskId
      x-operation-id-source: derived
    servers:
    - url: https://yce-api-01.makeupar.com
  /s2s/v2.0/task/cloth-v3:
    post:
      summary: Run an AI Cloth V3 task
      description: 'AI tasks are asynchronous. Prefer webhook-based completion handling when the feature supports webhooks. Configure your webhook endpoint, verify webhook signatures, and use the received `task_id` to query the task result after a `success` or `error` notification. See the webhook integration guide for setup and verification details.


        If webhooks are not supported for the feature, or if your integration cannot use webhooks, implement polling. After starting an AI task, keep polling the task status endpoint at the given `polling_interval` until the task status is either `success` or `error`.


        Do not stop polling a running task for longer than the allowed polling window. If the task is not polled in time, the task may expire; a later status check can return `InvalidTaskId` even if processing finished, and the consumed units may still be charged.'
      tags:
      - V3 0
      security:
      - BearerAuthenticationV2: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              allOf:
              - $ref: '#/components/schemas/RunClothV3Task'
      responses:
        '200':
          description: Successful execution of the task
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BasicRunTaskResponseV2'
        '400':
          description: Failed execution of task
          content:
            application/json:
              schema:
                allOf:
                - $ref: '#/components/schemas/RunError'
        '401':
          $ref: '#/components/responses/InvalidApiKey'
        '429':
          $ref: '#/components/responses/TooManyRequests'
      operationId: postS2sV20TaskClothV3
      x-operation-id-source: derived
    servers:
    - url: https://yce-api-01.makeupar.com
  /s2s/v2.0/task/cloth-v3/{task_id}:
    get:
      summary: Check the status of a AI Cloth V3 task
      tags:
      - V3 0
      security:
      - BearerAuthenticationV2: []
      parameters:
      - name: task_id
        in: path
        required: true
        schema:
          type: string
          example: grH0CvsgXuAIHLUzD0V1Ol34hoet3R1tvdbtiVHrDb6_UqCLKIejAIajwxrhOAfe
        description: ID of task to check
      responses:
        '200':
          description: Successful check of the task status
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TaskStatusResponseV2'
        '400':
          $ref: '#/components/responses/InvalidTaskId'
        '401':
          $ref: '#/components/responses/InvalidApiKey'
        '500':
          $ref: '#/components/responses/TaskTimeout'
      operationId: getS2sV20TaskClothV3ByTaskId
      x-operation-id-source: derived
    servers:
    - url: https://yce-api-01.makeupar.com
  /s2s/v2.0/task/template/ai-studio:
    get:
      summary: List predefined templates
      tags:
      - V3 0
      security:
      - BearerAuthenticationV2: []
      parameters:
      - name: page_size
        in: query
        schema:
          type: integer
          example: 20
        description: Number of results to return in this page. Valid value should be between 1 and 20. Default 20.
      - name: starting_token
        in: query
        schema:
          type: string
          example: 73a3c9e69b89
        description: Token for current page. Start with `null` for the first page, and use `next_token` from the previous response to start next page
      responses:
        '200':
          description: Successful retrieval of styles
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TemplateResponseSchema'
        '400':
          description: Invalid request parameters
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InvalidParametersSchema'
        '401':
          description: Invalid API Key or Inactive API Key or Expired API Key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InvalidApiKeySchema'
      operationId: getS2sV20TaskTemplateAiStudio
      x-operation-id-source: derived
    servers:
    - url: https://yce-api-01.makeupar.com
  /s2s/v2.0/task/ai-studio:
    post:
      summary: Run an AI Studio task
      description: Please refer to the polling guide for checking task status. Requires a source image, template ID, and output count configuration.
      tags:
      - V3 0
      security:
      - BearerAuthenticationV2: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              allOf:
              - $ref: '#/components/schemas/RunWithSingleTemplateAndSrcUrl'
              - $ref: '#/components/schemas/RunWithOutputCntCustom200'
      responses:
        '200':
          description: Successful execution of the task
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/BasicRunTaskResponseV2'
        '400':
          description: Failed execution of task
          content:
            application/json:
              schema:
                allOf:
                - $ref: '#/components/schemas/RunErrorSchema'
        '401':
          description: Invalid API Key or Inactive API Key or Expired API Key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InvalidApiKeySchema'
        '429':
          description: Too many requests within a given amount of time
          content:
            application/json:
              schema:
                type: object
      operationId: postS2sV20TaskAiStudio
      x-operation-id-source: derived
    servers:
    - url: https://yce-api-01.makeupar.com
  /s2s/v2.0/task/ai-studio/{task_id}:
    get:
      summary: Check the status of the AI Studio task
      tags:
      - V3 0
      security:
      - BearerAuthenticationV2: []
      parameters:
      - name: task_id
        in: path
        required: true
        schema:
          type: string
          example: grH0CvsgXuAIHLUzD0V1Ol34hoet3R1tvdbtiVHrDb6_UqCLKIejAIajwxrhOAfe
        description: ID of task to check
      responses:
        '200':
          description: Successful check of the task status
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TaskStatusResponseMultiResV2_2'
        '400':
          description: Invalid task id
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InvalidTaskIdSchema'
        '401':
          description: Invalid API Key or Inactive API Key or Expired API Key
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InvalidApiKeySchema'
        '500':
          description: The task has no response in the expected time
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TaskTimeoutSchema'
      operationId: getS2sV20TaskAiStudioByTaskId
      x-operation-id-source: derived
    servers:
    - url: https://yce-api-01.makeupar.com
components:
  schemas:
    Template:
      type: object
      properties:
        id:
          type: string
          description: The ID of the template. Use this as \`template_id\` when run task.
          example: good_template_001
        thumb:
          type: string
          description: The thumbnail of style.
        title:
          type: string
          description: The title of the template.
        category_name:
          type: string
          description: The category name of the template.
    TaskStatusResponseMultiResV2:
      type: object
      properties:
        status:
          type: integer
          description: Response status
          example: 200
        data:
          type: object
          properties:
            task_status:
              type: string
              enum:
              - running
              - success
              - error
              description: Status of this task
            error:
              $ref: '#/components/schemas/EngineErrorCode'
            error_message:
              type: string
              description: Detailed description of error
            results: null
      $ref: '#/components/schemas/TaskStatusResponseBodyMultiUrlResultsV2'
    TaskStatusResponseBodyMultiUrlResultsV2:
      type: object
      properties:
        output:
          type: array
          items:
            type: object
            properties:
              url:
                type: string
                description: URL to download this result. Valid for 2 hours
                example: https://example.com/sample-result-url
    BasicRunTaskV2SrcFileId:
      type: object
      required:
      - src_file_id
      properties:
        src_file_id:
          type: string
          description: ID of file to run task. File ID from upload file API.
          example: pfNK5PuRe0MrwLHcGA3DOmB1ahwfXTbYHjv+KoBIxbE=
    RunWithOutputCntCustom200:
      type: object
      required:
      - output_count
      properties:
        output_count:
          type: integer
          minimum: 1
          maximum: 200
          description: The number of generated images. It must be between 1 to 200.
          example: 20
    BasicRunTaskV2SrcFileUrl:
      type: object
      required:
      - src_file_url
      properties:
        src_file_url:
          type: string
          description: Url of the file to run task. The url should be publicly accessible.
          example: https://example.com/selfie.jpg
    RunWithSingleTemplate:
      title: RunWithSingleTemplate
      type: object
      properties:
        template_id:
          type: string
          description: ID of the template. List predefined templates first, and use the id of a template.
          example: good_template_001
      required:
      - template_id
    RunError:
      type: object
      properties:
        status:
          type: integer
          description: Response status
          example: 400
        error:
          type: string
          description: Error message
          example: The operation could not be completed
        error_code:
          type: string
          enum:
          - InvalidParameters
          - CreditInsufficiency
          - InvalidStyleGroup
          - InvalidStyle
          - BadRequest
          description: "Error code:\n  * InvalidParameters - Invalid request parameters\n  * CreditInsufficiency - Insufficient unit to run\n  * BadRequest - Unexpected request parameter\n  * InvalidStyleGroup - Invalid style group id\n  * InvalidStyle - Invalid style id\n"
    BasicRunTaskResponseV2:
      type: object
      properties:
        status:
          type: integer
          description: Response status
          example: 200
        data:
          type: object
          properties:
            task_id:
              type: string
              description: ID of this task. Task result is valid to query by this ID for 24 hours.
              example: grH0CvsgXuAIHLUzD0V1Ol34hoet3R1tvdbtiVHrDb6_UqCLKIejAIajwxrhOAfe
    BasicRunTaskV2:
      title: BasicRunTaskV2
      anyOf:
      - title: Run task with src file url
        allOf:
        - $ref: '#/components/schemas/BasicRunTaskV2SrcFileUrl'
      - title: Run task with src file ID
        allOf:
        - $ref: '#/components/schemas/BasicRunTaskV2SrcFileId'
    RunWithSingleTemplateAndSrcUrl:
      title: RunWithSingleTemplateAndSrcUrl
      allOf:
      - $ref: '#/components/schemas/RunWithSingleTemplate'
      - $ref: '#/components/schemas/BasicRunTaskV2'
    EngineErrorCode:
      type:
      - string
      - 'null'
      enum:
      - error_exceed_max_image_size
      - exceed_max_filesize
      - invalid_parameter
      - error_download_image
      - error_download_mask
      - error_decode_image
      - error_decode_mask
      - error_nsfw_content_detected
      - error_no_face
      - error_pose
      - error_face_parsing
      - error_inference
      - exceed_nsfw_retry_limits
      - error_upload
      - unknown_internal_error
      description: 'Errors:

        - \`error_exceed_max_image_size\`  - Input image size exceeds the maximum limit

        - \`exceed_max_filesize\` - Input file size exceeds the maximum limit

        - \`invalid_parameter\` - Invalid parameter value

        - \`error_download_image\` - Download source image error

        - \`error_download_mask\` - Download mask image error

        - \`error_decode_image\` - Decode source image error

        - \`error_decode_mask\` - Decode mask image error

        - \`error_nsfw_content_detected\` - NSFW content detected in source image

        - \`error_no_face\` - No face detected on source image

        - \`error_pose\` - Failed to detect pose on source image

        - \`error_face_parsing\` - Failed to do face segmentation on source image

        - \`error_inference\` - Inference pipeline error

        - \`exceed_nsfw_retry_limits\` - Exceed the retry limits to avoid generated NSFW image

        - \`error_upload\` - Upload result image error

        - \`unknown_internal_error\` - Others

        '
    BasicRunTaskV2RefFileId:
      type: object
      properties:
        ref_file_id:
          type: string
          description: ID of the reference file to run task. File ID from upload file API.
          example: pfNK5PuRe0MrwLHcGA3DOmB1ahwfXTbYHjv+KoBIxbE=
    RunClothV3Task:
      allOf:
      - anyOf:
        - allOf:
          - title: Run task with src file url & ref file url
            required:
            - ref_file_url
          - $ref: '#/components/schemas/BasicRunTaskV2SrcFileUrl'
          - $ref: '#/components/schemas/BasicRunTaskV2RefFileUrl'
          - $ref: '#/components/schemas/RunClothsTaskV2GarmentCategory'
        - allOf:
          - title: Run task with src file url & ref file ID
            required:
            - ref_file_id
          - $ref: '#/components/schemas/BasicRunTaskV2SrcFileUrl'
          - $ref: '#/components/schemas/BasicRunTaskV2RefFileId'
          - $ref: '#/components/schemas/RunClothsTaskV2GarmentCategory'
        - allOf:
          - title: Run task with src file ID & ref file url
            required:
            - ref_file_url
          - $ref: '#/components/schemas/BasicRunTaskV2SrcFileId'
          - $ref: '#/components/schemas/BasicRunTaskV2RefFileUrl'
          - $ref: '#/components/schemas/RunClothsTaskV2GarmentCategory'
        - allOf:
          - title: Run task with src file ID & ref file ID
            required:
            - ref_file_id
          - $ref: '#/components/schemas/BasicRunTaskV2SrcFileId'
          - $ref: '#/components/schemas/BasicRunTaskV2RefFileId'
          - $ref: '#/components/schemas/RunClothsTaskV2GarmentCategory'
      - properties:
          change_shoes:
            type: boolean
            default: true
            description: 'Control whether shoes should be swapped when a full body reference image with shoes is available for processing.

              <br> Have effect when `garment_category` is `full_body` or `lower_body`

              '
    TaskStatusResponseBodySingleUrlResultsV2:
      type: object
      properties:
        url:
          type: string
          description: URL to download this result. Valid for 2 hours
          example: https://example.com/sample-result-url
    RunClothsTaskV2GarmentCategory:
      required:
      - garment_category
      properties:
        garment_category:
          type: string
          enum:
          - full_body
          - lower_body
          - upper_body
          - shoes
          - auto
          description: The category of garment of reference image. It's required if reference image provided. Utilize the "auto" parameter to allow the AI engine to automatically identify and classify garment categories.
    TaskStatusResponseV2:
      type: object
      properties:
        status:
          type: integer
          description: Response status
          example: 200
        data:
          type: object
          properties:
            task_status:
              type: string
              enum:
              - running
              - success
              - error
              description: Status of this task
            error:
              $ref: '#/components/schemas/EngineErrorCode'
            error_message:
              type: string
              description: Detailed description of error
            results: null
      $ref: '#/components/schemas/TaskStatusResponseBodySingleUrlResultsV2'
    BasicRunTaskV2RefFileUrl:
      type: object
      properties:
        ref_file_url:
          type: string
          description: Url of the reference file to run task. The url should be publicly accessible.
          example: https://example.com/accessory.jpg
    Template_2:
      type: object
      properties:
        id:
          type: string
          description: The ID of the template. Use this as `template_id` when run task.
          example: good_template_001
        thumb:
          type: string
          description: The thumbnail of style.
        title:
          type: string
          description: The title of the template.
        category_name:
          type: string
          description: The category name of the template.
    InvalidApiKeySchema:
      type: object
      properties:
        status:
          type: integer
          example: 401
          description: Response status
        error_code:
          type: string
          enum:
          - InvalidApiKey
          - InactiveApiKey
          - ExpiredApiKey
          description: "Error code:\n  * InvalidApiKey - API Key is not given or not valid\n  * InactiveApiKey - API Key is inactivated\n  * ExpiredApiKey - API Key is expired\n"
    InvalidParametersSchema:
      type: object
      properties:
        status:
          type: integer
          example: 400
          description: Response status
        error:
          type: string
          description: Error message
          example: The operation could not be completed
        error_code:
          type: string
          enum:
          - InvalidParameters
          description: "Error code:\n  * InvalidParameters - Invalid request parameters or body\n"
    TaskStatusResponseMultiResV2_2:
      type: object
      properties:
        status:
          type: integer
          description: Response status
          example: 200
        data:
          type: object
          properties:
            task_status:
              type: string
              enum:
              - running
              - success
              - error
              description: Status of this task
            error:
              $ref: '#/components/schemas/EngineErrorCode_2'
            error_message:
              type: string
              description: Detailed description of error
            results:
              $ref: '#/components/schemas/TaskStatusResponseBodyMultiUrlResultsV2'
    BasicRunTaskV2SrcFileId_2:
      title: Run task with src file ID
      type: object
      required:
      - src_file_id
      properties:
        src_file_id:
          type: string
          description: ID of file to run task. File ID from upload file API.
          example: pfNK5PuRe0MrwLHcGA3DOmB1ahwfXTbYHjv+KoBIxbE=
    InvalidTaskIdSchema:
      type: object
      properties:
        status:
          type: integer
          description: Response status
          example: 400
        error_code:
          type: string
          enum:
          - InvalidTaskId
          description: "Error code:\n  * InvalidTaskId - Invalid task id\n"
    BasicRunTaskV2SrcFileUrl_2:
      title: Run task with src file url
      type: object
      required:
      - src_file_url
      properties:
        src_file_url:
          type: string
          description: Url of the file to run task. The url should be publicly accessible.
          example: https://example.com/selfie.jpg
    TemplateResponseSchema:
      type: object
      properties:
        status:
          type: integer
          description: Response status
          example: 200
        data:
          type: object
          properties:
            templates:
              type: array
              items:
                $ref: '#/components/schemas/Template_2'
            next_token:
              type: string
              example: 73a3c9e69b89
              description: Token to query next page.
    TaskTimeoutSchema:
      type: object
      properties:
        status:
          type: integer
          description: Response status
          example: 500
        error_code:
          type: string
          enum:
          - TaskTimeout
          description: "Error code:\n  * TaskTimeout - The task has no response in the expected time\n"
    RunErrorSchema:
      type: object
      properties:
        status:
          type: integer
          description: Response status
          example: 400
        error:
          type: string
          description: Error message
          example: The operation could not be completed
        error_code:
          type: string
          enum:
          - CreditInsufficiency
          - InvalidStyleGroup
          - InvalidStyle
          - BadRequest
          - InvalidParameters
          description: "Error code:\n  * CreditInsufficiency - Insufficient unit to run\n  * BadRequest - Unexpected request parameter\n  * InvalidStyleGroup - Invalid style group id\n  * InvalidStyle - Invalid style id\n  * InvalidParameters - Invalid request parameters\n"
    BasicRunTaskV2_2:
      title: BasicRunTaskV2
      anyOf:
      - $ref: '#/components/schemas/BasicRunTaskV2SrcFileUrl_2'
      - $ref: '#/components/schemas/BasicRunTaskV2SrcFileId_2'
    EngineErrorCode_2:
      type:
      - string
      - 'null'
      enum:
      - exceed_max_filesize
      - invalid_parameter
      - error_download_image
      - error_download_mask
      - error_decode_image
      - error_decode_mask
      - error_nsfw_content_detected
      - error_no_face
      - error_pose
      - error_face_parsing
      - error_inference
      - exceed_nsfw_retry_limits
      - error_upload
      - unknown_internal_error
      description: 'Errors:

        - `exceed_max_filesize` - Input file size exceeds the maximum limit

        - `invalid_parameter` - Invalid parameter value

        - `error_download_image` - Download source image error

        - `error_download_mask` - Download mask image error

        - `error_decode_image` - Decode source image error

        - `error_decode_mask` - Decode mask image error

        - `error_nsfw_content_detected` - NSFW content detected in source image

        - `error_no_face` - No face detected on source image

        - `error_pose` - Failed to detect pose on source image

        - `error_face_parsing` - Failed to do face segmentation on source image

        - `error_inference` - Inference pipeline error

        - `exceed_nsfw_retry_limits` - Exceed the retry limits to avoid generated NSFW image

        - `error_upload` - Upload result image error

        - `unknown_internal_error` - Others

        '
  responses:
    InvalidTaskId:
      description: Invalid task ID
      content:
        application/json:
          schema:
            type: object
            properties:
              status:
                type: integer
                example: 400
                description: Response status
              error:
                type: string
                example: Invalid task ID
    TemplateResponse:
      description: Successful retrieval of styles
      content:
        application/json:
          schema:
            type: object
            properties:
              status:
                type: integer
                description: Response status
                example: 200
              data:
                type: object
                properties:
                  templates:
                    type: array
                    items:
                      $ref: '#/components/schemas/Template'
                  next_token:
                    type: string
                    example: 73a3c9e69b89
                    description: Token to query next page.
    InvalidApiKey:
      description: Invalid or missing API key
      content:
        application/json:
          schema:
            type: object
            properties:
              status:
                type: integer
                example: 401
                description: Response status
              error:
                type: string
                example: Invalid API key
    TaskTimeout:
      description: Task execution timeout
      content:
        application/json:
          schema:
            type: object
            properties:
              status:
                type: integer
                example: 500
                description: Response status
              error:
                type: string
                example: Task execution timed out
    InvalidParameters:
      description: Invalid request parameters
      content:
        application/json:
          schema:
            type: object
            properties:
              status:
                type: integer
                example: 400
                description: Response status
              error:
                type: string
                example: Invalid parameter value
              error_code:
                type: string
                example: InvalidParameters
    TooManyRequests:
      description: Too many requests
      content:
        application/json:
          schema:
            type: object
            properties:
              status:
                type: integer
                example: 429
                description: Response status
              error:
                type: string
                example: Too many requests
  securitySchemes:
    BearerAuthenticationV2:
      type: http
      scheme: bearer
      description: 'Use the standard ''Bearer authentication''. Put your ''API Key'' in header: `Authorization:Bearer YOUR_API_KEY`. Notice that there is '' '' a space between ''Bearer'' and the ''YOUR_API_KEY''.'
x-refined-from:
- perfect-corp-ai_avatar_generator-openapi.yml
- perfect-corp-ai_clothes-openapi.yml
- perfect-corp-ai_studio_generator-openapi.yml