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

# Cancel an open job

> Requires `jobs:write`. Same rules as Cancel in the app. A `queued`, `running` or `waiting_for_review` job moves to `cancelled` and stops running. Finished jobs, and provider-backed jobs, return `409 job_action_unavailable`. A cancelled job can't be reopened, so create a new one if you need the work again.



## OpenAPI

````yaml https://public-api.hyperlocalise.com/openapi.yaml post /v1/jobs/{jobId}/cancel
openapi: 3.1.0
info:
  title: Hyperlocalise Public API
  version: 1.0.0
  description: >-
    Read projects, Queries, jobs, glossaries, and translation memories from a
    Hyperlocalise workspace; create native projects from project templates and
    manage those templates; define custom project fields and set their values;
    manage the strings, translations, screenshots, and settings of native
    projects; search strings; round-trip bilingual files; update jobs one at a
    time or in bulk; register job-change webhook endpoints; import and export
    glossaries and translation memories; and read the Reports page's reports as
    JSON or CSV.
servers:
  - url: https://public-api.hyperlocalise.com
security:
  - personalAccessToken: []
tags:
  - name: Identity
  - name: Projects
  - name: Project templates
  - name: Custom fields
  - name: Queries
  - name: Jobs
  - name: Strings
  - name: Translations
  - name: Screenshots
  - name: Figma attachments
  - name: Bilingual files
  - name: Glossaries
  - name: Translation memories
  - name: Webhooks
  - name: CDN
  - name: Hyperlab
  - name: Reports
    description: >-
      The Reports page's reports for scripts, BI tools and payment systems.
      Every report needs `reports:read`, which only admins' and localization
      managers' keys hold, and the workspace's Reports feature. Each answer says
      whether recent work is still being counted (`stillUpdating`); figures can
      lag live work by one capture run. A workspace may ask for 30 reports a
      minute, in bursts of 10.
paths:
  /v1/jobs/{jobId}/cancel:
    parameters:
      - $ref: '#/components/parameters/JobId'
    post:
      tags:
        - Jobs
      summary: Cancel an open job
      description: >-
        Requires `jobs:write`. Same rules as Cancel in the app. A `queued`,
        `running` or `waiting_for_review` job moves to `cancelled` and stops
        running. Finished jobs, and provider-backed jobs, return `409
        job_action_unavailable`. A cancelled job can't be reopened, so create a
        new one if you need the work again.
      operationId: cancelJob
      responses:
        '200':
          description: The cancelled job.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/JobResponse'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '403':
          $ref: '#/components/responses/Forbidden'
        '404':
          $ref: '#/components/responses/NotFound'
        '409':
          $ref: '#/components/responses/Conflict'
        '503':
          $ref: '#/components/responses/Unavailable'
components:
  parameters:
    JobId:
      name: jobId
      in: path
      required: true
      schema:
        type: string
        maxLength: 128
  schemas:
    JobResponse:
      type: object
      required:
        - job
      properties:
        job:
          $ref: '#/components/schemas/Job'
    Job:
      type: object
      required:
        - id
        - projectId
        - kind
        - type
        - status
        - createdAt
        - updatedAt
        - completedAt
        - lastError
        - title
        - description
        - dueAt
        - ownerEmail
        - outputFiles
        - sourceFile
        - sourceLocale
        - targetLocales
        - step
        - after
      properties:
        id:
          type: string
        projectId:
          type:
            - string
            - 'null'
        kind:
          type: string
          enum:
            - translation
            - research
            - review
            - proofread
            - sync
            - asset_management
        type:
          type:
            - string
            - 'null'
          enum:
            - string
            - file
            - keys
            - null
        status:
          type: string
          enum:
            - queued
            - running
            - succeeded
            - failed
            - waiting_for_review
            - cancelled
        createdAt:
          type: string
          format: date-time
        updatedAt:
          type: string
          format: date-time
        completedAt:
          type:
            - string
            - 'null'
          format: date-time
        lastError:
          type:
            - string
            - 'null'
        title:
          type:
            - string
            - 'null'
        description:
          type:
            - string
            - 'null'
        dueAt:
          type:
            - string
            - 'null'
          format: date-time
        ownerEmail:
          type:
            - string
            - 'null'
        outputFiles:
          type:
            - array
            - 'null'
          description: Translated files of a finished file job.
          items:
            type: object
            required:
              - fileId
              - locale
              - filename
            properties:
              fileId:
                type: string
              locale:
                type: string
              filename:
                type: string
        sourceFile:
          type:
            - object
            - 'null'
          description: >-
            The file the job translates or reviews. `null` for jobs without a
            file, such as key jobs.
          required:
            - fileId
            - path
            - branch
          properties:
            fileId:
              type: string
              description: Stored file id, as the `/v1/files` routes use.
            path:
              type:
                - string
                - 'null'
              description: The file's path in the project; `null` when it has none.
            branch:
              type:
                - string
                - 'null'
              description: >-
                The project version branch the file belongs to; `null` when it
                has no path.
        sourceLocale:
          type:
            - string
            - 'null'
        targetLocales:
          type:
            - array
            - 'null'
          items:
            type: string
        step:
          type:
            - string
            - 'null'
          enum:
            - translate
            - post_edit
            - proofread
            - null
          description: >-
            The job's step as a task for people. `null` for AI jobs and for jobs
            synced from another TMS. A post-edit task and a proofread task both
            have kind `proofread`.
        after:
          type:
            - string
            - 'null'
          description: >-
            The job this task comes after. While that job is unfinished the
            task's status is `queued`.
    Error:
      type: object
      required:
        - error
        - message
      properties:
        error:
          type: string
        message:
          type: string
        details:
          type: object
          description: >-
            Structured context, such as the `jobId` that stopped a bulk job
            update.
          additionalProperties: true
  responses:
    Unauthorized:
      description: The personal access token is missing or invalid.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Forbidden:
      description: The token lacks the required scope or workspace access.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    NotFound:
      description: The resource is missing or inaccessible.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Conflict:
      description: >-
        The project is not native, the key already exists, the segment is
        locked, the webhook endpoint limit was reached, or the job, memory, or
        glossary is managed elsewhere or archived.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Unavailable:
      description: Authentication or resource storage is temporarily unavailable.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    personalAccessToken:
      type: apiKey
      in: header
      name: x-api-key

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.