Farcaster cast volume
POST /api/fc-cast-metricsCast volume over time for a search query: how many Farcaster casts matched per bucket across the last 1d, 7d, 30d, 90d or 180d (hourly or daily buckets), optionally limited to one author or channel, plus the total. Send POST /api/fc-cast-metrics with the required field q and pay $0.005 per call over x402 or MPP (there is no free tier). It returns a JSON object with source, fetchedAt, cached, rateLimit, query and 7 more.
Cached 60 s. Use to chart mention volume for a token, product or event and detect spikes.
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
q | string | yes | Search text (1-256 chars). Also accepted as query, search, term, keyword. |
interval | string (one of: 1d, 7d, 30d, 90d, 180d) | no | Lookback window (default 7d). |
authorFid | integer | no | Only casts by this fid. |
channel | string | no | Only casts in this channel id. |
Example request
curl -i -X POST https://agent402.tools/api/fc-cast-metrics \
-H "Content-Type: application/json" \
-d '{"q":"x402","interval":"7d"}'Without payment this returns HTTP 402 Payment Required with the exact price for fc-cast-metrics; any x402 v2 or MPP client pays it and retries.
Watch a call get paid
POST /api/fc-cast-metrics$0.005 USDCPAYMENT-SIGNATUREon 14 chains200 OKAgent402-ReceiptEd25519Example response
{
"source": "neynar",
"fetchedAt": "2026-08-22T13:19:12.000Z",
"cached": false,
"rateLimit": {
"limit": 300,
"remaining": 299,
"resetAt": "2026-08-22T13:20:00.000Z"
},
"query": "x402",
"interval": "7d",
"authorFid": null,
"channel": null,
"resolutionSeconds": 3600,
"total": 42,
"bucketCount": 168,
"buckets": [
{
"start": "2026-08-15T15:00:00.000Z",
"count": 1
},
{
"start": "2026-08-15T16:00:00.000Z",
"count": 7
}
]
}| Field | Type | Always present | In the example |
|---|---|---|---|
source | string | yes | neynar |
fetchedAt | string | yes | 2026-08-22T13:19:12.000Z |
cached | boolean | yes | false |
rateLimit | object | yes | 3 fields: limit, remaining, resetAt |
query | string | yes | x402 |
interval | string | yes | 7d |
authorFid | null | no | null |
channel | null | no | null |
resolutionSeconds | number | yes | 3600 |
total | number | yes | 42 |
bucketCount | number | yes | 168 |
buckets | array of objects | yes | 2 items in the example |
From an MCP client
catalog.call {
"slug": "fc-cast-metrics",
"params": {
"q": "x402",
"interval": "7d"
}
}The hosted connector at https://agent402.tools/mcp needs a payment for fc-cast-metrics; the stdio package pays it from a wallet or from an AGENT402_CREDITS_KEY issued earlier. Local install: npx -y agent402-mcp@0.14.0.
Errors and behavior
qis required. An input the tool rejects returns an HTTP 4xx whose body carrieserror,tool,expected,requiredandexample, so the caller can correct it.- A paid call that ends in any status of 400 or above is not charged over x402, MPP or a prepaid credits key: settlement runs after the tool and only on a successful response. The exception is a Tempo push credential, a transfer the buyer sent before the call: it settles before the tool runs, so if the tool then fails the payment is recorded as a refund owed to the paying wallet.
- Wallet-only: this tool reaches the network or stored state, so it has no proof-of-work tier. A prepaid card-credits key issued earlier (
Authorization: Bearer a402_...) also pays it. - A
GETorHEADto /api/fc-cast-metrics returns the same 402 quote, so the price can be read without a body. - An
Idempotency-Keyheader makes a retried paid call replay the first 200 instead of charging again (an answer larger than 1 MB is not replayed).
Paid call (JavaScript agent)
import { wrapFetchWithPayment } from "@x402/fetch";
import { x402Client } from "@x402/core/client";
import { registerExactEvmScheme } from "@x402/evm/exact/client";
import { privateKeyToAccount } from "viem/accounts";
const client = new x402Client();
client.setSpendControls?.({ maxAmountPerPayment: "$0.005" }); // refuse any quote above this tool's price
registerExactEvmScheme(client, { signer: privateKeyToAccount(KEY) });
const payFetch = wrapFetchWithPayment(fetch, client);
const res = await payFetch("https://agent402.tools/api/fc-cast-metrics", {
method: "POST",
headers: { "Content-Type": "application/json" },
body: JSON.stringify({
"q": "x402",
"interval": "7d"
}),
});Related tools
Farcaster cast search
Search Farcaster casts by keyword (literal, semantic or hybrid match), newest first, optionally filtered to one author.
Farcaster cast lookup
Fetch one Farcaster cast by hash or warpcast.com / farcaster.xyz URL.
Farcaster cast replies
The reply thread under a Farcaster cast (by hash or URL): the root cast plus replies flattened with their depth (1-5.
Farcaster channel details
Details for one Farcaster channel by id (e.g. base) or FIP-2 parent URL: name, description, follower and member counts.
Farcaster channel feed
Latest casts in one or more Farcaster channels (e.g. base, farcaster, ethereum), newest first, with optional replies.
Farcaster trending channels
Trending Farcaster channels ranked by casting activity over 1d, 7d or 30d, with cast counts for all three windows.