Guides for building with MetalAPI
Everything you need to integrate real-time and historical metal, currency and crypto prices — from your first request to webhooks and production best practices.
Getting started
Your first request, authentication and how plan limits work.
Getting Started with MetalAPI
Create a free account, get your API key and make your first request for live gold, silver, platinum and palladium prices.
API Authentication
Send your API key as a query parameter or header, restrict keys to your own domains and keep them safe.
Rate Limits & Plans
How monthly quotas, per-minute limits and update intervals work on each plan, and how to track your usage.
API reference
Endpoints, response formats, units and error codes.
Available Endpoints
Every MetalAPI endpoint and its parameters: latest, historical, convert, timeframe, change, OHLC, carat, symbols, usage and stream.
Error Handling
MetalAPI error codes, their HTTP status codes, and how to handle and retry failed requests.
Data Formats & Units
How rates are expressed, choosing a base currency and mass unit, bid/ask and karat prices, timestamps and market hours.
API Documentation Overview
A one-page tour of the MetalAPI REST API: base URL, authentication, parameters, response format, errors, rate limits and code examples.
Advanced topics
Historical analysis, webhooks, widgets and running in production.
Embeddable Price Widgets
Show live metal prices on any website with an embeddable widget. No backend code, and no API key in your page.
Webhooks & Price Alerts
Receive signed HTTP callbacks when a price crosses your threshold, and verify them with HMAC-SHA256.
Accessing Historical Data
Query daily prices back to 1999, fetch date ranges, compare two dates, get OHLC bars and analyse price trends.
Best Practices
Cache wisely, batch symbols, stream instead of polling, and keep your keys and webhooks secure.