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

# Clear skew protection threshold

> Clear the environment's skew protection threshold, or with `task` the threshold of that one task. Sessions already moved stay on their new runs; the others keep their versions and stored pins. Clearing a threshold that isn't set changes nothing. Use a secret key from a deployed environment, such as staging or production. Development environments return 400.



## OpenAPI

````yaml v3-openapi DELETE /api/v1/deployments/skew-protection-threshold
openapi: 3.1.0
info:
  title: Trigger.dev v3 REST API
  description: >-
    The REST API lets you trigger and manage runs on Trigger.dev. You can
    trigger a run, get the status of a run, and get the results of a run. 
  version: 2024-04
  license:
    name: Apache 2.0
    url: https://www.apache.org/licenses/LICENSE-2.0.html
servers:
  - url: https://api.trigger.dev
    description: Trigger.dev API
security: []
paths:
  /api/v1/deployments/skew-protection-threshold:
    delete:
      tags:
        - deployments
      summary: Clear skew protection threshold
      description: >-
        Clear the environment's skew protection threshold, or with `task` the
        threshold of that one task. Sessions already moved stay on their new
        runs; the others keep their versions and stored pins. Clearing a
        threshold that isn't set changes nothing. Use a secret key from a
        deployed environment, such as staging or production. Development
        environments return 400.
      operationId: clear_skew_protection_threshold_v1
      parameters:
        - in: query
          name: task
          required: false
          schema:
            type: string
            minLength: 1
            maxLength: 256
          description: >-
            A task id. Clears that task's own threshold and leaves the
            environment's. Leave it out to clear the environment's threshold and
            leave each task's.
      responses:
        '200':
          description: The environment's skew protection state after the change
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SkewProtectionThresholdState'
        '400':
          description: >-
            The key belongs to a development environment, or `task` is empty or
            over 256 characters
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/SkewProtectionThresholdError'
        '401':
          description: >-
            Unauthorized. The API key is missing or invalid, or isn't a secret
            key
        '403':
          description: The API key can't write deployments
      security:
        - secretKey: []
      x-codeSamples:
        - lang: curl
          source: >-
            curl -X DELETE
            "https://api.trigger.dev/api/v1/deployments/skew-protection-threshold"
            \
              -H "Authorization: Bearer tr_prod_sk_1234"
components:
  schemas:
    SkewProtectionThresholdState:
      type: object
      properties:
        currentVersion:
          type: string
          nullable: true
          description: The current deployment's version, or null when nothing is current.
          example: '20261109.22'
        threshold:
          description: >-
            The environment's skew protection threshold, or null when none is
            set.
          anyOf:
            - $ref: '#/components/schemas/SkewProtectionThreshold'
            - type: 'null'
        tasks:
          type: object
          description: >-
            Each task's own skew protection threshold, by task id. Empty when no
            task has one.
          additionalProperties:
            $ref: '#/components/schemas/SkewProtectionThreshold'
    SkewProtectionThresholdError:
      type: object
      properties:
        error:
          type: string
          example: No deployed deployment with version 99999999.1 in this environment.
    SkewProtectionThreshold:
      type: object
      properties:
        version:
          type: string
          example: '20261109.22'
        deploymentId:
          type: string
          nullable: true
          description: The ID of the deployment with this version.
          example: deployment_exv9bt4gdbuun6mc24iuq
        setAt:
          type: string
          format: date-time
        setBy:
          type: object
          nullable: true
          properties:
            type:
              type: string
              enum:
                - user
                - api
                - migrated
              description: >-
                `user` from the dashboard, `api` through this API, `migrated`
                when Trigger.dev set it for you.
  securitySchemes:
    secretKey:
      type: http
      scheme: bearer
      description: >
        Use a named environment API key. It starts with `tr_dev_sk_`,
        `tr_prod_sk_`, `tr_stg_sk_`, etc.


        Create a named API key in the API Keys section of your Trigger.dev
        project dashboard. Choose the narrowest access preset that supports your
        integration.


        Our TypeScript SDK will default to using the value of the
        `TRIGGER_SECRET_KEY` environment variable if it is set. If you are using
        the SDK in a different environment, you can set the key using the
        `configure` function.


        ```typescript

        import { configure } from "@trigger.dev/sdk";


        configure({ accessToken: "tr_dev_sk_1234" });

        ```

````

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