All URIs are relative to https://api-v2.intrinio.com
Method | HTTP request | Description |
---|---|---|
getForexCurrencies | GET /forex/currencies | Forex Currencies |
getForexPairs | GET /forex/pairs | Forex Currency Pairs |
getForexPrices | GET /forex/prices/{pair}/{timeframe} | Forex Currency Prices |
View Intrinio API Documentation
ApiResponseForexCurrencies getForexCurrencies()
Returns a list of forex currencies for which prices are available.
var intrinioSDK = require('intrinio-sdk');
intrinioSDK.ApiClient.instance.authentications['ApiKeyAuth'].apiKey = "YOUR_API_KEY";
intrinioSDK.ApiClient.instance.enableRetries = true;
var forex = new intrinioSDK.ForexApi();
forex.getForexCurrencies().then(function(data) {
data = JSON.stringify(data, null, 2)
console.log(data);
}, function(error) {
console.error(error);
});
This endpoint does not need any parameter.
View Intrinio API Documentation
ApiResponseForexPairs getForexPairs()
Returns a list of currency pairs used to request foreign exchange (forex) market price data. The currency that is used as the reference is called quote currency and the currency that is quoted in relation is called the base currency. For example, in the pair code “EURGBP” with a price of 0.88, one Euro (base currency) can be exchanged for 0.88 British Pounds (quote currency).
var intrinioSDK = require('intrinio-sdk');
intrinioSDK.ApiClient.instance.authentications['ApiKeyAuth'].apiKey = "YOUR_API_KEY";
intrinioSDK.ApiClient.instance.enableRetries = true;
var forex = new intrinioSDK.ForexApi();
forex.getForexPairs().then(function(data) {
data = JSON.stringify(data, null, 2)
console.log(data);
}, function(error) {
console.error(error);
});
This endpoint does not need any parameter.
View Intrinio API Documentation
ApiResponseForexPrices getForexPrices(pair, timeframe, opts)
Provides a list of forex price quotes for a given forex currency pair and timeframe.
var intrinioSDK = require('intrinio-sdk');
intrinioSDK.ApiClient.instance.authentications['ApiKeyAuth'].apiKey = "YOUR_API_KEY";
intrinioSDK.ApiClient.instance.enableRetries = true;
var forex = new intrinioSDK.ForexApi();
var pair = "EURUSD";
var timeframe = "D1";
var opts = {
'timezone': "UTC",
'startDate': new Date("2018-01-01"),
'startTime': null,
'endDate': new Date("2019-01-01"),
'endTime': null,
'pageSize': 100,
'nextPage': null
};
forex.getForexPrices(pair, timeframe, opts).then(function(data) {
data = JSON.stringify(data, null, 2)
console.log(data);
}, function(error) {
console.error(error);
});
Name | Type | Description | Notes |
---|---|---|---|
pair | String | The Forex Currency Pair code | |
timeframe | String | The time interval for the quotes | |
timezone | String | Returns trading times in this timezone | [optional] [default to UTC] |
startDate | Date | Return Forex Prices on or after this date | [optional] |
startTime | String | Return Forex Prices at or after this time (24-hour in 'hh:mm' format, UTC timezone) | [optional] |
endDate | Date | Return Forex Prices on or before this date | [optional] |
endTime | String | Return Forex Prices at or before this time (24-hour in 'hh:mm' format, UTC timezone) | [optional] |
pageSize | Number | The number of results to return | [optional] [default to 100] |
nextPage | String | Gets the next page of data from a previous API call | [optional] |