Forex Currency Prices

Forex Currency Prices Javascript API Documentation

Provides a list of forex price quotes for a given forex currency pair and timeframe.

API Class:
ForexApi
Instance Method:
getForexPrices()

Stock Price Code Example

Use my API Key
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);
});
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Parameters

NameTypeDescriptionNotes
pairStringThe Forex Currency Pair code 
timeframeStringThe time interval for the quotes 
timezoneStringReturns trading times in this timezone[optional] [default to UTC]  
startDateDateReturn Forex Prices on or after this date[optional]  
startTimeStringReturn Forex Prices at or after this time (24-hour in ‘hh:mm' format, UTC timezone)[optional]  
endDateDateReturn Forex Prices on or before this date[optional]  
endTimeStringReturn Forex Prices at or before this time (24-hour in ‘hh:mm' format, UTC timezone)[optional]  
pageSizeNumberThe number of results to return[optional] [default to 100]  
nextPageStringGets the next page of data from a previous API call[optional]  


Return Type

object
ApiResponseForexPrices

Properties

NameTypeDescription
prices[ForexPrice] 
pairForexPairThe Forex currency pair for which prices were requested  
nextPageStringThe token required to request the next page of the data. If null, no further results are available.  
object
ForexPrice

Properties

NameTypeDescription
occurredAtStringThe timestamp of the beginning of the timeframe. The open prices would be at this time, while close prices would be at this time plus the timeframe.  
openBidNumberOpen bid  
highBidNumberHigh bid  
lowBidNumberLow bid  
closeBidNumberClose bid  
openAskNumberOpen ask  
highAskNumberHigh ask  
lowAskNumberLow ask  
closeAskNumberClose ask  
totalTicksNumberTotal ticks  
object
ForexPair

Properties

NameTypeDescription
codeStringThe common code of the currency pair  
baseCurrencyStringThe ISO 4217 currency code of the base currency  
quoteCurrencyStringThe ISO 4217 currency code of the quote currency