Skip to content

Polygon API

by polygon.io

API keyHTTPSFinance
Open documentation ↗

Overview

Historical stock market data

Polygon is a finance API from polygon.io. Requests are authenticated with an API key. It is served over HTTPS. Its OpenAPI description documents 10 endpoints.

At a glance

Authentication
API key
HTTPS
Yes
CORS
Unknown
Category
Finance
Base URL
https://api.polygon.io
Version
1.0.0
Endpoints
10
Spec updated
2017-11-27

Make a first request

Replace the placeholders; the documentation says exactly where credentials go.

cURL
curl -X GET "https://api.polygon.io/v1/companies" \
  -H "Accept: application/json" \
  -H "X-API-Key: YOUR_API_KEY"
JavaScript
const response = await fetch("https://api.polygon.io/v1/companies", {
  method: "GET",
  headers: {
    "Accept": "application/json",
    "X-API-Key": "YOUR_API_KEY",
  },
});
const data = await response.json();
console.log(data);
Python
import requests

response = requests.request(
    "GET",
    "https://api.polygon.io/v1/companies",
    headers={
    "Accept": "application/json",
    "X-API-Key": "YOUR_API_KEY",
    },
    timeout=30,
)
print(response.json())

Endpoints

MethodPathWhat it does
GET/v1/companiesAvailable Companies
GET/v1/currenciesAvailable Currencies
GET/v1/historic/agg/{size}/{symbol}/{date}Historic Aggregates
GET/v1/historic/forex/{from}/{to}/{date}Historic Forex Ticks
GET/v1/historic/quotes/{symbol}/{date}Historic Quotes
GET/v1/historic/trades/{symbol}/{date}Historic Trades
GET/v1/last/currencies/{from}/{to}Last Trade for a Currency Pair
GET/v1/last/stocks/{symbol}Last Trade for a Symbol
GET/v1/last_quote/currencies/{from}/{to}Last Quote for a Currency Pair
GET/v1/last_quote/stocks/{symbol}Last Quote for a Symbol

Questions

Does the Polygon API need an API key?

Yes. The Polygon API uses API key authentication; the documentation explains how to get credentials.

Does the Polygon API support HTTPS?

Yes, the Polygon API is served over HTTPS.

How many endpoints does the Polygon API have?

Its OpenAPI description lists 10 endpoints in version 1.0.0. All of them are shown on this page.

What are alternatives to the Polygon API?

Other Finance APIs include Stripe, SEC EDGAR Data, Plaid, Fed Treasury, Razorpay IFSC.

Compare alternatives →

Listed from public-apis (MIT), public-apis database (MIT), APIs.guru (CC0).