@haven_ai/sdk 0.0.0-dev.202610231728.63dccc8 → 0.0.0-dev.202610240100.6d87ddf
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/README.md +12 -4
- package/dist/{base64-HBqOk9hF.d.ts → base64-BRBqDeU_.d.ts} +1 -1
- package/dist/{base64-CS85bzyD.d.cts → base64-CufKm8XV.d.cts} +1 -1
- package/dist/{chunk-OBZQNRY6.cjs → chunk-2C5XPH4C.cjs} +3 -3
- package/dist/{chunk-OBZQNRY6.cjs.map → chunk-2C5XPH4C.cjs.map} +1 -1
- package/dist/{chunk-HCFAGYYQ.js → chunk-LKT5B4TK.js} +3 -3
- package/dist/{chunk-HCFAGYYQ.js.map → chunk-LKT5B4TK.js.map} +1 -1
- package/dist/edge.cjs +53 -53
- package/dist/edge.d.cts +2 -2
- package/dist/edge.d.ts +2 -2
- package/dist/edge.js +2 -2
- package/dist/index.cjs +145 -144
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +8 -7
- package/dist/index.d.ts +8 -7
- package/dist/index.js +8 -7
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -2,8 +2,8 @@ import { P as PaymentReceipt, R as ReceiptVerification } from './receipt-B48nv3H
|
|
|
2
2
|
export { a as RECEIPT_VERSION, v as verifyPaymentReceipt } from './receipt-B48nv3HR.cjs';
|
|
3
3
|
import { M as MerchantEgressPolicy, H as HavenClientConfig, P as PaymentRequest, a as PaymentResult, b as PaymentIntent, X as X402PaymentRequired, c as X402AuthorizationOptions, d as X402Intent, e as PaymentStatusResult, f as HavenAgent, g as HavenAgentSummary, S as SweepResult, h as HavenAllowanceSummary, i as HavenBalanceCoverage, B as BudgetPrecheckResult, j as PostPurchaseAllowanceSummary, A as AgentPaymentWarning, k as HavenCatalogEntry, l as HavenCatalogSubmission, m as HavenPaymentReceipt, n as HavenPaymentReceiptsPage, O as OpenTaskBudgetResult, o as HavenTaskBudget, T as TaskBudgetSignContext, p as SubmitTaskBudgetResult, C as CloseTaskBudgetResult, q as SubmitSubBudgetResult, r as HavenPendingSubBudgetSignature, s as CloseSubBudgetResult, t as PaymentResumeState, u as X402Receipt, v as X402Quote, w as X402Erc7710Settlement, x as X402McpCallContext, y as SignData, R as ResumeAuthorizedX402Input, z as ResumeX402PaymentInput, D as X402ResumeState, E as X402McpTransport, F as X402MerchantCallContext, G as X402IntentByKey, I as HavenError } from './types-BKLgr5kr.cjs';
|
|
4
4
|
export { J as AGENT_PAYMENT_FAILURE_CODE_VALUES, K as AGENT_PAYMENT_NEXT_ACTION_VALUES, L as AGENT_PAYMENT_PHASE_VALUES, N as AGENT_PAYMENT_RAIL_VALUES, Q as AgentNextStep, U as AgentPaymentEnumSchema, V as AgentPaymentFailureCode, W as AgentPaymentFailureCodeDescriptions, Y as AgentPaymentFailureCodeSchema, Z as AgentPaymentNextAction, _ as AgentPaymentNextActionDescriptions, $ as AgentPaymentNextActionSchema, a0 as AgentPaymentPhase, a1 as AgentPaymentPhaseDescriptions, a2 as AgentPaymentPhaseSchema, a3 as AgentPaymentRail, a4 as AgentPaymentRailDescriptions, a5 as AgentPaymentRailSchema, a6 as AgentPaymentSummary, a7 as AgentPaymentWarningCode, a8 as AgentPurchaseSummary, a9 as CatalogSubmissionAccepted, aa as DEFAULT_CONFIRMATION_TIMEOUT_MS, ab as HOSTED_DISCOVERY_TIMEOUT_MS, ac as HOSTED_EGRESS_TIMEOUTS, ad as HOSTED_MAX_GET_REDIRECTS, ae as HOSTED_RESPONSE_BYTE_CAPS, af as HavenAgentAllowanceSummary, ag as HavenAgentReadiness, ah as HavenAgentSupersession, ai as HavenAllowance, aj as HavenApiError, ak as HavenCatalogMerchant, al as HavenListScope, am as HavenPaymentStateError, an as HavenSigningError, ao as HavenTimeoutError, ap as HavenUnsupportedSignerVersionError, aq as HavenZeroSettlementHashError, ar as MERCHANT_EGRESS_REFUSED_CODE, as as MERCHANT_EGRESS_RESPONSE_CAP_CODE, at as MachinePaymentRail, au as MerchantEgressRefusalReason, av as MerchantEgressRefusedError, aw as MerchantEgressResponseCapError, ax as MerchantEgressTimeouts, ay as MerchantEgressUse, az as MerchantTimeoutError, aA as PaymentFee, aB as PaymentNextAction, aC as PaymentPhase, aD as PaymentStatus, aE as SIGNER_UPDATE_FALLBACK, aF as SignerRefusalCode, aG as SweepConfirmation, aH as SweepEntry, aI as X402AlreadySettledError, aJ as X402Erc7710AlreadySettledError, aK as X402ExpectedAuth, aL as X402ExpectedContext, aM as X402PaymentOption, aN as X402RequestSnapshot, aO as X402TaskBudgetMismatchError, aP as X402UnexpectedStatusError, aQ as assertPublicHttpsMerchantUrl, aR as isPublicHttpsMerchantUrl, aS as publicHttpsMerchantUrlRefusal, aT as readBodyCapped, aU as signerUpdateFallback, aV as strictMerchantEgressPolicy } from './types-BKLgr5kr.cjs';
|
|
5
|
-
import { H as HavenClientUpdate, S as SweepPrepareResponse, a as SweepAuthorization, b as SweepSubmitResponse } from './base64-
|
|
6
|
-
export { C as CONNECTOR_PACKAGE_NAME, D as DEFAULT_NEXT_TOOL_BY_ACTION, c as DIRECT_SIGN_CONTEXT_VERSION, E as ENTRY_POINT_V07, d as ERC7710_ASSET_TRANSFER_METHOD, e as HAVEN_CLIENT_HEADER, f as HAVEN_CONNECTOR_CHANNEL, g as HAVEN_MINIMUM_NODE_VERSION, h as HYBRID_DELEGATOR_DOMAIN_NAME, i as HYBRID_DELEGATOR_DOMAIN_VERSION, j as HavenTypedDataRefusedError, k as HavenUserOpBindingError, M as MAX_TASK_BUDGET_TTL_SECONDS, N as NEXT_TOOL_SERVER_NAMES, l as NEXT_TOOL_SERVER_ROLES, m as NextStep, n as NextStepArguments, o as NextStepHandoff, p as NextStepInput, q as NextStepTarget, r as NextStepTargets, s as NextToolServerRole, P as PACKED_USER_OPERATION_FIELDS, R as ROOT_AUTHORITY, t as SDK_CLIENT_IDENTITY, u as SDK_VERSION, v as SWEEP_BASE_CHAIN_ID, w as SWEEP_BASE_SEPOLIA_CHAIN_ID, x as SWEEP_BASE_SEPOLIA_USDC_ADDRESS, y as SWEEP_BASE_USDC_ADDRESS, z as SettlementChildExpectation, A as SweepEip712Domain, B as SweepExpectedAuth, F as SweepPreparation, G as SweepSubmitResult, I as SweepTypedData, T as TASK_SIGN_CONTEXT_VERSION, J as TRANSFER_WITH_AUTHORIZATION_TYPES, K as TYPED_DATA_NOT_ALLOWED, L as TaskBudgetCloseExpectation, O as TaskChildExpectation, Q as TaskChildTypedData, U as UnsupportedNodeVersionMessageOptions, X as X402PaymentHeaderContext, V as X402PaymentHeaderValidationError, W as X402SchemeSelection, Y as X402_LEGACY_PAYMENT_HEADER_NAME, Z as X402_MAX_AUTHORIZATION_WINDOW_SECONDS, _ as X402_PAYMENT_HEADER_NAME, $ as X402_PAYMENT_HEADER_NAMES_SENT, a0 as X402_PAYMENT_NONCE_TAG, a1 as X402_PAYMENT_REQUIRED_HEADER_NAME, a2 as X402_PAYMENT_RESPONSE_HEADER_NAME, a3 as X402_SETTLEMENT_FORWARD_MARGIN_SECONDS, a4 as assertBoundDirectPaymentUserOp, a5 as assertOwnTaskBudgetCloseUserOp, a6 as assertOwnTaskChild, a7 as assertUserOpTypedDataBinding, a8 as buildSweepAuthorizationMessage, a9 as buildSweepTypedData, aa as buildX402ExpectedMessage, ab as compareNodeVersions, ac as connectorRerunCommand, ad as connectorSpec, ae as connectorUpgradeCommand, af as createNextStepBuilder, ag as decodeBase64Json, ah as decodeBase64Utf8, ai as defaultNextToolFor, aj as deriveDelegateAccountAddress, ak as deriveX402PaymentNonce, al as encodeBase64Json, am as encodeBase64Utf8, an as encodePaymentProof, ao as hashDelegation, ap as havenClientIdentity, aq as isConnectorChannel, ar as isErc7710Option, as as isPackedUserOperationTypedData, at as isSupportedNodeVersion, au as isSweepableChain, av as isTaskChildTypedData, aw as normalizePaymentRequired, ax as packedUserOperationHash, ay as parseNextTool, az as parsePaymentRequired, aA as parsePaymentRequiredResponse, aB as readClientUpdate, aC as renderNextTool, aD as resolveConnectorChannel, aE as resolveTokenBySymbol, aF as resolveTokenFromAddress, aG as selectErc7710PaymentOption, aH as selectPaymentOption, aI as selectStandardPaymentOption, aJ as selectX402SettlementScheme, aK as sweepUsdcAddress, aL as sweepUsdcDomain, aM as toStandardPaymentRequirements, aN as unsupportedNodeVersionMessage, aO as validateStandardX402PaymentHeader, aP as verifySettlementChild, aQ as x402AssetTransferMethod, aR as x402AuthorizationAmount, aS as x402FacilitatorAddresses, aT as x402PaymentHeaderNamesFor, aU as x402RetryHeadersFor, aV as x402V2PaymentEnvelope } from './base64-
|
|
5
|
+
import { H as HavenClientUpdate, S as SweepPrepareResponse, a as SweepAuthorization, b as SweepSubmitResponse } from './base64-CufKm8XV.cjs';
|
|
6
|
+
export { C as CONNECTOR_PACKAGE_NAME, D as DEFAULT_NEXT_TOOL_BY_ACTION, c as DIRECT_SIGN_CONTEXT_VERSION, E as ENTRY_POINT_V07, d as ERC7710_ASSET_TRANSFER_METHOD, e as HAVEN_CLIENT_HEADER, f as HAVEN_CONNECTOR_CHANNEL, g as HAVEN_MINIMUM_NODE_VERSION, h as HYBRID_DELEGATOR_DOMAIN_NAME, i as HYBRID_DELEGATOR_DOMAIN_VERSION, j as HavenTypedDataRefusedError, k as HavenUserOpBindingError, M as MAX_TASK_BUDGET_TTL_SECONDS, N as NEXT_TOOL_SERVER_NAMES, l as NEXT_TOOL_SERVER_ROLES, m as NextStep, n as NextStepArguments, o as NextStepHandoff, p as NextStepInput, q as NextStepTarget, r as NextStepTargets, s as NextToolServerRole, P as PACKED_USER_OPERATION_FIELDS, R as ROOT_AUTHORITY, t as SDK_CLIENT_IDENTITY, u as SDK_VERSION, v as SWEEP_BASE_CHAIN_ID, w as SWEEP_BASE_SEPOLIA_CHAIN_ID, x as SWEEP_BASE_SEPOLIA_USDC_ADDRESS, y as SWEEP_BASE_USDC_ADDRESS, z as SettlementChildExpectation, A as SweepEip712Domain, B as SweepExpectedAuth, F as SweepPreparation, G as SweepSubmitResult, I as SweepTypedData, T as TASK_SIGN_CONTEXT_VERSION, J as TRANSFER_WITH_AUTHORIZATION_TYPES, K as TYPED_DATA_NOT_ALLOWED, L as TaskBudgetCloseExpectation, O as TaskChildExpectation, Q as TaskChildTypedData, U as UnsupportedNodeVersionMessageOptions, X as X402PaymentHeaderContext, V as X402PaymentHeaderValidationError, W as X402SchemeSelection, Y as X402_LEGACY_PAYMENT_HEADER_NAME, Z as X402_MAX_AUTHORIZATION_WINDOW_SECONDS, _ as X402_PAYMENT_HEADER_NAME, $ as X402_PAYMENT_HEADER_NAMES_SENT, a0 as X402_PAYMENT_NONCE_TAG, a1 as X402_PAYMENT_REQUIRED_HEADER_NAME, a2 as X402_PAYMENT_RESPONSE_HEADER_NAME, a3 as X402_SETTLEMENT_FORWARD_MARGIN_SECONDS, a4 as assertBoundDirectPaymentUserOp, a5 as assertOwnTaskBudgetCloseUserOp, a6 as assertOwnTaskChild, a7 as assertUserOpTypedDataBinding, a8 as buildSweepAuthorizationMessage, a9 as buildSweepTypedData, aa as buildX402ExpectedMessage, ab as compareNodeVersions, ac as connectorRerunCommand, ad as connectorSpec, ae as connectorUpgradeCommand, af as createNextStepBuilder, ag as decodeBase64Json, ah as decodeBase64Utf8, ai as defaultNextToolFor, aj as deriveDelegateAccountAddress, ak as deriveX402PaymentNonce, al as encodeBase64Json, am as encodeBase64Utf8, an as encodePaymentProof, ao as hashDelegation, ap as havenClientIdentity, aq as isConnectorChannel, ar as isErc7710Option, as as isPackedUserOperationTypedData, at as isSupportedNodeVersion, au as isSweepableChain, av as isTaskChildTypedData, aw as normalizePaymentRequired, ax as packedUserOperationHash, ay as parseNextTool, az as parsePaymentRequired, aA as parsePaymentRequiredResponse, aB as readClientUpdate, aC as renderNextTool, aD as resolveConnectorChannel, aE as resolveTokenBySymbol, aF as resolveTokenFromAddress, aG as selectErc7710PaymentOption, aH as selectPaymentOption, aI as selectStandardPaymentOption, aJ as selectX402SettlementScheme, aK as sweepUsdcAddress, aL as sweepUsdcDomain, aM as toStandardPaymentRequirements, aN as unsupportedNodeVersionMessage, aO as validateStandardX402PaymentHeader, aP as verifySettlementChild, aQ as x402AssetTransferMethod, aR as x402AuthorizationAmount, aS as x402FacilitatorAddresses, aT as x402PaymentHeaderNamesFor, aU as x402RetryHeadersFor, aV as x402V2PaymentEnvelope } from './base64-CufKm8XV.cjs';
|
|
7
7
|
import 'x402/types';
|
|
8
8
|
import 'viem';
|
|
9
9
|
|
|
@@ -348,12 +348,13 @@ declare class HavenClient {
|
|
|
348
348
|
/**
|
|
349
349
|
* Post-purchase allowance/budget summary for a settled payment (#1310).
|
|
350
350
|
*
|
|
351
|
-
* Reuses the EXACT rail-aware read path {@link getAllowances}
|
|
352
|
-
*
|
|
353
|
-
*
|
|
354
|
-
* the #1090 `deriveDelegationBudgets`-backed enforcer read, never
|
|
351
|
+
* Reuses the EXACT rail-aware read path {@link getAllowances} uses —
|
|
352
|
+
* `GET /machine-payments/allowances`, with delegation-rail values coming
|
|
353
|
+
* from the #1090 `deriveDelegationBudgets`-backed enforcer read, never
|
|
355
354
|
* `agent_allowances` — so this can never disagree with
|
|
356
|
-
* {@link getAllowances} for the same fixture.
|
|
355
|
+
* {@link getAllowances} for the same fixture. (#1306's catalog-purchase
|
|
356
|
+
* preflight read the same path until #3054; it now calls
|
|
357
|
+
* `POST /machine-payments/budget-precheck` instead.) The settled token is
|
|
357
358
|
* resolved from {@link getPaymentStatus} so callers pass only
|
|
358
359
|
* `paymentId`, never a second haven_get_agent-style round trip.
|
|
359
360
|
*
|
package/dist/index.d.ts
CHANGED
|
@@ -2,8 +2,8 @@ import { P as PaymentReceipt, R as ReceiptVerification } from './receipt-iGW5iNq
|
|
|
2
2
|
export { a as RECEIPT_VERSION, v as verifyPaymentReceipt } from './receipt-iGW5iNq2.js';
|
|
3
3
|
import { M as MerchantEgressPolicy, H as HavenClientConfig, P as PaymentRequest, a as PaymentResult, b as PaymentIntent, X as X402PaymentRequired, c as X402AuthorizationOptions, d as X402Intent, e as PaymentStatusResult, f as HavenAgent, g as HavenAgentSummary, S as SweepResult, h as HavenAllowanceSummary, i as HavenBalanceCoverage, B as BudgetPrecheckResult, j as PostPurchaseAllowanceSummary, A as AgentPaymentWarning, k as HavenCatalogEntry, l as HavenCatalogSubmission, m as HavenPaymentReceipt, n as HavenPaymentReceiptsPage, O as OpenTaskBudgetResult, o as HavenTaskBudget, T as TaskBudgetSignContext, p as SubmitTaskBudgetResult, C as CloseTaskBudgetResult, q as SubmitSubBudgetResult, r as HavenPendingSubBudgetSignature, s as CloseSubBudgetResult, t as PaymentResumeState, u as X402Receipt, v as X402Quote, w as X402Erc7710Settlement, x as X402McpCallContext, y as SignData, R as ResumeAuthorizedX402Input, z as ResumeX402PaymentInput, D as X402ResumeState, E as X402McpTransport, F as X402MerchantCallContext, G as X402IntentByKey, I as HavenError } from './types-BKLgr5kr.js';
|
|
4
4
|
export { J as AGENT_PAYMENT_FAILURE_CODE_VALUES, K as AGENT_PAYMENT_NEXT_ACTION_VALUES, L as AGENT_PAYMENT_PHASE_VALUES, N as AGENT_PAYMENT_RAIL_VALUES, Q as AgentNextStep, U as AgentPaymentEnumSchema, V as AgentPaymentFailureCode, W as AgentPaymentFailureCodeDescriptions, Y as AgentPaymentFailureCodeSchema, Z as AgentPaymentNextAction, _ as AgentPaymentNextActionDescriptions, $ as AgentPaymentNextActionSchema, a0 as AgentPaymentPhase, a1 as AgentPaymentPhaseDescriptions, a2 as AgentPaymentPhaseSchema, a3 as AgentPaymentRail, a4 as AgentPaymentRailDescriptions, a5 as AgentPaymentRailSchema, a6 as AgentPaymentSummary, a7 as AgentPaymentWarningCode, a8 as AgentPurchaseSummary, a9 as CatalogSubmissionAccepted, aa as DEFAULT_CONFIRMATION_TIMEOUT_MS, ab as HOSTED_DISCOVERY_TIMEOUT_MS, ac as HOSTED_EGRESS_TIMEOUTS, ad as HOSTED_MAX_GET_REDIRECTS, ae as HOSTED_RESPONSE_BYTE_CAPS, af as HavenAgentAllowanceSummary, ag as HavenAgentReadiness, ah as HavenAgentSupersession, ai as HavenAllowance, aj as HavenApiError, ak as HavenCatalogMerchant, al as HavenListScope, am as HavenPaymentStateError, an as HavenSigningError, ao as HavenTimeoutError, ap as HavenUnsupportedSignerVersionError, aq as HavenZeroSettlementHashError, ar as MERCHANT_EGRESS_REFUSED_CODE, as as MERCHANT_EGRESS_RESPONSE_CAP_CODE, at as MachinePaymentRail, au as MerchantEgressRefusalReason, av as MerchantEgressRefusedError, aw as MerchantEgressResponseCapError, ax as MerchantEgressTimeouts, ay as MerchantEgressUse, az as MerchantTimeoutError, aA as PaymentFee, aB as PaymentNextAction, aC as PaymentPhase, aD as PaymentStatus, aE as SIGNER_UPDATE_FALLBACK, aF as SignerRefusalCode, aG as SweepConfirmation, aH as SweepEntry, aI as X402AlreadySettledError, aJ as X402Erc7710AlreadySettledError, aK as X402ExpectedAuth, aL as X402ExpectedContext, aM as X402PaymentOption, aN as X402RequestSnapshot, aO as X402TaskBudgetMismatchError, aP as X402UnexpectedStatusError, aQ as assertPublicHttpsMerchantUrl, aR as isPublicHttpsMerchantUrl, aS as publicHttpsMerchantUrlRefusal, aT as readBodyCapped, aU as signerUpdateFallback, aV as strictMerchantEgressPolicy } from './types-BKLgr5kr.js';
|
|
5
|
-
import { H as HavenClientUpdate, S as SweepPrepareResponse, a as SweepAuthorization, b as SweepSubmitResponse } from './base64-
|
|
6
|
-
export { C as CONNECTOR_PACKAGE_NAME, D as DEFAULT_NEXT_TOOL_BY_ACTION, c as DIRECT_SIGN_CONTEXT_VERSION, E as ENTRY_POINT_V07, d as ERC7710_ASSET_TRANSFER_METHOD, e as HAVEN_CLIENT_HEADER, f as HAVEN_CONNECTOR_CHANNEL, g as HAVEN_MINIMUM_NODE_VERSION, h as HYBRID_DELEGATOR_DOMAIN_NAME, i as HYBRID_DELEGATOR_DOMAIN_VERSION, j as HavenTypedDataRefusedError, k as HavenUserOpBindingError, M as MAX_TASK_BUDGET_TTL_SECONDS, N as NEXT_TOOL_SERVER_NAMES, l as NEXT_TOOL_SERVER_ROLES, m as NextStep, n as NextStepArguments, o as NextStepHandoff, p as NextStepInput, q as NextStepTarget, r as NextStepTargets, s as NextToolServerRole, P as PACKED_USER_OPERATION_FIELDS, R as ROOT_AUTHORITY, t as SDK_CLIENT_IDENTITY, u as SDK_VERSION, v as SWEEP_BASE_CHAIN_ID, w as SWEEP_BASE_SEPOLIA_CHAIN_ID, x as SWEEP_BASE_SEPOLIA_USDC_ADDRESS, y as SWEEP_BASE_USDC_ADDRESS, z as SettlementChildExpectation, A as SweepEip712Domain, B as SweepExpectedAuth, F as SweepPreparation, G as SweepSubmitResult, I as SweepTypedData, T as TASK_SIGN_CONTEXT_VERSION, J as TRANSFER_WITH_AUTHORIZATION_TYPES, K as TYPED_DATA_NOT_ALLOWED, L as TaskBudgetCloseExpectation, O as TaskChildExpectation, Q as TaskChildTypedData, U as UnsupportedNodeVersionMessageOptions, X as X402PaymentHeaderContext, V as X402PaymentHeaderValidationError, W as X402SchemeSelection, Y as X402_LEGACY_PAYMENT_HEADER_NAME, Z as X402_MAX_AUTHORIZATION_WINDOW_SECONDS, _ as X402_PAYMENT_HEADER_NAME, $ as X402_PAYMENT_HEADER_NAMES_SENT, a0 as X402_PAYMENT_NONCE_TAG, a1 as X402_PAYMENT_REQUIRED_HEADER_NAME, a2 as X402_PAYMENT_RESPONSE_HEADER_NAME, a3 as X402_SETTLEMENT_FORWARD_MARGIN_SECONDS, a4 as assertBoundDirectPaymentUserOp, a5 as assertOwnTaskBudgetCloseUserOp, a6 as assertOwnTaskChild, a7 as assertUserOpTypedDataBinding, a8 as buildSweepAuthorizationMessage, a9 as buildSweepTypedData, aa as buildX402ExpectedMessage, ab as compareNodeVersions, ac as connectorRerunCommand, ad as connectorSpec, ae as connectorUpgradeCommand, af as createNextStepBuilder, ag as decodeBase64Json, ah as decodeBase64Utf8, ai as defaultNextToolFor, aj as deriveDelegateAccountAddress, ak as deriveX402PaymentNonce, al as encodeBase64Json, am as encodeBase64Utf8, an as encodePaymentProof, ao as hashDelegation, ap as havenClientIdentity, aq as isConnectorChannel, ar as isErc7710Option, as as isPackedUserOperationTypedData, at as isSupportedNodeVersion, au as isSweepableChain, av as isTaskChildTypedData, aw as normalizePaymentRequired, ax as packedUserOperationHash, ay as parseNextTool, az as parsePaymentRequired, aA as parsePaymentRequiredResponse, aB as readClientUpdate, aC as renderNextTool, aD as resolveConnectorChannel, aE as resolveTokenBySymbol, aF as resolveTokenFromAddress, aG as selectErc7710PaymentOption, aH as selectPaymentOption, aI as selectStandardPaymentOption, aJ as selectX402SettlementScheme, aK as sweepUsdcAddress, aL as sweepUsdcDomain, aM as toStandardPaymentRequirements, aN as unsupportedNodeVersionMessage, aO as validateStandardX402PaymentHeader, aP as verifySettlementChild, aQ as x402AssetTransferMethod, aR as x402AuthorizationAmount, aS as x402FacilitatorAddresses, aT as x402PaymentHeaderNamesFor, aU as x402RetryHeadersFor, aV as x402V2PaymentEnvelope } from './base64-
|
|
5
|
+
import { H as HavenClientUpdate, S as SweepPrepareResponse, a as SweepAuthorization, b as SweepSubmitResponse } from './base64-BRBqDeU_.js';
|
|
6
|
+
export { C as CONNECTOR_PACKAGE_NAME, D as DEFAULT_NEXT_TOOL_BY_ACTION, c as DIRECT_SIGN_CONTEXT_VERSION, E as ENTRY_POINT_V07, d as ERC7710_ASSET_TRANSFER_METHOD, e as HAVEN_CLIENT_HEADER, f as HAVEN_CONNECTOR_CHANNEL, g as HAVEN_MINIMUM_NODE_VERSION, h as HYBRID_DELEGATOR_DOMAIN_NAME, i as HYBRID_DELEGATOR_DOMAIN_VERSION, j as HavenTypedDataRefusedError, k as HavenUserOpBindingError, M as MAX_TASK_BUDGET_TTL_SECONDS, N as NEXT_TOOL_SERVER_NAMES, l as NEXT_TOOL_SERVER_ROLES, m as NextStep, n as NextStepArguments, o as NextStepHandoff, p as NextStepInput, q as NextStepTarget, r as NextStepTargets, s as NextToolServerRole, P as PACKED_USER_OPERATION_FIELDS, R as ROOT_AUTHORITY, t as SDK_CLIENT_IDENTITY, u as SDK_VERSION, v as SWEEP_BASE_CHAIN_ID, w as SWEEP_BASE_SEPOLIA_CHAIN_ID, x as SWEEP_BASE_SEPOLIA_USDC_ADDRESS, y as SWEEP_BASE_USDC_ADDRESS, z as SettlementChildExpectation, A as SweepEip712Domain, B as SweepExpectedAuth, F as SweepPreparation, G as SweepSubmitResult, I as SweepTypedData, T as TASK_SIGN_CONTEXT_VERSION, J as TRANSFER_WITH_AUTHORIZATION_TYPES, K as TYPED_DATA_NOT_ALLOWED, L as TaskBudgetCloseExpectation, O as TaskChildExpectation, Q as TaskChildTypedData, U as UnsupportedNodeVersionMessageOptions, X as X402PaymentHeaderContext, V as X402PaymentHeaderValidationError, W as X402SchemeSelection, Y as X402_LEGACY_PAYMENT_HEADER_NAME, Z as X402_MAX_AUTHORIZATION_WINDOW_SECONDS, _ as X402_PAYMENT_HEADER_NAME, $ as X402_PAYMENT_HEADER_NAMES_SENT, a0 as X402_PAYMENT_NONCE_TAG, a1 as X402_PAYMENT_REQUIRED_HEADER_NAME, a2 as X402_PAYMENT_RESPONSE_HEADER_NAME, a3 as X402_SETTLEMENT_FORWARD_MARGIN_SECONDS, a4 as assertBoundDirectPaymentUserOp, a5 as assertOwnTaskBudgetCloseUserOp, a6 as assertOwnTaskChild, a7 as assertUserOpTypedDataBinding, a8 as buildSweepAuthorizationMessage, a9 as buildSweepTypedData, aa as buildX402ExpectedMessage, ab as compareNodeVersions, ac as connectorRerunCommand, ad as connectorSpec, ae as connectorUpgradeCommand, af as createNextStepBuilder, ag as decodeBase64Json, ah as decodeBase64Utf8, ai as defaultNextToolFor, aj as deriveDelegateAccountAddress, ak as deriveX402PaymentNonce, al as encodeBase64Json, am as encodeBase64Utf8, an as encodePaymentProof, ao as hashDelegation, ap as havenClientIdentity, aq as isConnectorChannel, ar as isErc7710Option, as as isPackedUserOperationTypedData, at as isSupportedNodeVersion, au as isSweepableChain, av as isTaskChildTypedData, aw as normalizePaymentRequired, ax as packedUserOperationHash, ay as parseNextTool, az as parsePaymentRequired, aA as parsePaymentRequiredResponse, aB as readClientUpdate, aC as renderNextTool, aD as resolveConnectorChannel, aE as resolveTokenBySymbol, aF as resolveTokenFromAddress, aG as selectErc7710PaymentOption, aH as selectPaymentOption, aI as selectStandardPaymentOption, aJ as selectX402SettlementScheme, aK as sweepUsdcAddress, aL as sweepUsdcDomain, aM as toStandardPaymentRequirements, aN as unsupportedNodeVersionMessage, aO as validateStandardX402PaymentHeader, aP as verifySettlementChild, aQ as x402AssetTransferMethod, aR as x402AuthorizationAmount, aS as x402FacilitatorAddresses, aT as x402PaymentHeaderNamesFor, aU as x402RetryHeadersFor, aV as x402V2PaymentEnvelope } from './base64-BRBqDeU_.js';
|
|
7
7
|
import 'x402/types';
|
|
8
8
|
import 'viem';
|
|
9
9
|
|
|
@@ -348,12 +348,13 @@ declare class HavenClient {
|
|
|
348
348
|
/**
|
|
349
349
|
* Post-purchase allowance/budget summary for a settled payment (#1310).
|
|
350
350
|
*
|
|
351
|
-
* Reuses the EXACT rail-aware read path {@link getAllowances}
|
|
352
|
-
*
|
|
353
|
-
*
|
|
354
|
-
* the #1090 `deriveDelegationBudgets`-backed enforcer read, never
|
|
351
|
+
* Reuses the EXACT rail-aware read path {@link getAllowances} uses —
|
|
352
|
+
* `GET /machine-payments/allowances`, with delegation-rail values coming
|
|
353
|
+
* from the #1090 `deriveDelegationBudgets`-backed enforcer read, never
|
|
355
354
|
* `agent_allowances` — so this can never disagree with
|
|
356
|
-
* {@link getAllowances} for the same fixture.
|
|
355
|
+
* {@link getAllowances} for the same fixture. (#1306's catalog-purchase
|
|
356
|
+
* preflight read the same path until #3054; it now calls
|
|
357
|
+
* `POST /machine-payments/budget-precheck` instead.) The settled token is
|
|
357
358
|
* resolved from {@link getPaymentStatus} so callers pass only
|
|
358
359
|
* `paymentId`, never a second haven_get_agent-style round trip.
|
|
359
360
|
*
|
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { decodeBase64Json, selectStandardPaymentOption, buildX402IdempotencyKey, x402AuthorizationAmount, assertBoundDirectPaymentUserOp, assertFundingLegPaysDelegate, HavenTypedDataRefusedError, assertOwnSettlementChild, parsePaymentRequiredResponse, x402PaymentHeaderNamesSent, SDK_CLIENT_IDENTITY, readClientUpdate, HAVEN_CLIENT_HEADER, isSweepableChain, sweepUsdcAddress, x402PaymentHeaderNamesFor, X402_PAYMENT_HEADER_NAMES, toStandardPaymentRequirements, deriveX402PaymentNonce, encodeBase64Json, x402V2PaymentEnvelope, isErc7710Option, buildSignedTaxDeclaration, encodeTaxDeclarationHeader, selectX402SettlementScheme, selectErc7710PaymentOption, x402AssetTransferMethod, resolveTokenFromAddress, normalizePaymentRequired, X_TAX_DECLARATION_HEADER } from './chunk-
|
|
2
|
-
export { DEFAULT_NEXT_TOOL_BY_ACTION, ERC7710_ASSET_TRANSFER_METHOD, HAVEN_CLIENT_HEADER, HAVEN_MINIMUM_NODE_VERSION, HavenTypedDataRefusedError, MAX_TASK_BUDGET_TTL_SECONDS, NEXT_TOOL_SERVER_NAMES, NEXT_TOOL_SERVER_ROLES, SDK_CLIENT_IDENTITY, SDK_VERSION, SWEEP_BASE_CHAIN_ID, SWEEP_BASE_SEPOLIA_CHAIN_ID, SWEEP_BASE_SEPOLIA_USDC_ADDRESS, SWEEP_BASE_USDC_ADDRESS, TRANSFER_WITH_AUTHORIZATION_TYPES, TYPED_DATA_NOT_ALLOWED, X402PaymentHeaderValidationError, X402_LEGACY_PAYMENT_HEADER_NAME, X402_MAX_AUTHORIZATION_WINDOW_SECONDS, X402_PAYMENT_HEADER_NAME, X402_PAYMENT_HEADER_NAMES_SENT, X402_PAYMENT_NONCE_TAG, X402_PAYMENT_REQUIRED_HEADER_NAME, X402_PAYMENT_RESPONSE_HEADER_NAME, X402_SETTLEMENT_FORWARD_MARGIN_SECONDS, assertBoundDirectPaymentUserOp, assertOwnTaskBudgetCloseUserOp, assertOwnTaskChild, buildSweepAuthorizationMessage, buildSweepTypedData, buildX402ExpectedMessage, compareNodeVersions, createNextStepBuilder, decodeBase64Json, decodeBase64Utf8, defaultNextToolFor, deriveX402PaymentNonce, encodeBase64Json, encodeBase64Utf8, encodePaymentProof, hashDelegation, havenClientIdentity, isErc7710Option, isSupportedNodeVersion, isSweepableChain, isTaskChildTypedData, normalizePaymentRequired, parseNextTool, parsePaymentRequired, parsePaymentRequiredResponse, readClientUpdate, renderNextTool, resolveTokenBySymbol, resolveTokenFromAddress, selectErc7710PaymentOption, selectPaymentOption, selectStandardPaymentOption, selectX402SettlementScheme, sweepUsdcAddress, sweepUsdcDomain, toStandardPaymentRequirements, unsupportedNodeVersionMessage, validateStandardX402PaymentHeader, x402AssetTransferMethod, x402AuthorizationAmount, x402FacilitatorAddresses, x402PaymentHeaderNamesFor, x402RetryHeadersFor, x402V2PaymentEnvelope } from './chunk-
|
|
1
|
+
import { decodeBase64Json, selectStandardPaymentOption, buildX402IdempotencyKey, x402AuthorizationAmount, assertBoundDirectPaymentUserOp, assertFundingLegPaysDelegate, HavenTypedDataRefusedError, assertOwnSettlementChild, parsePaymentRequiredResponse, x402PaymentHeaderNamesSent, SDK_CLIENT_IDENTITY, readClientUpdate, HAVEN_CLIENT_HEADER, isSweepableChain, sweepUsdcAddress, x402PaymentHeaderNamesFor, X402_PAYMENT_HEADER_NAMES, toStandardPaymentRequirements, deriveX402PaymentNonce, encodeBase64Json, x402V2PaymentEnvelope, isErc7710Option, buildSignedTaxDeclaration, encodeTaxDeclarationHeader, selectX402SettlementScheme, selectErc7710PaymentOption, x402AssetTransferMethod, resolveTokenFromAddress, normalizePaymentRequired, X_TAX_DECLARATION_HEADER } from './chunk-LKT5B4TK.js';
|
|
2
|
+
export { DEFAULT_NEXT_TOOL_BY_ACTION, ERC7710_ASSET_TRANSFER_METHOD, HAVEN_CLIENT_HEADER, HAVEN_MINIMUM_NODE_VERSION, HavenTypedDataRefusedError, MAX_TASK_BUDGET_TTL_SECONDS, NEXT_TOOL_SERVER_NAMES, NEXT_TOOL_SERVER_ROLES, SDK_CLIENT_IDENTITY, SDK_VERSION, SWEEP_BASE_CHAIN_ID, SWEEP_BASE_SEPOLIA_CHAIN_ID, SWEEP_BASE_SEPOLIA_USDC_ADDRESS, SWEEP_BASE_USDC_ADDRESS, TRANSFER_WITH_AUTHORIZATION_TYPES, TYPED_DATA_NOT_ALLOWED, X402PaymentHeaderValidationError, X402_LEGACY_PAYMENT_HEADER_NAME, X402_MAX_AUTHORIZATION_WINDOW_SECONDS, X402_PAYMENT_HEADER_NAME, X402_PAYMENT_HEADER_NAMES_SENT, X402_PAYMENT_NONCE_TAG, X402_PAYMENT_REQUIRED_HEADER_NAME, X402_PAYMENT_RESPONSE_HEADER_NAME, X402_SETTLEMENT_FORWARD_MARGIN_SECONDS, assertBoundDirectPaymentUserOp, assertOwnTaskBudgetCloseUserOp, assertOwnTaskChild, buildSweepAuthorizationMessage, buildSweepTypedData, buildX402ExpectedMessage, compareNodeVersions, createNextStepBuilder, decodeBase64Json, decodeBase64Utf8, defaultNextToolFor, deriveX402PaymentNonce, encodeBase64Json, encodeBase64Utf8, encodePaymentProof, hashDelegation, havenClientIdentity, isErc7710Option, isSupportedNodeVersion, isSweepableChain, isTaskChildTypedData, normalizePaymentRequired, parseNextTool, parsePaymentRequired, parsePaymentRequiredResponse, readClientUpdate, renderNextTool, resolveTokenBySymbol, resolveTokenFromAddress, selectErc7710PaymentOption, selectPaymentOption, selectStandardPaymentOption, selectX402SettlementScheme, sweepUsdcAddress, sweepUsdcDomain, toStandardPaymentRequirements, unsupportedNodeVersionMessage, validateStandardX402PaymentHeader, x402AssetTransferMethod, x402AuthorizationAmount, x402FacilitatorAddresses, x402PaymentHeaderNamesFor, x402RetryHeadersFor, x402V2PaymentEnvelope } from './chunk-LKT5B4TK.js';
|
|
3
3
|
import { verifyPaymentReceipt } from './chunk-BUHOTJU3.js';
|
|
4
4
|
export { RECEIPT_VERSION, verifyPaymentReceipt } from './chunk-BUHOTJU3.js';
|
|
5
5
|
import { HavenSigningError, HavenError, DEFAULT_CONFIRMATION_TIMEOUT_MS, HavenApiError, assertUserOpTypedDataBinding, AgentPaymentRail, AgentPaymentPhase, HavenTimeoutError, X402TaskBudgetMismatchError, X402UnexpectedStatusError, X402AlreadySettledError, MerchantTimeoutError, AgentPaymentWarningCode, AgentPaymentNextAction, HavenPaymentStateError, HavenZeroSettlementHashError, X402Erc7710AlreadySettledError, chainIdForNetwork } from './chunk-XFKSI3C4.js';
|
|
@@ -3953,12 +3953,13 @@ var HavenClient = class {
|
|
|
3953
3953
|
/**
|
|
3954
3954
|
* Post-purchase allowance/budget summary for a settled payment (#1310).
|
|
3955
3955
|
*
|
|
3956
|
-
* Reuses the EXACT rail-aware read path {@link getAllowances}
|
|
3957
|
-
*
|
|
3958
|
-
*
|
|
3959
|
-
* the #1090 `deriveDelegationBudgets`-backed enforcer read, never
|
|
3956
|
+
* Reuses the EXACT rail-aware read path {@link getAllowances} uses —
|
|
3957
|
+
* `GET /machine-payments/allowances`, with delegation-rail values coming
|
|
3958
|
+
* from the #1090 `deriveDelegationBudgets`-backed enforcer read, never
|
|
3960
3959
|
* `agent_allowances` — so this can never disagree with
|
|
3961
|
-
* {@link getAllowances} for the same fixture.
|
|
3960
|
+
* {@link getAllowances} for the same fixture. (#1306's catalog-purchase
|
|
3961
|
+
* preflight read the same path until #3054; it now calls
|
|
3962
|
+
* `POST /machine-payments/budget-precheck` instead.) The settled token is
|
|
3962
3963
|
* resolved from {@link getPaymentStatus} so callers pass only
|
|
3963
3964
|
* `paymentId`, never a second haven_get_agent-style round trip.
|
|
3964
3965
|
*
|