signet.js 0.0.10 → 0.0.12-beta1

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/types/index.d.ts CHANGED
@@ -8,6 +8,9 @@ import { Action as Action$1 } from '@near-js/transactions';
8
8
  import { TxExecutionStatus } from '@near-js/types';
9
9
  import { NetworkId, Action, FinalExecutionOutcome } from '@near-wallet-selector/core';
10
10
  import { KeyPair as KeyPair$1 } from 'near-api-js';
11
+ import * as _solana_web3_js from '@solana/web3.js';
12
+ import { PublicKey, AccountMeta, TransactionInstruction, Signer } from '@solana/web3.js';
13
+ import { AnchorProvider } from '@coral-xyz/anchor';
11
14
 
12
15
  interface SignArgs {
13
16
  /** The payload to sign as an array of 32 bytes */
@@ -46,7 +49,7 @@ declare abstract class BaseChainSignatureContract {
46
49
  /**
47
50
  * Full contract interface that extends BaseChainSignatureContract to provide all Sig Network Smart Contract capabilities.
48
51
  */
49
- declare abstract class ChainSignatureContract$2 extends BaseChainSignatureContract {
52
+ declare abstract class ChainSignatureContract$3 extends BaseChainSignatureContract {
50
53
  /**
51
54
  * Signs a payload using Sig Network MPC.
52
55
  *
@@ -108,6 +111,7 @@ declare const ENVS: {
108
111
  declare const CHAINS: {
109
112
  readonly ETHEREUM: "ETHEREUM";
110
113
  readonly NEAR: "NEAR";
114
+ readonly SOLANA: "SOLANA";
111
115
  };
112
116
  /**
113
117
  * Root public keys for the Sig Network Smart Contracts across different environments.
@@ -124,6 +128,7 @@ declare const ROOT_PUBLIC_KEYS: Record<keyof typeof ENVS, NajPublicKey>;
124
128
  declare const KDF_CHAIN_IDS: {
125
129
  readonly ETHEREUM: "0x1";
126
130
  readonly NEAR: "0x18d";
131
+ readonly SOLANA: "0x800001f5";
127
132
  };
128
133
  /**
129
134
  * Contract addresses for different chains and environments.
@@ -182,9 +187,9 @@ declare namespace cryptography {
182
187
  export { cryptography_compressPubKey as compressPubKey, cryptography_deriveChildPublicKey as deriveChildPublicKey, cryptography_najToUncompressedPubKeySEC1 as najToUncompressedPubKeySEC1, cryptography_toRSV as toRSV };
183
188
  }
184
189
 
185
- declare const index$7_cryptography: typeof cryptography;
186
- declare namespace index$7 {
187
- export { index$7_cryptography as cryptography };
190
+ declare const index$8_cryptography: typeof cryptography;
191
+ declare namespace index$8 {
192
+ export { index$8_cryptography as cryptography };
188
193
  }
189
194
 
190
195
  declare abstract class ChainAdapter<TransactionRequest, UnsignedTransaction> {
@@ -382,15 +387,15 @@ interface EVMFeeProperties {
382
387
  }
383
388
  declare function fetchEVMFeeProperties(client: PublicClient, transaction: TransactionRequest): Promise<EVMFeeProperties>;
384
389
 
385
- type index$6_EVM = EVM;
386
- declare const index$6_EVM: typeof EVM;
387
- type index$6_EVMMessage = EVMMessage;
388
- type index$6_EVMTransactionRequest = EVMTransactionRequest;
389
- type index$6_EVMTypedData = EVMTypedData;
390
- type index$6_EVMUnsignedTransaction = EVMUnsignedTransaction;
391
- declare const index$6_fetchEVMFeeProperties: typeof fetchEVMFeeProperties;
392
- declare namespace index$6 {
393
- export { index$6_EVM as EVM, type index$6_EVMMessage as EVMMessage, type index$6_EVMTransactionRequest as EVMTransactionRequest, type index$6_EVMTypedData as EVMTypedData, type index$6_EVMUnsignedTransaction as EVMUnsignedTransaction, index$6_fetchEVMFeeProperties as fetchEVMFeeProperties };
390
+ type index$7_EVM = EVM;
391
+ declare const index$7_EVM: typeof EVM;
392
+ type index$7_EVMMessage = EVMMessage;
393
+ type index$7_EVMTransactionRequest = EVMTransactionRequest;
394
+ type index$7_EVMTypedData = EVMTypedData;
395
+ type index$7_EVMUnsignedTransaction = EVMUnsignedTransaction;
396
+ declare const index$7_fetchEVMFeeProperties: typeof fetchEVMFeeProperties;
397
+ declare namespace index$7 {
398
+ export { index$7_EVM as EVM, type index$7_EVMMessage as EVMMessage, type index$7_EVMTransactionRequest as EVMTransactionRequest, type index$7_EVMTypedData as EVMTypedData, type index$7_EVMUnsignedTransaction as EVMUnsignedTransaction, index$7_fetchEVMFeeProperties as fetchEVMFeeProperties };
394
399
  }
395
400
 
396
401
  interface BTCTransaction$1 {
@@ -528,18 +533,18 @@ declare class Bitcoin extends ChainAdapter<BTCTransactionRequest, BTCUnsignedTra
528
533
  broadcastTx(txSerialized: string): Promise<string>;
529
534
  }
530
535
 
531
- type index$5_BTCInput = BTCInput;
532
- type index$5_BTCNetworkIds = BTCNetworkIds;
533
- type index$5_BTCOutput = BTCOutput;
534
- type index$5_BTCRpcAdapter = BTCRpcAdapter;
535
- declare const index$5_BTCRpcAdapter: typeof BTCRpcAdapter;
536
- declare const index$5_BTCRpcAdapters: typeof BTCRpcAdapters;
537
- type index$5_BTCTransactionRequest = BTCTransactionRequest;
538
- type index$5_BTCUnsignedTransaction = BTCUnsignedTransaction;
539
- type index$5_Bitcoin = Bitcoin;
540
- declare const index$5_Bitcoin: typeof Bitcoin;
541
- declare namespace index$5 {
542
- export { type index$5_BTCInput as BTCInput, type index$5_BTCNetworkIds as BTCNetworkIds, type index$5_BTCOutput as BTCOutput, index$5_BTCRpcAdapter as BTCRpcAdapter, index$5_BTCRpcAdapters as BTCRpcAdapters, type BTCTransaction$1 as BTCTransaction, type index$5_BTCTransactionRequest as BTCTransactionRequest, type index$5_BTCUnsignedTransaction as BTCUnsignedTransaction, index$5_Bitcoin as Bitcoin };
536
+ type index$6_BTCInput = BTCInput;
537
+ type index$6_BTCNetworkIds = BTCNetworkIds;
538
+ type index$6_BTCOutput = BTCOutput;
539
+ type index$6_BTCRpcAdapter = BTCRpcAdapter;
540
+ declare const index$6_BTCRpcAdapter: typeof BTCRpcAdapter;
541
+ declare const index$6_BTCRpcAdapters: typeof BTCRpcAdapters;
542
+ type index$6_BTCTransactionRequest = BTCTransactionRequest;
543
+ type index$6_BTCUnsignedTransaction = BTCUnsignedTransaction;
544
+ type index$6_Bitcoin = Bitcoin;
545
+ declare const index$6_Bitcoin: typeof Bitcoin;
546
+ declare namespace index$6 {
547
+ export { type index$6_BTCInput as BTCInput, type index$6_BTCNetworkIds as BTCNetworkIds, type index$6_BTCOutput as BTCOutput, index$6_BTCRpcAdapter as BTCRpcAdapter, index$6_BTCRpcAdapters as BTCRpcAdapters, type BTCTransaction$1 as BTCTransaction, type index$6_BTCTransactionRequest as BTCTransactionRequest, type index$6_BTCUnsignedTransaction as BTCUnsignedTransaction, index$6_Bitcoin as Bitcoin };
543
548
  }
544
549
 
545
550
  type CosmosNetworkIds = string;
@@ -601,19 +606,19 @@ declare class Cosmos extends ChainAdapter<CosmosTransactionRequest, CosmosUnsign
601
606
  broadcastTx(txSerialized: string): Promise<string>;
602
607
  }
603
608
 
604
- type index$4_Cosmos = Cosmos;
605
- declare const index$4_Cosmos: typeof Cosmos;
606
- type index$4_CosmosNetworkIds = CosmosNetworkIds;
607
- type index$4_CosmosTransactionRequest = CosmosTransactionRequest;
608
- type index$4_CosmosUnsignedTransaction = CosmosUnsignedTransaction;
609
- declare namespace index$4 {
610
- export { index$4_Cosmos as Cosmos, type index$4_CosmosNetworkIds as CosmosNetworkIds, type index$4_CosmosTransactionRequest as CosmosTransactionRequest, type index$4_CosmosUnsignedTransaction as CosmosUnsignedTransaction };
609
+ type index$5_Cosmos = Cosmos;
610
+ declare const index$5_Cosmos: typeof Cosmos;
611
+ type index$5_CosmosNetworkIds = CosmosNetworkIds;
612
+ type index$5_CosmosTransactionRequest = CosmosTransactionRequest;
613
+ type index$5_CosmosUnsignedTransaction = CosmosUnsignedTransaction;
614
+ declare namespace index$5 {
615
+ export { index$5_Cosmos as Cosmos, type index$5_CosmosNetworkIds as CosmosNetworkIds, type index$5_CosmosTransactionRequest as CosmosTransactionRequest, type index$5_CosmosUnsignedTransaction as CosmosUnsignedTransaction };
611
616
  }
612
617
 
613
- type index$3_ChainAdapter<TransactionRequest, UnsignedTransaction> = ChainAdapter<TransactionRequest, UnsignedTransaction>;
614
- declare const index$3_ChainAdapter: typeof ChainAdapter;
615
- declare namespace index$3 {
616
- export { index$3_ChainAdapter as ChainAdapter, index$5 as btc, index$4 as cosmos, index$6 as evm };
618
+ type index$4_ChainAdapter<TransactionRequest, UnsignedTransaction> = ChainAdapter<TransactionRequest, UnsignedTransaction>;
619
+ declare const index$4_ChainAdapter: typeof ChainAdapter;
620
+ declare namespace index$4 {
621
+ export { index$4_ChainAdapter as ChainAdapter, index$6 as btc, index$5 as cosmos, index$7 as evm };
617
622
  }
618
623
 
619
624
  type ChainSignatureContractIds = string;
@@ -734,7 +739,7 @@ interface ChainSignatureContractArgs {
734
739
  *
735
740
  * @extends AbstractChainSignatureContract
736
741
  */
737
- declare class ChainSignatureContract$1 extends ChainSignatureContract$2 {
742
+ declare class ChainSignatureContract$2 extends ChainSignatureContract$3 {
738
743
  private readonly networkId;
739
744
  private readonly contractId;
740
745
  private readonly accountId;
@@ -766,13 +771,13 @@ declare class ChainSignatureContract$1 extends ChainSignatureContract$2 {
766
771
  private requireAccount;
767
772
  }
768
773
 
769
- declare const utils$1: {
774
+ declare const utils$2: {
770
775
  transaction: typeof transaction;
771
776
  signAndSend: typeof signAndSend;
772
777
  };
773
778
 
774
- declare namespace index$2 {
775
- export { ChainSignatureContract$1 as ChainSignatureContract, utils$1 as utils };
779
+ declare namespace index$3 {
780
+ export { ChainSignatureContract$2 as ChainSignatureContract, utils$2 as utils };
776
781
  }
777
782
 
778
783
  declare const abi: ({
@@ -893,56 +898,40 @@ declare class ChainSignatureError extends Error {
893
898
  receipt: TransactionReceipt;
894
899
  constructor(message: string, requestId: `0x${string}`, receipt: TransactionReceipt);
895
900
  }
896
- declare class SignatureNotFoundError extends ChainSignatureError {
901
+ declare class SignatureNotFoundError$1 extends ChainSignatureError {
897
902
  constructor(requestId: `0x${string}`, receipt: TransactionReceipt);
898
903
  }
899
- declare class SignatureContractError extends ChainSignatureError {
904
+ declare class SignatureContractError$1 extends ChainSignatureError {
900
905
  errorCode: string;
901
906
  constructor(errorCode: string, requestId: `0x${string}`, receipt: TransactionReceipt);
902
907
  }
903
- declare class SigningError extends ChainSignatureError {
908
+ declare class SigningError$1 extends ChainSignatureError {
904
909
  originalError?: Error;
905
910
  constructor(requestId: `0x${string}`, receipt: TransactionReceipt, originalError?: Error);
906
911
  }
907
912
 
908
- type errors_ChainSignatureError = ChainSignatureError;
909
- declare const errors_ChainSignatureError: typeof ChainSignatureError;
910
- type errors_SignatureContractError = SignatureContractError;
911
- declare const errors_SignatureContractError: typeof SignatureContractError;
912
- type errors_SignatureNotFoundError = SignatureNotFoundError;
913
- declare const errors_SignatureNotFoundError: typeof SignatureNotFoundError;
914
- type errors_SigningError = SigningError;
915
- declare const errors_SigningError: typeof SigningError;
916
- declare namespace errors {
917
- export { errors_ChainSignatureError as ChainSignatureError, errors_SignatureContractError as SignatureContractError, errors_SignatureNotFoundError as SignatureNotFoundError, errors_SigningError as SigningError };
913
+ type errors$1_ChainSignatureError = ChainSignatureError;
914
+ declare const errors$1_ChainSignatureError: typeof ChainSignatureError;
915
+ declare namespace errors$1 {
916
+ export { errors$1_ChainSignatureError as ChainSignatureError, SignatureContractError$1 as SignatureContractError, SignatureNotFoundError$1 as SignatureNotFoundError, SigningError$1 as SigningError };
918
917
  }
919
918
 
919
+ interface RetryOptions {
920
+ delay?: number;
921
+ retryCount?: number;
922
+ }
920
923
  interface SignOptions {
921
924
  sign: {
922
925
  algo?: string;
923
926
  dest?: string;
924
927
  params?: string;
925
928
  };
926
- retry: {
927
- delay?: number;
928
- retryCount?: number;
929
- };
929
+ retry: RetryOptions;
930
930
  }
931
931
  interface SignatureErrorData {
932
932
  requestId: string;
933
- responder: string;
934
933
  error: string;
935
934
  }
936
- interface RequestIdArgs {
937
- address: Address;
938
- payload: Hex;
939
- path: string;
940
- keyVersion: number;
941
- chainId: bigint;
942
- algo: string;
943
- dest: string;
944
- params: string;
945
- }
946
935
 
947
936
  /**
948
937
  * Implementation of the ChainSignatureContract for EVM chains.
@@ -952,7 +941,7 @@ interface RequestIdArgs {
952
941
  * once it's available. The sign method handles this process automatically by polling
953
942
  * for the signature using the requestId.
954
943
  */
955
- declare class ChainSignatureContract extends ChainSignatureContract$2 {
944
+ declare class ChainSignatureContract$1 extends ChainSignatureContract$3 {
956
945
  private readonly publicClient;
957
946
  private readonly walletClient;
958
947
  private readonly contractAddress;
@@ -996,36 +985,42 @@ declare class ChainSignatureContract extends ChainSignatureContract$2 {
996
985
  * parameters, it will throw an error.
997
986
  */
998
987
  sign(args: SignArgs, options?: SignOptions): Promise<RSVSignature>;
988
+ pollForRequestId({ requestId, payload, path, fromBlock, options, }: {
989
+ requestId: Hex;
990
+ payload: number[];
991
+ path: string;
992
+ fromBlock: bigint;
993
+ options?: RetryOptions;
994
+ }): Promise<RSVSignature | SignatureErrorData | undefined>;
995
+ getSignRequestParams(args: SignArgs, options?: SignOptions['sign']): Promise<{
996
+ target: Hex;
997
+ data: Hex;
998
+ value: bigint;
999
+ }>;
999
1000
  /**
1000
1001
  * Generates the request ID for a signature request allowing to track the response.
1001
1002
  *
1002
- * @param request - The signature request object containing:
1003
- * @param request.address - The contract/wallet address calling the signing contract
1004
- * @param request.payload - The data payload to be signed as a hex string
1005
- * @param request.path - The derivation path for the key
1006
- * @param request.keyVersion - The version of the key to use
1007
- * @param request.chainId - The chain ID as a bigint
1008
- * @param request.algo - The signing algorithm to use
1009
- * @param request.dest - The destination for the signature
1010
- * @param request.params - Additional parameters for the signing process
1003
+ * @param args - The signature request object containing:
1004
+ * @param args.payload - The data payload to be signed as a hex string
1005
+ * @param args.path - The derivation path for the key
1006
+ * @param args.keyVersion - The version of the key to use
1007
+ * @param options - The signature request object containing:
1008
+ * @param options.algo - The signing algorithm to use
1009
+ * @param options.dest - The destination for the signature
1010
+ * @param options.params - Additional parameters for the signing process
1011
1011
  * @returns A hex string representing the unique request ID
1012
1012
  *
1013
1013
  * @example
1014
1014
  * ```typescript
1015
1015
  * const requestId = ChainSignatureContract.getRequestId({
1016
- * address: walletClient.account.address,
1017
1016
  * payload: payload: `0x${Buffer.from(args.payload).toString('hex')}`,,
1018
1017
  * path: '',
1019
- * keyVersion: 0,
1020
- * chainId: 1n,
1021
- * algo: '',
1022
- * dest: '',
1023
- * params: ''
1018
+ * keyVersion: 0
1024
1019
  * });
1025
1020
  * console.log(requestId); // 0x...
1026
1021
  * ```
1027
1022
  */
1028
- getRequestId(request: RequestIdArgs): Hex;
1023
+ getRequestId(args: SignArgs, options?: SignOptions['sign']): Hex;
1029
1024
  getErrorFromEvents(requestId: Hex, fromBlock: bigint): Promise<SignatureErrorData | undefined>;
1030
1025
  /**
1031
1026
  * Searches for SignatureResponded events that match the given requestId.
@@ -1039,8 +1034,326 @@ declare class ChainSignatureContract extends ChainSignatureContract$2 {
1039
1034
  getSignatureFromEvents(requestId: Hex, fromBlock: bigint): Promise<RSVSignature | undefined>;
1040
1035
  }
1041
1036
 
1042
- declare const utils: {
1037
+ declare const utils$1: {
1043
1038
  ChainSignaturesContractABI: typeof ChainSignaturesContractABI;
1039
+ errors: typeof errors$1;
1040
+ };
1041
+
1042
+ declare namespace index$2 {
1043
+ export { ChainSignatureContract$1 as ChainSignatureContract, utils$1 as utils };
1044
+ }
1045
+
1046
+ declare class SignatureNotFoundError extends Error {
1047
+ readonly requestId?: string;
1048
+ readonly hash?: string;
1049
+ constructor(requestId?: string, metadata?: {
1050
+ hash?: string;
1051
+ });
1052
+ }
1053
+ declare class SignatureContractError extends Error {
1054
+ readonly requestId?: string;
1055
+ readonly hash?: string;
1056
+ readonly originalError?: {
1057
+ hash: string;
1058
+ };
1059
+ constructor(message: string, requestId?: string, metadata?: {
1060
+ hash?: string;
1061
+ });
1062
+ }
1063
+ declare class SigningError extends Error {
1064
+ readonly requestId: string;
1065
+ readonly hash?: string;
1066
+ readonly originalError?: Error;
1067
+ constructor(requestId: string, metadata?: {
1068
+ hash?: string;
1069
+ }, originalError?: Error);
1070
+ }
1071
+ declare class ResponseError extends Error {
1072
+ constructor(message: string);
1073
+ }
1074
+
1075
+ type errors_ResponseError = ResponseError;
1076
+ declare const errors_ResponseError: typeof ResponseError;
1077
+ type errors_SignatureContractError = SignatureContractError;
1078
+ declare const errors_SignatureContractError: typeof SignatureContractError;
1079
+ type errors_SignatureNotFoundError = SignatureNotFoundError;
1080
+ declare const errors_SignatureNotFoundError: typeof SignatureNotFoundError;
1081
+ type errors_SigningError = SigningError;
1082
+ declare const errors_SigningError: typeof SigningError;
1083
+ declare namespace errors {
1084
+ export { errors_ResponseError as ResponseError, errors_SignatureContractError as SignatureContractError, errors_SignatureNotFoundError as SignatureNotFoundError, errors_SigningError as SigningError };
1085
+ }
1086
+
1087
+ declare class ChainSignatureContract extends ChainSignatureContract$3 {
1088
+ private readonly provider;
1089
+ private readonly program;
1090
+ private readonly programId;
1091
+ private readonly rootPublicKey;
1092
+ private readonly requesterAddress;
1093
+ /**
1094
+ * Creates a new instance of the ChainSignatureContract for Solana chains.
1095
+ *
1096
+ * @param args - Configuration options for the contract
1097
+ * @param args.provider - An Anchor Provider for interacting with Solana
1098
+ * @param args.programId - The program ID as a string or PublicKey
1099
+ * @param args.rootPublicKey - Optional root public key. If not provided, it will be derived from the program ID
1100
+ * @param args.requesterAddress - Provider wallet address is always the fee payer but requester can be overridden
1101
+ */
1102
+ constructor(args: {
1103
+ provider: AnchorProvider;
1104
+ programId: string | PublicKey;
1105
+ rootPublicKey?: NajPublicKey;
1106
+ requesterAddress?: string;
1107
+ });
1108
+ /**
1109
+ * Gets the connection from the provider
1110
+ */
1111
+ get connection(): _solana_web3_js.Connection;
1112
+ getCurrentSignatureDeposit(): Promise<BN>;
1113
+ /**
1114
+ * Get the Program State PDA
1115
+ */
1116
+ getProgramStatePDA(): Promise<PublicKey>;
1117
+ getDerivedPublicKey(args: {
1118
+ path: string;
1119
+ predecessor: string;
1120
+ }): Promise<UncompressedPubKeySEC1>;
1121
+ getPublicKey(): Promise<UncompressedPubKeySEC1>;
1122
+ getSignRequestInstruction(args: SignArgs, options?: Pick<SignOptions, 'sign'> & {
1123
+ remainingAccounts?: Array<AccountMeta>;
1124
+ }): Promise<TransactionInstruction>;
1125
+ /**
1126
+ * Sends a transaction to the program to request a signature, then
1127
+ * polls for the signature result. If the signature is not found within the retry
1128
+ * parameters, it will throw an error.
1129
+ */
1130
+ sign(args: SignArgs, options?: Partial<SignOptions> & {
1131
+ remainingAccounts?: Array<AccountMeta>;
1132
+ remainingSigners?: Array<Signer>;
1133
+ }): Promise<RSVSignature>;
1134
+ /**
1135
+ * Listens for signature or error events matching the given requestId.
1136
+ * Sets up listeners for both event types and returns a promise that resolves when
1137
+ * either a valid signature or an error is received.
1138
+ */
1139
+ listenForSignatureEvents({ requestId, payload, path, options, }: {
1140
+ requestId: string;
1141
+ payload: number[];
1142
+ path: string;
1143
+ options?: RetryOptions;
1144
+ }): Promise<RSVSignature | SignatureErrorData | undefined>;
1145
+ /**
1146
+ * Generates the request ID for a signature request allowing to track the response.
1147
+ */
1148
+ getRequestId(args: SignArgs, options?: SignOptions['sign']): string;
1149
+ }
1150
+
1151
+ declare const utils: {
1152
+ ChainSignaturesContractIdl: {
1153
+ address: string;
1154
+ metadata: {
1155
+ name: string;
1156
+ version: string;
1157
+ spec: string;
1158
+ description: string;
1159
+ };
1160
+ instructions: ({
1161
+ name: string;
1162
+ discriminator: number[];
1163
+ accounts: {
1164
+ name: string;
1165
+ signer: boolean;
1166
+ }[];
1167
+ args: ({
1168
+ name: string;
1169
+ type: {
1170
+ vec: {
1171
+ array: (string | number)[];
1172
+ defined?: undefined;
1173
+ };
1174
+ };
1175
+ } | {
1176
+ name: string;
1177
+ type: {
1178
+ vec: {
1179
+ defined: {
1180
+ name: string;
1181
+ };
1182
+ array?: undefined;
1183
+ };
1184
+ };
1185
+ })[];
1186
+ } | {
1187
+ name: string;
1188
+ discriminator: number[];
1189
+ accounts: {
1190
+ name: string;
1191
+ signer: boolean;
1192
+ }[];
1193
+ args: ({
1194
+ name: string;
1195
+ type: {
1196
+ vec: {
1197
+ array: (string | number)[];
1198
+ };
1199
+ };
1200
+ } | {
1201
+ name: string;
1202
+ type: {
1203
+ vec: string;
1204
+ };
1205
+ })[];
1206
+ } | {
1207
+ name: string;
1208
+ discriminator: number[];
1209
+ accounts: ({
1210
+ name: string;
1211
+ writable: boolean;
1212
+ pda: {
1213
+ seeds: {
1214
+ kind: string;
1215
+ value: number[];
1216
+ }[];
1217
+ };
1218
+ signer?: undefined;
1219
+ optional?: undefined;
1220
+ address?: undefined;
1221
+ } | {
1222
+ name: string;
1223
+ writable: boolean;
1224
+ signer: boolean;
1225
+ pda?: undefined;
1226
+ optional?: undefined;
1227
+ address?: undefined;
1228
+ } | {
1229
+ name: string;
1230
+ writable: boolean;
1231
+ signer: boolean;
1232
+ optional: boolean;
1233
+ pda?: undefined;
1234
+ address?: undefined;
1235
+ } | {
1236
+ name: string;
1237
+ address: string;
1238
+ writable?: undefined;
1239
+ pda?: undefined;
1240
+ signer?: undefined;
1241
+ optional?: undefined;
1242
+ })[];
1243
+ args: ({
1244
+ name: string;
1245
+ type: {
1246
+ array: (string | number)[];
1247
+ };
1248
+ } | {
1249
+ name: string;
1250
+ type: string;
1251
+ })[];
1252
+ } | {
1253
+ name: string;
1254
+ discriminator: number[];
1255
+ accounts: ({
1256
+ name: string;
1257
+ writable: boolean;
1258
+ pda: {
1259
+ seeds: {
1260
+ kind: string;
1261
+ value: number[];
1262
+ }[];
1263
+ };
1264
+ signer?: undefined;
1265
+ relations?: undefined;
1266
+ docs?: undefined;
1267
+ address?: undefined;
1268
+ } | {
1269
+ name: string;
1270
+ writable: boolean;
1271
+ signer: boolean;
1272
+ relations: string[];
1273
+ pda?: undefined;
1274
+ docs?: undefined;
1275
+ address?: undefined;
1276
+ } | {
1277
+ name: string;
1278
+ docs: string[];
1279
+ writable: boolean;
1280
+ pda?: undefined;
1281
+ signer?: undefined;
1282
+ relations?: undefined;
1283
+ address?: undefined;
1284
+ } | {
1285
+ name: string;
1286
+ address: string;
1287
+ writable?: undefined;
1288
+ pda?: undefined;
1289
+ signer?: undefined;
1290
+ relations?: undefined;
1291
+ docs?: undefined;
1292
+ })[];
1293
+ args: {
1294
+ name: string;
1295
+ type: string;
1296
+ }[];
1297
+ })[];
1298
+ accounts: {
1299
+ name: string;
1300
+ discriminator: number[];
1301
+ }[];
1302
+ events: {
1303
+ name: string;
1304
+ discriminator: number[];
1305
+ }[];
1306
+ errors: {
1307
+ code: number;
1308
+ name: string;
1309
+ msg: string;
1310
+ }[];
1311
+ types: ({
1312
+ name: string;
1313
+ type: {
1314
+ kind: string;
1315
+ fields: ({
1316
+ name: string;
1317
+ type: {
1318
+ defined: {
1319
+ name: string;
1320
+ };
1321
+ array?: undefined;
1322
+ };
1323
+ } | {
1324
+ name: string;
1325
+ type: {
1326
+ array: (string | number)[];
1327
+ defined?: undefined;
1328
+ };
1329
+ } | {
1330
+ name: string;
1331
+ type: string;
1332
+ })[];
1333
+ };
1334
+ } | {
1335
+ name: string;
1336
+ type: {
1337
+ kind: string;
1338
+ fields: ({
1339
+ name: string;
1340
+ type: string;
1341
+ } | {
1342
+ name: string;
1343
+ type: {
1344
+ array: (string | number)[];
1345
+ option?: undefined;
1346
+ };
1347
+ } | {
1348
+ name: string;
1349
+ type: {
1350
+ option: string;
1351
+ array?: undefined;
1352
+ };
1353
+ })[];
1354
+ };
1355
+ })[];
1356
+ };
1044
1357
  errors: typeof errors;
1045
1358
  };
1046
1359
 
@@ -1053,7 +1366,7 @@ declare namespace index$1 {
1053
1366
 
1054
1367
  type index_SignArgs = SignArgs;
1055
1368
  declare namespace index {
1056
- export { ChainSignatureContract$2 as ChainSignatureContract, type index_SignArgs as SignArgs, index$1 as evm, index$2 as near };
1369
+ export { ChainSignatureContract$3 as ChainSignatureContract, type index_SignArgs as SignArgs, index$2 as evm, index$3 as near, index$1 as solana };
1057
1370
  }
1058
1371
 
1059
- export { type CompressedPubKeySEC1, type HashToSign, type KeyDerivationPath, type MPCSignature, type NajPublicKey, type NearNearMpcSignature, type RSVSignature, type SigNetEvmMpcSignature, type SigNetNearMpcSignature, type UncompressedPubKeySEC1, index$3 as chainAdapters, constants, index as contracts, index$7 as utils };
1372
+ export { type CompressedPubKeySEC1, type HashToSign, type KeyDerivationPath, type MPCSignature, type NajPublicKey, type NearNearMpcSignature, type RSVSignature, type SigNetEvmMpcSignature, type SigNetNearMpcSignature, type UncompressedPubKeySEC1, index$4 as chainAdapters, constants, index as contracts, index$8 as utils };