trades: Get recent trades

API: coinbase.com:coinbase-pro-api
Endpoint: /products/{product_id}/trades
Response format: application/json
Auth: none
Method: GET
Last Status: 200
Latency: 206ms

Description

Returns the most recent trades (market executions) for a trading pair. Use this to display recent activity, analyze trading patterns, and verify recent price movements.

From spec: Get a list of the latest trades for a product, sorted by time (descending).

Usage Tips

- Results are paginated; use 'after' parameter for older trades - 'side' indicates if trade was buyer-maker or seller-maker - 'size' is the amount traded in base currency - Results sorted by time descending (newest first)

Parameters (4)

after (string, query, optional)

Return trades after this trade ID (pagination)

before (string, query, optional)

Return trades before this trade ID (pagination)

limit (integer, query, optional, default: 100)

Number of trades to return (max 1000)

Constraints: {'minimum': 1, 'maximum': 1000}

product_id (string, path, required)

Product ID (e.g., BTC-USD)

Examples (1)

Get BTC-USD recent trades probe-gate

Demonstrates retrieving the most recent executed trades showing trade side, size, price, and timestamp for market activity analysis.

curl 'https://api.exchange.coinbase.com/products/BTC-USD/trades'
import requests

resp = requests.get("https://api.exchange.coinbase.com/products/BTC-USD/trades")
data = resp.json()
import zingu_apis

api = zingu_apis.api("coinbase-pro")
result = api.fetch("products/{product_id}/trades")

for item in result:
    print(item)
const resp = await fetch("https://api.exchange.coinbase.com/products/BTC-USD/trades");
const data = await resp.json();

Probe History

Latency

Status Codes

TimeStatusLatencySize
2026-04-16 17:44:58.253724 200 206ms
2026-04-16 02:26:42.790176 200 272ms
2026-04-15 00:53:00.115996 200 485ms
2026-04-14 00:15:20.913828 200 304ms
2026-04-12 13:59:07.026890 200 150ms
2026-04-10 01:47:21.633882 200 238ms
2026-04-09 01:54:22.179487 200 457ms
2026-04-08 07:54:26.562555 200 177ms
2026-04-07 00:43:15.284155 200 169ms
2026-04-05 16:45:37.380446 ERR