Get ticker
curl --request POST \
--url https://api.aisa.one/apis/v1/api-exchange-coinbase-com/markets/get-ticker \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"product_id": "BTC-USD"
}
'import requests
url = "https://api.aisa.one/apis/v1/api-exchange-coinbase-com/markets/get-ticker"
payload = { "product_id": "BTC-USD" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({product_id: 'BTC-USD'})
};
fetch('https://api.aisa.one/apis/v1/api-exchange-coinbase-com/markets/get-ticker', 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://api.aisa.one/apis/v1/api-exchange-coinbase-com/markets/get-ticker",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'product_id' => 'BTC-USD'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.aisa.one/apis/v1/api-exchange-coinbase-com/markets/get-ticker"
payload := strings.NewReader("{\n \"product_id\": \"BTC-USD\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.aisa.one/apis/v1/api-exchange-coinbase-com/markets/get-ticker")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"product_id\": \"BTC-USD\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/api-exchange-coinbase-com/markets/get-ticker")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"product_id\": \"BTC-USD\"\n}"
response = http.request(request)
puts response.read_body{
"ask": "84528.11",
"bid": "84525.99",
"observed_at_ms": 1790268797121,
"price": "84525.99",
"product_id": "BTC-USD",
"rfq_volume": "44.427295",
"size": "0.00000054",
"source_url": "https://api.exchange.coinbase.com/products/BTC-USD/ticker",
"stats": {
"high": "84929.78",
"last": "84510.6",
"low": "82708.96",
"open": "84030.1",
"rfq_volume_24hour": "44.406101",
"rfq_volume_30day": "3072.450663",
"volume": "7401.34907045",
"volume_30day": "192387.3321936"
},
"stats_url": "https://api.exchange.coinbase.com/products/BTC-USD/stats",
"time": "2026-09-24T16:53:16.482700292Z",
"trade_id": 1097948756,
"volume": "7384.66321691"
}Coinbase Exchange
Get ticker
Current price and 24h range of a pair; poll it instead of the order book when you only need best bid/ask.
POST
https://api.aisa.one
/
apis
/
v1
/
api-exchange-coinbase-com
/
markets
/
get-ticker
Get ticker
curl --request POST \
--url https://api.aisa.one/apis/v1/api-exchange-coinbase-com/markets/get-ticker \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"product_id": "BTC-USD"
}
'import requests
url = "https://api.aisa.one/apis/v1/api-exchange-coinbase-com/markets/get-ticker"
payload = { "product_id": "BTC-USD" }
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({product_id: 'BTC-USD'})
};
fetch('https://api.aisa.one/apis/v1/api-exchange-coinbase-com/markets/get-ticker', 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://api.aisa.one/apis/v1/api-exchange-coinbase-com/markets/get-ticker",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'product_id' => 'BTC-USD'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.aisa.one/apis/v1/api-exchange-coinbase-com/markets/get-ticker"
payload := strings.NewReader("{\n \"product_id\": \"BTC-USD\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.aisa.one/apis/v1/api-exchange-coinbase-com/markets/get-ticker")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"product_id\": \"BTC-USD\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.aisa.one/apis/v1/api-exchange-coinbase-com/markets/get-ticker")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"product_id\": \"BTC-USD\"\n}"
response = http.request(request)
puts response.read_body{
"ask": "84528.11",
"bid": "84525.99",
"observed_at_ms": 1790268797121,
"price": "84525.99",
"product_id": "BTC-USD",
"rfq_volume": "44.427295",
"size": "0.00000054",
"source_url": "https://api.exchange.coinbase.com/products/BTC-USD/ticker",
"stats": {
"high": "84929.78",
"last": "84510.6",
"low": "82708.96",
"open": "84030.1",
"rfq_volume_24hour": "44.406101",
"rfq_volume_30day": "3072.450663",
"volume": "7401.34907045",
"volume_30day": "192387.3321936"
},
"stats_url": "https://api.exchange.coinbase.com/products/BTC-USD/stats",
"time": "2026-09-24T16:53:16.482700292Z",
"trade_id": 1097948756,
"volume": "7384.66321691"
}请求规范
- 方法与路径: POST /apis/v1/api-exchange-coinbase-com/markets/get-ticker
- 可用状态: enabled
- 请求 URL 模板:
https://api.aisa.one/apis/v1/api-exchange-coinbase-com/markets/get-ticker
{
"operationId": "api-exchange-coinbase-com.markets.get-ticker",
"method": "POST",
"path": "/apis/v1/api-exchange-coinbase-com/markets/get-ticker",
"servers": [
{
"url": "https://api.aisa.one"
}
],
"parameters": [],
"security": [
{
"bearerAuth": []
}
],
"requestBody": {
"content": {
"application/json": {
"examples": {
"provider": {
"summary": "Official provider example; checked against AIsa request constraints",
"value": {
"product_id": "BTC-USD"
}
}
},
"schema": {
"additionalProperties": true,
"properties": {
"product_id": {
"description": "Trading pair id `BASE-QUOTE` as listed by `list_products`, e.g. `BTC-USD`, `USELESS-USD`. Case-insensitive; the canonical upper-case id is returned. Pattern: ^[A-Za-z0-9]{1,20}-[A-Za-z0-9]{1,20}$.",
"type": "string"
}
},
"required": [
"product_id"
],
"type": "object"
}
}
},
"required": true
},
"x-aisa-status": "enabled",
"components": {
"securitySchemes": {
"bearerAuth": {
"scheme": "bearer",
"type": "http"
}
}
}
}
费用与请求规则
按实际用量收费。 默认请求预估费用:$0.0005 USD。 最终费用以实际用量为准。 账户适用价格可能不同;支持报价的接口可按实际请求获取报价。授权
请求体
application/json
响应
Market snapshot for one trading pair: last trade price, size, id and time, best bid and ask and 24h volume (GET /products/{product_id}/ticker) together with the 24h/30d statistics (GET /products/{product_id}/stats: open, high, low, last, volume). Prices and sizes are decimal strings in the pair's quote and base currency.
The response contains the tool result directly.
| Documented field | Provider type | Description |
|---|---|---|
ask | string | Decimal string exactly as the exchange sends it (never converted to a float). Best ask; null when the exchange sends none. |
bid | string | Decimal string exactly as the exchange sends it (never converted to a float). Best bid; null when the exchange sends none (no resting bids). |
observed_at_ms | number | Milliseconds since the Unix epoch when this call ran. |
price | string | Decimal string exactly as the exchange sends it (never converted to a float). Last trade price. |
product_id | string | Canonical upper-case product id. |
rfq_volume | string | Decimal string exactly as the exchange sends it (never converted to a float). 24h RFQ volume; null when the exchange omits it. |
size | string | Decimal string exactly as the exchange sends it (never converted to a float). Last trade size. |
source_url | string | The upstream request URL this record was shaped from. |
stats | object | 24-hour statistics from GET /products/{id}/stats; a field is null when the exchange omits it or sends an empty string (thin or halted markets). |
stats_url | string | The /stats request URL. |
time | string | Time of the last trade, RFC 3339 UTC. |
trade_id | number | Id of the last trade; the same space as list_trades cursors. |
volume | string | Decimal string exactly as the exchange sends it (never converted to a float). 24h base-currency volume. |
These are the provider's documented fields. Field requiredness, nullability and nested object structures are specified only where the descriptions explicitly say so.