@0xmonaco/types 1.0.41 → 1.0.42-develop.791e6f3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1573,6 +1573,85 @@ export interface paths {
1573
1573
  patch?: never;
1574
1574
  trace?: never;
1575
1575
  };
1576
+ "/api/v1/orders/twap": {
1577
+ parameters: {
1578
+ query?: never;
1579
+ header?: never;
1580
+ path?: never;
1581
+ cookie?: never;
1582
+ };
1583
+ /**
1584
+ * List TWAP orders
1585
+ * @description List TWAP orders.
1586
+ *
1587
+ * List TWAP parent orders for the authenticated user with pagination and
1588
+ * optional filtering by state and trading pair.
1589
+ */
1590
+ get: operations["list_twap_orders"];
1591
+ put?: never;
1592
+ /**
1593
+ * Create TWAP order
1594
+ * @description Create TWAP order.
1595
+ *
1596
+ * Create a server-side TWAP (time-weighted average price) parent order. The
1597
+ * matching engine executes it as a schedule of MARKET child orders with
1598
+ * seeded size/timing randomization across the requested window, then stops
1599
+ * hard at the end time — any unfilled remainder is reported as shortfall,
1600
+ * never traded past the window. Delegated-agent sessions are rejected.
1601
+ */
1602
+ post: operations["create_twap_order"];
1603
+ delete?: never;
1604
+ options?: never;
1605
+ head?: never;
1606
+ patch?: never;
1607
+ trace?: never;
1608
+ };
1609
+ "/api/v1/orders/twap/{twapOrderId}": {
1610
+ parameters: {
1611
+ query?: never;
1612
+ header?: never;
1613
+ path?: never;
1614
+ cookie?: never;
1615
+ };
1616
+ /**
1617
+ * Get TWAP order by ID
1618
+ * @description Get TWAP order by ID.
1619
+ *
1620
+ * Get a single TWAP parent order by its ID. Users can only access their own
1621
+ * TWAP orders.
1622
+ */
1623
+ get: operations["get_twap_order"];
1624
+ put?: never;
1625
+ post?: never;
1626
+ delete?: never;
1627
+ options?: never;
1628
+ head?: never;
1629
+ patch?: never;
1630
+ trace?: never;
1631
+ };
1632
+ "/api/v1/orders/twap/{twapOrderId}/cancel": {
1633
+ parameters: {
1634
+ query?: never;
1635
+ header?: never;
1636
+ path?: never;
1637
+ cookie?: never;
1638
+ };
1639
+ get?: never;
1640
+ put?: never;
1641
+ /**
1642
+ * Cancel TWAP order
1643
+ * @description Cancel TWAP order.
1644
+ *
1645
+ * Cancel a TWAP parent order. Child orders are IOC and never rest, so the
1646
+ * cancel is atomic and immediate; already-executed quantity stands.
1647
+ */
1648
+ post: operations["cancel_twap_order"];
1649
+ delete?: never;
1650
+ options?: never;
1651
+ head?: never;
1652
+ patch?: never;
1653
+ trace?: never;
1654
+ };
1576
1655
  "/api/v1/orders/{orderId}": {
1577
1656
  parameters: {
1578
1657
  query?: never;
@@ -2191,6 +2270,11 @@ export interface components {
2191
2270
  * @example 1050750000
2192
2271
  */
2193
2272
  totalBalanceRaw?: string | null;
2273
+ /**
2274
+ * @description True when this asset is the chain's wrapped-native token (e.g. WSEI): vault deposits can be made in native coin via depositNative (the vault wraps on entry) and withdrawals pay out native
2275
+ * @example true
2276
+ */
2277
+ wrappedNative?: boolean | null;
2194
2278
  };
2195
2279
  AppUser: {
2196
2280
  /**
@@ -2840,6 +2924,24 @@ export interface components {
2840
2924
  */
2841
2925
  message?: string | null;
2842
2926
  };
2927
+ CancelTwapOrderResponse: {
2928
+ /**
2929
+ * Format: uuid
2930
+ * @description Cancelled TWAP parent order UUID
2931
+ * @example 123e4567-e89b-12d3-a456-426614174000
2932
+ */
2933
+ twapOrderId?: string | null;
2934
+ /**
2935
+ * @description Result status: SUCCESS or FAILED
2936
+ * @example SUCCESS
2937
+ */
2938
+ status?: string | null;
2939
+ /**
2940
+ * @description Human-readable status message
2941
+ * @example TWAP order cancelled successfully
2942
+ */
2943
+ message?: string | null;
2944
+ };
2843
2945
  Candle: {
2844
2946
  /**
2845
2947
  * @description Unix timestamp for the start of the candle period in milliseconds
@@ -3209,6 +3311,153 @@ export interface components {
3209
3311
  */
3210
3312
  delegationId?: string | null;
3211
3313
  };
3314
+ CreateTwapOrderRequest: {
3315
+ /**
3316
+ * Format: uuid
3317
+ * @description Trading pair UUID
3318
+ * @example afae0e16-2d05-4ee9-9ee8-afae0e162d05
3319
+ */
3320
+ tradingPairId: string;
3321
+ /**
3322
+ * @description Order side: BUY or SELL
3323
+ * @example BUY
3324
+ */
3325
+ side: string;
3326
+ /**
3327
+ * @description Total quantity to execute across the window as decimal string. Must be at least 2x the pair's minimum order size so it can be sliced, and small enough that the window's slice budget can carry it with every child at or below the pair's maximum order size.
3328
+ * @example 10
3329
+ */
3330
+ quantity: string;
3331
+ /**
3332
+ * Format: int64
3333
+ * @description Execution window length in seconds from launch. Exactly one of durationSeconds or endTime must be set. Bounds (env-tunable defaults): 60 to 2592000 (1 minute to 30 days).
3334
+ * @example 3600
3335
+ */
3336
+ durationSeconds?: number | null;
3337
+ /**
3338
+ * @description Window start (RFC 3339, UTC only — use a Z suffix; non-UTC offsets are rejected). Only valid together with endTime; defaults to now.
3339
+ * @example 2026-08-01T10:00:00Z
3340
+ */
3341
+ startTime?: string | null;
3342
+ /**
3343
+ * @description Window end (RFC 3339, UTC only — use a Z suffix; non-UTC offsets are rejected). Exactly one of durationSeconds or endTime must be set. The effective window must satisfy the same duration bounds. Execution stops hard at this time; any unfilled remainder is reported as shortfall.
3344
+ * @example 2026-08-01T11:00:00Z
3345
+ */
3346
+ endTime?: string | null;
3347
+ /**
3348
+ * @description Optional parent-level limit price as decimal string. BUY child orders never execute above it, SELL children never below it. Omitted: slippage band protection only.
3349
+ * @example 35000.00
3350
+ */
3351
+ limitPrice?: string | null;
3352
+ /**
3353
+ * Format: int32
3354
+ * @description Per-slice protective price band in basis points around the reference price (default 100 = 1%, maximum 500 = 5% — deliberately tighter than the standalone market-order cap; TWAP slices never sweep deep)
3355
+ * @example 100
3356
+ */
3357
+ slippageToleranceBps?: number | null;
3358
+ /**
3359
+ * @description Apply seeded randomization to slice sizes and timing (default true). The seed is recorded for audit, so the schedule is reproducible to compliance but unpredictable to the market.
3360
+ * @example true
3361
+ */
3362
+ randomize?: boolean | null;
3363
+ /**
3364
+ * @description Whether the TWAP parent is reduce-only (margin only). Child orders inherit it and clamp to the live position.
3365
+ * @example false
3366
+ */
3367
+ reduceOnly?: boolean | null;
3368
+ /**
3369
+ * @description Trading mode: SPOT or MARGIN (default: SPOT)
3370
+ * @example SPOT
3371
+ */
3372
+ tradingMode?: string | null;
3373
+ /**
3374
+ * Format: uuid
3375
+ * @description Margin account UUID for margin TWAP orders. Resolved once at creation and reused by every child order.
3376
+ * @example 123e4567-e89b-12d3-a456-426614174000
3377
+ */
3378
+ marginAccountId?: string | null;
3379
+ /**
3380
+ * Format: uuid
3381
+ * @description Existing isolated risk bucket UUID for risk-bucket-scoped margin TWAP orders. Snapshot at creation.
3382
+ * @example 123e4567-e89b-12d3-a456-426614174001
3383
+ */
3384
+ riskBucketId?: string | null;
3385
+ /**
3386
+ * @description Risk bucket mode for margin TWAP orders. Defaults to ISOLATED. Values: ISOLATED, CROSS.
3387
+ * @example CROSS
3388
+ * @enum {string|null}
3389
+ */
3390
+ marginMode?: "ISOLATED" | "CROSS" | null;
3391
+ /**
3392
+ * @description Leverage multiplier as a decimal string. Required for normal margin TWAP orders; optional and ignored for reduce-only.
3393
+ * @example 5
3394
+ */
3395
+ leverage?: string | null;
3396
+ /**
3397
+ * @description Strategy key used to group risk buckets for margin orders
3398
+ * @example my-strategy
3399
+ */
3400
+ strategyKey?: string | null;
3401
+ /**
3402
+ * @description Use master account balance for sub-account orders
3403
+ * @example false
3404
+ */
3405
+ useMasterBalance?: boolean | null;
3406
+ /**
3407
+ * @description Client-assigned idempotency key (max 36 chars), unique per user and application. A duplicate is rejected with 409.
3408
+ * @example oms-3f6a1c
3409
+ */
3410
+ clientTwapId?: string | null;
3411
+ };
3412
+ CreateTwapOrderResponse: {
3413
+ /**
3414
+ * Format: uuid
3415
+ * @description Created TWAP parent order UUID
3416
+ * @example 123e4567-e89b-12d3-a456-426614174000
3417
+ */
3418
+ twapOrderId?: string | null;
3419
+ /**
3420
+ * @description Result status: SUCCESS or FAILED. SUCCESS means the parent is durably recorded; execution itself is best-effort within the window.
3421
+ * @example SUCCESS
3422
+ */
3423
+ status?: string | null;
3424
+ /**
3425
+ * @description Human-readable status message
3426
+ * @example TWAP order created successfully
3427
+ */
3428
+ message?: string | null;
3429
+ /**
3430
+ * @description Initial parent state: always PENDING at create; the parent activates on its first attempted slice
3431
+ * @example PENDING
3432
+ */
3433
+ state?: string | null;
3434
+ /**
3435
+ * Format: uuid
3436
+ * @description Resolved margin account UUID for margin TWAP orders
3437
+ */
3438
+ marginAccountId?: string | null;
3439
+ /**
3440
+ * Format: uuid
3441
+ * @description Resolved isolated risk bucket UUID for risk-bucket-scoped margin TWAP orders
3442
+ */
3443
+ riskBucketId?: string | null;
3444
+ /**
3445
+ * Format: int32
3446
+ * @description Number of slices in the planned schedule
3447
+ * @example 120
3448
+ */
3449
+ plannedSlices?: number | null;
3450
+ /**
3451
+ * @description Planned time of the first slice (ISO 8601)
3452
+ * @example 2026-08-01T10:00:27Z
3453
+ */
3454
+ firstSliceAt?: string | null;
3455
+ /**
3456
+ * @description Resolved window end (ISO 8601). Execution never continues past it.
3457
+ * @example 2026-08-01T11:00:00Z
3458
+ */
3459
+ endTime?: string | null;
3460
+ };
3212
3461
  DelegatedAgent: {
3213
3462
  /**
3214
3463
  * Format: uuid
@@ -3571,6 +3820,11 @@ export interface components {
3571
3820
  * @example 1050750000
3572
3821
  */
3573
3822
  totalBalanceRaw?: string | null;
3823
+ /**
3824
+ * @description True when this asset is the chain's wrapped-native token (e.g. WSEI): vault deposits can be made in native coin via depositNative (the vault wraps on entry) and withdrawals pay out native
3825
+ * @example true
3826
+ */
3827
+ wrappedNative?: boolean | null;
3574
3828
  };
3575
3829
  GetBalancesResponse: {
3576
3830
  balances?: components["schemas"]["AccountBalance"][] | null;
@@ -4528,6 +4782,15 @@ export interface components {
4528
4782
  * as unavailable, never as zero.
4529
4783
  */
4530
4784
  liquidationPrice?: string | null;
4785
+ /**
4786
+ * @description Account distress ratio: maintenance margin required divided by equity
4787
+ * (higher is closer to liquidation). Equity that is zero or negative has no
4788
+ * meaningful quotient, so an account that still owes a maintenance requirement
4789
+ * reports the maximum-decimal sentinel (79228162514264337593543950335,
4790
+ * maximal distress) rather than zero or a negative value, and an account with
4791
+ * no open maintenance requirement reports zero. Clamp the sentinel before
4792
+ * display.
4793
+ */
4531
4794
  marginRatio?: string | null;
4532
4795
  /**
4533
4796
  * @description Maintenance margin required by this position at mark_price using the
@@ -5210,6 +5473,27 @@ export interface components {
5210
5473
  */
5211
5474
  totalPages?: number | null;
5212
5475
  };
5476
+ ListTwapOrdersResponse: {
5477
+ orders?: components["schemas"]["TwapOrder"][] | null;
5478
+ /**
5479
+ * Format: uint32
5480
+ * @description Total number of TWAP orders matching the filter
5481
+ * @example 3
5482
+ */
5483
+ total?: number | null;
5484
+ /**
5485
+ * Format: uint32
5486
+ * @description Current page number
5487
+ * @example 1
5488
+ */
5489
+ page?: number | null;
5490
+ /**
5491
+ * Format: uint32
5492
+ * @description Items per page
5493
+ * @example 20
5494
+ */
5495
+ pageSize?: number | null;
5496
+ };
5213
5497
  MarginAccountMovement: {
5214
5498
  id?: string | null;
5215
5499
  movementType?: string | null;
@@ -5502,6 +5786,14 @@ export interface components {
5502
5786
  priceAsOf?: string | null;
5503
5787
  /** @enum {string|null} */
5504
5788
  pricingStatus?: "priced" | "unpriced" | null;
5789
+ /** @description Weighted-average cost per unit of the holding, quote-denominated, from the spot cost-basis engine. Deposits are marked at the last-traded price at deposit time. Present only when a cost-basis checkpoint exists for the asset. */
5790
+ avgCost?: string | null;
5791
+ /** @description Unrealized PnL for the holding: costBasisQuantity x (markPrice - avgCost), quote-denominated. Uses the cost-basis engine's folded quantity so it agrees with the portfolio summary headline. Present only when both a cost-basis checkpoint and a mark price exist. */
5792
+ unrealizedPnl?: string | null;
5793
+ /** @description Unrealized return on the holding's cost basis, as a percentage: unrealizedPnl / (costBasisQuantity x avgCost) x 100. Present only when unrealizedPnl is present and the cost basis is non-zero. */
5794
+ unrealizedRoe?: string | null;
5795
+ /** @description Cumulative realized PnL booked against this holding over its lifetime, gross of fees, quote-denominated. Present only when a cost-basis checkpoint exists for the asset. */
5796
+ cumRealized?: string | null;
5505
5797
  };
5506
5798
  PortfolioAssetsPerformance: {
5507
5799
  pnl?: string | null;
@@ -6503,6 +6795,15 @@ export interface components {
6503
6795
  * @description Resolve the full live position size when triggered. Mutually exclusive
6504
6796
  * with quantity. For compatibility, omitting both quantity and this field
6505
6797
  * also means full-position close.
6798
+ *
6799
+ * Attaching a full-close leg to a position SUPERSEDES that position's
6800
+ * previously active full-close legs of the same condition type: they are
6801
+ * cancelled in the same engine step that creates the replacement, so moving
6802
+ * a take-profit or stop-loss is one call with no window in which the
6803
+ * position holds both levels or neither. Fixed-quantity legs never
6804
+ * participate — laddered partial exits stack — and a superseded leg's
6805
+ * OCO sibling is left active rather than dropped. Legs attached to an entry
6806
+ * order are excluded on both sides.
6506
6807
  */
6507
6808
  closePosition?: boolean | null;
6508
6809
  };
@@ -6825,6 +7126,155 @@ export interface components {
6825
7126
  */
6826
7127
  tradingBalance?: string | null;
6827
7128
  };
7129
+ TwapOrder: {
7130
+ /**
7131
+ * Format: uuid
7132
+ * @description TWAP parent order UUID
7133
+ */
7134
+ twapOrderId?: string | null;
7135
+ /**
7136
+ * Format: uuid
7137
+ * @description Trading pair UUID
7138
+ */
7139
+ tradingPairId?: string | null;
7140
+ /**
7141
+ * @description Order side: BUY or SELL
7142
+ * @example BUY
7143
+ */
7144
+ side?: string | null;
7145
+ /**
7146
+ * @description Trading mode: SPOT or MARGIN
7147
+ * @example SPOT
7148
+ */
7149
+ tradingMode?: string | null;
7150
+ /**
7151
+ * @description Total quantity requested
7152
+ * @example 10
7153
+ */
7154
+ totalQuantity?: string | null;
7155
+ /**
7156
+ * @description Quantity executed so far across all child orders
7157
+ * @example 4.5
7158
+ */
7159
+ executedQuantity?: string | null;
7160
+ /**
7161
+ * @description Notional (quote) value executed so far
7162
+ * @example 157500.00
7163
+ */
7164
+ executedNotional?: string | null;
7165
+ /**
7166
+ * @description Volume-weighted average fill price (executedNotional / executedQuantity); absent until the first fill
7167
+ * @example 35000.00
7168
+ */
7169
+ averageFillPrice?: string | null;
7170
+ /**
7171
+ * @description Execution progress as a decimal fraction (executedQuantity / totalQuantity, 0 to 1)
7172
+ * @example 0.45
7173
+ */
7174
+ progress?: string | null;
7175
+ /**
7176
+ * @description Parent-level limit price; absent when only the slippage band protects child orders
7177
+ * @example 35000.00
7178
+ */
7179
+ limitPrice?: string | null;
7180
+ /**
7181
+ * Format: int32
7182
+ * @description Per-slice protective price band in basis points
7183
+ * @example 100
7184
+ */
7185
+ slippageToleranceBps?: number | null;
7186
+ /**
7187
+ * @description Whether the parent is reduce-only
7188
+ * @example false
7189
+ */
7190
+ reduceOnly?: boolean | null;
7191
+ /**
7192
+ * Format: uuid
7193
+ * @description Margin account UUID for margin TWAP orders
7194
+ */
7195
+ marginAccountId?: string | null;
7196
+ /**
7197
+ * Format: uuid
7198
+ * @description Isolated risk bucket UUID for risk-bucket-scoped margin TWAP orders
7199
+ */
7200
+ riskBucketId?: string | null;
7201
+ /**
7202
+ * @description Leverage for margin TWAP orders
7203
+ * @example 5
7204
+ */
7205
+ leverage?: string | null;
7206
+ /**
7207
+ * @description Whether child orders use the master account balance
7208
+ * @example false
7209
+ */
7210
+ useMasterBalance?: boolean | null;
7211
+ /** @description Strategy key used to group risk buckets */
7212
+ strategyKey?: string | null;
7213
+ /** @description Client-assigned idempotency key */
7214
+ clientTwapId?: string | null;
7215
+ /**
7216
+ * @description Whether seeded size/timing randomization is applied to the schedule
7217
+ * @example true
7218
+ */
7219
+ randomize?: boolean | null;
7220
+ /**
7221
+ * @description Window start (ISO 8601)
7222
+ * @example 2026-08-01T10:00:00Z
7223
+ */
7224
+ startTime?: string | null;
7225
+ /**
7226
+ * @description Window end (ISO 8601). Execution stops hard at this time.
7227
+ * @example 2026-08-01T11:00:00Z
7228
+ */
7229
+ endTime?: string | null;
7230
+ /**
7231
+ * Format: int64
7232
+ * @description Derived base slice interval in milliseconds (stored for audit)
7233
+ * @example 30000
7234
+ */
7235
+ intervalMs?: number | null;
7236
+ /**
7237
+ * Format: int32
7238
+ * @description Number of slices in the planned schedule
7239
+ * @example 120
7240
+ */
7241
+ plannedSlices?: number | null;
7242
+ /**
7243
+ * Format: int32
7244
+ * @description Number of child orders placed so far
7245
+ * @example 54
7246
+ */
7247
+ slicesPlaced?: number | null;
7248
+ /**
7249
+ * Format: int32
7250
+ * @description Number of slices skipped or failed so far (limit price through the market, self-trade prevention, halted market, failed admission). Skips never terminate the parent; the deficit flows into catch-up.
7251
+ * @example 2
7252
+ */
7253
+ slicesSkipped?: number | null;
7254
+ /**
7255
+ * @description Planned time of the next slice (ISO 8601); absent once the parent is terminal
7256
+ * @example 2026-08-01T10:27:30Z
7257
+ */
7258
+ nextSliceAt?: string | null;
7259
+ /**
7260
+ * @description Parent state: PENDING, ACTIVE, COMPLETED, or CANCELLED
7261
+ * @example ACTIVE
7262
+ */
7263
+ state?: string | null;
7264
+ /** @description Terminal cause detail, e.g. an end-of-window shortfall ('ended with shortfall <qty>'); absent for non-terminal parents */
7265
+ terminalReason?: string | null;
7266
+ /**
7267
+ * @description Creation timestamp (ISO 8601)
7268
+ * @example 2026-08-01T09:59:58Z
7269
+ */
7270
+ createdAt?: string | null;
7271
+ /** @description Last update timestamp (ISO 8601) */
7272
+ updatedAt?: string | null;
7273
+ /** @description Cancellation timestamp (ISO 8601) */
7274
+ cancelledAt?: string | null;
7275
+ /** @description Completion timestamp (ISO 8601) */
7276
+ completedAt?: string | null;
7277
+ };
6828
7278
  UpdateLimitRequest: {
6829
7279
  /**
6830
7280
  * Format: uuid
@@ -9397,6 +9847,8 @@ export interface operations {
9397
9847
  endTime?: number;
9398
9848
  /** @description Max candles to return (max 1000) */
9399
9849
  limit?: number;
9850
+ /** @description Price series to chart: trade (default, trade-derived OHLCV) or mark (mark-price series, margin pairs only; each candle's open/high/low/close are the bucket's closing mark and volume is 0) */
9851
+ priceType?: "trade" | "mark";
9400
9852
  };
9401
9853
  header?: never;
9402
9854
  path: {
@@ -10299,6 +10751,207 @@ export interface operations {
10299
10751
  };
10300
10752
  };
10301
10753
  };
10754
+ list_twap_orders: {
10755
+ parameters: {
10756
+ query?: {
10757
+ /** @description Page number (1-indexed) */
10758
+ page?: number;
10759
+ /** @description Items per page (max 100) */
10760
+ pageSize?: number;
10761
+ state?: string;
10762
+ /** @description Trading pair identifier (UUID) */
10763
+ tradingPairId?: string;
10764
+ };
10765
+ header?: never;
10766
+ path?: never;
10767
+ cookie?: never;
10768
+ };
10769
+ requestBody?: never;
10770
+ responses: {
10771
+ /** @description OK */
10772
+ 200: {
10773
+ headers: {
10774
+ [name: string]: unknown;
10775
+ };
10776
+ content: {
10777
+ "application/json": components["schemas"]["ListTwapOrdersResponse"];
10778
+ };
10779
+ };
10780
+ /** @description Invalid query parameters */
10781
+ 400: {
10782
+ headers: {
10783
+ [name: string]: unknown;
10784
+ };
10785
+ content?: never;
10786
+ };
10787
+ /** @description Authentication required */
10788
+ 401: {
10789
+ headers: {
10790
+ [name: string]: unknown;
10791
+ };
10792
+ content?: never;
10793
+ };
10794
+ /** @description Internal server error */
10795
+ 500: {
10796
+ headers: {
10797
+ [name: string]: unknown;
10798
+ };
10799
+ content?: never;
10800
+ };
10801
+ };
10802
+ };
10803
+ create_twap_order: {
10804
+ parameters: {
10805
+ query?: never;
10806
+ header?: never;
10807
+ path?: never;
10808
+ cookie?: never;
10809
+ };
10810
+ requestBody: {
10811
+ content: {
10812
+ "application/json": components["schemas"]["CreateTwapOrderRequest"];
10813
+ };
10814
+ };
10815
+ responses: {
10816
+ /** @description OK */
10817
+ 200: {
10818
+ headers: {
10819
+ [name: string]: unknown;
10820
+ };
10821
+ content: {
10822
+ "application/json": components["schemas"]["CreateTwapOrderResponse"];
10823
+ };
10824
+ };
10825
+ /** @description Invalid TWAP parameters (window bounds, quantity too small or too large to slice, margin field mismatch) or per-user active TWAP cap reached */
10826
+ 400: {
10827
+ headers: {
10828
+ [name: string]: unknown;
10829
+ };
10830
+ content?: never;
10831
+ };
10832
+ /** @description Authentication required or delegated-agent session (rejected for TWAP) */
10833
+ 401: {
10834
+ headers: {
10835
+ [name: string]: unknown;
10836
+ };
10837
+ content?: never;
10838
+ };
10839
+ /** @description Duplicate clientTwapId for this user and application */
10840
+ 409: {
10841
+ headers: {
10842
+ [name: string]: unknown;
10843
+ };
10844
+ content?: never;
10845
+ };
10846
+ /** @description Internal server error or matching engine failure */
10847
+ 500: {
10848
+ headers: {
10849
+ [name: string]: unknown;
10850
+ };
10851
+ content?: never;
10852
+ };
10853
+ };
10854
+ };
10855
+ get_twap_order: {
10856
+ parameters: {
10857
+ query?: never;
10858
+ header?: never;
10859
+ path: {
10860
+ twapOrderId: string;
10861
+ };
10862
+ cookie?: never;
10863
+ };
10864
+ requestBody?: never;
10865
+ responses: {
10866
+ /** @description OK */
10867
+ 200: {
10868
+ headers: {
10869
+ [name: string]: unknown;
10870
+ };
10871
+ content: {
10872
+ "application/json": components["schemas"]["TwapOrder"];
10873
+ };
10874
+ };
10875
+ /** @description Invalid TWAP order ID format */
10876
+ 400: {
10877
+ headers: {
10878
+ [name: string]: unknown;
10879
+ };
10880
+ content?: never;
10881
+ };
10882
+ /** @description Authentication required */
10883
+ 401: {
10884
+ headers: {
10885
+ [name: string]: unknown;
10886
+ };
10887
+ content?: never;
10888
+ };
10889
+ /** @description TWAP order not found */
10890
+ 404: {
10891
+ headers: {
10892
+ [name: string]: unknown;
10893
+ };
10894
+ content?: never;
10895
+ };
10896
+ /** @description Internal server error */
10897
+ 500: {
10898
+ headers: {
10899
+ [name: string]: unknown;
10900
+ };
10901
+ content?: never;
10902
+ };
10903
+ };
10904
+ };
10905
+ cancel_twap_order: {
10906
+ parameters: {
10907
+ query?: never;
10908
+ header?: never;
10909
+ path: {
10910
+ twapOrderId: string;
10911
+ };
10912
+ cookie?: never;
10913
+ };
10914
+ requestBody?: never;
10915
+ responses: {
10916
+ /** @description OK */
10917
+ 200: {
10918
+ headers: {
10919
+ [name: string]: unknown;
10920
+ };
10921
+ content: {
10922
+ "application/json": components["schemas"]["CancelTwapOrderResponse"];
10923
+ };
10924
+ };
10925
+ /** @description Invalid TWAP order ID or order already terminal */
10926
+ 400: {
10927
+ headers: {
10928
+ [name: string]: unknown;
10929
+ };
10930
+ content?: never;
10931
+ };
10932
+ /** @description Authentication required or delegated-agent session (rejected for TWAP) */
10933
+ 401: {
10934
+ headers: {
10935
+ [name: string]: unknown;
10936
+ };
10937
+ content?: never;
10938
+ };
10939
+ /** @description TWAP order not found */
10940
+ 404: {
10941
+ headers: {
10942
+ [name: string]: unknown;
10943
+ };
10944
+ content?: never;
10945
+ };
10946
+ /** @description Internal server error */
10947
+ 500: {
10948
+ headers: {
10949
+ [name: string]: unknown;
10950
+ };
10951
+ content?: never;
10952
+ };
10953
+ };
10954
+ };
10302
10955
  get_order_by_id: {
10303
10956
  parameters: {
10304
10957
  query?: never;