Get Token Price Snapshot
curl --request GET \
--url https://demo-api.mobula.io/api/2/token/price-atimport requests
url = "https://demo-api.mobula.io/api/2/token/price-at"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://demo-api.mobula.io/api/2/token/price-at', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://demo-api.mobula.io/api/2/token/price-at",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://demo-api.mobula.io/api/2/token/price-at"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://demo-api.mobula.io/api/2/token/price-at")
.asString();require 'uri'
require 'net/http'
url = URI("https://demo-api.mobula.io/api/2/token/price-at")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"data": {
"name": "<string>",
"symbol": "<string>",
"logo": "<string>",
"priceUSD": 123,
"marketCapUSD": 123,
"marketCapDilutedUSD": 123,
"timestamp": 123,
"swapTimestamp": 123,
"poolAddress": "<string>"
}
}Market & Token Data
Get Token Price Snapshot
Retrieve the closest historical token price to a given unix timestamp.
GET
/
2
/
token
/
price-at
Get Token Price Snapshot
curl --request GET \
--url https://demo-api.mobula.io/api/2/token/price-atimport requests
url = "https://demo-api.mobula.io/api/2/token/price-at"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://demo-api.mobula.io/api/2/token/price-at', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://demo-api.mobula.io/api/2/token/price-at",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://demo-api.mobula.io/api/2/token/price-at"
req, _ := http.NewRequest("GET", url, nil)
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://demo-api.mobula.io/api/2/token/price-at")
.asString();require 'uri'
require 'net/http'
url = URI("https://demo-api.mobula.io/api/2/token/price-at")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body{
"data": {
"name": "<string>",
"symbol": "<string>",
"logo": "<string>",
"priceUSD": 123,
"marketCapUSD": 123,
"marketCapDilutedUSD": 123,
"timestamp": 123,
"swapTimestamp": 123,
"poolAddress": "<string>"
}
}Batch Support Available: For batch requests (up to 100 tokens), use the
POST /2/token/price-at endpoint.Query details
| Parameter | Type | Description |
|---|---|---|
blockchain | string | Blockchain name or ID (e.g., “Solana”, “1” for Ethereum) |
address | string | Token contract address |
timestamp | number | Required. Unix timestamp (seconds) for the point-in-time lookup |
Note: Always query using the address, not the name or symbol, to get accurate results.
Response Format
| Field | Type | Description |
|---|---|---|
priceUSD | number | Token price in USD at the closest swap |
timestamp | number | The requested timestamp |
swapTimestamp | number | Actual swap timestamp (ms) used for the price |
poolAddress | string | Pool address where the swap was found |
Usage Examples
curl -X GET "https://api.mobula.io/api/2/token/price-at?address=0xC02aaA39b223FE8D0A0e5C4F27eAD9083C756Cc2&blockchain=ethereum×tamp=1700000000"
Example Response
{
"data": {
"priceUSD": 2012.66,
"timestamp": 1700000000,
"swapTimestamp": 1699999997000,
"poolAddress": "0x88e6a0c2ddd26feeb64f039a2c41296fcb3f5640"
}
}
Query Parameters
Blockchain chain ID (e.g., "evm:56", "solana:solana")
Token contract address
Unix timestamp (seconds) for historical price lookup
Required range:
x > 0Response
200 - application/json
Token price at timestamp response
Show child attributes
Show child attributes
⌘I