下单

状态变更操作必须防止重复提交。

预览订单

操作名

TradeApiService.PREVIEW_ORDER = preview_order. 使用服务端方法 preview_order。这是 *ApiService 常量,不是客户端成员方法。

请求

TigerRequest<TigerDictResponse>

ModelValue: PlaceOrderModel.

参数

SDK propertyC# typeAPI fieldSDK defaultRequiredConstraints
LangLanguagelangNone (omitted if not set)no
Accountstring (nullable)accountnullAuto-filled if emptyTradeClient uses DefaultAccount when empty
SecretKeystringsecret_keynullno
OrderIdInt32order_idNone (omitted if not set)Optional
SecTypeSecTypesec_typeNone (omitted if not set)Optional
MarketMarketmarketNone (omitted if not set)OptionalEnum value
CurrencyCurrencycurrencyNone (omitted if not set)Optional
SymbolstringsymbolnullRequired
Rightstring (nullable)rightnullOptional
Strikestring (nullable)strikenullOptional
Expirystring (nullable)expirynullOptional
ActionActionTypeactionNone (omitted if not set)Optional
OrderTypeOrderTypeorder_typeNone (omitted if not set)Optionalprice fields are conditionally required by order type
TotalQuantityInt64 (nullable)total_quantitynullOptional
TotalQuantityScaleInt32 (nullable)total_quantity_scalenullOptional
LimitPriceDouble (nullable)limit_pricenullOptionalconditional order-price field
CashAmountDouble (nullable)cash_amountnullOptional
AdjustLimitDoubleadjust_limitNone (omitted if not set)Optional
AuxPriceDouble (nullable)aux_pricenullOptionalconditional order-price field
TrailingPercentDouble (nullable)trailing_percentnullOptionalconditional order-price field
TimeInForceTimeInForcetime_in_forceTimeInForce.DAYOptional
ExpireTimelongexpire_timeNone (omitted if not set)Optional
OutsideRthBooleanoutside_rthtrueOptional
TradingSessionTypeTradeSessiontrading_session_typeNone (omitted if not set)Optional
ExchangestringexchangenullOptional
MultiplierdoublemultiplierNone (omitted if not set)Optional
LocalSymbolstringlocal_symbolnullOptional
AllocAccounts列表,元素为 stringalloc_accountsnullOptional
AllocShares列表,元素为 Doublealloc_sharesnullOptional
AlgoStrategystringalgo_strategynullOptional
AlgoParams列表,元素为 TagValuealgo_paramsnullOptional
DisplaySizeInt64 (nullable)display_sizenullOptional
MinDisplaySizeInt64 (nullable)min_display_sizenullOptional
CheckIntervalsInt64 (nullable)check_intervalsnullOptional
PriceTypestring (nullable)price_typenullOptional
StartTimeInt64 (nullable)start_timenullOptionalTimestamp or date format; maintain chronological order
EndTimeInt64 (nullable)end_timenullOptionalTimestamp or date format; maintain chronological order
UserMarkstringuser_marknullOptional
AttachTypeAttachTypeattach_typeNone (omitted if not set)Optional
ProfitTakerOrderIdInt32profit_taker_orderIdNone (omitted if not set)Optional
ProfitTakerPriceDoubleprofit_taker_priceNone (omitted if not set)Optional
ProfitTakerTifTimeInForceprofit_taker_tifNone (omitted if not set)Optional
ProfitTakerRthBooleanprofit_taker_rthNone (omitted if not set)Optional
StopLossOrderTypeOrderTypestop_loss_order_typeNone (omitted if not set)Optional
StopLossOrderIdInt32stop_loss_orderIdNone (omitted if not set)Optional
StopLossPriceDoublestop_loss_priceNone (omitted if not set)Optional
StopLossLimitPriceDoublestop_loss_limit_priceNone (omitted if not set)Optional
StopLossTifTimeInForcestop_loss_tifNone (omitted if not set)Optional
StopLossTrailingPercentDoublestop_loss_trailing_percentNone (omitted if not set)Optional
StopLossTrailingAmountDoublestop_loss_trailing_amountNone (omitted if not set)Optional
ComboTypestringcombo_typenullOptional

返回

TigerDictResponse inherits TigerResponse; its data property is 字典,键为 string,值为 object. Key SDK fields: 动态字段.

示例

TigerRequest<TigerDictResponse> request = new()
{
    ApiMethodName = TradeApiService.PREVIEW_ORDER,
    ModelValue = new PlaceOrderModel { Account = tradeClient.GetDefaultAccount, OrderId = 12345, SecType = SecType.STK, Market = Market.US, Currency = Currency.USD }
};
TigerDictResponse? response = await tradeClient.ExecuteAsync(request);

响应类型

Dictionary<string, object>? data = response?.Data; // response 或 data 缺失时为 null

下单

操作名

TradeApiService.PLACE_ORDER = place_order. 使用服务端方法 place_order。这是 *ApiService 常量,不是客户端成员方法。

请求

TigerRequest<PlaceOrderResponse>

ModelValue: PlaceOrderModel.

参数

SDK propertyC# typeAPI fieldSDK defaultRequiredConstraints
LangLanguagelangNone (omitted if not set)no
Accountstring (nullable)accountnullAuto-filled if emptyTradeClient uses DefaultAccount when empty
SecretKeystringsecret_keynullno
OrderIdInt32order_idNone (omitted if not set)Optional
SecTypeSecTypesec_typeNone (omitted if not set)Optional
MarketMarketmarketNone (omitted if not set)OptionalEnum value
CurrencyCurrencycurrencyNone (omitted if not set)Optional
SymbolstringsymbolnullRequired
Rightstring (nullable)rightnullOptional
Strikestring (nullable)strikenullOptional
Expirystring (nullable)expirynullOptional
ActionActionTypeactionNone (omitted if not set)Optional
OrderTypeOrderTypeorder_typeNone (omitted if not set)Optionalprice fields are conditionally required by order type
TotalQuantityInt64 (nullable)total_quantitynullOptional
TotalQuantityScaleInt32 (nullable)total_quantity_scalenullOptional
LimitPriceDouble (nullable)limit_pricenullOptionalconditional order-price field
CashAmountDouble (nullable)cash_amountnullOptional
AdjustLimitDoubleadjust_limitNone (omitted if not set)Optional
AuxPriceDouble (nullable)aux_pricenullOptionalconditional order-price field
TrailingPercentDouble (nullable)trailing_percentnullOptionalconditional order-price field
TimeInForceTimeInForcetime_in_forceTimeInForce.DAYOptional
ExpireTimelongexpire_timeNone (omitted if not set)Optional
OutsideRthBooleanoutside_rthtrueOptional
TradingSessionTypeTradeSessiontrading_session_typeNone (omitted if not set)Optional
ExchangestringexchangenullOptional
MultiplierdoublemultiplierNone (omitted if not set)Optional
LocalSymbolstringlocal_symbolnullOptional
AllocAccounts列表,元素为 stringalloc_accountsnullOptional
AllocShares列表,元素为 Doublealloc_sharesnullOptional
AlgoStrategystringalgo_strategynullOptional
AlgoParams列表,元素为 TagValuealgo_paramsnullOptional
DisplaySizeInt64 (nullable)display_sizenullOptional
MinDisplaySizeInt64 (nullable)min_display_sizenullOptional
CheckIntervalsInt64 (nullable)check_intervalsnullOptional
PriceTypestring (nullable)price_typenullOptional
StartTimeInt64 (nullable)start_timenullOptionalTimestamp or date format; maintain chronological order
EndTimeInt64 (nullable)end_timenullOptionalTimestamp or date format; maintain chronological order
UserMarkstringuser_marknullOptional
AttachTypeAttachTypeattach_typeNone (omitted if not set)Optional
ProfitTakerOrderIdInt32profit_taker_orderIdNone (omitted if not set)Optional
ProfitTakerPriceDoubleprofit_taker_priceNone (omitted if not set)Optional
ProfitTakerTifTimeInForceprofit_taker_tifNone (omitted if not set)Optional
ProfitTakerRthBooleanprofit_taker_rthNone (omitted if not set)Optional
StopLossOrderTypeOrderTypestop_loss_order_typeNone (omitted if not set)Optional
StopLossOrderIdInt32stop_loss_orderIdNone (omitted if not set)Optional
StopLossPriceDoublestop_loss_priceNone (omitted if not set)Optional
StopLossLimitPriceDoublestop_loss_limit_priceNone (omitted if not set)Optional
StopLossTifTimeInForcestop_loss_tifNone (omitted if not set)Optional
StopLossTrailingPercentDoublestop_loss_trailing_percentNone (omitted if not set)Optional
StopLossTrailingAmountDoublestop_loss_trailing_amountNone (omitted if not set)Optional
ComboTypestringcombo_typenullOptional

返回

PlaceOrderResponse inherits TigerResponse; its data property is PlaceOrderItem. Key SDK fields: Id: long, SubIds: list of Int64, Orders: list of TradeOrder.

示例

TigerRequest<PlaceOrderResponse> request = new()
{
    ApiMethodName = TradeApiService.PLACE_ORDER,
    ModelValue = new PlaceOrderModel { Account = tradeClient.GetDefaultAccount, OrderId = 12345, SecType = SecType.STK, Market = Market.US, Currency = Currency.USD }
};
PlaceOrderResponse? response = await tradeClient.ExecuteAsync(request);

响应类型

PlaceOrderItem? data = response?.Data; // response 或 data 缺失时为 null

返回示例

{
  "code": 0,
  "message": "success",
  "timestamp": 1785528000000,
  "data": {
    "id": 123458,
    "orderId": 789014,
    "subIds": []
  }
}

Did this page help you?