# Live Price Oracle (`zinin/live-price-oracle`) Actor

Current USD price for any token by contract address or ticker: 24h change, liquidity, volume, best DEX pair. Keyless, no wallet, no RPC node — DexScreener's public API. Built to be called cheaply by AI agents that just need the number.

- **URL**: https://apify.com/zinin/live-price-oracle.md
- **Developed by:** [Tim Zinin](https://apify.com/zinin) (community)
- **Categories:** Agents, Developer tools
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.70 / 1,000 price fetcheds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

## Live Price Oracle — Crypto Price by Symbol or Address

Point this Actor at a token contract address or ticker and get back its current USD price straight from DexScreener's public API, plus 24h change, liquidity and volume from the token's best-liquidity trading pair. No wallet, no RPC node, no API key — built to be called cheaply and often, e.g. by an AI agent quoting a trade over x402.

### What you get

- **Price by address or ticker.** Pass an EVM `0x…` address, a Solana base58 address, or a plain ticker like `WETH` — one row per entry.
- **The full picture on the best pair**: current USD price, 24h price change, that pair's liquidity and 24h volume, and which DEX and chain it trades on.
- **Chain-scoped lookups.** Set `chainId` to pin the search to one EVM chain (Ethereum, BSC, Base, Polygon, Arbitrum). Pass a chain this Actor doesn't recognize and the row is rejected outright — `found: false`, free — instead of silently handing back a pair from the wrong chain.
- **PulseChain guard.** PulseChain is a full state-fork of Ethereum, so a pre-fork Ethereum address has an unrelated "twin" there with unrelated liquidity that could otherwise silently outrank the real chain. PulseChain pairs are excluded unless they're the only match.
- **Stablecoin sanity guard.** Query a canonical USDC/USDT/DAI address and the matched pair prices it outside $0.90–$1.10 (e.g. a wrong-chain "twin" pair slipping past the PulseChain guard above) and the row comes back `found: false` with the reason instead of a silently wrong price — free, not charged.
- **Built for high-frequency calls.** Concurrency up to 20, keyless, no signup — cheap enough for an agent to hit before every quote or trade-sizing decision, not just once a day.
- Runs on Apify: schedule it, monitor it, call it from the API or the MCP server, export to JSON/CSV/Excel, or push straight into your own pipeline.

### Who uses it

- **Trading bots and AI agents** — a keyless, per-call price source cheap enough to hit before every quote or trade.
- **Portfolio trackers** — refresh USD value across a token list without running a node.
- **Researchers and dashboards** — pull price, liquidity and volume for a token list in one run.

### How to run it

1. Click **Try for free** — no card needed on the free plan.
2. Paste contract addresses or tickers into **Tokens**, one per row, and optionally set **Chain ID** to pin the search to a single EVM chain.
3. Press **Start** and read the results from the dataset — UI, API or webhook.

### Pricing

Pay-per-event: **$0.005 per run start + $0.002 per result**. No monthly seat. 100 tokens cost about **$0.21**; 1,000 tokens about **$2.01**.

A token that could not be priced — not found on the requested chain, or an unrecognized `chainId` — is still returned with `found: false` and the reason, and it is **not** charged for. You pay for a price, not for an attempt.

### 简体中文说明

输入代币合约地址（EVM `0x…` 或 Solana base58）或代币代码（如 `WETH`），此 Actor 会直接从 DexScreener 的公开 API 返回该代币当前美元价格，以及流动性最高交易对的 24 小时涨跌幅、流动性和成交量、所在的 DEX 和链。无需钱包、无需 RPC 节点、无需密钥，专为高频调用设计——并发最高 20，足够便宜，可以让交易机器人或 AI 代理在每次报价或下单前都查一次（例如按次付费的 x402 场景）。

可以用 `chainId` 把查询限定在一条 EVM 链上（以太坊、BSC、Base、Polygon、Arbitrum）；传入本 Actor 不认识的链会直接免费返回 `found: false`，不会悄悄拿一条错误链上的交易对凑数。同一个合约地址若在多条链上都有交易对，本 Actor 默认取流动性最高的一个；PulseChain 是以太坊主网的完整分叉，会有一个流动性完全不同的"分身"交易对，除非是唯一匹配结果，否则会被排除，避免干扰对知名代币的判断。

计费为按事件付费：每次运行 $0.005，每个成功查到价格的代币 $0.002（`result-found`）。查不到价格的代币（该链上没有交易对，或 `chainId` 无法识别）仍会以 `found: false` 返回原因，**不计费**。100 个代币约 $0.21，1000 个约 $2.01。

**这不是什么。** 这是一个价格数据源，**不构成财务建议**——只呈现 DexScreener 公开数据展示的价格、流动性和成交量，不包含任何买入、卖出或持有的建议，交易前请自行核实。

### Input

| Field | Type | Description |
|-------|------|-------------|
| `tokens` | array of strings | Contract addresses (EVM `0x…` or Solana base58) or tickers/search terms. Up to 100. One row per entry. |
| `chainId` | integer | Optional. Restrict to one EVM chain: 1=Ethereum, 56=BSC, 8453=Base, 137=Polygon, 42161=Arbitrum. An unrecognized chainId is rejected for free rather than falling through unfiltered. Leave empty to accept the best pair on any chain. |
| `maxConcurrency` | integer | Parallelism (1–20, default 10). |

```json
{
  "tokens": ["0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48", "WETH"]
}
```

### Output

One dataset row per input. This is a real row from a real run:

```json
{
  "input": "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
  "found": true,
  "chainId": "ethereum",
  "symbol": "USDC",
  "priceUsd": 1.00083,
  "priceChangeH24": -0.01,
  "liquidityUsd": 884338.84,
  "volumeH24": 46805699.37,
  "pairAddress": "0x0fb0e40cec3bb23e13abc585958a93c796fbea56955e19a23727a716a0423239",
  "dexId": "uniswap",
  "source": "dexscreener",
  "asOf": "2026-07-26T13:20:21.757Z",
  "summary": "USDC: $1.00083 (24h -0.0%)",
  "checkedAt": "2026-07-26T13:20:21.757Z"
}
```

| Field | Description |
|-------|--------------|
| `input` | The address or search term you passed |
| `found` | Whether a price was found |
| `chainId` / `dexId` / `pairAddress` | Where the best pair trades |
| `symbol` | The token's ticker |
| `priceUsd` | Current price in USD |
| `priceChangeH24` | 24h price change, percent |
| `liquidityUsd` / `volumeH24` | The best pair's pool liquidity and 24h volume |
| `source` | Always `"dexscreener"` |
| `asOf` / `checkedAt` | When this price was pulled |
| `summary` | Human-readable one-liner: `"{symbol}: $x (24h {change}%)"` |
| `error` | Present only when `found: false` — why no price was returned, including an unsupported `chainId` |

### API

Start a run with a bearer token and explicit JSON input:

```bash
curl -sS -X POST 'https://api.apify.com/v2/acts/zinin~live-price-oracle/runs?waitForFinish=60' \
  -H "Authorization: Bearer $APIFY_TOKEN" \
  -H 'Content-Type: application/json' \
  --data '{"tokens":["0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48","WETH"]}'
```

Read Dataset rows using the returned `defaultDatasetId`:

```bash
curl -sS "https://api.apify.com/v2/datasets/$DEFAULT_DATASET_ID/items?clean=true&format=json" \
  -H "Authorization: Bearer $APIFY_TOKEN"
```

### MCP

For an Apify MCP client exposing the standard `call-actor` tool, send this exact payload:

```json
{
  "name": "call-actor",
  "arguments": {
    "actor": "zinin/live-price-oracle",
    "input": {
      "tokens": ["0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48", "WETH"]
    }
  }
}
```

#### Related tools

Related tools for adjacent workflows in crypto and wallets, data pipelines for AI applications.

| Actor | What it does |
|---|---|
| [Token Launch Radar](https://apify.com/zinin/token-launch-radar) | Pair it in the crypto and wallets workflow: Look up any token contract address or ticker across DEXes and get liquidity, 24h volume, pair age, a 0-100... |
| [URL to Markdown Converter](https://apify.com/zinin/url-to-markdown) | Pair it in the data pipelines for AI applications workflow: Fetch any URL and convert it into clean, LLM-ready Markdown — headings, links, lists and emphasis... |
| [Whale Wallet Tracker](https://apify.com/zinin/whale-wallet-tracker) | Pair it in the crypto and wallets workflow: Track large native ETH and ERC-20 token movements for any wallet(s) via Etherscan's multichain API (bring... |
| [Structured Data Extractor](https://apify.com/zinin/structured-extract) | Pair it in the data pipelines for AI applications workflow: Turn any URL into clean structured JSON — title, description, image, JSON-LD, headings, links, emails and... |
| [Rug Pull Risk Scorer](https://apify.com/zinin/rug-pull-scorer) | Pair it in the crypto and wallets workflow: Score ERC-20/BEP-20 token rug-pull risk from honeypot.is simulation + DexScreener liquidity/age |

### FAQ / Limitations

**Does it need an API key or wallet?** No — DexScreener's public API is free and keyless.

**How fresh is the data?** As fresh as DexScreener's own feed — typically seconds to a couple of minutes behind the DEX itself.

**What happens if I pass a chain the token doesn't trade on, or a chain this Actor doesn't know?** An unrecognized `chainId` is rejected up front — `found: false`, not charged. A recognized chain with no pair for that token also comes back `found: false`, with the reason spelled out.

**How is "best pair" chosen?** Highest liquidity on the requested chain (or across all chains if `chainId` is left empty), with PulseChain excluded unless it's the only match — see "PulseChain guard" above.

**Can I call it from an AI agent?** Yes — it's a standard Apify Actor, callable via the Apify API or the Apify MCP server, and cheap enough to call per quote.

**What this is NOT.** This is a price feed, not financial advice. It reports what DexScreener's public API shows — price, liquidity and volume — and nothing more. Nothing in its output is a recommendation to buy, sell or hold any token; verify independently before trading on it.

Found a wrong result, or need a chain we don't cover? Open an issue on this Actor's page.

### Machine use

The Actor is callable through the Apify API, SDK, and Apify MCP server. The input and Dataset row are the machine-facing contract: `found: false` on a row is a real, free answer (unrecognized chain, no pair on the requested chain), not an error to retry blindly, and `priceUsd`/`liquidityUsd`/`volumeH24` are a price feed reading, not a trading recommendation — an agent quoting a trade off this data should still apply its own risk checks.

***

Built by [zinin](https://apify.com/zinin). Questions? Telegram [@timzinin](https://t.me/timzinin).

# Actor input Schema

## `tokens` (type: `array`):

Token contract addresses (EVM `0x…` or Solana base58) or tickers/search terms (e.g. `WETH`, `PEPE`). One row per entry.

## `chainId` (type: `integer`):

Restrict results to one EVM chain: 1=Ethereum, 56=BSC, 8453=Base, 137=Polygon, 42161=Arbitrum. Leave empty to accept the best pair on any chain.

## `maxConcurrency` (type: `integer`):

How many tokens to look up in parallel.

## Actor input object example

```json
{
  "tokens": [
    "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
    "WETH"
  ],
  "maxConcurrency": 10
}
```

# Actor output Schema

## `results` (type: `string`):

API URL for the default dataset items produced by this run.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "tokens": [
        "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
        "WETH"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("zinin/live-price-oracle").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "tokens": [
        "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
        "WETH",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("zinin/live-price-oracle").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "tokens": [
    "0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48",
    "WETH"
  ]
}' |
apify call zinin/live-price-oracle --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=zinin/live-price-oracle",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/acts/guq5SidjVKtywT2G9/builds/A1XaoJUcPSGojACXH/openapi.json
