x402-proxy 0.10.12 → 0.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -3
- package/dist/{Credential-0iRzpJkF.js → Mcp-CKylLH8N.js} +209 -211
- package/dist/accounts-D5u2KBgr.js +4 -0
- package/dist/{hashTypedData-CtEdfx4y.js → accounts-D9KsVVpJ.js} +228 -3
- package/dist/{auth-J9VuNMoG.js → auth-CaCZiNCk.js} +3 -3
- package/dist/bin/cli.js +46 -51
- package/dist/{decodeFunctionData-JPOUdvil.js → call-CNxk2xpg.js} +2084 -144
- package/dist/{decodeFunctionData-DuFcwhC_.js → call-DdUUzMfg.js} +11 -16
- package/dist/{ccip-C6CQOJYv.js → ccip-Cc1Fdazz.js} +1 -1
- package/dist/{ccip-Bx-zoUCJ.js → ccip-IumNC20V.js} +13 -3
- package/dist/{ccip-C2k1DD1T.js → ccip-JDVib6lf.js} +1 -1
- package/dist/{ccip-RZzsZ5Mv.js → ccip-RzF9aX_O.js} +3 -4
- package/dist/{chain-CafcHffR.js → chain-C_3Km9Dx.js} +1 -1
- package/dist/{client-Bcl2uC6u.js → client-C2DwSbYN.js} +1 -2
- package/dist/{Sse-DGR-tH7K.js → client-DqtxTnu6.js} +10249 -6224
- package/dist/client-DuqEc8Iw.js +3 -0
- package/dist/{client-DZV1cVsW.js → client-uAaF6lv2.js} +2 -2
- package/dist/{derive-DNUl8LU9.js → config-cyNyKO4-.js} +1024 -919
- package/dist/{dist-DM5_F3r5.js → dist-CFt2UZ4W.js} +1 -1
- package/dist/{dist-DxJCYyL5.js → dist-Cwt2qrTK.js} +2 -2
- package/dist/{helpers-ChcFbdC0.js → helpers-DebIs_21.js} +2 -2
- package/dist/{sendRawTransactionSync-DvSkhZtW.js → http-J0KYM-2Y.js} +2186 -169
- package/dist/index.d.ts +0 -1
- package/dist/index.js +30107 -771
- package/dist/{index.node-l8K03uWn.js → index.node-xc-jRJ78.js} +1 -1
- package/dist/{localBatchGatewayRequest-DOdQ9bR7.js → localBatchGatewayRequest-0gr8vzH3.js} +14 -2
- package/dist/{localBatchGatewayRequest-DQkbZaSy.js → localBatchGatewayRequest-CBsFXIAU.js} +2 -2
- package/dist/{localBatchGatewayRequest-C-RPJyDO.js → localBatchGatewayRequest-CPqqSJcB.js} +2 -2
- package/dist/{schemas-BxMFYNbH.js → schemas-DzZjufD1.js} +1 -1
- package/dist/{secp256k1-BZpiyffY.js → secp256k1-Bp7LcNvI.js} +2 -7
- package/dist/secp256k1-BsaSkXlH.js +2 -0
- package/dist/{secp256k1-BjenrLl5.js → secp256k1-BwSAYyif.js} +2 -2
- package/dist/secp256k1-CHAXu2gP.js +3 -0
- package/dist/{server-D2apWWY9.js → server-Dbsk9dql.js} +2 -2
- package/dist/setup-BdSfEdx4.js +3 -0
- package/dist/{setup-BY4J49Lv.js → setup-C10O8N36.js} +16 -33
- package/dist/{hmac-59IlS_by.js → sha2-XLg3s2a9.js} +81 -81
- package/dist/{sha256-FAs0qeni.js → sha256-DCLdwsRU.js} +1 -1
- package/dist/{sha3-DbMJRJ3C.js → sha3-03id956K.js} +1 -1
- package/dist/{sha3-CYkWM8Xa.js → sha3-VSia5eGE.js} +1 -1
- package/dist/{sse-qIEKrJEZ.js → sse-kba68iqF.js} +2 -2
- package/dist/status-B2xUewrq.js +3 -0
- package/dist/{status-CD_fCzGf.js → status-DjZdIeES.js} +2 -3
- package/dist/{stdio-BfDjLLnd.js → stdio-CdmkLt8r.js} +3 -3
- package/dist/{streamableHttp-BkayeoEQ.js → streamableHttp-DRntYTFN.js} +2 -2
- package/dist/{types-BmyZIQ8G.js → types-BQ17ZF7g.js} +1 -1
- package/dist/{types-DlqDf-zE.js → types-DH9rDVeP.js} +1 -1
- package/dist/{utils-SeGHMW9O.js → utils-psFtUKLa.js} +53 -53
- package/dist/wallet-BsCgqUun.js +3 -0
- package/dist/{wallet-C4RiduwM.js → wallet-CUCoLEqs.js} +179 -147
- package/package.json +1 -1
- package/dist/Mcp-CSyD7Hxz.js +0 -10
- package/dist/Sse-C-KDPYh0.js +0 -16482
- package/dist/accounts-DsuvWwph.js +0 -232
- package/dist/accounts-DzvAlQRn.js +0 -5
- package/dist/accounts-IG-Cmrwy.js +0 -229
- package/dist/chain-DwfP5RGZ.js +0 -1968
- package/dist/chunk-DBEY4PJZ.js +0 -16
- package/dist/client-1XQsO-Eh.js +0 -5152
- package/dist/client-Co7Fg1lv.js +0 -6388
- package/dist/config-BUQsit4s.js +0 -3
- package/dist/config-DR1Fs_wL.js +0 -6600
- package/dist/config-rvKA3SYT.js +0 -96
- package/dist/hashTypedData-BHmP9dBd.js +0 -859
- package/dist/http-BAtucMbS.js +0 -2060
- package/dist/isAddressEqual-BLrd1Hg1.js +0 -9
- package/dist/isAddressEqual-DsAqfQOD.js +0 -10
- package/dist/parseUnits-CApwcKSD.js +0 -49
- package/dist/parseUnits-cMO2udMe.js +0 -48
- package/dist/secp256k1-CLPUX17u.js +0 -3
- package/dist/setup-wMOAgrsN.js +0 -3
- package/dist/status-_TcPMyzr.js +0 -3
- package/dist/tempo-BcTkftHK.js +0 -17
- package/dist/tempo-Bs_aydgm.js +0 -18
- package/dist/wallet-BymEHYms.js +0 -3
- /package/dist/{api-CUzmQvTQ.js → api-B5mo8tpE.js} +0 -0
- /package/dist/{dist-C2YO6HSQ.js → dist-CvV4mGO6.js} +0 -0
- /package/dist/{index.node-DPDV8w2j.js → index.node-DCvOPMK7.js} +0 -0
- /package/dist/{utils-BYjkXZDF.js → utils-B1qOlJzL.js} +0 -0
|
@@ -1,20 +1,16 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import { i as __toESM } from "./chunk-DjEMn6fM.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import { B as
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import { t as
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import
|
|
12
|
-
import "./localBatchGatewayRequest-
|
|
13
|
-
import { l as
|
|
14
|
-
import { t as secp256k1 } from "./secp256k1-BjenrLl5.js";
|
|
15
|
-
import { d as loadWalletFile, o as getHistoryPath } from "./config-rvKA3SYT.js";
|
|
16
|
-
import { $ as UnknownNodeError$1, $t as encodeAbiParameters, A as slice$4, An as DecodeLogTopicsMismatch$1, At as CallExecutionError, B as toNumber, Bn as InvalidAbiItemError$1, Bt as TransactionReceiptRevertedError, C as fromBoolean, Cn as AbiDecodingDataSizeTooSmallError, Ct as UnsupportedNonOptionalCapabilityError, D as padLeft, Dn as AbiEventSignatureNotFoundError, Dt as HttpRequestError, E as fromString$2, En as AbiEventSignatureEmptyTopicsError, Et as WalletConnectSessionSettlementError, F as fromString$1, Fn as parseStructs$1, G as decodeFunctionResult$1, Gt as stringify$1, H as trimLeft, Hn as modifiers, Ht as prettyPrint, I as size$4, In as parseAbiParameter, It as InvalidSerializableTransactionError, J as maxUint256$1, Jt as createCursor, K as isAddressEqual$1, L as slice$3, Ln as parseSignature$1, Lt as TransactionExecutionError, M as validate$5, Mn as size$2, Mt as ContractFunctionRevertedError$1, N as from$9, Nn as isHex$1, Nt as ContractFunctionZeroDataError, O as padRight, On as BytesSizeMismatchError$1, Ot as RpcRequestError, P as fromHex$1, Pn as formatAbiItem$1, Pt as RawContractError$1, Q as getNodeError$1, Qt as getAbiItem, R as toBigInt, Rn as splitParameters, Rt as TransactionNotFoundError$1, S as from$10, Sn as trim$1, St as UnsupportedChainIdError, T as fromNumber, Tn as AbiEventNotFoundError, Tt as UserRejectedRequestError, U as stringify$2, Un as formatAbiItem$2, Ut as formatGwei, V as toString, Vn as isStructSignature$1, Vt as WaitForTransactionReceiptTimeoutError$1, W as BaseError$3, Wn as formatAbiParameters, Wt as formatEther, X as formatTransactionRequest$1, Xt as encodeFunctionData$1, Y as serializeStateOverride$1, Yt as PositionOutOfBoundsError$1, Z as extract$2, Zt as parseAccount$1, _ as universalResolverResolveAbi$1, _n as stringToHex, _t as SwitchChainError, a as withResolvers$1, an as isAddress$1, at as InternalRpcError, b as IntegerOutOfRangeError, bn as hexToBool, bt as UnknownBundleIdError, c as encodeDeployData, cn as LruMap$1, ct as InvalidRequestRpcError, d as multicall3Bytecode, dn as keccak256$3, dt as MethodNotFoundRpcError, en as bytesRegex$1, et as AtomicReadyWalletRejectedUpgradeError, f as addressResolverAbi$1, fn as hexToBytes, ft as MethodNotSupportedRpcError, g as textResolverAbi$1, gn as numberToHex$1, gt as ResourceUnavailableRpcError, h as multicall3Abi$1, hn as bytesToHex$1, ht as ResourceNotFoundRpcError, i as createBatchScheduler, in as concatHex$1, it as DuplicateIdError, j as toNumber$1, jn as BaseError$2, jt as ContractFunctionExecutionError, k as size$3, kn as DecodeLogDataMismatch$1, kt as TimeoutError, l as deploylessCallViaBytecodeBytecode$1, ln as InvalidAddressError$2, lt as JsonRpcVersionUnsupportedError, m as erc6492SignatureValidatorAbi, mn as toBytes$1, mt as ProviderDisconnectedError, nn as slice$2, nt as BundleTooLargeError, o as getCallError$1, on as checksumAddress, ot as InvalidInputRpcError$1, p as erc1271Abi, pn as stringToBytes$1, pt as ParseRpcError, q as assertRequest$1, qt as decodeAbiParameters, r as call$1, rn as concat$2, rt as ChainDisconnectedError, s as getChainContractAddress$1, sn as getAddress$1, st as InvalidParamsRpcError, tn as integerRegex$1, tt as AtomicityNotSupportedError, u as erc6492SignatureValidatorByteCode, un as toEventSelector, ut as LimitExceededRpcError, v as universalResolverReverseAbi$1, vn as toHex$1, vt as TransactionRejectedRpcError, w as fromBytes$1, wn as AbiDecodingZeroDataError$1, wt as UnsupportedProviderMethodError, x as concat$3, xn as hexToNumber$1, xt as UnknownRpcError, y as toRpc$1, yn as hexToBigInt$1, yt as UnauthorizedProviderError, z as toBoolean, zn as InvalidAbiParametersError, zt as TransactionReceiptNotFoundError$1 } from "./localBatchGatewayRequest-DQkbZaSy.js";
|
|
17
|
-
import { G as mainnet, H as setTransactionMessageFeePayer, Jt as transformEncoder, K as AccountRole, St as getAddressEncoder, U as setTransactionMessageLifetimeUsingBlockhash, V as setTransactionMessageComputeUnitPrice, X as upgradeRoleToSigner, Z as pipe, Zo as SolanaError, _t as address, c as isTransactionSigner, f as createDefaultRpcTransport, gt as getU8Encoder, ht as getU64Encoder, j as createTransactionMessage, k as appendTransactionMessageInstructions, l as partiallySignTransactionMessageWithSigners, na as SOLANA_ERROR__PROGRAM_CLIENTS__RESOLVED_INSTRUCTION_INPUT_MUST_BE_NON_NULL, ot as getStructEncoder, p as createSolanaRpcFromTransport, ts as isSolanaError, wt as getProgramDerivedAddress, x as getBase64EncodedWireTransaction, z as prependTransactionMessageInstruction } from "./index.node-DPDV8w2j.js";
|
|
3
|
+
import { _ as base58, h as deriveSolanaKeypair, m as deriveEvmKeypair, o as getHistoryPath, u as loadWalletFile, v as ed25519, x as buildCommand, y as require_picocolors } from "./config-cyNyKO4-.js";
|
|
4
|
+
import { $ as BaseError, D as fromString, Jt as encodeFunctionData, M as slice, Qt as parseStructs, R as validate$3, S as concat, Ut as RawContractError, Vt as ContractFunctionRevertedError, _ as universalResolverReverseAbi, a as getChainContractAddress, at as formatTransactionRequest, ct as getNodeError, en as parseSignature, et as decodeFunctionResult, g as universalResolverResolveAbi, h as textResolverAbi, ht as InvalidInputRpcError, i as getCallError, in as isStructSignature, m as multicall3Abi, nt as assertRequest, on as formatAbiItem, r as withResolvers, rn as InvalidAbiItemError, rt as serializeStateOverride, s as deploylessCallViaBytecodeBytecode, st as extract$1, t as call, tt as isAddressEqual, u as addressResolverAbi, v as toRpc } from "./call-DdUUzMfg.js";
|
|
5
|
+
import { $ as parseEventLogs$1, B as formatTransactionReceipt$1, C as encode$4, Ct as getAction$1, F as defineChain, G as uninstallFilter$1, H as withRetry$1, J as poll$1, K as getFilterChanges$1, L as getCode$1, M as keccak256$1, Q as getLogs$1, R as createClient$1, St as encodeEventTopics$1, U as sendRawTransaction$1, W as watchContractEvent$1, X as readContract$1, Y as observe$1, Z as getContractEvents$1, _t as BlockNotFoundError$1, a as getTransactionReceipt$1, at as fillTransaction$1, bt as createContractEventFilter$1, ct as getTransactionCount$1, dt as getGasPrice$1, et as decodeEventLog$1, ft as getBlock$1, gt as formatTransaction$1, ht as defineTransaction, i as multicall$1, it as prepareTransactionRequest$1, k as validate$4, lt as estimateFeesPerGas$1, mt as formatBlock$1, nt as estimateGas$1, ot as getChainId$1, pt as defineBlock, q as getBlockNumber$1, r as verifyHash$1, t as http$1, tt as formatLog$1, ut as estimateMaxPriorityFeePerGas$1, xt as createFilterRequestScope$1, yt as getContractError$1, z as defineTransactionReceipt } from "./http-J0KYM-2Y.js";
|
|
6
|
+
import { t as keccak_256 } from "./sha3-VSia5eGE.js";
|
|
7
|
+
import { t as sha256$1 } from "./sha256-DCLdwsRU.js";
|
|
8
|
+
import { t as secp256k1 } from "./secp256k1-BwSAYyif.js";
|
|
9
|
+
import { $ as toBytes, B as slice$1, D as TransactionReceiptRevertedError, E as TransactionReceiptNotFoundError, F as parseAccount, G as isAddress, M as stringify, Mt as BaseError$1, Nt as size$1, O as WaitForTransactionReceiptTimeoutError, Ot as DecodeLogDataMismatch, Pt as isHex, Q as stringToBytes, T as TransactionNotFoundError, U as concat$1, W as concatHex, X as keccak256$2, Y as InvalidAddressError$1, at as hexToBigInt, ct as trim, et as bytesToHex, gt as AbiDecodingZeroDataError, kt as DecodeLogTopicsMismatch, q as getAddress, rt as toHex, st as hexToNumber, tt as numberToHex, v as UnknownNodeError } from "./chain-C_3Km9Dx.js";
|
|
10
|
+
import { E as toRlp$1, l as hashTypedData$1, m as serializeTransaction$1, p as hashMessage$1, t as privateKeyToAccount } from "./accounts-D9KsVVpJ.js";
|
|
11
|
+
import "./localBatchGatewayRequest-0gr8vzH3.js";
|
|
12
|
+
import { $ as UnknownNodeError$1, $t as encodeAbiParameters, A as slice$4, An as DecodeLogTopicsMismatch$1, At as CallExecutionError, B as toNumber, Bn as InvalidAbiItemError$1, Bt as TransactionReceiptRevertedError$1, C as fromBoolean, Cn as AbiDecodingDataSizeTooSmallError, Ct as UnsupportedNonOptionalCapabilityError, D as padLeft, Dn as AbiEventSignatureNotFoundError, Dt as HttpRequestError, E as fromString$2, En as AbiEventSignatureEmptyTopicsError, Et as WalletConnectSessionSettlementError, F as fromString$1, Fn as parseStructs$1, G as decodeFunctionResult$1, Gt as stringify$1, H as trimLeft, Hn as modifiers, Ht as prettyPrint, I as size$4, In as parseAbiParameter, It as InvalidSerializableTransactionError, J as maxUint256$1, Jt as createCursor, K as isAddressEqual$1, L as slice$3, Ln as parseSignature$1, Lt as TransactionExecutionError, M as validate$5, Mn as size$2, Mt as ContractFunctionRevertedError$1, N as from$9, Nn as isHex$1, Nt as ContractFunctionZeroDataError, O as padRight, On as BytesSizeMismatchError$1, Ot as RpcRequestError, P as fromHex$1, Pn as formatAbiItem$1, Pt as RawContractError$1, Q as getNodeError$1, Qt as getAbiItem, R as toBigInt, Rn as splitParameters, Rt as TransactionNotFoundError$1, S as from$10, Sn as trim$1, St as UnsupportedChainIdError, T as fromNumber, Tn as AbiEventNotFoundError, Tt as UserRejectedRequestError, U as stringify$2, Un as formatAbiItem$2, Ut as formatGwei, V as toString, Vn as isStructSignature$1, Vt as WaitForTransactionReceiptTimeoutError$1, W as BaseError$3, Wn as formatAbiParameters, Wt as formatEther, X as formatTransactionRequest$1, Xt as encodeFunctionData$1, Y as serializeStateOverride$1, Yt as PositionOutOfBoundsError$1, Z as extract$2, Zt as parseAccount$1, _ as universalResolverResolveAbi$1, _n as stringToHex, _t as SwitchChainError, a as withResolvers$1, an as isAddress$1, at as InternalRpcError, b as IntegerOutOfRangeError, bn as hexToBool, bt as UnknownBundleIdError, c as encodeDeployData, cn as LruMap$1, ct as InvalidRequestRpcError, d as multicall3Bytecode, dn as keccak256$3, dt as MethodNotFoundRpcError, en as bytesRegex$1, et as AtomicReadyWalletRejectedUpgradeError, f as addressResolverAbi$1, fn as hexToBytes, ft as MethodNotSupportedRpcError, g as textResolverAbi$1, gn as numberToHex$1, gt as ResourceUnavailableRpcError, h as multicall3Abi$1, hn as bytesToHex$1, ht as ResourceNotFoundRpcError, i as createBatchScheduler, in as concatHex$1, it as DuplicateIdError, j as toNumber$1, jn as BaseError$2, jt as ContractFunctionExecutionError, k as size$3, kn as DecodeLogDataMismatch$1, kt as TimeoutError, l as deploylessCallViaBytecodeBytecode$1, ln as InvalidAddressError$2, lt as JsonRpcVersionUnsupportedError, m as erc6492SignatureValidatorAbi, mn as toBytes$1, mt as ProviderDisconnectedError, nn as slice$2, nt as BundleTooLargeError, o as getCallError$1, on as checksumAddress, ot as InvalidInputRpcError$1, p as erc1271Abi, pn as stringToBytes$1, pt as ParseRpcError, q as assertRequest$1, qt as decodeAbiParameters, r as call$1, rn as concat$2, rt as ChainDisconnectedError, s as getChainContractAddress$1, sn as getAddress$1, st as InvalidParamsRpcError, tn as integerRegex$1, tt as AtomicityNotSupportedError, u as erc6492SignatureValidatorByteCode, un as toEventSelector, ut as LimitExceededRpcError, v as universalResolverReverseAbi$1, vn as toHex$1, vt as TransactionRejectedRpcError, w as fromBytes$1, wn as AbiDecodingZeroDataError$1, wt as UnsupportedProviderMethodError, x as concat$3, xn as hexToNumber$1, xt as UnknownRpcError, y as toRpc$1, yn as hexToBigInt$1, yt as UnauthorizedProviderError, z as toBoolean, zn as InvalidAbiParametersError, zt as TransactionReceiptNotFoundError$1 } from "./localBatchGatewayRequest-CBsFXIAU.js";
|
|
13
|
+
import { G as mainnet, H as setTransactionMessageFeePayer, Jt as transformEncoder, K as AccountRole, St as getAddressEncoder, U as setTransactionMessageLifetimeUsingBlockhash, V as setTransactionMessageComputeUnitPrice, X as upgradeRoleToSigner, Z as pipe, Zo as SolanaError, _t as address, c as isTransactionSigner, f as createDefaultRpcTransport, gt as getU8Encoder, ht as getU64Encoder, j as createTransactionMessage, k as appendTransactionMessageInstructions, l as partiallySignTransactionMessageWithSigners, na as SOLANA_ERROR__PROGRAM_CLIENTS__RESOLVED_INSTRUCTION_INPUT_MUST_BE_NON_NULL, ot as getStructEncoder, p as createSolanaRpcFromTransport, ts as isSolanaError, wt as getProgramDerivedAddress, x as getBase64EncodedWireTransaction, z as prependTransactionMessageInstruction } from "./index.node-DCvOPMK7.js";
|
|
18
14
|
import { dirname } from "node:path";
|
|
19
15
|
import { appendFileSync, existsSync, mkdirSync, readFileSync, statSync, writeFileSync } from "node:fs";
|
|
20
16
|
//#region packages/x402-proxy/src/lib/output.ts
|
|
@@ -7504,6 +7500,42 @@ async function verifySiweMessage$1(client, parameters) {
|
|
|
7504
7500
|
});
|
|
7505
7501
|
}
|
|
7506
7502
|
//#endregion
|
|
7503
|
+
//#region node_modules/.pnpm/viem@2.47.6_typescript@5.9.3_zod@4.3.6/node_modules/viem/_esm/actions/wallet/sendRawTransactionSync.js
|
|
7504
|
+
/**
|
|
7505
|
+
* Sends a **signed** transaction to the network synchronously,
|
|
7506
|
+
* and waits for the transaction to be included in a block.
|
|
7507
|
+
*
|
|
7508
|
+
* - Docs: https://viem.sh/docs/actions/wallet/sendRawTransactionSync
|
|
7509
|
+
* - JSON-RPC Method: [`eth_sendRawTransactionSync`](https://eips.ethereum.org/EIPS/eip-7966)
|
|
7510
|
+
*
|
|
7511
|
+
* @param client - Client to use
|
|
7512
|
+
* @param parameters - {@link SendRawTransactionParameters}
|
|
7513
|
+
* @returns The transaction receipt. {@link SendRawTransactionSyncReturnType}
|
|
7514
|
+
*
|
|
7515
|
+
* @example
|
|
7516
|
+
* import { createWalletClient, custom } from 'viem'
|
|
7517
|
+
* import { mainnet } from 'viem/chains'
|
|
7518
|
+
* import { sendRawTransactionSync } from 'viem/wallet'
|
|
7519
|
+
*
|
|
7520
|
+
* const client = createWalletClient({
|
|
7521
|
+
* chain: mainnet,
|
|
7522
|
+
* transport: custom(window.ethereum),
|
|
7523
|
+
* })
|
|
7524
|
+
*
|
|
7525
|
+
* const receipt = await sendRawTransactionSync(client, {
|
|
7526
|
+
* serializedTransaction: '0x02f850018203118080825208808080c080a04012522854168b27e5dc3d5839bab5e6b39e1a0ffd343901ce1622e3d64b48f1a04e00902ae0502c4728cbf12156290df99c3ed7de85b1dbfe20b5c36931733a33'
|
|
7527
|
+
* })
|
|
7528
|
+
*/
|
|
7529
|
+
async function sendRawTransactionSync$1(client, { serializedTransaction, throwOnReceiptRevert, timeout }) {
|
|
7530
|
+
const receipt = await client.request({
|
|
7531
|
+
method: "eth_sendRawTransactionSync",
|
|
7532
|
+
params: timeout ? [serializedTransaction, timeout] : [serializedTransaction]
|
|
7533
|
+
}, { retryCount: 0 });
|
|
7534
|
+
const formatted = (client.chain?.formatters?.transactionReceipt?.format || formatTransactionReceipt$1)(receipt);
|
|
7535
|
+
if (formatted.status === "reverted" && throwOnReceiptRevert) throw new TransactionReceiptRevertedError({ receipt: formatted });
|
|
7536
|
+
return formatted;
|
|
7537
|
+
}
|
|
7538
|
+
//#endregion
|
|
7507
7539
|
//#region node_modules/.pnpm/viem@2.47.6_typescript@5.9.3_zod@4.3.6/node_modules/viem/_esm/clients/decorators/public.js
|
|
7508
7540
|
function publicActions$1(client) {
|
|
7509
7541
|
return {
|
|
@@ -7598,6 +7630,135 @@ function createPublicClient$1(parameters) {
|
|
|
7598
7630
|
}).extend(publicActions$1);
|
|
7599
7631
|
}
|
|
7600
7632
|
//#endregion
|
|
7633
|
+
//#region node_modules/.pnpm/viem@2.47.6_typescript@5.9.3_zod@4.3.6/node_modules/viem/_esm/op-stack/contracts.js
|
|
7634
|
+
/**
|
|
7635
|
+
* Predeploy contracts for OP Stack.
|
|
7636
|
+
* @see https://github.com/ethereum-optimism/optimism/blob/develop/specs/predeploys.md
|
|
7637
|
+
*/
|
|
7638
|
+
const contracts = {
|
|
7639
|
+
gasPriceOracle: { address: "0x420000000000000000000000000000000000000F" },
|
|
7640
|
+
l1Block: { address: "0x4200000000000000000000000000000000000015" },
|
|
7641
|
+
l2CrossDomainMessenger: { address: "0x4200000000000000000000000000000000000007" },
|
|
7642
|
+
l2Erc721Bridge: { address: "0x4200000000000000000000000000000000000014" },
|
|
7643
|
+
l2StandardBridge: { address: "0x4200000000000000000000000000000000000010" },
|
|
7644
|
+
l2ToL1MessagePasser: { address: "0x4200000000000000000000000000000000000016" }
|
|
7645
|
+
};
|
|
7646
|
+
//#endregion
|
|
7647
|
+
//#region node_modules/.pnpm/viem@2.47.6_typescript@5.9.3_zod@4.3.6/node_modules/viem/_esm/op-stack/formatters.js
|
|
7648
|
+
const formatters = {
|
|
7649
|
+
block: /* @__PURE__ */ defineBlock({ format(args) {
|
|
7650
|
+
return {
|
|
7651
|
+
transactions: args.transactions?.map((transaction) => {
|
|
7652
|
+
if (typeof transaction === "string") return transaction;
|
|
7653
|
+
const formatted = formatTransaction$1(transaction);
|
|
7654
|
+
if (formatted.typeHex === "0x7e") {
|
|
7655
|
+
formatted.isSystemTx = transaction.isSystemTx;
|
|
7656
|
+
formatted.mint = transaction.mint ? hexToBigInt(transaction.mint) : void 0;
|
|
7657
|
+
formatted.sourceHash = transaction.sourceHash;
|
|
7658
|
+
formatted.type = "deposit";
|
|
7659
|
+
}
|
|
7660
|
+
return formatted;
|
|
7661
|
+
}),
|
|
7662
|
+
stateRoot: args.stateRoot
|
|
7663
|
+
};
|
|
7664
|
+
} }),
|
|
7665
|
+
transaction: /* @__PURE__ */ defineTransaction({ format(args) {
|
|
7666
|
+
const transaction = {};
|
|
7667
|
+
if (args.type === "0x7e") {
|
|
7668
|
+
transaction.isSystemTx = args.isSystemTx;
|
|
7669
|
+
transaction.mint = args.mint ? hexToBigInt(args.mint) : void 0;
|
|
7670
|
+
transaction.sourceHash = args.sourceHash;
|
|
7671
|
+
transaction.type = "deposit";
|
|
7672
|
+
}
|
|
7673
|
+
return transaction;
|
|
7674
|
+
} }),
|
|
7675
|
+
transactionReceipt: /* @__PURE__ */ defineTransactionReceipt({ format(args) {
|
|
7676
|
+
return {
|
|
7677
|
+
l1GasPrice: args.l1GasPrice ? hexToBigInt(args.l1GasPrice) : null,
|
|
7678
|
+
l1GasUsed: args.l1GasUsed ? hexToBigInt(args.l1GasUsed) : null,
|
|
7679
|
+
l1Fee: args.l1Fee ? hexToBigInt(args.l1Fee) : null,
|
|
7680
|
+
l1FeeScalar: args.l1FeeScalar ? Number(args.l1FeeScalar) : null
|
|
7681
|
+
};
|
|
7682
|
+
} })
|
|
7683
|
+
};
|
|
7684
|
+
//#endregion
|
|
7685
|
+
//#region node_modules/.pnpm/viem@2.47.6_typescript@5.9.3_zod@4.3.6/node_modules/viem/_esm/op-stack/serializers.js
|
|
7686
|
+
function serializeTransaction(transaction, signature) {
|
|
7687
|
+
if (isDeposit(transaction)) return serializeTransactionDeposit(transaction);
|
|
7688
|
+
return serializeTransaction$1(transaction, signature);
|
|
7689
|
+
}
|
|
7690
|
+
const serializers = { transaction: serializeTransaction };
|
|
7691
|
+
function serializeTransactionDeposit(transaction) {
|
|
7692
|
+
assertTransactionDeposit(transaction);
|
|
7693
|
+
const { sourceHash, data, from, gas, isSystemTx, mint, to, value } = transaction;
|
|
7694
|
+
return concatHex(["0x7e", toRlp$1([
|
|
7695
|
+
sourceHash,
|
|
7696
|
+
from,
|
|
7697
|
+
to ?? "0x",
|
|
7698
|
+
mint ? toHex(mint) : "0x",
|
|
7699
|
+
value ? toHex(value) : "0x",
|
|
7700
|
+
gas ? toHex(gas) : "0x",
|
|
7701
|
+
isSystemTx ? "0x1" : "0x",
|
|
7702
|
+
data ?? "0x"
|
|
7703
|
+
])]);
|
|
7704
|
+
}
|
|
7705
|
+
function isDeposit(transaction) {
|
|
7706
|
+
if (transaction.type === "deposit") return true;
|
|
7707
|
+
if (typeof transaction.sourceHash !== "undefined") return true;
|
|
7708
|
+
return false;
|
|
7709
|
+
}
|
|
7710
|
+
function assertTransactionDeposit(transaction) {
|
|
7711
|
+
const { from, to } = transaction;
|
|
7712
|
+
if (from && !isAddress(from)) throw new InvalidAddressError$1({ address: from });
|
|
7713
|
+
if (to && !isAddress(to)) throw new InvalidAddressError$1({ address: to });
|
|
7714
|
+
}
|
|
7715
|
+
//#endregion
|
|
7716
|
+
//#region node_modules/.pnpm/viem@2.47.6_typescript@5.9.3_zod@4.3.6/node_modules/viem/_esm/op-stack/chainConfig.js
|
|
7717
|
+
const chainConfig = {
|
|
7718
|
+
blockTime: 2e3,
|
|
7719
|
+
contracts,
|
|
7720
|
+
formatters,
|
|
7721
|
+
serializers
|
|
7722
|
+
};
|
|
7723
|
+
//#endregion
|
|
7724
|
+
//#region node_modules/.pnpm/viem@2.47.6_typescript@5.9.3_zod@4.3.6/node_modules/viem/_esm/chains/definitions/base.js
|
|
7725
|
+
const sourceId = 1;
|
|
7726
|
+
const base = /* @__PURE__ */ defineChain({
|
|
7727
|
+
...chainConfig,
|
|
7728
|
+
id: 8453,
|
|
7729
|
+
name: "Base",
|
|
7730
|
+
nativeCurrency: {
|
|
7731
|
+
name: "Ether",
|
|
7732
|
+
symbol: "ETH",
|
|
7733
|
+
decimals: 18
|
|
7734
|
+
},
|
|
7735
|
+
rpcUrls: { default: { http: ["https://mainnet.base.org"] } },
|
|
7736
|
+
blockExplorers: { default: {
|
|
7737
|
+
name: "Basescan",
|
|
7738
|
+
url: "https://basescan.org",
|
|
7739
|
+
apiUrl: "https://api.basescan.org/api"
|
|
7740
|
+
} },
|
|
7741
|
+
contracts: {
|
|
7742
|
+
...chainConfig.contracts,
|
|
7743
|
+
disputeGameFactory: { [sourceId]: { address: "0x43edB88C4B80fDD2AdFF2412A7BebF9dF42cB40e" } },
|
|
7744
|
+
l2OutputOracle: { [sourceId]: { address: "0x56315b90c40730925ec5485cf004d835058518A0" } },
|
|
7745
|
+
multicall3: {
|
|
7746
|
+
address: "0xca11bde05977b3631167028862be2a173976ca11",
|
|
7747
|
+
blockCreated: 5022
|
|
7748
|
+
},
|
|
7749
|
+
portal: { [sourceId]: {
|
|
7750
|
+
address: "0x49048044D57e1C92A77f79988d21Fa8fAF74E97e",
|
|
7751
|
+
blockCreated: 17482143
|
|
7752
|
+
} },
|
|
7753
|
+
l1StandardBridge: { [sourceId]: {
|
|
7754
|
+
address: "0x3154Cf16ccdb4C6d922629664174b904d80F2C35",
|
|
7755
|
+
blockCreated: 17482143
|
|
7756
|
+
} }
|
|
7757
|
+
},
|
|
7758
|
+
sourceId
|
|
7759
|
+
});
|
|
7760
|
+
({ ...base });
|
|
7761
|
+
//#endregion
|
|
7601
7762
|
//#region node_modules/.pnpm/@x402+evm@2.8.0_typescript@5.9.3/node_modules/@x402/evm/dist/esm/chunk-GD4MKCN7.mjs
|
|
7602
7763
|
var EIP2612_GAS_SPONSORING_KEY = "eip2612GasSponsoring";
|
|
7603
7764
|
var ERC20_APPROVAL_GAS_SPONSORING_KEY = "erc20ApprovalGasSponsoring";
|
|
@@ -7848,7 +8009,7 @@ function publicKeyToAddress(publicKey) {
|
|
|
7848
8009
|
//#region node_modules/.pnpm/viem@2.47.6_typescript@5.9.3_zod@3.25.76/node_modules/viem/_esm/utils/signature/recoverPublicKey.js
|
|
7849
8010
|
async function recoverPublicKey({ hash, signature }) {
|
|
7850
8011
|
const hashHex = isHex$1(hash) ? hash : toHex$1(hash);
|
|
7851
|
-
const { secp256k1 } = await import("./secp256k1-
|
|
8012
|
+
const { secp256k1 } = await import("./secp256k1-CHAXu2gP.js");
|
|
7852
8013
|
return `0x${(() => {
|
|
7853
8014
|
if (typeof signature === "object" && "r" in signature && "s" in signature) {
|
|
7854
8015
|
const { r, s, v, yParity } = signature;
|
|
@@ -16206,7 +16367,7 @@ async function sendRawTransactionSync(client, { serializedTransaction, throwOnRe
|
|
|
16206
16367
|
params: timeout ? [serializedTransaction, timeout] : [serializedTransaction]
|
|
16207
16368
|
}, { retryCount: 0 });
|
|
16208
16369
|
const formatted = (client.chain?.formatters?.transactionReceipt?.format || formatTransactionReceipt)(receipt);
|
|
16209
|
-
if (formatted.status === "reverted" && throwOnReceiptRevert) throw new TransactionReceiptRevertedError({ receipt: formatted });
|
|
16370
|
+
if (formatted.status === "reverted" && throwOnReceiptRevert) throw new TransactionReceiptRevertedError$1({ receipt: formatted });
|
|
16210
16371
|
return formatted;
|
|
16211
16372
|
}
|
|
16212
16373
|
//#endregion
|
|
@@ -17020,135 +17181,6 @@ function toClientEvmSigner(signer, publicClient) {
|
|
|
17020
17181
|
if (estimateFeesPerGas) result.estimateFeesPerGas = () => estimateFeesPerGas();
|
|
17021
17182
|
return result;
|
|
17022
17183
|
}
|
|
17023
|
-
//#endregion
|
|
17024
|
-
//#region node_modules/.pnpm/viem@2.47.6_typescript@5.9.3_zod@4.3.6/node_modules/viem/_esm/op-stack/contracts.js
|
|
17025
|
-
/**
|
|
17026
|
-
* Predeploy contracts for OP Stack.
|
|
17027
|
-
* @see https://github.com/ethereum-optimism/optimism/blob/develop/specs/predeploys.md
|
|
17028
|
-
*/
|
|
17029
|
-
const contracts = {
|
|
17030
|
-
gasPriceOracle: { address: "0x420000000000000000000000000000000000000F" },
|
|
17031
|
-
l1Block: { address: "0x4200000000000000000000000000000000000015" },
|
|
17032
|
-
l2CrossDomainMessenger: { address: "0x4200000000000000000000000000000000000007" },
|
|
17033
|
-
l2Erc721Bridge: { address: "0x4200000000000000000000000000000000000014" },
|
|
17034
|
-
l2StandardBridge: { address: "0x4200000000000000000000000000000000000010" },
|
|
17035
|
-
l2ToL1MessagePasser: { address: "0x4200000000000000000000000000000000000016" }
|
|
17036
|
-
};
|
|
17037
|
-
//#endregion
|
|
17038
|
-
//#region node_modules/.pnpm/viem@2.47.6_typescript@5.9.3_zod@4.3.6/node_modules/viem/_esm/op-stack/formatters.js
|
|
17039
|
-
const formatters = {
|
|
17040
|
-
block: /* @__PURE__ */ defineBlock({ format(args) {
|
|
17041
|
-
return {
|
|
17042
|
-
transactions: args.transactions?.map((transaction) => {
|
|
17043
|
-
if (typeof transaction === "string") return transaction;
|
|
17044
|
-
const formatted = formatTransaction$1(transaction);
|
|
17045
|
-
if (formatted.typeHex === "0x7e") {
|
|
17046
|
-
formatted.isSystemTx = transaction.isSystemTx;
|
|
17047
|
-
formatted.mint = transaction.mint ? hexToBigInt(transaction.mint) : void 0;
|
|
17048
|
-
formatted.sourceHash = transaction.sourceHash;
|
|
17049
|
-
formatted.type = "deposit";
|
|
17050
|
-
}
|
|
17051
|
-
return formatted;
|
|
17052
|
-
}),
|
|
17053
|
-
stateRoot: args.stateRoot
|
|
17054
|
-
};
|
|
17055
|
-
} }),
|
|
17056
|
-
transaction: /* @__PURE__ */ defineTransaction({ format(args) {
|
|
17057
|
-
const transaction = {};
|
|
17058
|
-
if (args.type === "0x7e") {
|
|
17059
|
-
transaction.isSystemTx = args.isSystemTx;
|
|
17060
|
-
transaction.mint = args.mint ? hexToBigInt(args.mint) : void 0;
|
|
17061
|
-
transaction.sourceHash = args.sourceHash;
|
|
17062
|
-
transaction.type = "deposit";
|
|
17063
|
-
}
|
|
17064
|
-
return transaction;
|
|
17065
|
-
} }),
|
|
17066
|
-
transactionReceipt: /* @__PURE__ */ defineTransactionReceipt({ format(args) {
|
|
17067
|
-
return {
|
|
17068
|
-
l1GasPrice: args.l1GasPrice ? hexToBigInt(args.l1GasPrice) : null,
|
|
17069
|
-
l1GasUsed: args.l1GasUsed ? hexToBigInt(args.l1GasUsed) : null,
|
|
17070
|
-
l1Fee: args.l1Fee ? hexToBigInt(args.l1Fee) : null,
|
|
17071
|
-
l1FeeScalar: args.l1FeeScalar ? Number(args.l1FeeScalar) : null
|
|
17072
|
-
};
|
|
17073
|
-
} })
|
|
17074
|
-
};
|
|
17075
|
-
//#endregion
|
|
17076
|
-
//#region node_modules/.pnpm/viem@2.47.6_typescript@5.9.3_zod@4.3.6/node_modules/viem/_esm/op-stack/serializers.js
|
|
17077
|
-
function serializeTransaction(transaction, signature) {
|
|
17078
|
-
if (isDeposit(transaction)) return serializeTransactionDeposit(transaction);
|
|
17079
|
-
return serializeTransaction$1(transaction, signature);
|
|
17080
|
-
}
|
|
17081
|
-
const serializers = { transaction: serializeTransaction };
|
|
17082
|
-
function serializeTransactionDeposit(transaction) {
|
|
17083
|
-
assertTransactionDeposit(transaction);
|
|
17084
|
-
const { sourceHash, data, from, gas, isSystemTx, mint, to, value } = transaction;
|
|
17085
|
-
return concatHex(["0x7e", toRlp$1([
|
|
17086
|
-
sourceHash,
|
|
17087
|
-
from,
|
|
17088
|
-
to ?? "0x",
|
|
17089
|
-
mint ? toHex(mint) : "0x",
|
|
17090
|
-
value ? toHex(value) : "0x",
|
|
17091
|
-
gas ? toHex(gas) : "0x",
|
|
17092
|
-
isSystemTx ? "0x1" : "0x",
|
|
17093
|
-
data ?? "0x"
|
|
17094
|
-
])]);
|
|
17095
|
-
}
|
|
17096
|
-
function isDeposit(transaction) {
|
|
17097
|
-
if (transaction.type === "deposit") return true;
|
|
17098
|
-
if (typeof transaction.sourceHash !== "undefined") return true;
|
|
17099
|
-
return false;
|
|
17100
|
-
}
|
|
17101
|
-
function assertTransactionDeposit(transaction) {
|
|
17102
|
-
const { from, to } = transaction;
|
|
17103
|
-
if (from && !isAddress(from)) throw new InvalidAddressError$1({ address: from });
|
|
17104
|
-
if (to && !isAddress(to)) throw new InvalidAddressError$1({ address: to });
|
|
17105
|
-
}
|
|
17106
|
-
//#endregion
|
|
17107
|
-
//#region node_modules/.pnpm/viem@2.47.6_typescript@5.9.3_zod@4.3.6/node_modules/viem/_esm/op-stack/chainConfig.js
|
|
17108
|
-
const chainConfig = {
|
|
17109
|
-
blockTime: 2e3,
|
|
17110
|
-
contracts,
|
|
17111
|
-
formatters,
|
|
17112
|
-
serializers
|
|
17113
|
-
};
|
|
17114
|
-
//#endregion
|
|
17115
|
-
//#region node_modules/.pnpm/viem@2.47.6_typescript@5.9.3_zod@4.3.6/node_modules/viem/_esm/chains/definitions/base.js
|
|
17116
|
-
const sourceId = 1;
|
|
17117
|
-
const base = /* @__PURE__ */ defineChain({
|
|
17118
|
-
...chainConfig,
|
|
17119
|
-
id: 8453,
|
|
17120
|
-
name: "Base",
|
|
17121
|
-
nativeCurrency: {
|
|
17122
|
-
name: "Ether",
|
|
17123
|
-
symbol: "ETH",
|
|
17124
|
-
decimals: 18
|
|
17125
|
-
},
|
|
17126
|
-
rpcUrls: { default: { http: ["https://mainnet.base.org"] } },
|
|
17127
|
-
blockExplorers: { default: {
|
|
17128
|
-
name: "Basescan",
|
|
17129
|
-
url: "https://basescan.org",
|
|
17130
|
-
apiUrl: "https://api.basescan.org/api"
|
|
17131
|
-
} },
|
|
17132
|
-
contracts: {
|
|
17133
|
-
...chainConfig.contracts,
|
|
17134
|
-
disputeGameFactory: { [sourceId]: { address: "0x43edB88C4B80fDD2AdFF2412A7BebF9dF42cB40e" } },
|
|
17135
|
-
l2OutputOracle: { [sourceId]: { address: "0x56315b90c40730925ec5485cf004d835058518A0" } },
|
|
17136
|
-
multicall3: {
|
|
17137
|
-
address: "0xca11bde05977b3631167028862be2a173976ca11",
|
|
17138
|
-
blockCreated: 5022
|
|
17139
|
-
},
|
|
17140
|
-
portal: { [sourceId]: {
|
|
17141
|
-
address: "0x49048044D57e1C92A77f79988d21Fa8fAF74E97e",
|
|
17142
|
-
blockCreated: 17482143
|
|
17143
|
-
} },
|
|
17144
|
-
l1StandardBridge: { [sourceId]: {
|
|
17145
|
-
address: "0x3154Cf16ccdb4C6d922629664174b904d80F2C35",
|
|
17146
|
-
blockCreated: 17482143
|
|
17147
|
-
} }
|
|
17148
|
-
},
|
|
17149
|
-
sourceId
|
|
17150
|
-
});
|
|
17151
|
-
({ ...base });
|
|
17152
17184
|
function isMeaningfulInferenceRecord(record) {
|
|
17153
17185
|
if (record.kind !== "x402_inference") return true;
|
|
17154
17186
|
if (!record.ok) return true;
|
|
@@ -17601,7 +17633,7 @@ async function buildX402Client(wallet, opts) {
|
|
|
17601
17633
|
})) });
|
|
17602
17634
|
}
|
|
17603
17635
|
if (wallet.solanaKey) {
|
|
17604
|
-
const { createKeyPairSignerFromBytes } = await import("./index.node-
|
|
17636
|
+
const { createKeyPairSignerFromBytes } = await import("./index.node-xc-jRJ78.js");
|
|
17605
17637
|
const signer = await createKeyPairSignerFromBytes(wallet.solanaKey);
|
|
17606
17638
|
client.register("solana:*", new OptimizedSvmScheme(signer));
|
|
17607
17639
|
}
|
package/package.json
CHANGED
package/dist/Mcp-CSyD7Hxz.js
DELETED
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
#!/usr/bin/env node
|
|
2
|
-
//#region node_modules/.pnpm/mppx@0.5.1_@modelcontextprotocol+sdk@1.27.1_zod@4.3.6__express@5.2.1_hono@4.12.9_openap_7e96141f01ea299750883fead337550c/node_modules/mppx/dist/Mcp.js
|
|
3
|
-
/** MCP JSON-RPC error code for payment required. */
|
|
4
|
-
const paymentRequiredCode = -32042;
|
|
5
|
-
/** MCP metadata key for credentials. */
|
|
6
|
-
const credentialMetaKey = "org.paymentauth/credential";
|
|
7
|
-
/** MCP metadata key for receipts. */
|
|
8
|
-
const receiptMetaKey = "org.paymentauth/receipt";
|
|
9
|
-
//#endregion
|
|
10
|
-
export { paymentRequiredCode as n, receiptMetaKey as r, credentialMetaKey as t };
|