Yahoo Finance API endpoint
Returns the Yahoo Finance earnings modules for a `symbol` such as `AAPL`, including `earnings` and `earningsTrend`, under `modules`. The response echoes the `symbol`, and the symbol is the only input.
/yahoo-finance/ticker/{symbol}/earnings| Field | Filled in, of 4 checked | Values in the sample |
|---|---|---|
| currency | 4 | USD in all 4 |
| epsActual | 4 | 1.85 to 2.84, median 2.01 |
| epsDifference | 4 | 0.07 to 0.17, median 0.08 |
| epsEstimate | 4 | 1.77 to 2.67, median 1.89 |
| maxAge | 4 | 1 |
| period | 4 | “-4q” and 3 other values |
| quarter | 4 | 1,759,190,400 to 1,782,777,600, median 1,767,139,200 |
| surprisePercent | 4 | 0.03 to 0.07, median 0.05 |
| Parameter | Type | Required | Default | Description | Example |
|---|---|---|---|---|---|
| symbol (path) | string | Yes | Yahoo Finance symbol such as AAPL | AAPL | |
| x-api-key (header) | string | Yes | API key required |
curl -X GET "https://api.crawlora.net/api/v1/yahoo-finance/ticker/AAPL/earnings" \ -H "x-api-key: $CRAWLORA_API_KEY"
{
"code": 200,
"msg": "OK",
"data": {
"symbol": "AAPL",
"modules": {
"earnings": {},
"earningsTrend": {}
}
}
}Request schema
No body schema
Response schema
#/definitions/yahoofinance.moduleResponseDoc
| Field | Type | Required | Enum | Bounds | Example | Description |
|---|---|---|---|---|---|---|
| code | integer | No | 200 | |||
| data | yahoofinance.ModuleResponse | No | ||||
| data.modules | object | No | Data grouped by section. | |||
| data.symbol | string | No | AAPL | Ticker symbol, for example `AAPL`. | ||
| msg | string | No | OK |
| Status | Description | Schema |
|---|---|---|
| 400 | Bad Request | #/definitions/app.Response |
| 404 | Not Found | #/definitions/app.Response |
| 500 | Internal Server Error | #/definitions/app.Response |
| 503 | Service Unavailable | #/definitions/app.Response |
Use environment variables for secrets and keep Crawlora API keys server-side.
curl -X GET "https://api.crawlora.net/api/v1/yahoo-finance/ticker/AAPL/earnings" \
-H "x-api-key: $CRAWLORA_API_KEY"