---
title: "Cancels a specific transaction by its ID."
method: DELETE
path: "/api/v1/relayers/{relayer_id}/transactions/{transaction_id}"
tags: ["Relayers"]
---

# Cancels a specific transaction by its ID.

`DELETE /api/v1/relayers/{relayer_id}/transactions/{transaction_id}`

## Path parameters

- `relayer_id` string, required
- `transaction_id` string, required

## Response `200`

Relayer transaction canceled successfully

- ApiResponseTransactionResponse
  - `data` union
    - EvmTransactionResponse
      - `confirmed_at` string
      - `created_at` string, required
      - `data` string
      - `from` string, required
      - `gas_limit` integer, nullable
      - `gas_price` string
      - `hash` string
      - `id` string, required
      - `max_fee_per_gas` string
      - `max_priority_fee_per_gas` string
      - `nonce` integer
      - `relayer_id` string, required
      - `sent_at` string
      - `signature` EvmTransactionDataSignature
        - `r` string, required
        - `s` string, required
        - `sig` string, required
        - `v` integer, required
      - `speed` 'fastest' | 'fast' | 'average' | 'safeLow'
      - `status` 'canceled' | 'pending' | 'sent' | 'submitted' | 'mined' | 'confirmed' | 'failed' | 'expired', required
      - `status_reason` string, nullable
      - `to` string
      - `value` string, required
    - SolanaTransactionResponse
      - `confirmed_at` string
      - `created_at` string, required
      - `id` string, required
      - `instructions` SolanaInstructionSpec[]
        - `accounts` SolanaAccountMeta[], required — Account metadata for the instruction
          - `is_signer` boolean, required — Whether the account is a signer
          - `is_writable` boolean, required — Whether the account is writable
          - `pubkey` string, required — Account public key (base58-encoded)
        - `data` string, required — Instruction data (base64-encoded)
        - `program_id` string, required — Program ID (base58-encoded pubkey)
      - `sent_at` string
      - `signature` string
      - `status` 'canceled' | 'pending' | 'sent' | 'submitted' | 'mined' | 'confirmed' | 'failed' | 'expired', required
      - `status_reason` string
      - `transaction` string, required
    - StellarTransactionResponse
      - `confirmed_at` string
      - `created_at` string, required
      - `fee` integer, required
      - `hash` string
      - `id` string, required
      - `relayer_id` string, required
      - `sent_at` string
      - `sequence_number` string, required — Stellar sequence number encoded as a decimal string to preserve precision.
      - `source_account` string, required
      - `status` 'canceled' | 'pending' | 'sent' | 'submitted' | 'mined' | 'confirmed' | 'failed' | 'expired', required
      - `status_reason` string, nullable
      - `transaction_result_xdr` string
  - `error` string
  - `metadata` PluginMetadata
    - `logs` LogEntry[], nullable
      - `level` 'log' | 'info' | 'error' | 'warn' | 'debug' | 'result', required
      - `message` string, required
    - `traces` unknown[], nullable
      - unknown
  - `pagination` PaginationMeta
    - `current_page` integer, required
    - `per_page` integer, required
    - `total_items` integer, required
  - `success` boolean, required

## Other responses

- `400` — BadRequest
- `401` — Unauthorized
- `404` — Not Found
- `429` — Too Many Requests
- `500` — Internal server error

## Changes

- **2026-06-05** `97fada1b2001` — 1 breaking, 1 info
  - the `data/oneOf[#/components/schemas/StellarTransactionResponse]/sequence_number` response's property type changed from `integer` to `string`, and format from `int64` to no format for status `200`
  - the `data/oneOf[#/components/schemas/StellarTransactionResponse]/sequence_number` response's property pattern `^-?[0-9]+$` was added for the status `200`
- **2025-12-22** `2abd60a9c2d8` — 1 info
  - added the optional property `data/oneOf[#/components/schemas/StellarTransactionResponse]/transaction_result_xdr` to the response with the `200` status
- **2025-11-07** `d1f71894e671` — 1 info
  - added the optional property `data/oneOf[#/components/schemas/SolanaTransactionResponse]/instructions` to the response with the `200` status
- …earlier changes not shown

[Full history](https://skmtc.dev/openzeppelin/apis/openzeppelin-relayer-api/changes/api/v1/relayers/:relayer_id/transactions/:transaction_id/delete.md)

---

[API](https://skmtc.dev/openzeppelin/apis/openzeppelin-relayer-api.md) · [All operations](https://skmtc.dev/openzeppelin/apis/openzeppelin-relayer-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/openzeppelin/openzeppelin-relayer-api/revisions/e6e7514284f5/schema)
