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

# Try On Job Cancel (Beta)

> **BETA** - This endpoint is currently in beta and may change without notice.<br/><br/>
Cancels a Try On job that is currently pending or running.
When a Try On job is submitted with wait_for_result set to false, it can be cancelled using this endpoint if it hasn't completed yet. Jobs that are already completed or failed cannot be cancelled.




## OpenAPI

````yaml POST /v1/try-on/job/{jobId}/cancel
openapi: 3.1.0
info:
  description: >-
    The Pixelcut API specification, learn more about the API at at
    https://www.pixelcut.ai/docs
  version: 0.0.2
  title: Pixelcut API
  termsOfService: >-
    https://pixelcut.notion.site/Pixelcut-API-Terms-of-Service-11b3b550490080d89a91e943d010efdf
  contact:
    name: API Support
    email: api@pixelcut.ai
servers:
  - url: https://api.developer.pixelcut.ai
    description: Pixelcut API server
security: []
paths:
  /v1/try-on/job/{jobId}/cancel:
    post:
      tags:
        - Endpoints
      summary: Try On Job Cancel (Beta)
      description: >
        **BETA** - This endpoint is currently in beta and may change without
        notice.<br/><br/>

        Cancels a Try On job that is currently pending or running.

        When a Try On job is submitted with wait_for_result set to false, it can
        be cancelled using this endpoint if it hasn't completed yet. Jobs that
        are already completed or failed cannot be cancelled.
      operationId: try-on-job-cancel
      parameters:
        - name: jobId
          in: path
          required: true
          schema:
            type: string
          description: The ID of the job to cancel
      responses:
        '200':
          description: Job cancelled successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                    description: Confirmation message
                    example: Job cancelled
        '401':
          $ref: '#/components/responses/Error401'
        '404':
          $ref: '#/components/responses/Error404'
        '409':
          description: Job has already finished and cannot be canceled
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                    example: Job has already finished and cannot be canceled
                  error_code:
                    type: string
                    enum:
                      - job_finished
                    example: job_finished
        '429':
          $ref: '#/components/responses/Error429'
        '500':
          $ref: '#/components/responses/Error500'
      security:
        - ApiKeyAuth: []
components:
  responses:
    Error401:
      description: The authentication token is missing or invalid.
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
                example: API Token not found
              error_code:
                type: string
                enum:
                  - invalid_auth_token
    Error404:
      description: Job not found
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
                example: Job not found
              error_code:
                type: string
                enum:
                  - not_found
    Error429:
      description: Rate limit exceeded
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string
                example: Too many requests
              error_code:
                type: string
                enum:
                  - rate_limit_exceeded
    Error500:
      description: Internal service error
  securitySchemes:
    ApiKeyAuth:
      description: >
        All API requests require a valid api key. Include your token as a HTTP
        request header in the following format: `X-API-Key: skXXXXXXXXXXXXXXXX`.
        You can obtain an api key by signing up for developer access in your
        Pixelcut account.
      type: apiKey
      name: X-API-KEY
      in: header

````