Intrinio's stock API was designed by financial professionals for developers, a rare situation in the world of Fintech. Our singular endpoint API is easy to integrate and scale for a developer while the data structures are intuitive for financial analysts.
This article explains a few of the resources Intrinio has made available to help you get started to our API v2. It contains 4 major sections:
- A summary of the tools you'll need to get started using API v2
- An explanation of how to make your first API call
- A list of sample API calls to show you what is possible
- A list of SDKs that include sample code in many languages
Tools you'll need
- The API Documentation- Everything the API does is documented here
- API tutorial - Quick guide to make your first API call
- CSV Documentation - The API typically outputs JSON, but you can output a CSV as well
- The Data Tag Directory - This feature looks up the data types Intrinio provides
- Paging Tutorial - This article explains how to page through data via the API
- The Help Page- You can chat support and see a list of helpful links here
Making Your First API Call
Start by looking at the API documentation. There you will see that the API uses Basic Authentication administered over HTTPS. You can see what this means, and build your first API call, by pasting the following text into your browser:
Your API access key is located on your account page under tab ACCESS KEYS.
Notice that the API call is broken into several parts.
The base URL- https://www.api.intrinio.com/
A data type- data_point?
A ticker- ticker=AAPL&
And an item - item=close_price
Once you have made a few sample API calls and taken a look at the tools Intrinio offers, you might also want to check out this article that explains paging with the Intrinio API. When you start making API calls for more data, you'll have to "page" through the results.
Sample API calls
While sample stock API calls are included in the API documentation, it can be useful to see a few together to get an idea of the breadth of data types available through Intrinio. Once you learn the format of a few data types, its easy to change the building blocks of the API call to get a different piece of data:
Often times you will notice that there are limits to the amount of data available in a single call. This limit is 100 items per page in general, but adding a pager, page_number=2 in this case, allows you to pull multiple pages. Here is the paging documentation.
This grabs AAPL's income statement from Q2, 2015:
This one shows all companies with a new filing date on or after 2017-03-06, which is useful for determining which fundamentals need to be updated:
This call uses data_point, a data type that returns the most current piece of data:
This stock api call uses the historical data format to pull Apple's price to earnings ratio over the course of 2014. Historical data allows you to pull data as a time series or to pull data from a specific point in time:
This call will return the entire price history of Apple if you use a pager. You can use this data type to specify a specific date range or pull it all in at once, with a default page size of 100 rows. See our Page Size Limits documentation for more info:
This is a handy call that returns the first 100 companies that Intrinio covers, including the ticker/id symbols you can parse out to use in other API calls. Since the number of items that can be returned in a single call is limited to 100, and Intrinio covers way more than 100 tickers, you will need to change to the second page to get the second 100. This requires a loop to get the entire list.
This call extends the previous call to get the basic company information for Apple:
SDKs in Numerous Languages
Once you have mastered the syntax for Intrinio API calls, you will want to use your preferred programming language to automatically input your API username and password and parse the data for use in your application.