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

# Cancel a pending transaction

> Cancels a pending transaction. Only pending transactions can be cancelled. Only transactions belonging to the integrator can be cancelled.



## OpenAPI

````yaml /api-reference/openapi.json delete /transactions/sign/{transactionId}
openapi: 3.0.0
info:
  title: Relayer
  description: >-
    Relayer API — Kit-based crypto infrastructure for OTC exchange, wallet
    signing, payouts, and widget actions.
  version: '1.0'
  contact: {}
servers:
  - url: https://testnet.relayer.fi/v1
    description: Sandbox (testnet wallets, no real fiat)
  - url: https://api.relayer.fi/v1
    description: Production (mainnet wallets, regulated fiat rails)
security:
  - api-key: []
tags:
  - name: 'Action: Builders'
    description: Transaction metadata builders
  - name: 'Action: Directory'
    description: Widget directory
  - name: 'Action: Execute'
  - name: 'Action: Tokens'
    description: Token lists per chain/protocol
  - name: Addresses
  - name: Agents
  - name: App
    description: Application endpoints
  - name: 'Payout: Accounts'
    description: Payment execution
  - name: 'Payout: Off-ramp'
  - name: 'Payout: On-ramp'
  - name: 'Payout: Orders'
  - name: 'Payout: Recipients'
    description: Beneficiary management
  - name: Signing - Passkeys
  - name: Signing - Recovery
  - name: Signing Approvals
    description: Transaction signing approvals
  - name: Signing Policies
    description: Signing policy management
  - name: Transactions
    description: Transaction signing and broadcasting
  - name: Wallets
    description: Wallet and address management
paths:
  /transactions/sign/{transactionId}:
    delete:
      tags:
        - Transactions
      summary: Cancel a pending transaction
      description: >-
        Cancels a pending transaction. Only pending transactions can be
        cancelled. Only transactions belonging to the integrator can be
        cancelled.
      operationId: TransactionsController_cancelSignedTransaction
      parameters:
        - name: transactionId
          required: true
          in: path
          description: Transaction ID
          schema:
            example: tx-uuid-abc123
            type: string
        - name: integratorId
          required: false
          in: query
          description: Integrator ID (required for ADMIN/INTERNAL scope)
          schema:
            example: uuid-integrator-id
            type: string
      responses:
        '200':
          description: Transaction cancelled successfully
        '400':
          description: Bad Request - Transaction cannot be cancelled
        '403':
          description: Forbidden - Transaction does not belong to this integrator
        '404':
          description: Transaction not found
      security:
        - api-key: []
        - api-key: []
      x-codeSamples:
        - lang: bash
          label: cURL
          source: >-
            curl -X DELETE
            https://api.relayer.fi/v1/transactions/sign/$TRANSACTION_ID \
              -H "Authorization: ApiKey $RELAYER_API_KEY"
        - lang: TypeScript
          label: Node.js
          source: |-
            // Cancel a transaction in awaiting_signature state. Once broadcast,
            // cancellation is no longer possible via this endpoint.
            const response = await fetch(
              `https://api.relayer.fi/v1/transactions/sign/${transactionId}`,
              {
                method: "DELETE",
                headers: { Authorization: `ApiKey ${process.env.RELAYER_API_KEY}` },
              },
            );
components:
  securitySchemes:
    api-key:
      type: apiKey
      in: header
      name: Authorization
      description: 'Use this format: `ApiKey <your_api_key>`'

````