> ## 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 Market Data

> Get market data for any crypto token

<Warning>
  **Deprecated Endpoint**

  This endpoint is deprecated. Please use the new v2 endpoints instead:

  * [/api/2/asset/details](/rest-api-reference/endpoint/asset-details) — For asset-level data (metadata, market data, supply stats) by asset ID or token address
  * [/api/2/token/details](/rest-api-reference/endpoint/token-details) — For detailed token-level data (holdings, trading activity, volume) by token address and blockchain
</Warning>

### Query Details

Input in "asset" the name of the asset you want to query, or the contract address while adding the blockchain as a second parameter. The market data asset query pattern is explained [in great details here](/rest-api-reference/docs/market-asset-query), with blockchain format, etc.

| Parameter                | Type                 | Required | Description                                                                                                |
| ------------------------ | -------------------- | -------- | ---------------------------------------------------------------------------------------------------------- |
| `asset`                  | string               | Yes      | The asset identifier to query. This can be the token’s name or the contract address.                       |
| `blockchain`             | string               | Cond.    | The blockchain network name or ID where the asset resides. Required if querying by contract address.       |
| `shouldFetchPriceChange` | string (e.g., "24h") | No       | Timeframe for price change calculation. Example: `"24h"` returns price change over the last 24 hours.      |
| `symbol`                 | string               | Cond.    | Token ticker symbol. If duplicates exist, returns the first match. Use contract + blockchain for accuracy. |
| `id`                     | number               | Cond.    | The Asset Unique Identifier to query.                                                                      |

### Additional Notes

* **Data Freshness:**
  Market data is constantly recomputed, in real time. There is no delay except how fast we ingest blocks, which is usually 100-200ms after blocks are emitted.

* **Pricing Model Details:**
  Price data is computed using Octopus, Mobula's market data engine. You can have a high-level overview of how it's computing DeFi prices [here](https://mirror.xyz/0x6483Ca5ac1EbC6eB08d36979d217db2572CbAad2/Lw8NSSjqR4JSzthKZQCfHLwD3NPGsuaAfHGMY1zi-WI). `volume` is on-chain volume, and `off_chain_volume` is - as name implies, the off-chain volume.

* On some long tail assets, `price is different than on CoinGecko or CoinMarketCap. Why?`
  Mobula uses market-depth-weighted average price, which is more accurate than the simple average price. This is especially important for assets with low / zero volume in the long tail.

* `How to query native tokens?`
  To query the native token of any given chain, use `asset=0xEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE&blockchain=<blockchain_name or blockchain_id>`

### Usage Examples

* Query by Asset Name

```bash theme={null}
curl -X GET "https://api.mobula.io/api/1/market/data?shouldFetchPriceChange=24h&blockchain=ethereum&asset=cult"
```

* Query by Contract Address of Token.

```bash theme={null}
curl -X GET "https://api.mobula.io/api/1/market/data?shouldFetchPriceChange=24h&blockchain=ethereum&asset=0x0000000000c5dc95539589fbd24be07c6c14eca4"
```

* Query by Query Native Token.

```bash theme={null}
curl -X GET "https://api.mobula.io/api/1/market/data?shouldFetchPriceChange=24h&blockchain=ethereum&asset=0xEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEE"
```

* Query by Asset id.

```bash theme={null}
curl -X GET "https://api.mobula.io/api/1/market/data?shouldFetchPriceChange=24h&id=100"
```


## OpenAPI

````yaml get /1/market/data
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 - Usage
    description: Per-key API and WebSocket usage history
  - name: V2 - Blockchains
    description: System metadata and chain listings
  - name: V2 - Prediction Markets
    description: >-
      Polymarket markets/events, wallet positions, and the full execution stack
      (auth, order build/submit/cancel, approvals, pUSD wrap/unwrap, deploy,
      deposit/withdraw, redeem). Alpha — see /api/2/pm/*.
  - 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:
  /1/market/data:
    get:
      tags:
        - V1 - Market Data
      summary: Get market data
      parameters:
        - schema:
            type: string
            description: Blockchain name or chain ID
          required: false
          description: Blockchain name or chain ID
          name: blockchain
          in: query
        - schema:
            type: string
            description: Token contract address or name
          required: false
          description: Token contract address or name
          name: asset
          in: query
        - schema:
            type: string
            description: Token symbol
          required: false
          description: Token symbol
          name: symbol
          in: query
        - schema:
            type: number
            nullable: true
            description: Asset ID
          required: false
          description: Asset ID
          name: id
          in: query
      responses:
        '200':
          description: Market data response
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: object
                    properties:
                      id:
                        type: number
                        nullable: true
                      name:
                        type: string
                      symbol:
                        type: string
                      decimals:
                        type: number
                        nullable: true
                      logo:
                        type: string
                        nullable: true
                      rank:
                        type: number
                        nullable: true
                      price:
                        type: number
                        nullable: true
                      market_cap:
                        type: number
                      market_cap_diluted:
                        type: number
                      volume:
                        type: number
                        nullable: true
                      volume_change_24h:
                        type: number
                        nullable: true
                      volume_7d:
                        type: number
                        nullable: true
                      liquidity:
                        type: number
                      liquidityMax:
                        type: number
                      ath:
                        type: number
                        nullable: true
                      atl:
                        type: number
                        nullable: true
                      off_chain_volume:
                        type: number
                        nullable: true
                      is_listed:
                        type: boolean
                      price_change_1h:
                        type: number
                      price_change_24h:
                        type: number
                      price_change_7d:
                        type: number
                      price_change_1m:
                        type: number
                      price_change_1y:
                        type: number
                      total_supply:
                        type: number
                      circulating_supply:
                        type: number
                      contracts:
                        type: array
                        items:
                          type: object
                          properties:
                            address:
                              type: string
                            blockchainId:
                              type: string
                            blockchain:
                              type: string
                            decimals:
                              type: number
                          required:
                            - address
                            - blockchainId
                            - blockchain
                            - decimals
                      native:
                        type: object
                        properties:
                          name:
                            type: string
                          symbol:
                            type: string
                          address:
                            type: string
                          type:
                            type: string
                          decimals:
                            type: number
                          logo:
                            type: string
                        required:
                          - name
                          - symbol
                          - address
                          - type
                          - decimals
                          - logo
                      priceNative:
                        type: number
                    required:
                      - id
                      - name
                      - symbol
                      - decimals
                      - logo
                      - rank
                      - price
                      - market_cap
                      - market_cap_diluted
                      - volume
                      - volume_change_24h
                      - volume_7d
                      - liquidity
                      - liquidityMax
                      - ath
                      - atl
                      - off_chain_volume
                      - is_listed
                      - price_change_1h
                      - price_change_24h
                      - price_change_7d
                      - price_change_1m
                      - price_change_1y
                      - total_supply
                      - circulating_supply
                      - contracts
                required:
                  - data

````