@totalis/hip4-client 0.97.0 → 0.99.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 CHANGED
@@ -3,6 +3,40 @@
3
3
  `@totalis/hip4-client` follows [semantic versioning](https://semver.org).
4
4
  The contract version the generated types come from is `sdkVersion` in `./version`.
5
5
 
6
+ ## 0.99.0
7
+
8
+ ### Added
9
+
10
+ - Partner account value (TT-2795, contract `232.0.0-partner-account-value`,
11
+ major 228, additive). `getPartnerAccountValue`
12
+ (`GET /v1/partner/accounts/{wallet}/account-value`, partner server key)
13
+ answers the `AccountValue` the user's own `getAccountValue` does, for a wallet
14
+ the partner admitted that still signs for the account it opened; any other
15
+ wallet is `404 NOT_FOUND`, and a deployment with financial actions off is
16
+ `503 FINANCIAL_ACTIONS_DISABLED`. 600 reads a minute per partner.
17
+ `createPartnerServer` gains `accountValue(wallet)` for it.
18
+
19
+ ## 0.98.0
20
+
21
+ ### Added
22
+
23
+ - Partner webhook replay (TT-2794, contract `231.0.0-partner-webhook-events`,
24
+ major 227, additive). `listPartnerWebhookEvents`
25
+ (`GET /v1/partner/webhook-events`, partner server key) lists every webhook
26
+ event Totalis queued for the partner in the last 30 days, oldest first, with
27
+ the body as posted, its `status` (`PENDING`, `DELIVERED` or `FAILED`),
28
+ `attempts`, `queued_at` and `delivered_at`. Page with `cursor` and narrow
29
+ with `since`. `createPartnerServer` gains `webhookEvents` for it.
30
+ - Account value (TT-2787, contract `230.0.0-account-value`, major 226,
31
+ additive). `getAccountValue` (`GET /v1/me/account-value`, scope
32
+ `account:read`) answers everything an account holds at Totalis, every
33
+ amount read at one HyperEVM block (`block_number`): `wallet_usdc`,
34
+ `vault_cash` (all of it, including cash held for an operation that has not
35
+ landed), `run_off_cash`, `open_positions` and their `open_cost` (the sum of
36
+ `acquisition_cost`), and `claimable_profit` (unclaimed profit net of the
37
+ fee), with `amount` their total. When `state` is `UNKNOWN` every amount is
38
+ null. `totalis.accountValue()` reads it.
39
+
6
40
  ## 0.97.0
7
41
 
8
42
  ### Changed
@@ -26,6 +26,8 @@ export type paths = {
26
26
  readonly "/v1/partner/wallet-admissions": Pick<SharedPaths["/v1/partner/wallet-admissions"], "parameters" | "post">;
27
27
  readonly "/v1/partner/report": Pick<SharedPaths["/v1/partner/report"], "parameters" | "get">;
28
28
  readonly "/v1/partner/fills": Pick<SharedPaths["/v1/partner/fills"], "parameters" | "get">;
29
+ readonly "/v1/partner/webhook-events": Pick<SharedPaths["/v1/partner/webhook-events"], "parameters" | "get">;
30
+ readonly "/v1/partner/accounts/{wallet}/account-value": Pick<SharedPaths["/v1/partner/accounts/{wallet}/account-value"], "parameters" | "get">;
29
31
  readonly "/v1/me/acquisition": Pick<SharedPaths["/v1/me/acquisition"], "parameters" | "put">;
30
32
  readonly "/v1/me/username": Pick<SharedPaths["/v1/me/username"], "parameters" | "put">;
31
33
  readonly "/v1/me/username/availability": Pick<SharedPaths["/v1/me/username/availability"], "parameters" | "get">;
@@ -102,6 +104,7 @@ export type paths = {
102
104
  readonly "/v1/rfqs/{rfq_id}": Pick<SharedPaths["/v1/rfqs/{rfq_id}"], "parameters" | "get">;
103
105
  readonly "/v1/rfqs/{rfq_id}/cancel": Pick<SharedPaths["/v1/rfqs/{rfq_id}/cancel"], "parameters" | "post">;
104
106
  readonly "/v1/me/balances": Pick<SharedPaths["/v1/me/balances"], "parameters" | "get">;
107
+ readonly "/v1/me/account-value": Pick<SharedPaths["/v1/me/account-value"], "parameters" | "get">;
105
108
  readonly "/v1/me/operations": Pick<SharedPaths["/v1/me/operations"], "parameters" | "get">;
106
109
  readonly "/v1/me/operations/{operation_id}": Pick<SharedPaths["/v1/me/operations/{operation_id}"], "parameters" | "get">;
107
110
  readonly "/v1/makers/{maker_id}/funding-transaction": Pick<SharedPaths["/v1/makers/{maker_id}/funding-transaction"], "parameters" | "get">;
@@ -120,4 +123,4 @@ export type paths = {
120
123
  readonly "/v1/makers/{maker_id}/exposure": Pick<SharedPaths["/v1/makers/{maker_id}/exposure"], "parameters" | "get">;
121
124
  readonly "/v1/makers/{maker_id}/performance": Pick<SharedPaths["/v1/makers/{maker_id}/performance"], "parameters" | "get">;
122
125
  };
123
- export type operations = Pick<SharedOperations, "abandonCoreExit" | "acceptQuote" | "activeCoreExits" | "admitOwnMaker" | "admitPartnerWallet" | "approveWallet" | "bindEmbeddedWallet" | "cancelRfq" | "confirmComboCopyAgent" | "confirmCoreCopyAgent" | "createCashout" | "createComment" | "createCoreExit" | "createDeposit" | "createGoldenRfq" | "createRfq" | "createRunOffClaim" | "createWalletChallenge" | "createWalletSession" | "createWithdrawal" | "deleteComment" | "editComment" | "endWalletSession" | "followTrader" | "getAcceptance" | "getAccountActivity" | "getAccountPnl" | "getAccountPosition" | "getBalances" | "getCopyAgents" | "getCopyBudget" | "getCopySettings" | "getCopySummary" | "getCoreExit" | "getDeployment" | "getGolden" | "getGoldenMarkets" | "getGoldenOffer" | "getGoldenSuggestions" | "getHypercoreBalance" | "getHypercorePortfolio" | "getHypercoreSettlementCredits" | "getIdentity" | "getMakerActivity" | "getMakerCapital" | "getMakerExposure" | "getMakerPerformance" | "getMakerPosition" | "getMakerQuotes" | "getMakerTelemetry" | "getMakerVaultFundingTransaction" | "getMakerWithdrawal" | "getMarket" | "getMarketDataConfig" | "getMarketDefinitions" | "getMarketHistory" | "getMarketRecurringRound" | "getMarketReferenceCloses" | "getMarketScoreTimeline" | "getMarketStats" | "getMyGenesis" | "getMyReferralBonus" | "getOperation" | "getOwnMaker" | "getPartnerReport" | "getPerpMarks" | "getProfitLeaderboard" | "getQuestion" | "getQuestionRecurringRound" | "getQuestionScoreTimeline" | "getRfq" | "getSeries" | "getSuggestedCombo" | "getTaxonomy" | "getTrader" | "getTraderPnl" | "getUsernameAvailability" | "getVaultAgents" | "getVolumeLeaderboard" | "getWalletApproval" | "getWithdrawal" | "grantComboCopyAgent" | "grantVaultAgent" | "likeComment" | "listAccountActivity" | "listAccountPositions" | "listComboCopies" | "listComboFeed" | "listCommentReplies" | "listComments" | "listControlledMakers" | "listCopiedFills" | "listCopyTrades" | "listDiscovery" | "listFollows" | "listMakerActivity" | "listMakerPositions" | "listMakerQuoteHistory" | "listMarkets" | "listMyNotifications" | "listOperations" | "listPartnerFills" | "listQuotes" | "listTraderPositions" | "listTraderTrades" | "markMyNotificationsRead" | "placeGolden" | "reactComment" | "recordAcquisition" | "recordGoldenTelegramClick" | "refreshPicture" | "requestComboCopyAgent" | "requestCoreCopyAgent" | "revokeComboCopyAgent" | "searchCatalog" | "setAvatar" | "setCopyAllocation" | "setCopySettings" | "setPublicProfile" | "setUsername" | "setXHandleShown" | "signGoldenGift" | "stream" | "streamMarkets" | "switchOffComboCopyAgent" | "switchOffCoreCopyAgent" | "unfollowTrader" | "unlikeComment" | "unlockGolden" | "unreactComment">;
126
+ export type operations = Pick<SharedOperations, "abandonCoreExit" | "acceptQuote" | "activeCoreExits" | "admitOwnMaker" | "admitPartnerWallet" | "approveWallet" | "bindEmbeddedWallet" | "cancelRfq" | "confirmComboCopyAgent" | "confirmCoreCopyAgent" | "createCashout" | "createComment" | "createCoreExit" | "createDeposit" | "createGoldenRfq" | "createRfq" | "createRunOffClaim" | "createWalletChallenge" | "createWalletSession" | "createWithdrawal" | "deleteComment" | "editComment" | "endWalletSession" | "followTrader" | "getAcceptance" | "getAccountActivity" | "getAccountPnl" | "getAccountPosition" | "getAccountValue" | "getBalances" | "getCopyAgents" | "getCopyBudget" | "getCopySettings" | "getCopySummary" | "getCoreExit" | "getDeployment" | "getGolden" | "getGoldenMarkets" | "getGoldenOffer" | "getGoldenSuggestions" | "getHypercoreBalance" | "getHypercorePortfolio" | "getHypercoreSettlementCredits" | "getIdentity" | "getMakerActivity" | "getMakerCapital" | "getMakerExposure" | "getMakerPerformance" | "getMakerPosition" | "getMakerQuotes" | "getMakerTelemetry" | "getMakerVaultFundingTransaction" | "getMakerWithdrawal" | "getMarket" | "getMarketDataConfig" | "getMarketDefinitions" | "getMarketHistory" | "getMarketRecurringRound" | "getMarketReferenceCloses" | "getMarketScoreTimeline" | "getMarketStats" | "getMyGenesis" | "getMyReferralBonus" | "getOperation" | "getOwnMaker" | "getPartnerAccountValue" | "getPartnerReport" | "getPerpMarks" | "getProfitLeaderboard" | "getQuestion" | "getQuestionRecurringRound" | "getQuestionScoreTimeline" | "getRfq" | "getSeries" | "getSuggestedCombo" | "getTaxonomy" | "getTrader" | "getTraderPnl" | "getUsernameAvailability" | "getVaultAgents" | "getVolumeLeaderboard" | "getWalletApproval" | "getWithdrawal" | "grantComboCopyAgent" | "grantVaultAgent" | "likeComment" | "listAccountActivity" | "listAccountPositions" | "listComboCopies" | "listComboFeed" | "listCommentReplies" | "listComments" | "listControlledMakers" | "listCopiedFills" | "listCopyTrades" | "listDiscovery" | "listFollows" | "listMakerActivity" | "listMakerPositions" | "listMakerQuoteHistory" | "listMarkets" | "listMyNotifications" | "listOperations" | "listPartnerFills" | "listPartnerWebhookEvents" | "listQuotes" | "listTraderPositions" | "listTraderTrades" | "markMyNotificationsRead" | "placeGolden" | "reactComment" | "recordAcquisition" | "recordGoldenTelegramClick" | "refreshPicture" | "requestComboCopyAgent" | "requestCoreCopyAgent" | "revokeComboCopyAgent" | "searchCatalog" | "setAvatar" | "setCopyAllocation" | "setCopySettings" | "setPublicProfile" | "setUsername" | "setXHandleShown" | "signGoldenGift" | "stream" | "streamMarkets" | "switchOffComboCopyAgent" | "switchOffCoreCopyAgent" | "unfollowTrader" | "unlikeComment" | "unlockGolden" | "unreactComment">;
@@ -437,6 +437,7 @@ export declare const operationErrors: {
437
437
  readonly getAccountActivity: readonly ["UNAUTHENTICATED", "FORBIDDEN", "AUTHORIZATION_UNAVAILABLE", "DEPENDENCY_STALE", "RATE_LIMITED", "INVALID_QUERY", "ORIGIN_REQUIRED", "NOT_FOUND", "SOURCE_UNAVAILABLE", "CONTRACT_UNAVAILABLE", "IDENTITY_NOT_FOUND"];
438
438
  readonly getAccountPnl: readonly ["UNAUTHENTICATED", "FORBIDDEN", "AUTHORIZATION_UNAVAILABLE", "RATE_LIMITED", "INVALID_QUERY", "ORIGIN_REQUIRED", "SOURCE_UNAVAILABLE", "CONTRACT_UNAVAILABLE", "IDENTITY_NOT_FOUND"];
439
439
  readonly getAccountPosition: readonly ["UNAUTHENTICATED", "FORBIDDEN", "AUTHORIZATION_UNAVAILABLE", "DEPENDENCY_STALE", "RATE_LIMITED", "INVALID_QUERY", "ORIGIN_REQUIRED", "NOT_FOUND", "SOURCE_UNAVAILABLE", "CONTRACT_UNAVAILABLE", "IDENTITY_NOT_FOUND"];
440
+ readonly getAccountValue: readonly ["UNAUTHENTICATED", "FORBIDDEN", "AUTHORIZATION_UNAVAILABLE", "DEPENDENCY_STALE", "RATE_LIMITED", "IDENTITY_NOT_FOUND", "SOURCE_UNAVAILABLE"];
440
441
  readonly getBalances: readonly ["UNAUTHENTICATED", "FORBIDDEN", "AUTHORIZATION_UNAVAILABLE", "DEPENDENCY_STALE", "RATE_LIMITED", "IDENTITY_NOT_FOUND"];
441
442
  readonly getCollateralReduction: readonly ["UNAUTHENTICATED", "FORBIDDEN", "AUTHORIZATION_UNAVAILABLE", "DEPENDENCY_STALE", "RATE_LIMITED", "INVALID_REQUEST", "NOT_FOUND", "IDENTITY_NOT_FOUND"];
442
443
  readonly getCopyAgents: readonly ["UNAUTHENTICATED", "FORBIDDEN", "AUTHORIZATION_UNAVAILABLE", "RATE_LIMITED", "ORIGIN_REQUIRED", "IDENTITY_NOT_FOUND", "CONTRACT_UNAVAILABLE", "INVALID_QUERY"];
@@ -476,6 +477,7 @@ export declare const operationErrors: {
476
477
  readonly getMyReferralBonus: readonly ["UNAUTHENTICATED", "FORBIDDEN", "AUTHORIZATION_UNAVAILABLE", "RATE_LIMITED", "ORIGIN_REQUIRED", "IDENTITY_NOT_FOUND", "INVALID_QUERY", "CONTRACT_UNAVAILABLE"];
477
478
  readonly getOperation: readonly ["UNAUTHENTICATED", "FORBIDDEN", "AUTHORIZATION_UNAVAILABLE", "DEPENDENCY_STALE", "RATE_LIMITED", "INVALID_REQUEST", "NOT_FOUND", "IDENTITY_NOT_FOUND"];
478
479
  readonly getOwnMaker: readonly ["UNAUTHENTICATED", "FORBIDDEN", "AUTHORIZATION_UNAVAILABLE", "DEPENDENCY_STALE", "RATE_LIMITED", "ORIGIN_REQUIRED", "NOT_FOUND", "IDENTITY_NOT_FOUND"];
480
+ readonly getPartnerAccountValue: readonly ["INVALID_REQUEST", "UNAUTHENTICATED", "FORBIDDEN", "NOT_FOUND", "RATE_LIMITED", "AUTHORIZATION_UNAVAILABLE", "DEPENDENCY_STALE", "FINANCIAL_ACTIONS_DISABLED", "SOURCE_UNAVAILABLE"];
479
481
  readonly getPartnerReport: readonly ["INVALID_QUERY", "UNAUTHENTICATED", "FORBIDDEN", "RATE_LIMITED", "AUTHORIZATION_UNAVAILABLE", "SOURCE_UNAVAILABLE"];
480
482
  readonly getPerpMarks: readonly ["NOT_FOUND", "MARKET_DATA_UNAVAILABLE", "INVALID_QUERY"];
481
483
  readonly getPersonalApiKeyCapabilities: readonly ["UNAUTHENTICATED", "FORBIDDEN", "AUTHORIZATION_UNAVAILABLE", "DEPENDENCY_STALE", "RATE_LIMITED", "INVALID_REQUEST", "NOT_FOUND"];
@@ -518,6 +520,7 @@ export declare const operationErrors: {
518
520
  readonly listOperations: readonly ["UNAUTHENTICATED", "FORBIDDEN", "AUTHORIZATION_UNAVAILABLE", "DEPENDENCY_STALE", "RATE_LIMITED", "INVALID_QUERY", "INVALID_CURSOR", "IDENTITY_NOT_FOUND"];
519
521
  readonly listOperatorApiKeys: readonly ["UNAUTHENTICATED", "FORBIDDEN", "AUTHORIZATION_UNAVAILABLE", "DEPENDENCY_STALE", "RATE_LIMITED", "INVALID_REQUEST", "NOT_FOUND"];
520
522
  readonly listPartnerFills: readonly ["INVALID_QUERY", "INVALID_CURSOR", "UNAUTHENTICATED", "FORBIDDEN", "RATE_LIMITED", "AUTHORIZATION_UNAVAILABLE", "SOURCE_UNAVAILABLE"];
523
+ readonly listPartnerWebhookEvents: readonly ["INVALID_QUERY", "INVALID_CURSOR", "UNAUTHENTICATED", "FORBIDDEN", "RATE_LIMITED", "AUTHORIZATION_UNAVAILABLE", "SOURCE_UNAVAILABLE"];
521
524
  readonly listPersonalApiKeys: readonly ["UNAUTHENTICATED", "FORBIDDEN", "AUTHORIZATION_UNAVAILABLE", "DEPENDENCY_STALE", "RATE_LIMITED", "INVALID_REQUEST", "NOT_FOUND"];
522
525
  readonly listQuotes: readonly ["UNAUTHENTICATED", "FORBIDDEN", "AUTHORIZATION_UNAVAILABLE", "DEPENDENCY_STALE", "RATE_LIMITED", "INVALID_REQUEST", "NOT_FOUND", "IDENTITY_NOT_FOUND"];
523
526
  readonly listRfqs: readonly ["UNAUTHENTICATED", "FORBIDDEN", "AUTHORIZATION_UNAVAILABLE", "DEPENDENCY_STALE", "RATE_LIMITED", "INVALID_QUERY", "INVALID_CURSOR"];
@@ -917,6 +917,15 @@ export const operationErrors = {
917
917
  "CONTRACT_UNAVAILABLE",
918
918
  "IDENTITY_NOT_FOUND"
919
919
  ],
920
+ "getAccountValue": [
921
+ "UNAUTHENTICATED",
922
+ "FORBIDDEN",
923
+ "AUTHORIZATION_UNAVAILABLE",
924
+ "DEPENDENCY_STALE",
925
+ "RATE_LIMITED",
926
+ "IDENTITY_NOT_FOUND",
927
+ "SOURCE_UNAVAILABLE"
928
+ ],
920
929
  "getBalances": [
921
930
  "UNAUTHENTICATED",
922
931
  "FORBIDDEN",
@@ -1302,6 +1311,17 @@ export const operationErrors = {
1302
1311
  "NOT_FOUND",
1303
1312
  "IDENTITY_NOT_FOUND"
1304
1313
  ],
1314
+ "getPartnerAccountValue": [
1315
+ "INVALID_REQUEST",
1316
+ "UNAUTHENTICATED",
1317
+ "FORBIDDEN",
1318
+ "NOT_FOUND",
1319
+ "RATE_LIMITED",
1320
+ "AUTHORIZATION_UNAVAILABLE",
1321
+ "DEPENDENCY_STALE",
1322
+ "FINANCIAL_ACTIONS_DISABLED",
1323
+ "SOURCE_UNAVAILABLE"
1324
+ ],
1305
1325
  "getPartnerReport": [
1306
1326
  "INVALID_QUERY",
1307
1327
  "UNAUTHENTICATED",
@@ -1710,6 +1730,15 @@ export const operationErrors = {
1710
1730
  "AUTHORIZATION_UNAVAILABLE",
1711
1731
  "SOURCE_UNAVAILABLE"
1712
1732
  ],
1733
+ "listPartnerWebhookEvents": [
1734
+ "INVALID_QUERY",
1735
+ "INVALID_CURSOR",
1736
+ "UNAUTHENTICATED",
1737
+ "FORBIDDEN",
1738
+ "RATE_LIMITED",
1739
+ "AUTHORIZATION_UNAVAILABLE",
1740
+ "SOURCE_UNAVAILABLE"
1741
+ ],
1713
1742
  "listPersonalApiKeys": [
1714
1743
  "UNAUTHENTICATED",
1715
1744
  "FORBIDDEN",
@@ -555,6 +555,46 @@ export type paths = {
555
555
  readonly patch?: never;
556
556
  readonly trace?: never;
557
557
  };
558
+ readonly "/v1/partner/webhook-events": {
559
+ readonly parameters: {
560
+ readonly query?: never;
561
+ readonly header?: never;
562
+ readonly path?: never;
563
+ readonly cookie?: never;
564
+ };
565
+ /**
566
+ * List your webhook events
567
+ * @description Every webhook event Totalis queued for you in the last 30 days, delivered or not, in the order it queued them, each with the body it posts and how its delivery stands, so you can recover events your endpoint missed.
568
+ */
569
+ readonly get: operations["listPartnerWebhookEvents"];
570
+ readonly put?: never;
571
+ readonly post?: never;
572
+ readonly delete?: never;
573
+ readonly options?: never;
574
+ readonly head?: never;
575
+ readonly patch?: never;
576
+ readonly trace?: never;
577
+ };
578
+ readonly "/v1/partner/accounts/{wallet}/account-value": {
579
+ readonly parameters: {
580
+ readonly query?: never;
581
+ readonly header?: never;
582
+ readonly path?: never;
583
+ readonly cookie?: never;
584
+ };
585
+ /**
586
+ * Get a user's account value
587
+ * @description The value of an account your admission of this wallet opened, the body Get account value returns to the user, read with your server key so you can keep a user's history after their own key lapses.
588
+ */
589
+ readonly get: operations["getPartnerAccountValue"];
590
+ readonly put?: never;
591
+ readonly post?: never;
592
+ readonly delete?: never;
593
+ readonly options?: never;
594
+ readonly head?: never;
595
+ readonly patch?: never;
596
+ readonly trace?: never;
597
+ };
558
598
  readonly "/v1/me/acquisition": {
559
599
  readonly parameters: {
560
600
  readonly query?: never;
@@ -2332,6 +2372,26 @@ export type paths = {
2332
2372
  readonly patch?: never;
2333
2373
  readonly trace?: never;
2334
2374
  };
2375
+ readonly "/v1/me/account-value": {
2376
+ readonly parameters: {
2377
+ readonly query?: never;
2378
+ readonly header?: never;
2379
+ readonly path?: never;
2380
+ readonly cookie?: never;
2381
+ };
2382
+ /**
2383
+ * Get account value
2384
+ * @description Everything your account holds at Totalis, all read at one HyperEVM block: wallet USDC, your cash in the vault and in vaults running off, what you paid for your open positions, and the profit you can still claim, net of the fee.
2385
+ */
2386
+ readonly get: operations["getAccountValue"];
2387
+ readonly put?: never;
2388
+ readonly post?: never;
2389
+ readonly delete?: never;
2390
+ readonly options?: never;
2391
+ readonly head?: never;
2392
+ readonly patch?: never;
2393
+ readonly trace?: never;
2394
+ };
2335
2395
  readonly "/v1/me/operations": {
2336
2396
  readonly parameters: {
2337
2397
  readonly query?: never;
@@ -4524,6 +4584,78 @@ export type components = {
4524
4584
  /** @description Whether more fills follow in the range. */
4525
4585
  readonly has_more: boolean;
4526
4586
  };
4587
+ readonly PartnerWebhookEvent: {
4588
+ /** @description The event body exactly as Totalis posts it to the webhook. */
4589
+ readonly event: {
4590
+ /** @description The event's id, as the webhook-id header carried it; dedupe on it. */
4591
+ readonly id: string;
4592
+ /** @description The event type, such as position.opened or balance.updated. */
4593
+ readonly type: string;
4594
+ /** @description When the event happened. */
4595
+ readonly created_at: string;
4596
+ /** @description The event's data, as posted. */
4597
+ readonly data: unknown;
4598
+ };
4599
+ /**
4600
+ * @description PENDING while Totalis still sends it, DELIVERED once the webhook answered 2xx, FAILED after the last attempt failed.
4601
+ * @enum {string}
4602
+ */
4603
+ readonly status: "PENDING" | "DELIVERED" | "FAILED";
4604
+ /** @description How many times Totalis has sent it. */
4605
+ readonly attempts: number;
4606
+ /** @description When Totalis queued it. */
4607
+ readonly queued_at: components["schemas"]["$defs-Timestamp"];
4608
+ /**
4609
+ * Format: date-time
4610
+ * @description When the webhook accepted it, or null.
4611
+ */
4612
+ readonly delivered_at: string | null;
4613
+ };
4614
+ readonly PartnerWebhookEventPage: {
4615
+ /** @description Events in the order Totalis queued them, oldest first. */
4616
+ readonly events: readonly components["schemas"]["PartnerWebhookEvent"][];
4617
+ /** @description Send it as cursor for the events after this page. It follows the last event even when has_more is false, so keep it and read again later for new events. Null only when no event has been returned yet. */
4618
+ readonly next_cursor: components["schemas"]["NextCursor"];
4619
+ /** @description Whether more events follow. */
4620
+ readonly has_more: boolean;
4621
+ };
4622
+ readonly Checkpoint: {
4623
+ /** @description Last HyperEVM block the vault projection has indexed; the read reflects chain state up to and including this block. */
4624
+ readonly block_number: components["schemas"]["UInt64String"];
4625
+ /**
4626
+ * @description CURRENT when the projection is within 32 blocks of a chain head observed in the last two minutes; STALE when it lags, so figures may be behind.
4627
+ * @enum {unknown}
4628
+ */
4629
+ readonly projection_state: "CURRENT" | "STALE";
4630
+ };
4631
+ /** @description What the account holds at Totalis at one HyperEVM block, in atomic USDC (6 decimals, "1000000" = 1 USDC): wallet USDC, its cash in the vault and in vaults running off, what it paid for its open positions, and the profit it can still claim, net of the fee. Every amount is read from the chain at block_number. HyperCore balances are not included; read them from Hyperliquid. */
4632
+ readonly AccountValue: {
4633
+ /** @description The account's wallet, lowercase. */
4634
+ readonly account: components["schemas"]["LowercaseNonZeroAddress"];
4635
+ /**
4636
+ * @description CURRENT when every amount was read at block_number; UNKNOWN when the chain could not be read, or the projection did not reach that block in time, and every amount is null. Read again later.
4637
+ * @enum {unknown}
4638
+ */
4639
+ readonly state: "CURRENT" | "UNKNOWN";
4640
+ /** @description The account's value: wallet_usdc + vault_cash + run_off_cash + open_cost + claimable_profit. Null unless state is CURRENT. */
4641
+ readonly amount: components["schemas"]["$defs-Amount"] | null;
4642
+ /** @description The HyperEVM block every amount was read at. Null unless state is CURRENT. */
4643
+ readonly block_number: components["schemas"]["UInt64String"] | null;
4644
+ /** @description USDC in the account's wallet on HyperEVM, including any already committed to a Totalis withdrawal or stake that has not landed. Null unless state is CURRENT. */
4645
+ readonly wallet_usdc: components["schemas"]["$defs-Amount"] | null;
4646
+ /** @description All the account's cash in the vault, including any held for an operation that has not landed, so it can exceed GET /v1/me/balances' free vault cash. Null unless state is CURRENT. */
4647
+ readonly vault_cash: components["schemas"]["$defs-Amount"] | null;
4648
+ /** @description The account's cash in vaults running off, all together; GET /v1/me/balances lists it per vault. Null unless state is CURRENT. */
4649
+ readonly run_off_cash: components["schemas"]["$defs-Amount"] | null;
4650
+ /** @description How many positions the account holds that have not settled: OPEN and AWAITING_SETTLEMENT in GET /v1/me/positions. Null unless state is CURRENT. */
4651
+ readonly open_positions: number | null;
4652
+ /** @description What the account paid for those positions: the sum of their acquisition_cost. Null unless state is CURRENT. */
4653
+ readonly open_cost: components["schemas"]["$defs-Amount"] | null;
4654
+ /** @description What claiming every SETTLED_UNCLAIMED position would pay the account: each one's unclaimed_profit minus floor(unclaimed_profit * fee_bps / 10000). Null unless state is CURRENT. */
4655
+ readonly claimable_profit: components["schemas"]["$defs-Amount"] | null;
4656
+ /** @description The vault projection the read used to find the account's positions. When state is CURRENT it has reached block_number. */
4657
+ readonly checkpoint: components["schemas"]["Checkpoint"];
4658
+ };
4527
4659
  /** @description One tagged landing on the app. Values come from utm_source, utm_medium, utm_campaign and ref; the path carries no query string. */
4528
4660
  readonly AcquisitionTouch: {
4529
4661
  readonly source?: string;
@@ -5819,15 +5951,6 @@ export type components = {
5819
5951
  */
5820
5952
  readonly state: "CURRENT" | "UNKNOWN" | "STALE";
5821
5953
  };
5822
- readonly Checkpoint: {
5823
- /** @description Last HyperEVM block the vault projection has indexed; the read reflects chain state up to and including this block. */
5824
- readonly block_number: components["schemas"]["UInt64String"];
5825
- /**
5826
- * @description CURRENT when the projection is within 32 blocks of a chain head observed in the last two minutes; STALE when it lags, so figures may be behind.
5827
- * @enum {unknown}
5828
- */
5829
- readonly projection_state: "CURRENT" | "STALE";
5830
- };
5831
5954
  /**
5832
5955
  * @description Why an operation ended EXPIRED_UNEXECUTED; nothing it would have done happened. INSUFFICIENT_CASH: an ACCEPT whose taker's money (free vault Cash, or the wallet USDC its funding draws) did not cover the stake when it was to execute, for a funded accept by two seconds after its `fund_by`; the RFQ fails with the same `terminal_reason`. DEADLINE_BEFORE_CLAIM: the venue reached it too late, with too little of its signed deadline left to sign and send it. AUTHORIZATION_TOO_CLOSE: when the venue took it, the chain's clock left too little of its signed deadline to send it. SIGNER_QUOTE_LIFE: its signed deadline could not cover the wait for its place in the sender's queue. SIMULATION_REVERTED: simulated before sending, the vault would have rejected it, for a reason other than INSUFFICIENT_CASH. QUARANTINE_EXPIRED: it was held for review after the signer refused it or its retries ran out, and its signed deadline passed meanwhile. ATTESTATION_EXPIRED: a maker's self-funded attestation expired before its signed transaction arrived. For an ACCEPT every reason but INSUFFICIENT_CASH fails the RFQ as EXPIRED_UNEXECUTED.
5833
5956
  * @enum {string}
@@ -7996,6 +8119,88 @@ export interface operations {
7996
8119
  readonly 503: components["responses"]["Unavailable"];
7997
8120
  };
7998
8121
  };
8122
+ readonly listPartnerWebhookEvents: {
8123
+ readonly parameters: {
8124
+ readonly query?: {
8125
+ /**
8126
+ * @description List only events queued at or after this RFC 3339 time.
8127
+ * @example 2026-11-13T00:00:00Z
8128
+ */
8129
+ readonly since?: string;
8130
+ /**
8131
+ * @description Omit for the oldest events kept; then send a previous response's next_cursor unchanged.
8132
+ * @example v1:812:balance_01933a5e-6f1c-7c3a-9b1e-2f4d5c6b7a81
8133
+ */
8134
+ readonly cursor?: components["schemas"]["PageCursor"];
8135
+ /**
8136
+ * @description Maximum items per page, 1 to 200, default 50. A page may hold fewer, even none, while has_more is true.
8137
+ * @example 50
8138
+ */
8139
+ readonly limit?: components["parameters"]["Limit"];
8140
+ };
8141
+ readonly header?: never;
8142
+ readonly path?: never;
8143
+ readonly cookie?: never;
8144
+ };
8145
+ readonly requestBody?: never;
8146
+ readonly responses: {
8147
+ /** @description A page of your webhook events. No caching. */
8148
+ readonly 200: {
8149
+ headers: {
8150
+ readonly [name: string]: unknown;
8151
+ };
8152
+ content: {
8153
+ readonly "application/json": components["schemas"]["PartnerWebhookEventPage"];
8154
+ };
8155
+ };
8156
+ /** @description `INVALID_QUERY`: since is not an RFC 3339 time, or limit is not 1 to 200. `INVALID_CURSOR`: the cursor is not one this endpoint returned. */
8157
+ readonly 400: components["responses"]["Error"];
8158
+ /** @description The partner server key is missing, unknown or revoked, or your partner is suspended. */
8159
+ readonly 401: components["responses"]["Error"];
8160
+ /** @description Any credential but a partner server key, or any request with an `Origin`, is refused: read webhook events from your server. */
8161
+ readonly 403: components["responses"]["Error"];
8162
+ readonly 429: components["responses"]["RateLimited"];
8163
+ /** @description Webhook events are temporarily unavailable; resend after `Retry-After`. */
8164
+ readonly 503: components["responses"]["Unavailable"];
8165
+ };
8166
+ };
8167
+ readonly getPartnerAccountValue: {
8168
+ readonly parameters: {
8169
+ readonly query?: never;
8170
+ readonly header?: never;
8171
+ readonly path: {
8172
+ /**
8173
+ * @description The wallet you admitted, still signing for the account it opened.
8174
+ * @example 0x8ba1f109551bD432803012645Ac136ddd64DBA72
8175
+ */
8176
+ readonly wallet: components["schemas"]["Address"];
8177
+ };
8178
+ readonly cookie?: never;
8179
+ };
8180
+ readonly requestBody?: never;
8181
+ readonly responses: {
8182
+ /** @description The account's value and its parts. When state is UNKNOWN every amount is null; read again later. No caching. */
8183
+ readonly 200: {
8184
+ headers: {
8185
+ readonly [name: string]: unknown;
8186
+ };
8187
+ content: {
8188
+ readonly "application/json": components["schemas"]["AccountValue"];
8189
+ };
8190
+ };
8191
+ /** @description `INVALID_REQUEST`: wallet is not a 0x-prefixed 20-byte hex address. */
8192
+ readonly 400: components["responses"]["Error"];
8193
+ /** @description The partner server key is missing, unknown or revoked, or your partner is suspended. */
8194
+ readonly 401: components["responses"]["Error"];
8195
+ /** @description Any credential but a partner server key, or any request with an `Origin`, is refused: read account values from your server. */
8196
+ readonly 403: components["responses"]["Error"];
8197
+ /** @description `NOT_FOUND`: you did not admit this wallet, it has no account yet, or it no longer signs for the account it opened. A wallet another partner admitted, or no partner, answers the same. */
8198
+ readonly 404: components["responses"]["Error"];
8199
+ readonly 429: components["responses"]["RateLimited"];
8200
+ /** @description The value is temporarily unavailable; resend after `Retry-After`. */
8201
+ readonly 503: components["responses"]["Unavailable"];
8202
+ };
8203
+ };
7999
8204
  readonly recordAcquisition: {
8000
8205
  readonly parameters: {
8001
8206
  readonly query?: never;
@@ -11653,6 +11858,31 @@ export interface operations {
11653
11858
  readonly 503: components["responses"]["Unavailable"];
11654
11859
  };
11655
11860
  };
11861
+ readonly getAccountValue: {
11862
+ readonly parameters: {
11863
+ readonly query?: never;
11864
+ readonly header?: never;
11865
+ readonly path?: never;
11866
+ readonly cookie?: never;
11867
+ };
11868
+ readonly requestBody?: never;
11869
+ readonly responses: {
11870
+ /** @description Your account's value and its parts. When state is UNKNOWN every amount is null; read again later. No caching. */
11871
+ readonly 200: {
11872
+ headers: {
11873
+ readonly [name: string]: unknown;
11874
+ };
11875
+ content: {
11876
+ readonly "application/json": components["schemas"]["AccountValue"];
11877
+ };
11878
+ };
11879
+ readonly 401: components["responses"]["Error"];
11880
+ readonly 403: components["responses"]["Error"];
11881
+ readonly 404: components["responses"]["Error"];
11882
+ readonly 429: components["responses"]["RateLimited"];
11883
+ readonly 503: components["responses"]["Unavailable"];
11884
+ };
11885
+ };
11656
11886
  readonly listOperations: {
11657
11887
  readonly parameters: {
11658
11888
  readonly query?: {
@@ -1,14 +1,14 @@
1
- export declare const sdkVersion = "229.0.0-free-combo-positions";
2
- export declare const openapiSha256 = "13e7c698136fc0afbd569d644a7935ac9900d09b4d68eddf7ba7caab11fc4687";
1
+ export declare const sdkVersion = "232.0.0-partner-account-value";
2
+ export declare const openapiSha256 = "25a67887e4f47ba0b0c9f35c3a6c6f4b598f89fc865e857b03ec2df67a825880";
3
3
  export declare const realtimeSha256 = "32e56c8bb642401f5b03e9c38274087c09bebb73ffe60c0d34432c2e78ce1e15";
4
4
  export declare const jsonSchemaSha256: {
5
- readonly "account.schema.json": "c11a94438d5f7b54e08d3b559098ce2671f4c9aad3a79feb684b7a81f77d809a";
5
+ readonly "account.schema.json": "e6cd5a75429d074f23bd7f6ffd370fa59d0e3f7dbd6aef6433e5ba0d21b5baeb";
6
6
  readonly "comments.schema.json": "b3e35b9b1bd90b763658fcd25910ec123d44713cdf608b4e52667c91b78f0aa5";
7
7
  readonly "common.schema.json": "04f51deb3cbea448e59195e26ede3212598d58a7940fe67eb2123fd9161c5edb";
8
8
  readonly "core-exit.schema.json": "c7f617e815225cdcac95c236f8b73fbe288ee5713ff444c3be90eb915fc3a401";
9
9
  readonly "error.schema.json": "f98be7f7a0fa7d46479743fb040684627658abc3a04b0dccdf3f089a22454715";
10
10
  readonly "hypercore.schema.json": "5b89b2bbff7ec8cc1b8717375d12ce9cd5ab6aa5af03c4fdc6cc753ef9583a2c";
11
- readonly "identity.schema.json": "02e333b88c82d89abd6f1c9b739935db1701c67aa53b4fcc487f1d78d8c99dcc";
11
+ readonly "identity.schema.json": "a97ec2f4319a16619d3a3ab613989fb1dba8107713e0fb8f1f9ad5aea25a67e3";
12
12
  readonly "maker-access.schema.json": "49698ee0235e42064aae0397db1e0f646bdc10d9dfa10121714ba06dd69fee3b";
13
13
  readonly "maker-action.schema.json": "dc41e52c868848e85cdeb918992cb710d34616d2803a63f6d9a658e016744a50";
14
14
  readonly "maker-telemetry.schema.json": "85b111ce0f4935299d1116071b43de12e775bef4e0c283c12f19046d34374a9c";
@@ -18,7 +18,7 @@ export declare const jsonSchemaSha256: {
18
18
  readonly "realtime.schema.json": "32e56c8bb642401f5b03e9c38274087c09bebb73ffe60c0d34432c2e78ce1e15";
19
19
  };
20
20
  export declare const operations: {
21
- readonly client: readonly ["abandonCoreExit", "acceptQuote", "activeCoreExits", "admitOwnMaker", "admitPartnerWallet", "approveWallet", "bindEmbeddedWallet", "cancelRfq", "confirmComboCopyAgent", "confirmCoreCopyAgent", "createCashout", "createComment", "createCoreExit", "createDeposit", "createGoldenRfq", "createRfq", "createRunOffClaim", "createWalletChallenge", "createWalletSession", "createWithdrawal", "deleteComment", "editComment", "endWalletSession", "followTrader", "getAcceptance", "getAccountActivity", "getAccountPnl", "getAccountPosition", "getBalances", "getCopyAgents", "getCopyBudget", "getCopySettings", "getCopySummary", "getCoreExit", "getDeployment", "getGolden", "getGoldenMarkets", "getGoldenOffer", "getGoldenSuggestions", "getHypercoreBalance", "getHypercorePortfolio", "getHypercoreSettlementCredits", "getIdentity", "getMakerActivity", "getMakerCapital", "getMakerExposure", "getMakerPerformance", "getMakerPosition", "getMakerQuotes", "getMakerTelemetry", "getMakerVaultFundingTransaction", "getMakerWithdrawal", "getMarket", "getMarketDataConfig", "getMarketDefinitions", "getMarketHistory", "getMarketRecurringRound", "getMarketReferenceCloses", "getMarketScoreTimeline", "getMarketStats", "getMyGenesis", "getMyReferralBonus", "getOperation", "getOwnMaker", "getPartnerReport", "getPerpMarks", "getProfitLeaderboard", "getQuestion", "getQuestionRecurringRound", "getQuestionScoreTimeline", "getRfq", "getSeries", "getSuggestedCombo", "getTaxonomy", "getTrader", "getTraderPnl", "getUsernameAvailability", "getVaultAgents", "getVolumeLeaderboard", "getWalletApproval", "getWithdrawal", "grantComboCopyAgent", "grantVaultAgent", "likeComment", "listAccountActivity", "listAccountPositions", "listComboCopies", "listComboFeed", "listCommentReplies", "listComments", "listControlledMakers", "listCopiedFills", "listCopyTrades", "listDiscovery", "listFollows", "listMakerActivity", "listMakerPositions", "listMakerQuoteHistory", "listMarkets", "listMyNotifications", "listOperations", "listPartnerFills", "listQuotes", "listTraderPositions", "listTraderTrades", "markMyNotificationsRead", "placeGolden", "reactComment", "recordAcquisition", "recordGoldenTelegramClick", "refreshPicture", "requestComboCopyAgent", "requestCoreCopyAgent", "revokeComboCopyAgent", "searchCatalog", "setAvatar", "setCopyAllocation", "setCopySettings", "setPublicProfile", "setUsername", "setXHandleShown", "signGoldenGift", "stream", "streamMarkets", "switchOffComboCopyAgent", "switchOffCoreCopyAgent", "unfollowTrader", "unlikeComment", "unlockGolden", "unreactComment"];
21
+ readonly client: readonly ["abandonCoreExit", "acceptQuote", "activeCoreExits", "admitOwnMaker", "admitPartnerWallet", "approveWallet", "bindEmbeddedWallet", "cancelRfq", "confirmComboCopyAgent", "confirmCoreCopyAgent", "createCashout", "createComment", "createCoreExit", "createDeposit", "createGoldenRfq", "createRfq", "createRunOffClaim", "createWalletChallenge", "createWalletSession", "createWithdrawal", "deleteComment", "editComment", "endWalletSession", "followTrader", "getAcceptance", "getAccountActivity", "getAccountPnl", "getAccountPosition", "getAccountValue", "getBalances", "getCopyAgents", "getCopyBudget", "getCopySettings", "getCopySummary", "getCoreExit", "getDeployment", "getGolden", "getGoldenMarkets", "getGoldenOffer", "getGoldenSuggestions", "getHypercoreBalance", "getHypercorePortfolio", "getHypercoreSettlementCredits", "getIdentity", "getMakerActivity", "getMakerCapital", "getMakerExposure", "getMakerPerformance", "getMakerPosition", "getMakerQuotes", "getMakerTelemetry", "getMakerVaultFundingTransaction", "getMakerWithdrawal", "getMarket", "getMarketDataConfig", "getMarketDefinitions", "getMarketHistory", "getMarketRecurringRound", "getMarketReferenceCloses", "getMarketScoreTimeline", "getMarketStats", "getMyGenesis", "getMyReferralBonus", "getOperation", "getOwnMaker", "getPartnerAccountValue", "getPartnerReport", "getPerpMarks", "getProfitLeaderboard", "getQuestion", "getQuestionRecurringRound", "getQuestionScoreTimeline", "getRfq", "getSeries", "getSuggestedCombo", "getTaxonomy", "getTrader", "getTraderPnl", "getUsernameAvailability", "getVaultAgents", "getVolumeLeaderboard", "getWalletApproval", "getWithdrawal", "grantComboCopyAgent", "grantVaultAgent", "likeComment", "listAccountActivity", "listAccountPositions", "listComboCopies", "listComboFeed", "listCommentReplies", "listComments", "listControlledMakers", "listCopiedFills", "listCopyTrades", "listDiscovery", "listFollows", "listMakerActivity", "listMakerPositions", "listMakerQuoteHistory", "listMarkets", "listMyNotifications", "listOperations", "listPartnerFills", "listPartnerWebhookEvents", "listQuotes", "listTraderPositions", "listTraderTrades", "markMyNotificationsRead", "placeGolden", "reactComment", "recordAcquisition", "recordGoldenTelegramClick", "refreshPicture", "requestComboCopyAgent", "requestCoreCopyAgent", "revokeComboCopyAgent", "searchCatalog", "setAvatar", "setCopyAllocation", "setCopySettings", "setPublicProfile", "setUsername", "setXHandleShown", "signGoldenGift", "stream", "streamMarkets", "switchOffComboCopyAgent", "switchOffCoreCopyAgent", "unfollowTrader", "unlikeComment", "unlockGolden", "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,15 +1,15 @@
1
1
  // Generated by scripts/generate.mjs; do not edit.
2
- export const sdkVersion = "229.0.0-free-combo-positions";
3
- export const openapiSha256 = "13e7c698136fc0afbd569d644a7935ac9900d09b4d68eddf7ba7caab11fc4687";
2
+ export const sdkVersion = "232.0.0-partner-account-value";
3
+ export const openapiSha256 = "25a67887e4f47ba0b0c9f35c3a6c6f4b598f89fc865e857b03ec2df67a825880";
4
4
  export const realtimeSha256 = "32e56c8bb642401f5b03e9c38274087c09bebb73ffe60c0d34432c2e78ce1e15";
5
5
  export const jsonSchemaSha256 = {
6
- "account.schema.json": "c11a94438d5f7b54e08d3b559098ce2671f4c9aad3a79feb684b7a81f77d809a",
6
+ "account.schema.json": "e6cd5a75429d074f23bd7f6ffd370fa59d0e3f7dbd6aef6433e5ba0d21b5baeb",
7
7
  "comments.schema.json": "b3e35b9b1bd90b763658fcd25910ec123d44713cdf608b4e52667c91b78f0aa5",
8
8
  "common.schema.json": "04f51deb3cbea448e59195e26ede3212598d58a7940fe67eb2123fd9161c5edb",
9
9
  "core-exit.schema.json": "c7f617e815225cdcac95c236f8b73fbe288ee5713ff444c3be90eb915fc3a401",
10
10
  "error.schema.json": "f98be7f7a0fa7d46479743fb040684627658abc3a04b0dccdf3f089a22454715",
11
11
  "hypercore.schema.json": "5b89b2bbff7ec8cc1b8717375d12ce9cd5ab6aa5af03c4fdc6cc753ef9583a2c",
12
- "identity.schema.json": "02e333b88c82d89abd6f1c9b739935db1701c67aa53b4fcc487f1d78d8c99dcc",
12
+ "identity.schema.json": "a97ec2f4319a16619d3a3ab613989fb1dba8107713e0fb8f1f9ad5aea25a67e3",
13
13
  "maker-access.schema.json": "49698ee0235e42064aae0397db1e0f646bdc10d9dfa10121714ba06dd69fee3b",
14
14
  "maker-action.schema.json": "dc41e52c868848e85cdeb918992cb710d34616d2803a63f6d9a658e016744a50",
15
15
  "maker-telemetry.schema.json": "85b111ce0f4935299d1116071b43de12e775bef4e0c283c12f19046d34374a9c",
@@ -48,6 +48,7 @@ export const operations = {
48
48
  "getAccountActivity",
49
49
  "getAccountPnl",
50
50
  "getAccountPosition",
51
+ "getAccountValue",
51
52
  "getBalances",
52
53
  "getCopyAgents",
53
54
  "getCopyBudget",
@@ -84,6 +85,7 @@ export const operations = {
84
85
  "getMyReferralBonus",
85
86
  "getOperation",
86
87
  "getOwnMaker",
88
+ "getPartnerAccountValue",
87
89
  "getPartnerReport",
88
90
  "getPerpMarks",
89
91
  "getProfitLeaderboard",
@@ -122,6 +124,7 @@ export const operations = {
122
124
  "listMyNotifications",
123
125
  "listOperations",
124
126
  "listPartnerFills",
127
+ "listPartnerWebhookEvents",
125
128
  "listQuotes",
126
129
  "listTraderPositions",
127
130
  "listTraderTrades",
package/dist/partner.d.ts CHANGED
@@ -6,6 +6,9 @@ export type WalletAdmission = components["schemas"]["WalletAdmission"];
6
6
  export type PartnerReport = components["schemas"]["PartnerReport"];
7
7
  /** A page of fee events on your users' positions (TT-2749). Amounts are atomic USDC strings. */
8
8
  export type PartnerFillPage = components["schemas"]["PartnerFillPage"];
9
+ export type PartnerWebhookEventPage = components["schemas"]["PartnerWebhookEventPage"];
10
+ /** What an account holds at Totalis at one HyperEVM block (TT-2787). Amounts are atomic USDC strings. */
11
+ export type PartnerAccountValue = components["schemas"]["AccountValue"];
9
12
  /** A wallet's signed consent to one partner opening its account (TT-1688). */
10
13
  export type AdmissionConsent = {
11
14
  readonly expires_at: string;
@@ -51,7 +54,9 @@ export type PartnerServerOptions = Omit<ApiClientOptions, "accessToken" | "partn
51
54
  * wallet's consent (`signAdmissionConsent` in your frontend), and its next
52
55
  * wallet sign-in creates the account, attributed to you. `report` reads your
53
56
  * fees, terms and payouts (TT-2420), and `fills` each fee event on your
54
- * users' positions (TT-2749). Refuses to run in a browser or a React Native
57
+ * users' positions (TT-2749), `webhookEvents` reads back the webhook
58
+ * events Totalis queued for you (TT-2794), and `accountValue` the value of an
59
+ * account you admitted (TT-2795). Refuses to run in a browser or a React Native
55
60
  * app, where the server key would be exposed.
56
61
  */
57
62
  export declare function createPartnerServer(options: PartnerServerOptions): {
@@ -83,5 +88,25 @@ export declare function createPartnerServer(options: PartnerServerOptions): {
83
88
  readonly cursor?: string;
84
89
  readonly limit?: number;
85
90
  }): Promise<PartnerFillPage>;
91
+ /**
92
+ * Your webhook events from the last 30 days, delivered or not, oldest
93
+ * first, each with the body as it was posted and how its delivery stands:
94
+ * recover what your endpoint missed. `since` (RFC 3339) narrows to events
95
+ * queued from then on. Pass `next_cursor` as `cursor` for the next page;
96
+ * it follows the last event even when `has_more` is false, so keep it to
97
+ * read new events later.
98
+ */
99
+ webhookEvents(query?: {
100
+ readonly since?: string;
101
+ readonly cursor?: string;
102
+ readonly limit?: number;
103
+ }): Promise<PartnerWebhookEventPage>;
104
+ /**
105
+ * The value of the account your admission of `wallet` opened, the body
106
+ * the user's own Get account value returns, read with your server key so
107
+ * you can keep it after the user's key lapses. A wallet you did not
108
+ * admit, or one no longer signing for that account, is a 404.
109
+ */
110
+ accountValue(wallet: string): Promise<PartnerAccountValue>;
86
111
  };
87
112
  export type PartnerServer = ReturnType<typeof createPartnerServer>;
package/dist/partner.js CHANGED
@@ -34,7 +34,9 @@ export async function signAdmissionConsent(request) {
34
34
  * wallet's consent (`signAdmissionConsent` in your frontend), and its next
35
35
  * wallet sign-in creates the account, attributed to you. `report` reads your
36
36
  * fees, terms and payouts (TT-2420), and `fills` each fee event on your
37
- * users' positions (TT-2749). Refuses to run in a browser or a React Native
37
+ * users' positions (TT-2749), `webhookEvents` reads back the webhook
38
+ * events Totalis queued for you (TT-2794), and `accountValue` the value of an
39
+ * account you admitted (TT-2795). Refuses to run in a browser or a React Native
38
40
  * app, where the server key would be exposed.
39
41
  */
40
42
  export function createPartnerServer(options) {
@@ -74,5 +76,25 @@ export function createPartnerServer(options) {
74
76
  async fills(query) {
75
77
  return unwrap(await client.GET("/v1/partner/fills", { params: { query: query ?? {} } }));
76
78
  },
79
+ /**
80
+ * Your webhook events from the last 30 days, delivered or not, oldest
81
+ * first, each with the body as it was posted and how its delivery stands:
82
+ * recover what your endpoint missed. `since` (RFC 3339) narrows to events
83
+ * queued from then on. Pass `next_cursor` as `cursor` for the next page;
84
+ * it follows the last event even when `has_more` is false, so keep it to
85
+ * read new events later.
86
+ */
87
+ async webhookEvents(query) {
88
+ return unwrap(await client.GET("/v1/partner/webhook-events", { params: { query: query ?? {} } }));
89
+ },
90
+ /**
91
+ * The value of the account your admission of `wallet` opened, the body
92
+ * the user's own Get account value returns, read with your server key so
93
+ * you can keep it after the user's key lapses. A wallet you did not
94
+ * admit, or one no longer signing for that account, is a 404.
95
+ */
96
+ async accountValue(wallet) {
97
+ return unwrap(await client.GET("/v1/partner/accounts/{wallet}/account-value", { params: { path: { wallet } } }));
98
+ },
77
99
  };
78
100
  }
package/dist/totalis.d.ts CHANGED
@@ -319,6 +319,23 @@ export declare function createTotalis(options: TotalisOptions): {
319
319
  readonly wallet: bigint | null;
320
320
  readonly total: bigint | null;
321
321
  }>;
322
+ /** What the account holds at Totalis, every amount read at one block (`GET /v1/me/account-value`). */
323
+ accountValue: (signal?: AbortSignal) => Promise<{
324
+ readonly account: import("./generated/openapi.js").components["schemas"]["LowercaseNonZeroAddress"];
325
+ readonly state: "CURRENT" | "UNKNOWN";
326
+ readonly amount: import("./generated/openapi.js").components["schemas"]["$defs-Amount"] | null;
327
+ readonly block_number: import("./generated/openapi.js").components["schemas"]["UInt64String"] | null;
328
+ readonly wallet_usdc: import("./generated/openapi.js").components["schemas"]["$defs-Amount"] | null;
329
+ readonly vault_cash: import("./generated/openapi.js").components["schemas"]["$defs-Amount"] | null;
330
+ readonly run_off_cash: import("./generated/openapi.js").components["schemas"]["$defs-Amount"] | null;
331
+ readonly open_positions: number | null;
332
+ readonly open_cost: import("./generated/openapi.js").components["schemas"]["$defs-Amount"] | null;
333
+ readonly claimable_profit: import("./generated/openapi.js").components["schemas"]["$defs-Amount"] | null;
334
+ readonly checkpoint: {
335
+ readonly block_number: import("./generated/openapi.js").components["schemas"]["UInt64String"];
336
+ readonly projection_state: "CURRENT" | "STALE";
337
+ };
338
+ }>;
322
339
  readComboCash: (options?: {
323
340
  readonly info?: HyperliquidInfo;
324
341
  readonly signal?: AbortSignal;
package/dist/totalis.js CHANGED
@@ -449,6 +449,10 @@ export function createTotalis(options) {
449
449
  async function readSpendableCash(signal) {
450
450
  return spendableCash(unwrap(await client.GET("/v1/me/balances", signal === undefined ? {} : { signal })));
451
451
  }
452
+ /** A fresh `GET /v1/me/account-value`: what the account holds at Totalis, every amount read at one block; all null when `state` is `UNKNOWN`. */
453
+ async function readAccountValue(signal) {
454
+ return unwrap(await client.GET("/v1/me/account-value", signal === undefined ? {} : { signal }));
455
+ }
452
456
  /**
453
457
  * The account's Combo cash now (`ComboCash`): one venue balances read and
454
458
  * the signer's HyperCore cash read from Hyperliquid, together. Pass `cash`
@@ -1558,6 +1562,8 @@ export function createTotalis(options) {
1558
1562
  deployment,
1559
1563
  /** Spendable Totalis cash from a fresh balances read (`spendableCash`): `{ vault, wallet, total }`, each `null` while unknown, never 0. */
1560
1564
  spendableCash: readSpendableCash,
1565
+ /** What the account holds at Totalis, every amount read at one block (`GET /v1/me/account-value`). */
1566
+ accountValue: readAccountValue,
1561
1567
  readComboCash,
1562
1568
  openPosition,
1563
1569
  cashOut,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@totalis/hip4-client",
3
- "version": "0.97.0",
3
+ "version": "0.99.0",
4
4
  "description": "Totalis HIP-4 SDK: typed HTTP clients, signer-agnostic typed data, a retrying request layer, pagination, a realtime stream and taker/maker flows",
5
5
  "type": "module",
6
6
  "files": [