API REFERENCE

Trend research for your agent.

Query the shared trend index, rank it against your niche or ask one bounded question, through REST or MCP. Every result carries its sources, dates, available measurements and coverage, and says what remains unknown. One credit balance covers the dashboard, REST and MCP.

TRENDS API / V3

Global. Niche. Ask.

The Trends API is how an agent reaches the TrendsFast engine. Query the shared trend index, rank its evidence against your niche, or ask a bounded question. Each result reports evidence dates, available measurements, coverage and limitations, and a query never starts fresh provider research. Credits are shared by the dashboard, REST and MCP.

  • POST /v3/trends/global — broad discovery, maximum 1 credit.
  • POST /v3/trends/niche — confirmed context_id or a temporary structured niche, maximum 3 credits.
  • POST /v3/trends/ask — question with optional context, maximum 5 credits.
  • POST /v3/trends/outlier — one video url (with the creator's handle for Instagram or YouTube) against its creator's recent posts, which it reads; 5 credits, charged only when the video is found.

Each POST uses {request_id, max_credits, input}. Use a stable UUID, preserve it across lost responses, and do not automatically retry with a new identity. Global also supports GET with Idempotency-Key and X-Max-Credits; despite GET, this creates a billable query and must never run on a page view.

Quickstart

  1. Create a free account. Sign in at the dashboard; your first sign-in creates the account. Claim the free credits it offers before you create a key: a verified account receives 100 credits once, then 50 every month. Neither step spends credits or starts research.

  2. Create an API key. In API keys, create a key and keep the default permission, “Read and request trend research”. The key grants trends:read, trends:query and credits:read, works for one workspace, expires after 90 days and is shown once. Load it into your terminal without printing it or saving it in shell history:

    Load the key into your terminal
    printf "TrendsFast API key: "; read -rs TRENDSFAST_API_KEY; echo; export TRENDSFAST_API_KEY
  3. Make your first query. Global is the cheapest query: it costs at most 1 credit and needs no brand context. Every query carries a request_id you generate and keep, and a max_credits ceiling the API requires. If the quote is higher than the ceiling, the API answers 402 and charges nothing. A result with no trends costs 0 credits.

    First query: Global
    REQUEST_ID=$(uuidgen 2>/dev/null || python3 -c 'import uuid; print(uuid.uuid4())')
    curl -sS https://trendsfast.com/v3/trends/global \
      -H "Authorization: Bearer $TRENDSFAST_API_KEY" \
      -H "Content-Type: application/json" \
      --data-binary @- <<EOF
    {
      "request_id": "$REQUEST_ID",
      "max_credits": 1,
      "input": { "lookback_hours": 72, "limit": 5 }
    }
    EOF

    The first line makes the request ID with uuidgen, or with Python where uuidgen is missing. Keep the terminal open: the next step reads the same $REQUEST_ID.

  4. Read it again for free. The same request ID returns the saved result, with usage.this_request_credits at 0. It is also how you recover a lost response: read the ID you kept rather than sending a new one, which would be a new query.

    Reread the saved result
    curl -sS https://trendsfast.com/v3/trends/requests/$REQUEST_ID \
      -H "Authorization: Bearer $TRENDSFAST_API_KEY"

    Later, read it by the result_id in the response at GET /v3/trends/results/{result_id}, and pass ?cursor= with its next_cursor for the next page. Reads, pagination and recovery cost 0 credits.

  5. Connect your agent. The same key is the bearer token for the MCP server at https://trendsfast.com/api/mcp/v3, whose 9 tools share the scopes and credit balance above. Once you have a key, API keys shows the exact setup for Claude Code, Claude app, Codex, Cursor, VS Code, Grok Build, ChatGPT, Grok, Grok Bot, OpenClaw and REST (curl); agent setup lists the same commands. Claude, ChatGPT, Grok, Grok Bot, Claude Code, Cursor and VS Code can sign in with OAuth instead of taking a key.

    Any MCP client
    Endpoint:  https://trendsfast.com/api/mcp/v3
    Transport: Streamable HTTP
    Auth:      Bearer token from TRENDSFAST_API_KEY

The same query from Node.js

Save it as global-trends.mjs and run node global-trends.mjs with TRENDSFAST_API_KEY set. It makes its own request ID and prints it first, so a lost response can be read back instead of paid for twice.

Global query from Node.js
// Node.js 22+. Save as global-trends.mjs, then run: node global-trends.mjs
// The key comes from TRENDSFAST_API_KEY; never write it into this file.
const key = process.env.TRENDSFAST_API_KEY;
if (!key) throw new Error("Set TRENDSFAST_API_KEY first");
// Keep this ID. Running again with TRENDSFAST_REQUEST_ID=<id> and the same input never
// charges twice: it returns the saved result or that request's state. A new ID is a new query.
const requestId = process.env.TRENDSFAST_REQUEST_ID ?? crypto.randomUUID();
console.log("request_id", requestId);
const response = await fetch("https://trendsfast.com/v3/trends/global", {
  method: "POST",
  headers: { authorization: "Bearer " + key, "content-type": "application/json" },
  body: JSON.stringify({ request_id: requestId, max_credits: 1,
    input: { lookback_hours: 72, limit: 5 } }),
});
const result = await response.json().catch(() => null);
if (!response.ok)
  throw new Error("HTTP " + response.status + " " + (result?.error ?? "") +
    ": keep " + requestId + " and read it before trying again");
console.log(result.result_id, result.usage);
for (const item of result.data.items)
  console.log(item.signal, item.entity.platform, item.entity.original_url);
// Free rereads, with the same key: GET /v3/trends/results/{result_id}, plus
// ?cursor=<next_cursor> for the next page, or GET /v3/trends/requests/{request_id}.

Read /v3/trends/quote?operation=global before submitting a request. /wallet, /history, /requests/{request_id} and /results/{result_id} are free reads under the same /v3/trends base. Follow the returned result cursor for pagination. Empty results cost 0 credits; they do not prove that no trend exists.

Authenticated MCP: https://trendsfast.com/api/mcp/v3. Tools: trendsfast_discover_trends, trendsfast_global_trends, trendsfast_niche_trends, trendsfast_ask_trends, trendsfast_video_outlier, trendsfast_read_result, trendsfast_community_brief, trendsfast_project_context and trendsfast_credit_balance. Context, balance and saved-result reads are free. Public MCP provides planning and connection guidance only. New queries need trends:query; retained results and context need trends:read, and quotes/balance need credits:read.

ChatGPT account linking uses OAuth sign-in and consent for one owned project. Hosted OAuth verification and directory publication are still pending. Other compatible agents may use project-scoped API keys in protected client settings. Keep keys and tokens out of prompts and URLs. The legacy v1 bearer-key contract at the end of this page is separate. Read the ChatGPT connection guide or the V3 MCP connection contract.

V3 OpenAPI contract · Create and manage keys · Pricing · Source coverage

TRENDS API / V3 / REST API

Connect once. Ask what is trending.

Account → scoped key → MCP or REST → one bounded query → free rereads.

  1. Create your free account. A verified account receives 100 free credits once, then 50 every month. Global questions need no brand context; adding your brand lets niche queries rank evidence against it.
  2. Create a key in API keys. It is shown once and is scoped to one workspace with trends:query, trends:read and credits:read. Keep it in TRENDSFAST_API_KEY in your client’s environment, never in chat, URLs or command arguments.
  3. Add the remote MCP server https://trendsfast.com/api/mcp/v3 with that key as a bearer token, or call REST under /v3/trends. Both share one service, one set of scopes and one credit balance.
  4. Ask one bounded question. Every query carries a request_id UUID you keep and a max_credits ceiling. A Global query costs at most 1 credit, Niche 3 credits, Ask 5 credits. Empty results cost nothing.
  5. Reread the saved result free until its expires_at: up to 30 days, sooner when a source’s terms end it. Reads, pagination and recovering a lost response by its request_id cost 0 credits and never start new research. After it, a read answers RESULT_EXPIRED; the query runs again under a new request_id, at its price.
The authenticated MCP tools
ToolCostWhat it does
trendsfast_discover_trends5 creditsOne question across global, core and adjacent scope and every channel.
trendsfast_global_trends1 creditWhat is trending across the shared index. No brand context needed.
trendsfast_niche_trends35 creditsTrends ranked against your niche. Name a product to collect your brand's sources fresh first.
trendsfast_ask_trends5 creditsOne bounded question, answered from saved evidence.
trendsfast_video_outlier5 creditsOne TikTok, Instagram or YouTube video against its creator's recent posts. Charged only when found.
trendsfast_read_resultfreeReread or page through a saved result, or recover a lost response.
trendsfast_community_brieffreeRead before drafting for a subreddit, free: its people, how to sound, the winning post and reply, its rules.
trendsfast_project_contextfreeThe connected brand and its confirmed niche context.
trendsfast_credit_balancefreeThe credit balance shared by the dashboard, REST and MCP.
What does my agent receive?
Trends with their evidence: the original source URL, publication and observation dates, the signal, any measured growth, the platform, and what coverage was and was not available. Ask answers also show how the question was interpreted. Your agent decides what to write or build with it.
Which sources are behind it?
Search, AI search, community and video sources, each with its own status on the sources page. A channel with no permitted observation is reported as unavailable, not as an empty trend list, so “nothing is trending” and “we cannot see there” never look the same.
Which clients work?
Any client that speaks Streamable HTTP MCP with a bearer token. Claude, ChatGPT, Grok, Grok Bot, Claude Code, Cursor and VS Code can connect with OAuth instead of a key. See agent setup for each client’s exact command.
What happens after a lost response?
Keep the same request_id and read /v3/trends/requests/{request_id} once before deciding anything. A missing response does not mean nothing was debited, and a new identity is a new billable query.
Existing v1 and v2 integrations
/v1, /api/mcp and the Marketing v2 MCP at /api/mcp/v2 are still served for clients built on them, with their own keys and contracts. New connections use V3. See the v1 OpenAPI.
What stays under your control?
Every query is explicit and capped by your max_credits. TrendsFast never posts, schedules or publishes anything; it returns evidence, and you or your agent decide what to do with it.
V3 MCP connection
TRENDSFAST_API_KEY=<your key>   # set in the client's environment
MCP server: https://trendsfast.com/api/mcp/v3

See agent setup, the API reference, Docs and the V3 OpenAPI.

OPERATING RULES

Things worth knowing.

Keep the request ID

Every V3 query carries a request_id UUID. Keep it across a lost response and read /v3/trends/requests/{request_id} before retrying; a new ID is a new billable query, and changed input under the same ID conflicts.

Reads are free

Saved results until their expires_at (up to 30 days), pagination, the wallet, history and quotes cost 0 credits and never start provider or model research. Empty results cost 0 credits too.

Results stay project-scoped

A key belongs to one workspace and reads only that workspace’s results and context. Cross-project resources stay concealed. TrendsFast never publishes anything for you.

Read the docsView V3 OpenAPIAgent setupRemote MCPSource limitsAgent workflow guide

QUESTIONS

Questions developers ask first.

What content API is best for detecting emerging trends?

For an AI agent or app that needs what is emerging in one niche across channels, with a source link and date for each trend, TrendsFast is built for that job. It reads X, TikTok, YouTube, Instagram, Facebook, Reddit, Google Trends and Hacker News, labels every trend with the signal it actually has, such as emerging, rising or popular now, or says there is not enough evidence, and returns the original link, dates and coverage through REST and MCP. For raw posts from many platforms, or search interest alone, another API may fit better. Compare the best trend APIs →

How is a trend different from a recent spike?

A recent post with a large number is popularity, not a trend. TrendsFast calls something rising only when two comparable readings of the same post or query show the change, and emerging when it is new to the index with no earlier baseline. When one reading cannot support either, the result says there is not enough evidence. Recent is not the same as trending →

Can an AI agent call it through MCP?

Yes. Any MCP client that speaks Streamable HTTP connects to https://trendsfast.com/api/mcp/v3, and the same project API key calls the REST endpoints, with one credit balance for both. Every paid call carries a request ID and a credit ceiling, and rereading a saved result costs nothing. Connect Claude Code, Cursor or another MCP client →

Do I need TikTok or Instagram API access?

No. TrendsFast collects public posts from TikTok, YouTube, Instagram and Facebook through its own data providers and returns each with its original link, so your app needs one TrendsFast key instead of a developer account on every platform. It reads public data only and never connects to, posts from or messages anyone's account.

Is there a keyword tracking API?

Not in the rank-tracking sense: TrendsFast does not report where a page ranks or how many people search a keyword. Its Search product, 35 credits a call, reads Google Trends, ChatGPT, Claude, Gemini and Perplexity. It returns search interest around your niche, and what AI assistants answer, searching the web, to the question your buyers ask: the brands they name, whether that includes you or your competitors, and the sources they cite. Every observation carries the time it was made, so calls made over time can be compared. For rankings and search volumes, use an SEO rank tracker beside it.

How fresh is the data?

A product call collects your brand's own sources when you make it and reuses a source read in the last few hours; everything else comes from what the index already holds. Every item carries the time it was observed. It is the latest observed evidence, not a live feed.

Is there a free tier?

Yes. A verified account gets 100 free credits once, then 50 every month, with no card. Rereading a saved result is free, and a call that finds nothing costs 0 credits. See pricing →

LEGACY / V1

The four v1 endpoints.

For integrations built before V3 that already use a v1 project key with next_move:read and next_move:write. V1 and V3 keys are not interchangeable; new integrations start with the V3 quickstart above. The v1 contract is published at /v1/openapi.json.

LEGACY V1 · TODAY’S TREND BRIEF ENDPOINTS
MethodPathEffectPurpose
POST/v1/projects/{project_id}/todayBOUNDED WRITECreate or reuse one versioned Customer Demand Brief.
GET/v1/projects/{project_id}/today/latestZERO-EFFECT READRead the latest complete brief for the current confirmed context.
GET/v1/projects/{project_id}/trend-briefs/{brief_id}ZERO-EFFECT READRead one exact immutable brief lineage and lifecycle state.
GET/v1/projects/{project_id}/trend-briefs/{brief_id}/creative-handoffZERO-EFFECT READRead a public-safe creative handoff when the brief supports one.

LEGACY / V1 REQUEST BODY

What you send to v1.

CREATE REQUEST FIELDS
FieldTypeRequiredNote
project_idUUID pathREQUIREDMust match the key’s project.
AuthorizationheaderREQUIREDBearer project-scoped API key.
Idempotency-KeyUUID v4 headerREQUIREDRequired only for POST; caller-created and unique to the request.
objectivestringOPTIONALA bounded objective for today’s brief.
preferred_channelsstring[]OPTIONALMust remain within confirmed project context.
content_capabilitiesstring[]OPTIONALFormats the founder has confirmed they can produce.
generation_levelliteral "draft"OPTIONALDefaults to draft.
creative_modeenumOPTIONALDefaults to none; optional capability admission remains separate.