latestOpenAPI 3.0.32026-08-101461131.1 MB

ad6f143e43aa

fx:aggregates

Simple Moving Average (SMA)

Get the simple moving average (SMA) for a ticker symbol over a given time range.

get/v1/indicators/sma/{fxTicker}

Path parameters

fxTickerstring required

The ticker symbol for which to get simple moving average (SMA) data.

Query parameters

timestampstring

Query by timestamp. Either a date with the format YYYY-MM-DD or a millisecond timestamp.

timespan'minute' | 'hour' | 'day' | 'week' | 'month' | 'quarter' | 'year'

The size of the aggregate time window.

adjustedboolean

Whether or not the aggregates used to calculate the simple moving average are adjusted for splits. By default, aggregates are adjusted. Set this to false to get results that are NOT adjusted for splits.

windowinteger

The window size used to calculate the simple moving average (SMA). i.e. a window size of 10 with daily aggregates would result in a 10 day moving average.

series_type'open' | 'high' | 'low' | 'close'

The price in the aggregate which will be used to calculate the simple moving average. i.e. 'close' will result in using close prices to calculate the simple moving average (SMA).

expand_underlyingboolean

Whether or not to include the aggregates used to calculate this indicator in the response.

order'asc' | 'desc'

The order in which to return the results, ordered by timestamp.

limitinteger

Limit the number of results returned, default is 10 and max is 5000

timestamp.gtestring

Range by timestamp.

timestamp.gtstring

Range by timestamp.

timestamp.ltestring

Range by timestamp.

timestamp.ltstring

Range by timestamp.

Response

Simple Moving Average (SMA) data for each period.

next_urlstring

If present, this value can be used to fetch the next page of data.

request_idstring required

A request id assigned by the server.

statusstring required

The status of this request's response.