starknet 8.1.1 → 8.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +12 -0
- package/dist/index.d.ts +877 -139
- package/dist/index.global.js +2122 -396
- package/dist/index.global.js.map +1 -1
- package/dist/index.js +2143 -396
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +2122 -396
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -530,6 +530,7 @@ type ApiEstimateFeeResponse = FeeEstimate[];
|
|
|
530
530
|
declare function isRPC08Plus_ResourceBounds(entry: ResourceBounds): entry is RPCSPEC08.ResourceBounds;
|
|
531
531
|
declare function isRPC08Plus_ResourceBoundsBN(entry: ResourceBoundsBN): entry is ResourceBoundsBN;
|
|
532
532
|
type ResourceBounds = Merge<RPCSPEC08.ResourceBounds, RPC.ResourceBounds>;
|
|
533
|
+
type EventFilter = RPC.EventFilter;
|
|
533
534
|
/**
|
|
534
535
|
* Represents percentage overhead for each resource bound
|
|
535
536
|
* numerical 50 means 50% overhead
|
|
@@ -619,6 +620,16 @@ type ByteArray = {
|
|
|
619
620
|
type Calldata = string[] & {
|
|
620
621
|
readonly __compiled__?: true;
|
|
621
622
|
};
|
|
623
|
+
/**
|
|
624
|
+
* "Abi Entry type"
|
|
625
|
+
* @example
|
|
626
|
+
* 'core::bytes_31::bytes31'
|
|
627
|
+
* 'core::bool'
|
|
628
|
+
* 'core::felt'
|
|
629
|
+
* 'core::uint256'
|
|
630
|
+
* 'core::uint512'
|
|
631
|
+
*/
|
|
632
|
+
type AbiEntryType = AbiEntry['type'];
|
|
622
633
|
/**
|
|
623
634
|
* Represents an integer in the range [0, 2^256)
|
|
624
635
|
*/
|
|
@@ -858,7 +869,7 @@ type RpcProviderOptions = {
|
|
|
858
869
|
default?: boolean;
|
|
859
870
|
waitMode?: boolean;
|
|
860
871
|
baseFetch?: WindowOrWorkerGlobalScope['fetch'];
|
|
861
|
-
resourceBoundsOverhead?: ResourceBoundsOverhead;
|
|
872
|
+
resourceBoundsOverhead?: ResourceBoundsOverhead | false;
|
|
862
873
|
batch?: false | number;
|
|
863
874
|
};
|
|
864
875
|
|
|
@@ -887,10 +898,6 @@ type EstimateFeeResponseOverhead = {
|
|
|
887
898
|
overall_fee: bigint;
|
|
888
899
|
unit: PRICE_UNIT;
|
|
889
900
|
};
|
|
890
|
-
/**
|
|
891
|
-
* same type as EstimateFeeResponseOverhead but without overhead
|
|
892
|
-
*/
|
|
893
|
-
type EstimateFeeResponse = EstimateFeeResponseOverhead;
|
|
894
901
|
type EstimateFeeResponseBulkOverhead = Array<EstimateFeeResponseOverhead>;
|
|
895
902
|
type InvokeFunctionResponse = InvokedTransaction;
|
|
896
903
|
type DeclareContractResponse = DeclaredTransaction;
|
|
@@ -1035,7 +1042,7 @@ declare abstract class SignerInterface {
|
|
|
1035
1042
|
/**
|
|
1036
1043
|
* Method to get the public key of the signer
|
|
1037
1044
|
*
|
|
1038
|
-
* @returns {string} hex-string
|
|
1045
|
+
* @returns {Promise<string>} hex-string public key
|
|
1039
1046
|
* @example
|
|
1040
1047
|
* ```typescript
|
|
1041
1048
|
* const mySigner = new Signer("0x123");
|
|
@@ -1048,49 +1055,67 @@ declare abstract class SignerInterface {
|
|
|
1048
1055
|
* Signs a JSON object for off-chain usage with the private key and returns the signature.
|
|
1049
1056
|
* This adds a message prefix so it can't be interchanged with transactions
|
|
1050
1057
|
*
|
|
1051
|
-
* @param {TypedData} typedData JSON object to be signed
|
|
1052
|
-
* @param {string} accountAddress Hex string of the account's address
|
|
1058
|
+
* @param {TypedData} typedData - JSON object to be signed
|
|
1059
|
+
* @param {string} accountAddress - Hex string of the account's address
|
|
1053
1060
|
* @returns {Promise<Signature>} the signature of the message
|
|
1054
1061
|
* @example
|
|
1055
1062
|
* ```typescript
|
|
1056
1063
|
* const mySigner = new Signer("0x123");
|
|
1057
|
-
*
|
|
1058
|
-
*
|
|
1059
|
-
*
|
|
1060
|
-
*
|
|
1061
|
-
*
|
|
1062
|
-
*
|
|
1063
|
-
*
|
|
1064
|
-
*
|
|
1065
|
-
*
|
|
1066
|
-
*
|
|
1067
|
-
*
|
|
1064
|
+
* const myTypedData: TypedData = {
|
|
1065
|
+
* domain: {
|
|
1066
|
+
* name: "Example DApp",
|
|
1067
|
+
* chainId: constants.StarknetChainId.SN_SEPOLIA,
|
|
1068
|
+
* version: "0.0.3"
|
|
1069
|
+
* },
|
|
1070
|
+
* types: {
|
|
1071
|
+
* StarkNetDomain: [
|
|
1072
|
+
* { name: "name", type: "string" },
|
|
1073
|
+
* { name: "chainId", type: "felt" },
|
|
1074
|
+
* { name: "version", type: "string" }
|
|
1075
|
+
* ],
|
|
1076
|
+
* Message: [{ name: "message", type: "felt" }]
|
|
1077
|
+
* },
|
|
1078
|
+
* primaryType: "Message",
|
|
1079
|
+
* message: { message: "1234" }
|
|
1080
|
+
* };
|
|
1081
|
+
* const result = await mySigner.signMessage(myTypedData, "0x5d08a4e9188429da4e993c9bf25aafe5cd491ee2b501505d4d059f0c938f82d");
|
|
1068
1082
|
* // result = Signature {r: 684915484701699003335398790608214855489903651271362390249153620883122231253n,
|
|
1069
1083
|
* // s: 1399150959912500412309102776989465580949387575375484933432871778355496929189n, recovery: 1}
|
|
1070
1084
|
* ```
|
|
1071
|
-
|
|
1072
1085
|
*/
|
|
1073
1086
|
abstract signMessage(typedData: TypedData, accountAddress: string): Promise<Signature>;
|
|
1074
1087
|
/**
|
|
1075
|
-
* Signs transactions with the private key and returns the signature
|
|
1088
|
+
* Signs INVOKE transactions with the private key and returns the signature
|
|
1076
1089
|
*
|
|
1077
|
-
* @param {Call[]} transactions
|
|
1078
|
-
* @param {InvocationsSignerDetails} transactionsDetail
|
|
1090
|
+
* @param {Call[]} transactions - Array of Call objects representing the transactions
|
|
1091
|
+
* @param {InvocationsSignerDetails} transactionsDetail - Transaction details including V3 fields
|
|
1079
1092
|
* @returns {Promise<Signature>} the signature of the transaction
|
|
1093
|
+
* @remarks Only supports V3 transactions. V0, V1, and V2 transactions will throw an error.
|
|
1080
1094
|
* @example
|
|
1081
1095
|
* ```typescript
|
|
1082
1096
|
* const mySigner = new Signer("0x123");
|
|
1083
1097
|
* const calls: Call[] = [{
|
|
1084
|
-
*
|
|
1085
|
-
*
|
|
1086
|
-
*
|
|
1098
|
+
* contractAddress: "0x1234567890123456789012345678901234567890",
|
|
1099
|
+
* entrypoint: "transfer",
|
|
1100
|
+
* calldata: ["0xRecipient", "1000", "0"]
|
|
1087
1101
|
* }];
|
|
1088
1102
|
* const transactionsDetail: InvocationsSignerDetails = {
|
|
1089
|
-
*
|
|
1090
|
-
*
|
|
1091
|
-
*
|
|
1092
|
-
*
|
|
1093
|
-
*
|
|
1103
|
+
* walletAddress: '0x742d35Cc6634C0532925a3b844Bc454e4438f44e',
|
|
1104
|
+
* chainId: constants.StarknetChainId.SN_MAIN,
|
|
1105
|
+
* cairoVersion: "1",
|
|
1106
|
+
* version: "0x3",
|
|
1107
|
+
* nonce: 1,
|
|
1108
|
+
* resourceBounds: {
|
|
1109
|
+
* l1_gas: { amount: "0x1000", price: "0x20" },
|
|
1110
|
+
* l2_gas: { amount: "0x200", price: "0x5" },
|
|
1111
|
+
* l1_data_gas: { amount: "0x500", price: "0x10" }
|
|
1112
|
+
* },
|
|
1113
|
+
* tip: 0,
|
|
1114
|
+
* paymasterData: [],
|
|
1115
|
+
* accountDeploymentData: [],
|
|
1116
|
+
* nonceDataAvailabilityMode: RPC.EDataAvailabilityMode.L1,
|
|
1117
|
+
* feeDataAvailabilityMode: RPC.EDataAvailabilityMode.L1
|
|
1118
|
+
* };
|
|
1094
1119
|
* const result = await mySigner.signTransaction(calls, transactionsDetail);
|
|
1095
1120
|
* // result = Signature {r: 304910226421970384958146916800275294114105560641204815169249090836676768876n,
|
|
1096
1121
|
* // s: 1072798866000813654190523783606274062837012608648308896325315895472901074693n, recovery: 0}
|
|
@@ -1100,21 +1125,31 @@ declare abstract class SignerInterface {
|
|
|
1100
1125
|
/**
|
|
1101
1126
|
* Signs a DEPLOY_ACCOUNT transaction with the private key and returns the signature
|
|
1102
1127
|
*
|
|
1103
|
-
* @param {DeployAccountSignerDetails} transaction to deploy an account contract
|
|
1128
|
+
* @param {DeployAccountSignerDetails} transaction - Transaction details to deploy an account contract
|
|
1104
1129
|
* @returns {Promise<Signature>} the signature of the transaction to deploy an account
|
|
1130
|
+
* @remarks Only supports V3 transactions. V0, V1, and V2 transactions will throw an error.
|
|
1105
1131
|
* @example
|
|
1106
1132
|
* ```typescript
|
|
1107
1133
|
* const mySigner = new Signer("0x123");
|
|
1108
1134
|
* const myDeployAcc: DeployAccountSignerDetails = {
|
|
1109
1135
|
* contractAddress: "0x65a822fbee1ae79e898688b5a4282dc79e0042cbed12f6169937fddb4c26641",
|
|
1110
|
-
* version: "
|
|
1136
|
+
* version: "0x3",
|
|
1137
|
+
* chainId: constants.StarknetChainId.SN_SEPOLIA,
|
|
1111
1138
|
* classHash: "0x5f3614e8671257aff9ac38e929c74d65b02d460ae966cd826c9f04a7fa8e0d4",
|
|
1112
|
-
* constructorCalldata: [
|
|
1113
|
-
*
|
|
1139
|
+
* constructorCalldata: ["0x123", "0x456"],
|
|
1140
|
+
* addressSalt: "0x789",
|
|
1141
|
+
* nonce: 0,
|
|
1142
|
+
* resourceBounds: {
|
|
1143
|
+
* l1_gas: { amount: "0x1000", price: "0x20" },
|
|
1144
|
+
* l2_gas: { amount: "0x200", price: "0x5" },
|
|
1145
|
+
* l1_data_gas: { amount: "0x500", price: "0x10" }
|
|
1146
|
+
* },
|
|
1147
|
+
* tip: 0,
|
|
1148
|
+
* paymasterData: [],
|
|
1149
|
+
* accountDeploymentData: [],
|
|
1114
1150
|
* nonceDataAvailabilityMode: RPC.EDataAvailabilityMode.L1,
|
|
1115
|
-
* feeDataAvailabilityMode: RPC.EDataAvailabilityMode.L1
|
|
1116
|
-
*
|
|
1117
|
-
* }
|
|
1151
|
+
* feeDataAvailabilityMode: RPC.EDataAvailabilityMode.L1
|
|
1152
|
+
* };
|
|
1118
1153
|
* const result = await mySigner.signDeployAccountTransaction(myDeployAcc);
|
|
1119
1154
|
* // result = Signature {r: 2871311234341436528393212130310036951068553852419934781736214693308640202748n,
|
|
1120
1155
|
* // s: 1746271646048888422437132495446973163454853863041370993384284773665861377605n, recovery: 1}
|
|
@@ -1124,20 +1159,30 @@ declare abstract class SignerInterface {
|
|
|
1124
1159
|
/**
|
|
1125
1160
|
* Signs a DECLARE transaction with the private key and returns the signature
|
|
1126
1161
|
*
|
|
1127
|
-
* @param {DeclareSignerDetails} transaction to declare a class
|
|
1162
|
+
* @param {DeclareSignerDetails} transaction - Transaction details to declare a contract class
|
|
1128
1163
|
* @returns {Promise<Signature>} the signature of the transaction to declare a class
|
|
1164
|
+
* @remarks Only supports V3 transactions. V0, V1, and V2 transactions will throw an error.
|
|
1129
1165
|
* @example
|
|
1130
1166
|
* ```typescript
|
|
1131
1167
|
* const mySigner = new Signer("0x123");
|
|
1132
1168
|
* const myDeclare: DeclareSignerDetails = {
|
|
1133
|
-
* version: "
|
|
1169
|
+
* version: "0x3",
|
|
1170
|
+
* chainId: constants.StarknetChainId.SN_SEPOLIA,
|
|
1134
1171
|
* senderAddress: "0x65a822fbee1ae79e898688b5a4282dc79e0042cbed12f6169937fddb4c26641",
|
|
1135
1172
|
* classHash: "0x5f3614e8671257aff9ac38e929c74d65b02d460ae966cd826c9f04a7fa8e0d4",
|
|
1136
|
-
*
|
|
1173
|
+
* compiledClassHash: "0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef",
|
|
1174
|
+
* nonce: 45,
|
|
1175
|
+
* resourceBounds: {
|
|
1176
|
+
* l1_gas: { amount: "0x1000", price: "0x20" },
|
|
1177
|
+
* l2_gas: { amount: "0x200", price: "0x5" },
|
|
1178
|
+
* l1_data_gas: { amount: "0x500", price: "0x10" }
|
|
1179
|
+
* },
|
|
1180
|
+
* tip: 0,
|
|
1181
|
+
* paymasterData: [],
|
|
1182
|
+
* accountDeploymentData: [],
|
|
1137
1183
|
* nonceDataAvailabilityMode: RPC.EDataAvailabilityMode.L1,
|
|
1138
|
-
* feeDataAvailabilityMode: RPC.EDataAvailabilityMode.L1
|
|
1139
|
-
*
|
|
1140
|
-
}
|
|
1184
|
+
* feeDataAvailabilityMode: RPC.EDataAvailabilityMode.L1
|
|
1185
|
+
* };
|
|
1141
1186
|
* const result = await mySigner.signDeclareTransaction(myDeclare);
|
|
1142
1187
|
* // result = Signature {r: 2432056944313955951711774394836075930010416436707488863728289188289211995670n,
|
|
1143
1188
|
* // s: 3407649393310177489888603098175002856596469926897298636282244411990343146307n, recovery: 1}
|
|
@@ -1805,9 +1850,9 @@ type TipAnalysisOptions = {
|
|
|
1805
1850
|
declare function getTipStatsFromBlocks(provider: ProviderInterface, blockIdentifier?: BlockIdentifier, options?: TipAnalysisOptions): Promise<TipEstimate>;
|
|
1806
1851
|
|
|
1807
1852
|
type TransactionStatusReceiptSets = {
|
|
1808
|
-
|
|
1809
|
-
|
|
1810
|
-
|
|
1853
|
+
SUCCEEDED: SuccessfulTransactionReceiptResponse;
|
|
1854
|
+
REVERTED: RevertedTransactionReceiptResponse;
|
|
1855
|
+
ERROR: Error;
|
|
1811
1856
|
};
|
|
1812
1857
|
type TransactionReceiptStatus = keyof TransactionStatusReceiptSets;
|
|
1813
1858
|
type TransactionReceiptValue = TransactionStatusReceiptSets[TransactionReceiptStatus];
|
|
@@ -1818,14 +1863,31 @@ type TransactionReceiptCallbacksDefault = Partial<TransactionReceiptCallbacksDef
|
|
|
1818
1863
|
_: () => void;
|
|
1819
1864
|
};
|
|
1820
1865
|
type TransactionReceiptCallbacks = TransactionReceiptCallbacksDefined | TransactionReceiptCallbacksDefault;
|
|
1821
|
-
type
|
|
1822
|
-
|
|
1823
|
-
readonly
|
|
1824
|
-
readonly value: TransactionStatusReceiptSets[T];
|
|
1866
|
+
type SuccessfulTransactionReceiptResponseHelper = SuccessfulTransactionReceiptResponse & {
|
|
1867
|
+
readonly statusReceipt: 'SUCCEEDED';
|
|
1868
|
+
readonly value: SuccessfulTransactionReceiptResponse;
|
|
1825
1869
|
match(callbacks: TransactionReceiptCallbacks): void;
|
|
1826
|
-
|
|
1827
|
-
|
|
1870
|
+
isSuccess(): this is SuccessfulTransactionReceiptResponseHelper;
|
|
1871
|
+
isReverted(): this is RevertedTransactionReceiptResponseHelper;
|
|
1872
|
+
isError(): this is ErrorReceiptResponseHelper;
|
|
1873
|
+
};
|
|
1874
|
+
type RevertedTransactionReceiptResponseHelper = RevertedTransactionReceiptResponse & {
|
|
1875
|
+
readonly statusReceipt: 'REVERTED';
|
|
1876
|
+
readonly value: RevertedTransactionReceiptResponse;
|
|
1877
|
+
match(callbacks: TransactionReceiptCallbacks): void;
|
|
1878
|
+
isSuccess(): this is SuccessfulTransactionReceiptResponseHelper;
|
|
1879
|
+
isReverted(): this is RevertedTransactionReceiptResponseHelper;
|
|
1880
|
+
isError(): this is ErrorReceiptResponseHelper;
|
|
1881
|
+
};
|
|
1882
|
+
type ErrorReceiptResponseHelper = {
|
|
1883
|
+
readonly statusReceipt: 'ERROR';
|
|
1884
|
+
readonly value: Error;
|
|
1885
|
+
match(callbacks: TransactionReceiptCallbacks): void;
|
|
1886
|
+
isSuccess(): this is SuccessfulTransactionReceiptResponseHelper;
|
|
1887
|
+
isReverted(): this is RevertedTransactionReceiptResponseHelper;
|
|
1888
|
+
isError(): this is ErrorReceiptResponseHelper;
|
|
1828
1889
|
};
|
|
1890
|
+
type GetTransactionReceiptResponse = SuccessfulTransactionReceiptResponseHelper | RevertedTransactionReceiptResponseHelper | ErrorReceiptResponseHelper;
|
|
1829
1891
|
|
|
1830
1892
|
declare abstract class ResponseParser {
|
|
1831
1893
|
abstract parseGetBlockResponse(res: BlockWithTxHashes): GetBlockResponse;
|
|
@@ -2473,11 +2535,20 @@ declare const Uint: {
|
|
|
2473
2535
|
readonly u16: "core::integer::u16";
|
|
2474
2536
|
readonly u32: "core::integer::u32";
|
|
2475
2537
|
readonly u64: "core::integer::u64";
|
|
2538
|
+
readonly u96: "core::integer::u96";
|
|
2476
2539
|
readonly u128: "core::integer::u128";
|
|
2477
2540
|
readonly u256: "core::integer::u256";
|
|
2478
2541
|
readonly u512: "core::integer::u512";
|
|
2479
2542
|
};
|
|
2480
2543
|
type Uint = ValuesType<typeof Uint>;
|
|
2544
|
+
declare const Int: {
|
|
2545
|
+
readonly i8: "core::integer::i8";
|
|
2546
|
+
readonly i16: "core::integer::i16";
|
|
2547
|
+
readonly i32: "core::integer::i32";
|
|
2548
|
+
readonly i64: "core::integer::i64";
|
|
2549
|
+
readonly i128: "core::integer::i128";
|
|
2550
|
+
};
|
|
2551
|
+
type Int = ValuesType<typeof Int>;
|
|
2481
2552
|
declare const Literal: {
|
|
2482
2553
|
readonly ClassHash: "core::starknet::class_hash::ClassHash";
|
|
2483
2554
|
readonly ContractAddress: "core::starknet::contract_address::ContractAddress";
|
|
@@ -2919,6 +2990,178 @@ declare abstract class AccountInterface extends ProviderInterface {
|
|
|
2919
2990
|
abstract declareIfNot(contractPayload: DeclareContractPayload, transactionsDetail?: InvocationsDetails): Promise<DeclareContractResponse>;
|
|
2920
2991
|
}
|
|
2921
2992
|
|
|
2993
|
+
/**
|
|
2994
|
+
* Abi parser interface
|
|
2995
|
+
*/
|
|
2996
|
+
declare abstract class AbiParserInterface {
|
|
2997
|
+
/**
|
|
2998
|
+
* Helper to calculate inputs length from abi
|
|
2999
|
+
* @param abiMethod FunctionAbi
|
|
3000
|
+
* @return number
|
|
3001
|
+
*/
|
|
3002
|
+
abstract methodInputsLength(abiMethod: FunctionAbi): number;
|
|
3003
|
+
/**
|
|
3004
|
+
* get method definition from abi
|
|
3005
|
+
* @param name string
|
|
3006
|
+
* @returns FunctionAbi | undefined
|
|
3007
|
+
*/
|
|
3008
|
+
abstract getMethod(name: string): FunctionAbi | undefined;
|
|
3009
|
+
/**
|
|
3010
|
+
* Return Abi in legacy format
|
|
3011
|
+
* @return Abi
|
|
3012
|
+
*/
|
|
3013
|
+
abstract getLegacyFormat(): Abi;
|
|
3014
|
+
/**
|
|
3015
|
+
* Get request parser for the given abi type
|
|
3016
|
+
* @param abiType AbiEntryType
|
|
3017
|
+
* @returns Parser function
|
|
3018
|
+
*/
|
|
3019
|
+
abstract getRequestParser(abiType: AbiEntryType): (val: unknown) => any;
|
|
3020
|
+
/**
|
|
3021
|
+
* Get response parser for the given abi type
|
|
3022
|
+
* @param abiType AbiEntryType
|
|
3023
|
+
* @returns Parser function
|
|
3024
|
+
*/
|
|
3025
|
+
abstract getResponseParser(abiType: AbiEntryType): (responseIterator: Iterator<string>) => any;
|
|
3026
|
+
}
|
|
3027
|
+
|
|
3028
|
+
/**
|
|
3029
|
+
* Parsing map for parser, request and response parsers are separated
|
|
3030
|
+
* Configure parsing strategy for each abi type
|
|
3031
|
+
*/
|
|
3032
|
+
type ParsingStrategy = {
|
|
3033
|
+
request: Record<AbiEntryType, (val: unknown) => any>;
|
|
3034
|
+
response: Record<AbiEntryType, (responseIterator: Iterator<string>) => any>;
|
|
3035
|
+
};
|
|
3036
|
+
/**
|
|
3037
|
+
* More robust parsing strategy
|
|
3038
|
+
* Configuration mapping - data-driven approach
|
|
3039
|
+
* Configure parsing strategy for each abi type
|
|
3040
|
+
*/
|
|
3041
|
+
declare const hdParsingStrategy: {
|
|
3042
|
+
readonly request: {
|
|
3043
|
+
readonly [x: string]: (val: unknown) => string[];
|
|
3044
|
+
readonly "core::bytes_31::bytes31": (val: unknown) => string[];
|
|
3045
|
+
readonly "core::byte_array::ByteArray": (val: unknown) => string[];
|
|
3046
|
+
readonly "core::felt252": (val: unknown) => string[];
|
|
3047
|
+
readonly "core::integer::u256": (val: unknown) => string[];
|
|
3048
|
+
};
|
|
3049
|
+
readonly response: {
|
|
3050
|
+
readonly [x: string]: ((responseIterator: Iterator<string>) => string) | ((responseIterator: Iterator<string>) => bigint);
|
|
3051
|
+
readonly "core::bytes_31::bytes31": (responseIterator: Iterator<string>) => string;
|
|
3052
|
+
readonly "core::byte_array::ByteArray": (responseIterator: Iterator<string>) => string;
|
|
3053
|
+
readonly "core::felt252": (responseIterator: Iterator<string>) => bigint;
|
|
3054
|
+
readonly "core::integer::u256": (responseIterator: Iterator<string>) => bigint;
|
|
3055
|
+
};
|
|
3056
|
+
};
|
|
3057
|
+
/**
|
|
3058
|
+
* Faster parsing strategy
|
|
3059
|
+
* Configuration mapping - data-driven approach
|
|
3060
|
+
* Configure parsing strategy for each abi type
|
|
3061
|
+
*/
|
|
3062
|
+
declare const fastParsingStrategy: ParsingStrategy;
|
|
3063
|
+
|
|
3064
|
+
declare class AbiParser1 implements AbiParserInterface {
|
|
3065
|
+
abi: Abi;
|
|
3066
|
+
parsingStrategy: ParsingStrategy;
|
|
3067
|
+
constructor(abi: Abi, parsingStrategy?: ParsingStrategy);
|
|
3068
|
+
getRequestParser(abiType: AbiEntryType): (val: unknown) => any;
|
|
3069
|
+
getResponseParser(abiType: AbiEntryType): (responseIterator: Iterator<string>) => any;
|
|
3070
|
+
/**
|
|
3071
|
+
* abi method inputs length without '_len' inputs
|
|
3072
|
+
* cairo 0 reducer
|
|
3073
|
+
* @param abiMethod FunctionAbi
|
|
3074
|
+
* @returns number
|
|
3075
|
+
*/
|
|
3076
|
+
methodInputsLength(abiMethod: FunctionAbi): number;
|
|
3077
|
+
/**
|
|
3078
|
+
* get method definition from abi
|
|
3079
|
+
* @param name string
|
|
3080
|
+
* @returns FunctionAbi | undefined
|
|
3081
|
+
*/
|
|
3082
|
+
getMethod(name: string): FunctionAbi | undefined;
|
|
3083
|
+
/**
|
|
3084
|
+
* Get Abi in legacy format
|
|
3085
|
+
* @returns Abi
|
|
3086
|
+
*/
|
|
3087
|
+
getLegacyFormat(): Abi;
|
|
3088
|
+
}
|
|
3089
|
+
|
|
3090
|
+
declare class AbiParser2 implements AbiParserInterface {
|
|
3091
|
+
abi: Abi;
|
|
3092
|
+
parsingStrategy: ParsingStrategy;
|
|
3093
|
+
constructor(abi: Abi, parsingStrategy?: ParsingStrategy);
|
|
3094
|
+
getRequestParser(abiType: AbiEntryType): (val: unknown) => any;
|
|
3095
|
+
getResponseParser(abiType: AbiEntryType): (responseIterator: Iterator<string>) => any;
|
|
3096
|
+
/**
|
|
3097
|
+
* abi method inputs length
|
|
3098
|
+
* @param abiMethod FunctionAbi
|
|
3099
|
+
* @returns number
|
|
3100
|
+
*/
|
|
3101
|
+
methodInputsLength(abiMethod: FunctionAbi): number;
|
|
3102
|
+
/**
|
|
3103
|
+
* get method definition from abi
|
|
3104
|
+
* @param name string
|
|
3105
|
+
* @returns FunctionAbi | undefined
|
|
3106
|
+
*/
|
|
3107
|
+
getMethod(name: string): FunctionAbi | undefined;
|
|
3108
|
+
/**
|
|
3109
|
+
* Get Abi in legacy format
|
|
3110
|
+
* @returns Abi
|
|
3111
|
+
*/
|
|
3112
|
+
getLegacyFormat(): Abi;
|
|
3113
|
+
}
|
|
3114
|
+
|
|
3115
|
+
/**
|
|
3116
|
+
* Creates ABI parser
|
|
3117
|
+
*
|
|
3118
|
+
* @param {Abi} abi
|
|
3119
|
+
* @returns {AbiParserInterface} abi parser interface
|
|
3120
|
+
*
|
|
3121
|
+
* @example
|
|
3122
|
+
* const abiParser2 = createAbiParser([getInterfaceAbi('struct')]);
|
|
3123
|
+
* // abiParser2 instanceof AbiParser2 === true
|
|
3124
|
+
*
|
|
3125
|
+
* const abiParser1 = createAbiParser([getFunctionAbi('struct')]);
|
|
3126
|
+
* // abiParser1 instanceof AbiParser1 === true
|
|
3127
|
+
*/
|
|
3128
|
+
declare function createAbiParser(abi: Abi, parsingStrategy?: ParsingStrategy): AbiParserInterface;
|
|
3129
|
+
/**
|
|
3130
|
+
* Retrieves ABI version
|
|
3131
|
+
*
|
|
3132
|
+
* @param {Abi} abi
|
|
3133
|
+
* @returns {1 | 2 | 0} abi 1, 2 or 0 version
|
|
3134
|
+
*
|
|
3135
|
+
* @example
|
|
3136
|
+
* // Example 1: Return ABI version 2
|
|
3137
|
+
* const version = getAbiVersion([getInterfaceAbi()]);
|
|
3138
|
+
* // version === 2
|
|
3139
|
+
*
|
|
3140
|
+
* // Example 2: Return ABI version 1
|
|
3141
|
+
* const version = getAbiVersion([getInterfaceAbi('core::bool')]);
|
|
3142
|
+
* // version === 1
|
|
3143
|
+
*
|
|
3144
|
+
* // Example 3: Return ABI version 0
|
|
3145
|
+
* const version = getAbiVersion([getInterfaceAbi('felt')]);
|
|
3146
|
+
* // version === 0
|
|
3147
|
+
*/
|
|
3148
|
+
declare function getAbiVersion(abi: Abi): 1 | 2 | 0;
|
|
3149
|
+
/**
|
|
3150
|
+
* Checks if no constructor valid
|
|
3151
|
+
*
|
|
3152
|
+
* @param {string} method
|
|
3153
|
+
* @param {RawArgs} argsCalldata
|
|
3154
|
+
* @param {FunctionAbi} abiMethod
|
|
3155
|
+
* @returns boolean
|
|
3156
|
+
*
|
|
3157
|
+
* @example
|
|
3158
|
+
* const result1 = isNoConstructorValid('constructor', [])
|
|
3159
|
+
* // result1 === true
|
|
3160
|
+
* const result2 = isNoConstructorValid('test', ['test'])
|
|
3161
|
+
* // result2 === false
|
|
3162
|
+
*/
|
|
3163
|
+
declare function isNoConstructorValid(method: string, argsCalldata: RawArgs, abiMethod?: FunctionAbi): boolean;
|
|
3164
|
+
|
|
2922
3165
|
type AsyncContractFunction<T = any> = (...args: ArgsOrCalldataWithOptions) => Promise<T>;
|
|
2923
3166
|
type ContractFunction = (...args: ArgsOrCalldataWithOptions) => any;
|
|
2924
3167
|
type CallResult = {
|
|
@@ -2937,6 +3180,10 @@ type CommonContractOptions = {
|
|
|
2937
3180
|
* @default true
|
|
2938
3181
|
*/
|
|
2939
3182
|
parseResponse?: boolean;
|
|
3183
|
+
/**
|
|
3184
|
+
* Custom parsing strategy for request/response processing
|
|
3185
|
+
*/
|
|
3186
|
+
parsingStrategy?: ParsingStrategy;
|
|
2940
3187
|
};
|
|
2941
3188
|
type ContractOptions = {
|
|
2942
3189
|
abi: Abi;
|
|
@@ -2961,6 +3208,11 @@ type ExecuteOptions = Pick<CommonContractOptions, 'parseRequest'> & {
|
|
|
2961
3208
|
* Deployer contract salt
|
|
2962
3209
|
*/
|
|
2963
3210
|
salt?: string;
|
|
3211
|
+
/**
|
|
3212
|
+
* Wait for transaction to be included in a block
|
|
3213
|
+
* @default false
|
|
3214
|
+
*/
|
|
3215
|
+
waitForTransaction?: boolean;
|
|
2964
3216
|
} & Partial<UniversalDetails>;
|
|
2965
3217
|
type CallOptions = CommonContractOptions & {
|
|
2966
3218
|
formatResponse?: FormatResponse;
|
|
@@ -2973,7 +3225,9 @@ type ParsedEvent = {
|
|
|
2973
3225
|
block_number?: BlockNumber;
|
|
2974
3226
|
transaction_hash?: TransactionHash;
|
|
2975
3227
|
};
|
|
2976
|
-
type ParsedEvents = Array<ParsedEvent
|
|
3228
|
+
type ParsedEvents = Array<ParsedEvent> & {
|
|
3229
|
+
getByPath?(path: string): ParsedStruct | null;
|
|
3230
|
+
};
|
|
2977
3231
|
/**
|
|
2978
3232
|
* Advance formatting used to get js types data as result
|
|
2979
3233
|
* @description https://starknetjs.com/docs/guides/define_call_message/#formatresponse
|
|
@@ -3015,7 +3269,7 @@ type DeployOnlyParams = FactoryParamsBase & {
|
|
|
3015
3269
|
constructorCalldata?: RawArgs;
|
|
3016
3270
|
abi?: Abi;
|
|
3017
3271
|
};
|
|
3018
|
-
type FactoryParams = DeclareAndDeployParams | DeployOnlyParams;
|
|
3272
|
+
type FactoryParams = (DeclareAndDeployParams | DeployOnlyParams) & CommonContractOptions;
|
|
3019
3273
|
|
|
3020
3274
|
type RPC_ERROR_SET = {
|
|
3021
3275
|
FAILED_TO_RECEIVE_TXN: FAILED_TO_RECEIVE_TXN;
|
|
@@ -3202,7 +3456,18 @@ declare function arrayBufferToString(array: ArrayBuffer): string;
|
|
|
3202
3456
|
* // result = Uint8Array(2) [ 72, 105 ]
|
|
3203
3457
|
* ```
|
|
3204
3458
|
*/
|
|
3205
|
-
declare function
|
|
3459
|
+
declare function utf8ToUint8Array(str: string): Uint8Array;
|
|
3460
|
+
/**
|
|
3461
|
+
* @deprecated use utf8ToUint8Array instead
|
|
3462
|
+
*/
|
|
3463
|
+
declare const utf8ToArray: typeof utf8ToUint8Array;
|
|
3464
|
+
/**
|
|
3465
|
+
* Convert utf8-string to bigint
|
|
3466
|
+
*
|
|
3467
|
+
* @param str The UTF-8 string to convert.
|
|
3468
|
+
* @returns The converted bigint.
|
|
3469
|
+
*/
|
|
3470
|
+
declare function utf8ToBigInt(str: string): bigint;
|
|
3206
3471
|
/**
|
|
3207
3472
|
* Convert string to array buffer (browser and node compatible)
|
|
3208
3473
|
*
|
|
@@ -3378,23 +3643,100 @@ declare const pascalToSnake: (text: string) => string;
|
|
|
3378
3643
|
* ```
|
|
3379
3644
|
*/
|
|
3380
3645
|
declare function concatenateArrayBuffer(uint8arrays: Uint8Array[]): Uint8Array;
|
|
3646
|
+
/**
|
|
3647
|
+
* Convert hex string to Uint8Array
|
|
3648
|
+
*
|
|
3649
|
+
* @param {string} hex The hex string to convert (with or without '0x' prefix)
|
|
3650
|
+
* @returns {Uint8Array} The converted byte array
|
|
3651
|
+
* @throws {Error} If the string contains non-hexadecimal characters
|
|
3652
|
+
*
|
|
3653
|
+
* @example
|
|
3654
|
+
* ```typescript
|
|
3655
|
+
* const hexString = '0x48656c6c6f';
|
|
3656
|
+
* const result = encode.hexStringToUint8Array(hexString);
|
|
3657
|
+
* // result = Uint8Array(5) [ 72, 101, 108, 108, 111 ]
|
|
3658
|
+
* ```
|
|
3659
|
+
*/
|
|
3660
|
+
declare function hexStringToUint8Array(hex: string): Uint8Array;
|
|
3661
|
+
/**
|
|
3662
|
+
* Convert any string to Uint8Array
|
|
3663
|
+
*
|
|
3664
|
+
* Handles three types of strings:
|
|
3665
|
+
* - Hex strings (e.g., '0x123f') - converts hex bytes to Uint8Array
|
|
3666
|
+
* - Decimal strings (e.g., '124324332') - converts decimal number to bytes
|
|
3667
|
+
* - Text strings (e.g., 'I am cool ☥') - converts UTF-8 text to bytes
|
|
3668
|
+
*
|
|
3669
|
+
* @param {string} str The string to convert
|
|
3670
|
+
* @returns {Uint8Array} The converted byte array
|
|
3671
|
+
*
|
|
3672
|
+
* @example
|
|
3673
|
+
* ```typescript
|
|
3674
|
+
* // Hex string
|
|
3675
|
+
* const hex = stringToUint8Array('0x48656c6c6f');
|
|
3676
|
+
* // result = Uint8Array(5) [ 72, 101, 108, 108, 111 ]
|
|
3677
|
+
*
|
|
3678
|
+
* // Decimal string
|
|
3679
|
+
* const decimal = stringToUint8Array('256');
|
|
3680
|
+
* // result = Uint8Array(2) [ 1, 0 ]
|
|
3681
|
+
*
|
|
3682
|
+
* // Text string
|
|
3683
|
+
* const text = stringToUint8Array('Hello ☥');
|
|
3684
|
+
* // result = UTF-8 encoded bytes
|
|
3685
|
+
* ```
|
|
3686
|
+
*/
|
|
3687
|
+
declare function stringToUint8Array(str: string): Uint8Array;
|
|
3688
|
+
/**
|
|
3689
|
+
* Convert bigint to Uint8Array (big-endian)
|
|
3690
|
+
*
|
|
3691
|
+
* @param {bigint} value The bigint value to convert (must be non-negative)
|
|
3692
|
+
* @returns {Uint8Array} The converted byte array in big-endian byte order
|
|
3693
|
+
* @throws {Error} If value is negative
|
|
3694
|
+
*
|
|
3695
|
+
* @example
|
|
3696
|
+
* ```typescript
|
|
3697
|
+
* const value = 256n; // 0x0100
|
|
3698
|
+
* const result = encode.bigIntToUint8Array(value);
|
|
3699
|
+
* // result = Uint8Array([1, 0]) - big-endian, MSB first
|
|
3700
|
+
* ```
|
|
3701
|
+
*/
|
|
3702
|
+
declare function bigIntToUint8Array(value: bigint): Uint8Array;
|
|
3703
|
+
/**
|
|
3704
|
+
* Convert Uint8Array to bigint (big-endian)
|
|
3705
|
+
*
|
|
3706
|
+
* @param {Uint8Array} data The Uint8Array to convert (interpreted as big-endian)
|
|
3707
|
+
* @returns {bigint} The converted bigint value
|
|
3708
|
+
*
|
|
3709
|
+
* @example
|
|
3710
|
+
* ```typescript
|
|
3711
|
+
* const data = new Uint8Array([1, 0]); // Big-endian representation
|
|
3712
|
+
* const result = encode.uint8ArrayToBigInt(data);
|
|
3713
|
+
* // result = 256n (0x0100)
|
|
3714
|
+
* ```
|
|
3715
|
+
*/
|
|
3716
|
+
declare function uint8ArrayToBigInt(data: Uint8Array): bigint;
|
|
3381
3717
|
|
|
3382
3718
|
declare const encode_IS_BROWSER: typeof IS_BROWSER;
|
|
3383
3719
|
declare const encode_addHexPrefix: typeof addHexPrefix;
|
|
3384
3720
|
declare const encode_arrayBufferToString: typeof arrayBufferToString;
|
|
3385
3721
|
declare const encode_atobUniversal: typeof atobUniversal;
|
|
3722
|
+
declare const encode_bigIntToUint8Array: typeof bigIntToUint8Array;
|
|
3386
3723
|
declare const encode_btoaUniversal: typeof btoaUniversal;
|
|
3387
3724
|
declare const encode_buf2hex: typeof buf2hex;
|
|
3388
3725
|
declare const encode_calcByteLength: typeof calcByteLength;
|
|
3389
3726
|
declare const encode_concatenateArrayBuffer: typeof concatenateArrayBuffer;
|
|
3727
|
+
declare const encode_hexStringToUint8Array: typeof hexStringToUint8Array;
|
|
3390
3728
|
declare const encode_padLeft: typeof padLeft;
|
|
3391
3729
|
declare const encode_pascalToSnake: typeof pascalToSnake;
|
|
3392
3730
|
declare const encode_removeHexPrefix: typeof removeHexPrefix;
|
|
3393
3731
|
declare const encode_sanitizeBytes: typeof sanitizeBytes;
|
|
3394
3732
|
declare const encode_sanitizeHex: typeof sanitizeHex;
|
|
3733
|
+
declare const encode_stringToUint8Array: typeof stringToUint8Array;
|
|
3734
|
+
declare const encode_uint8ArrayToBigInt: typeof uint8ArrayToBigInt;
|
|
3395
3735
|
declare const encode_utf8ToArray: typeof utf8ToArray;
|
|
3736
|
+
declare const encode_utf8ToBigInt: typeof utf8ToBigInt;
|
|
3737
|
+
declare const encode_utf8ToUint8Array: typeof utf8ToUint8Array;
|
|
3396
3738
|
declare namespace encode {
|
|
3397
|
-
export { encode_IS_BROWSER as IS_BROWSER, encode_addHexPrefix as addHexPrefix, encode_arrayBufferToString as arrayBufferToString, encode_atobUniversal as atobUniversal, encode_btoaUniversal as btoaUniversal, encode_buf2hex as buf2hex, encode_calcByteLength as calcByteLength, encode_concatenateArrayBuffer as concatenateArrayBuffer, encode_padLeft as padLeft, encode_pascalToSnake as pascalToSnake, encode_removeHexPrefix as removeHexPrefix, encode_sanitizeBytes as sanitizeBytes, encode_sanitizeHex as sanitizeHex, encode_utf8ToArray as utf8ToArray };
|
|
3739
|
+
export { encode_IS_BROWSER as IS_BROWSER, encode_addHexPrefix as addHexPrefix, encode_arrayBufferToString as arrayBufferToString, encode_atobUniversal as atobUniversal, encode_bigIntToUint8Array as bigIntToUint8Array, encode_btoaUniversal as btoaUniversal, encode_buf2hex as buf2hex, encode_calcByteLength as calcByteLength, encode_concatenateArrayBuffer as concatenateArrayBuffer, encode_hexStringToUint8Array as hexStringToUint8Array, encode_padLeft as padLeft, encode_pascalToSnake as pascalToSnake, encode_removeHexPrefix as removeHexPrefix, encode_sanitizeBytes as sanitizeBytes, encode_sanitizeHex as sanitizeHex, encode_stringToUint8Array as stringToUint8Array, encode_uint8ArrayToBigInt as uint8ArrayToBigInt, encode_utf8ToArray as utf8ToArray, encode_utf8ToBigInt as utf8ToBigInt, encode_utf8ToUint8Array as utf8ToUint8Array };
|
|
3398
3740
|
}
|
|
3399
3741
|
|
|
3400
3742
|
/**
|
|
@@ -3412,7 +3754,23 @@ declare const RANGE_FELT: {
|
|
|
3412
3754
|
readonly min: bigint;
|
|
3413
3755
|
readonly max: bigint;
|
|
3414
3756
|
};
|
|
3415
|
-
declare const
|
|
3757
|
+
declare const RANGE_U8: {
|
|
3758
|
+
readonly min: bigint;
|
|
3759
|
+
readonly max: bigint;
|
|
3760
|
+
};
|
|
3761
|
+
declare const RANGE_U16: {
|
|
3762
|
+
readonly min: bigint;
|
|
3763
|
+
readonly max: bigint;
|
|
3764
|
+
};
|
|
3765
|
+
declare const RANGE_U32: {
|
|
3766
|
+
readonly min: bigint;
|
|
3767
|
+
readonly max: bigint;
|
|
3768
|
+
};
|
|
3769
|
+
declare const RANGE_U64: {
|
|
3770
|
+
readonly min: bigint;
|
|
3771
|
+
readonly max: bigint;
|
|
3772
|
+
};
|
|
3773
|
+
declare const RANGE_U96: {
|
|
3416
3774
|
readonly min: bigint;
|
|
3417
3775
|
readonly max: bigint;
|
|
3418
3776
|
};
|
|
@@ -3420,6 +3778,26 @@ declare const RANGE_U128: {
|
|
|
3420
3778
|
readonly min: bigint;
|
|
3421
3779
|
readonly max: bigint;
|
|
3422
3780
|
};
|
|
3781
|
+
declare const RANGE_I8: {
|
|
3782
|
+
readonly min: bigint;
|
|
3783
|
+
readonly max: bigint;
|
|
3784
|
+
};
|
|
3785
|
+
declare const RANGE_I16: {
|
|
3786
|
+
readonly min: bigint;
|
|
3787
|
+
readonly max: bigint;
|
|
3788
|
+
};
|
|
3789
|
+
declare const RANGE_I32: {
|
|
3790
|
+
readonly min: bigint;
|
|
3791
|
+
readonly max: bigint;
|
|
3792
|
+
};
|
|
3793
|
+
declare const RANGE_I64: {
|
|
3794
|
+
readonly min: bigint;
|
|
3795
|
+
readonly max: bigint;
|
|
3796
|
+
};
|
|
3797
|
+
declare const RANGE_I128: {
|
|
3798
|
+
readonly min: bigint;
|
|
3799
|
+
readonly max: bigint;
|
|
3800
|
+
};
|
|
3423
3801
|
declare const LegacyUDC: {
|
|
3424
3802
|
readonly ADDRESS: "0x041a78e741e5af2fec34b695679bc6891742439f7afb8484ecd7766661ad02bf";
|
|
3425
3803
|
readonly ENTRYPOINT: "deployContract";
|
|
@@ -3481,6 +3859,7 @@ declare const DEFAULT_GLOBAL_CONFIG: {
|
|
|
3481
3859
|
defaultTipType: TipType;
|
|
3482
3860
|
fetch: any;
|
|
3483
3861
|
websocket: any;
|
|
3862
|
+
buffer: any;
|
|
3484
3863
|
};
|
|
3485
3864
|
declare const RPC_DEFAULT_NODES: {
|
|
3486
3865
|
readonly SN_MAIN: readonly ["https://starknet-mainnet.public.blastapi.io/rpc/"];
|
|
@@ -3499,6 +3878,9 @@ declare const SYSTEM_MESSAGES: {
|
|
|
3499
3878
|
maxFeeInV3: string;
|
|
3500
3879
|
declareNonSierra: string;
|
|
3501
3880
|
unsupportedMethodForRpcVersion: string;
|
|
3881
|
+
txEvictedFromMempool: string;
|
|
3882
|
+
consensusFailed: string;
|
|
3883
|
+
txFailsBlockBuildingValidation: string;
|
|
3502
3884
|
};
|
|
3503
3885
|
|
|
3504
3886
|
declare const constants_ADDR_BOUND: typeof ADDR_BOUND;
|
|
@@ -3516,7 +3898,16 @@ declare const constants_PAYMASTER_RPC_NODES: typeof PAYMASTER_RPC_NODES;
|
|
|
3516
3898
|
declare const constants_PRIME: typeof PRIME;
|
|
3517
3899
|
declare const constants_RANGE_FELT: typeof RANGE_FELT;
|
|
3518
3900
|
declare const constants_RANGE_I128: typeof RANGE_I128;
|
|
3901
|
+
declare const constants_RANGE_I16: typeof RANGE_I16;
|
|
3902
|
+
declare const constants_RANGE_I32: typeof RANGE_I32;
|
|
3903
|
+
declare const constants_RANGE_I64: typeof RANGE_I64;
|
|
3904
|
+
declare const constants_RANGE_I8: typeof RANGE_I8;
|
|
3519
3905
|
declare const constants_RANGE_U128: typeof RANGE_U128;
|
|
3906
|
+
declare const constants_RANGE_U16: typeof RANGE_U16;
|
|
3907
|
+
declare const constants_RANGE_U32: typeof RANGE_U32;
|
|
3908
|
+
declare const constants_RANGE_U64: typeof RANGE_U64;
|
|
3909
|
+
declare const constants_RANGE_U8: typeof RANGE_U8;
|
|
3910
|
+
declare const constants_RANGE_U96: typeof RANGE_U96;
|
|
3520
3911
|
declare const constants_RPC_DEFAULT_NODES: typeof RPC_DEFAULT_NODES;
|
|
3521
3912
|
declare const constants_SNIP9_V1_INTERFACE_ID: typeof SNIP9_V1_INTERFACE_ID;
|
|
3522
3913
|
declare const constants_SNIP9_V2_INTERFACE_ID: typeof SNIP9_V2_INTERFACE_ID;
|
|
@@ -3527,7 +3918,7 @@ declare const constants_TEXT_TO_FELT_MAX_LEN: typeof TEXT_TO_FELT_MAX_LEN;
|
|
|
3527
3918
|
declare const constants_UDC: typeof UDC;
|
|
3528
3919
|
declare const constants_ZERO: typeof ZERO;
|
|
3529
3920
|
declare namespace constants {
|
|
3530
|
-
export { constants_ADDR_BOUND as ADDR_BOUND, constants_API_VERSION as API_VERSION, _BaseUrl as BaseUrl, constants_DEFAULT_GLOBAL_CONFIG as DEFAULT_GLOBAL_CONFIG, constants_HARDENING_4BYTES as HARDENING_4BYTES, constants_HARDENING_BYTE as HARDENING_BYTE, constants_IS_BROWSER as IS_BROWSER, constants_LegacyUDC as LegacyUDC, constants_MASK_250 as MASK_250, constants_MASK_31 as MASK_31, constants_MAX_STORAGE_ITEM_SIZE as MAX_STORAGE_ITEM_SIZE, _NetworkName as NetworkName, constants_OutsideExecutionCallerAny as OutsideExecutionCallerAny, constants_PAYMASTER_RPC_NODES as PAYMASTER_RPC_NODES, constants_PRIME as PRIME, constants_RANGE_FELT as RANGE_FELT, constants_RANGE_I128 as RANGE_I128, constants_RANGE_U128 as RANGE_U128, constants_RPC_DEFAULT_NODES as RPC_DEFAULT_NODES, constants_SNIP9_V1_INTERFACE_ID as SNIP9_V1_INTERFACE_ID, constants_SNIP9_V2_INTERFACE_ID as SNIP9_V2_INTERFACE_ID, constants_SYSTEM_MESSAGES as SYSTEM_MESSAGES, _StarknetChainId as StarknetChainId, type constants_SupportedCairoVersion as SupportedCairoVersion, _SupportedRpcVersion as SupportedRpcVersion, type constants_SupportedTransactionVersion as SupportedTransactionVersion, constants_TEXT_TO_FELT_MAX_LEN as TEXT_TO_FELT_MAX_LEN, _TransactionHashPrefix as TransactionHashPrefix, constants_UDC as UDC, constants_ZERO as ZERO };
|
|
3921
|
+
export { constants_ADDR_BOUND as ADDR_BOUND, constants_API_VERSION as API_VERSION, _BaseUrl as BaseUrl, constants_DEFAULT_GLOBAL_CONFIG as DEFAULT_GLOBAL_CONFIG, constants_HARDENING_4BYTES as HARDENING_4BYTES, constants_HARDENING_BYTE as HARDENING_BYTE, constants_IS_BROWSER as IS_BROWSER, constants_LegacyUDC as LegacyUDC, constants_MASK_250 as MASK_250, constants_MASK_31 as MASK_31, constants_MAX_STORAGE_ITEM_SIZE as MAX_STORAGE_ITEM_SIZE, _NetworkName as NetworkName, constants_OutsideExecutionCallerAny as OutsideExecutionCallerAny, constants_PAYMASTER_RPC_NODES as PAYMASTER_RPC_NODES, constants_PRIME as PRIME, constants_RANGE_FELT as RANGE_FELT, constants_RANGE_I128 as RANGE_I128, constants_RANGE_I16 as RANGE_I16, constants_RANGE_I32 as RANGE_I32, constants_RANGE_I64 as RANGE_I64, constants_RANGE_I8 as RANGE_I8, constants_RANGE_U128 as RANGE_U128, constants_RANGE_U16 as RANGE_U16, constants_RANGE_U32 as RANGE_U32, constants_RANGE_U64 as RANGE_U64, constants_RANGE_U8 as RANGE_U8, constants_RANGE_U96 as RANGE_U96, constants_RPC_DEFAULT_NODES as RPC_DEFAULT_NODES, constants_SNIP9_V1_INTERFACE_ID as SNIP9_V1_INTERFACE_ID, constants_SNIP9_V2_INTERFACE_ID as SNIP9_V2_INTERFACE_ID, constants_SYSTEM_MESSAGES as SYSTEM_MESSAGES, _StarknetChainId as StarknetChainId, type constants_SupportedCairoVersion as SupportedCairoVersion, _SupportedRpcVersion as SupportedRpcVersion, type constants_SupportedTransactionVersion as SupportedTransactionVersion, constants_TEXT_TO_FELT_MAX_LEN as TEXT_TO_FELT_MAX_LEN, _TransactionHashPrefix as TransactionHashPrefix, constants_UDC as UDC, constants_ZERO as ZERO };
|
|
3531
3922
|
}
|
|
3532
3923
|
|
|
3533
3924
|
declare class RpcChannel$1 {
|
|
@@ -4189,7 +4580,7 @@ declare class RpcError<BaseErrorT extends RPC_ERROR = RPC_ERROR> extends Library
|
|
|
4189
4580
|
params: any;
|
|
4190
4581
|
};
|
|
4191
4582
|
constructor(baseError: BaseErrorT, method: string, params: any);
|
|
4192
|
-
get code(): 1 | 66 | 10 | 31 | 20 |
|
|
4583
|
+
get code(): 1 | 66 | 10 | 31 | 20 | 21 | 24 | 27 | 28 | 29 | 32 | 33 | 34 | 40 | 41 | 42 | 51 | 52 | 53 | 54 | 55 | 56 | 57 | 58 | 59 | 60 | 61 | 62 | 63 | 67 | 68 | 100 | 150 | 151 | 153 | 154 | 155 | 156 | 157 | 158 | 159 | 160 | 163;
|
|
4193
4584
|
/**
|
|
4194
4585
|
* Verifies the underlying RPC error, also serves as a type guard for the _baseError_ property
|
|
4195
4586
|
* @example
|
|
@@ -4847,6 +5238,8 @@ declare class Contract implements ContractInterface {
|
|
|
4847
5238
|
address: string;
|
|
4848
5239
|
providerOrAccount: ProviderOrAccount;
|
|
4849
5240
|
classHash?: string;
|
|
5241
|
+
parseRequest: boolean;
|
|
5242
|
+
parseResponse: boolean;
|
|
4850
5243
|
private structs;
|
|
4851
5244
|
private events;
|
|
4852
5245
|
readonly functions: {
|
|
@@ -4864,6 +5257,7 @@ declare class Contract implements ContractInterface {
|
|
|
4864
5257
|
readonly [key: string]: AsyncContractFunction | any;
|
|
4865
5258
|
private callData;
|
|
4866
5259
|
withOptionsProps?: WithOptions;
|
|
5260
|
+
private parsingStrategy?;
|
|
4867
5261
|
/**
|
|
4868
5262
|
* @param options
|
|
4869
5263
|
* - abi: Abi of the contract object (required)
|
|
@@ -4871,13 +5265,20 @@ declare class Contract implements ContractInterface {
|
|
|
4871
5265
|
* - providerOrAccount?: Provider or Account to attach to (fallback to defaultProvider)
|
|
4872
5266
|
* - parseRequest?: compile and validate arguments (optional, default true)
|
|
4873
5267
|
* - parseResponse?: Parse elements of the response array and structuring them into response object (optional, default true)
|
|
5268
|
+
* - parser?: Abi parser (optional, default createAbiParser(options.abi))
|
|
4874
5269
|
*/
|
|
4875
5270
|
constructor(options: ContractOptions);
|
|
4876
5271
|
withOptions(options: WithOptions): this;
|
|
4877
5272
|
attach(address: string, abi?: Abi): void;
|
|
4878
|
-
isDeployed(): Promise<
|
|
5273
|
+
isDeployed(): Promise<this>;
|
|
4879
5274
|
call(method: string, args?: ArgsOrCalldata, { parseRequest, parseResponse, formatResponse, blockIdentifier, }?: CallOptions): Promise<CallResult>;
|
|
4880
|
-
invoke(method: string, args
|
|
5275
|
+
invoke(method: string, args: ArgsOrCalldata, options: ExecuteOptions & {
|
|
5276
|
+
waitForTransaction: true;
|
|
5277
|
+
}): Promise<SuccessfulTransactionReceiptResponseHelper>;
|
|
5278
|
+
invoke(method: string, args: ArgsOrCalldata, options: ExecuteOptions & {
|
|
5279
|
+
waitForTransaction: false;
|
|
5280
|
+
}): Promise<InvokeFunctionResponse>;
|
|
5281
|
+
invoke(method: string, args?: ArgsOrCalldata, options?: ExecuteOptions): Promise<InvokeFunctionResponse>;
|
|
4881
5282
|
estimate(method: string, args?: ArgsOrCalldata, estimateDetails?: UniversalDetails): Promise<EstimateFeeResponseOverhead>;
|
|
4882
5283
|
populate(method: string, args?: RawArgs): Call;
|
|
4883
5284
|
parseEvents(receipt: GetTransactionReceiptResponse): ParsedEvents;
|
|
@@ -5472,6 +5873,7 @@ declare namespace json {
|
|
|
5472
5873
|
* ```
|
|
5473
5874
|
*/
|
|
5474
5875
|
declare function isHex(hex: string): boolean;
|
|
5876
|
+
declare const isHexString: typeof isHex;
|
|
5475
5877
|
/**
|
|
5476
5878
|
* Convert BigNumberish to bigint
|
|
5477
5879
|
*
|
|
@@ -5729,7 +6131,7 @@ declare function addPercent(number: BigNumberish, percent: number): bigint;
|
|
|
5729
6131
|
declare function stringToSha256ToArrayBuff4(str: string): Uint8Array;
|
|
5730
6132
|
/**
|
|
5731
6133
|
* Checks if a given value is of BigNumberish type.
|
|
5732
|
-
* 234, 234n, "234", "0xea" are valid
|
|
6134
|
+
* 234, 234n, "234", "0xea" are valid, exclude boolean and string
|
|
5733
6135
|
* @param {unknown} input a value
|
|
5734
6136
|
* @returns {boolean} true if type of input is `BigNumberish`
|
|
5735
6137
|
* @example
|
|
@@ -5739,6 +6141,14 @@ declare function stringToSha256ToArrayBuff4(str: string): Uint8Array;
|
|
|
5739
6141
|
* ```
|
|
5740
6142
|
*/
|
|
5741
6143
|
declare function isBigNumberish(input: unknown): input is BigNumberish;
|
|
6144
|
+
/**
|
|
6145
|
+
* Expect the next value from an iterator
|
|
6146
|
+
*
|
|
6147
|
+
* @param iterator The iterator to get the next value from.
|
|
6148
|
+
* @returns The next value from the iterator.
|
|
6149
|
+
* @throws Error if the iterator is done.
|
|
6150
|
+
*/
|
|
6151
|
+
declare function getNext(iterator: Iterator<string>): string;
|
|
5742
6152
|
|
|
5743
6153
|
declare const num_addPercent: typeof addPercent;
|
|
5744
6154
|
declare const num_assertInRange: typeof assertInRange;
|
|
@@ -5748,10 +6158,12 @@ declare const num_cleanHex: typeof cleanHex;
|
|
|
5748
6158
|
declare const num_getDecimalString: typeof getDecimalString;
|
|
5749
6159
|
declare const num_getHexString: typeof getHexString;
|
|
5750
6160
|
declare const num_getHexStringArray: typeof getHexStringArray;
|
|
6161
|
+
declare const num_getNext: typeof getNext;
|
|
5751
6162
|
declare const num_hexToBytes: typeof hexToBytes;
|
|
5752
6163
|
declare const num_hexToDecimalString: typeof hexToDecimalString;
|
|
5753
6164
|
declare const num_isBigNumberish: typeof isBigNumberish;
|
|
5754
6165
|
declare const num_isHex: typeof isHex;
|
|
6166
|
+
declare const num_isHexString: typeof isHexString;
|
|
5755
6167
|
declare const num_isStringWholeNumber: typeof isStringWholeNumber;
|
|
5756
6168
|
declare const num_stringToSha256ToArrayBuff4: typeof stringToSha256ToArrayBuff4;
|
|
5757
6169
|
declare const num_toBigInt: typeof toBigInt;
|
|
@@ -5762,7 +6174,7 @@ declare const num_toHexString: typeof toHexString;
|
|
|
5762
6174
|
declare const num_toStorageKey: typeof toStorageKey;
|
|
5763
6175
|
declare const num_tryToBigInt: typeof tryToBigInt;
|
|
5764
6176
|
declare namespace num {
|
|
5765
|
-
export { num_addPercent as addPercent, num_assertInRange as assertInRange, num_bigNumberishArrayToDecimalStringArray as bigNumberishArrayToDecimalStringArray, num_bigNumberishArrayToHexadecimalStringArray as bigNumberishArrayToHexadecimalStringArray, num_cleanHex as cleanHex, num_getDecimalString as getDecimalString, num_getHexString as getHexString, num_getHexStringArray as getHexStringArray, num_hexToBytes as hexToBytes, num_hexToDecimalString as hexToDecimalString, num_isBigNumberish as isBigNumberish, num_isHex as isHex, num_isStringWholeNumber as isStringWholeNumber, num_stringToSha256ToArrayBuff4 as stringToSha256ToArrayBuff4, num_toBigInt as toBigInt, num_toCairoBool as toCairoBool, num_toHex as toHex, num_toHex64 as toHex64, num_toHexString as toHexString, num_toStorageKey as toStorageKey, num_tryToBigInt as tryToBigInt };
|
|
6177
|
+
export { num_addPercent as addPercent, num_assertInRange as assertInRange, num_bigNumberishArrayToDecimalStringArray as bigNumberishArrayToDecimalStringArray, num_bigNumberishArrayToHexadecimalStringArray as bigNumberishArrayToHexadecimalStringArray, num_cleanHex as cleanHex, num_getDecimalString as getDecimalString, num_getHexString as getHexString, num_getHexStringArray as getHexStringArray, num_getNext as getNext, num_hexToBytes as hexToBytes, num_hexToDecimalString as hexToDecimalString, num_isBigNumberish as isBigNumberish, num_isHex as isHex, num_isHexString as isHexString, num_isStringWholeNumber as isStringWholeNumber, num_stringToSha256ToArrayBuff4 as stringToSha256ToArrayBuff4, num_toBigInt as toBigInt, num_toCairoBool as toCairoBool, num_toHex as toHex, num_toHex64 as toHex64, num_toHexString as toHexString, num_toStorageKey as toStorageKey, num_tryToBigInt as tryToBigInt };
|
|
5766
6178
|
}
|
|
5767
6179
|
|
|
5768
6180
|
/**
|
|
@@ -6012,16 +6424,40 @@ declare function signatureToDecimalArray(sig?: Signature): ArraySignatureType;
|
|
|
6012
6424
|
* ```
|
|
6013
6425
|
*/
|
|
6014
6426
|
declare function signatureToHexArray(sig?: Signature): ArraySignatureType;
|
|
6427
|
+
/**
|
|
6428
|
+
* Returns a resource bounds with zero values and no overhead.
|
|
6429
|
+
* @returns {ResourceBoundsBN} A resource bounds with zero values and no overhead.
|
|
6430
|
+
*/
|
|
6431
|
+
declare function zeroResourceBounds(): ResourceBoundsBN;
|
|
6015
6432
|
/**
|
|
6016
6433
|
* Calculates the maximum resource bounds for fee estimation.
|
|
6017
6434
|
*
|
|
6018
|
-
* @param {FeeEstimate
|
|
6019
|
-
* @param {ResourceBoundsOverhead} [overhead] - The percentage overhead added to the max units and max price per unit.
|
|
6435
|
+
* @param {FeeEstimate} estimate The estimate for the fee.
|
|
6436
|
+
* @param {ResourceBoundsOverhead | false} [overhead] - The percentage overhead added to the max units and max price per unit. Pass `false` to disable overhead.
|
|
6020
6437
|
* @returns {ResourceBoundsBN} The resource bounds with overhead represented as BigInt.
|
|
6021
6438
|
* @throws {Error} If the estimate object is undefined or does not have the required properties.
|
|
6022
6439
|
*/
|
|
6023
|
-
declare function toOverheadResourceBounds(estimate: FeeEstimate, overhead?: ResourceBoundsOverhead): ResourceBoundsBN;
|
|
6024
|
-
|
|
6440
|
+
declare function toOverheadResourceBounds(estimate: FeeEstimate, overhead?: ResourceBoundsOverhead | false): ResourceBoundsBN;
|
|
6441
|
+
/**
|
|
6442
|
+
* Converts a resource bounds to an estimate fee response. No overhead is applied.
|
|
6443
|
+
* @param {ResourceBoundsBN} resourceBounds - The resource bounds to convert.
|
|
6444
|
+
* @returns {EstimateFeeResponseOverhead} The estimate fee response.
|
|
6445
|
+
* @example
|
|
6446
|
+
* ```typescript
|
|
6447
|
+
* const resourceBounds = {
|
|
6448
|
+
* l1_gas: { max_amount: 1000n, max_price_per_unit: 100n },
|
|
6449
|
+
* l2_gas: { max_amount: 2000n, max_price_per_unit: 200n },
|
|
6450
|
+
* l1_data_gas: { max_amount: 500n, max_price_per_unit: 50n }
|
|
6451
|
+
* };
|
|
6452
|
+
* const result = stark.resourceBoundsToEstimateFeeResponse(resourceBounds);
|
|
6453
|
+
* // result = {
|
|
6454
|
+
* // resourceBounds: resourceBounds,
|
|
6455
|
+
* // overall_fee: 129000n,
|
|
6456
|
+
* // unit: 'FRI'
|
|
6457
|
+
* // }
|
|
6458
|
+
* ```
|
|
6459
|
+
*/
|
|
6460
|
+
declare function resourceBoundsToEstimateFeeResponse(resourceBounds: ResourceBoundsBN): EstimateFeeResponseOverhead;
|
|
6025
6461
|
/**
|
|
6026
6462
|
* Calculates the overall fee for a transaction based on resource consumption and prices.
|
|
6027
6463
|
*
|
|
@@ -6029,7 +6465,7 @@ declare function resourceBoundsToEstimateFee(resourceBounds: ResourceBoundsBN):
|
|
|
6029
6465
|
* l1_gas_consumed*l1_gas_price + l1_data_gas_consumed*l1_data_gas_price + l2_gas_consumed*l2_gas_price
|
|
6030
6466
|
*
|
|
6031
6467
|
* @param {FeeEstimate} estimate - The fee estimate containing gas consumption and price data
|
|
6032
|
-
* @param {ResourceBoundsOverhead} overhead - The overhead percentage
|
|
6468
|
+
* @param {ResourceBoundsOverhead | false} overhead - The overhead percentage. Pass `false` to disable overhead.
|
|
6033
6469
|
* @returns {bigint} The calculated overall fee in wei or fri
|
|
6034
6470
|
* @example
|
|
6035
6471
|
* ```typescript
|
|
@@ -6045,9 +6481,9 @@ declare function resourceBoundsToEstimateFee(resourceBounds: ResourceBoundsBN):
|
|
|
6045
6481
|
* // result = 1000n * 100n + 500n * 50n + 200n * 20n = 129000n
|
|
6046
6482
|
* ```
|
|
6047
6483
|
*/
|
|
6048
|
-
declare function toOverheadOverallFee(estimate: FeeEstimate, overhead?: ResourceBoundsOverhead): bigint;
|
|
6484
|
+
declare function toOverheadOverallFee(estimate: FeeEstimate, overhead?: ResourceBoundsOverhead | false): bigint;
|
|
6049
6485
|
/**
|
|
6050
|
-
* Mock zero fee response
|
|
6486
|
+
* Mock zero fee API response
|
|
6051
6487
|
*/
|
|
6052
6488
|
declare function ZeroFeeEstimate(): FeeEstimate;
|
|
6053
6489
|
/**
|
|
@@ -6173,7 +6609,7 @@ declare const index$1_getFullPublicKey: typeof getFullPublicKey;
|
|
|
6173
6609
|
declare const index$1_intDAM: typeof intDAM;
|
|
6174
6610
|
declare const index$1_randomAddress: typeof randomAddress;
|
|
6175
6611
|
declare const index$1_resourceBoundsToBigInt: typeof resourceBoundsToBigInt;
|
|
6176
|
-
declare const index$
|
|
6612
|
+
declare const index$1_resourceBoundsToEstimateFeeResponse: typeof resourceBoundsToEstimateFeeResponse;
|
|
6177
6613
|
declare const index$1_resourceBoundsToHexString: typeof resourceBoundsToHexString;
|
|
6178
6614
|
declare const index$1_signatureToDecimalArray: typeof signatureToDecimalArray;
|
|
6179
6615
|
declare const index$1_signatureToHexArray: typeof signatureToHexArray;
|
|
@@ -6182,8 +6618,9 @@ declare const index$1_toOverheadOverallFee: typeof toOverheadOverallFee;
|
|
|
6182
6618
|
declare const index$1_toOverheadResourceBounds: typeof toOverheadResourceBounds;
|
|
6183
6619
|
declare const index$1_toTransactionVersion: typeof toTransactionVersion;
|
|
6184
6620
|
declare const index$1_v3Details: typeof v3Details;
|
|
6621
|
+
declare const index$1_zeroResourceBounds: typeof zeroResourceBounds;
|
|
6185
6622
|
declare namespace index$1 {
|
|
6186
|
-
export { index$1_ZeroFeeEstimate as ZeroFeeEstimate, index$1_compressProgram as compressProgram, index$1_decompressProgram as decompressProgram, index$1_formatSignature as formatSignature, index$1_getFullPublicKey as getFullPublicKey, index$1_intDAM as intDAM, index$1_randomAddress as randomAddress, index$1_resourceBoundsToBigInt as resourceBoundsToBigInt, index$
|
|
6623
|
+
export { index$1_ZeroFeeEstimate as ZeroFeeEstimate, index$1_compressProgram as compressProgram, index$1_decompressProgram as decompressProgram, index$1_formatSignature as formatSignature, index$1_getFullPublicKey as getFullPublicKey, index$1_intDAM as intDAM, index$1_randomAddress as randomAddress, index$1_resourceBoundsToBigInt as resourceBoundsToBigInt, index$1_resourceBoundsToEstimateFeeResponse as resourceBoundsToEstimateFeeResponse, index$1_resourceBoundsToHexString as resourceBoundsToHexString, index$1_signatureToDecimalArray as signatureToDecimalArray, index$1_signatureToHexArray as signatureToHexArray, index$1_toFeeVersion as toFeeVersion, index$1_toOverheadOverallFee as toOverheadOverallFee, index$1_toOverheadResourceBounds as toOverheadResourceBounds, index$1_toTransactionVersion as toTransactionVersion, index$1_v3Details as v3Details, index$1_zeroResourceBounds as zeroResourceBounds };
|
|
6187
6624
|
}
|
|
6188
6625
|
|
|
6189
6626
|
/**
|
|
@@ -6404,7 +6841,7 @@ declare function isDecimalString(str: string): boolean;
|
|
|
6404
6841
|
* // result = false
|
|
6405
6842
|
* ```
|
|
6406
6843
|
*/
|
|
6407
|
-
declare function isText(val: any):
|
|
6844
|
+
declare function isText(val: any): val is string;
|
|
6408
6845
|
/**
|
|
6409
6846
|
* Test if value is short text
|
|
6410
6847
|
* @param {any} val - The item to test
|
|
@@ -6439,6 +6876,7 @@ declare const isLongText: (val: any) => boolean;
|
|
|
6439
6876
|
*/
|
|
6440
6877
|
declare function splitLongString(longStr: string): string[];
|
|
6441
6878
|
/**
|
|
6879
|
+
* @deprecated use Utf8 instead
|
|
6442
6880
|
* Convert an ASCII short string to a hexadecimal string.
|
|
6443
6881
|
* @param {string} str short string (ASCII string, 31 characters max)
|
|
6444
6882
|
* @returns {string} hex-string with 248 bits max
|
|
@@ -6450,6 +6888,7 @@ declare function splitLongString(longStr: string): string[];
|
|
|
6450
6888
|
*/
|
|
6451
6889
|
declare function encodeShortString(str: string): string;
|
|
6452
6890
|
/**
|
|
6891
|
+
* @deprecated use Utf8 instead
|
|
6453
6892
|
* Convert a hexadecimal or decimal string to an ASCII string.
|
|
6454
6893
|
* @param {string} str representing a 248 bit max number (ex. "0x1A4F64EA56" or "236942575435676423")
|
|
6455
6894
|
* @returns {string} short string; 31 characters max
|
|
@@ -7190,7 +7629,7 @@ declare function getAbiEvents(abi: Abi): AbiEvents;
|
|
|
7190
7629
|
}}]
|
|
7191
7630
|
* ```
|
|
7192
7631
|
*/
|
|
7193
|
-
declare function parseEvents(providerReceivedEvents: EmittedEvent$1[], abiEvents: AbiEvents, abiStructs: AbiStructs, abiEnums: AbiEnums): ParsedEvents;
|
|
7632
|
+
declare function parseEvents(providerReceivedEvents: EmittedEvent$1[], abiEvents: AbiEvents, abiStructs: AbiStructs, abiEnums: AbiEnums, parser: AbiParserInterface): ParsedEvents;
|
|
7194
7633
|
|
|
7195
7634
|
declare const index_getAbiEvents: typeof getAbiEvents;
|
|
7196
7635
|
declare const index_isAbiEvent: typeof isAbiEvent;
|
|
@@ -7478,6 +7917,96 @@ declare class BatchClient<T extends {
|
|
|
7478
7917
|
}>(method: M, params?: T[M]['params'], id?: string | number): Promise<TResponse>;
|
|
7479
7918
|
}
|
|
7480
7919
|
|
|
7920
|
+
declare class CairoUint8 {
|
|
7921
|
+
data: bigint;
|
|
7922
|
+
static abiSelector: string;
|
|
7923
|
+
constructor(data: BigNumberish | boolean | unknown);
|
|
7924
|
+
static __processData(data: BigNumberish | boolean | unknown): bigint;
|
|
7925
|
+
toApiRequest(): string[];
|
|
7926
|
+
toBigInt(): bigint;
|
|
7927
|
+
decodeUtf8(): string;
|
|
7928
|
+
toHexString(): string;
|
|
7929
|
+
static validate(data: BigNumberish | boolean | unknown): void;
|
|
7930
|
+
static is(data: BigNumberish | boolean | unknown): boolean;
|
|
7931
|
+
/**
|
|
7932
|
+
* Check if provided abi type is this data type
|
|
7933
|
+
*/
|
|
7934
|
+
static isAbiType(abiType: string): boolean;
|
|
7935
|
+
static factoryFromApiResponse(responseIterator: Iterator<string>): CairoUint8;
|
|
7936
|
+
}
|
|
7937
|
+
|
|
7938
|
+
declare class CairoUint16 {
|
|
7939
|
+
data: bigint;
|
|
7940
|
+
static abiSelector: string;
|
|
7941
|
+
constructor(data: BigNumberish | boolean | unknown);
|
|
7942
|
+
static __processData(data: BigNumberish | boolean | unknown): bigint;
|
|
7943
|
+
toApiRequest(): string[];
|
|
7944
|
+
toBigInt(): bigint;
|
|
7945
|
+
decodeUtf8(): string;
|
|
7946
|
+
toHexString(): string;
|
|
7947
|
+
static validate(data: BigNumberish | boolean | unknown): void;
|
|
7948
|
+
static is(data: BigNumberish | boolean | unknown): boolean;
|
|
7949
|
+
/**
|
|
7950
|
+
* Check if provided abi type is this data type
|
|
7951
|
+
*/
|
|
7952
|
+
static isAbiType(abiType: string): boolean;
|
|
7953
|
+
static factoryFromApiResponse(responseIterator: Iterator<string>): CairoUint16;
|
|
7954
|
+
}
|
|
7955
|
+
|
|
7956
|
+
declare class CairoUint64 {
|
|
7957
|
+
data: bigint;
|
|
7958
|
+
static abiSelector: string;
|
|
7959
|
+
constructor(data: BigNumberish | boolean | unknown);
|
|
7960
|
+
static __processData(data: BigNumberish | boolean | unknown): bigint;
|
|
7961
|
+
toApiRequest(): string[];
|
|
7962
|
+
toBigInt(): bigint;
|
|
7963
|
+
decodeUtf8(): string;
|
|
7964
|
+
toHexString(): string;
|
|
7965
|
+
static validate(data: BigNumberish | boolean | unknown): void;
|
|
7966
|
+
static is(data: BigNumberish | boolean | unknown): boolean;
|
|
7967
|
+
/**
|
|
7968
|
+
* Check if provided abi type is this data type
|
|
7969
|
+
*/
|
|
7970
|
+
static isAbiType(abiType: string): boolean;
|
|
7971
|
+
static factoryFromApiResponse(responseIterator: Iterator<string>): CairoUint64;
|
|
7972
|
+
}
|
|
7973
|
+
|
|
7974
|
+
declare class CairoUint96 {
|
|
7975
|
+
data: bigint;
|
|
7976
|
+
static abiSelector: string;
|
|
7977
|
+
constructor(data: BigNumberish | boolean | unknown);
|
|
7978
|
+
static __processData(data: BigNumberish | boolean | unknown): bigint;
|
|
7979
|
+
toApiRequest(): string[];
|
|
7980
|
+
toBigInt(): bigint;
|
|
7981
|
+
decodeUtf8(): string;
|
|
7982
|
+
toHexString(): string;
|
|
7983
|
+
static validate(data: BigNumberish | boolean | unknown): void;
|
|
7984
|
+
static is(data: BigNumberish | boolean | unknown): boolean;
|
|
7985
|
+
/**
|
|
7986
|
+
* Check if provided abi type is this data type
|
|
7987
|
+
*/
|
|
7988
|
+
static isAbiType(abiType: string): boolean;
|
|
7989
|
+
static factoryFromApiResponse(responseIterator: Iterator<string>): CairoUint96;
|
|
7990
|
+
}
|
|
7991
|
+
|
|
7992
|
+
declare class CairoUint128 {
|
|
7993
|
+
data: bigint;
|
|
7994
|
+
static abiSelector: string;
|
|
7995
|
+
constructor(data: BigNumberish | boolean | unknown);
|
|
7996
|
+
static __processData(data: BigNumberish | boolean | unknown): bigint;
|
|
7997
|
+
toApiRequest(): string[];
|
|
7998
|
+
toBigInt(): bigint;
|
|
7999
|
+
decodeUtf8(): string;
|
|
8000
|
+
toHexString(): string;
|
|
8001
|
+
static validate(data: BigNumberish | boolean | unknown): void;
|
|
8002
|
+
static is(data: BigNumberish | boolean | unknown): boolean;
|
|
8003
|
+
/**
|
|
8004
|
+
* Check if provided abi type is this data type
|
|
8005
|
+
*/
|
|
8006
|
+
static isAbiType(abiType: string): boolean;
|
|
8007
|
+
static factoryFromApiResponse(responseIterator: Iterator<string>): CairoUint128;
|
|
8008
|
+
}
|
|
8009
|
+
|
|
7481
8010
|
/**
|
|
7482
8011
|
* Singular class handling cairo u256 data type
|
|
7483
8012
|
*/
|
|
@@ -7492,24 +8021,19 @@ declare const UINT_256_HIGH_MIN = 0n;
|
|
|
7492
8021
|
declare class CairoUint256 {
|
|
7493
8022
|
low: bigint;
|
|
7494
8023
|
high: bigint;
|
|
7495
|
-
static abiSelector:
|
|
8024
|
+
static abiSelector: "core::integer::u256";
|
|
7496
8025
|
/**
|
|
7497
8026
|
* Default constructor (Lib usage)
|
|
7498
|
-
* @param bigNumberish BigNumberish value representing uin256
|
|
7499
8027
|
*/
|
|
7500
|
-
constructor(
|
|
8028
|
+
constructor(data: BigNumberish | Uint256 | unknown);
|
|
7501
8029
|
/**
|
|
7502
8030
|
* Direct props initialization (Api response)
|
|
7503
8031
|
*/
|
|
7504
8032
|
constructor(low: BigNumberish, high: BigNumberish);
|
|
7505
|
-
/**
|
|
7506
|
-
* Initialization from Uint256 object
|
|
7507
|
-
*/
|
|
7508
|
-
constructor(uint256: Uint256);
|
|
7509
8033
|
/**
|
|
7510
8034
|
* Validate if BigNumberish can be represented as Unit256
|
|
7511
8035
|
*/
|
|
7512
|
-
static validate(bigNumberish: BigNumberish): bigint;
|
|
8036
|
+
static validate(bigNumberish: BigNumberish | unknown): bigint;
|
|
7513
8037
|
/**
|
|
7514
8038
|
* Validate if low and high can be represented as Unit256
|
|
7515
8039
|
*/
|
|
@@ -7520,11 +8044,12 @@ declare class CairoUint256 {
|
|
|
7520
8044
|
/**
|
|
7521
8045
|
* Check if BigNumberish can be represented as Unit256
|
|
7522
8046
|
*/
|
|
7523
|
-
static is(bigNumberish: BigNumberish): boolean;
|
|
8047
|
+
static is(bigNumberish: BigNumberish | unknown): boolean;
|
|
7524
8048
|
/**
|
|
7525
8049
|
* Check if provided abi type is this data type
|
|
7526
8050
|
*/
|
|
7527
|
-
static isAbiType(abiType: string):
|
|
8051
|
+
static isAbiType(abiType: string): abiType is "core::integer::u256";
|
|
8052
|
+
static factoryFromApiResponse(responseIterator: Iterator<string>): CairoUint256;
|
|
7528
8053
|
/**
|
|
7529
8054
|
* Return bigint representation
|
|
7530
8055
|
*/
|
|
@@ -7566,21 +8091,16 @@ declare class CairoUint512 {
|
|
|
7566
8091
|
static abiSelector: string;
|
|
7567
8092
|
/**
|
|
7568
8093
|
* Default constructor (Lib usage)
|
|
7569
|
-
* @param bigNumberish BigNumberish value representing u512
|
|
7570
8094
|
*/
|
|
7571
|
-
constructor(bigNumberish: BigNumberish);
|
|
8095
|
+
constructor(bigNumberish: BigNumberish | Uint512 | unknown);
|
|
7572
8096
|
/**
|
|
7573
8097
|
* Direct props initialization (Api response)
|
|
7574
8098
|
*/
|
|
7575
8099
|
constructor(limb0: BigNumberish, limb1: BigNumberish, limb2: BigNumberish, limb3: BigNumberish);
|
|
7576
|
-
/**
|
|
7577
|
-
* Initialization from Uint512 object
|
|
7578
|
-
*/
|
|
7579
|
-
constructor(uint512: Uint512);
|
|
7580
8100
|
/**
|
|
7581
8101
|
* Validate if BigNumberish can be represented as Uint512
|
|
7582
8102
|
*/
|
|
7583
|
-
static validate(bigNumberish: BigNumberish): bigint;
|
|
8103
|
+
static validate(bigNumberish: BigNumberish | unknown): bigint;
|
|
7584
8104
|
/**
|
|
7585
8105
|
* Validate if limbs can be represented as Uint512
|
|
7586
8106
|
*/
|
|
@@ -7593,11 +8113,12 @@ declare class CairoUint512 {
|
|
|
7593
8113
|
/**
|
|
7594
8114
|
* Check if BigNumberish can be represented as Uint512
|
|
7595
8115
|
*/
|
|
7596
|
-
static is(bigNumberish: BigNumberish): boolean;
|
|
8116
|
+
static is(bigNumberish: BigNumberish | unknown): boolean;
|
|
7597
8117
|
/**
|
|
7598
8118
|
* Check if provided abi type is this data type
|
|
7599
8119
|
*/
|
|
7600
8120
|
static isAbiType(abiType: string): boolean;
|
|
8121
|
+
static factoryFromApiResponse(responseIterator: Iterator<string>): CairoUint512;
|
|
7601
8122
|
/**
|
|
7602
8123
|
* Return bigint representation
|
|
7603
8124
|
*/
|
|
@@ -7628,6 +8149,116 @@ declare class CairoUint512 {
|
|
|
7628
8149
|
toApiRequest(): string[];
|
|
7629
8150
|
}
|
|
7630
8151
|
|
|
8152
|
+
declare class CairoInt8 {
|
|
8153
|
+
data: bigint;
|
|
8154
|
+
static abiSelector: string;
|
|
8155
|
+
constructor(data: BigNumberish | boolean | unknown);
|
|
8156
|
+
static __processData(data: BigNumberish | boolean | unknown): bigint;
|
|
8157
|
+
toApiRequest(): string[];
|
|
8158
|
+
toBigInt(): bigint;
|
|
8159
|
+
decodeUtf8(): string;
|
|
8160
|
+
/**
|
|
8161
|
+
* For negative values field element representation as positive hex string.
|
|
8162
|
+
* @returns cairo field arithmetic hex string
|
|
8163
|
+
*/
|
|
8164
|
+
toHexString(): string;
|
|
8165
|
+
static validate(data: BigNumberish | boolean | unknown): void;
|
|
8166
|
+
static is(data: BigNumberish | boolean | unknown): boolean;
|
|
8167
|
+
/**
|
|
8168
|
+
* Check if provided abi type is this data type
|
|
8169
|
+
*/
|
|
8170
|
+
static isAbiType(abiType: string): boolean;
|
|
8171
|
+
static factoryFromApiResponse(responseIterator: Iterator<string>): CairoInt8;
|
|
8172
|
+
}
|
|
8173
|
+
|
|
8174
|
+
declare class CairoInt16 {
|
|
8175
|
+
data: bigint;
|
|
8176
|
+
static abiSelector: string;
|
|
8177
|
+
constructor(data: BigNumberish | boolean | unknown);
|
|
8178
|
+
static __processData(data: BigNumberish | boolean | unknown): bigint;
|
|
8179
|
+
toApiRequest(): string[];
|
|
8180
|
+
toBigInt(): bigint;
|
|
8181
|
+
decodeUtf8(): string;
|
|
8182
|
+
/**
|
|
8183
|
+
* For negative values field element representation as positive hex string.
|
|
8184
|
+
* @returns cairo field arithmetic hex string
|
|
8185
|
+
*/
|
|
8186
|
+
toHexString(): string;
|
|
8187
|
+
static validate(data: BigNumberish | boolean | unknown): void;
|
|
8188
|
+
static is(data: BigNumberish | boolean | unknown): boolean;
|
|
8189
|
+
/**
|
|
8190
|
+
* Check if provided abi type is this data type
|
|
8191
|
+
*/
|
|
8192
|
+
static isAbiType(abiType: string): boolean;
|
|
8193
|
+
static factoryFromApiResponse(responseIterator: Iterator<string>): CairoInt16;
|
|
8194
|
+
}
|
|
8195
|
+
|
|
8196
|
+
declare class CairoInt32 {
|
|
8197
|
+
data: bigint;
|
|
8198
|
+
static abiSelector: string;
|
|
8199
|
+
constructor(data: BigNumberish | boolean | unknown);
|
|
8200
|
+
static __processData(data: BigNumberish | boolean | unknown): bigint;
|
|
8201
|
+
toApiRequest(): string[];
|
|
8202
|
+
toBigInt(): bigint;
|
|
8203
|
+
decodeUtf8(): string;
|
|
8204
|
+
/**
|
|
8205
|
+
* For negative values field element representation as positive hex string.
|
|
8206
|
+
* @returns cairo field arithmetic hex string
|
|
8207
|
+
*/
|
|
8208
|
+
toHexString(): string;
|
|
8209
|
+
static validate(data: BigNumberish | boolean | unknown): void;
|
|
8210
|
+
static is(data: BigNumberish | boolean | unknown): boolean;
|
|
8211
|
+
/**
|
|
8212
|
+
* Check if provided abi type is this data type
|
|
8213
|
+
*/
|
|
8214
|
+
static isAbiType(abiType: string): boolean;
|
|
8215
|
+
static factoryFromApiResponse(responseIterator: Iterator<string>): CairoInt32;
|
|
8216
|
+
}
|
|
8217
|
+
|
|
8218
|
+
declare class CairoInt64 {
|
|
8219
|
+
data: bigint;
|
|
8220
|
+
static abiSelector: string;
|
|
8221
|
+
constructor(data: BigNumberish | boolean | unknown);
|
|
8222
|
+
static __processData(data: BigNumberish | boolean | unknown): bigint;
|
|
8223
|
+
toApiRequest(): string[];
|
|
8224
|
+
toBigInt(): bigint;
|
|
8225
|
+
decodeUtf8(): string;
|
|
8226
|
+
/**
|
|
8227
|
+
* For negative values field element representation as positive hex string.
|
|
8228
|
+
* @returns cairo field arithmetic hex string
|
|
8229
|
+
*/
|
|
8230
|
+
toHexString(): string;
|
|
8231
|
+
static validate(data: BigNumberish | boolean | unknown): void;
|
|
8232
|
+
static is(data: BigNumberish | boolean | unknown): boolean;
|
|
8233
|
+
/**
|
|
8234
|
+
* Check if provided abi type is this data type
|
|
8235
|
+
*/
|
|
8236
|
+
static isAbiType(abiType: string): boolean;
|
|
8237
|
+
static factoryFromApiResponse(responseIterator: Iterator<string>): CairoInt64;
|
|
8238
|
+
}
|
|
8239
|
+
|
|
8240
|
+
declare class CairoInt128 {
|
|
8241
|
+
data: bigint;
|
|
8242
|
+
static abiSelector: string;
|
|
8243
|
+
constructor(data: BigNumberish | boolean | unknown);
|
|
8244
|
+
static __processData(data: BigNumberish | boolean | unknown): bigint;
|
|
8245
|
+
toApiRequest(): string[];
|
|
8246
|
+
toBigInt(): bigint;
|
|
8247
|
+
decodeUtf8(): string;
|
|
8248
|
+
/**
|
|
8249
|
+
* For negative values field element representation as positive hex string.
|
|
8250
|
+
* @returns cairo field arithmetic hex string
|
|
8251
|
+
*/
|
|
8252
|
+
toHexString(): string;
|
|
8253
|
+
static validate(data: BigNumberish | boolean | unknown): void;
|
|
8254
|
+
static is(data: BigNumberish | boolean | unknown): boolean;
|
|
8255
|
+
/**
|
|
8256
|
+
* Check if provided abi type is this data type
|
|
8257
|
+
*/
|
|
8258
|
+
static isAbiType(abiType: string): boolean;
|
|
8259
|
+
static factoryFromApiResponse(responseIterator: Iterator<string>): CairoInt128;
|
|
8260
|
+
}
|
|
8261
|
+
|
|
7631
8262
|
declare class CairoFixedArray {
|
|
7632
8263
|
/**
|
|
7633
8264
|
* JS array representing a Cairo fixed array.
|
|
@@ -7714,6 +8345,7 @@ declare class CairoFixedArray {
|
|
|
7714
8345
|
compile(): Object;
|
|
7715
8346
|
/**
|
|
7716
8347
|
* Checks if the given Cairo type is a fixed-array type.
|
|
8348
|
+
* structure: [string; number]
|
|
7717
8349
|
*
|
|
7718
8350
|
* @param {string} type - The type to check.
|
|
7719
8351
|
* @returns - `true` if the type is a fixed array type, `false` otherwise.
|
|
@@ -7724,6 +8356,119 @@ declare class CairoFixedArray {
|
|
|
7724
8356
|
static isTypeFixedArray(type: string): boolean;
|
|
7725
8357
|
}
|
|
7726
8358
|
|
|
8359
|
+
declare class CairoBytes31 {
|
|
8360
|
+
static MAX_BYTE_SIZE: 31;
|
|
8361
|
+
data: Uint8Array;
|
|
8362
|
+
static abiSelector: "core::bytes_31::bytes31";
|
|
8363
|
+
constructor(data: string | Uint8Array | Buffer | unknown);
|
|
8364
|
+
static __processData(data: Uint8Array | string | Buffer | unknown): Uint8Array;
|
|
8365
|
+
toApiRequest(): string[];
|
|
8366
|
+
toBigInt(): bigint;
|
|
8367
|
+
decodeUtf8(): string;
|
|
8368
|
+
toHexString(): string;
|
|
8369
|
+
static validate(data: Uint8Array | string | Buffer | unknown): void;
|
|
8370
|
+
static is(data: Uint8Array | string | Buffer): boolean;
|
|
8371
|
+
/**
|
|
8372
|
+
* Check if provided abi type is this data type
|
|
8373
|
+
*/
|
|
8374
|
+
static isAbiType(abiType: string): boolean;
|
|
8375
|
+
static factoryFromApiResponse(responseIterator: Iterator<string>): CairoBytes31;
|
|
8376
|
+
}
|
|
8377
|
+
|
|
8378
|
+
/**
|
|
8379
|
+
* felt252 is the basic field element used in Cairo.
|
|
8380
|
+
* It corresponds to an integer in the range 0 ≤ x < P where P is a very large prime number currently equal to 2^251 + 17⋅2^192 + 1.
|
|
8381
|
+
* Any operation that uses felt252 will be computed modulo P.
|
|
8382
|
+
* 63 hex symbols (31 bytes + 4 bits), 252 bits
|
|
8383
|
+
*/
|
|
8384
|
+
declare class CairoFelt252 {
|
|
8385
|
+
/**
|
|
8386
|
+
* byte representation of the felt252
|
|
8387
|
+
*/
|
|
8388
|
+
data: Uint8Array;
|
|
8389
|
+
static abiSelector: "core::felt252";
|
|
8390
|
+
constructor(data: BigNumberish | boolean | unknown);
|
|
8391
|
+
static __processData(data: BigNumberish | boolean): Uint8Array;
|
|
8392
|
+
toBigInt(): bigint;
|
|
8393
|
+
decodeUtf8(): string;
|
|
8394
|
+
toHexString(): string;
|
|
8395
|
+
toApiRequest(): string[];
|
|
8396
|
+
static validate(data: BigNumberish | boolean | unknown): void;
|
|
8397
|
+
static is(data: BigNumberish | boolean | unknown): boolean;
|
|
8398
|
+
static isAbiType(abiType: string): boolean;
|
|
8399
|
+
static factoryFromApiResponse(responseIterator: Iterator<string>): CairoFelt252;
|
|
8400
|
+
}
|
|
8401
|
+
|
|
8402
|
+
declare class CairoUint32 {
|
|
8403
|
+
data: bigint;
|
|
8404
|
+
static abiSelector: string;
|
|
8405
|
+
constructor(data: BigNumberish);
|
|
8406
|
+
static __processData(data: BigNumberish): bigint;
|
|
8407
|
+
toApiRequest(): string[];
|
|
8408
|
+
toBigInt(): bigint;
|
|
8409
|
+
decodeUtf8(): string;
|
|
8410
|
+
toHexString(): string;
|
|
8411
|
+
static validate(data: BigNumberish): void;
|
|
8412
|
+
static is(data: BigNumberish): boolean;
|
|
8413
|
+
/**
|
|
8414
|
+
* Check if provided abi type is this data type
|
|
8415
|
+
*/
|
|
8416
|
+
static isAbiType(abiType: string): boolean;
|
|
8417
|
+
static factoryFromApiResponse(responseIterator: Iterator<string>): CairoUint32;
|
|
8418
|
+
}
|
|
8419
|
+
|
|
8420
|
+
declare class CairoByteArray {
|
|
8421
|
+
/**
|
|
8422
|
+
* entire dataset
|
|
8423
|
+
*/
|
|
8424
|
+
data: CairoBytes31[];
|
|
8425
|
+
/**
|
|
8426
|
+
* cairo specific implementation helper
|
|
8427
|
+
*/
|
|
8428
|
+
pending_word: CairoFelt252;
|
|
8429
|
+
/**
|
|
8430
|
+
* cairo specific implementation helper
|
|
8431
|
+
*/
|
|
8432
|
+
pending_word_len: CairoUint32;
|
|
8433
|
+
static abiSelector: "core::byte_array::ByteArray";
|
|
8434
|
+
/**
|
|
8435
|
+
* byteArray from typed components
|
|
8436
|
+
*/
|
|
8437
|
+
constructor(data: CairoBytes31[], pendingWord: CairoFelt252, pendingWordLen: CairoUint32);
|
|
8438
|
+
constructor(data: BigNumberish | Buffer | Uint8Array | unknown);
|
|
8439
|
+
static __processData(inData: BigNumberish | Buffer | Uint8Array | unknown): {
|
|
8440
|
+
data: CairoBytes31[];
|
|
8441
|
+
pending_word: CairoFelt252;
|
|
8442
|
+
pending_word_len: CairoUint32;
|
|
8443
|
+
};
|
|
8444
|
+
toApiRequest(): string[];
|
|
8445
|
+
decodeUtf8(): string;
|
|
8446
|
+
toBigInt(): bigint;
|
|
8447
|
+
toHexString(): string;
|
|
8448
|
+
toBuffer(): any;
|
|
8449
|
+
static validate(data: Uint8Array | Buffer | BigNumberish | unknown): void;
|
|
8450
|
+
/**
|
|
8451
|
+
* Check if the provided data is a valid CairoByteArray
|
|
8452
|
+
*
|
|
8453
|
+
* @param data - The data to check
|
|
8454
|
+
* @returns True if the data is a valid CairoByteArray, false otherwise
|
|
8455
|
+
*/
|
|
8456
|
+
static is(data: any): boolean;
|
|
8457
|
+
/**
|
|
8458
|
+
* Check if provided abi type is this data type
|
|
8459
|
+
*/
|
|
8460
|
+
static isAbiType(abiType: string): boolean;
|
|
8461
|
+
/**
|
|
8462
|
+
* Private helper to check if the CairoByteArray is properly initialized
|
|
8463
|
+
*/
|
|
8464
|
+
private assertInitialized;
|
|
8465
|
+
/**
|
|
8466
|
+
* Private helper to reconstruct the full byte sequence from chunks and pending word
|
|
8467
|
+
*/
|
|
8468
|
+
private reconstructBytes;
|
|
8469
|
+
static factoryFromApiResponse(responseIterator: Iterator<string>): CairoByteArray;
|
|
8470
|
+
}
|
|
8471
|
+
|
|
7727
8472
|
/**
|
|
7728
8473
|
* Format a hex number to '0x' and 64 characters, adding leading zeros if necessary.
|
|
7729
8474
|
*
|
|
@@ -7789,26 +8534,6 @@ declare function getChecksumAddress(address: BigNumberish): string;
|
|
|
7789
8534
|
*/
|
|
7790
8535
|
declare function validateChecksumAddress(address: string): boolean;
|
|
7791
8536
|
|
|
7792
|
-
declare abstract class AbiParserInterface {
|
|
7793
|
-
/**
|
|
7794
|
-
* Helper to calculate inputs length from abi
|
|
7795
|
-
* @param abiMethod FunctionAbi
|
|
7796
|
-
* @return number
|
|
7797
|
-
*/
|
|
7798
|
-
abstract methodInputsLength(abiMethod: FunctionAbi): number;
|
|
7799
|
-
/**
|
|
7800
|
-
*
|
|
7801
|
-
* @param name string
|
|
7802
|
-
* @return FunctionAbi | undefined
|
|
7803
|
-
*/
|
|
7804
|
-
abstract getMethod(name: string): FunctionAbi | undefined;
|
|
7805
|
-
/**
|
|
7806
|
-
* Return Abi in legacy format
|
|
7807
|
-
* @return Abi
|
|
7808
|
-
*/
|
|
7809
|
-
abstract getLegacyFormat(): Abi;
|
|
7810
|
-
}
|
|
7811
|
-
|
|
7812
8537
|
/**
|
|
7813
8538
|
* Checks if the given name ends with "_len".
|
|
7814
8539
|
*
|
|
@@ -7881,13 +8606,20 @@ declare const isTypeResult: (type: string) => boolean;
|
|
|
7881
8606
|
* @returns - Returns true if the value is a valid Uint type, otherwise false.
|
|
7882
8607
|
*/
|
|
7883
8608
|
declare const isTypeUint: (type: string) => boolean;
|
|
8609
|
+
/**
|
|
8610
|
+
* Checks if the given value is a valid Int type.
|
|
8611
|
+
*
|
|
8612
|
+
* @param {string} type - The value to check.
|
|
8613
|
+
* @returns - Returns true if the value is a valid Int type, otherwise false.
|
|
8614
|
+
*/
|
|
8615
|
+
declare const isTypeInt: (type: string) => boolean;
|
|
7884
8616
|
/**
|
|
7885
8617
|
* Checks if the given type is `uint256`.
|
|
7886
8618
|
*
|
|
7887
8619
|
* @param {string} type - The type to be checked.
|
|
7888
8620
|
* @returns - Returns true if the type is `uint256`, otherwise false.
|
|
7889
8621
|
*/
|
|
7890
|
-
declare const isTypeUint256: (type: string) =>
|
|
8622
|
+
declare const isTypeUint256: (type: string) => type is "core::integer::u256";
|
|
7891
8623
|
/**
|
|
7892
8624
|
* Checks if the given type is a literal type.
|
|
7893
8625
|
*
|
|
@@ -7915,20 +8647,6 @@ declare const isTypeContractAddress: (type: string) => type is "core::starknet::
|
|
|
7915
8647
|
* @returns - Returns true if the given type is 'core::starknet::eth_address::EthAddress', otherwise false.
|
|
7916
8648
|
*/
|
|
7917
8649
|
declare const isTypeEthAddress: (type: string) => type is "core::starknet::eth_address::EthAddress";
|
|
7918
|
-
/**
|
|
7919
|
-
* Checks if the given type is 'core::bytes_31::bytes31'.
|
|
7920
|
-
*
|
|
7921
|
-
* @param {string} type - The type to check.
|
|
7922
|
-
* @returns - True if the type is 'core::bytes_31::bytes31', false otherwise.
|
|
7923
|
-
*/
|
|
7924
|
-
declare const isTypeBytes31: (type: string) => type is "core::bytes_31::bytes31";
|
|
7925
|
-
/**
|
|
7926
|
-
* Checks if the given type is equal to the 'core::byte_array::ByteArray'.
|
|
7927
|
-
*
|
|
7928
|
-
* @param {string} type - The type to check.
|
|
7929
|
-
* @returns - True if the given type is equal to 'core::byte_array::ByteArray', false otherwise.
|
|
7930
|
-
*/
|
|
7931
|
-
declare const isTypeByteArray: (type: string) => type is "core::byte_array::ByteArray";
|
|
7932
8650
|
/**
|
|
7933
8651
|
* Checks if the given type is equal to the u96 type
|
|
7934
8652
|
*
|
|
@@ -8020,12 +8738,11 @@ declare const cairo_isCairo1Type: typeof isCairo1Type;
|
|
|
8020
8738
|
declare const cairo_isLen: typeof isLen;
|
|
8021
8739
|
declare const cairo_isTypeArray: typeof isTypeArray;
|
|
8022
8740
|
declare const cairo_isTypeBool: typeof isTypeBool;
|
|
8023
|
-
declare const cairo_isTypeByteArray: typeof isTypeByteArray;
|
|
8024
|
-
declare const cairo_isTypeBytes31: typeof isTypeBytes31;
|
|
8025
8741
|
declare const cairo_isTypeContractAddress: typeof isTypeContractAddress;
|
|
8026
8742
|
declare const cairo_isTypeEnum: typeof isTypeEnum;
|
|
8027
8743
|
declare const cairo_isTypeEthAddress: typeof isTypeEthAddress;
|
|
8028
8744
|
declare const cairo_isTypeFelt: typeof isTypeFelt;
|
|
8745
|
+
declare const cairo_isTypeInt: typeof isTypeInt;
|
|
8029
8746
|
declare const cairo_isTypeLiteral: typeof isTypeLiteral;
|
|
8030
8747
|
declare const cairo_isTypeNamedTuple: typeof isTypeNamedTuple;
|
|
8031
8748
|
declare const cairo_isTypeNonZero: typeof isTypeNonZero;
|
|
@@ -8041,7 +8758,7 @@ declare const cairo_tuple: typeof tuple;
|
|
|
8041
8758
|
declare const cairo_uint256: typeof uint256;
|
|
8042
8759
|
declare const cairo_uint512: typeof uint512;
|
|
8043
8760
|
declare namespace cairo {
|
|
8044
|
-
export { cairo_felt as felt, cairo_getAbiContractVersion as getAbiContractVersion, cairo_getArrayType as getArrayType, cairo_isCairo1Abi as isCairo1Abi, cairo_isCairo1Type as isCairo1Type, cairo_isLen as isLen, cairo_isTypeArray as isTypeArray, cairo_isTypeBool as isTypeBool,
|
|
8761
|
+
export { cairo_felt as felt, cairo_getAbiContractVersion as getAbiContractVersion, cairo_getArrayType as getArrayType, cairo_isCairo1Abi as isCairo1Abi, cairo_isCairo1Type as isCairo1Type, cairo_isLen as isLen, cairo_isTypeArray as isTypeArray, cairo_isTypeBool as isTypeBool, cairo_isTypeContractAddress as isTypeContractAddress, cairo_isTypeEnum as isTypeEnum, cairo_isTypeEthAddress as isTypeEthAddress, cairo_isTypeFelt as isTypeFelt, cairo_isTypeInt as isTypeInt, cairo_isTypeLiteral as isTypeLiteral, cairo_isTypeNamedTuple as isTypeNamedTuple, cairo_isTypeNonZero as isTypeNonZero, cairo_isTypeOption as isTypeOption, cairo_isTypeResult as isTypeResult, cairo_isTypeSecp256k1Point as isTypeSecp256k1Point, cairo_isTypeStruct as isTypeStruct, cairo_isTypeTuple as isTypeTuple, cairo_isTypeU96 as isTypeU96, cairo_isTypeUint as isTypeUint, cairo_isTypeUint256 as isTypeUint256, cairo_tuple as tuple, cairo_uint256 as uint256, cairo_uint512 as uint512 };
|
|
8045
8762
|
}
|
|
8046
8763
|
|
|
8047
8764
|
/**
|
|
@@ -8133,14 +8850,20 @@ declare namespace byteArray {
|
|
|
8133
8850
|
* );
|
|
8134
8851
|
* // parsedField === ['1952805748']
|
|
8135
8852
|
*/
|
|
8136
|
-
declare function parseCalldataField(argsIterator
|
|
8853
|
+
declare function parseCalldataField({ argsIterator, input, structs, enums, parser, }: {
|
|
8854
|
+
argsIterator: Iterator<any>;
|
|
8855
|
+
input: AbiEntry;
|
|
8856
|
+
structs: AbiStructs;
|
|
8857
|
+
enums: AbiEnums;
|
|
8858
|
+
parser: AbiParserInterface;
|
|
8859
|
+
}): string | string[];
|
|
8137
8860
|
|
|
8138
8861
|
declare class CallData {
|
|
8139
8862
|
abi: Abi;
|
|
8140
8863
|
parser: AbiParserInterface;
|
|
8141
8864
|
protected readonly structs: AbiStructs;
|
|
8142
8865
|
protected readonly enums: AbiEnums;
|
|
8143
|
-
constructor(abi: Abi);
|
|
8866
|
+
constructor(abi: Abi, parsingStrategy?: ParsingStrategy);
|
|
8144
8867
|
/**
|
|
8145
8868
|
* Validate arguments passed to the method as corresponding to the ones in the abi
|
|
8146
8869
|
* @param type ValidateType - type of the method
|
|
@@ -8257,6 +8980,15 @@ declare function extractContractHashes(payload: DeclareContractPayload): Complet
|
|
|
8257
8980
|
declare function contractClassResponseToLegacyCompiledContract(ccr: ContractClassResponse): LegacyCompiledContract;
|
|
8258
8981
|
|
|
8259
8982
|
/**
|
|
8983
|
+
* !! Main design decision:
|
|
8984
|
+
* Class can't extend GetTransactionReceiptResponse because it is union type
|
|
8985
|
+
* and it is not possible to extend union type in current typescript version
|
|
8986
|
+
* So we have to use factory function to create 'data' return type and inject constructor
|
|
8987
|
+
*
|
|
8988
|
+
* ERROR case left but in library flow it is not possible as fetch would throw on error before it could be read by Helper
|
|
8989
|
+
*/
|
|
8990
|
+
/**
|
|
8991
|
+
* @deprecated Use `createTransactionReceipt` instead
|
|
8260
8992
|
* Utility that analyses transaction receipt response and provides helpers to process it
|
|
8261
8993
|
* @example
|
|
8262
8994
|
* ```typescript
|
|
@@ -8272,17 +9004,23 @@ declare function contractClassResponseToLegacyCompiledContract(ccr: ContractClas
|
|
|
8272
9004
|
* }
|
|
8273
9005
|
* ```
|
|
8274
9006
|
*/
|
|
8275
|
-
declare class ReceiptTx
|
|
9007
|
+
declare class ReceiptTx {
|
|
8276
9008
|
readonly statusReceipt: TransactionReceiptStatus;
|
|
8277
9009
|
readonly value: TransactionReceiptValue;
|
|
8278
9010
|
constructor(receipt: GetTxReceiptResponseWithoutHelper);
|
|
8279
|
-
match(callbacks: TransactionReceiptCallbacks)
|
|
8280
|
-
isSuccess()
|
|
8281
|
-
isReverted()
|
|
8282
|
-
isError()
|
|
9011
|
+
match: (callbacks: TransactionReceiptCallbacks) => void;
|
|
9012
|
+
isSuccess: () => this is SuccessfulTransactionReceiptResponseHelper;
|
|
9013
|
+
isReverted: () => this is RevertedTransactionReceiptResponseHelper;
|
|
9014
|
+
isError: () => this is ErrorReceiptResponseHelper;
|
|
8283
9015
|
static isSuccess(transactionReceipt: GetTxReceiptResponseWithoutHelper): transactionReceipt is SuccessfulTransactionReceiptResponse;
|
|
8284
9016
|
static isReverted(transactionReceipt: GetTxReceiptResponseWithoutHelper): transactionReceipt is RevertedTransactionReceiptResponse;
|
|
8285
9017
|
}
|
|
9018
|
+
/**
|
|
9019
|
+
* Creates a transaction receipt response object with helpers
|
|
9020
|
+
* @param receipt - The transaction receipt response from the provider
|
|
9021
|
+
* @returns A transaction receipt response object with helpers
|
|
9022
|
+
*/
|
|
9023
|
+
declare function createTransactionReceipt(receipt: GetTxReceiptResponseWithoutHelper): GetTransactionReceiptResponse;
|
|
8286
9024
|
|
|
8287
9025
|
/**
|
|
8288
9026
|
* Convert strk to fri or fri to strk
|
|
@@ -8480,4 +9218,4 @@ declare class Logger {
|
|
|
8480
9218
|
*/
|
|
8481
9219
|
declare const logger: Logger;
|
|
8482
9220
|
|
|
8483
|
-
export { type Abi, type AbiEntry, type AbiEnum, type AbiEnums, type AbiEvent, type AbiEvents, type AbiInterfaces, type AbiStruct, type AbiStructs, Account, AccountInterface, type AccountInvocationItem, type AccountInvocations, type AccountInvocationsFactoryDetails, type AccountOptions, type AllowArray, type ApiEstimateFeeResponse, type Args, type ArgsOrCalldata, type ArgsOrCalldataWithOptions, type ArraySignatureType, type AsyncContractFunction, type BLOCK_HASH, type BLOCK_NUMBER, BatchClient, type BatchClientOptions, type BigNumberish, type Block$1 as Block, type BlockIdentifier, type BlockNumber, BlockStatus, BlockTag, type BlockWithTxHashes, type Builtins, type ByteArray, type ByteCode, type CairoAssembly, type CairoContract, CairoCustomEnum, type CairoEnum, type CairoEnumRaw, type CairoEvent, type CairoEventDefinition, type CairoEventVariant, CairoFixedArray, CairoOption, CairoOptionVariant, CairoResult, CairoResultVariant, CairoUint256, CairoUint512, type CairoVersion, type Call, type CallContractResponse, CallData, type CallDetails, type CallOptions, type CallResult, type Calldata, type CommonContractOptions, type CompiledContract, type CompiledSierra, type CompiledSierraCasm, type CompilerVersion, type CompleteDeclareContractPayload, type CompressedProgram, Contract, type ContractClass, type ContractClassIdentifier, type ContractClassPayload, type ContractClassResponse, type ContractEntryPointFields, type ContractFunction, ContractInterface, type ContractOptions, type ContractVersion, type DeclareAndDeployContractPayload, type DeclareContractPayload, type DeclareContractResponse, type DeclareContractTransaction, type DeclareDeployUDCResponse, type DeclareSignerDetails, type DeclareTransactionReceiptResponse, type DeclaredTransaction, type DeployAccountContractPayload, type DeployAccountContractTransaction, type DeployAccountSignerDetails, type DeployAccountTransactionReceiptResponse, type DeployAndInvokeTransaction, type DeployContractResponse, type DeployContractUDCResponse, type DeployTransaction, type DeployTransactionReceiptResponse, type DeployedAccountTransaction, Deployer, type DeployerCall, DeployerInterface, type Details, EDAMode, EDataAvailabilityMode, ETH_ADDRESS, ETransactionExecutionStatus, ETransactionStatus, ETransactionVersion, ETransactionVersion2, ETransactionVersion3, type EVENTS_CHUNK, type EmittedEvent, EntryPointType, type EntryPointsByType, type
|
|
9221
|
+
export { type Abi, type AbiEntry, type AbiEntryType, type AbiEnum, type AbiEnums, type AbiEvent, type AbiEvents, type AbiInterfaces, AbiParser1, AbiParser2, AbiParserInterface, type AbiStruct, type AbiStructs, Account, AccountInterface, type AccountInvocationItem, type AccountInvocations, type AccountInvocationsFactoryDetails, type AccountOptions, type AllowArray, type ApiEstimateFeeResponse, type Args, type ArgsOrCalldata, type ArgsOrCalldataWithOptions, type ArraySignatureType, type AsyncContractFunction, type BLOCK_HASH, type BLOCK_NUMBER, BatchClient, type BatchClientOptions, type BigNumberish, type Block$1 as Block, type BlockIdentifier, type BlockNumber, BlockStatus, BlockTag, type BlockWithTxHashes, type Builtins, type ByteArray, type ByteCode, type CairoAssembly, CairoByteArray, type CairoContract, CairoCustomEnum, type CairoEnum, type CairoEnumRaw, type CairoEvent, type CairoEventDefinition, type CairoEventVariant, CairoFixedArray, CairoInt128, CairoInt16, CairoInt32, CairoInt64, CairoInt8, CairoOption, CairoOptionVariant, CairoResult, CairoResultVariant, CairoUint128, CairoUint16, CairoUint256, CairoUint512, CairoUint64, CairoUint8, CairoUint96, type CairoVersion, type Call, type CallContractResponse, CallData, type CallDetails, type CallOptions, type CallResult, type Calldata, type CommonContractOptions, type CompiledContract, type CompiledSierra, type CompiledSierraCasm, type CompilerVersion, type CompleteDeclareContractPayload, type CompressedProgram, Contract, type ContractClass, type ContractClassIdentifier, type ContractClassPayload, type ContractClassResponse, type ContractEntryPointFields, type ContractFunction, ContractInterface, type ContractOptions, type ContractVersion, type DeclareAndDeployContractPayload, type DeclareContractPayload, type DeclareContractResponse, type DeclareContractTransaction, type DeclareDeployUDCResponse, type DeclareSignerDetails, type DeclareTransactionReceiptResponse, type DeclaredTransaction, type DeployAccountContractPayload, type DeployAccountContractTransaction, type DeployAccountSignerDetails, type DeployAccountTransactionReceiptResponse, type DeployAndInvokeTransaction, type DeployContractResponse, type DeployContractUDCResponse, type DeployTransaction, type DeployTransactionReceiptResponse, type DeployedAccountTransaction, Deployer, type DeployerCall, DeployerInterface, type Details, EDAMode, EDataAvailabilityMode, ETH_ADDRESS, ETransactionExecutionStatus, ETransactionStatus, ETransactionVersion, ETransactionVersion2, ETransactionVersion3, type EVENTS_CHUNK, type EmittedEvent, EntryPointType, type EntryPointsByType, type ErrorReceiptResponseHelper, type EstimateFeeBulk, type EstimateFeeResponseBulkOverhead, type EstimateFeeResponseOverhead, EthSigner, type Event$1 as Event, type EventEntry, type EventFilter, type ExecutableDeployAndInvokeTransaction, type ExecutableDeployTransaction, type ExecutableInvokeTransaction, type ExecutableUserInvoke, type ExecutableUserTransaction, type ExecuteOptions, type ExecutionParameters, type FEE_ESTIMATE, type FELT, type FactoryParams, type FeeEstimate, type FeeMode, type FormatResponse, type FunctionAbi, type GasPrices, type GetBlockResponse, type GetTransactionReceiptResponse, type GetTransactionResponse, type GetTxReceiptResponseWithoutHelper, type HexCalldata, type Hint, Int, type InterfaceAbi, type Invocation, type Invocations, type InvocationsDetails, type InvocationsDetailsWithNonce, type InvocationsSignerDetails, type InvokeFunctionResponse, type InvokeTransaction, type InvokeTransactionReceiptResponse, type InvokedTransaction, type L1HandlerTransactionReceiptResponse, type L1_HANDLER_TXN, type LedgerPathCalculation, LedgerSigner111 as LedgerSigner, LedgerSigner111, LedgerSigner221, LedgerSigner231, type LegacyCompiledContract, type LegacyContractClass, type LegacyEvent, LibraryError, Literal, type LogLevel, LogLevelIndex, type Methods, type MultiDeployContractResponse, type MultiType, NON_ZERO_PREFIX, type Nonce, type OptionalPayload, type OutsideCall, type OutsideExecution, type OutsideExecutionOptions, OutsideExecutionTypesV1, OutsideExecutionTypesV2, OutsideExecutionVersion, type OutsideTransaction, type PENDING_DECLARE_TXN_RECEIPT, type PENDING_DEPLOY_ACCOUNT_TXN_RECEIPT, type PENDING_INVOKE_TXN_RECEIPT, type PENDING_L1_HANDLER_TXN_RECEIPT, type PENDING_STATE_UPDATE, type PRE_CONFIRMED_STATE_UPDATE, type PRICE_UNIT, type ParsedEvent, type ParsedEvents, type ParsedStruct, type ParsingStrategy, type PaymasterDetails, type PaymasterFeeEstimate, PaymasterInterface, type PaymasterOptions, PaymasterRpc, type PaymasterRpcOptions, type PaymasterTimeBounds, type PendingBlock, type PendingReceipt, type PendingStateUpdate, type PreConfirmedStateUpdate, type PreparedDeployAndInvokeTransaction, type PreparedDeployTransaction, type PreparedInvokeTransaction, type PreparedTransaction, type Program, RpcProvider as Provider, ProviderInterface, type ProviderOptions, type ProviderOrAccount, type PythonicHints, type RESOURCE_PRICE, index$4 as RPC, rpc_0_8_1 as RPC08, rpc_0_9_0 as RPC09, RPCResponseParser, type RPC_ERROR, type RPC_ERROR_SET, type RawArgs, type RawArgsArray, type RawArgsObject, type RawCalldata, type Receipt, ReceiptTx, type RequiredKeysOf, type ResourceBounds, type ResourceBoundsBN, type ResourceBoundsOverhead, ResponseParser, type RevertedTransactionReceiptResponse, type RevertedTransactionReceiptResponseHelper, RpcChannel, RpcError, RpcProvider, type RpcProviderOptions, type SIMULATION_FLAG, type STATE_UPDATE, type SierraContractClass, type SierraContractEntryPointFields, type SierraEntryPointsByType, type SierraProgramDebugInfo, type Signature, Signer, SignerInterface, type Simplify, type SimulateTransaction, type SimulateTransactionDetails, type SimulateTransactionOverhead, type SimulateTransactionOverheadResponse, type SimulateTransactionResponse, type SimulationFlags, type StarkProfile, type StateUpdate, type StateUpdateResponse, type Storage, Subscription, type SubscriptionBlockIdentifier, type SuccessfulTransactionReceiptResponse, type SuccessfulTransactionReceiptResponseHelper, type TXN_EXECUTION_STATUS, type TXN_HASH$1 as TXN_HASH, type TXN_STATUS, TimeoutError, type TipAnalysisOptions, type TipEstimate, type TipType, type TokenData, TransactionExecutionStatus, TransactionFinalityStatus, type TransactionReceipt, type TransactionReceiptCallbacks, type TransactionReceiptCallbacksDefault, type TransactionReceiptCallbacksDefined, type TransactionReceiptStatus, type TransactionReceiptValue, type TransactionStatus, type TransactionStatusReceiptSets, type TransactionTrace, TransactionType, type TransactionWithHash, type Tupled, type TypedContractV2, UINT_128_MAX, UINT_128_MIN, UINT_256_HIGH_MAX, UINT_256_HIGH_MIN, UINT_256_LOW_MAX, UINT_256_LOW_MIN, UINT_256_MAX, UINT_256_MIN, UINT_512_MAX, UINT_512_MIN, Uint, type Uint256, type Uint512, type UniversalDeployerContractPayload, type UniversalDetails, type UserInvoke, type UserTransaction, type V3DeclareSignerDetails, type V3DeployAccountSignerDetails, type V3InvocationsSignerDetails, type V3TransactionDetails, ValidateType, WalletAccount, WebSocketChannel, WebSocketNotConnectedError, type WebSocketOptions, type WeierstrassSignatureType, type WithOptions, addAddressPadding, byteArray, cairo, config, constants, contractClassResponseToLegacyCompiledContract, createAbiParser, createTransactionReceipt, defaultDeployer, defaultPaymaster, defaultProvider, ec, encode, eth, index as events, extractContractHashes, fastParsingStrategy, getAbiVersion, getChecksumAddress, type getContractVersionOptions, type getEstimateFeeBulkOptions, getGasPrices, getLedgerPathBuffer111 as getLedgerPathBuffer, getLedgerPathBuffer111, getLedgerPathBuffer221, type getSimulateTransactionOptions, getTipStatsFromBlocks, index$3 as hash, hdParsingStrategy, isAccount, isNoConstructorValid, isPendingBlock, isPendingStateUpdate, isPendingTransaction, isRPC08Plus_ResourceBounds, isRPC08Plus_ResourceBoundsBN, isSierra, isSupportedSpecVersion, isV3Tx, isVersion, json, legacyDeployer, logger, merkle, num, outsideExecution, parseCalldataField, paymaster, provider, selector, shortString, src5, index$1 as stark, starknetId, toAnyPatchVersion, toApiVersion, index$2 as transaction, typedData, uint256$1 as uint256, units, v2 as v2hash, v3 as v3hash, validateAndParseAddress, validateChecksumAddress, verifyMessageInStarknet, type waitForTransactionOptions, connect as wallet };
|