@t2000/sdk 10.15.1 → 10.16.1

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/dist/index.d.cts CHANGED
@@ -1,8 +1,8 @@
1
1
  import { EventEmitter } from 'eventemitter3';
2
2
  import { SuiGrpcClient } from '@mysten/sui/grpc';
3
3
  import { Ed25519Keypair } from '@mysten/sui/keypairs/ed25519';
4
- import { X as T2000Error, b1 as T2000Options, a2 as TransactionSigner, u as PayOptions, v as PayResult, b2 as SwapResult, b3 as SwapQuoteResult, V as SupportedAsset, F as SendResult, B as BalanceResponse, a1 as TransactionRecord, g as DepositInfo, b4 as PaymentRequest, ab as ZkLoginProof, b5 as SuiCoreClient, s as OverlayFeeConfig, b6 as SponsoredCoinMergeCache, W as SwapRouteResult, b7 as SendableAsset } from './commerce-C4D3VxBu.cjs';
5
- export { A as A2A_ESCROW_FEE_CONFIG_ID, a as A2A_ESCROW_PACKAGE_ID, b8 as CETUS_USDC_SUI_POOL, C as CLOCK_ID, b as COIN_REGISTRY, c as ClassifyBalanceChange, d as ClassifyResult, e as CoinMeta, b9 as CoinPage, D as DEFAULT_COMMERCE_API_BASE, ba as DEFAULT_GRPC_URL, f as DEFAULT_NETWORK, E as ETH_TYPE, h as ExtractedTransfer, bb as GASLESS_MIN_STABLE_AMOUNT, bc as GASLESS_STABLE_TYPES, G as GAS_RESERVE_MIN, I as IKA_TYPE, J as JOB_STATES, i as Job, j as JobState, k as JobTerms, l as JobVerification, K as KNOWN_TARGETS, m as KeypairSigner, L as LABEL_PATTERNS, n as LOFI_TYPE, M as MANIFEST_TYPE, o as MAX_DELIVER_HORIZON_MS, p as MAX_JOB_USDC, q as MAX_REVIEW_WINDOW_MS, r as MIST_PER_SUI, N as NAVX_TYPE, bd as OPERATION_ASSETS, O as OVERLAY_FEE_RATE, be as Operation, P as PREFLIGHT_MAX_AMOUNT, t as PREFLIGHT_OK, w as PreflightResult, bf as SENDABLE_ASSETS, S as STABLE_ASSETS, x as SUI_DECIMALS, y as SUI_TYPE, z as SUPPORTED_ASSETS, bg as SelectAndSplitResult, bh as SerializedCetusRoute, bi as SerializedCetusRoutePath, bj as SerializedRouterDataV3, H as ServiceListing, Q as SimulationResult, R as StableAsset, T as SuiHolding, U as SuiRpcTxBlock, Y as T2000ErrorCode, Z as T2000ErrorData, _ as T2000_OVERLAY_FEE_WALLET, $ as TOKEN_MAP, a0 as TransactionLeg, a3 as TxDirection, a4 as USDC_DECIMALS, a5 as USDC_TYPE, a6 as USDE_TYPE, a7 as USDSUI_TYPE, a8 as USDT_TYPE, a9 as WAL_TYPE, aa as WBTC_TYPE, ac as ZkLoginSigner, bk as addSendToTx, bl as addSwapToTx, bm as assertAllowedAsset, bn as assertBuyerRequirements, ad as buildCreateJobTx, ae as buildDeliverJobTx, af as buildRefundJobTx, ag as buildRejectJobTx, ah as buildReleaseJobTx, ai as buildSendTx, aj as buildSwapTx, ak as checkPositiveAmount, al as checkSuiAddress, am as classifyAction, an as classifyLabel, ao as classifyTransaction, bo as deserializeCetusRoute, ap as executeTx, aq as extractAllUserLegs, ar as extractTransferDetails, as as extractTxCommands, at as extractTxSender, au as fallbackLabel, bp as fetchAllCoins, av as fetchService, aw as findSwapRoute, ax as formatAssetAmount, ay as formatSui, az as formatUsd, bq as getCoinMeta, aA as getDecimals, aB as getDecimalsForCoinType, aC as getJob, aD as getJobSpec, br as getSuiClient, bs as getSuiGrpcClient, bt as isAllowedAsset, bu as isCetusRouteFresh, bv as isInRegistry, aE as jobActionsFor, aF as listServices, aG as mapMoveAbortCode, aH as mapWalletError, aI as mistToSui, bw as normalizeAsset, bx as normalizeCoinType, aJ as parseMppSuiChallenge, aK as parseSuiRpcTx, aL as payWithMpp, aM as preflightCreateJob, aN as preflightFail, aO as preflightPay, aP as preflightSend, aQ as preflightSwap, aR as putJobSpec, by as queryHistory, bz as queryTransaction, aS as rawToStable, aT as rawToUsdc, aU as refineLendingLabel, aV as resolveSymbol, aW as resolveTokenType, bA as selectAndSplitCoin, bB as selectSuiCoin, bC as serializeCetusRoute, bD as simulateTransaction, aX as stableToRaw, aY as suiToMist, bE as throwIfSimulationFailed, aZ as truncateAddress, a_ as usdcToRaw, a$ as validateAddress, bF as verifyCetusRouteCoinMatch, b0 as verifyJobForSeller } from './commerce-C4D3VxBu.cjs';
4
+ import { X as T2000Error, b1 as T2000Options, a2 as TransactionSigner, u as PayOptions, v as PayResult, b2 as SwapResult, b3 as SwapQuoteResult, V as SupportedAsset, F as SendResult, B as BalanceResponse, a1 as TransactionRecord, g as DepositInfo, b4 as PaymentRequest, ab as ZkLoginProof, b5 as SuiCoreClient, s as OverlayFeeConfig, b6 as SponsoredCoinMergeCache, W as SwapRouteResult, b7 as SendableAsset } from './commerce-BkSSPS1w.cjs';
5
+ export { A as A2A_ESCROW_FEE_CONFIG_ID, a as A2A_ESCROW_PACKAGE_ID, b8 as CETUS_USDC_SUI_POOL, C as CLOCK_ID, b as COIN_REGISTRY, c as ClassifyBalanceChange, d as ClassifyResult, e as CoinMeta, b9 as CoinPage, D as DEFAULT_COMMERCE_API_BASE, ba as DEFAULT_GRPC_URL, f as DEFAULT_NETWORK, E as ETH_TYPE, h as ExtractedTransfer, bb as GASLESS_MIN_STABLE_AMOUNT, bc as GASLESS_STABLE_TYPES, G as GAS_RESERVE_MIN, I as IKA_TYPE, J as JOB_STATES, i as Job, j as JobState, k as JobTerms, l as JobVerification, K as KNOWN_TARGETS, m as KeypairSigner, L as LABEL_PATTERNS, n as LOFI_TYPE, M as MANIFEST_TYPE, o as MAX_DELIVER_HORIZON_MS, p as MAX_JOB_USDC, q as MAX_REVIEW_WINDOW_MS, r as MIST_PER_SUI, N as NAVX_TYPE, bd as OPERATION_ASSETS, O as OVERLAY_FEE_RATE, be as Operation, P as PREFLIGHT_MAX_AMOUNT, t as PREFLIGHT_OK, w as PreflightResult, bf as SENDABLE_ASSETS, S as STABLE_ASSETS, x as SUI_DECIMALS, y as SUI_TYPE, z as SUPPORTED_ASSETS, bg as SelectAndSplitResult, bh as SerializedCetusRoute, bi as SerializedCetusRoutePath, bj as SerializedRouterDataV3, H as ServiceListing, Q as SimulationResult, R as StableAsset, T as SuiHolding, U as SuiRpcTxBlock, Y as T2000ErrorCode, Z as T2000ErrorData, _ as T2000_OVERLAY_FEE_WALLET, $ as TOKEN_MAP, a0 as TransactionLeg, a3 as TxDirection, a4 as USDC_DECIMALS, a5 as USDC_TYPE, a6 as USDE_TYPE, a7 as USDSUI_TYPE, a8 as USDT_TYPE, a9 as WAL_TYPE, aa as WBTC_TYPE, ac as ZkLoginSigner, bk as addSendToTx, bl as addSwapToTx, bm as assertAllowedAsset, bn as assertBuyerRequirements, ad as buildCreateJobTx, bo as buildDeclineJobTx, ae as buildDeliverJobTx, af as buildRefundJobTx, ag as buildRejectJobTx, ah as buildReleaseJobTx, ai as buildSendTx, aj as buildSwapTx, ak as checkPositiveAmount, al as checkSuiAddress, am as classifyAction, an as classifyLabel, ao as classifyTransaction, bp as deserializeCetusRoute, ap as executeTx, aq as extractAllUserLegs, ar as extractTransferDetails, as as extractTxCommands, at as extractTxSender, au as fallbackLabel, bq as fetchAllCoins, av as fetchService, aw as findSwapRoute, ax as formatAssetAmount, ay as formatSui, az as formatUsd, br as getCoinMeta, aA as getDecimals, aB as getDecimalsForCoinType, aC as getJob, aD as getJobSpec, bs as getSuiClient, bt as getSuiGrpcClient, bu as isAllowedAsset, bv as isCetusRouteFresh, bw as isInRegistry, aE as jobActionsFor, aF as listServices, aG as mapMoveAbortCode, aH as mapWalletError, aI as mistToSui, bx as normalizeAsset, by as normalizeCoinType, aJ as parseMppSuiChallenge, aK as parseSuiRpcTx, aL as payWithMpp, aM as preflightCreateJob, aN as preflightFail, aO as preflightPay, aP as preflightSend, aQ as preflightSwap, aR as putJobSpec, bz as queryHistory, bA as queryTransaction, aS as rawToStable, aT as rawToUsdc, aU as refineLendingLabel, aV as resolveSymbol, aW as resolveTokenType, bB as selectAndSplitCoin, bC as selectSuiCoin, bD as serializeCetusRoute, bE as simulateTransaction, aX as stableToRaw, aY as suiToMist, bF as throwIfSimulationFailed, aZ as truncateAddress, a_ as usdcToRaw, a$ as validateAddress, bG as verifyCetusRouteCoinMatch, b0 as verifyJobForSeller } from './commerce-BkSSPS1w.cjs';
6
6
  import { Transaction, TransactionObjectArgument } from '@mysten/sui/transactions';
7
7
  import { SuinsClient } from '@mysten/suins';
8
8
  import '@mysten/sui/client';
@@ -565,9 +565,26 @@ declare function getAddress(keypair: Ed25519Keypair): string;
565
565
  * target the LATEST published id — the original id (types, Job verbs) is
566
566
  * unchanged.
567
567
  */
568
- /** The latest published `a2a_escrow` package id (v2 upgrade 2026-07-28 —
569
- * adds the `opening` module). Job-verb calls keep using the original id. */
568
+ /** The LATEST published `a2a_escrow` package id (v3 upgrade 2026-07-28 —
569
+ * adds `escrow::decline`; v2 added the `opening` module). New-verb calls
570
+ * (opening + decline) target this; original-id verbs stay put, and older
571
+ * package ids remain callable for published clients. */
570
572
  declare const A2A_ESCROW_OPENING_PACKAGE_ID: string;
573
+ /**
574
+ * PINNED per-upgrade package ids — event-filter anchors, NEVER bump these.
575
+ *
576
+ * A Sui event's type carries the package id that FIRST DEFINED the struct,
577
+ * not the id of the version that executed. Indexers filtering
578
+ * `<pkg>::module` must therefore pin the DEFINING id per event family:
579
+ * v1 (A2A_ESCROW_PACKAGE_ID) — JobCreated/Delivered/Released/Rejected/Refunded
580
+ * v2 (…_V2_ID) — OpeningCreated/Claimed/Cancelled/Refunded
581
+ * v3 (…_V3_ID) — JobDeclined
582
+ * Filtering the floating LATEST id matches nothing once the next upgrade
583
+ * lands (live finding, 2026-07-28: the openings indexer went dark when
584
+ * A2A_ESCROW_OPENING_PACKAGE_ID moved v2 → v3).
585
+ */
586
+ declare const A2A_ESCROW_PACKAGE_V2_ID = "0x860288d789dc617f6474a0a6801d6011e53bf30d5fb801cdad47b9bc6adb098b";
587
+ declare const A2A_ESCROW_PACKAGE_V3_ID = "0x69ad93c555519de520a5c7f7f2963ad6f8b91cefc098fc2eed75942dcb5bcbe7";
571
588
  /** v1 claim policy: any ACTIVE registered Agent ID. */
572
589
  declare const OPENING_CLAIM_POLICY_ANY_ACTIVE = 0;
573
590
  /** Max time an opening may stay claimable (contract cap): 30 days. */
@@ -1416,4 +1433,4 @@ interface DirectPoolSwapArgs {
1416
1433
  */
1417
1434
  declare function buildDirectPoolSwapTx(args: DirectPoolSwapArgs): Promise<Transaction>;
1418
1435
 
1419
- export { A2A_ESCROW_OPENING_PACKAGE_ID, AGENT_CAPITAL_PACKAGE_ID, AGENT_CAPITAL_PUBLISHED_AT, AGENT_ID_PARENT, AGENT_ID_PARENT_NAME, AGENT_ID_PARENT_NFT_ID, AGENT_POOL_TICK_SPACING, AGENT_TOKEN_DECIMALS, AGENT_TOKEN_LP_ALLOCATION, AGENT_TOKEN_TOTAL_SUPPLY, AGENT_TOKEN_TREASURY_ALLOCATION, AUDRIC_PARENT, AUDRIC_PARENT_NAME, AUDRIC_PARENT_NFT_ID, type AgentCoinModule, type AgentCoinParams, type ApiModel, type AppenderContext, BalanceResponse, type BuildAddLeafParams, type BuildRevokeLeafParams, CAPITAL_REGISTRY_ID, CAPITAL_REGISTRY_VERSION, CETUS_CLMM_PACKAGE_ID, CETUS_GLOBAL_CONFIG_ID, CETUS_INTEGRATE_PUBLISHED_AT, CETUS_POOLS_ID, CETUS_POSITION_TYPE, type ChatMessage, type ChatParams, type ChatResult, type ChatUsage, type CheckStatus, type ComposeTxOptions, type ComposeTxResult, DEFAULT_API_BASE, type DailySpend, DepositInfo, type DirectPoolSwapArgs, InvalidAddressError, type LabelValidationResult, type LimitAssertInput, LimitEnforcer, LimitExceededError, type LimitKind, type LimitOperation, type LimitsConfig, type LimitsFile, MAX_OPEN_WINDOW_MS, MIN_LP_USDC, type NormalizedAddress, OPENING_CLAIM_POLICY_ANY_ACTIVE, type OpenJobFilter, type OpenJobRow, type Opening, type OpeningTerms, OverlayFeeConfig, PayOptions, PayResult, PaymentRequest, type PublishAgentCoinArgs, type PublishAgentCoinResult, SPONSORED_PYTH_DEPENDENT_PROVIDERS, SUINS_NAME_REGEX, SUI_ADDRESS_REGEX, SUI_ADDRESS_STRICT_REGEX, SYMBOL_BLOCKLIST, SendResult, type SendTransferInput, SendableAsset, type StepPreview, SuinsNotRegisteredError, type SuinsParent, SuinsRpcError, SupportedAsset, type SwapExecuteInput, SwapQuoteResult, SwapResult, SwapRouteResult, T2000, T2000Error, T2000Options, type TokenizeArgs, TransactionRecord, TransactionSigner, type TrustMode, type UpstreamClaim, type VerifyAnchor, type VerifyCheck, type VerifyOptions, type VerifyResult, type VerifyUpstream, WRITE_APPENDER_REGISTRY, type WriteStep, type WriteToolName, ZkLoginProof, approxUsdValue, assertLimitConfig, buildAddLeafTx, buildAgentCoinModule, buildCancelOpeningTx, buildClaimOpeningTx, buildCreateOpeningTx, buildDirectPoolSwapTx, buildPublishAgentCoinTx, buildRefundUnclaimedTx, buildRevokeLeafTx, buildTokenizeTx, cancelOpenJob, chatCompletion, chatCompletionStream, claimOpenJob, clearLimits, composeTx, dailySpentToday, deriveAllowedAddressesFromPtb, displayHandle, exportPrivateKey, fullHandle, generateKeypair, getAddress, getLimits, getOpenJob, getOpening, getSponsoredSwapProviders, getSwapQuote, hasLimits, keypairFromPrivateKey, listModels, listOpenJobs, loadKey, looksLikeSuiNs, normalizeAddressInput, postOpenJob, preflightCreateOpening, queryBalance, readLimitsFile, recordDailySpend, refundOpenJob, resolveAddressToSuinsViaRpc, resolveSuinsViaRpc, saveBech32, saveKey, setLimits, validateAgentCoinParams, validateLabel, verifyReceipt, walletExists, writeLimitsFile };
1436
+ export { A2A_ESCROW_OPENING_PACKAGE_ID, A2A_ESCROW_PACKAGE_V2_ID, A2A_ESCROW_PACKAGE_V3_ID, AGENT_CAPITAL_PACKAGE_ID, AGENT_CAPITAL_PUBLISHED_AT, AGENT_ID_PARENT, AGENT_ID_PARENT_NAME, AGENT_ID_PARENT_NFT_ID, AGENT_POOL_TICK_SPACING, AGENT_TOKEN_DECIMALS, AGENT_TOKEN_LP_ALLOCATION, AGENT_TOKEN_TOTAL_SUPPLY, AGENT_TOKEN_TREASURY_ALLOCATION, AUDRIC_PARENT, AUDRIC_PARENT_NAME, AUDRIC_PARENT_NFT_ID, type AgentCoinModule, type AgentCoinParams, type ApiModel, type AppenderContext, BalanceResponse, type BuildAddLeafParams, type BuildRevokeLeafParams, CAPITAL_REGISTRY_ID, CAPITAL_REGISTRY_VERSION, CETUS_CLMM_PACKAGE_ID, CETUS_GLOBAL_CONFIG_ID, CETUS_INTEGRATE_PUBLISHED_AT, CETUS_POOLS_ID, CETUS_POSITION_TYPE, type ChatMessage, type ChatParams, type ChatResult, type ChatUsage, type CheckStatus, type ComposeTxOptions, type ComposeTxResult, DEFAULT_API_BASE, type DailySpend, DepositInfo, type DirectPoolSwapArgs, InvalidAddressError, type LabelValidationResult, type LimitAssertInput, LimitEnforcer, LimitExceededError, type LimitKind, type LimitOperation, type LimitsConfig, type LimitsFile, MAX_OPEN_WINDOW_MS, MIN_LP_USDC, type NormalizedAddress, OPENING_CLAIM_POLICY_ANY_ACTIVE, type OpenJobFilter, type OpenJobRow, type Opening, type OpeningTerms, OverlayFeeConfig, PayOptions, PayResult, PaymentRequest, type PublishAgentCoinArgs, type PublishAgentCoinResult, SPONSORED_PYTH_DEPENDENT_PROVIDERS, SUINS_NAME_REGEX, SUI_ADDRESS_REGEX, SUI_ADDRESS_STRICT_REGEX, SYMBOL_BLOCKLIST, SendResult, type SendTransferInput, SendableAsset, type StepPreview, SuinsNotRegisteredError, type SuinsParent, SuinsRpcError, SupportedAsset, type SwapExecuteInput, SwapQuoteResult, SwapResult, SwapRouteResult, T2000, T2000Error, T2000Options, type TokenizeArgs, TransactionRecord, TransactionSigner, type TrustMode, type UpstreamClaim, type VerifyAnchor, type VerifyCheck, type VerifyOptions, type VerifyResult, type VerifyUpstream, WRITE_APPENDER_REGISTRY, type WriteStep, type WriteToolName, ZkLoginProof, approxUsdValue, assertLimitConfig, buildAddLeafTx, buildAgentCoinModule, buildCancelOpeningTx, buildClaimOpeningTx, buildCreateOpeningTx, buildDirectPoolSwapTx, buildPublishAgentCoinTx, buildRefundUnclaimedTx, buildRevokeLeafTx, buildTokenizeTx, cancelOpenJob, chatCompletion, chatCompletionStream, claimOpenJob, clearLimits, composeTx, dailySpentToday, deriveAllowedAddressesFromPtb, displayHandle, exportPrivateKey, fullHandle, generateKeypair, getAddress, getLimits, getOpenJob, getOpening, getSponsoredSwapProviders, getSwapQuote, hasLimits, keypairFromPrivateKey, listModels, listOpenJobs, loadKey, looksLikeSuiNs, normalizeAddressInput, postOpenJob, preflightCreateOpening, queryBalance, readLimitsFile, recordDailySpend, refundOpenJob, resolveAddressToSuinsViaRpc, resolveSuinsViaRpc, saveBech32, saveKey, setLimits, validateAgentCoinParams, validateLabel, verifyReceipt, walletExists, writeLimitsFile };
package/dist/index.d.ts CHANGED
@@ -1,8 +1,8 @@
1
1
  import { EventEmitter } from 'eventemitter3';
2
2
  import { SuiGrpcClient } from '@mysten/sui/grpc';
3
3
  import { Ed25519Keypair } from '@mysten/sui/keypairs/ed25519';
4
- import { X as T2000Error, b1 as T2000Options, a2 as TransactionSigner, u as PayOptions, v as PayResult, b2 as SwapResult, b3 as SwapQuoteResult, V as SupportedAsset, F as SendResult, B as BalanceResponse, a1 as TransactionRecord, g as DepositInfo, b4 as PaymentRequest, ab as ZkLoginProof, b5 as SuiCoreClient, s as OverlayFeeConfig, b6 as SponsoredCoinMergeCache, W as SwapRouteResult, b7 as SendableAsset } from './commerce-C4D3VxBu.js';
5
- export { A as A2A_ESCROW_FEE_CONFIG_ID, a as A2A_ESCROW_PACKAGE_ID, b8 as CETUS_USDC_SUI_POOL, C as CLOCK_ID, b as COIN_REGISTRY, c as ClassifyBalanceChange, d as ClassifyResult, e as CoinMeta, b9 as CoinPage, D as DEFAULT_COMMERCE_API_BASE, ba as DEFAULT_GRPC_URL, f as DEFAULT_NETWORK, E as ETH_TYPE, h as ExtractedTransfer, bb as GASLESS_MIN_STABLE_AMOUNT, bc as GASLESS_STABLE_TYPES, G as GAS_RESERVE_MIN, I as IKA_TYPE, J as JOB_STATES, i as Job, j as JobState, k as JobTerms, l as JobVerification, K as KNOWN_TARGETS, m as KeypairSigner, L as LABEL_PATTERNS, n as LOFI_TYPE, M as MANIFEST_TYPE, o as MAX_DELIVER_HORIZON_MS, p as MAX_JOB_USDC, q as MAX_REVIEW_WINDOW_MS, r as MIST_PER_SUI, N as NAVX_TYPE, bd as OPERATION_ASSETS, O as OVERLAY_FEE_RATE, be as Operation, P as PREFLIGHT_MAX_AMOUNT, t as PREFLIGHT_OK, w as PreflightResult, bf as SENDABLE_ASSETS, S as STABLE_ASSETS, x as SUI_DECIMALS, y as SUI_TYPE, z as SUPPORTED_ASSETS, bg as SelectAndSplitResult, bh as SerializedCetusRoute, bi as SerializedCetusRoutePath, bj as SerializedRouterDataV3, H as ServiceListing, Q as SimulationResult, R as StableAsset, T as SuiHolding, U as SuiRpcTxBlock, Y as T2000ErrorCode, Z as T2000ErrorData, _ as T2000_OVERLAY_FEE_WALLET, $ as TOKEN_MAP, a0 as TransactionLeg, a3 as TxDirection, a4 as USDC_DECIMALS, a5 as USDC_TYPE, a6 as USDE_TYPE, a7 as USDSUI_TYPE, a8 as USDT_TYPE, a9 as WAL_TYPE, aa as WBTC_TYPE, ac as ZkLoginSigner, bk as addSendToTx, bl as addSwapToTx, bm as assertAllowedAsset, bn as assertBuyerRequirements, ad as buildCreateJobTx, ae as buildDeliverJobTx, af as buildRefundJobTx, ag as buildRejectJobTx, ah as buildReleaseJobTx, ai as buildSendTx, aj as buildSwapTx, ak as checkPositiveAmount, al as checkSuiAddress, am as classifyAction, an as classifyLabel, ao as classifyTransaction, bo as deserializeCetusRoute, ap as executeTx, aq as extractAllUserLegs, ar as extractTransferDetails, as as extractTxCommands, at as extractTxSender, au as fallbackLabel, bp as fetchAllCoins, av as fetchService, aw as findSwapRoute, ax as formatAssetAmount, ay as formatSui, az as formatUsd, bq as getCoinMeta, aA as getDecimals, aB as getDecimalsForCoinType, aC as getJob, aD as getJobSpec, br as getSuiClient, bs as getSuiGrpcClient, bt as isAllowedAsset, bu as isCetusRouteFresh, bv as isInRegistry, aE as jobActionsFor, aF as listServices, aG as mapMoveAbortCode, aH as mapWalletError, aI as mistToSui, bw as normalizeAsset, bx as normalizeCoinType, aJ as parseMppSuiChallenge, aK as parseSuiRpcTx, aL as payWithMpp, aM as preflightCreateJob, aN as preflightFail, aO as preflightPay, aP as preflightSend, aQ as preflightSwap, aR as putJobSpec, by as queryHistory, bz as queryTransaction, aS as rawToStable, aT as rawToUsdc, aU as refineLendingLabel, aV as resolveSymbol, aW as resolveTokenType, bA as selectAndSplitCoin, bB as selectSuiCoin, bC as serializeCetusRoute, bD as simulateTransaction, aX as stableToRaw, aY as suiToMist, bE as throwIfSimulationFailed, aZ as truncateAddress, a_ as usdcToRaw, a$ as validateAddress, bF as verifyCetusRouteCoinMatch, b0 as verifyJobForSeller } from './commerce-C4D3VxBu.js';
4
+ import { X as T2000Error, b1 as T2000Options, a2 as TransactionSigner, u as PayOptions, v as PayResult, b2 as SwapResult, b3 as SwapQuoteResult, V as SupportedAsset, F as SendResult, B as BalanceResponse, a1 as TransactionRecord, g as DepositInfo, b4 as PaymentRequest, ab as ZkLoginProof, b5 as SuiCoreClient, s as OverlayFeeConfig, b6 as SponsoredCoinMergeCache, W as SwapRouteResult, b7 as SendableAsset } from './commerce-BkSSPS1w.js';
5
+ export { A as A2A_ESCROW_FEE_CONFIG_ID, a as A2A_ESCROW_PACKAGE_ID, b8 as CETUS_USDC_SUI_POOL, C as CLOCK_ID, b as COIN_REGISTRY, c as ClassifyBalanceChange, d as ClassifyResult, e as CoinMeta, b9 as CoinPage, D as DEFAULT_COMMERCE_API_BASE, ba as DEFAULT_GRPC_URL, f as DEFAULT_NETWORK, E as ETH_TYPE, h as ExtractedTransfer, bb as GASLESS_MIN_STABLE_AMOUNT, bc as GASLESS_STABLE_TYPES, G as GAS_RESERVE_MIN, I as IKA_TYPE, J as JOB_STATES, i as Job, j as JobState, k as JobTerms, l as JobVerification, K as KNOWN_TARGETS, m as KeypairSigner, L as LABEL_PATTERNS, n as LOFI_TYPE, M as MANIFEST_TYPE, o as MAX_DELIVER_HORIZON_MS, p as MAX_JOB_USDC, q as MAX_REVIEW_WINDOW_MS, r as MIST_PER_SUI, N as NAVX_TYPE, bd as OPERATION_ASSETS, O as OVERLAY_FEE_RATE, be as Operation, P as PREFLIGHT_MAX_AMOUNT, t as PREFLIGHT_OK, w as PreflightResult, bf as SENDABLE_ASSETS, S as STABLE_ASSETS, x as SUI_DECIMALS, y as SUI_TYPE, z as SUPPORTED_ASSETS, bg as SelectAndSplitResult, bh as SerializedCetusRoute, bi as SerializedCetusRoutePath, bj as SerializedRouterDataV3, H as ServiceListing, Q as SimulationResult, R as StableAsset, T as SuiHolding, U as SuiRpcTxBlock, Y as T2000ErrorCode, Z as T2000ErrorData, _ as T2000_OVERLAY_FEE_WALLET, $ as TOKEN_MAP, a0 as TransactionLeg, a3 as TxDirection, a4 as USDC_DECIMALS, a5 as USDC_TYPE, a6 as USDE_TYPE, a7 as USDSUI_TYPE, a8 as USDT_TYPE, a9 as WAL_TYPE, aa as WBTC_TYPE, ac as ZkLoginSigner, bk as addSendToTx, bl as addSwapToTx, bm as assertAllowedAsset, bn as assertBuyerRequirements, ad as buildCreateJobTx, bo as buildDeclineJobTx, ae as buildDeliverJobTx, af as buildRefundJobTx, ag as buildRejectJobTx, ah as buildReleaseJobTx, ai as buildSendTx, aj as buildSwapTx, ak as checkPositiveAmount, al as checkSuiAddress, am as classifyAction, an as classifyLabel, ao as classifyTransaction, bp as deserializeCetusRoute, ap as executeTx, aq as extractAllUserLegs, ar as extractTransferDetails, as as extractTxCommands, at as extractTxSender, au as fallbackLabel, bq as fetchAllCoins, av as fetchService, aw as findSwapRoute, ax as formatAssetAmount, ay as formatSui, az as formatUsd, br as getCoinMeta, aA as getDecimals, aB as getDecimalsForCoinType, aC as getJob, aD as getJobSpec, bs as getSuiClient, bt as getSuiGrpcClient, bu as isAllowedAsset, bv as isCetusRouteFresh, bw as isInRegistry, aE as jobActionsFor, aF as listServices, aG as mapMoveAbortCode, aH as mapWalletError, aI as mistToSui, bx as normalizeAsset, by as normalizeCoinType, aJ as parseMppSuiChallenge, aK as parseSuiRpcTx, aL as payWithMpp, aM as preflightCreateJob, aN as preflightFail, aO as preflightPay, aP as preflightSend, aQ as preflightSwap, aR as putJobSpec, bz as queryHistory, bA as queryTransaction, aS as rawToStable, aT as rawToUsdc, aU as refineLendingLabel, aV as resolveSymbol, aW as resolveTokenType, bB as selectAndSplitCoin, bC as selectSuiCoin, bD as serializeCetusRoute, bE as simulateTransaction, aX as stableToRaw, aY as suiToMist, bF as throwIfSimulationFailed, aZ as truncateAddress, a_ as usdcToRaw, a$ as validateAddress, bG as verifyCetusRouteCoinMatch, b0 as verifyJobForSeller } from './commerce-BkSSPS1w.js';
6
6
  import { Transaction, TransactionObjectArgument } from '@mysten/sui/transactions';
7
7
  import { SuinsClient } from '@mysten/suins';
8
8
  import '@mysten/sui/client';
@@ -565,9 +565,26 @@ declare function getAddress(keypair: Ed25519Keypair): string;
565
565
  * target the LATEST published id — the original id (types, Job verbs) is
566
566
  * unchanged.
567
567
  */
568
- /** The latest published `a2a_escrow` package id (v2 upgrade 2026-07-28 —
569
- * adds the `opening` module). Job-verb calls keep using the original id. */
568
+ /** The LATEST published `a2a_escrow` package id (v3 upgrade 2026-07-28 —
569
+ * adds `escrow::decline`; v2 added the `opening` module). New-verb calls
570
+ * (opening + decline) target this; original-id verbs stay put, and older
571
+ * package ids remain callable for published clients. */
570
572
  declare const A2A_ESCROW_OPENING_PACKAGE_ID: string;
573
+ /**
574
+ * PINNED per-upgrade package ids — event-filter anchors, NEVER bump these.
575
+ *
576
+ * A Sui event's type carries the package id that FIRST DEFINED the struct,
577
+ * not the id of the version that executed. Indexers filtering
578
+ * `<pkg>::module` must therefore pin the DEFINING id per event family:
579
+ * v1 (A2A_ESCROW_PACKAGE_ID) — JobCreated/Delivered/Released/Rejected/Refunded
580
+ * v2 (…_V2_ID) — OpeningCreated/Claimed/Cancelled/Refunded
581
+ * v3 (…_V3_ID) — JobDeclined
582
+ * Filtering the floating LATEST id matches nothing once the next upgrade
583
+ * lands (live finding, 2026-07-28: the openings indexer went dark when
584
+ * A2A_ESCROW_OPENING_PACKAGE_ID moved v2 → v3).
585
+ */
586
+ declare const A2A_ESCROW_PACKAGE_V2_ID = "0x860288d789dc617f6474a0a6801d6011e53bf30d5fb801cdad47b9bc6adb098b";
587
+ declare const A2A_ESCROW_PACKAGE_V3_ID = "0x69ad93c555519de520a5c7f7f2963ad6f8b91cefc098fc2eed75942dcb5bcbe7";
571
588
  /** v1 claim policy: any ACTIVE registered Agent ID. */
572
589
  declare const OPENING_CLAIM_POLICY_ANY_ACTIVE = 0;
573
590
  /** Max time an opening may stay claimable (contract cap): 30 days. */
@@ -1416,4 +1433,4 @@ interface DirectPoolSwapArgs {
1416
1433
  */
1417
1434
  declare function buildDirectPoolSwapTx(args: DirectPoolSwapArgs): Promise<Transaction>;
1418
1435
 
1419
- export { A2A_ESCROW_OPENING_PACKAGE_ID, AGENT_CAPITAL_PACKAGE_ID, AGENT_CAPITAL_PUBLISHED_AT, AGENT_ID_PARENT, AGENT_ID_PARENT_NAME, AGENT_ID_PARENT_NFT_ID, AGENT_POOL_TICK_SPACING, AGENT_TOKEN_DECIMALS, AGENT_TOKEN_LP_ALLOCATION, AGENT_TOKEN_TOTAL_SUPPLY, AGENT_TOKEN_TREASURY_ALLOCATION, AUDRIC_PARENT, AUDRIC_PARENT_NAME, AUDRIC_PARENT_NFT_ID, type AgentCoinModule, type AgentCoinParams, type ApiModel, type AppenderContext, BalanceResponse, type BuildAddLeafParams, type BuildRevokeLeafParams, CAPITAL_REGISTRY_ID, CAPITAL_REGISTRY_VERSION, CETUS_CLMM_PACKAGE_ID, CETUS_GLOBAL_CONFIG_ID, CETUS_INTEGRATE_PUBLISHED_AT, CETUS_POOLS_ID, CETUS_POSITION_TYPE, type ChatMessage, type ChatParams, type ChatResult, type ChatUsage, type CheckStatus, type ComposeTxOptions, type ComposeTxResult, DEFAULT_API_BASE, type DailySpend, DepositInfo, type DirectPoolSwapArgs, InvalidAddressError, type LabelValidationResult, type LimitAssertInput, LimitEnforcer, LimitExceededError, type LimitKind, type LimitOperation, type LimitsConfig, type LimitsFile, MAX_OPEN_WINDOW_MS, MIN_LP_USDC, type NormalizedAddress, OPENING_CLAIM_POLICY_ANY_ACTIVE, type OpenJobFilter, type OpenJobRow, type Opening, type OpeningTerms, OverlayFeeConfig, PayOptions, PayResult, PaymentRequest, type PublishAgentCoinArgs, type PublishAgentCoinResult, SPONSORED_PYTH_DEPENDENT_PROVIDERS, SUINS_NAME_REGEX, SUI_ADDRESS_REGEX, SUI_ADDRESS_STRICT_REGEX, SYMBOL_BLOCKLIST, SendResult, type SendTransferInput, SendableAsset, type StepPreview, SuinsNotRegisteredError, type SuinsParent, SuinsRpcError, SupportedAsset, type SwapExecuteInput, SwapQuoteResult, SwapResult, SwapRouteResult, T2000, T2000Error, T2000Options, type TokenizeArgs, TransactionRecord, TransactionSigner, type TrustMode, type UpstreamClaim, type VerifyAnchor, type VerifyCheck, type VerifyOptions, type VerifyResult, type VerifyUpstream, WRITE_APPENDER_REGISTRY, type WriteStep, type WriteToolName, ZkLoginProof, approxUsdValue, assertLimitConfig, buildAddLeafTx, buildAgentCoinModule, buildCancelOpeningTx, buildClaimOpeningTx, buildCreateOpeningTx, buildDirectPoolSwapTx, buildPublishAgentCoinTx, buildRefundUnclaimedTx, buildRevokeLeafTx, buildTokenizeTx, cancelOpenJob, chatCompletion, chatCompletionStream, claimOpenJob, clearLimits, composeTx, dailySpentToday, deriveAllowedAddressesFromPtb, displayHandle, exportPrivateKey, fullHandle, generateKeypair, getAddress, getLimits, getOpenJob, getOpening, getSponsoredSwapProviders, getSwapQuote, hasLimits, keypairFromPrivateKey, listModels, listOpenJobs, loadKey, looksLikeSuiNs, normalizeAddressInput, postOpenJob, preflightCreateOpening, queryBalance, readLimitsFile, recordDailySpend, refundOpenJob, resolveAddressToSuinsViaRpc, resolveSuinsViaRpc, saveBech32, saveKey, setLimits, validateAgentCoinParams, validateLabel, verifyReceipt, walletExists, writeLimitsFile };
1436
+ export { A2A_ESCROW_OPENING_PACKAGE_ID, A2A_ESCROW_PACKAGE_V2_ID, A2A_ESCROW_PACKAGE_V3_ID, AGENT_CAPITAL_PACKAGE_ID, AGENT_CAPITAL_PUBLISHED_AT, AGENT_ID_PARENT, AGENT_ID_PARENT_NAME, AGENT_ID_PARENT_NFT_ID, AGENT_POOL_TICK_SPACING, AGENT_TOKEN_DECIMALS, AGENT_TOKEN_LP_ALLOCATION, AGENT_TOKEN_TOTAL_SUPPLY, AGENT_TOKEN_TREASURY_ALLOCATION, AUDRIC_PARENT, AUDRIC_PARENT_NAME, AUDRIC_PARENT_NFT_ID, type AgentCoinModule, type AgentCoinParams, type ApiModel, type AppenderContext, BalanceResponse, type BuildAddLeafParams, type BuildRevokeLeafParams, CAPITAL_REGISTRY_ID, CAPITAL_REGISTRY_VERSION, CETUS_CLMM_PACKAGE_ID, CETUS_GLOBAL_CONFIG_ID, CETUS_INTEGRATE_PUBLISHED_AT, CETUS_POOLS_ID, CETUS_POSITION_TYPE, type ChatMessage, type ChatParams, type ChatResult, type ChatUsage, type CheckStatus, type ComposeTxOptions, type ComposeTxResult, DEFAULT_API_BASE, type DailySpend, DepositInfo, type DirectPoolSwapArgs, InvalidAddressError, type LabelValidationResult, type LimitAssertInput, LimitEnforcer, LimitExceededError, type LimitKind, type LimitOperation, type LimitsConfig, type LimitsFile, MAX_OPEN_WINDOW_MS, MIN_LP_USDC, type NormalizedAddress, OPENING_CLAIM_POLICY_ANY_ACTIVE, type OpenJobFilter, type OpenJobRow, type Opening, type OpeningTerms, OverlayFeeConfig, PayOptions, PayResult, PaymentRequest, type PublishAgentCoinArgs, type PublishAgentCoinResult, SPONSORED_PYTH_DEPENDENT_PROVIDERS, SUINS_NAME_REGEX, SUI_ADDRESS_REGEX, SUI_ADDRESS_STRICT_REGEX, SYMBOL_BLOCKLIST, SendResult, type SendTransferInput, SendableAsset, type StepPreview, SuinsNotRegisteredError, type SuinsParent, SuinsRpcError, SupportedAsset, type SwapExecuteInput, SwapQuoteResult, SwapResult, SwapRouteResult, T2000, T2000Error, T2000Options, type TokenizeArgs, TransactionRecord, TransactionSigner, type TrustMode, type UpstreamClaim, type VerifyAnchor, type VerifyCheck, type VerifyOptions, type VerifyResult, type VerifyUpstream, WRITE_APPENDER_REGISTRY, type WriteStep, type WriteToolName, ZkLoginProof, approxUsdValue, assertLimitConfig, buildAddLeafTx, buildAgentCoinModule, buildCancelOpeningTx, buildClaimOpeningTx, buildCreateOpeningTx, buildDirectPoolSwapTx, buildPublishAgentCoinTx, buildRefundUnclaimedTx, buildRevokeLeafTx, buildTokenizeTx, cancelOpenJob, chatCompletion, chatCompletionStream, claimOpenJob, clearLimits, composeTx, dailySpentToday, deriveAllowedAddressesFromPtb, displayHandle, exportPrivateKey, fullHandle, generateKeypair, getAddress, getLimits, getOpenJob, getOpening, getSponsoredSwapProviders, getSwapQuote, hasLimits, keypairFromPrivateKey, listModels, listOpenJobs, loadKey, looksLikeSuiNs, normalizeAddressInput, postOpenJob, preflightCreateOpening, queryBalance, readLimitsFile, recordDailySpend, refundOpenJob, resolveAddressToSuinsViaRpc, resolveSuinsViaRpc, saveBech32, saveKey, setLimits, validateAgentCoinParams, validateLabel, verifyReceipt, walletExists, writeLimitsFile };
package/dist/index.js CHANGED
@@ -3193,14 +3193,155 @@ init_errors();
3193
3193
  init_token_registry();
3194
3194
  init_preflight();
3195
3195
  init_coinSelection();
3196
+
3197
+ // src/wallet/opening.ts
3198
+ init_errors();
3199
+ init_token_registry();
3200
+ init_coinSelection();
3201
+ var A2A_ESCROW_OPENING_PACKAGE_ID = process.env.A2A_ESCROW_OPENING_PACKAGE_ID ?? "0x69ad93c555519de520a5c7f7f2963ad6f8b91cefc098fc2eed75942dcb5bcbe7";
3202
+ var A2A_ESCROW_PACKAGE_V2_ID = "0x860288d789dc617f6474a0a6801d6011e53bf30d5fb801cdad47b9bc6adb098b";
3203
+ var A2A_ESCROW_PACKAGE_V3_ID = "0x69ad93c555519de520a5c7f7f2963ad6f8b91cefc098fc2eed75942dcb5bcbe7";
3204
+ var CLOCK_ID2 = "0x6";
3205
+ var MODULE = "opening";
3206
+ var SHA256_HEX_RE = /^(0x)?[0-9a-fA-F]{64}$/;
3207
+ var OPENING_CLAIM_POLICY_ANY_ACTIVE = 0;
3208
+ var MAX_OPEN_WINDOW_MS = 2592e6;
3209
+ function feeConfigArg(tx) {
3210
+ return tx.sharedObjectRef({
3211
+ objectId: A2A_ESCROW_FEE_CONFIG_ID,
3212
+ initialSharedVersion: A2A_ESCROW_FEE_CONFIG_VERSION,
3213
+ mutable: false
3214
+ });
3215
+ }
3216
+ function hexToBytes2(hex) {
3217
+ const clean = hex.replace(/^0x/, "");
3218
+ const bytes = [];
3219
+ for (let i = 0; i < clean.length; i += 2) {
3220
+ bytes.push(Number.parseInt(clean.slice(i, i + 2), 16));
3221
+ }
3222
+ return bytes;
3223
+ }
3224
+ function preflightCreateOpening(terms) {
3225
+ if (!Number.isFinite(terms.amountUsdc) || terms.amountUsdc <= 0) {
3226
+ return { valid: false, code: "INVALID_AMOUNT", error: "Budget must be positive." };
3227
+ }
3228
+ if (terms.amountUsdc > MAX_JOB_USDC) {
3229
+ return {
3230
+ valid: false,
3231
+ code: "INVALID_AMOUNT",
3232
+ error: `Open jobs cap at ${MAX_JOB_USDC} USDC (v1).`
3233
+ };
3234
+ }
3235
+ if (!SHA256_HEX_RE.test(terms.specHash)) {
3236
+ return { valid: false, code: "INVALID_INPUT", error: "specHash must be a sha256 hex string." };
3237
+ }
3238
+ const now = Date.now();
3239
+ if (terms.openUntilMs <= now) {
3240
+ return { valid: false, code: "INVALID_INPUT", error: "openUntil must be in the future." };
3241
+ }
3242
+ if (terms.openUntilMs > now + MAX_OPEN_WINDOW_MS) {
3243
+ return { valid: false, code: "INVALID_INPUT", error: "Openings can stay claimable at most 30 days." };
3244
+ }
3245
+ if (terms.slaMs <= 0) {
3246
+ return { valid: false, code: "INVALID_INPUT", error: "Delivery window must be positive." };
3247
+ }
3248
+ return { valid: true };
3249
+ }
3250
+ async function buildCreateOpeningTx({
3251
+ client,
3252
+ buyer,
3253
+ terms
3254
+ }) {
3255
+ const pf = preflightCreateOpening(terms);
3256
+ if (!pf.valid) throw new T2000Error(pf.code ?? "INVALID_INPUT", pf.error ?? "Invalid opening.");
3257
+ const rawAmount = BigInt(Math.floor(terms.amountUsdc * 10 ** USDC_DECIMALS));
3258
+ const tx = new Transaction();
3259
+ const { coin } = await selectAndSplitCoin(tx, client, validateAddress(buyer), USDC_TYPE, rawAmount, {
3260
+ allowSwapAll: false
3261
+ });
3262
+ tx.moveCall({
3263
+ target: `${A2A_ESCROW_OPENING_PACKAGE_ID}::${MODULE}::create_open`,
3264
+ typeArguments: [USDC_TYPE],
3265
+ arguments: [
3266
+ coin,
3267
+ tx.pure.vector("u8", hexToBytes2(terms.specHash)),
3268
+ tx.pure.u64(terms.openUntilMs),
3269
+ tx.pure.u64(terms.slaMs),
3270
+ tx.pure.u64(terms.reviewWindowMs),
3271
+ tx.pure.u64(terms.rejectSplitBps),
3272
+ tx.pure.u8(OPENING_CLAIM_POLICY_ANY_ACTIVE),
3273
+ feeConfigArg(tx),
3274
+ tx.object(CLOCK_ID2)
3275
+ ]
3276
+ });
3277
+ return tx;
3278
+ }
3279
+ function buildClaimOpeningTx({
3280
+ openingId,
3281
+ registryId
3282
+ }) {
3283
+ const tx = new Transaction();
3284
+ tx.moveCall({
3285
+ target: `${A2A_ESCROW_OPENING_PACKAGE_ID}::${MODULE}::claim`,
3286
+ typeArguments: [USDC_TYPE],
3287
+ arguments: [
3288
+ tx.object(openingId),
3289
+ tx.object(registryId),
3290
+ feeConfigArg(tx),
3291
+ tx.object(CLOCK_ID2)
3292
+ ]
3293
+ });
3294
+ return tx;
3295
+ }
3296
+ function openingCall(openingId, fn) {
3297
+ const tx = new Transaction();
3298
+ tx.moveCall({
3299
+ target: `${A2A_ESCROW_OPENING_PACKAGE_ID}::${MODULE}::${fn}`,
3300
+ typeArguments: [USDC_TYPE],
3301
+ arguments: [tx.object(openingId), feeConfigArg(tx), tx.object(CLOCK_ID2)]
3302
+ });
3303
+ return tx;
3304
+ }
3305
+ function buildCancelOpeningTx(openingId) {
3306
+ return openingCall(openingId, "cancel_open");
3307
+ }
3308
+ function buildRefundUnclaimedTx(openingId) {
3309
+ return openingCall(openingId, "refund_unclaimed");
3310
+ }
3311
+ function bytesToHex2(bytes) {
3312
+ return `0x${Array.from(bytes).map((b) => b.toString(16).padStart(2, "0")).join("")}`;
3313
+ }
3314
+ async function getOpening(client, openingId) {
3315
+ const resp = await client.core.getObject({ objectId: openingId, include: { json: true } }).catch(() => null);
3316
+ const objType = resp?.object?.type ?? "";
3317
+ const json = resp?.object?.json;
3318
+ if (!json || !objType.includes(`::${MODULE}::Opening<`)) {
3319
+ return null;
3320
+ }
3321
+ return {
3322
+ id: openingId,
3323
+ buyer: String(json.buyer),
3324
+ amountUsdc: Number(json.amount) / 10 ** USDC_DECIMALS,
3325
+ feeBps: Number(json.fee_bps ?? 0),
3326
+ specHash: bytesToHex2(json.spec_hash ?? []),
3327
+ openUntilMs: Number(json.open_until_ms),
3328
+ slaMs: Number(json.sla_ms),
3329
+ reviewWindowMs: Number(json.review_window_ms),
3330
+ rejectSplitBps: Number(json.reject_split_bps),
3331
+ claimPolicy: Number(json.claim_policy ?? 0),
3332
+ createdAtMs: Number(json.created_at_ms ?? 0)
3333
+ };
3334
+ }
3335
+
3336
+ // src/wallet/job.ts
3196
3337
  var A2A_ESCROW_PACKAGE_ID = process.env.A2A_ESCROW_PACKAGE_ID ?? "0x358a819c1c016e2cc84ef5fbea81cba90c31f7f8a62bf45cb5e5276acf198bdd";
3197
3338
  var A2A_ESCROW_FEE_CONFIG_ID = process.env.A2A_ESCROW_FEE_CONFIG_ID ?? "0xddaa25570950b7484dbf20797ebcf75707be9c87cd67bef2a06ed2e81d2c494b";
3198
3339
  var A2A_ESCROW_FEE_CONFIG_VERSION = Number(
3199
3340
  process.env.A2A_ESCROW_FEE_CONFIG_VERSION ?? 931861903
3200
3341
  );
3201
- var CLOCK_ID2 = "0x6";
3202
- var MODULE = "escrow";
3203
- function feeConfigArg(tx) {
3342
+ var CLOCK_ID3 = "0x6";
3343
+ var MODULE2 = "escrow";
3344
+ function feeConfigArg2(tx) {
3204
3345
  return tx.sharedObjectRef({
3205
3346
  objectId: A2A_ESCROW_FEE_CONFIG_ID,
3206
3347
  initialSharedVersion: A2A_ESCROW_FEE_CONFIG_VERSION,
@@ -3217,7 +3358,7 @@ var JOB_STATES = [
3217
3358
  "refunded",
3218
3359
  "rejected"
3219
3360
  ];
3220
- function hexToBytes2(hex) {
3361
+ function hexToBytes3(hex) {
3221
3362
  const clean = hex.startsWith("0x") ? hex.slice(2) : hex;
3222
3363
  if (clean.length === 0 || clean.length % 2 !== 0 || /[^0-9a-fA-F]/.test(clean)) {
3223
3364
  throw new T2000Error(
@@ -3231,7 +3372,7 @@ function hexToBytes2(hex) {
3231
3372
  }
3232
3373
  return out;
3233
3374
  }
3234
- function bytesToHex2(bytes) {
3375
+ function bytesToHex3(bytes) {
3235
3376
  const arr = typeof bytes === "string" ? Array.from(atob(bytes), (c) => c.charCodeAt(0)) : bytes;
3236
3377
  let s = "0x";
3237
3378
  for (const b of arr) s += b.toString(16).padStart(2, "0");
@@ -3262,7 +3403,7 @@ function preflightCreateJob(terms) {
3262
3403
  return preflightFail("INVALID_AMOUNT", "rejectSplitBps must be an integer 0\u201310000.");
3263
3404
  }
3264
3405
  try {
3265
- hexToBytes2(terms.specHash);
3406
+ hexToBytes3(terms.specHash);
3266
3407
  } catch (e) {
3267
3408
  return preflightFail("INVALID_AMOUNT", e.message);
3268
3409
  }
@@ -3285,40 +3426,49 @@ async function buildCreateJobTx({
3285
3426
  allowSwapAll: false
3286
3427
  });
3287
3428
  tx.moveCall({
3288
- target: `${A2A_ESCROW_PACKAGE_ID}::${MODULE}::create`,
3429
+ target: `${A2A_ESCROW_PACKAGE_ID}::${MODULE2}::create`,
3289
3430
  typeArguments: [USDC_TYPE],
3290
3431
  arguments: [
3291
3432
  tx.pure.address(seller),
3292
3433
  coin,
3293
- tx.pure.vector("u8", hexToBytes2(terms.specHash)),
3434
+ tx.pure.vector("u8", hexToBytes3(terms.specHash)),
3294
3435
  tx.pure.u64(terms.deliverByMs),
3295
3436
  tx.pure.u64(terms.reviewWindowMs),
3296
3437
  tx.pure.u64(terms.rejectSplitBps),
3297
- feeConfigArg(tx),
3298
- tx.object(CLOCK_ID2)
3438
+ feeConfigArg2(tx),
3439
+ tx.object(CLOCK_ID3)
3299
3440
  ]
3300
3441
  });
3301
3442
  return tx;
3302
3443
  }
3444
+ function buildDeclineJobTx(jobId) {
3445
+ const tx = new Transaction();
3446
+ tx.moveCall({
3447
+ target: `${A2A_ESCROW_OPENING_PACKAGE_ID}::${MODULE2}::decline`,
3448
+ typeArguments: [USDC_TYPE],
3449
+ arguments: [tx.object(jobId), feeConfigArg2(tx), tx.object(CLOCK_ID3)]
3450
+ });
3451
+ return tx;
3452
+ }
3303
3453
  function jobCall(jobId, fn) {
3304
3454
  const tx = new Transaction();
3305
3455
  tx.moveCall({
3306
- target: `${A2A_ESCROW_PACKAGE_ID}::${MODULE}::${fn}`,
3456
+ target: `${A2A_ESCROW_PACKAGE_ID}::${MODULE2}::${fn}`,
3307
3457
  typeArguments: [USDC_TYPE],
3308
- arguments: [tx.object(jobId), feeConfigArg(tx), tx.object(CLOCK_ID2)]
3458
+ arguments: [tx.object(jobId), feeConfigArg2(tx), tx.object(CLOCK_ID3)]
3309
3459
  });
3310
3460
  return tx;
3311
3461
  }
3312
3462
  function buildDeliverJobTx(jobId, deliveryHash) {
3313
3463
  const tx = new Transaction();
3314
3464
  tx.moveCall({
3315
- target: `${A2A_ESCROW_PACKAGE_ID}::${MODULE}::deliver`,
3465
+ target: `${A2A_ESCROW_PACKAGE_ID}::${MODULE2}::deliver`,
3316
3466
  typeArguments: [USDC_TYPE],
3317
3467
  arguments: [
3318
3468
  tx.object(jobId),
3319
- tx.pure.vector("u8", hexToBytes2(deliveryHash)),
3320
- feeConfigArg(tx),
3321
- tx.object(CLOCK_ID2)
3469
+ tx.pure.vector("u8", hexToBytes3(deliveryHash)),
3470
+ feeConfigArg2(tx),
3471
+ tx.object(CLOCK_ID3)
3322
3472
  ]
3323
3473
  });
3324
3474
  return tx;
@@ -3341,7 +3491,7 @@ async function getJob(client, jobId) {
3341
3491
  });
3342
3492
  const objType = resp.object?.type ?? "";
3343
3493
  const json = resp.object?.json;
3344
- if (!json || !objType.includes(`::${MODULE}::Job<`)) {
3494
+ if (!json || !objType.includes(`::${MODULE2}::Job<`)) {
3345
3495
  throw new T2000Error("RPC_ERROR", `Object ${jobId} is not an a2a_escrow Job.`);
3346
3496
  }
3347
3497
  const stateNum = Number(json.state ?? -1);
@@ -3359,12 +3509,12 @@ async function getJob(client, jobId) {
3359
3509
  amountUsdc: Number(json.amount) / 10 ** USDC_DECIMALS,
3360
3510
  escrowUsdc: Number(json.escrow) / 10 ** USDC_DECIMALS,
3361
3511
  feeBps: Number(json.fee_bps ?? 0),
3362
- specHash: bytesToHex2(json.spec_hash ?? []),
3512
+ specHash: bytesToHex3(json.spec_hash ?? []),
3363
3513
  deliverByMs: Number(json.deliver_by_ms),
3364
3514
  reviewWindowMs: Number(json.review_window_ms),
3365
3515
  rejectSplitBps: Number(json.reject_split_bps),
3366
3516
  state,
3367
- deliveryHash: hasDelivery ? bytesToHex2(deliveryBytes) : null,
3517
+ deliveryHash: hasDelivery ? bytesToHex3(deliveryBytes) : null,
3368
3518
  deliveredAtMs: hasDelivery ? deliveredAtMs : null,
3369
3519
  createdAtMs: Number(json.created_at_ms)
3370
3520
  };
@@ -3409,143 +3559,6 @@ async function verifyJobForSeller({
3409
3559
  return { ok: problems.length === 0, job, problems };
3410
3560
  }
3411
3561
 
3412
- // src/wallet/opening.ts
3413
- init_errors();
3414
- init_token_registry();
3415
- init_coinSelection();
3416
- var A2A_ESCROW_OPENING_PACKAGE_ID = process.env.A2A_ESCROW_OPENING_PACKAGE_ID ?? "0x860288d789dc617f6474a0a6801d6011e53bf30d5fb801cdad47b9bc6adb098b";
3417
- var CLOCK_ID3 = "0x6";
3418
- var MODULE2 = "opening";
3419
- var SHA256_HEX_RE = /^(0x)?[0-9a-fA-F]{64}$/;
3420
- var OPENING_CLAIM_POLICY_ANY_ACTIVE = 0;
3421
- var MAX_OPEN_WINDOW_MS = 2592e6;
3422
- function feeConfigArg2(tx) {
3423
- return tx.sharedObjectRef({
3424
- objectId: A2A_ESCROW_FEE_CONFIG_ID,
3425
- initialSharedVersion: A2A_ESCROW_FEE_CONFIG_VERSION,
3426
- mutable: false
3427
- });
3428
- }
3429
- function hexToBytes3(hex) {
3430
- const clean = hex.replace(/^0x/, "");
3431
- const bytes = [];
3432
- for (let i = 0; i < clean.length; i += 2) {
3433
- bytes.push(Number.parseInt(clean.slice(i, i + 2), 16));
3434
- }
3435
- return bytes;
3436
- }
3437
- function preflightCreateOpening(terms) {
3438
- if (!Number.isFinite(terms.amountUsdc) || terms.amountUsdc <= 0) {
3439
- return { valid: false, code: "INVALID_AMOUNT", error: "Budget must be positive." };
3440
- }
3441
- if (terms.amountUsdc > MAX_JOB_USDC) {
3442
- return {
3443
- valid: false,
3444
- code: "INVALID_AMOUNT",
3445
- error: `Open jobs cap at ${MAX_JOB_USDC} USDC (v1).`
3446
- };
3447
- }
3448
- if (!SHA256_HEX_RE.test(terms.specHash)) {
3449
- return { valid: false, code: "INVALID_INPUT", error: "specHash must be a sha256 hex string." };
3450
- }
3451
- const now = Date.now();
3452
- if (terms.openUntilMs <= now) {
3453
- return { valid: false, code: "INVALID_INPUT", error: "openUntil must be in the future." };
3454
- }
3455
- if (terms.openUntilMs > now + MAX_OPEN_WINDOW_MS) {
3456
- return { valid: false, code: "INVALID_INPUT", error: "Openings can stay claimable at most 30 days." };
3457
- }
3458
- if (terms.slaMs <= 0) {
3459
- return { valid: false, code: "INVALID_INPUT", error: "Delivery window must be positive." };
3460
- }
3461
- return { valid: true };
3462
- }
3463
- async function buildCreateOpeningTx({
3464
- client,
3465
- buyer,
3466
- terms
3467
- }) {
3468
- const pf = preflightCreateOpening(terms);
3469
- if (!pf.valid) throw new T2000Error(pf.code ?? "INVALID_INPUT", pf.error ?? "Invalid opening.");
3470
- const rawAmount = BigInt(Math.floor(terms.amountUsdc * 10 ** USDC_DECIMALS));
3471
- const tx = new Transaction();
3472
- const { coin } = await selectAndSplitCoin(tx, client, validateAddress(buyer), USDC_TYPE, rawAmount, {
3473
- allowSwapAll: false
3474
- });
3475
- tx.moveCall({
3476
- target: `${A2A_ESCROW_OPENING_PACKAGE_ID}::${MODULE2}::create_open`,
3477
- typeArguments: [USDC_TYPE],
3478
- arguments: [
3479
- coin,
3480
- tx.pure.vector("u8", hexToBytes3(terms.specHash)),
3481
- tx.pure.u64(terms.openUntilMs),
3482
- tx.pure.u64(terms.slaMs),
3483
- tx.pure.u64(terms.reviewWindowMs),
3484
- tx.pure.u64(terms.rejectSplitBps),
3485
- tx.pure.u8(OPENING_CLAIM_POLICY_ANY_ACTIVE),
3486
- feeConfigArg2(tx),
3487
- tx.object(CLOCK_ID3)
3488
- ]
3489
- });
3490
- return tx;
3491
- }
3492
- function buildClaimOpeningTx({
3493
- openingId,
3494
- registryId
3495
- }) {
3496
- const tx = new Transaction();
3497
- tx.moveCall({
3498
- target: `${A2A_ESCROW_OPENING_PACKAGE_ID}::${MODULE2}::claim`,
3499
- typeArguments: [USDC_TYPE],
3500
- arguments: [
3501
- tx.object(openingId),
3502
- tx.object(registryId),
3503
- feeConfigArg2(tx),
3504
- tx.object(CLOCK_ID3)
3505
- ]
3506
- });
3507
- return tx;
3508
- }
3509
- function openingCall(openingId, fn) {
3510
- const tx = new Transaction();
3511
- tx.moveCall({
3512
- target: `${A2A_ESCROW_OPENING_PACKAGE_ID}::${MODULE2}::${fn}`,
3513
- typeArguments: [USDC_TYPE],
3514
- arguments: [tx.object(openingId), feeConfigArg2(tx), tx.object(CLOCK_ID3)]
3515
- });
3516
- return tx;
3517
- }
3518
- function buildCancelOpeningTx(openingId) {
3519
- return openingCall(openingId, "cancel_open");
3520
- }
3521
- function buildRefundUnclaimedTx(openingId) {
3522
- return openingCall(openingId, "refund_unclaimed");
3523
- }
3524
- function bytesToHex3(bytes) {
3525
- return `0x${Array.from(bytes).map((b) => b.toString(16).padStart(2, "0")).join("")}`;
3526
- }
3527
- async function getOpening(client, openingId) {
3528
- const resp = await client.core.getObject({ objectId: openingId, include: { json: true } }).catch(() => null);
3529
- const objType = resp?.object?.type ?? "";
3530
- const json = resp?.object?.json;
3531
- if (!json || !objType.includes(`::${MODULE2}::Opening<`)) {
3532
- return null;
3533
- }
3534
- return {
3535
- id: openingId,
3536
- buyer: String(json.buyer),
3537
- amountUsdc: Number(json.amount) / 10 ** USDC_DECIMALS,
3538
- feeBps: Number(json.fee_bps ?? 0),
3539
- specHash: bytesToHex3(json.spec_hash ?? []),
3540
- openUntilMs: Number(json.open_until_ms),
3541
- slaMs: Number(json.sla_ms),
3542
- reviewWindowMs: Number(json.review_window_ms),
3543
- rejectSplitBps: Number(json.reject_split_bps),
3544
- claimPolicy: Number(json.claim_policy ?? 0),
3545
- createdAtMs: Number(json.created_at_ms ?? 0)
3546
- };
3547
- }
3548
-
3549
3562
  // src/commerce.ts
3550
3563
  var DEFAULT_COMMERCE_API_BASE = "https://api.t2000.ai/v1";
3551
3564
  async function commerceFetchJson(url, init) {
@@ -4552,6 +4565,6 @@ async function buildDirectPoolSwapTx(args) {
4552
4565
  return tx;
4553
4566
  }
4554
4567
 
4555
- export { A2A_ESCROW_FEE_CONFIG_ID, A2A_ESCROW_OPENING_PACKAGE_ID, A2A_ESCROW_PACKAGE_ID, AGENT_CAPITAL_PACKAGE_ID, AGENT_CAPITAL_PUBLISHED_AT, AGENT_ID_PARENT, AGENT_ID_PARENT_NAME, AGENT_ID_PARENT_NFT_ID, AGENT_POOL_TICK_SPACING, AGENT_TOKEN_DECIMALS, AGENT_TOKEN_LP_ALLOCATION, AGENT_TOKEN_TOTAL_SUPPLY, AGENT_TOKEN_TREASURY_ALLOCATION, AUDRIC_PARENT, AUDRIC_PARENT_NAME, AUDRIC_PARENT_NFT_ID, CAPITAL_REGISTRY_ID, CAPITAL_REGISTRY_VERSION, CETUS_CLMM_PACKAGE_ID, CETUS_GLOBAL_CONFIG_ID, CETUS_INTEGRATE_PUBLISHED_AT, CETUS_POOLS_ID, CETUS_POSITION_TYPE, CETUS_USDC_SUI_POOL, CLOCK_ID, COIN_REGISTRY, DEFAULT_API_BASE, DEFAULT_COMMERCE_API_BASE, DEFAULT_GRPC_URL, DEFAULT_NETWORK, ETH_TYPE, GASLESS_MIN_STABLE_AMOUNT, GASLESS_STABLE_TYPES, GAS_RESERVE_MIN, IKA_TYPE, InvalidAddressError, JOB_STATES, KNOWN_TARGETS, KeypairSigner, LABEL_PATTERNS, LOFI_TYPE, LimitEnforcer, LimitExceededError, MANIFEST_TYPE, MAX_DELIVER_HORIZON_MS, MAX_JOB_USDC, MAX_OPEN_WINDOW_MS, MAX_REVIEW_WINDOW_MS, MIN_LP_USDC, MIST_PER_SUI, NAVX_TYPE, OPENING_CLAIM_POLICY_ANY_ACTIVE, OPERATION_ASSETS, OVERLAY_FEE_RATE, PREFLIGHT_MAX_AMOUNT, PREFLIGHT_OK, SENDABLE_ASSETS, SPONSORED_PYTH_DEPENDENT_PROVIDERS, STABLE_ASSETS, SUINS_NAME_REGEX, SUI_ADDRESS_REGEX, SUI_ADDRESS_STRICT_REGEX, SUI_DECIMALS, SUI_TYPE, SUPPORTED_ASSETS, SYMBOL_BLOCKLIST, SuinsNotRegisteredError, SuinsRpcError, T2000, T2000Error, T2000_OVERLAY_FEE_WALLET, TOKEN_MAP, USDC_DECIMALS, USDC_TYPE, USDE_TYPE, USDSUI_TYPE, USDT_TYPE, WAL_TYPE, WBTC_TYPE, WRITE_APPENDER_REGISTRY, ZkLoginSigner, addSendToTx, addSwapToTx, approxUsdValue, assertAllowedAsset, assertBuyerRequirements, assertLimitConfig, buildAddLeafTx, buildAgentCoinModule, buildCancelOpeningTx, buildClaimOpeningTx, buildCreateJobTx, buildCreateOpeningTx, buildDeliverJobTx, buildDirectPoolSwapTx, buildPublishAgentCoinTx, buildRefundJobTx, buildRefundUnclaimedTx, buildRejectJobTx, buildReleaseJobTx, buildRevokeLeafTx, buildSendTx, buildSwapTx, buildTokenizeTx, cancelOpenJob, chatCompletion, chatCompletionStream, checkPositiveAmount, checkSuiAddress, claimOpenJob, classifyAction, classifyLabel, classifyTransaction, clearLimits, composeTx, dailySpentToday, deriveAllowedAddressesFromPtb, deserializeCetusRoute, displayHandle, executeTx, exportPrivateKey, extractAllUserLegs, extractTransferDetails, extractTxCommands, extractTxSender, fallbackLabel, fetchAllCoins, fetchService, findSwapRoute, formatAssetAmount, formatSui, formatUsd, fullHandle, generateKeypair, getAddress, getCoinMeta, getDecimals, getDecimalsForCoinType, getJob, getJobSpec, getLimits, getOpenJob, getOpening, getSponsoredSwapProviders, getSuiClient, getSuiGrpcClient, getSwapQuote, hasLimits, isAllowedAsset, isCetusRouteFresh, isInRegistry, jobActionsFor, keypairFromPrivateKey, listModels, listOpenJobs, listServices, loadKey, looksLikeSuiNs, mapMoveAbortCode, mapWalletError, mistToSui, normalizeAddressInput, normalizeAsset, normalizeCoinType, parseMppSuiChallenge, parseSuiRpcTx, payWithMpp, postOpenJob, preflightCreateJob, preflightCreateOpening, preflightFail, preflightPay, preflightSend, preflightSwap, putJobSpec, queryBalance, queryHistory, queryTransaction, rawToStable, rawToUsdc, readLimitsFile, recordDailySpend, refineLendingLabel, refundOpenJob, resolveAddressToSuinsViaRpc, resolveSuinsViaRpc, resolveSymbol, resolveTokenType, saveBech32, saveKey, selectAndSplitCoin, selectSuiCoin, serializeCetusRoute, setLimits, simulateTransaction, stableToRaw, suiToMist, throwIfSimulationFailed, truncateAddress, usdcToRaw, validateAddress, validateAgentCoinParams, validateLabel, verifyCetusRouteCoinMatch, verifyJobForSeller, verifyReceipt, walletExists, writeLimitsFile };
4568
+ export { A2A_ESCROW_FEE_CONFIG_ID, A2A_ESCROW_OPENING_PACKAGE_ID, A2A_ESCROW_PACKAGE_ID, A2A_ESCROW_PACKAGE_V2_ID, A2A_ESCROW_PACKAGE_V3_ID, AGENT_CAPITAL_PACKAGE_ID, AGENT_CAPITAL_PUBLISHED_AT, AGENT_ID_PARENT, AGENT_ID_PARENT_NAME, AGENT_ID_PARENT_NFT_ID, AGENT_POOL_TICK_SPACING, AGENT_TOKEN_DECIMALS, AGENT_TOKEN_LP_ALLOCATION, AGENT_TOKEN_TOTAL_SUPPLY, AGENT_TOKEN_TREASURY_ALLOCATION, AUDRIC_PARENT, AUDRIC_PARENT_NAME, AUDRIC_PARENT_NFT_ID, CAPITAL_REGISTRY_ID, CAPITAL_REGISTRY_VERSION, CETUS_CLMM_PACKAGE_ID, CETUS_GLOBAL_CONFIG_ID, CETUS_INTEGRATE_PUBLISHED_AT, CETUS_POOLS_ID, CETUS_POSITION_TYPE, CETUS_USDC_SUI_POOL, CLOCK_ID, COIN_REGISTRY, DEFAULT_API_BASE, DEFAULT_COMMERCE_API_BASE, DEFAULT_GRPC_URL, DEFAULT_NETWORK, ETH_TYPE, GASLESS_MIN_STABLE_AMOUNT, GASLESS_STABLE_TYPES, GAS_RESERVE_MIN, IKA_TYPE, InvalidAddressError, JOB_STATES, KNOWN_TARGETS, KeypairSigner, LABEL_PATTERNS, LOFI_TYPE, LimitEnforcer, LimitExceededError, MANIFEST_TYPE, MAX_DELIVER_HORIZON_MS, MAX_JOB_USDC, MAX_OPEN_WINDOW_MS, MAX_REVIEW_WINDOW_MS, MIN_LP_USDC, MIST_PER_SUI, NAVX_TYPE, OPENING_CLAIM_POLICY_ANY_ACTIVE, OPERATION_ASSETS, OVERLAY_FEE_RATE, PREFLIGHT_MAX_AMOUNT, PREFLIGHT_OK, SENDABLE_ASSETS, SPONSORED_PYTH_DEPENDENT_PROVIDERS, STABLE_ASSETS, SUINS_NAME_REGEX, SUI_ADDRESS_REGEX, SUI_ADDRESS_STRICT_REGEX, SUI_DECIMALS, SUI_TYPE, SUPPORTED_ASSETS, SYMBOL_BLOCKLIST, SuinsNotRegisteredError, SuinsRpcError, T2000, T2000Error, T2000_OVERLAY_FEE_WALLET, TOKEN_MAP, USDC_DECIMALS, USDC_TYPE, USDE_TYPE, USDSUI_TYPE, USDT_TYPE, WAL_TYPE, WBTC_TYPE, WRITE_APPENDER_REGISTRY, ZkLoginSigner, addSendToTx, addSwapToTx, approxUsdValue, assertAllowedAsset, assertBuyerRequirements, assertLimitConfig, buildAddLeafTx, buildAgentCoinModule, buildCancelOpeningTx, buildClaimOpeningTx, buildCreateJobTx, buildCreateOpeningTx, buildDeclineJobTx, buildDeliverJobTx, buildDirectPoolSwapTx, buildPublishAgentCoinTx, buildRefundJobTx, buildRefundUnclaimedTx, buildRejectJobTx, buildReleaseJobTx, buildRevokeLeafTx, buildSendTx, buildSwapTx, buildTokenizeTx, cancelOpenJob, chatCompletion, chatCompletionStream, checkPositiveAmount, checkSuiAddress, claimOpenJob, classifyAction, classifyLabel, classifyTransaction, clearLimits, composeTx, dailySpentToday, deriveAllowedAddressesFromPtb, deserializeCetusRoute, displayHandle, executeTx, exportPrivateKey, extractAllUserLegs, extractTransferDetails, extractTxCommands, extractTxSender, fallbackLabel, fetchAllCoins, fetchService, findSwapRoute, formatAssetAmount, formatSui, formatUsd, fullHandle, generateKeypair, getAddress, getCoinMeta, getDecimals, getDecimalsForCoinType, getJob, getJobSpec, getLimits, getOpenJob, getOpening, getSponsoredSwapProviders, getSuiClient, getSuiGrpcClient, getSwapQuote, hasLimits, isAllowedAsset, isCetusRouteFresh, isInRegistry, jobActionsFor, keypairFromPrivateKey, listModels, listOpenJobs, listServices, loadKey, looksLikeSuiNs, mapMoveAbortCode, mapWalletError, mistToSui, normalizeAddressInput, normalizeAsset, normalizeCoinType, parseMppSuiChallenge, parseSuiRpcTx, payWithMpp, postOpenJob, preflightCreateJob, preflightCreateOpening, preflightFail, preflightPay, preflightSend, preflightSwap, putJobSpec, queryBalance, queryHistory, queryTransaction, rawToStable, rawToUsdc, readLimitsFile, recordDailySpend, refineLendingLabel, refundOpenJob, resolveAddressToSuinsViaRpc, resolveSuinsViaRpc, resolveSymbol, resolveTokenType, saveBech32, saveKey, selectAndSplitCoin, selectSuiCoin, serializeCetusRoute, setLimits, simulateTransaction, stableToRaw, suiToMist, throwIfSimulationFailed, truncateAddress, usdcToRaw, validateAddress, validateAgentCoinParams, validateLabel, verifyCetusRouteCoinMatch, verifyJobForSeller, verifyReceipt, walletExists, writeLimitsFile };
4556
4569
  //# sourceMappingURL=index.js.map
4557
4570
  //# sourceMappingURL=index.js.map