Finance News API

Finance News API

Real-time Finance News API using the JSON payload to extract dynamic financial data.
Free Plan $0.00 Monthly Subscribe
50 Requests / Monthly
Free for Lifetime
No Credit Card Required
MOST POPULAR
Starter Plan $14.99 Monthly Subscribe
1,000 Requests / Monthly
Standard Support
Real-Time News and Data
Simple and Scalable
Over 100,000 financial facts
Real-time and historical data
Pro Plan $49.99 Monthly Subscribe
15,000 Requests / Monthly
Standard Support
Real-Time News and Data
Simple and Scalable
Over 100,000 financial facts
Real-time and historical data
Enterprise Plan $99.99 Monthly Subscribe
50,000 Requests / Monthly
Standard Support
Real-Time News and Data
Simple and Scalable
Over 100,000 financial facts
Real-time and historical data
Custom Plan Volume Monthly Contact Us
Any requests volume you need
Real-Time News and Data
Simple and Scalable
Over 100,000 financial facts
Real-time and historical data

What is the Finance News API?

The full set of available real-time financial data, historical financial data, reliable data sources, scalable infrastructure, and extensive API documentation can be accessed using a simple API request to the Finance News API's news endpoint. Below you will find an example API request as well as a series of optional parameters you can use to filter your news results.

The Finance News API was built to provide a powerful, scalable yet easy-to-use REST API interface delivering worldwide live and historical financial news data in handy JSON format. The API comes with a single news HTTP GET endpoint along with a series of parameters and options you can use to narrow down your finance news data results. Among other options, you can filter by dates and timeframes, sources, and search keywords, tags, and tickers.

How does the Finance News API help you?

The full set of available real-time news articles can be accessed using a simple API request to the Finance News API's news endpoint. Below you will find an example API request as well as a series of optional parameters you can use to filter your news results.

Delayed news on Free Plan: Please note that accounts subscribed to the Free Plan will receive live news only with a 60-minute delay. To lift this limitation and get news in real-time, please sign up or upgrade to the Standard Plan or higher.

Code Samples

The Finance News API supports any client and server-side programming language. We have prepared code examples for the languages PHP, Python, jQuery, Go and Ruby.

Example Request

curl --request GET 'https://api.apilayer.com/financelayer/news?date=today&keywords=at%26t&sources=seekingalpha.com&keyword=merger&tickers=dis' \
--header 'apikey: YOUR API KEY'

Example Response


{
    "pagination": {
        "limit": 25,
        "offset": 0,
        "count": 25,
        "total": 10000
    },
    "data": [
        {
            "title": "AT&T: Best Investment For Investors Seeking Value And Growth",
            "url": "https://seekingalpha.com/article/4457821-at-and-t-value-and-growth",
            "description": "AT&T and Discovery merger provides investors with the potential for valuation and dividend appreciation. See more on how this merger can boost T stock here.",
            "source": "seekingalpha.com",
            "tickers": [
                "dis",
                "disca",
                "discb",
                "disck",
                "nflx",
                "tmus",
                "vz"
            ],
            "tags": [
                "Business",
                "Communication Services",
                "Consumer Cyclical",
                "Dis",
                "Disca",
                "Discb",
                "Disck",
                "Nflx",
                "Stock",
                "T",
                "Tmus",
                "Vz"
            ],
            "published_at": "2021-09-30T14:53:42+00:00"
        }
    ]
}

API Documentation

Interested in our API? Please read below for detailed documentation and integration guide equipped with a library with 100+ pre-written code examples that can get you going in minutes.

Finance News API Reference

This API is organized around REST. Our API has predictable resource-oriented URLs, accepts form-encoded request bodies, returns JSON-encoded responses, and uses standard HTTP response codes, authentication, and verbs.

Just Getting Started?

Check out our development quickstart guide.

Authentication

Finance News API uses API keys to authenticate requests. You can view and manage your API keys in the Accounts page.

Your API keys carry many privileges, so be sure to keep them secure! Do not share your secret API keys in publicly accessible areas such as GitHub, client-side code, and so forth.

All requests made to the API must hold a custom HTTP header named "apikey". Implementation differs with each programming language. Below are some samples.

All API requests must be made over HTTPS. Calls made over plain HTTP will fail. API requests without authentication will also fail.

Endpoints

The full set of available real-time news articles can be accessed using a simple API request to the financelayer API's news endpoint. Below you will find an example API request as well as a series of optional parameters you can use to filter your news results.

Parameters

date (optional)

Use this parameter to specify a date or date range. Example: &date=2020-01-01 for news on Jan 1st and &date=2020-12-24,2020-12-31 for news between Dec 24th and 31st. Available options:

  • today
  • thisweek
  • thismonth
  • last7days
  • last30days
  • last3months
  • yeartodate
  • YYYY-MM-DD
  • YYYY-MM-DD,YYYY-MM-DD

Location: Query, Data Type: string

fallback (optional)

It can be on (default) or off. Fallback is used in case the search query doesn't return any news, then it will return the default results

Location: Query, Data Type: string

keywords (optional)

Use this parameter to search for sentences, you can also exclude words that you do not want to appear in your search results. Example: To search for 'New bitcoin news 2021' but exclude 'Etherum': &sources=new bitcoin news 2021, -etherum

Location: Query, Data Type: string

limit (optional)

Use this parameter to specify a pagination limit (number of results per page) for your API request. The default limit value is 25, the maximum allowed limit value is 100.

Location: Query, Data Type: integer

offset (optional)

Use this parameter to specify a pagination offset value for your API request. Example: An offset value of 100 combined with a limit value of 10 would show results 100-110. The default value is 0, starting with the first available result.

Location: Query, Data Type: integer

sort (optional)

Use this parameter to specify sorting order. Available values by published date: desc, asc

Location: Query, Data Type: string

sources (optional)

Use this parameter to include or exclude one or multiple comma-separated news sources. Example: To include forbes.com, but exclude bloomberg.com: &sources=forbes.com, -bloomberg.com

Location: Query, Data Type: string

tags (optional)

Use this parameter to search for tags by which news are tagged. You can search by multiple tags, separating tags with a comma, you can also exclude tags that you do not want to appear in your search results. Example: &tags=Bitcoin, -money. Results will exclude tags money from results

Location: Query, Data Type: string

tickers (optional)

Use this parameter to search for ticker symbols. You can search multiple tickers, separating them with comma, you can also exclude tickers that you do not want to appear in your search results. Example: &tickers=btc, pifi, -appl. Results will exclude ticker appl from results

Location: Query, Data Type: string

** A word enclosed with curly brackets "{ }" in the code means that it is a parameter and it should be replaced with your own values when executing. (also overwriting the curly brackets).
Returns

Below is a sample response from the endpoint


If you wish to play around interactively with real values and run code, see...

Rate Limiting

Each subscription has its own rate limit. When you become a member, you start by choosing a rate limit that suits your usage needs. Do not worry; You can upgrade or downgrade your plan at any time. For this reason, instead of starting with a larger plan that you do not need, we can offer you to upgrade your plan after you start with "free" or "gold plan" options and start using the API.

When you reach a rate limit (both daily and monthly), the service will stop responding and returning the HTTP 429 response status code (Too many requests) for each request with the following JSON string body text.

{
"message":"You have exceeded your daily\/monthly API rate limit. Please review and upgrade your subscription plan at https:\/\/apilayer.com\/subscriptions to continue."
}

A reminder email will be sent to you when your API usage reaches both 80% and 90%, so that you can take immediate actions such as upgrading your plan in order to prevent your application using the API from being interrupted.

You can also programmatically check your rate limit yourself. As a result of each request made to the APILayer, the following 4 fields provide you with all the necessary information within the HTTP Headers.

x-ratelimit-limit-month: Request limit per month
x-ratelimit-remaining-month: Request limit remaining this month
x-ratelimit-limit-day: Request limit per day
x-ratelimit-remaining-day: Request limit remaining today

You can contact our support unit if you need any assistance with your application regarding to handle the returned result by looking at the header information.

Error Codes

APILayer uses standard HTTP response codes to indicate the success or failure of an API request. In general: Codes in the 2xx range indicate success. Codes in the 4xx range indicate a clientside error, which means that failed given the information provided (e.g., a missing parameter, unauthorized access etc.). Codes in the 5xx range indicate an error with APILayer's servers (normally this should'nt happen at all).

If the response code is not 200, it means the operation failed somehow and you may need to take an action accordingly. You can check the response (which will be in JSON format) for a field called 'message' that briefly explains the error reported.

Status Code Explanation
400 - Bad Request The request was unacceptable, often due to missing a required parameter.
401 - Unauthorized No valid API key provided.
404 - Not Found The requested resource doesn't exist.
429 - Too many requests API request limit exceeded. See section Rate Limiting for more info.
5xx - Server Error We have failed to process your request. (You can contact us anytime)

You can always contact for support and ask for more assistance. We'll be glad to assist you with building your product.