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

# Get Token Trade by Transaction

> Retrieve a specific trade by transaction hash and blockchain. Returns the first trade found in the transaction.



## OpenAPI

````yaml get /2/token/trade
openapi: 3.0.0
info:
  version: 1.0.0
  title: Mobula API
  description: >-
    Documentation of the Mobula API


    **Demo API**: The default server (demo-api.mobula.io) is a demo API with
    rate limits.

    For production use, please use api.mobula.io with an API key from
    https://admin.mobula.io
servers:
  - url: https://demo-api.mobula.io/api/
    description: Demo API (rate limited, for testing only)
  - url: https://api.mobula.io/api/
    description: Production API (requires API key)
security: []
tags:
  - name: V2 - Token
    description: Token details, price, security, ATH, and holder data
  - name: V2 - Market Data
    description: Market details, OHLCV history, and lighthouse metrics
  - name: V2 - Trades
    description: Token trades, enriched trades, and trade filters
  - name: V2 - Wallet
    description: Wallet positions, activity, trades, analysis, and labels
  - name: V2 - Assets
    description: Cross-chain asset details and price history
  - name: V2 - Swap
    description: Swap quoting and execution
  - name: V2 - Perps
    description: Perpetual futures quoting, execution, and positions
  - name: V2 - Bridge
    description: Cross-chain bridge quoting and intent status (Alpha Preview)
  - name: V2 - DeFi
    description: Bonding pools and pulse data
  - name: V2 - Search
    description: Universal fast search
  - name: V2 - Blockchains
    description: System metadata and chain listings
  - name: V1 - Market Data
    description: Market prices, history, sparklines, pairs, and multi-data
  - name: V1 - Wallet
    description: Wallet portfolio, transactions, history, and NFTs
  - name: V1 - Token
    description: First buyers
  - name: V1 - Trades
    description: Market trades by pair
  - name: V1 - Metadata
    description: Token metadata, categories, trendings, and news
  - name: V1 - Assets
    description: List all assets
  - name: V1 - Search
    description: Search for assets, tokens, and pairs
  - name: V1 - DeFi
    description: Bonding pool pulse data
  - name: V1 - Blockchains
    description: Blockchain listings, pairs, and stats
  - name: V1 - Webhooks
    description: Webhook management
  - name: V1 - Feed
    description: Custom feed creation
paths:
  /2/token/trade:
    get:
      tags:
        - V2 - Trades
      summary: Get a single trade by transaction hash
      parameters:
        - schema:
            type: string
            description: Blockchain chain ID (e.g., "evm:56", "solana:solana")
          required: false
          description: Blockchain chain ID (e.g., "evm:56", "solana:solana")
          name: chainId
          in: query
        - schema:
            type: string
            minLength: 1
            description: Transaction hash
          required: true
          description: Transaction hash
          name: transactionHash
          in: query
      responses:
        '200':
          description: Token trade response
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                      operation:
                        type: string
                        enum:
                          - regular
                          - mev
                          - mev_sandwiched
                          - deposit
                          - withdrawal
                          - bond
                        description: >-
                          Trade operation type (regular, mev, mev_sandwiched,
                          deposit, withdrawal, bond)
                      type:
                        type: string
                        enum:
                          - buy
                          - sell
                          - deposit
                          - withdrawal
                        description: Trade type (buy, sell, deposit, withdrawal)
                      baseTokenAmount:
                        type: number
                      baseTokenAmountRaw:
                        type: string
                      baseTokenAmountUSD:
                        type: number
                      quoteTokenAmount:
                        type: number
                      quoteTokenAmountRaw:
                        type: string
                      quoteTokenAmountUSD:
                        type: number
                      date:
                        type: number
                      swapSenderAddress:
                        type: string
                      transactionSenderAddress:
                        type: string
                      swapRecipient:
                        type: string
                        nullable: true
                        description: >-
                          The actual beneficiary wallet of the swap. Most
                          important address for AA wallets and accurate PnL
                          tracking.
                      blockchain:
                        type: string
                      transactionHash:
                        type: string
                      marketAddress:
                        type: string
                      marketAddresses:
                        type: array
                        items:
                          type: string
                      baseTokenPriceUSD:
                        type: number
                      quoteTokenPriceUSD:
                        type: number
                      baseTokenMarketCapUSD:
                        type: number
                        nullable: true
                      quoteTokenMarketCapUSD:
                        type: number
                        nullable: true
                      labels:
                        type: array
                        nullable: true
                        items:
                          type: string
                        default: []
                      walletMetadata:
                        type: object
                        nullable: true
                        properties:
                          entityName:
                            type: string
                            nullable: true
                          entityLogo:
                            type: string
                            nullable: true
                          entityLabels:
                            type: array
                            items:
                              type: string
                          entityType:
                            type: string
                            nullable: true
                          entityDescription:
                            type: string
                            nullable: true
                          entityTwitter:
                            type: string
                            nullable: true
                          entityWebsite:
                            type: string
                            nullable: true
                          entityGithub:
                            type: string
                            nullable: true
                          entityDiscord:
                            type: string
                            nullable: true
                          entityTelegram:
                            type: string
                            nullable: true
                          extra:
                            type: object
                            additionalProperties:
                              nullable: true
                        required:
                          - entityName
                          - entityLogo
                          - entityLabels
                          - entityType
                          - entityDescription
                          - entityTwitter
                          - entityWebsite
                          - entityGithub
                          - entityDiscord
                          - entityTelegram
                      baseToken:
                        type: object
                        nullable: true
                        properties:
                          address:
                            type: string
                          name:
                            type: string
                            nullable: true
                          symbol:
                            type: string
                            nullable: true
                          logo:
                            type: string
                            nullable: true
                          decimals:
                            type: number
                        required:
                          - address
                          - name
                          - symbol
                          - logo
                          - decimals
                      quoteToken:
                        type: object
                        nullable: true
                        properties:
                          address:
                            type: string
                          name:
                            type: string
                            nullable: true
                          symbol:
                            type: string
                            nullable: true
                          logo:
                            type: string
                            nullable: true
                          decimals:
                            type: number
                        required:
                          - address
                          - name
                          - symbol
                          - logo
                          - decimals
                      platform:
                        type: object
                        nullable: true
                        properties:
                          id:
                            type: string
                          name:
                            type: string
                          logo:
                            type: string
                            nullable: true
                        required:
                          - id
                          - name
                          - logo
                      totalFeesUSD:
                        type: number
                        nullable: true
                      gasFeesUSD:
                        type: number
                        nullable: true
                      platformFeesUSD:
                        type: number
                        nullable: true
                      mevFeesUSD:
                        type: number
                        nullable: true
                    required:
                      - id
                      - operation
                      - type
                      - baseTokenAmount
                      - baseTokenAmountRaw
                      - baseTokenAmountUSD
                      - quoteTokenAmount
                      - quoteTokenAmountRaw
                      - quoteTokenAmountUSD
                      - date
                      - swapSenderAddress
                      - transactionSenderAddress
                      - blockchain
                      - transactionHash
                      - marketAddress
                      - baseTokenPriceUSD
                      - quoteTokenPriceUSD
                required:
                  - data

````