@safe-global/api-kit 3.0.0-alpha.2 → 3.0.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/dist/cjs/index.cjs +257 -253
- package/dist/esm/index.mjs +254 -250
- package/dist/src/SafeApiKit.d.ts +80 -83
- package/dist/src/SafeApiKit.d.ts.map +1 -1
- package/dist/src/types/safeTransactionServiceTypes.d.ts +40 -22
- package/dist/src/types/safeTransactionServiceTypes.d.ts.map +1 -1
- package/dist/src/utils/config.d.ts.map +1 -1
- package/dist/src/utils/queryParamsMap.d.ts +5 -0
- package/dist/src/utils/queryParamsMap.d.ts.map +1 -0
- package/package.json +9 -11
package/dist/src/SafeApiKit.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { SafeMultisigConfirmationListResponse, SafeMultisigTransactionResponse, SafeOperation, SafeOperationConfirmationListResponse, SafeOperationResponse } from '@safe-global/types-kit';
|
|
1
|
+
import { AddMessageOptions, AddSafeDelegateProps, AddSafeOperationProps, AllTransactionsListResponse, AllTransactionsOptions, DeleteSafeDelegateProps, GetIncomingTransactionsOptions, GetModuleTransactionsOptions, GetMultisigTransactionsOptions, GetPendingSafeOperationListOptions, GetSafeDelegateProps, GetSafeMessageListOptions, GetSafeOperationListOptions, GetSafeOperationListResponse, ListOptions, ModulesResponse, OwnerResponse, PendingTransactionsOptions, ProposeTransactionProps, SafeCreationInfoResponse, SafeDelegateListResponse, SafeInfoResponse, SafeMessage, SafeMessageListResponse, SafeModuleTransactionListResponse, SafeMultisigTransactionEstimate, SafeMultisigTransactionEstimateResponse, SafeMultisigTransactionListResponse, SafeServiceInfoResponse, SafeSingletonResponse, SignatureResponse, SignedSafeDelegateResponse, TokenInfoListOptions, TokenInfoListResponse, TokenInfoResponse, TransferListResponse } from './types/safeTransactionServiceTypes';
|
|
2
|
+
import { DataDecoded, SafeMultisigConfirmationListResponse, SafeMultisigTransactionResponse, SafeOperation, SafeOperationConfirmationListResponse, SafeOperationResponse } from '@safe-global/types-kit';
|
|
3
3
|
export interface SafeApiKitConfig {
|
|
4
4
|
/** chainId - The chainId */
|
|
5
5
|
chainId: bigint;
|
|
@@ -31,7 +31,67 @@ declare class SafeApiKit {
|
|
|
31
31
|
* @throws "Not Found"
|
|
32
32
|
* @throws "Ensure this field has at least 1 hexadecimal chars (not counting 0x)."
|
|
33
33
|
*/
|
|
34
|
-
decodeData(data: string, to?: string): Promise<
|
|
34
|
+
decodeData(data: string, to?: string): Promise<DataDecoded>;
|
|
35
|
+
/**
|
|
36
|
+
* Returns the list of delegates.
|
|
37
|
+
*
|
|
38
|
+
* @param getSafeDelegateProps - Properties to filter the returned list of delegates
|
|
39
|
+
* @returns The list of delegates
|
|
40
|
+
* @throws "Checksum address validation failed"
|
|
41
|
+
*/
|
|
42
|
+
getSafeDelegates({ safeAddress, delegateAddress, delegatorAddress, label, limit, offset }: GetSafeDelegateProps): Promise<SafeDelegateListResponse>;
|
|
43
|
+
/**
|
|
44
|
+
* Adds a new delegate for a given Safe address.
|
|
45
|
+
*
|
|
46
|
+
* @param addSafeDelegateProps - The configuration of the new delegate
|
|
47
|
+
* @returns
|
|
48
|
+
* @throws "Invalid Safe delegate address"
|
|
49
|
+
* @throws "Invalid Safe delegator address"
|
|
50
|
+
* @throws "Invalid label"
|
|
51
|
+
* @throws "Checksum address validation failed"
|
|
52
|
+
* @throws "Address <delegate_address> is not checksumed"
|
|
53
|
+
* @throws "Safe=<safe_address> does not exist or it's still not indexed"
|
|
54
|
+
* @throws "Signing owner is not an owner of the Safe"
|
|
55
|
+
*/
|
|
56
|
+
addSafeDelegate({ safeAddress, delegateAddress, delegatorAddress, label, signer }: AddSafeDelegateProps): Promise<SignedSafeDelegateResponse>;
|
|
57
|
+
/**
|
|
58
|
+
* Removes a delegate for a given Safe address.
|
|
59
|
+
*
|
|
60
|
+
* @param deleteSafeDelegateProps - The configuration for the delegate that will be removed
|
|
61
|
+
* @returns
|
|
62
|
+
* @throws "Invalid Safe delegate address"
|
|
63
|
+
* @throws "Invalid Safe delegator address"
|
|
64
|
+
* @throws "Checksum address validation failed"
|
|
65
|
+
* @throws "Signing owner is not an owner of the Safe"
|
|
66
|
+
* @throws "Not found"
|
|
67
|
+
*/
|
|
68
|
+
removeSafeDelegate({ delegateAddress, delegatorAddress, signer }: DeleteSafeDelegateProps): Promise<void>;
|
|
69
|
+
/**
|
|
70
|
+
* Get a message by its safe message hash
|
|
71
|
+
* @param messageHash The Safe message hash
|
|
72
|
+
* @returns The message
|
|
73
|
+
*/
|
|
74
|
+
getMessage(messageHash: string): Promise<SafeMessage>;
|
|
75
|
+
/**
|
|
76
|
+
* Get the list of messages associated to a Safe account
|
|
77
|
+
* @param safeAddress The safe address
|
|
78
|
+
* @param options The options to filter the list of messages
|
|
79
|
+
* @returns The paginated list of messages
|
|
80
|
+
*/
|
|
81
|
+
getMessages(safeAddress: string, options?: GetSafeMessageListOptions): Promise<SafeMessageListResponse>;
|
|
82
|
+
/**
|
|
83
|
+
* Creates a new message with an initial signature
|
|
84
|
+
* Add more signatures from other owners using addMessageSignature()
|
|
85
|
+
* @param safeAddress The safe address
|
|
86
|
+
* @param options The raw message to add, signature and safeAppId if any
|
|
87
|
+
*/
|
|
88
|
+
addMessage(safeAddress: string, addMessageOptions: AddMessageOptions): Promise<void>;
|
|
89
|
+
/**
|
|
90
|
+
* Add a signature to an existing message
|
|
91
|
+
* @param messageHash The safe message hash
|
|
92
|
+
* @param signature The signature
|
|
93
|
+
*/
|
|
94
|
+
addMessageSignature(messageHash: string, signature: string): Promise<void>;
|
|
35
95
|
/**
|
|
36
96
|
* Returns the list of Safes where the address provided is an owner.
|
|
37
97
|
*
|
|
@@ -88,40 +148,6 @@ declare class SafeApiKit {
|
|
|
88
148
|
* @throws "Checksum address validation failed"
|
|
89
149
|
*/
|
|
90
150
|
getSafeInfo(safeAddress: string): Promise<SafeInfoResponse>;
|
|
91
|
-
/**
|
|
92
|
-
* Returns the list of delegates.
|
|
93
|
-
*
|
|
94
|
-
* @param getSafeDelegateProps - Properties to filter the returned list of delegates
|
|
95
|
-
* @returns The list of delegates
|
|
96
|
-
* @throws "Checksum address validation failed"
|
|
97
|
-
*/
|
|
98
|
-
getSafeDelegates({ safeAddress, delegateAddress, delegatorAddress, label, limit, offset }: GetSafeDelegateProps): Promise<SafeDelegateListResponse>;
|
|
99
|
-
/**
|
|
100
|
-
* Adds a new delegate for a given Safe address.
|
|
101
|
-
*
|
|
102
|
-
* @param addSafeDelegateProps - The configuration of the new delegate
|
|
103
|
-
* @returns
|
|
104
|
-
* @throws "Invalid Safe delegate address"
|
|
105
|
-
* @throws "Invalid Safe delegator address"
|
|
106
|
-
* @throws "Invalid label"
|
|
107
|
-
* @throws "Checksum address validation failed"
|
|
108
|
-
* @throws "Address <delegate_address> is not checksumed"
|
|
109
|
-
* @throws "Safe=<safe_address> does not exist or it's still not indexed"
|
|
110
|
-
* @throws "Signing owner is not an owner of the Safe"
|
|
111
|
-
*/
|
|
112
|
-
addSafeDelegate({ safeAddress, delegateAddress, delegatorAddress, label, signer }: AddSafeDelegateProps): Promise<SignedSafeDelegateResponse>;
|
|
113
|
-
/**
|
|
114
|
-
* Removes a delegate for a given Safe address.
|
|
115
|
-
*
|
|
116
|
-
* @param deleteSafeDelegateProps - The configuration for the delegate that will be removed
|
|
117
|
-
* @returns
|
|
118
|
-
* @throws "Invalid Safe delegate address"
|
|
119
|
-
* @throws "Invalid Safe delegator address"
|
|
120
|
-
* @throws "Checksum address validation failed"
|
|
121
|
-
* @throws "Signing owner is not an owner of the Safe"
|
|
122
|
-
* @throws "Not found"
|
|
123
|
-
*/
|
|
124
|
-
removeSafeDelegate({ delegateAddress, delegatorAddress, signer }: DeleteSafeDelegateProps): Promise<void>;
|
|
125
151
|
/**
|
|
126
152
|
* Returns the creation information of a Safe.
|
|
127
153
|
*
|
|
@@ -160,41 +186,33 @@ declare class SafeApiKit {
|
|
|
160
186
|
* Returns the history of incoming transactions of a Safe account.
|
|
161
187
|
*
|
|
162
188
|
* @param safeAddress - The Safe address
|
|
189
|
+
* @param options - Optional parameters to filter or modify the response
|
|
163
190
|
* @returns The history of incoming transactions
|
|
164
191
|
* @throws "Invalid Safe address"
|
|
165
192
|
* @throws "Checksum address validation failed"
|
|
166
193
|
*/
|
|
167
|
-
getIncomingTransactions(safeAddress: string): Promise<TransferListResponse>;
|
|
194
|
+
getIncomingTransactions(safeAddress: string, options?: GetIncomingTransactionsOptions): Promise<TransferListResponse>;
|
|
168
195
|
/**
|
|
169
196
|
* Returns the history of module transactions of a Safe account.
|
|
170
197
|
*
|
|
171
198
|
* @param safeAddress - The Safe address
|
|
199
|
+
* @param options - Optional parameters to filter or modify the response
|
|
172
200
|
* @returns The history of module transactions
|
|
173
201
|
* @throws "Invalid Safe address"
|
|
174
202
|
* @throws "Invalid data"
|
|
175
203
|
* @throws "Invalid ethereum address"
|
|
176
204
|
*/
|
|
177
|
-
getModuleTransactions(safeAddress: string): Promise<SafeModuleTransactionListResponse>;
|
|
205
|
+
getModuleTransactions(safeAddress: string, options?: GetModuleTransactionsOptions): Promise<SafeModuleTransactionListResponse>;
|
|
178
206
|
/**
|
|
179
207
|
* Returns the history of multi-signature transactions of a Safe account.
|
|
180
208
|
*
|
|
181
209
|
* @param safeAddress - The Safe address
|
|
210
|
+
* @param options - Optional parameters to filter or modify the response
|
|
182
211
|
* @returns The history of multi-signature transactions
|
|
183
212
|
* @throws "Invalid Safe address"
|
|
184
213
|
* @throws "Checksum address validation failed"
|
|
185
214
|
*/
|
|
186
|
-
getMultisigTransactions(safeAddress: string): Promise<SafeMultisigTransactionListResponse>;
|
|
187
|
-
/**
|
|
188
|
-
* Returns the list of multi-signature transactions that are waiting for the confirmation of the Safe owners.
|
|
189
|
-
*
|
|
190
|
-
* @param safeAddress - The Safe address
|
|
191
|
-
* @param currentNonce - Deprecated, use inside object property: Current nonce of the Safe.
|
|
192
|
-
* @returns The list of transactions waiting for the confirmation of the Safe owners
|
|
193
|
-
* @throws "Invalid Safe address"
|
|
194
|
-
* @throws "Invalid data"
|
|
195
|
-
* @throws "Invalid ethereum address"
|
|
196
|
-
*/
|
|
197
|
-
getPendingTransactions(safeAddress: string, currentNonce?: number): Promise<SafeMultisigTransactionListResponse>;
|
|
215
|
+
getMultisigTransactions(safeAddress: string, options?: GetMultisigTransactionsOptions): Promise<SafeMultisigTransactionListResponse>;
|
|
198
216
|
/**
|
|
199
217
|
* Returns the list of multi-signature transactions that are waiting for the confirmation of the Safe owners.
|
|
200
218
|
*
|
|
@@ -205,14 +223,16 @@ declare class SafeApiKit {
|
|
|
205
223
|
* @throws "Invalid data"
|
|
206
224
|
* @throws "Invalid ethereum address"
|
|
207
225
|
*/
|
|
208
|
-
getPendingTransactions(safeAddress: string,
|
|
226
|
+
getPendingTransactions(safeAddress: string, options?: PendingTransactionsOptions): Promise<SafeMultisigTransactionListResponse>;
|
|
209
227
|
/**
|
|
210
228
|
* Returns a list of transactions for a Safe. The list has different structures depending on the transaction type
|
|
211
229
|
*
|
|
212
230
|
* @param safeAddress - The Safe address
|
|
231
|
+
* @param options - Optional parameters to filter or modify the response
|
|
213
232
|
* @returns The list of transactions waiting for the confirmation of the Safe owners
|
|
214
233
|
* @throws "Invalid Safe address"
|
|
215
234
|
* @throws "Checksum address validation failed"
|
|
235
|
+
* @throws "Ordering field is not valid"
|
|
216
236
|
*/
|
|
217
237
|
getAllTransactions(safeAddress: string, options?: AllTransactionsOptions): Promise<AllTransactionsListResponse>;
|
|
218
238
|
/**
|
|
@@ -228,9 +248,10 @@ declare class SafeApiKit {
|
|
|
228
248
|
/**
|
|
229
249
|
* Returns the list of all the ERC20 tokens handled by the Safe.
|
|
230
250
|
*
|
|
251
|
+
* @param options - Optional parameters to filter or modify the response
|
|
231
252
|
* @returns The list of all the ERC20 tokens
|
|
232
253
|
*/
|
|
233
|
-
getTokenList(): Promise<TokenInfoListResponse>;
|
|
254
|
+
getTokenList(options?: TokenInfoListOptions): Promise<TokenInfoListResponse>;
|
|
234
255
|
/**
|
|
235
256
|
* Returns the information of a given ERC20 token.
|
|
236
257
|
*
|
|
@@ -240,48 +261,24 @@ declare class SafeApiKit {
|
|
|
240
261
|
* @throws "Checksum address validation failed"
|
|
241
262
|
*/
|
|
242
263
|
getToken(tokenAddress: string): Promise<TokenInfoResponse>;
|
|
243
|
-
/**
|
|
244
|
-
* Get a message by its safe message hash
|
|
245
|
-
* @param messageHash The Safe message hash
|
|
246
|
-
* @returns The message
|
|
247
|
-
*/
|
|
248
|
-
getMessage(messageHash: string): Promise<SafeMessage>;
|
|
249
|
-
/**
|
|
250
|
-
* Get the list of messages associated to a Safe account
|
|
251
|
-
* @param safeAddress The safe address
|
|
252
|
-
* @param options The options to filter the list of messages
|
|
253
|
-
* @returns The paginated list of messages
|
|
254
|
-
*/
|
|
255
|
-
getMessages(safeAddress: string, { ordering, limit, offset }?: GetSafeMessageListProps): Promise<SafeMessageListResponse>;
|
|
256
|
-
/**
|
|
257
|
-
* Creates a new message with an initial signature
|
|
258
|
-
* Add more signatures from other owners using addMessageSignature()
|
|
259
|
-
* @param safeAddress The safe address
|
|
260
|
-
* @param options The raw message to add, signature and safeAppId if any
|
|
261
|
-
*/
|
|
262
|
-
addMessage(safeAddress: string, addMessageProps: AddMessageProps): Promise<void>;
|
|
263
|
-
/**
|
|
264
|
-
* Add a signature to an existing message
|
|
265
|
-
* @param messageHash The safe message hash
|
|
266
|
-
* @param signature The signature
|
|
267
|
-
*/
|
|
268
|
-
addMessageSignature(messageHash: string, signature: string): Promise<void>;
|
|
269
264
|
/**
|
|
270
265
|
* Get the SafeOperations that were sent from a particular address.
|
|
271
|
-
* @param
|
|
266
|
+
* @param safeAddress - The Safe address
|
|
267
|
+
* @param options - Optional parameters to filter or modify the response
|
|
272
268
|
* @throws "Safe address must not be empty"
|
|
273
269
|
* @throws "Invalid Ethereum address {safeAddress}"
|
|
274
270
|
* @returns The SafeOperations sent from the given Safe's address
|
|
275
271
|
*/
|
|
276
|
-
getSafeOperationsByAddress(
|
|
272
|
+
getSafeOperationsByAddress(safeAddress: string, options?: GetSafeOperationListOptions): Promise<GetSafeOperationListResponse>;
|
|
277
273
|
/**
|
|
278
274
|
* Get the SafeOperations that are pending to send to the bundler
|
|
279
|
-
* @param
|
|
275
|
+
* @param safeAddress - The Safe address
|
|
276
|
+
* @param options - Optional parameters to filter or modify the response
|
|
280
277
|
* @throws "Safe address must not be empty"
|
|
281
278
|
* @throws "Invalid Ethereum address {safeAddress}"
|
|
282
279
|
* @returns The pending SafeOperations
|
|
283
280
|
*/
|
|
284
|
-
getPendingSafeOperations(
|
|
281
|
+
getPendingSafeOperations(safeAddress: string, options?: GetPendingSafeOperationListOptions): Promise<GetSafeOperationListResponse>;
|
|
285
282
|
/**
|
|
286
283
|
* Get a SafeOperation by its hash.
|
|
287
284
|
* @param safeOperationHash The SafeOperation hash
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SafeApiKit.d.ts","sourceRoot":"","sources":["../../src/SafeApiKit.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,
|
|
1
|
+
{"version":3,"file":"SafeApiKit.d.ts","sourceRoot":"","sources":["../../src/SafeApiKit.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,iBAAiB,EACjB,oBAAoB,EACpB,qBAAqB,EACrB,2BAA2B,EAC3B,sBAAsB,EACtB,uBAAuB,EACvB,8BAA8B,EAC9B,4BAA4B,EAC5B,8BAA8B,EAC9B,kCAAkC,EAClC,oBAAoB,EACpB,yBAAyB,EACzB,2BAA2B,EAC3B,4BAA4B,EAC5B,WAAW,EACX,eAAe,EACf,aAAa,EACb,0BAA0B,EAC1B,uBAAuB,EAEvB,wBAAwB,EACxB,wBAAwB,EACxB,gBAAgB,EAChB,WAAW,EACX,uBAAuB,EACvB,iCAAiC,EACjC,+BAA+B,EAC/B,uCAAuC,EACvC,mCAAmC,EACnC,uBAAuB,EACvB,qBAAqB,EACrB,iBAAiB,EACjB,0BAA0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;;;;;;;;OAQG;IACG,gBAAgB,CAAC,aAAa,EAAE,qBAAqB,GAAG,aAAa,GAAG,OAAO,CAAC,IAAI,CAAC;IAsE3F;;;;;;;;OAQG;IACG,6BAA6B,CACjC,iBAAiB,EAAE,MAAM,EACzB,EAAE,KAAK,EAAE,MAAM,EAAE,GAAE,WAAgB,GAClC,OAAO,CAAC,qCAAqC,CAAC;IAuBjD;;;;;;;;;;OAUG;IACG,oBAAoB,CAAC,iBAAiB,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;CAaxF;AAED,eAAe,UAAU,CAAA"}
|
|
@@ -1,11 +1,14 @@
|
|
|
1
|
-
import { Account, Chain, Transport,
|
|
2
|
-
import { SafeMultisigTransactionResponse, SafeTransactionData, UserOperation, SafeOperationResponse, ListResponse, SignatureType } from '@safe-global/types-kit';
|
|
1
|
+
import { Account, Chain, Transport, WalletClient } from 'viem';
|
|
2
|
+
import { EIP712TypedData, SafeMultisigTransactionResponse, SafeTransactionData, UserOperation, SafeOperationResponse, ListResponse, SignatureType, DataDecoded, UserOperationResponse } from '@safe-global/types-kit';
|
|
3
3
|
export type ListOptions = {
|
|
4
4
|
/** Maximum number of results to return per page */
|
|
5
5
|
limit?: number;
|
|
6
6
|
/** Initial index from which to return the results */
|
|
7
7
|
offset?: number;
|
|
8
8
|
};
|
|
9
|
+
export type QueryParamsOptions = {
|
|
10
|
+
[key: string]: string | number | boolean | undefined;
|
|
11
|
+
};
|
|
9
12
|
export type SafeServiceInfoResponse = {
|
|
10
13
|
readonly name: string;
|
|
11
14
|
readonly version: string;
|
|
@@ -52,7 +55,9 @@ export type SafeCreationInfoResponse = {
|
|
|
52
55
|
readonly factoryAddress: string;
|
|
53
56
|
readonly singleton: string;
|
|
54
57
|
readonly setupData: string;
|
|
55
|
-
readonly
|
|
58
|
+
readonly saltNonce: string | null;
|
|
59
|
+
readonly dataDecoded?: DataDecoded;
|
|
60
|
+
readonly userOperation: UserOperationResponse | null;
|
|
56
61
|
};
|
|
57
62
|
export type GetSafeDelegateProps = {
|
|
58
63
|
safeAddress?: string;
|
|
@@ -103,6 +108,12 @@ export type ProposeTransactionProps = {
|
|
|
103
108
|
senderSignature: string;
|
|
104
109
|
origin?: string;
|
|
105
110
|
};
|
|
111
|
+
export type GetMultisigTransactionsOptions = {
|
|
112
|
+
executed?: boolean;
|
|
113
|
+
nonce?: string;
|
|
114
|
+
/** Which field to use when ordering the results. It can be: `nonce`, `created`, `modified` (default: `-created`) */
|
|
115
|
+
ordering?: string;
|
|
116
|
+
} & ListOptions & QueryParamsOptions;
|
|
106
117
|
export type PendingTransactionsOptions = {
|
|
107
118
|
currentNonce?: number;
|
|
108
119
|
hasConfirmations?: boolean;
|
|
@@ -110,6 +121,9 @@ export type PendingTransactionsOptions = {
|
|
|
110
121
|
ordering?: string;
|
|
111
122
|
} & ListOptions;
|
|
112
123
|
export type SafeMultisigTransactionListResponse = ListResponse<SafeMultisigTransactionResponse>;
|
|
124
|
+
export type GetIncomingTransactionsOptions = {
|
|
125
|
+
from?: string;
|
|
126
|
+
} & ListOptions & QueryParamsOptions;
|
|
113
127
|
export type SafeModuleTransaction = {
|
|
114
128
|
readonly created?: string;
|
|
115
129
|
readonly executionDate: string;
|
|
@@ -120,11 +134,14 @@ export type SafeModuleTransaction = {
|
|
|
120
134
|
readonly module: string;
|
|
121
135
|
readonly to: string;
|
|
122
136
|
readonly value: string;
|
|
123
|
-
readonly data: string;
|
|
137
|
+
readonly data: string | null;
|
|
124
138
|
readonly operation: number;
|
|
125
|
-
readonly dataDecoded?:
|
|
139
|
+
readonly dataDecoded?: DataDecoded;
|
|
126
140
|
};
|
|
127
141
|
export type SafeModuleTransactionListResponse = ListResponse<SafeModuleTransaction>;
|
|
142
|
+
export type GetModuleTransactionsOptions = {
|
|
143
|
+
module?: string;
|
|
144
|
+
} & ListOptions & QueryParamsOptions;
|
|
128
145
|
export type TransferResponse = {
|
|
129
146
|
readonly type: string;
|
|
130
147
|
readonly executionDate: string;
|
|
@@ -149,6 +166,13 @@ export type TokenInfoResponse = {
|
|
|
149
166
|
readonly trusted: boolean;
|
|
150
167
|
};
|
|
151
168
|
export type TokenInfoListResponse = ListResponse<TokenInfoResponse>;
|
|
169
|
+
export type TokenInfoListOptions = {
|
|
170
|
+
/** Search term that will match `name` or `symbol` */
|
|
171
|
+
search?: string;
|
|
172
|
+
address?: string;
|
|
173
|
+
/** Which field to use when ordering the results. It can be: `name`, `symbol`, `address` (default: `-name`) */
|
|
174
|
+
ordering?: string;
|
|
175
|
+
} & ListOptions & QueryParamsOptions;
|
|
152
176
|
export type SafeModuleTransactionWithTransfersResponse = SafeModuleTransaction & {
|
|
153
177
|
readonly txType?: 'MODULE_TRANSACTION';
|
|
154
178
|
readonly transfers: TransferResponse[];
|
|
@@ -169,11 +193,7 @@ export type EthereumTxWithTransfersResponse = EthereumTxResponse & {
|
|
|
169
193
|
readonly txType?: 'ETHEREUM_TRANSACTION';
|
|
170
194
|
readonly transfers: TransferResponse[];
|
|
171
195
|
};
|
|
172
|
-
export type AllTransactionsOptions =
|
|
173
|
-
executed?: boolean;
|
|
174
|
-
queued?: boolean;
|
|
175
|
-
trusted?: boolean;
|
|
176
|
-
};
|
|
196
|
+
export type AllTransactionsOptions = ListOptions;
|
|
177
197
|
export type AllTransactionsListResponse = ListResponse<SafeModuleTransactionWithTransfersResponse | SafeMultisigTransactionWithTransfersResponse | EthereumTxWithTransfersResponse>;
|
|
178
198
|
export type ModulesResponse = {
|
|
179
199
|
safes: string[];
|
|
@@ -198,28 +218,26 @@ export type SafeMessage = {
|
|
|
198
218
|
readonly origin?: string;
|
|
199
219
|
};
|
|
200
220
|
export type SafeMessageListResponse = ListResponse<SafeMessage>;
|
|
201
|
-
export type
|
|
221
|
+
export type AddMessageOptions = {
|
|
202
222
|
message: string | EIP712TypedData;
|
|
203
223
|
safeAppId?: number;
|
|
204
224
|
signature: string;
|
|
205
225
|
};
|
|
206
|
-
export type
|
|
226
|
+
export type GetSafeMessageListOptions = {
|
|
207
227
|
/** Which field to use when ordering the results. It can be: `created`, `modified` (default: `-created`) */
|
|
208
228
|
ordering?: string;
|
|
209
229
|
} & ListOptions;
|
|
210
|
-
export type
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
message: Record<string, unknown>;
|
|
214
|
-
};
|
|
215
|
-
export type GetSafeOperationListProps = {
|
|
216
|
-
/** Address of the Safe to get SafeOperations for */
|
|
217
|
-
safeAddress: string;
|
|
230
|
+
export type GetSafeOperationListOptions = {
|
|
231
|
+
hasConfirmations?: boolean;
|
|
232
|
+
executed?: boolean;
|
|
218
233
|
/** Which field to use when ordering the results. It can be: `user_operation__nonce`, `created` (default: `-user_operation__nonce`) */
|
|
219
234
|
ordering?: string;
|
|
220
|
-
|
|
235
|
+
} & ListOptions & QueryParamsOptions;
|
|
236
|
+
export type GetPendingSafeOperationListOptions = {
|
|
221
237
|
hasConfirmations?: boolean;
|
|
222
|
-
|
|
238
|
+
/** Which field to use when ordering the results. It can be: `user_operation__nonce`, `created` (default: `-user_operation__nonce`) */
|
|
239
|
+
ordering?: string;
|
|
240
|
+
} & ListOptions & QueryParamsOptions;
|
|
223
241
|
export type GetSafeOperationListResponse = ListResponse<SafeOperationResponse>;
|
|
224
242
|
export type AddSafeOperationProps = {
|
|
225
243
|
/** Address of the EntryPoint contract */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"safeTransactionServiceTypes.d.ts","sourceRoot":"","sources":["../../../src/types/safeTransactionServiceTypes.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE,
|
|
1
|
+
{"version":3,"file":"safeTransactionServiceTypes.d.ts","sourceRoot":"","sources":["../../../src/types/safeTransactionServiceTypes.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,MAAM,CAAA;AAC9D,OAAO,EACL,eAAe,E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,MAAM,MAAM,yBAAyB,GAAG;IACtC,2GAA2G;IAC3G,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB,GAAG,WAAW,CAAA;AAEf,MAAM,MAAM,2BAA2B,GAAG;IACxC,gBAAgB,CAAC,EAAE,OAAO,CAAA;IAC1B,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB,sIAAsI;IACtI,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB,GAAG,WAAW,GAEb,kBAAkB,CAAA;AAEpB,MAAM,MAAM,kCAAkC,GAAG;IAC/C,gBAAgB,CAAC,EAAE,OAAO,CAAA;IAC1B,sIAAsI;IACtI,QAAQ,CAAC,EAAE,MAAM,CAAA;CAClB,GAAG,WAAW,GAEb,kBAAkB,CAAA;AAEpB,MAAM,MAAM,4BAA4B,GAAG,YAAY,CAAC,qBAAqB,CAAC,CAAA;AAE9E,MAAM,MAAM,qBAAqB,GAAG;IAClC,yCAAyC;IACzC,UAAU,EAAE,MAAM,CAAA;IAClB,6CAA6C;IAC7C,aAAa,EAAE,MAAM,CAAA;IACrB,qDAAqD;IACrD,WAAW,EAAE,MAAM,CAAA;IACnB,kCAAkC;IAClC,aAAa,EAAE,aAAa,CAAA;IAC5B,qBAAqB;IACrB,OAAO,CAAC,EAAE;QACR,uEAAuE;QACvE,UAAU,CAAC,EAAE,MAAM,CAAA;QACnB,mEAAmE;QACnE,UAAU,CAAC,EAAE,MAAM,CAAA;KACpB,CAAA;CACF,CAAA"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../src/utils/config.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,wBAAwB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../src/utils/config.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,wBAAwB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAsB3D,CAAA"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"queryParamsMap.d.ts","sourceRoot":"","sources":["../../../src/utils/queryParamsMap.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,eAAO,MAAM,gBAAgB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAEnD,CAAA"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@safe-global/api-kit",
|
|
3
|
-
"version": "3.0.0
|
|
3
|
+
"version": "3.0.0",
|
|
4
4
|
"description": "SDK that facilitates the interaction with the Safe Transaction Service API",
|
|
5
5
|
"types": "dist/src/index.d.ts",
|
|
6
6
|
"main": "dist/cjs/index.cjs",
|
|
@@ -18,17 +18,15 @@
|
|
|
18
18
|
"API"
|
|
19
19
|
],
|
|
20
20
|
"scripts": {
|
|
21
|
-
"test:web3": "export HARDHAT_NETWORK=sepolia && export ETH_LIB=web3 && nyc --reporter=lcov testing-kit test 'tests/endpoint/*.test.*'",
|
|
22
21
|
"test:ethers": "export HARDHAT_NETWORK=sepolia && export ETH_LIB=ethers && nyc --reporter=lcov testing-kit test 'tests/endpoint/*.test.*'",
|
|
23
22
|
"test:viem": "export HARDHAT_NETWORK=sepolia && export ETH_LIB=viem && nyc --reporter=lcov testing-kit test 'tests/endpoint/*.test.*'",
|
|
24
23
|
"test": "yarn test:viem",
|
|
25
|
-
"test:ci:web3": "export HARDHAT_NETWORK=sepolia && export ETH_LIB=web3 && nyc --reporter=lcov testing-kit test 'tests/e2e/*.test.*'",
|
|
26
24
|
"test:ci:ethers": "export HARDHAT_NETWORK=sepolia && export ETH_LIB=ethers && nyc --reporter=lcov testing-kit test 'tests/e2e/*.test.*'",
|
|
27
25
|
"test:ci:viem": "export HARDHAT_NETWORK=sepolia && export ETH_LIB=viem && nyc --reporter=lcov testing-kit test 'tests/e2e/*.test.*'",
|
|
28
26
|
"test:ci": "yarn test:ci:viem",
|
|
29
27
|
"format:check": "prettier --check \"*/**/*.{js,json,md,ts}\"",
|
|
30
28
|
"format": "prettier --write \"*/**/*.{js,json,md,ts}\"",
|
|
31
|
-
"unbuild": "rimraf dist .nyc_output
|
|
29
|
+
"unbuild": "rimraf dist coverage .nyc_output",
|
|
32
30
|
"build": "yarn unbuild && yarn build:esm && yarn build:cjs && yarn build:types",
|
|
33
31
|
"build:esm": "esbuild ./src/index --format=esm --bundle --packages=external --outdir=dist/esm --out-extension:.js=.mjs",
|
|
34
32
|
"build:cjs": "esbuild ./src/index --format=cjs --bundle --packages=external --outdir=dist/cjs --out-extension:.js=.cjs",
|
|
@@ -48,13 +46,14 @@
|
|
|
48
46
|
],
|
|
49
47
|
"homepage": "https://github.com/safe-global/safe-core-sdk#readme",
|
|
50
48
|
"devDependencies": {
|
|
51
|
-
"@safe-global/relay-kit": "^4.0.0
|
|
52
|
-
"@safe-global/testing-kit": "^0.2.0
|
|
49
|
+
"@safe-global/relay-kit": "^4.0.0",
|
|
50
|
+
"@safe-global/testing-kit": "^0.2.0",
|
|
53
51
|
"@types/chai": "^4.3.20",
|
|
54
52
|
"@types/chai-as-promised": "^7.1.8",
|
|
55
53
|
"@types/mocha": "^10.0.10",
|
|
56
54
|
"@types/node-fetch": "^2.6.12",
|
|
57
|
-
"@types/
|
|
55
|
+
"@types/semver": "^7.5.8",
|
|
56
|
+
"@types/sinon": "^17.0.4",
|
|
58
57
|
"chai": "^4.5.0",
|
|
59
58
|
"chai-as-promised": "^7.1.2",
|
|
60
59
|
"ethers": "^6.13.5",
|
|
@@ -63,12 +62,11 @@
|
|
|
63
62
|
"semver": "^7.6.1",
|
|
64
63
|
"sinon": "^19.0.2",
|
|
65
64
|
"sinon-chai": "3.7.0",
|
|
66
|
-
"tsconfig-paths": "^4.2.0"
|
|
67
|
-
"web3": "^4.12.1"
|
|
65
|
+
"tsconfig-paths": "^4.2.0"
|
|
68
66
|
},
|
|
69
67
|
"dependencies": {
|
|
70
|
-
"@safe-global/protocol-kit": "^6.0.0
|
|
71
|
-
"@safe-global/types-kit": "^2.0.0
|
|
68
|
+
"@safe-global/protocol-kit": "^6.0.0",
|
|
69
|
+
"@safe-global/types-kit": "^2.0.0",
|
|
72
70
|
"node-fetch": "^2.7.0",
|
|
73
71
|
"viem": "^2.21.8"
|
|
74
72
|
}
|