/indicativecostsandcharges/close

POST (version: 1)

Returns indicative costs and charges at closing. Supported website IDs: atm, atf, dem, def, det, esm, esf, est, frm, frf, frt, itm, itf, itt, nlm, nlf, nlt, nom, nof, not, sem, sef, set, eng, enf, ent, iei, iem, ief, iet, igi, igm, por, pof.
Request
Parameter Type Name Description
Body request (Object)
ask (Number)
[Constraint: NotNull]
bid (Number)
[Constraint: NotNull]
dealCurrencyCode (String)
[Constraint: NotNull]
dealReference (String)
[Constraint: NotNull]
direction (Constant)
BUY
SELL
epic (String)
guaranteedStop (Boolean)
instrumentId (String)
knockoutPremium (Number)
openingLevel (Number)
[Constraint: NotNull]
priceLevel (Number)
size (Number)
[Constraint: NotNull]
stopLevel (Number)
Response
close (Object)
ClosingExAnteResponse DEFAULT_CLOSING_EX_ANTE_RESPONSE
closingCommission (Number)
closingFxFee (Number)
closingIFTT (Number)
closingSpread (Number)
etpExitCost (Number)
guaranteedStopReturn (Number)
indicativeQuoteReference (String)
knockoutPremiumReturn (Number)
notionalValue (Number)
notionalValueInUserCurrency (Number)
currencyCodeISO (String)
Exceptions
HTTP code Description
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
invalid.input A generic input data error has occurred
400
public-api.costs-and-charges.client-error
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
404
invalid.url
404
public-api.costs-and-charges.indicative-quote-reference-not-found
500
public-api.costs-and-charges.general-error
500
system.error