/prices/{epic}

GET (version: 3)

Returns historical prices for a particular instrument. Returns the minute prices within the last 10 minutes by default.
Request
Parameter Type Name Description
Path epic (String) Instrument epic
Request (Optional) (Default=MINUTE) resolution (Resolution) Price resolution
Defines the resolution of requested prices.
DAY 1 day
HOUR 1 hour
HOUR_2 2 hours
HOUR_3 3 hours
HOUR_4 4 hours
MINUTE 1 minute
MINUTE_10 10 minutes
MINUTE_15 15 minutes
MINUTE_2 2 minutes
MINUTE_3 3 minutes
MINUTE_30 30 minutes
MINUTE_5 5 minutes
MONTH 1 month
SECOND 1 second
WEEK 1 week
Request (Optional) from (DateTime) Start date time (yyyy-MM-dd'T'HH:mm:ss)
Request (Optional) to (DateTime) End date time (yyyy-MM-dd'T'HH:mm:ss)
Request (Optional) (Default=10) max (int) Limits the number of price points (not applicable if a date range has been specified)
Request (Optional) (Default=20) pageSize (int) Page size (disable paging = 0)
Request (Optional) (Default=1) pageNumber (int) Page number
Response
List of prices
instrumentType (Constant)
Instrument type
BINARY
BUNGEE_CAPPED
BUNGEE_COMMODITIES
BUNGEE_CURRENCIES
BUNGEE_INDICES
COMMODITIES
CURRENCIES
INDICES
KNOCKOUTS_COMMODITIES
KNOCKOUTS_CURRENCIES
KNOCKOUTS_INDICES
KNOCKOUTS_SHARES
OPT_COMMODITIES
OPT_CURRENCIES
OPT_INDICES
OPT_RATES
OPT_SHARES
RATES
SECTORS
SHARES
SPRINT_MARKET
TEST_MARKET
UNKNOWN
metadata (Object)
Response metadata data.
pageData (Object)
Paging metadata
pageNumber (Number) Page number
pageSize (Number) Page size
totalPages (Number) Total number of pages
size (Number) Size
allowance (Object)
Historical price data allowance
allowanceExpiry (Number) The number of seconds till the current allowance period will end and the remaining allowance field is reset
remainingAllowance (Number) The number of data points still available to fetch within the current allowance period
totalAllowance (Number) The number of data points the API key and account combination is allowed to fetch in any given allowance period
prices (Array[Object])
Historical market price snapshot
closePrice (Object)
Price
ask (Number) Ask price
bid (Number) Bid price
lastTraded (Number) Last traded price. This will generally be null for non exchange-traded instruments
highPrice (Object)
Price
ask (Number) Ask price
bid (Number) Bid price
lastTraded (Number) Last traded price. This will generally be null for non exchange-traded instruments
lastTradedVolume (Number) Last traded volume. This will generally be null for non exchange-traded instruments
lowPrice (Object)
Price
ask (Number) Ask price
bid (Number) Bid price
lastTraded (Number) Last traded price. This will generally be null for non exchange-traded instruments
openPrice (Object)
Price
ask (Number) Ask price
bid (Number) Bid price
lastTraded (Number) Last traded price. This will generally be null for non exchange-traded instruments
snapshotTime (String) Snapshot local time, format is yyyy/MM/dd hh:mm:ss
snapshotTimeUTC (String) Snapshot time
Exceptions
HTTP code Description
400
error.invalid.daterange Invalid date range error
400
error.malformed.date Invalid date format error
400
error.public-api.failure.encryption.required A login has been attempted to the login V1 service by a client from the IG Singapore company. They need to use the v2 version as they need to send their passwords encrypyted.
400
error.request.invalid.date-range Invalid date range
400
error.security.api-key-missing The api key was not provided
400
error.unsupported.epic Invalid EPIC error. Currently only major currency pairs instruments are supported
400
invalid.input A generic input data error has occurred
401
error.public-api.failure.kyc.required The account is not allowed to log into public API. Please use the web platform.
401
error.public-api.failure.missing.credentials The user has not provided all required security credentials.
401
error.public-api.failure.pending.agreements.required The account is not allowed to log into public API. Please use the web platform.
401
error.public-api.failure.preferred.account.disabled The user's preferred account is disabled.
401
error.public-api.failure.preferred.account.not.set The user has not set a preferred account.
401
error.security.account-token-invalid The service requires an account token and the one provided was not valid
401
error.security.account-token-missing The service requires an account token and it was not provided
401
error.security.client-token-invalid The service requires a client token and the one provided was not valid
401
error.security.client-token-missing The service requires a client token and it was not provided
401
error.security.oauth-token-invalid Invalid OAuth access token
403
endpoint.unavailable.for.api-key The provided api key was not accepted
403
error.public-api.exceeded-account-allowance The account traffic allowance has been exceeded
403
error.public-api.exceeded-account-historical-data-allowance The account historical data traffic allowance has been exceeded
403
error.public-api.exceeded-account-trading-allowance The account trading traffic allowance has been exceeded
403
error.public-api.exceeded-api-key-allowance The api key traffic allowance has been exceeded
403
error.public-api.failure.stockbroking-not-supported Stockbroking not supported for Public API users.
403
error.security.api-key-disabled The provided api key was not accepted because it is not currently enabled
403
error.security.api-key-invalid The provided api key was not accepted
403
error.security.api-key-restricted The provided api key was not valid for the requesting account
403
error.security.api-key-revoked The provided api key was not accepted because it has been revoked
403
unauthorised.access.to.equity.exception Unauthorised access to equity data
404
invalid.url
500
system.error