TradeMCP News Docs

Authentication

API keys, scopes, rate limits and error codes.

Send your key in the X-API-Key header on every request. The WebSocket stream takes it as the api_key query parameter instead. Responses are JSON, and every time is UTC ISO-8601.

curl -s https://news.trademcp.dev/v1/assets -H "X-API-Key: dp_<prefix>_<secret>"

Scopes

Each key carries the scopes it may use. A request outside them is answered with 403.

ScopeGrants
news:read/v1/news/*
sentiment:read/v1/assets*
alerts:readread your alert rules and delivery log, dry-run rules
alerts:writecreate, change and delete rules, retry deliveries (includes alerts:read)
stream:readthe /v1/stream WebSocket

Managing keys

Create, rotate and revoke keys in the dashboard (organization admins; members can view).

  • Rotate creates a replacement key with the same name and scopes. The old key keeps working for 24 hours so you can roll the new one out, then stops. Revoke it early once you have switched.
  • Revoke stops a key within 30 seconds.
  • Your plan sets how many active keys you can hold; keys in their rotation grace period do not count.

Rate limits

Your organization has one per-minute request budget, set by its plan, that all of its keys share (a key may also have a lower limit of its own). Every response carries X-RateLimit-Limit and X-RateLimit-Remaining for the tightest applicable limit; past it you get 429 with a Retry-After header (seconds). The dashboard's usage page lists recent rate-limit events.

Errors

StatusMeaning
400Malformed input, for example an invalid pagination cursor
401Missing or invalid key
403The key lacks the scope for this endpoint
404No such article, rule or delivery (or not yours)
409Conflict, for example your plan's alert-rule limit is reached
422Validation failed; the body lists each invalid field
429Rate limited; retry after Retry-After seconds

On this page