developers:apiv2:reference

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
developers:apiv2:reference [2026/09/07 15:09] – [Proto files] chaddevelopers:apiv2:reference [2026/09/07 17:48] (current) – [ServerMessage (server → you)] chad
Line 41: Line 41:
  
 ===== Proto files ===== ===== Proto files =====
- 
-[[https://github.com/CTS-Futures/t4-api-tools/tree/main/proto/t4/v2|Proto Files in the T4 GitHub Repository]] 
- 
  
 ^ File ^ Contents ^ ^ File ^ Contents ^
 | [[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/service.proto|proto/t4/v2/service.proto]] | ''ClientMessage'' / ''ServerMessage'' envelopes, ''Heartbeat''. | | [[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/service.proto|proto/t4/v2/service.proto]] | ''ClientMessage'' / ''ServerMessage'' envelopes, ''Heartbeat''. |
-| [[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/auth/auth.proto]] | Login and authentication tokens. |+| [[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/auth/auth.proto|proto/t4/v2/auth/auth.proto]] | Login and authentication tokens. |
 | [[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/market/market.proto|proto/t4/v2/market/market.proto]] | Market-data subscribe and feed messages. | | [[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/market/market.proto|proto/t4/v2/market/market.proto]] | Market-data subscribe and feed messages. |
-| [[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/service.proto|proto/t4/v2/account/account.proto]] | Account subscribe, snapshot and updates. | +| [[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/account/account.proto|proto/t4/v2/account/account.proto]] | Account subscribe, snapshot and updates. | 
-| [[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/service.proto|proto/t4/v2/orderrouting/orderrouting.proto]] | Order submit/revise/pull/batch and updates. | +| [[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/orderrouting/orderrouting.proto|proto/t4/v2/orderrouting/orderrouting.proto]] | Order submit/revise/pull/batch and updates. | 
-| [[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/service.proto|proto/t4/v2/common/enums.proto]] | All enums. | +| [[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/common/enums.proto|proto/t4/v2/common/enums.proto]] | All enums. | 
-| [[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/service.proto|proto/t4/v2/common/price.proto]] | ''Price'' and ''Decimal'' wrappers. |+| [[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/common/price.proto|proto/t4/v2/common/price.proto]] | ''Price'' and ''Decimal'' wrappers. | 
 + 
 +===== ClientMessage (client → server) ===== 
 + 
 +<WRAP 75%> 
 +^ Payload ^ Purpose ^ 
 +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/service.proto#L75|Heartbeat]]'' | Keepalive. | 
 +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/auth/auth.proto#L9|LoginRequest]]'' | Authenticate. | 
 +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/auth/auth.proto#L63|AuthenticationTokenRequest]]'' | Request a token. | 
 +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/market/market.proto#L9|MarketSubscribe]]'' | Subscribe/unsubscribe a market (''quotes'' level + ''ticker''). | 
 +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/account/account.proto#L12|AccountSubscribe]]'' | Subscribe account(s). | 
 +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/orderrouting/orderrouting.proto#L30|OrderSubmit]]'' | Place order(s). | 
 +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/orderrouting/orderrouting.proto#L74|OrderRevise]]'' | Revise order(s). | 
 +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/orderrouting/orderrouting.proto#L100|OrderPull]]'' | Cancel order(s). | 
 +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/orderrouting/orderrouting.proto#L66|OrderBatch]]'' | All-or-nothing batch. | 
 +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/orderrouting/orderrouting.proto#L118|CreateUDS]]'' | Define a strategy. | 
 +</WRAP>
  
-===== ClientMessage (you → server) ===== 
  
-^ Field ^ Payload ^ Purpose ^ Docs ^ 
-| 1 | ''Heartbeat'' | Keepalive. | [[developers:apiv2:connecting|Connecting]] | 
-| 2 | ''LoginRequest'' | Authenticate. | [[developers:apiv2:connecting|Connecting]] | 
-| 3 | ''AuthenticationTokenRequest'' | Request a token. | [[developers:apiv2:connecting|Connecting]] | 
-| 100 | ''MarketSubscribe'' | Subscribe/unsubscribe a market (''quotes'' level + ''ticker''). | [[developers:apiv2:markets|Market Data]] | 
-| 200 | ''AccountSubscribe'' | Subscribe account(s). | [[developers:apiv2:accounts|Account Feed]] | 
-| 300 | ''OrderSubmit'' | Place order(s). | [[developers:apiv2:orders|Order Routing]] | 
-| 301 | ''OrderRevise'' | Revise order(s). | [[developers:apiv2:orders|Order Routing]] | 
-| 302 | ''OrderPull'' | Cancel order(s). | [[developers:apiv2:orders|Order Routing]] | 
-| 303 | ''OrderBatch'' | All-or-nothing batch. | [[developers:apiv2:orders|Order Routing]] | 
-| 340 | ''CreateUDS'' | Define a strategy. | [[developers:apiv2:orders|Order Routing]] | 
  
-===== ServerMessage (server → you) =====+===== ServerMessage (server → client) =====
  
-^ Field ^ Payload ^ Purpose ^ Docs +<WRAP 75%> 
-| 1 | ''Heartbeat'' | Keepalive. | [[developers:apiv2:connecting|Connecting]] +^ Payload ^ Purpose ^ 
-| 2 | ''LoginResponse'' | Login result, identity, entitlements. | [[developers:apiv2:connecting|Connecting]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/service.proto#L83|Heartbeat]]'' | Keepalive. | 
-| 3 | ''AuthenticationToken'' | Token + expiry. | [[developers:apiv2:connecting|Connecting]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/auth/auth.proto#L25|LoginResponse]]'' | Login result, identity, entitlements. | 
-| 100 | ''MarketSubscribeReject'' | Subscribe refused (check ''mode''). | [[developers:apiv2:markets|Market Data]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/auth/auth.proto#L75|AuthenticationToken]]'' | Token + expiry. | 
-| 102 | ''MarketDetails'' | Instrument definition. | [[developers:apiv2:markets|Market Data]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/market/market.proto#L21|MarketSubscribeReject]]'' | Subscribe refused (check ''mode''). | 
-| 103 | ''MarketDepth'' | Depth update (top-of-book / full book). | [[developers:apiv2:markets|Market Data]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/market/market.proto#L29|MarketDetails]]'' | Instrument definition. | 
-| 104 | ''MarketTrade'' | Trade print (''ticker''). | [[developers:apiv2:markets|Market Data]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/market/market.proto#L79|MarketDepth]]'' | Depth update (top-of-book / full book). | 
-| 105 | ''MarketHighLow'' | Session high/low/open. | [[developers:apiv2:markets|Market Data]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/market/market.proto#L119|MarketTrade]]'' | Trade print (''ticker''). | 
-| 106 | ''MarketPriceLimits'' | Price limits. | [[developers:apiv2:markets|Market Data]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/market/market.proto#L144|MarketHighLow]]'' | Session high/low/open. | 
-| 107 | ''MarketSettlement'' | Settlement, OI, VWAP. | [[developers:apiv2:markets|Market Data]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/market/market.proto#L155|MarketPriceLimits]]'' | Price limits. | 
-| 108 | ''MarketSnapshot'' | Full state on subscribe (price feed). | [[developers:apiv2:markets|Market Data]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/market/market.proto#L165|MarketSettlement]]'' | Settlement, OI, VWAP. | 
-| 109 | ''MarketByOrderSnapshot'' | Full book on subscribe (MBO). | [[developers:apiv2:markets|Market Data]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/market/market.proto#L190|MarketSnapshot]]'' | Full state on subscribe (price feed). | 
-| 110 | ''MarketByOrderUpdate'' | Per-order changes (MBO). | [[developers:apiv2:markets|Market Data]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/market/market.proto#L213|MarketByOrderSnapshot]]'' | Full book on subscribe (MBO). | 
-| 200 | ''AccountSubscribeResponse'' | Subscribe result. | [[developers:apiv2:accounts|Account Feed]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/market/market.proto#L231|MarketByOrderUpdate]]'' | Per-order changes (MBO). | 
-| 201 | ''AccountCurrency'' | Currency rates. | [[developers:apiv2:accounts|Account Feed]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/account/account.proto#L18|AccountSubscribeResponse]]'' | Subscribe result. | 
-| 202 | ''AccountPosition'' | Position. | [[developers:apiv2:accounts|Account Feed]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/account/account.proto#L26|AccountCurrency]]'' | Currency rates. | 
-| 203 | ''AccountUpdate'' | Balances / margin. | [[developers:apiv2:accounts|Account Feed]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/account/account.proto#L34|AccountPosition]]'' | Position. | 
-| 204 | ''AccountDetails'' | Account configuration. | [[developers:apiv2:accounts|Account Feed]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/account/account.proto#L78|AccountUpdate]]'' | Balances / margin. | 
-| 205 | ''AccountSnapshot'' | Full state on subscribe. | [[developers:apiv2:accounts|Account Feed]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/account/account.proto#L107|AccountDetails]]'' | Account configuration. | 
-| 206 | ''AccountProfit'' | Account UPL / RPL. | [[developers:apiv2:accounts|Account Feed]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/account/account.proto#L161|AccountSnapshot]]'' | Full state on subscribe. | 
-| 207 | ''AccountPositionProfit'' | Per-position UPL / RPL. | [[developers:apiv2:accounts|Account Feed]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/account/account.proto#L171|AccountProfit]]'' | Account UPL / RPL. | 
-| 300 | ''OrderUpdate'' | Unified order lifecycle event. | [[developers:apiv2:orders|Order Routing]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/account/account.proto#L191|AccountPositionProfit]]'' | Per-position UPL / RPL. | 
-| 301 | ''OrderTrade'' | Fill. | [[developers:apiv2:orders|Order Routing]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/orderrouting/orderrouting.proto#L155|OrderUpdate]]'' | Unified order lifecycle event. | 
-| 302 | ''MarginInquiryResponse'' | Margin preview. | [[developers:apiv2:orders|Order Routing]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/orderrouting/orderrouting.proto#L258|OrderTrade]]'' | Fill. | 
-| 310 | ''OrderBatchAcknowledge'' | Batch accepted. | [[developers:apiv2:orders|Order Routing]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/orderrouting/orderrouting.proto#L326|MarginInquiryResponse]]'' | Margin preview. | 
-| 311 | ''OrderBatchReject'' | Batch rejected. | [[developers:apiv2:orders|Order Routing]] +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/orderrouting/orderrouting.proto#L288|OrderBatchAcknowledge]]'' | Batch accepted. | 
-| 340 | ''CreateUDSResponse'' | Strategy created. | [[developers:apiv2:orders|Order Routing]] |+| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/orderrouting/orderrouting.proto#L305|OrderBatchReject]]'' | Batch rejected. | 
 +| ''[[https://github.com/CTS-Futures/t4-api-tools/blob/main/proto/t4/v2/orderrouting/orderrouting.proto#L279|CreateUDSResponse]]'' | Strategy created. | 
 +</WRAP>
  
  • developers/apiv2/reference.1788793790.txt.gz
  • Last modified: 2026/09/07 15:09
  • by chad