Import Time Series Data for Stocks in Airtable

Feb 14, 2022Andy Cloke

In this guide, we'll import time series data for stocks in Airtable. We will use the Alpha Vantage API, which provides free daily/weekly/monthly stock time series data. We'll use the Data Fetcher Airtable extension to import this data with no-code.

Install Data Fetcher

Install Data Fetcher from the Airtable marketplace. After the extension launches, sign up for a free Data Fetcher account by entering a password and clicking 'Sign up for free'.

Group 1Data Fetcher Sign Up .png

Import Time Series Data for Stocks in Airtable

On the home screen of the Data Fetcher extension, click 'Create your first request'. Requests in Data Fetcher are how you import data to or send data from your Airtable base.

click-create-your-first-request.png

On the create request screen in Data Fetcher, for Application, select 'Alpha Vantage'.

alpha-vantage-application.png

Next, you need an Alpha Vantage API key. You can sign up for one here.

get-alpha-vantage-api-key.png

Enter this key into the API Key input in Data Fetcher.

For Endpoint, select 'Daily raw time series for a stock'. If you want to import weekly time series data, use 'Weekly raw time series for a stock'. Or if you want monthly, use 'Monthly raw time series for a stock'.

Enter a Name for your request, e.g. 'Import Time Series'. Then click 'Save & Continue'.

import-time-series-save-continue.png

Enter the Stock symbol you want to import time series data for, e.g. 'IBM'. If you instead want to import data for multiple different stocks, rather than entering one symbol, you can reference table values for Stock symbol.

time-series-stock-symbol.png

Set the Output size to 'Last 100 days'. You can increase this to the full-length series after you are happy with your setup.

time-series-output-size.png

Select the Output Table & View you want to import time series stock data into.

output-table-1.png

Click 'Save & Run'.

time-series-save-run.png

The request will run and the Response field mapping modal will open. This is where you set how the available fields from Alpha Vantage should map to the fields in the output table.

For each Alpha Vantage field, you can either import or filter it. For an imported field, you can set whether to map them to an existing field or create a new field, as well as set the field type.

Make sure you import the 'Time Series (Daily) Date' field, which is the date for each record, also import 'Time Series (Daily) 1 open' and change the type to 'Currency'. Import any other fields you want. Then click 'Save & Run'.

time-series-response-field-mapping.png

Data Fetcher will create any fields that need to be created in the output table, then run the request again for each symbol and import the time-series stock data into Airtable.

Import Time-Series Stock Data Automatically

At the moment, we have to manually run the request to import the time-series stock data from Alpha Vantage. We can use Data Fetcher's scheduled requests feature to automatically import them every 15 minutes/ hour/ day etc.

In Data Fetcher, scroll to Schedule and click 'Upgrade'.

table-1-schedule-upgrade-button.png

A new tab will open where you can select a plan and enter your payment details to upgrade.

data fetcher upgrade pricing plans.png

Return to the Data Fetcher extension and click 'I've done this'.

table-1-schedule-ive-done-this-button.png

Under Schedule click '+ Authorize'.

Schedule Data Fetcher

A popup will open where you'll be prompted to authorize the Airtable bases for Data Fetcher to access. We recommended selecting 'All current and future bases in all current and future workspaces' to avoid having to unauthorize bases for future use.

Click 'Grant access'.

schedule-authorize-bases.jpg

Back in Data Fetcher, Schedule this request will now be switched on.

Select how often you want the request to run, e.g. 'Every 15 mins'. Click 'Save' The request will now run on the schedule and import the time-series stock data from Alpha Vantage automatically.

Group 11(2).png

Related Posts

How to Import Company Revenue, EPS and Financial Ratios in Airtable

How to Import Company Revenue, EPS and Financial Ratios in Airtable

Mar 22, 2022

Rosie Threlfall

Alpha VantageFinance
Import Historical Exchange Rates in Airtable

Import Historical Exchange Rates in Airtable

Feb 20, 2022

Andy Cloke

FinanceCurrency Conversion
How to Convert Currency in Airtable

How to Convert Currency in Airtable

Jul 29, 2021

Andy Cloke

FinanceCurrency Conversion