@totalis/hip4-client 0.73.0 → 0.75.0
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.
- package/CHANGELOG.md +76 -0
- package/dist/generated/account-read.d.ts +4 -4
- package/dist/generated/api-keys.d.ts +1 -1
- package/dist/generated/browse.d.ts +1 -1
- package/dist/generated/client.d.ts +3 -1
- package/dist/generated/errors.d.ts +23 -16
- package/dist/generated/errors.js +65 -13
- package/dist/generated/openapi.d.ts +252 -6
- package/dist/generated/realtime.d.ts +95 -0
- package/dist/generated/version.d.ts +6 -6
- package/dist/generated/version.js +8 -5
- package/dist/stream.d.ts +21 -1
- package/dist/stream.js +32 -11
- package/package.json +1 -1
|
@@ -426,7 +426,7 @@ export type paths = {
|
|
|
426
426
|
readonly put?: never;
|
|
427
427
|
/**
|
|
428
428
|
* Bind embedded wallet
|
|
429
|
-
* @description Idempotently
|
|
429
|
+
* @description Idempotently makes a wallet attested by the authenticated user's signed Privy identity token the account's: the account's current wallet if it has one, else the Privy embedded wallet, else the one Ethereum wallet the user signed in with. The account's wallet never changes once bound; several external wallets on a new account, or a wallet another account holds, answer EMBEDDED_WALLET_CONFLICT, and a smart contract wallet answers WALLET_CONTRACT_UNSUPPORTED. Creating a new account needs a Google, email, X or Ethereum wallet login linked in the identity token, or this answers SIGN_IN_REQUIRED (a Privy user with only a Solana wallet, such as one from the Solana app on the same Privy app, is refused), and, while the closed launch is on, an invite code redeemed with the access service first, or this answers ACCESS_REQUIRED. Existing accounts are unaffected.
|
|
430
430
|
*/
|
|
431
431
|
readonly post: operations["bindEmbeddedWallet"];
|
|
432
432
|
readonly delete?: never;
|
|
@@ -903,6 +903,26 @@ export type paths = {
|
|
|
903
903
|
readonly patch?: never;
|
|
904
904
|
readonly trace?: never;
|
|
905
905
|
};
|
|
906
|
+
readonly "/v1/me/combo-copies": {
|
|
907
|
+
readonly parameters: {
|
|
908
|
+
readonly query?: never;
|
|
909
|
+
readonly header?: never;
|
|
910
|
+
readonly path?: never;
|
|
911
|
+
readonly cookie?: never;
|
|
912
|
+
};
|
|
913
|
+
/**
|
|
914
|
+
* List my copied Combos
|
|
915
|
+
* @description The authenticated account's Combo copy journal, newest first: for each Combo a followed trader opened or cashed out that automatic copying acted on for the account, what became of the account's copy. PENDING is still being quoted, accepted or settled; COPIED landed on chain; SKIPPED was not placed, for reason; FAILED was refused by the vault or the signer. An EXIT appears only when the account mirrors exits and holds a copy of that trader's Combo. Amounts are HyperEVM USDC base units (10^-6). Poll the first page for new rows; ids are stable, and a PENDING row later reads as its outcome. The cursor never expires. leader keeps one public trader's rows. A trader whose profile is now off reads with no leader, and filtering by their username finds nothing.
|
|
916
|
+
*/
|
|
917
|
+
readonly get: operations["listComboCopies"];
|
|
918
|
+
readonly put?: never;
|
|
919
|
+
readonly post?: never;
|
|
920
|
+
readonly delete?: never;
|
|
921
|
+
readonly options?: never;
|
|
922
|
+
readonly head?: never;
|
|
923
|
+
readonly patch?: never;
|
|
924
|
+
readonly trace?: never;
|
|
925
|
+
};
|
|
906
926
|
readonly "/v1/me/copy-summary": {
|
|
907
927
|
readonly parameters: {
|
|
908
928
|
readonly query?: never;
|
|
@@ -1011,6 +1031,30 @@ export type paths = {
|
|
|
1011
1031
|
readonly patch?: never;
|
|
1012
1032
|
readonly trace?: never;
|
|
1013
1033
|
};
|
|
1034
|
+
readonly "/v1/me/vault-agents": {
|
|
1035
|
+
readonly parameters: {
|
|
1036
|
+
readonly query?: never;
|
|
1037
|
+
readonly header?: never;
|
|
1038
|
+
readonly path?: never;
|
|
1039
|
+
readonly cookie?: never;
|
|
1040
|
+
};
|
|
1041
|
+
/**
|
|
1042
|
+
* Get my vault agents
|
|
1043
|
+
* @description The authenticated account's vault agents whose latest AgentGrant on chain is still live, by agent address, a page at a time: each agent may sign the account's named TakerAccept, owner-side SellBack, seller-side CashoutTransfer and Exit to the account's own wallet or Core spot until valid_until. copy_agent marks a server-held copy agent (managed under /v1/me/copy-agents) rather than a key one of the account's devices holds. A grant appears once the chain-agent projects it, after its operation completes. nonce is the agent's last grant, which a new grant or revoke must exceed.
|
|
1044
|
+
*/
|
|
1045
|
+
readonly get: operations["getVaultAgents"];
|
|
1046
|
+
readonly put?: never;
|
|
1047
|
+
/**
|
|
1048
|
+
* Relay the account's grant or revoke of a device's vault agent
|
|
1049
|
+
* @description Relays the account's EIP-712 signature over AgentGrant(account, agent, valid_until, nonce) to setAgent; Totalis pays the gas. agent is a key one of the account's devices holds, so it can sign the account's named Combo accepts, cash-outs and Exits to its own wallet or Core spot without a wallet prompt. valid_until is unix seconds, in the future and at most 180 days away (the vault's limit); 0 revokes at once. nonce must exceed the agent's last grant (GET /v1/me/vault-agents), so a client uses the current unix time. Only the account's own signature (or its ERC-1271 verdict) grants. 403 FORBIDDEN for a copy agent, whose grants go through /v1/me/copy-agents. While financial actions run off only a revoke is relayed. A retry with the same Idempotency-Key returns the same operation.
|
|
1050
|
+
*/
|
|
1051
|
+
readonly post: operations["grantVaultAgent"];
|
|
1052
|
+
readonly delete?: never;
|
|
1053
|
+
readonly options?: never;
|
|
1054
|
+
readonly head?: never;
|
|
1055
|
+
readonly patch?: never;
|
|
1056
|
+
readonly trace?: never;
|
|
1057
|
+
};
|
|
1014
1058
|
readonly "/v1/me/copy-budget": {
|
|
1015
1059
|
readonly parameters: {
|
|
1016
1060
|
readonly query?: never;
|
|
@@ -2409,7 +2453,7 @@ export type paths = {
|
|
|
2409
2453
|
};
|
|
2410
2454
|
/**
|
|
2411
2455
|
* Get maker exposure
|
|
2412
|
-
* @description This maker's open book by outcome at the vault projection checkpoint: per outcome its YES and NO exposure, gross and net, worst case and what offsetting saves, and what awaits settlement; book totals count each ticket once. Legs resolve as a position's do.
|
|
2456
|
+
* @description This maker's open book by outcome at the vault projection checkpoint: per outcome its YES and NO exposure, gross and net, worst case and what offsetting saves, and what awaits settlement; book totals count each ticket once. Legs resolve as a position's do. A maker key reads only its own maker.
|
|
2413
2457
|
*/
|
|
2414
2458
|
readonly get: operations["getMakerExposure"];
|
|
2415
2459
|
readonly put?: never;
|
|
@@ -2429,7 +2473,7 @@ export type paths = {
|
|
|
2429
2473
|
};
|
|
2430
2474
|
/**
|
|
2431
2475
|
* Get maker performance
|
|
2432
|
-
* @description
|
|
2476
|
+
* @description Get your maker's trading P&L per period between `from` and `through`.
|
|
2433
2477
|
*/
|
|
2434
2478
|
readonly get: operations["getMakerPerformance"];
|
|
2435
2479
|
readonly put?: never;
|
|
@@ -2540,6 +2584,38 @@ export type components = {
|
|
|
2540
2584
|
/** @description The account's EIP-712 signature over AgentGrant(account, agent, 0, nonce). */
|
|
2541
2585
|
readonly signature: components["schemas"]["Signature65"];
|
|
2542
2586
|
};
|
|
2587
|
+
/** VaultAgentGrant */
|
|
2588
|
+
readonly VaultAgentGrant: {
|
|
2589
|
+
/** @description The key a device of the account holds; not the account, not a copy agent. */
|
|
2590
|
+
readonly agent: components["schemas"]["LowercaseNonZeroAddress"];
|
|
2591
|
+
/** @description Unix seconds the grant lasts until, at most 180 days away; 0 revokes. */
|
|
2592
|
+
readonly valid_until: components["schemas"]["UInt64String"];
|
|
2593
|
+
/** @description Above the agent's last grant; the current unix time works. */
|
|
2594
|
+
readonly nonce: components["schemas"]["UInt64String"];
|
|
2595
|
+
/** @description The account's EIP-712 signature over AgentGrant(account, agent, valid_until, nonce) in the vault's domain. */
|
|
2596
|
+
readonly signature: components["schemas"]["Signature65"];
|
|
2597
|
+
};
|
|
2598
|
+
/** VaultAgents */
|
|
2599
|
+
readonly VaultAgents: {
|
|
2600
|
+
/** @description The account wallet the agents sign for. */
|
|
2601
|
+
readonly account: components["schemas"]["Address"];
|
|
2602
|
+
/** @description Live grants, by agent address. */
|
|
2603
|
+
readonly agents: readonly components["schemas"]["VaultAgent"][];
|
|
2604
|
+
readonly next_cursor: components["schemas"]["NextCursor"];
|
|
2605
|
+
/** @description Whether more agents follow next_cursor. */
|
|
2606
|
+
readonly has_more: boolean;
|
|
2607
|
+
};
|
|
2608
|
+
/** VaultAgent */
|
|
2609
|
+
readonly VaultAgent: {
|
|
2610
|
+
/** @description The agent key. */
|
|
2611
|
+
readonly agent: components["schemas"]["Address"];
|
|
2612
|
+
/** @description Unix seconds the grant lasts until. */
|
|
2613
|
+
readonly valid_until: components["schemas"]["UInt64String"];
|
|
2614
|
+
/** @description The grant's nonce; a new grant or revoke must exceed it. */
|
|
2615
|
+
readonly nonce: components["schemas"]["UInt64String"];
|
|
2616
|
+
/** @description A server-held copy agent rather than a device's key. */
|
|
2617
|
+
readonly copy_agent: boolean;
|
|
2618
|
+
};
|
|
2543
2619
|
/** AgentGrantRelayed */
|
|
2544
2620
|
readonly AgentGrantRelayed: {
|
|
2545
2621
|
/** @description The relayed setAgent operation. */
|
|
@@ -3017,7 +3093,7 @@ export type components = {
|
|
|
3017
3093
|
* @description Stable HTTP error code. Each code has one HTTP status and one retry value.
|
|
3018
3094
|
* @enum {string}
|
|
3019
3095
|
*/
|
|
3020
|
-
readonly ErrorCode: "INVALID_REQUEST" | "INVALID_QUERY" | "INVALID_CURSOR" | "INVALID_IDEMPOTENCY_KEY" | "ORIGIN_REQUIRED" | "SUBPROTOCOL_REQUIRED" | "UNSUPPORTED_BROWSE_CONTRACT" | "UNAUTHENTICATED" | "FORBIDDEN" | "ORIGIN_NOT_ALLOWED" | "ACCESS_REQUIRED" | "SIGN_IN_REQUIRED" | "NOT_FOUND" | "IDENTITY_NOT_FOUND" | "QUOTE_NOT_FOUND" | "INVITE_CODE_NOT_FOUND" | "IDEMPOTENCY_KEY_REUSED" | "STATE_CONFLICT" | "INVITE_CODE_EXHAUSTED" | "STALE_CURSOR" | "CURSOR_EXPIRED" | "CURSOR_RESET" | "RECURRING_DEFINITION_CONFLICT" | "EMBEDDED_WALLET_CONFLICT" | "SECRET_UNAVAILABLE" | "ROTATION_IN_PROGRESS" | "TELEMETRY_CONFLICT" | "RFQ_NOT_CANCELLABLE" | "RFQ_NOT_OPEN" | "RFQ_GENERATION_STALE" | "RFQ_GENERATION_IN_FLIGHT" | "QUOTE_EXPIRED" | "QUOTE_CANCELLED" | "QUOTE_REPLACED" | "QUOTE_SIGNER_CHANGED" | "QUOTE_CAPACITY_EXCEEDED" | "CORE_ACCOUNT_NOT_READY" | "CORE_ACCOUNT_ACTIVATION_REQUIRED" | "CORE_EXIT_ABANDONED" | "CORE_MOVE_IN_FLIGHT" | "ACCEPTANCE_IN_FLIGHT" | "USERNAME_TAKEN" | "USERNAME_ALREADY_SET" | "USERNAME_REQUIRED" | "INVALID_SIGNATURE" | "WALLET_CONTRACT_UNSUPPORTED" | "WRONG_AUTHORITY" | "KEY_LIMIT_REACHED" | "USERNAME_NOT_ALLOWED" | "FOLLOW_SELF" | "FOLLOW_LIMIT_REACHED" | "RATE_LIMITED" | "CONNECTION_LIMIT" | "RFQ_INTENT_LIMIT" | "QUOTE_EXPOSURE_LIMIT" | "DEPENDENCY_STALE" | "AUTHORIZATION_UNAVAILABLE" | "SOURCE_UNAVAILABLE" | "CONTRACT_UNAVAILABLE" | "MARKET_DATA_UNAVAILABLE" | "BROWSE_UNAVAILABLE" | "FINANCIAL_ACTIONS_DISABLED" | "CORE_EXIT_UNAVAILABLE" | "COLLATERAL_REDUCTION_UNAVAILABLE" | "SPONSORSHIP_UNAVAILABLE" | "CONTRACT_SIGNATURE_OVERLOADED" | "QUOTE_EXPOSURE_STALE" | "COMBO_AUTOMATIC_DISABLED" | "GAS_PRICE_ABOVE_CEILING" | "EMBEDDED_WALLET_UNAVAILABLE" | "CONNECTION_DRAIN";
|
|
3096
|
+
readonly ErrorCode: "INVALID_REQUEST" | "INVALID_QUERY" | "INVALID_CURSOR" | "INVALID_IDEMPOTENCY_KEY" | "ORIGIN_REQUIRED" | "SUBPROTOCOL_REQUIRED" | "UNSUPPORTED_BROWSE_CONTRACT" | "UNAUTHENTICATED" | "FORBIDDEN" | "ORIGIN_NOT_ALLOWED" | "ACCESS_REQUIRED" | "SIGN_IN_REQUIRED" | "NOT_FOUND" | "IDENTITY_NOT_FOUND" | "QUOTE_NOT_FOUND" | "INVITE_CODE_NOT_FOUND" | "IDEMPOTENCY_KEY_REUSED" | "STATE_CONFLICT" | "INVITE_CODE_EXHAUSTED" | "STALE_CURSOR" | "CURSOR_EXPIRED" | "CURSOR_RESET" | "RECURRING_DEFINITION_CONFLICT" | "EMBEDDED_WALLET_CONFLICT" | "SECRET_UNAVAILABLE" | "ROTATION_IN_PROGRESS" | "TELEMETRY_CONFLICT" | "RFQ_NOT_CANCELLABLE" | "RFQ_NOT_OPEN" | "RFQ_GENERATION_STALE" | "RFQ_GENERATION_IN_FLIGHT" | "QUOTE_EXPIRED" | "QUOTE_CANCELLED" | "QUOTE_REPLACED" | "QUOTE_SIGNER_CHANGED" | "QUOTE_CAPACITY_EXCEEDED" | "CORE_ACCOUNT_NOT_READY" | "CORE_ACCOUNT_ACTIVATION_REQUIRED" | "CORE_EXIT_ABANDONED" | "CORE_MOVE_IN_FLIGHT" | "ACCEPTANCE_IN_FLIGHT" | "USERNAME_TAKEN" | "USERNAME_ALREADY_SET" | "USERNAME_REQUIRED" | "INVALID_SIGNATURE" | "WALLET_CONTRACT_UNSUPPORTED" | "WRONG_AUTHORITY" | "KEY_LIMIT_REACHED" | "USERNAME_NOT_ALLOWED" | "FOLLOW_SELF" | "FOLLOW_LIMIT_REACHED" | "RATE_LIMITED" | "CONNECTION_LIMIT" | "RFQ_INTENT_LIMIT" | "QUOTE_EXPOSURE_LIMIT" | "DEPENDENCY_STALE" | "AUTHORIZATION_UNAVAILABLE" | "SOURCE_UNAVAILABLE" | "CONTRACT_UNAVAILABLE" | "MARKET_DATA_UNAVAILABLE" | "BROWSE_UNAVAILABLE" | "FINANCIAL_ACTIONS_DISABLED" | "CORE_EXIT_UNAVAILABLE" | "COLLATERAL_REDUCTION_UNAVAILABLE" | "SPONSORSHIP_UNAVAILABLE" | "CONTRACT_SIGNATURE_OVERLOADED" | "QUOTE_EXPOSURE_STALE" | "COMBO_AUTOMATIC_DISABLED" | "GAS_PRICE_ABOVE_CEILING" | "EXECUTION_BACKLOG_FULL" | "EMBEDDED_WALLET_UNAVAILABLE" | "CONNECTION_DRAIN";
|
|
3021
3097
|
readonly FieldViolation: {
|
|
3022
3098
|
/**
|
|
3023
3099
|
* @description REQUIRED: the input is missing. INVALID: it is present but malformed or out of range. UNEXPECTED: the input is not accepted here.
|
|
@@ -7092,7 +7168,7 @@ export interface operations {
|
|
|
7092
7168
|
};
|
|
7093
7169
|
readonly requestBody?: never;
|
|
7094
7170
|
readonly responses: {
|
|
7095
|
-
/** @description
|
|
7171
|
+
/** @description Account wallet is bound */
|
|
7096
7172
|
readonly 204: {
|
|
7097
7173
|
headers: {
|
|
7098
7174
|
readonly [name: string]: unknown;
|
|
@@ -7103,6 +7179,7 @@ export interface operations {
|
|
|
7103
7179
|
readonly 401: components["responses"]["Error"];
|
|
7104
7180
|
readonly 403: components["responses"]["Error"];
|
|
7105
7181
|
readonly 409: components["responses"]["Error"];
|
|
7182
|
+
readonly 422: components["responses"]["Error"];
|
|
7106
7183
|
readonly 429: components["responses"]["RateLimited"];
|
|
7107
7184
|
readonly 503: components["responses"]["Unavailable"];
|
|
7108
7185
|
};
|
|
@@ -8138,6 +8215,99 @@ export interface operations {
|
|
|
8138
8215
|
readonly 503: components["responses"]["Unavailable"];
|
|
8139
8216
|
};
|
|
8140
8217
|
};
|
|
8218
|
+
readonly listComboCopies: {
|
|
8219
|
+
readonly parameters: {
|
|
8220
|
+
readonly query?: {
|
|
8221
|
+
/** @description Only this public trader's rows. */
|
|
8222
|
+
readonly leader?: components["schemas"]["Username"];
|
|
8223
|
+
/**
|
|
8224
|
+
* @description Omit for the first page; then send the previous response's next_cursor unchanged.
|
|
8225
|
+
* @example eyJ2IjoxLCJzIjoiMTIzNDUifQ
|
|
8226
|
+
*/
|
|
8227
|
+
readonly cursor?: components["parameters"]["Cursor"];
|
|
8228
|
+
/**
|
|
8229
|
+
* @description Maximum items per page, 1 to 200, default 50. A page may hold fewer, even none, while has_more is true.
|
|
8230
|
+
* @example 50
|
|
8231
|
+
*/
|
|
8232
|
+
readonly limit?: components["parameters"]["Limit"];
|
|
8233
|
+
};
|
|
8234
|
+
readonly header?: never;
|
|
8235
|
+
readonly path?: never;
|
|
8236
|
+
readonly cookie?: never;
|
|
8237
|
+
};
|
|
8238
|
+
readonly requestBody?: never;
|
|
8239
|
+
readonly responses: {
|
|
8240
|
+
/** @description A page of copied Combos */
|
|
8241
|
+
readonly 200: {
|
|
8242
|
+
headers: {
|
|
8243
|
+
readonly "Cache-Control"?: "no-store";
|
|
8244
|
+
readonly [name: string]: unknown;
|
|
8245
|
+
};
|
|
8246
|
+
content: {
|
|
8247
|
+
readonly "application/json": {
|
|
8248
|
+
/** @description Copied Combos, newest first. */
|
|
8249
|
+
readonly items: readonly {
|
|
8250
|
+
/** @description Stable ID of the trader's Combo trade; one row per trade. */
|
|
8251
|
+
readonly id: string;
|
|
8252
|
+
/** @description The trader copied; absent once their profile is off. */
|
|
8253
|
+
readonly leader?: components["schemas"]["Username"];
|
|
8254
|
+
/** @description When the copy was decided on, just after the trader's trade. */
|
|
8255
|
+
readonly at: components["schemas"]["$defs-Timestamp"];
|
|
8256
|
+
/** @description When the copy reached its outcome; absent while PENDING. */
|
|
8257
|
+
readonly decided_at?: components["schemas"]["$defs-Timestamp"];
|
|
8258
|
+
/**
|
|
8259
|
+
* @description ENTRY: the trader opened a Combo, and the copy opens the same legs at the account's stake. EXIT: the trader cashed theirs out, and the copy cashes out the account's copy.
|
|
8260
|
+
* @enum {string}
|
|
8261
|
+
*/
|
|
8262
|
+
readonly kind: "ENTRY" | "EXIT";
|
|
8263
|
+
/** @description The Combo's legs. */
|
|
8264
|
+
readonly legs: readonly components["schemas"]["TraderLeg"][];
|
|
8265
|
+
/**
|
|
8266
|
+
* ComboCopyLeaderTrade
|
|
8267
|
+
* @description The trader's Combo.
|
|
8268
|
+
*/
|
|
8269
|
+
readonly leader_trade: {
|
|
8270
|
+
/** @description The trader's Combo ticket. */
|
|
8271
|
+
readonly position_id: components["schemas"]["Bytes32"];
|
|
8272
|
+
/** @description What the trader's ticket staked, net of the taker fee. */
|
|
8273
|
+
readonly stake: components["schemas"]["$defs-Amount"];
|
|
8274
|
+
/** @description What the trader's ticket pays if every leg wins. */
|
|
8275
|
+
readonly payout: components["schemas"]["$defs-Amount"];
|
|
8276
|
+
/** @description The price the trader's cash-out was quoted at; present on an EXIT. A sell-back above the stake pays this less the vault's profit fee; a transfer pays it in full. */
|
|
8277
|
+
readonly price?: components["schemas"]["$defs-Amount"];
|
|
8278
|
+
};
|
|
8279
|
+
/**
|
|
8280
|
+
* @description What became of the copy.
|
|
8281
|
+
* @enum {string}
|
|
8282
|
+
*/
|
|
8283
|
+
readonly state: "PENDING" | "COPIED" | "SKIPPED" | "FAILED";
|
|
8284
|
+
/**
|
|
8285
|
+
* @description Why a SKIPPED copy was not placed; present only then.
|
|
8286
|
+
* @enum {string}
|
|
8287
|
+
*/
|
|
8288
|
+
readonly reason?: "SLIPPAGE" | "NO_QUOTE" | "MAKER_DECLINED" | "CAP_REACHED" | "INSUFFICIENT_BALANCE" | "BELOW_MINIMUM" | "AGENT_EXPIRED" | "CAPACITY" | "PAUSED" | "LEADER_PRIVATE" | "HALTED";
|
|
8289
|
+
/** @description The account's copied Combo ticket, as GET /v1/me/positions names it: on an ENTRY once COPIED, on every EXIT. */
|
|
8290
|
+
readonly position_id?: components["schemas"]["Bytes32"];
|
|
8291
|
+
/** @description What an ENTRY copy stakes from the account's copy budget, taker fee included; absent when it was skipped before it was sized, and on an EXIT. */
|
|
8292
|
+
readonly stake?: components["schemas"]["$defs-Amount"];
|
|
8293
|
+
/** @description What the copied ticket pays if every leg wins; present on a COPIED ENTRY. */
|
|
8294
|
+
readonly payout?: components["schemas"]["$defs-Amount"];
|
|
8295
|
+
/** @description The price the copy's cash-out was quoted at; present on a COPIED EXIT. A sell-back above the stake pays this less the vault's profit fee; the copied position shows what was received. */
|
|
8296
|
+
readonly price?: components["schemas"]["$defs-Amount"];
|
|
8297
|
+
}[];
|
|
8298
|
+
readonly next_cursor: components["schemas"]["NextCursor"];
|
|
8299
|
+
readonly has_more: boolean;
|
|
8300
|
+
};
|
|
8301
|
+
};
|
|
8302
|
+
};
|
|
8303
|
+
readonly 400: components["responses"]["Error"];
|
|
8304
|
+
readonly 401: components["responses"]["Error"];
|
|
8305
|
+
readonly 403: components["responses"]["Error"];
|
|
8306
|
+
readonly 404: components["responses"]["Error"];
|
|
8307
|
+
readonly 429: components["responses"]["RateLimited"];
|
|
8308
|
+
readonly 503: components["responses"]["Unavailable"];
|
|
8309
|
+
};
|
|
8310
|
+
};
|
|
8141
8311
|
readonly getCopySummary: {
|
|
8142
8312
|
readonly parameters: {
|
|
8143
8313
|
readonly query?: never;
|
|
@@ -8394,6 +8564,81 @@ export interface operations {
|
|
|
8394
8564
|
readonly 503: components["responses"]["Unavailable"];
|
|
8395
8565
|
};
|
|
8396
8566
|
};
|
|
8567
|
+
readonly getVaultAgents: {
|
|
8568
|
+
readonly parameters: {
|
|
8569
|
+
readonly query?: {
|
|
8570
|
+
/**
|
|
8571
|
+
* @description Omit for the first page; then send the previous response's next_cursor unchanged.
|
|
8572
|
+
* @example eyJ2IjoxLCJzIjoiMTIzNDUifQ
|
|
8573
|
+
*/
|
|
8574
|
+
readonly cursor?: components["parameters"]["Cursor"];
|
|
8575
|
+
/**
|
|
8576
|
+
* @description Maximum items per page, 1 to 200, default 50. A page may hold fewer, even none, while has_more is true.
|
|
8577
|
+
* @example 50
|
|
8578
|
+
*/
|
|
8579
|
+
readonly limit?: components["parameters"]["Limit"];
|
|
8580
|
+
};
|
|
8581
|
+
readonly header?: never;
|
|
8582
|
+
readonly path?: never;
|
|
8583
|
+
readonly cookie?: never;
|
|
8584
|
+
};
|
|
8585
|
+
readonly requestBody?: never;
|
|
8586
|
+
readonly responses: {
|
|
8587
|
+
/** @description The account's live vault agents */
|
|
8588
|
+
readonly 200: {
|
|
8589
|
+
headers: {
|
|
8590
|
+
readonly "Cache-Control"?: "no-store";
|
|
8591
|
+
readonly [name: string]: unknown;
|
|
8592
|
+
};
|
|
8593
|
+
content: {
|
|
8594
|
+
readonly "application/json": components["schemas"]["VaultAgents"];
|
|
8595
|
+
};
|
|
8596
|
+
};
|
|
8597
|
+
readonly 400: components["responses"]["Error"];
|
|
8598
|
+
readonly 401: components["responses"]["Error"];
|
|
8599
|
+
readonly 403: components["responses"]["Error"];
|
|
8600
|
+
readonly 404: components["responses"]["Error"];
|
|
8601
|
+
readonly 429: components["responses"]["RateLimited"];
|
|
8602
|
+
readonly 503: components["responses"]["Unavailable"];
|
|
8603
|
+
};
|
|
8604
|
+
};
|
|
8605
|
+
readonly grantVaultAgent: {
|
|
8606
|
+
readonly parameters: {
|
|
8607
|
+
readonly query?: never;
|
|
8608
|
+
readonly header: {
|
|
8609
|
+
/**
|
|
8610
|
+
* @description Lowercase UUIDv7 naming this command, unique per caller and route. A retry with the same key and body returns the original result; the same key with a different body returns `409 IDEMPOTENCY_KEY_REUSED`.
|
|
8611
|
+
* @example 0198a6f6-82a5-7abc-9f2a-4f0fb437493e
|
|
8612
|
+
*/
|
|
8613
|
+
readonly "Idempotency-Key": components["parameters"]["IdempotencyKey"];
|
|
8614
|
+
};
|
|
8615
|
+
readonly path?: never;
|
|
8616
|
+
readonly cookie?: never;
|
|
8617
|
+
};
|
|
8618
|
+
readonly requestBody: {
|
|
8619
|
+
readonly content: {
|
|
8620
|
+
readonly "application/json": components["schemas"]["VaultAgentGrant"];
|
|
8621
|
+
};
|
|
8622
|
+
};
|
|
8623
|
+
readonly responses: {
|
|
8624
|
+
/** @description Relayed, not yet on chain. Follow the operation with `GET /v1/me/operations/{operation_id}`. */
|
|
8625
|
+
readonly 202: {
|
|
8626
|
+
headers: {
|
|
8627
|
+
readonly [name: string]: unknown;
|
|
8628
|
+
};
|
|
8629
|
+
content: {
|
|
8630
|
+
readonly "application/json": components["schemas"]["AgentGrantRelayed"];
|
|
8631
|
+
};
|
|
8632
|
+
};
|
|
8633
|
+
readonly 400: components["responses"]["Error"];
|
|
8634
|
+
readonly 401: components["responses"]["Error"];
|
|
8635
|
+
readonly 403: components["responses"]["Error"];
|
|
8636
|
+
readonly 404: components["responses"]["Error"];
|
|
8637
|
+
readonly 409: components["responses"]["Error"];
|
|
8638
|
+
readonly 429: components["responses"]["RateLimited"];
|
|
8639
|
+
readonly 503: components["responses"]["Unavailable"];
|
|
8640
|
+
};
|
|
8641
|
+
};
|
|
8397
8642
|
readonly getCopyBudget: {
|
|
8398
8643
|
readonly parameters: {
|
|
8399
8644
|
readonly query?: never;
|
|
@@ -9177,6 +9422,7 @@ export interface operations {
|
|
|
9177
9422
|
readonly 409: components["responses"]["Error"];
|
|
9178
9423
|
readonly 422: components["responses"]["Error"];
|
|
9179
9424
|
readonly 429: components["responses"]["RateLimited"];
|
|
9425
|
+
/** @description `EXECUTION_BACKLOG_FULL`: the venue's on-chain queue could not send this trade before the quote expires, so nothing was created and the maker was not asked. Wait `Retry-After` seconds and accept a fresh quote. */
|
|
9180
9426
|
readonly 503: components["responses"]["Unavailable"];
|
|
9181
9427
|
};
|
|
9182
9428
|
};
|
|
@@ -10841,7 +11087,7 @@ export interface operations {
|
|
|
10841
11087
|
};
|
|
10842
11088
|
readonly requestBody?: never;
|
|
10843
11089
|
readonly responses: {
|
|
10844
|
-
/** @description Scoped read with one freshness status; amounts are atomic USDC strings or null. No shared caching. */
|
|
11090
|
+
/** @description Complete periods aggregate the positions that closed economically in them; incomplete periods return unavailable metrics. Gas stays unavailable until the payer of every transaction receipt is attributed. Scoped read with one freshness status; amounts are atomic USDC strings or null. No shared caching. */
|
|
10845
11091
|
readonly 200: {
|
|
10846
11092
|
headers: {
|
|
10847
11093
|
readonly "Cache-Control": components["headers"]["CacheControl"];
|
|
@@ -371,6 +371,15 @@ export type components = {
|
|
|
371
371
|
/** @description Publication coverage, sent each heartbeat to subscriptions that set publication_freshness. Null when no checkpoint is available; treat freshness as unproven. */
|
|
372
372
|
readonly data: components["schemas"]["PublicationCheckpoint"] | null;
|
|
373
373
|
};
|
|
374
|
+
readonly CapitalFrame: {
|
|
375
|
+
/**
|
|
376
|
+
* @description Frame discriminator, always capital. Sent to maker subscriptions that set capital: once on subscribe, again whenever the capital changes, and at least every 5000 ms.
|
|
377
|
+
* @constant
|
|
378
|
+
*/
|
|
379
|
+
readonly channel: "capital";
|
|
380
|
+
/** @description The same body as GET /v1/makers/{maker_id}/capital, read when the frame was published; its context says how fresh it is. Without a frame for 15 s, read capital over HTTP. */
|
|
381
|
+
readonly data: components["schemas"]["MakerCapital"];
|
|
382
|
+
};
|
|
374
383
|
readonly Snapshot: {
|
|
375
384
|
/** @description Stream cursor the snapshot is consistent with. Events after it follow on the stream; reconnect with it to replay them. */
|
|
376
385
|
readonly cursor: components["schemas"]["Cursor"];
|
|
@@ -413,6 +422,8 @@ export type components = {
|
|
|
413
422
|
readonly account_reads?: boolean;
|
|
414
423
|
/** @description Opt in to publication checkpoints and a 1000 ms authenticated heartbeat. */
|
|
415
424
|
readonly publication_freshness?: boolean;
|
|
425
|
+
/** @description Opt in to capital frames: the maker's capital read, pushed when it changes and at least every 5 s. Needs vault:read; without it the server closes with SUBSCRIPTION_DENIED. */
|
|
426
|
+
readonly capital?: boolean;
|
|
416
427
|
};
|
|
417
428
|
readonly Subscribe: {
|
|
418
429
|
/**
|
|
@@ -461,6 +472,8 @@ export type components = {
|
|
|
461
472
|
readonly account_reads?: boolean;
|
|
462
473
|
/** @description Opt in to publication checkpoints and a 1000 ms authenticated heartbeat. */
|
|
463
474
|
readonly publication_freshness?: boolean;
|
|
475
|
+
/** @description Opt in to capital frames: the maker's capital read, pushed when it changes and at least every 5 s. Needs vault:read; without it the server closes with SUBSCRIPTION_DENIED. */
|
|
476
|
+
readonly capital?: boolean;
|
|
464
477
|
};
|
|
465
478
|
/**
|
|
466
479
|
* Format: uuid
|
|
@@ -990,6 +1003,88 @@ export type components = {
|
|
|
990
1003
|
/** @description When the withdrawal last changed, RFC3339 UTC. */
|
|
991
1004
|
readonly updated_at: components["schemas"]["Timestamp"];
|
|
992
1005
|
};
|
|
1006
|
+
/** Format: date-time */
|
|
1007
|
+
readonly "$defs-Timestamp": string;
|
|
1008
|
+
/** @description Freshness of the read. Pages of one list share the snapshot bound into their cursor. */
|
|
1009
|
+
readonly ReadContext: {
|
|
1010
|
+
/** @description RFC3339 observation time of the oldest source this read used. */
|
|
1011
|
+
readonly as_of: components["schemas"]["$defs-Timestamp"];
|
|
1012
|
+
/**
|
|
1013
|
+
* @description Freshness of the whole read. CURRENT: every source is fresh and reconciled. STALE: a source lags or has not reconciled, such as a catching-up projection, a pending reorg rescan or a period not fully covered; amounts may be displayed with their age but never authorize an action. UNAVAILABLE: a required source could not be read, so the amounts it backs are null.
|
|
1014
|
+
* @enum {string}
|
|
1015
|
+
*/
|
|
1016
|
+
readonly status: "CURRENT" | "STALE" | "UNAVAILABLE";
|
|
1017
|
+
};
|
|
1018
|
+
readonly "$defs-Amount": string;
|
|
1019
|
+
/** @description Non-negative amount in atomic USDC (6 decimals, "1000000" = 1 USDC); null when it could not be established, never zero in its place. */
|
|
1020
|
+
readonly UnsignedMetric: components["schemas"]["$defs-Amount"] | null;
|
|
1021
|
+
readonly SignedAmount: string;
|
|
1022
|
+
/** @description Signed amount in atomic USDC (6 decimals, "1000000" = 1 USDC); null when it could not be established, never zero in its place. */
|
|
1023
|
+
readonly Metric: components["schemas"]["SignedAmount"] | null;
|
|
1024
|
+
readonly ActionAvailability: {
|
|
1025
|
+
/**
|
|
1026
|
+
* @description Action this decision covers: MAKER_WITHDRAW or MAKER_QUOTE.
|
|
1027
|
+
* @enum {string}
|
|
1028
|
+
*/
|
|
1029
|
+
readonly action: "MAKER_WITHDRAW" | "MAKER_QUOTE";
|
|
1030
|
+
/** @description Funding route the decision covers, e.g. MAKER_VAULT. */
|
|
1031
|
+
readonly route: string;
|
|
1032
|
+
/** @description Amount available for this action and route in atomic USDC (6 decimals, "1000000" = 1 USDC); null with blockers when unavailable. */
|
|
1033
|
+
readonly available: components["schemas"]["UnsignedMetric"];
|
|
1034
|
+
/** @description Machine-readable codes blocking the action, e.g. MAKER_WITHDRAW_PENDING or RECONCILIATION_MISMATCH; at least one when available is null. */
|
|
1035
|
+
readonly blockers: readonly string[];
|
|
1036
|
+
};
|
|
1037
|
+
/** @description A venue admission reservation on the maker vault. */
|
|
1038
|
+
readonly Reservation: {
|
|
1039
|
+
/** @description Stable reservation identifier. */
|
|
1040
|
+
readonly reservation_id: string;
|
|
1041
|
+
/** @description Operations holding this reservation. */
|
|
1042
|
+
readonly operation_ids: readonly string[];
|
|
1043
|
+
/** @description Reserved amount in atomic USDC (6 decimals, "1000000" = 1 USDC). */
|
|
1044
|
+
readonly value: components["schemas"]["$defs-Amount"];
|
|
1045
|
+
/**
|
|
1046
|
+
* @description ACTIVE: held and not yet reflected on-chain; UNKNOWN: outcome unknown, still counted as held.
|
|
1047
|
+
* @enum {string}
|
|
1048
|
+
*/
|
|
1049
|
+
readonly status: "ACTIVE" | "UNKNOWN";
|
|
1050
|
+
};
|
|
1051
|
+
/** @description Maker capital lanes and derived collateral, in atomic USDC (6 decimals, "1000000" = 1 USDC). Amounts are null when unavailable; context.status is their freshness. */
|
|
1052
|
+
readonly MakerCapital: {
|
|
1053
|
+
/** @description Freshness of this read: the oldest source observation and one status for every amount in the response. */
|
|
1054
|
+
readonly context: components["schemas"]["ReadContext"];
|
|
1055
|
+
/** @description Maker owner (its controller) from the same indexed vault row as the lanes. */
|
|
1056
|
+
readonly owner: components["schemas"]["LowercaseNonZeroAddress"];
|
|
1057
|
+
/** @description Maker signer (its quote signer) from the same indexed vault row as the lanes. The zero address means the maker was opened without one and cannot quote. */
|
|
1058
|
+
readonly signer: string;
|
|
1059
|
+
/** @description Maker vault lane V from the vault contract, including escrow and payables. */
|
|
1060
|
+
readonly vault_gross: components["schemas"]["UnsignedMetric"];
|
|
1061
|
+
/** @description Bettor net stakes escrowed in this maker's open tickets (E). */
|
|
1062
|
+
readonly stake_escrow: components["schemas"]["UnsignedMetric"];
|
|
1063
|
+
/** @description Settled winnings owed to ticket holders and not yet claimed (P). */
|
|
1064
|
+
readonly payable_owed: components["schemas"]["UnsignedMetric"];
|
|
1065
|
+
/** @description Original open maker exposure G: payout minus net stake summed over open tickets. */
|
|
1066
|
+
readonly gross_open: components["schemas"]["UnsignedMetric"];
|
|
1067
|
+
/** @description Maker discount lane D from the vault contract, which offsets gross_open in the requirement. */
|
|
1068
|
+
readonly discount: components["schemas"]["UnsignedMetric"];
|
|
1069
|
+
/** @description Collateral requirement R = max(G - min(D, G), ceil(G * floor_bps / 10000)) under the pinned release; null when floor_bps is null or an input is null. */
|
|
1070
|
+
readonly requirement: components["schemas"]["UnsignedMetric"];
|
|
1071
|
+
/** @description Collateral headroom F = max(V - E - P - R, 0). Not a guarantee of quote acceptance. */
|
|
1072
|
+
readonly free_collateral: components["schemas"]["UnsignedMetric"];
|
|
1073
|
+
/** @description Signed C = V - E - P. Excludes open-ticket valuation; not equity or NAV. */
|
|
1074
|
+
readonly capital_net_of_senior_liabilities: components["schemas"]["Metric"];
|
|
1075
|
+
/** @description Admission reservations H the venue holds for this maker that are not yet reflected on-chain; the sum of reservations. */
|
|
1076
|
+
readonly pending_commitments: components["schemas"]["UnsignedMetric"];
|
|
1077
|
+
/** @description max(F - H, 0): free collateral after unreflected commitments. Not private bot capacity. */
|
|
1078
|
+
readonly free_after_pending: components["schemas"]["UnsignedMetric"];
|
|
1079
|
+
/** @description Requirement floor K in basis points from the pinned release; null when the on-chain comparison mismatches, which makes requirement UNAVAILABLE. */
|
|
1080
|
+
readonly floor_bps: number | null;
|
|
1081
|
+
/** @description SHA-256 of the exact pinned artifact that names this deployment's chain and vault: the release artifact on chain 999, the environment's deployment manifest on 998. A client compares it with its own pinned artifact to bind the read to its deployment. */
|
|
1082
|
+
readonly deployment_digest: string;
|
|
1083
|
+
/** @description Decisions for MAKER_WITHDRAW and MAKER_QUOTE on the MAKER_VAULT route. MAKER_WITHDRAW is the amount a new withdrawal request may ask for: free_after_pending, so it never takes collateral from fills already admitted. The vault re-checks free collateral when the request executes after its delay; it is null with MAKER_WITHDRAW_PENDING while a request is live, or with a reconciliation blocker. MAKER_QUOTE is always null with one blocker, because quoting capacity depends on state only the maker's bot holds, such as its other live quotes. PRIVATE_QUOTE_CAPACITY_UNAVAILABLE means only that Totalis cannot compute that amount; it does not mean quoting is off, and the maker can keep quoting. A reconciliation blocker replaces it while the vault read and venue records disagree. */
|
|
1084
|
+
readonly actions: readonly components["schemas"]["ActionAvailability"][];
|
|
1085
|
+
/** @description Venue reservations on MAKER_VAULT that make up pending_commitments. */
|
|
1086
|
+
readonly reservations: readonly components["schemas"]["Reservation"][];
|
|
1087
|
+
} & unknown;
|
|
993
1088
|
readonly ReadSubscription: {
|
|
994
1089
|
/**
|
|
995
1090
|
* @description Account-read contract version of the subscription; always "1".
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
export declare const sdkVersion = "
|
|
2
|
-
export declare const openapiSha256 = "
|
|
3
|
-
export declare const realtimeSha256 = "
|
|
1
|
+
export declare const sdkVersion = "205.0.0-device-vault-agents";
|
|
2
|
+
export declare const openapiSha256 = "e742feade28ca115077a4275e4a6260646278e9adcf0839987b8566a2221c8f5";
|
|
3
|
+
export declare const realtimeSha256 = "1cac740e108e84ad1979f6ccc71089efd840404cb72d1612a86edc02769637e3";
|
|
4
4
|
export declare const jsonSchemaSha256: {
|
|
5
5
|
readonly "account.schema.json": "5106e2d53abef190990eff113f6692dd27df5848439cf5a80a42c11e89f2bef6";
|
|
6
6
|
readonly "comments.schema.json": "18f4addcfa4e31c2c833fce8b8beca61d2e2ee5b6318c2ed0b479698ff56b65e";
|
|
7
7
|
readonly "common.schema.json": "04f51deb3cbea448e59195e26ede3212598d58a7940fe67eb2123fd9161c5edb";
|
|
8
8
|
readonly "core-exit.schema.json": "c7f617e815225cdcac95c236f8b73fbe288ee5713ff444c3be90eb915fc3a401";
|
|
9
|
-
readonly "error.schema.json": "
|
|
9
|
+
readonly "error.schema.json": "56b1e1c4ea26078cb8ce7ab3c554c0415c8c82eec45821180fc0d5e891046c1e";
|
|
10
10
|
readonly "hypercore.schema.json": "5b89b2bbff7ec8cc1b8717375d12ce9cd5ab6aa5af03c4fdc6cc753ef9583a2c";
|
|
11
11
|
readonly "identity.schema.json": "94534b768030736f4fd1fad285f1312454ca5fbff0b1eb5fab70416a78923bd0";
|
|
12
12
|
readonly "maker-access.schema.json": "49698ee0235e42064aae0397db1e0f646bdc10d9dfa10121714ba06dd69fee3b";
|
|
@@ -15,10 +15,10 @@ export declare const jsonSchemaSha256: {
|
|
|
15
15
|
readonly "market-data.schema.json": "85db33fac6a29b0fa87a500bfda947d0ab3913b13f1c26663d4a7c0484c35786";
|
|
16
16
|
readonly "product-metadata.schema.json": "7c8ffbde878a0aedaed16814fcfd2e80038054b140886cc8736bb7b508042631";
|
|
17
17
|
readonly "quote.schema.json": "5616260d399d022bde2d0130cc9f8a09f71a3dc877276adf796c7a174d21b59a";
|
|
18
|
-
readonly "realtime.schema.json": "
|
|
18
|
+
readonly "realtime.schema.json": "1cac740e108e84ad1979f6ccc71089efd840404cb72d1612a86edc02769637e3";
|
|
19
19
|
};
|
|
20
20
|
export declare const operations: {
|
|
21
|
-
readonly client: readonly ["abandonCoreExit", "acceptQuote", "activeCoreExits", "admitOwnMaker", "admitPartnerWallet", "bindEmbeddedWallet", "cancelRfq", "confirmComboCopyAgent", "confirmCoreCopyAgent", "createCashout", "createComment", "createCoreExit", "createDeposit", "createRfq", "createRunOffClaim", "createWalletChallenge", "createWalletSession", "createWithdrawal", "deleteComment", "editComment", "endWalletSession", "followTrader", "getAcceptance", "getAccountActivity", "getAccountPnl", "getAccountPosition", "getBalances", "getCopyAgents", "getCopyBudget", "getCopySettings", "getCopySummary", "getCoreExit", "getDeployment", "getHypercoreBalance", "getHypercorePortfolio", "getHypercoreSettlementCredits", "getIdentity", "getMakerActivity", "getMakerCapital", "getMakerExposure", "getMakerPerformance", "getMakerPosition", "getMakerQuotes", "getMakerTelemetry", "getMakerVaultFundingTransaction", "getMakerWithdrawal", "getMarket", "getMarketDataConfig", "getMarketDefinitions", "getMarketHistory", "getMarketRecurringRound", "getMarketReferenceCloses", "getMarketScoreTimeline", "getMarketStats", "getOperation", "getOwnMaker", "getPartnerReport", "getPerpMarks", "getProfitLeaderboard", "getQuestion", "getQuestionRecurringRound", "getQuestionScoreTimeline", "getRfq", "getSeries", "getSuggestedCombo", "getTaxonomy", "getTrader", "getTraderPnl", "getUsernameAvailability", "getVolumeLeaderboard", "getWithdrawal", "grantComboCopyAgent", "likeComment", "listAccountActivity", "listAccountPositions", "listCommentReplies", "listComments", "listControlledMakers", "listCopiedFills", "listCopyTrades", "listDiscovery", "listFollows", "listMakerActivity", "listMakerPositions", "listMakerQuoteHistory", "listMarkets", "listOperations", "listQuotes", "listTraderPositions", "listTraderTrades", "reactComment", "recordAcquisition", "refreshPicture", "requestComboCopyAgent", "requestCoreCopyAgent", "revokeComboCopyAgent", "searchCatalog", "setAvatar", "setCopyAllocation", "setCopySettings", "setPublicProfile", "setUsername", "stream", "streamMarkets", "switchOffComboCopyAgent", "switchOffCoreCopyAgent", "unfollowTrader", "unlikeComment", "unreactComment"];
|
|
21
|
+
readonly client: readonly ["abandonCoreExit", "acceptQuote", "activeCoreExits", "admitOwnMaker", "admitPartnerWallet", "bindEmbeddedWallet", "cancelRfq", "confirmComboCopyAgent", "confirmCoreCopyAgent", "createCashout", "createComment", "createCoreExit", "createDeposit", "createRfq", "createRunOffClaim", "createWalletChallenge", "createWalletSession", "createWithdrawal", "deleteComment", "editComment", "endWalletSession", "followTrader", "getAcceptance", "getAccountActivity", "getAccountPnl", "getAccountPosition", "getBalances", "getCopyAgents", "getCopyBudget", "getCopySettings", "getCopySummary", "getCoreExit", "getDeployment", "getHypercoreBalance", "getHypercorePortfolio", "getHypercoreSettlementCredits", "getIdentity", "getMakerActivity", "getMakerCapital", "getMakerExposure", "getMakerPerformance", "getMakerPosition", "getMakerQuotes", "getMakerTelemetry", "getMakerVaultFundingTransaction", "getMakerWithdrawal", "getMarket", "getMarketDataConfig", "getMarketDefinitions", "getMarketHistory", "getMarketRecurringRound", "getMarketReferenceCloses", "getMarketScoreTimeline", "getMarketStats", "getOperation", "getOwnMaker", "getPartnerReport", "getPerpMarks", "getProfitLeaderboard", "getQuestion", "getQuestionRecurringRound", "getQuestionScoreTimeline", "getRfq", "getSeries", "getSuggestedCombo", "getTaxonomy", "getTrader", "getTraderPnl", "getUsernameAvailability", "getVaultAgents", "getVolumeLeaderboard", "getWithdrawal", "grantComboCopyAgent", "grantVaultAgent", "likeComment", "listAccountActivity", "listAccountPositions", "listComboCopies", "listCommentReplies", "listComments", "listControlledMakers", "listCopiedFills", "listCopyTrades", "listDiscovery", "listFollows", "listMakerActivity", "listMakerPositions", "listMakerQuoteHistory", "listMarkets", "listOperations", "listQuotes", "listTraderPositions", "listTraderTrades", "reactComment", "recordAcquisition", "refreshPicture", "requestComboCopyAgent", "requestCoreCopyAgent", "revokeComboCopyAgent", "searchCatalog", "setAvatar", "setCopyAllocation", "setCopySettings", "setPublicProfile", "setUsername", "stream", "streamMarkets", "switchOffComboCopyAgent", "switchOffCoreCopyAgent", "unfollowTrader", "unlikeComment", "unreactComment"];
|
|
22
22
|
readonly maker: readonly ["cancelQuote", "confirmQuote", "createCollateralReduction", "createQuote", "getAccountActivity", "getAccountPosition", "getCollateralReduction", "getDeployment", "getMakerActivity", "getMakerCapital", "getMakerExposure", "getMakerPerformance", "getMakerPosition", "getMakerQuotes", "getMakerTelemetry", "getMakerTelemetryPublication", "getMakerVaultFundingTransaction", "getMakerWithdrawal", "getMarket", "getMarketHistory", "getMarketRecurringRound", "getMarketReferenceCloses", "getOperation", "getQuestion", "getQuestionRecurringRound", "getRfq", "getSeries", "getTaxonomy", "listAccountActivity", "listAccountPositions", "listDiscovery", "listMakerAcceptances", "listMakerActivity", "listMakerPositions", "listMakerQuoteHistory", "listMarkets", "listOperations", "listRfqs", "publishMakerTelemetry", "releaseQuoteLease", "renewQuoteLease", "searchCatalog", "stream", "submitMakerSelfFundedTransaction"];
|
|
23
23
|
readonly operator: readonly ["live", "ready"];
|
|
24
24
|
};
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
// Generated by scripts/generate.mjs; do not edit.
|
|
2
|
-
export const sdkVersion = "
|
|
3
|
-
export const openapiSha256 = "
|
|
4
|
-
export const realtimeSha256 = "
|
|
2
|
+
export const sdkVersion = "205.0.0-device-vault-agents";
|
|
3
|
+
export const openapiSha256 = "e742feade28ca115077a4275e4a6260646278e9adcf0839987b8566a2221c8f5";
|
|
4
|
+
export const realtimeSha256 = "1cac740e108e84ad1979f6ccc71089efd840404cb72d1612a86edc02769637e3";
|
|
5
5
|
export const jsonSchemaSha256 = {
|
|
6
6
|
"account.schema.json": "5106e2d53abef190990eff113f6692dd27df5848439cf5a80a42c11e89f2bef6",
|
|
7
7
|
"comments.schema.json": "18f4addcfa4e31c2c833fce8b8beca61d2e2ee5b6318c2ed0b479698ff56b65e",
|
|
8
8
|
"common.schema.json": "04f51deb3cbea448e59195e26ede3212598d58a7940fe67eb2123fd9161c5edb",
|
|
9
9
|
"core-exit.schema.json": "c7f617e815225cdcac95c236f8b73fbe288ee5713ff444c3be90eb915fc3a401",
|
|
10
|
-
"error.schema.json": "
|
|
10
|
+
"error.schema.json": "56b1e1c4ea26078cb8ce7ab3c554c0415c8c82eec45821180fc0d5e891046c1e",
|
|
11
11
|
"hypercore.schema.json": "5b89b2bbff7ec8cc1b8717375d12ce9cd5ab6aa5af03c4fdc6cc753ef9583a2c",
|
|
12
12
|
"identity.schema.json": "94534b768030736f4fd1fad285f1312454ca5fbff0b1eb5fab70416a78923bd0",
|
|
13
13
|
"maker-access.schema.json": "49698ee0235e42064aae0397db1e0f646bdc10d9dfa10121714ba06dd69fee3b",
|
|
@@ -16,7 +16,7 @@ export const jsonSchemaSha256 = {
|
|
|
16
16
|
"market-data.schema.json": "85db33fac6a29b0fa87a500bfda947d0ab3913b13f1c26663d4a7c0484c35786",
|
|
17
17
|
"product-metadata.schema.json": "7c8ffbde878a0aedaed16814fcfd2e80038054b140886cc8736bb7b508042631",
|
|
18
18
|
"quote.schema.json": "5616260d399d022bde2d0130cc9f8a09f71a3dc877276adf796c7a174d21b59a",
|
|
19
|
-
"realtime.schema.json": "
|
|
19
|
+
"realtime.schema.json": "1cac740e108e84ad1979f6ccc71089efd840404cb72d1612a86edc02769637e3"
|
|
20
20
|
};
|
|
21
21
|
export const operations = {
|
|
22
22
|
"client": [
|
|
@@ -89,12 +89,15 @@ export const operations = {
|
|
|
89
89
|
"getTrader",
|
|
90
90
|
"getTraderPnl",
|
|
91
91
|
"getUsernameAvailability",
|
|
92
|
+
"getVaultAgents",
|
|
92
93
|
"getVolumeLeaderboard",
|
|
93
94
|
"getWithdrawal",
|
|
94
95
|
"grantComboCopyAgent",
|
|
96
|
+
"grantVaultAgent",
|
|
95
97
|
"likeComment",
|
|
96
98
|
"listAccountActivity",
|
|
97
99
|
"listAccountPositions",
|
|
100
|
+
"listComboCopies",
|
|
98
101
|
"listCommentReplies",
|
|
99
102
|
"listComments",
|
|
100
103
|
"listControlledMakers",
|
package/dist/stream.d.ts
CHANGED
|
@@ -9,6 +9,8 @@ export type StreamEventOf<T extends StreamEventType> = StreamEvent extends infer
|
|
|
9
9
|
} ? T extends K ? E : never : never : never;
|
|
10
10
|
export type StreamSnapshot = Schemas["Snapshot"];
|
|
11
11
|
export type StreamEventFrame = Schemas["EventFrame"];
|
|
12
|
+
/** A maker's capital, the same body as `GET /v1/makers/{maker_id}/capital`. */
|
|
13
|
+
export type StreamCapital = Schemas["CapitalFrame"]["data"];
|
|
12
14
|
/** What a stream follows: the account (optionally with every open RFQ), or one maker. The client manages the cursor. */
|
|
13
15
|
export type StreamSubscription = Omit<Schemas["AccountSubscription"], "cursor"> | Omit<Schemas["MakerSubscription"], "cursor">;
|
|
14
16
|
/** A server frame: `channel` names what `data` carries. */
|
|
@@ -36,7 +38,11 @@ export type StreamOptions = {
|
|
|
36
38
|
/** The WebSocket origin, such as `wss://hip4-ws.totalis.trade`. Defaults to `baseUrl`, else the environment's stream host. */
|
|
37
39
|
readonly streamBaseUrl?: string;
|
|
38
40
|
readonly accessToken: AccessToken;
|
|
39
|
-
/**
|
|
41
|
+
/**
|
|
42
|
+
* `publication_freshness` (1 s heartbeats and publication checkpoints) defaults on. Its
|
|
43
|
+
* heartbeats are what the silence timeout watches: a stream without it has no watchdog
|
|
44
|
+
* once subscribed, because WebSocket pings are invisible to clients.
|
|
45
|
+
*/
|
|
40
46
|
readonly subscription: StreamSubscription;
|
|
41
47
|
/**
|
|
42
48
|
* Resume after this cursor, for example one a bot persisted from `event.cursor`:
|
|
@@ -52,16 +58,25 @@ export type StreamOptions = {
|
|
|
52
58
|
};
|
|
53
59
|
/** Reconnect after this long without a frame. Default 5000 ms with publication freshness, otherwise off. */
|
|
54
60
|
readonly silenceTimeoutMs?: number;
|
|
61
|
+
/** Reconnect when a connect has not subscribed after this long, including while `accessToken` resolves. Default 10000 ms. */
|
|
62
|
+
readonly connectTimeoutMs?: number;
|
|
55
63
|
};
|
|
56
64
|
type Listeners = {
|
|
57
65
|
/** A new event, in order and deduplicated, with the frame that carried it. */
|
|
58
66
|
event: (event: StreamEvent, frame: StreamEventFrame) => void;
|
|
59
67
|
snapshot: (snapshot: StreamSnapshot) => void;
|
|
68
|
+
/**
|
|
69
|
+
* A maker subscription that set `capital`: its capital on subscribe, on every change and at
|
|
70
|
+
* least every 5 s, so a bot need not read capital before it quotes. Without one for 15 s,
|
|
71
|
+
* read capital over HTTP.
|
|
72
|
+
*/
|
|
73
|
+
capital: (capital: StreamCapital) => void;
|
|
60
74
|
/** Local state built from earlier events is void; replace it from the snapshot that follows. */
|
|
61
75
|
reset: () => void;
|
|
62
76
|
status: (status: StreamStatus) => void;
|
|
63
77
|
/** Every parsed frame, including publication checkpoints, market refreshes and read invalidations. */
|
|
64
78
|
frame: (frame: StreamFrame) => void;
|
|
79
|
+
/** A failure. The stream reconnects unless it is a StreamClosedError, so a run of these means it cannot get back. */
|
|
65
80
|
error: (error: unknown) => void;
|
|
66
81
|
};
|
|
67
82
|
/**
|
|
@@ -107,6 +122,9 @@ export declare class TotalisStream {
|
|
|
107
122
|
private nextDelayMs;
|
|
108
123
|
private timer;
|
|
109
124
|
private silence;
|
|
125
|
+
private connecting;
|
|
126
|
+
/** Counts connects, so one abandoned while its token resolved never opens a socket. */
|
|
127
|
+
private generation;
|
|
110
128
|
private reauthorized;
|
|
111
129
|
/** A REPLAY resume with publication freshness: live waits for the first publication frame, which follows the replayed events. */
|
|
112
130
|
private replaying;
|
|
@@ -138,5 +156,7 @@ export declare class TotalisStream {
|
|
|
138
156
|
private onClose;
|
|
139
157
|
private disconnected;
|
|
140
158
|
private watchSilence;
|
|
159
|
+
/** Gives up on the current connect or socket, reports why and reconnects. */
|
|
160
|
+
private abandon;
|
|
141
161
|
}
|
|
142
162
|
export {};
|