Skip to main content
POST
/
api
/
v1
/
trading
/
execution
/
limit-orders
Places a Market-if-touched order (similar to Limit order) to open a position when a threshold price is reached.
curl --request POST \
  --url https://public-api.etoro.com/api/v1/trading/execution/limit-orders \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <x-api-key>' \
  --header 'x-request-id: <x-request-id>' \
  --header 'x-user-key: <x-user-key>' \
  --data '
{
  "InstrumentID": 123,
  "IsBuy": true,
  "Leverage": 123,
  "Amount": 123,
  "AmountInUnits": 123,
  "StopLossRate": 123,
  "TakeProfitRate": 123,
  "Rate": 123,
  "IsTslEnabled": true,
  "IsDiscounted": true,
  "IsNoStopLoss": true,
  "IsNoTakeProfit": true,
  "CID": 123
}
'
{
  "token": "9af05785-be29-482d-a892-9d9be4fd34bc"
}

Headers

x-request-id
string<uuid>
required

A unique request identifier.

Example:

"d546d686-2b57-4bab-aa6d-6d72ae77a60f"

x-api-key
string<password>
required

API key for authentication.

Example:

"lhgfaslk21490FAScVPkdsb53F9dNkfHG4faZSG5vfjndfcfgdssdgsdHF4663"

x-user-key
string<password>
required

User-specific authentication key.

Example:

"eyJlYW4iOiJVbnJlZ2lzdGVyZWRBcHBsaWNhdGlvbiIsImVrIjoiOE5sZ2cwcW5EUVdROUFNWGpXT2lmOWktZnpidG5KcUlqWGJ3WHJZZkpZcldrbG90ZEhvLVBjSWhQaU8xU1ZtMW84aU1WZGZqN2xWNzFjLXFxLmcybXE1dnh4Q1hUT25xaWRUaTFlcEhmVk1fIn0_"

Body

application/json
InstrumentID
integer<int32>

The unique identifier of the financial instrument.

IsBuy
boolean

Indicates whether the order will open a long (true) or short (false) position.

Leverage
integer<int32>

The leverage ratio for the order.

Amount
number<double> | null

The amount of the trade in the account currency [USD]. Required if AmountInUnits is not provided.

AmountInUnits
number<double> | null

The number of units of the asset. Required if Amount is not provided. For most assets this can be a fractional number. Note that for Future Contracts this number should indicate the number of underlying units, and not the number of contracts, according to the formula: AmountInUnits = contract multiplier * number of contracts.

StopLossRate
number<double>

The stop-loss trigger price at which the position will generate a Market Order to close (after it was opened). StopLoss trigger price must be worse than current price.

TakeProfitRate
number<double>

The take-profit trigger price at which the position will generate a Market Order to close (after it has opened). TakeProfit trigger price must be better than the current price.

Rate
number<double>

The trigger price at which a Market order to open the position will be sent for execution. The trigger price must be better than the current price. This means that the trigger price must be lower than current price for Long positions, and higher than current price for Short positions.

IsTslEnabled
boolean | null

Indicates if a trailing stop loss (TSL) is enabled. This means that the stoploss rate indicated will get updated automatically whenever the asset price increases (for long positions) or decreases (for short position) effectively keeping the stoploss in a constant gap from the best price achieved so far.

IsDiscounted
boolean | null

SHOULD NOT BE EXTERNALZIED

IsNoStopLoss
boolean | null

Indicates if stop-loss is disabled.

IsNoTakeProfit
boolean | null

Indicates if take-profit is disabled.

CID
integer<int32>

SHOULD NOT BE EXTERNALIZED.

Response

200 - application/json

Market-if-touched order successfully placed. The response includes a confirmation token.

token
string<uuid>
required

A confirmation token indicating the order creation.