@haven_ai/sdk 0.7.0-alpha.0 → 0.8.1-alpha.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.
@@ -55,7 +55,7 @@ interface HavenClientConfig {
55
55
  chainRpcs?: Record<number, string>;
56
56
  }
57
57
  interface PaymentRequest {
58
- /** Token symbol: "EURe", "USDC.e", or "xDAI" */
58
+ /** Token symbol: "USDC" (agent budgets are USDC on Base and Base Sepolia) */
59
59
  token: string;
60
60
  /** Amount as a decimal string, e.g. "5.00" */
61
61
  amount: string;
@@ -133,6 +133,15 @@ interface PaymentIntent {
133
133
  expiresAt: string;
134
134
  /** Data needed to sign the payment */
135
135
  signData: SignData;
136
+ /**
137
+ * #3531: advisory, history-only recipient classification — `previously_paid`
138
+ * when this agent has a prior confirmed payment to this recipient,
139
+ * `new_address` otherwise. Never affects signing or policy. Absent against
140
+ * an older backend, and when the backend's history read fails.
141
+ */
142
+ recipient?: {
143
+ class: 'previously_paid' | 'new_address';
144
+ };
136
145
  }
137
146
  type PaymentStatus = 'pending_signature' | 'submitted' | 'confirmed' | 'pending_approval' | 'approved' | 'proposed' | 'executed' | 'rejected' | 'expired' | 'failed';
138
147
  interface PaymentResult {
@@ -550,6 +559,26 @@ interface HavenAllowance {
550
559
  tokenSymbol: string;
551
560
  configuredAmount: string;
552
561
  resetPeriodMin: number;
562
+ /**
563
+ * #3518: this budget's SCOPE, so an agent holding more than one budget
564
+ * for a token can name the merchant-locked one before paying. The
565
+ * recipient pin is null for an open budget; `merchantId` is set only on a
566
+ * #3331 merchant-locked budget (which always carries a pin). Additive —
567
+ * undefined on an older backend that does not send them.
568
+ */
569
+ delegationHash?: string;
570
+ recipientAddress?: string | null;
571
+ merchantId?: string | null;
572
+ /**
573
+ * #3518: the Haven-side reservation against this budget — the sum of its
574
+ * open, unexpired task- and sub-budget children's caps, in ATOMIC units.
575
+ * Reported beside `onchain.remaining` and never folded into it (the
576
+ * on-chain figure stays authoritative; a reservation releases on
577
+ * close/expire without any chain event). `'0'` also covers a failed
578
+ * read — the sum is best-effort server-side. Additive; undefined on an
579
+ * older backend.
580
+ */
581
+ reservedHavenAtomic?: string;
553
582
  /**
554
583
  * #3128: human-readable `onchain.remaining`, e.g. "4.96 USDC" — the SAME
555
584
  * string {@link HavenAgentAllowanceSummary.remainingDisplay} carries for
@@ -590,8 +619,12 @@ interface HavenAllowanceSummary {
590
619
  * (#1310). Read-only reporting — the on-chain policy remains the actual
591
620
  * spend gate either way, this only says what is left after the purchase.
592
621
  *
593
- * Deliberately the SAME rail-labeled field spelling as #1306's
594
- * catalog-purchase preflight `allowance` block (never a new spelling),
622
+ * #3464: the canonical key spelling is the ONE `haven_get_agent`'s
623
+ * `allowances[]` rows use — the read the server tells an agent to make
624
+ * first — with the figures named `remainingAtomic`, `remainingDisplay`,
625
+ * `resetPeriodMin`, `tokenSymbol`, `tokenAddress`. Deliberately the SAME
626
+ * spelling as #1306's catalog-purchase preflight `allowance` block (never a
627
+ * new spelling; the hosted result types carry the same names),
595
628
  * minus the preflight-only `sufficient` field: post-purchase reporting
596
629
  * answers "what is left", not "was this purchase covered". Read through the
597
630
  * exact same source as {@link HavenAllowanceSummary} / `haven_get_allowances`
@@ -599,19 +632,57 @@ interface HavenAllowanceSummary {
599
632
  * `deriveDelegationBudgets`-backed enforcer read, never `agent_allowances`),
600
633
  * so this can never disagree with `haven_get_allowances` for the same
601
634
  * fixture.
635
+ *
636
+ * The snake_case keys below are DEPRECATED since #3464 and kept for one
637
+ * deprecation window so existing readers keep working; every value is also
638
+ * emitted under the camelCase name above. Removal condition: once
639
+ * `packages/qa-agent` reads the camelCase keys on a released qa-agent build,
640
+ * the snake_case keys go — tracked as the additive-window close, not a
641
+ * separate decision. The new keys stay OPTIONAL on this exported type so
642
+ * existing constructors keep type-checking unchanged.
602
643
  */
603
644
  interface PostPurchaseAllowanceSummary {
604
- /** Which on-chain policy primitive gates this agent's spend (#1306 labeling). */
605
- rail: 'legacy' | 'delegation';
645
+ /**
646
+ * Which on-chain policy primitive gates this agent's spend (#1306
647
+ * labeling). #3464: `'legacy'` removed — unreachable since #1986/#2020
648
+ * (`GET /machine-payments/allowances` answers 410 before this summary is
649
+ * built), superseding #2265's keep-as-declared rationale; the public
650
+ * {@link HavenAgent.executionRail} keeps its declared union.
651
+ */
652
+ rail: 'delegation';
606
653
  /** Remaining atomic units, read through the same source as {@link HavenAllowance.onchain.remaining}. */
607
654
  remaining_atomic: string;
608
- /** Human-readable remaining, e.g. "4.96 USDC". Omitted when the token's decimals are unknown. */
655
+ /**
656
+ * @deprecated #3464 — use `remainingAtomic` (same value). Kept for the
657
+ * deprecation window; removed once `packages/qa-agent` reads the camelCase
658
+ * keys.
659
+ */
609
660
  remaining_display?: string;
661
+ /** @deprecated #3464 — use `tokenSymbol` (same value). Same removal condition. */
610
662
  token_symbol?: string;
663
+ /** @deprecated #3464 — use `tokenAddress` (same value). Same removal condition. */
611
664
  token_address?: string;
612
- /** Minutes — mirrors {@link HavenAllowance.resetPeriodMin} / the delegation's period. */
665
+ /** @deprecated #3464 — use `resetPeriodMin` (same value). Same removal condition. */
613
666
  reset_period?: number;
614
- source: 'allowance_module' | 'active_delegations';
667
+ /**
668
+ * Which source produced the figures. #3464: `'allowance_module'` removed
669
+ * for the same unreachability as `rail: 'legacy'` above.
670
+ */
671
+ source: 'active_delegations';
672
+ /** Remaining atomic units — the same figure `remaining_atomic` carries. Optional on the type, always emitted at runtime. */
673
+ remainingAtomic?: string;
674
+ /**
675
+ * Human-readable remaining, formatted by the ONE shared formatter
676
+ * (`formatRemainingDisplay`) — always emitted at runtime, never omitted:
677
+ * an unknown-decimals token gets the same explicit atomic label
678
+ * `haven_get_agent`'s `allowances[]` rows carry. Optional on the type so
679
+ * existing constructors stay valid.
680
+ */
681
+ remainingDisplay?: string;
682
+ /** Minutes — mirrors {@link HavenAllowance.resetPeriodMin} / the delegation's period. */
683
+ resetPeriodMin?: number;
684
+ tokenSymbol?: string;
685
+ tokenAddress?: string;
615
686
  }
616
687
  /**
617
688
  * #3126 — the answer to "is there money actually HELD behind my budget?",
@@ -669,6 +740,13 @@ interface HavenBalanceCoverage {
669
740
  * token (nothing was read).
670
741
  */
671
742
  budgetRemainingIsFromChain?: boolean;
743
+ /**
744
+ * #3518: present only when `budgetRemainingAtomic` is "0" because the
745
+ * agent has no OPEN budget for the token but holds live merchant-locked
746
+ * budgets — their recipients (lowercase). Those budgets pay only these
747
+ * addresses; `getAllowances()` reports their remaining figures.
748
+ */
749
+ budgetRecipientAddresses?: string[];
672
750
  }
673
751
  /**
674
752
  * Affirmative spend-readiness for the authenticated agent, derived from the raw
@@ -752,6 +830,81 @@ interface HavenAgentSummary extends HavenAgent {
752
830
  * budgets", not a fetch failure).
753
831
  */
754
832
  taskBudgets: HavenTaskBudgetSummary[];
833
+ /**
834
+ * #3506: the sub-budget rows THIS agent must still sign as the DELEGATING
835
+ * agent — the owner issued a sub-budget (a parent-child row for this agent
836
+ * plus a grant to the sub-agent), and each row is `pending` until this
837
+ * agent's delegate key signs it (or `closing` until it signs the close).
838
+ * A derived VIEW, populated from `GET /sub-budgets?status=awaiting_signature`;
839
+ * empty (never throws) against a backend that predates the filter.
840
+ */
841
+ pendingSubBudgetSignatures: HavenPendingSubBudgetSignature[];
842
+ }
843
+ /**
844
+ * #3506: one sub-budget row awaiting THIS agent's signature — what
845
+ * `haven_get_agent` carries per row so the agent can call
846
+ * `haven_sign { sub_budget_id }` then `haven_submit { sub_budget_id, signature }`.
847
+ */
848
+ interface HavenPendingSubBudgetSignature {
849
+ subBudgetId: string;
850
+ /** The parent-child row a grant hangs under; null on the parent-child row itself (they share a tree). */
851
+ parentSubBudgetId: string | null;
852
+ /** `open`: sign the child delegation (row is pending). `close`: sign the revocation (row is closing). */
853
+ purpose: 'open' | 'close';
854
+ /** `parent-child`: this agent's own narrowing of its budget. `grant`: the slice delegated to the sub-agent. */
855
+ what: 'parent-child' | 'grant';
856
+ /** The sub-agent that holds the grant; null on this agent's own parent-child row. */
857
+ subAgentId: string | null;
858
+ tokenAddress: string;
859
+ recipientAddress: string | null;
860
+ periodAmountAtomic: string;
861
+ expiresAt: number;
862
+ isExpired: boolean;
863
+ }
864
+ /** #3506: sub-budget lifecycle status, as the wire names it. */
865
+ type HavenSubBudgetStatus = 'pending' | 'open' | 'closing' | 'closed';
866
+ /** #3506: `RawSubBudget`, camelCased — what the SDK sub-budget methods return. */
867
+ interface HavenSubBudget {
868
+ id: string;
869
+ agentId: string;
870
+ parentAgentId: string;
871
+ parentSubBudgetId: string | null;
872
+ chainId: number;
873
+ tokenAddress: string;
874
+ recipientAddress: string | null;
875
+ parentDelegationHash: string;
876
+ delegationHash: string;
877
+ label: string | null;
878
+ periodAmountAtomic: string;
879
+ status: HavenSubBudgetStatus;
880
+ expiresAt: number;
881
+ isExpired: boolean;
882
+ createdAt: string;
883
+ openedAt: string | null;
884
+ closedAt: string | null;
885
+ closeTxHash: string | null;
886
+ }
887
+ /** #3506: `POST /sub-budgets/:id/submit` — opened (from pending) or closed (from closing). */
888
+ interface SubmitSubBudgetResult {
889
+ subBudget: HavenSubBudget;
890
+ status: 'open' | 'closed';
891
+ /** Present only once the close UserOp lands (`status === 'closed'` from `closing`). */
892
+ closeTxHash?: string;
893
+ }
894
+ /** #3506: the sign data a live-child close returns (the revocation UserOp's typed data). */
895
+ interface HavenSubBudgetCloseSignData {
896
+ signature_scheme: 'eip712_userop';
897
+ typed_data: Record<string, unknown>;
898
+ user_op_hash: string;
899
+ }
900
+ /** #3506: `POST /sub-budgets/:id/close`. */
901
+ interface CloseSubBudgetResult {
902
+ subBudget: HavenSubBudget;
903
+ /** `closed` on a trivial close (never signed, or already expired); absent when a close signature is pending. */
904
+ status?: 'closed';
905
+ /** Present only when the close needed a signature (a live child). */
906
+ signData?: HavenSubBudgetCloseSignData;
907
+ nextAction?: string;
755
908
  }
756
909
  /** #3329: task-budget lifecycle status, as the wire names it. */
757
910
  type HavenTaskBudgetStatus = 'pending' | 'open' | 'closing' | 'closed';
@@ -766,6 +919,22 @@ interface HavenTaskBudget {
766
919
  delegationHash: string;
767
920
  label: string | null;
768
921
  maxAtomic: string;
922
+ /**
923
+ * #3501: camelCase form of `spent_atomic` — the live enforcer figure.
924
+ * Present on GET reads of an open task budget; null when the read failed;
925
+ * absent when the response did not read the chain.
926
+ */
927
+ spentAtomic?: string | null;
928
+ /**
929
+ * #3501: what the chain will still allow through this child (cap minus
930
+ * spent, clamped at zero). A failed read is null — never the full cap.
931
+ */
932
+ remainingAtomic?: string | null;
933
+ /**
934
+ * #3501: provenance of `remainingAtomic`, the parent allowance's honesty
935
+ * flag (`onchain.remainingIsFromChain`, #1319) on the task-budget surface.
936
+ */
937
+ remainingIsFromChain?: boolean;
769
938
  status: HavenTaskBudgetStatus;
770
939
  expiresAt: number;
771
940
  isExpired: boolean;
@@ -778,6 +947,15 @@ interface HavenTaskBudget {
778
947
  * #3329: the condensed row `getAgentSummary()` carries per open, unexpired
779
948
  * task budget — enough to render a "reserved by open task budgets" line and
780
949
  * a task-budget list without a second read.
950
+ *
951
+ * #3501: each row also carries the budget-visibility figure the issue asks
952
+ * for — what the chain will still allow through this child — so an agent
953
+ * reading `haven_get_agent` can tell BEFORE its next payment whether the
954
+ * task budget will refuse it. `remainingAtomic` is null when the on-chain
955
+ * read failed (never the full cap as remaining), and
956
+ * `remainingIsFromChain` is the same honesty flag the parent allowance's
957
+ * `onchain.remainingIsFromChain` carries (#1319): true = live enforcer
958
+ * read, false = the read failed and the figures are null.
781
959
  */
782
960
  interface HavenTaskBudgetSummary {
783
961
  id: string;
@@ -785,8 +963,55 @@ interface HavenTaskBudgetSummary {
785
963
  tokenAddress: string;
786
964
  maxAtomic: string;
787
965
  maxDisplay: string;
966
+ /**
967
+ * #3501: spent so far through this child, from the enforcer's `spentMap`.
968
+ * Null when the on-chain read failed; also null for a budget whose
969
+ * delegation the read could not speak for.
970
+ */
971
+ spentAtomic: string | null;
972
+ /**
973
+ * #3501: `maxAtomic` minus spent, clamped at zero. Null — never the full
974
+ * cap — when the on-chain read failed.
975
+ */
976
+ remainingAtomic: string | null;
977
+ /**
978
+ * #3501: true when `remainingAtomic` came from the live enforcer read,
979
+ * false when that read failed (spent/remaining are then null).
980
+ */
981
+ remainingIsFromChain: boolean;
982
+ /**
983
+ * #3501: human form of `remainingAtomic` ("0.001 USDC"), derived by the
984
+ * same formatter as `maxDisplay`. Null exactly when `remainingAtomic` is
985
+ * null — a failed read never renders as an amount.
986
+ */
987
+ remainingDisplay: string | null;
788
988
  recipientAddress: string | null;
789
989
  expiresAt: number;
990
+ /**
991
+ * #3518: the budget's lifecycle status (`pending` | `open` | `closing` |
992
+ * `closed`) — `haven_get_agent` lists closing and pending budgets too (a
993
+ * close refusal says "re-check the budget's status", so the status must
994
+ * be readable there), and an agent that only ever saw open rows could
995
+ * not. Additive; undefined on a stale cached read from an older client
996
+ * build.
997
+ */
998
+ status?: HavenTaskBudgetStatus;
999
+ isExpired?: boolean;
1000
+ }
1001
+ /**
1002
+ * `precheckBudget()`'s 200 answer. #3518: the `budget_*` fields name the
1003
+ * budget the compare ran against — the one the payment would draw on
1004
+ * (absent when no budget row matched the token).
1005
+ */
1006
+ interface BudgetPrecheckResult {
1007
+ sufficient: boolean;
1008
+ remaining_atomic: string;
1009
+ remaining_is_from_chain?: boolean;
1010
+ replay?: boolean;
1011
+ budget_id?: string;
1012
+ budget_delegation_hash?: string;
1013
+ budget_recipient_address?: string | null;
1014
+ budget_merchant_id?: string | null;
790
1015
  }
791
1016
  /** #3329: `POST /task-budgets` and `POST /task-budgets/:id/close` — the sign-then-submit envelope. */
792
1017
  interface HavenTaskBudgetSignData {
@@ -949,8 +1174,10 @@ interface HavenPaymentReceipt {
949
1174
  /**
950
1175
  * The delegate → merchant settlement transaction (#2998). Trust level differs
951
1176
  * by scheme: on erc7710 it is `txHash` itself and Haven VERIFIED it on-chain
952
- * before the receipt existed; on eip3009 it is the merchant's claim as relayed
953
- * (PAYMENT-RESPONSE), NOT verified on-chain by Haven — cite it as such.
1177
+ * before the receipt existed. On eip3009 it is the settlement the agent
1178
+ * reported through `reportSettlementEvidence()` when there is one, which Haven
1179
+ * also VERIFIED on-chain (#3475); otherwise the merchant's claim as relayed
1180
+ * (PAYMENT-RESPONSE), NOT verified on-chain by Haven — cite that as such.
954
1181
  */
955
1182
  settlementTxHash: string | null;
956
1183
  chainId: number;
@@ -1487,6 +1714,38 @@ interface PaymentStatusResult {
1487
1714
  * row records its response); absent = unknown. See the raw field's doc.
1488
1715
  */
1489
1716
  delivered?: boolean;
1717
+ /**
1718
+ * #3475 follow-up: which settlement branch this x402 payment runs (#946).
1719
+ * `null` on the legacy rail, on any x402 intent whose scheme metadata
1720
+ * predates #946, or any stored value outside this enum.
1721
+ */
1722
+ settlementScheme?: 'eip3009' | 'erc7710' | null;
1723
+ /**
1724
+ * #3475 follow-up: `true` only when an eip3009 payment's merchant
1725
+ * settlement transaction is already recorded and on-chain-verified.
1726
+ * Absent — never `false` — when unknown or on erc7710, matching
1727
+ * `delivered`'s own honesty rule.
1728
+ */
1729
+ merchantSettlementRecorded?: boolean;
1730
+ /**
1731
+ * #3494: a bounded, redacted cause for a `failed` payment — present
1732
+ * (possibly `null`, when no message was recorded) only when `status` is
1733
+ * `'failed'`; absent on every other status.
1734
+ */
1735
+ failureReason?: string | null;
1736
+ /**
1737
+ * #3518: the budget delegation that METERED this payment, recorded at
1738
+ * authorize (migration 053) — the settle summary's authoritative answer
1739
+ * to "which budget paid". Absent on the legacy rail and on rows
1740
+ * predating migration 053.
1741
+ */
1742
+ budgetDelegationHash?: string;
1743
+ /**
1744
+ * #3564: `true` only while a payment's submit is receipt-unconfirmed and
1745
+ * not yet reconciled from the chain. Absent — never `false` — on every
1746
+ * other row, matching `delivered`'s own honesty rule.
1747
+ */
1748
+ submissionOutcomePending?: true;
1490
1749
  /** Platform fee surfaced so it's never silently collected (#386). */
1491
1750
  fee?: PaymentFee | null;
1492
1751
  amountAtomic?: string | null;
@@ -2033,7 +2292,7 @@ declare function buildSweepAuthorizationMessage(auth: SweepAuthorization): strin
2033
2292
  * This SDK's own version. Owned by `scripts/release-bump.mjs`, which rewrites
2034
2293
  * it with the package version on every release — never hand-edit it.
2035
2294
  */
2036
- declare const SDK_VERSION = "0.7.0-alpha.0";
2295
+ declare const SDK_VERSION = "0.8.1-alpha.0";
2037
2296
  /** The request header every published Haven client sends. */
2038
2297
  declare const HAVEN_CLIENT_HEADER = "X-Haven-Client";
2039
2298
  /** `<package>/<version>` — the value of {@link HAVEN_CLIENT_HEADER}. */
@@ -2620,7 +2879,7 @@ declare function encodePaymentProof(receipt: {
2620
2879
  * Resolve a token symbol from a contract address.
2621
2880
  *
2622
2881
  * Checks all supported chains. For chain-specific resolution,
2623
- * pass the optional `network` CAIP-2 string (e.g. "eip155:100").
2882
+ * pass the optional `network` CAIP-2 string (e.g. "eip155:8453").
2624
2883
  */
2625
2884
  declare function resolveTokenFromAddress(address: string, network?: string): {
2626
2885
  symbol: string;
@@ -2918,9 +3177,9 @@ declare class HavenTypedDataRefusedError extends HavenSigningError {
2918
3177
  /**
2919
3178
  * Chains the delegation rail has PINNED delegation contracts for
2920
3179
  * (`packages/backend/src/rails/delegation-contracts.ts`) — the only chains a
2921
- * direct-payment UserOp may be scoped to. Gnosis (100) has no pinned
2922
- * DelegationManager/enforcer set, so it is deliberately excluded even though
2923
- * the delegate account itself could exist there.
3180
+ * direct-payment UserOp may be scoped to. No other chain has a pinned
3181
+ * DelegationManager/enforcer set, so every other chain is deliberately
3182
+ * excluded even where the delegate account itself could exist.
2924
3183
  */
2925
3184
  declare const DIRECT_PAYMENT_CHAIN_IDS: ReadonlySet<number>;
2926
3185
  /** The DeleGator's single-execution `execute((address,uint256,bytes))` — selector `0x5c1c6dcd`. */
@@ -3135,4 +3394,4 @@ declare function encodeBase64Json(value: unknown): string;
3135
3394
  */
3136
3395
  declare function decodeBase64Json<T>(value: string, label?: string): T;
3137
3396
 
3138
- export { AgentPaymentPhase as $, type AgentPaymentWarning as A, type ResumeAuthorizedX402Input as B, type CloseTaskBudgetResult as C, type ResumeX402PaymentInput as D, type X402ResumeState as E, type X402McpTransport as F, type X402MerchantCallContext as G, type HavenClientConfig as H, HavenError as I, AGENT_PAYMENT_FAILURE_CODE_VALUES as J, AGENT_PAYMENT_NEXT_ACTION_VALUES as K, AGENT_PAYMENT_PHASE_VALUES as L, AGENT_PAYMENT_RAIL_VALUES as M, type AgentNextStep as N, type OpenTaskBudgetResult as O, type PaymentRequest as P, type AgentPaymentEnumSchema as Q, type RawPaymentParties as R, type SweepResult as S, type TaskBudgetSignContext as T, AgentPaymentFailureCode as U, AgentPaymentFailureCodeDescriptions as V, AgentPaymentFailureCodeSchema as W, type X402PaymentRequired as X, AgentPaymentNextAction as Y, AgentPaymentNextActionDescriptions as Z, AgentPaymentNextActionSchema as _, type HavenClientUpdate as a, type SweepExpectedAuth as a$, AgentPaymentPhaseDescriptions as a0, AgentPaymentPhaseSchema as a1, AgentPaymentRail as a2, AgentPaymentRailDescriptions as a3, AgentPaymentRailSchema as a4, type AgentPaymentSummary as a5, AgentPaymentWarningCode as a6, type AgentPurchaseSummary as a7, CONNECTOR_PACKAGE_NAME as a8, type CatalogSubmissionAccepted as a9, NEXT_TOOL_SERVER_NAMES as aA, NEXT_TOOL_SERVER_ROLES as aB, type NextStep as aC, type NextStepArguments as aD, type NextStepHandoff as aE, type NextStepInput as aF, type NextStepTarget as aG, type NextStepTargets as aH, type NextToolServerRole as aI, PACKED_USER_OPERATION_FIELDS as aJ, type PaymentFee as aK, type PaymentNextAction as aL, type PaymentPhase as aM, type PaymentStatus as aN, ROOT_AUTHORITY as aO, SDK_CLIENT_IDENTITY as aP, SDK_VERSION as aQ, SIGNER_UPDATE_FALLBACK as aR, SWEEP_BASE_CHAIN_ID as aS, SWEEP_BASE_SEPOLIA_CHAIN_ID as aT, SWEEP_BASE_SEPOLIA_USDC_ADDRESS as aU, SWEEP_BASE_USDC_ADDRESS as aV, type SettlementChildExpectation as aW, SignerRefusalCode as aX, type SweepConfirmation as aY, type SweepEip712Domain as aZ, type SweepEntry as a_, DEFAULT_CONFIRMATION_TIMEOUT_MS as aa, DEFAULT_NEXT_TOOL_BY_ACTION as ab, DIRECT_SIGN_CONTEXT_VERSION as ac, ENTRY_POINT_V07 as ad, ERC7710_ASSET_TRANSFER_METHOD as ae, HAVEN_CLIENT_HEADER as af, HAVEN_CONNECTOR_CHANNEL as ag, HAVEN_MINIMUM_NODE_VERSION as ah, HYBRID_DELEGATOR_DOMAIN_NAME as ai, HYBRID_DELEGATOR_DOMAIN_VERSION as aj, type HavenAgentAllowanceSummary as ak, type HavenAgentReadiness as al, type HavenAllowance as am, HavenApiError as an, type HavenCatalogMerchant as ao, type HavenListScope as ap, HavenPaymentStateError as aq, HavenSigningError as ar, HavenTimeoutError as as, HavenTypedDataRefusedError as at, HavenUnsupportedSignerVersionError as au, HavenUserOpBindingError as av, HavenZeroSettlementHashError as aw, MAX_TASK_BUDGET_TTL_SECONDS as ax, type MachinePaymentRail as ay, MerchantTimeoutError as az, type PaymentResult as b, resolveTokenBySymbol as b$, type SweepPreparation as b0, type SweepSubmitResult as b1, type SweepTypedData as b2, TASK_SIGN_CONTEXT_VERSION as b3, TRANSFER_WITH_AUTHORIZATION_TYPES as b4, TYPED_DATA_NOT_ALLOWED as b5, type TaskBudgetCloseExpectation as b6, type TaskChildExpectation as b7, type TaskChildTypedData as b8, type UnsupportedNodeVersionMessageOptions as b9, connectorRerunCommand as bA, connectorSpec as bB, connectorUpgradeCommand as bC, createNextStepBuilder as bD, decodeBase64Json as bE, decodeBase64Utf8 as bF, defaultNextToolFor as bG, deriveDelegateAccountAddress as bH, encodeBase64Json as bI, encodeBase64Utf8 as bJ, encodePaymentProof as bK, hashDelegation as bL, havenClientIdentity as bM, isConnectorChannel as bN, isErc7710Option as bO, isPackedUserOperationTypedData as bP, isSupportedNodeVersion as bQ, isSweepableChain as bR, isTaskChildTypedData as bS, normalizePaymentRequired as bT, packedUserOperationHash as bU, parseNextTool as bV, parsePaymentRequired as bW, parsePaymentRequiredResponse as bX, readClientUpdate as bY, renderNextTool as bZ, resolveConnectorChannel as b_, X402AlreadySettledError as ba, X402Erc7710AlreadySettledError as bb, type X402ExpectedAuth as bc, type X402ExpectedContext as bd, type X402PaymentHeaderContext as be, X402PaymentHeaderValidationError as bf, type X402PaymentOption as bg, type X402RequestSnapshot as bh, type X402SchemeSelection as bi, X402TaskBudgetMismatchError as bj, X402UnexpectedStatusError as bk, X402_LEGACY_PAYMENT_HEADER_NAME as bl, X402_MAX_AUTHORIZATION_WINDOW_SECONDS as bm, X402_PAYMENT_HEADER_NAME as bn, X402_PAYMENT_HEADER_NAMES_SENT as bo, X402_PAYMENT_REQUIRED_HEADER_NAME as bp, X402_PAYMENT_RESPONSE_HEADER_NAME as bq, X402_SETTLEMENT_FORWARD_MARGIN_SECONDS as br, assertBoundDirectPaymentUserOp as bs, assertOwnTaskBudgetCloseUserOp as bt, assertOwnTaskChild as bu, assertUserOpTypedDataBinding as bv, buildSweepAuthorizationMessage as bw, buildSweepTypedData as bx, buildX402ExpectedMessage as by, compareNodeVersions as bz, type PaymentIntent as c, resolveTokenFromAddress as c0, selectErc7710PaymentOption as c1, selectPaymentOption as c2, selectStandardPaymentOption as c3, selectX402SettlementScheme as c4, signerUpdateFallback as c5, sweepUsdcAddress as c6, sweepUsdcDomain as c7, toStandardPaymentRequirements as c8, unsupportedNodeVersionMessage as c9, validateStandardX402PaymentHeader as ca, verifySettlementChild as cb, x402AssetTransferMethod as cc, x402AuthorizationAmount as cd, x402FacilitatorAddresses as ce, x402V2PaymentEnvelope as cf, type DelegationForHashing as cg, CAVEAT_ENFORCERS as ch, CAVEAT_TYPEHASH as ci, DELEGATION_MANAGER as cj, DELEGATION_TYPEHASH as ck, DIRECT_PAYMENT_CHAIN_IDS as cl, EXECUTE_ABI as cm, HYBRID_DELEGATOR_IMPLEMENTATION as cn, MAX_SETTLEMENT_WINDOW_SECONDS as co, SIMPLE_FACTORY_ADDRESS as cp, type SettlementChildTypedData as cq, assertFundingLegPaysDelegate as cr, assertOwnSettlementChild as cs, chainIdForNetwork as ct, isSettlementChildTypedData as cu, type X402AuthorizationOptions as d, type X402Intent as e, type PaymentStatusResult as f, type HavenAgent as g, type HavenAgentSummary as h, type SweepPrepareResponse as i, type SweepAuthorization as j, type SweepSubmitResponse as k, type HavenAllowanceSummary as l, type HavenBalanceCoverage as m, type PostPurchaseAllowanceSummary as n, type HavenCatalogEntry as o, type HavenCatalogSubmission as p, type HavenPaymentReceipt as q, type HavenPaymentReceiptsPage as r, type HavenTaskBudget as s, type SubmitTaskBudgetResult as t, type PaymentResumeState as u, type X402Receipt as v, type X402Quote as w, type X402Erc7710Settlement as x, type X402McpCallContext as y, type SignData as z };
3397
+ export { AgentPaymentFailureCodeSchema as $, type AgentPaymentWarning as A, type BudgetPrecheckResult as B, type CloseTaskBudgetResult as C, type X402Erc7710Settlement as D, type X402McpCallContext as E, type SignData as F, type ResumeAuthorizedX402Input as G, type HavenClientConfig as H, type ResumeX402PaymentInput as I, type X402ResumeState as J, type X402McpTransport as K, type X402MerchantCallContext as L, HavenError as M, AGENT_PAYMENT_FAILURE_CODE_VALUES as N, type OpenTaskBudgetResult as O, type PaymentRequest as P, AGENT_PAYMENT_NEXT_ACTION_VALUES as Q, type RawPaymentParties as R, type SweepResult as S, type TaskBudgetSignContext as T, AGENT_PAYMENT_PHASE_VALUES as U, AGENT_PAYMENT_RAIL_VALUES as V, type AgentNextStep as W, type X402PaymentRequired as X, type AgentPaymentEnumSchema as Y, AgentPaymentFailureCode as Z, AgentPaymentFailureCodeDescriptions as _, type HavenClientUpdate as a, SignerRefusalCode as a$, AgentPaymentNextAction as a0, AgentPaymentNextActionDescriptions as a1, AgentPaymentNextActionSchema as a2, AgentPaymentPhase as a3, AgentPaymentPhaseDescriptions as a4, AgentPaymentPhaseSchema as a5, AgentPaymentRail as a6, AgentPaymentRailDescriptions as a7, AgentPaymentRailSchema as a8, type AgentPaymentSummary as a9, HavenZeroSettlementHashError as aA, MAX_TASK_BUDGET_TTL_SECONDS as aB, type MachinePaymentRail as aC, MerchantTimeoutError as aD, NEXT_TOOL_SERVER_NAMES as aE, NEXT_TOOL_SERVER_ROLES as aF, type NextStep as aG, type NextStepArguments as aH, type NextStepHandoff as aI, type NextStepInput as aJ, type NextStepTarget as aK, type NextStepTargets as aL, type NextToolServerRole as aM, PACKED_USER_OPERATION_FIELDS as aN, type PaymentFee as aO, type PaymentNextAction as aP, type PaymentPhase as aQ, type PaymentStatus as aR, ROOT_AUTHORITY as aS, SDK_CLIENT_IDENTITY as aT, SDK_VERSION as aU, SIGNER_UPDATE_FALLBACK as aV, SWEEP_BASE_CHAIN_ID as aW, SWEEP_BASE_SEPOLIA_CHAIN_ID as aX, SWEEP_BASE_SEPOLIA_USDC_ADDRESS as aY, SWEEP_BASE_USDC_ADDRESS as aZ, type SettlementChildExpectation as a_, AgentPaymentWarningCode as aa, type AgentPurchaseSummary as ab, CONNECTOR_PACKAGE_NAME as ac, type CatalogSubmissionAccepted as ad, DEFAULT_CONFIRMATION_TIMEOUT_MS as ae, DEFAULT_NEXT_TOOL_BY_ACTION as af, DIRECT_SIGN_CONTEXT_VERSION as ag, ENTRY_POINT_V07 as ah, ERC7710_ASSET_TRANSFER_METHOD as ai, HAVEN_CLIENT_HEADER as aj, HAVEN_CONNECTOR_CHANNEL as ak, HAVEN_MINIMUM_NODE_VERSION as al, HYBRID_DELEGATOR_DOMAIN_NAME as am, HYBRID_DELEGATOR_DOMAIN_VERSION as an, type HavenAgentAllowanceSummary as ao, type HavenAgentReadiness as ap, type HavenAllowance as aq, HavenApiError as ar, type HavenCatalogMerchant as as, type HavenListScope as at, HavenPaymentStateError as au, HavenSigningError as av, HavenTimeoutError as aw, HavenTypedDataRefusedError as ax, HavenUnsupportedSignerVersionError as ay, HavenUserOpBindingError as az, type PaymentResult as b, parsePaymentRequiredResponse as b$, type SweepConfirmation as b0, type SweepEip712Domain as b1, type SweepEntry as b2, type SweepExpectedAuth as b3, type SweepPreparation as b4, type SweepSubmitResult as b5, type SweepTypedData as b6, TASK_SIGN_CONTEXT_VERSION as b7, TRANSFER_WITH_AUTHORIZATION_TYPES as b8, TYPED_DATA_NOT_ALLOWED as b9, buildSweepAuthorizationMessage as bA, buildSweepTypedData as bB, buildX402ExpectedMessage as bC, compareNodeVersions as bD, connectorRerunCommand as bE, connectorSpec as bF, connectorUpgradeCommand as bG, createNextStepBuilder as bH, decodeBase64Json as bI, decodeBase64Utf8 as bJ, defaultNextToolFor as bK, deriveDelegateAccountAddress as bL, encodeBase64Json as bM, encodeBase64Utf8 as bN, encodePaymentProof as bO, hashDelegation as bP, havenClientIdentity as bQ, isConnectorChannel as bR, isErc7710Option as bS, isPackedUserOperationTypedData as bT, isSupportedNodeVersion as bU, isSweepableChain as bV, isTaskChildTypedData as bW, normalizePaymentRequired as bX, packedUserOperationHash as bY, parseNextTool as bZ, parsePaymentRequired as b_, type TaskBudgetCloseExpectation as ba, type TaskChildExpectation as bb, type TaskChildTypedData as bc, type UnsupportedNodeVersionMessageOptions as bd, X402AlreadySettledError as be, X402Erc7710AlreadySettledError as bf, type X402ExpectedAuth as bg, type X402ExpectedContext as bh, type X402PaymentHeaderContext as bi, X402PaymentHeaderValidationError as bj, type X402PaymentOption as bk, type X402RequestSnapshot as bl, type X402SchemeSelection as bm, X402TaskBudgetMismatchError as bn, X402UnexpectedStatusError as bo, X402_LEGACY_PAYMENT_HEADER_NAME as bp, X402_MAX_AUTHORIZATION_WINDOW_SECONDS as bq, X402_PAYMENT_HEADER_NAME as br, X402_PAYMENT_HEADER_NAMES_SENT as bs, X402_PAYMENT_REQUIRED_HEADER_NAME as bt, X402_PAYMENT_RESPONSE_HEADER_NAME as bu, X402_SETTLEMENT_FORWARD_MARGIN_SECONDS as bv, assertBoundDirectPaymentUserOp as bw, assertOwnTaskBudgetCloseUserOp as bx, assertOwnTaskChild as by, assertUserOpTypedDataBinding as bz, type PaymentIntent as c, readClientUpdate as c0, renderNextTool as c1, resolveConnectorChannel as c2, resolveTokenBySymbol as c3, resolveTokenFromAddress as c4, selectErc7710PaymentOption as c5, selectPaymentOption as c6, selectStandardPaymentOption as c7, selectX402SettlementScheme as c8, signerUpdateFallback as c9, sweepUsdcAddress as ca, sweepUsdcDomain as cb, toStandardPaymentRequirements as cc, unsupportedNodeVersionMessage as cd, validateStandardX402PaymentHeader as ce, verifySettlementChild as cf, x402AssetTransferMethod as cg, x402AuthorizationAmount as ch, x402FacilitatorAddresses as ci, x402V2PaymentEnvelope as cj, type DelegationForHashing as ck, CAVEAT_ENFORCERS as cl, CAVEAT_TYPEHASH as cm, DELEGATION_MANAGER as cn, DELEGATION_TYPEHASH as co, DIRECT_PAYMENT_CHAIN_IDS as cp, EXECUTE_ABI as cq, HYBRID_DELEGATOR_IMPLEMENTATION as cr, MAX_SETTLEMENT_WINDOW_SECONDS as cs, SIMPLE_FACTORY_ADDRESS as ct, type SettlementChildTypedData as cu, assertFundingLegPaysDelegate as cv, assertOwnSettlementChild as cw, chainIdForNetwork as cx, isSettlementChildTypedData as cy, type X402AuthorizationOptions as d, type X402Intent as e, type PaymentStatusResult as f, type HavenAgent as g, type HavenAgentSummary as h, type SweepPrepareResponse as i, type SweepAuthorization as j, type SweepSubmitResponse as k, type HavenAllowanceSummary as l, type HavenBalanceCoverage as m, type PostPurchaseAllowanceSummary as n, type HavenCatalogEntry as o, type HavenCatalogSubmission as p, type HavenPaymentReceipt as q, type HavenPaymentReceiptsPage as r, type HavenTaskBudget as s, type SubmitTaskBudgetResult as t, type SubmitSubBudgetResult as u, type HavenPendingSubBudgetSignature as v, type CloseSubBudgetResult as w, type PaymentResumeState as x, type X402Receipt as y, type X402Quote as z };
@@ -1016,5 +1016,5 @@ function assertRedeemsOwnBudgetDelegation(redeemCalldata, ownAccount) {
1016
1016
  }
1017
1017
 
1018
1018
  export { AGENT_PAYMENT_FAILURE_CODE_VALUES, AGENT_PAYMENT_NEXT_ACTION_VALUES, AGENT_PAYMENT_PHASE_VALUES, AGENT_PAYMENT_RAIL_VALUES, AgentPaymentFailureCode, AgentPaymentFailureCodeDescriptions, AgentPaymentFailureCodeSchema, AgentPaymentNextAction, AgentPaymentNextActionDescriptions, AgentPaymentNextActionSchema, AgentPaymentPhase, AgentPaymentPhaseDescriptions, AgentPaymentPhaseSchema, AgentPaymentRail, AgentPaymentRailDescriptions, AgentPaymentRailSchema, AgentPaymentWarningCode, CAVEAT_ENFORCERS, CONNECTOR_PACKAGE_NAME, DEFAULT_CONFIRMATION_TIMEOUT_MS, DELEGATION_MANAGER, DELEGATION_TUPLE_COMPONENTS, DIRECT_SIGN_CONTEXT_VERSION, ENTRY_POINT_V07, HAVEN_CONNECTOR_CHANNEL, HYBRID_DELEGATOR_DOMAIN_NAME, HYBRID_DELEGATOR_DOMAIN_VERSION, HYBRID_DELEGATOR_IMPLEMENTATION, HavenApiError, HavenError, HavenPaymentStateError, HavenSigningError, HavenTimeoutError, HavenUnsupportedSignerVersionError, HavenUserOpBindingError, HavenZeroSettlementHashError, MAX_SETTLEMENT_WINDOW_SECONDS, MerchantTimeoutError, PACKED_USER_OPERATION_FIELDS, REDEEM_DELEGATIONS_ABI, ROOT_AUTHORITY, SIGNER_UPDATE_FALLBACK, SIMPLE_FACTORY_ADDRESS, SINGLE_DEFAULT_MODE, SignerRefusalCode, TASK_SIGN_CONTEXT_VERSION, X402AlreadySettledError, X402Erc7710AlreadySettledError, X402TaskBudgetMismatchError, X402UnexpectedStatusError, assertRedeemsOwnBudgetDelegation, assertUserOpTypedDataBinding, chainIdForNetwork, connectorRerunCommand, connectorSpec, connectorUpgradeCommand, deriveDelegateAccountAddress, isConnectorChannel, isPackedUserOperationTypedData, isSettlementChildTypedData, packedUserOperationHash, resolveConnectorChannel, signerUpdateFallback, verifySettlementChild };
1019
- //# sourceMappingURL=chunk-NNIT7WAI.js.map
1020
- //# sourceMappingURL=chunk-NNIT7WAI.js.map
1019
+ //# sourceMappingURL=chunk-H4APV67M.js.map
1020
+ //# sourceMappingURL=chunk-H4APV67M.js.map