RealComposer

CoinMarketCap Safe & Unsafe Practices

Direct Answer

CoinMarketCap Pro API keys are server-only. Quote and metadata endpoints should run behind a cacheable GET proxy keyed by symbol so dashboards do not burn quota on every page view.

Credentials & Where They Belong

Server only
X-CMC_PRO_API_KEY

Professional API key billed per call.

Safe Practices

  • Cache quotes with a short TTL

    Crypto prices do not need sub-second freshness for most dashboards; 60 to 300 second edge cache is typical.

  • Fix symbols in the pipeline URL

    Clients pass query.symbol; the Worker injects the API key header server-side.

Unsafe Practices

  • Shipping the Pro key to browser chart libraries

    Scrapers can exhaust monthly credits and inflate your bill.

The RealComposer Pattern

Store COINMARKETCAP_API_KEY in the vault, enable GET cache TTL on /v1/cryptocurrency/quotes/latest, and return only price and percent change fields.

START BUILDING FREE

Frequently Asked Questions

Q:Can I cache CoinMarketCap responses at the edge?

Yes for identical symbol query strings. RealComposer GET cache keys include sorted query params, not client tokens.

CoinMarketCap Recipes

Related Concepts