eToro · Schema

OrderForOpenInfoResponse

Comprehensive order information response containing order details and all positions opened from this order.

Social TradingCopy TradingInvestingMarket DataPortfolio ManagementFintechTradingStocksCryptocurrencyETFs

Properties

Name Type Description
token string Tracking token for the request, used for correlation and debugging purposes. This token is generated by the system and can be used to track the request through various system components.
orderID integer The unique identifier of the order. This is the same OrderID that was provided in the request path parameter.
CID integer Customer ID (CID) associated with the order. This identifies the user account that created the order.
referenceID string Reference tracking ID for the order request.
statusID integer Current status of the order. Common values: 0 = Pending, 1 = Executed, 2 = Cancelled, 3 = Rejected, 4 = Partially Executed. The exact meaning of status codes may vary based on order type and system co
orderType integer Type of the order. Common values: 1 = Market Order, 2 = Limit Order, 3 = Stop Order. The exact order types depend on the trading system configuration.
openActionType integer The action type that triggered the order creation. This indicates the reason or context for opening the position, such as manual trade, copy trading, automated strategy, etc.
errorCode integer Error code if the order execution failed or encountered an error. This field is null if the order was successful. Error codes are system-specific and should be referenced against the system's error co
errorMessage string Human-readable error message describing any error that occurred during order processing. This field is null if the order was successful. Provides additional context beyond the errorCode.
instrumentID integer The unique identifier of the financial instrument that the order was placed for. This corresponds to the instrument being traded (e.g., stock, currency pair, commodity).
amount number The USD amount that was requested to be invested in the position. This represents the monetary value allocated to the order.
units number The number of units that were requested to be traded. If the order was placed by units rather than amount, this value represents the requested quantity.
requestOccurred string The timestamp when the order request was initially created and submitted to the system. This is in ISO 8601 format (UTC).
positions array List of all positions that were opened as a result of this order. Each position in this array represents a successfully executed position created from the order. This array is empty if the order has n
View JSON Schema on GitHub

JSON Schema

OrderForOpenInfoResponse.json Raw ↑
{
  "$schema": "http://json-schema.org/draft-07/schema#",
  "$id": "https://raw.githubusercontent.com/api-evangelist/etoro/refs/heads/main/json-schema/OrderForOpenInfoResponse.json",
  "title": "OrderForOpenInfoResponse",
  "type": "object",
  "description": "Comprehensive order information response containing order details and all positions opened from this order.",
  "required": [
    "orderID",
    "CID",
    "statusID",
    "orderType",
    "instrumentID",
    "requestOccurred"
  ],
  "properties": {
    "token": {
      "type": "string",
      "description": "Tracking token for the request, used for correlation and debugging purposes. This token is generated by the system and can be used to track the request through various system components.",
      "example": "550e8400-e29b-41d4-a716-446655440000"
    },
    "orderID": {
      "type": "integer",
      "format": "int64",
      "description": "The unique identifier of the order. This is the same OrderID that was provided in the request path parameter.",
      "example": 123456789
    },
    "CID": {
      "type": "integer",
      "format": "int64",
      "description": "Customer ID (CID) associated with the order. This identifies the user account that created the order.",
      "example": 987654321
    },
    "referenceID": {
      "type": "string",
      "description": "Reference tracking ID for the order request.",
      "example": "00000000-0000-0000-0000-000000000000"
    },
    "statusID": {
      "type": "integer",
      "description": "Current status of the order. Common values: 0 = Pending, 1 = Executed, 2 = Cancelled, 3 = Rejected, 4 = Partially Executed. The exact meaning of status codes may vary based on order type and system configuration.",
      "example": 1
    },
    "orderType": {
      "type": "integer",
      "description": "Type of the order. Common values: 1 = Market Order, 2 = Limit Order, 3 = Stop Order. The exact order types depend on the trading system configuration.",
      "example": 1
    },
    "openActionType": {
      "type": "integer",
      "description": "The action type that triggered the order creation. This indicates the reason or context for opening the position, such as manual trade, copy trading, automated strategy, etc.",
      "example": 1
    },
    "errorCode": {
      "type": "integer",
      "format": "nullable",
      "description": "Error code if the order execution failed or encountered an error. This field is null if the order was successful. Error codes are system-specific and should be referenced against the system's error code documentation.",
      "example": null
    },
    "errorMessage": {
      "type": "string",
      "format": "nullable",
      "description": "Human-readable error message describing any error that occurred during order processing. This field is null if the order was successful. Provides additional context beyond the errorCode.",
      "example": null
    },
    "instrumentID": {
      "type": "integer",
      "description": "The unique identifier of the financial instrument that the order was placed for. This corresponds to the instrument being traded (e.g., stock, currency pair, commodity).",
      "example": 67890
    },
    "amount": {
      "type": "number",
      "format": "decimal",
      "description": "The USD amount that was requested to be invested in the position. This represents the monetary value allocated to the order.",
      "example": 1000.0
    },
    "units": {
      "type": "number",
      "format": "decimal",
      "description": "The number of units that were requested to be traded. If the order was placed by units rather than amount, this value represents the requested quantity.",
      "example": 10.5
    },
    "requestOccurred": {
      "type": "string",
      "format": "date-time",
      "description": "The timestamp when the order request was initially created and submitted to the system. This is in ISO 8601 format (UTC).",
      "example": "2024-01-15T10:30:00Z"
    },
    "positions": {
      "type": "array",
      "description": "List of all positions that were opened as a result of this order. Each position in this array represents a successfully executed position created from the order. This array is empty if the order has not yet been executed or if execution failed.",
      "items": {
        "$ref": "#/components/schemas/OrderForOpenPositionInfo"
      }
    }
  }
}