Skip to content

Commit bce8ae2

Browse files
committed
add eoa execution options type
1 parent c26be2d commit bce8ae2

File tree

2 files changed

+31
-4
lines changed

2 files changed

+31
-4
lines changed

packages/engine/src/client/types.gen.ts

Lines changed: 28 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,28 @@ export type AaZksyncExecutionOptions = {
9292
chainId: string;
9393
};
9494

95+
/**
96+
* Uses EOA for execution. Only supported for signing currently.
97+
*/
98+
export type EoaExecutionOptions = {
99+
type: "eoa";
100+
101+
/**
102+
* The EOA address
103+
*/
104+
address: string;
105+
106+
/**
107+
* The chain id of the transaction
108+
*/
109+
chainId: string;
110+
111+
/**
112+
* The idempotency key of the transaction. Transaction requests sent with the same idempotency key will be de-duplicated. If not provided, a randomUUID will be generated. This is also used as the ID of a queued/stored transaction.
113+
*/
114+
idempotencyKey?: string;
115+
};
116+
95117
export type ListAccountsData = {
96118
body?: never;
97119
path?: never;
@@ -434,7 +456,8 @@ export type SignTransactionData = {
434456
executionOptions:
435457
| AutoExecutionOptions
436458
| AaExecutionOptions
437-
| AaZksyncExecutionOptions;
459+
| AaZksyncExecutionOptions
460+
| EoaExecutionOptions;
438461
params: Array<{
439462
/**
440463
* The recipient address
@@ -585,7 +608,8 @@ export type SignMessageData = {
585608
executionOptions:
586609
| AutoExecutionOptions
587610
| AaExecutionOptions
588-
| AaZksyncExecutionOptions;
611+
| AaZksyncExecutionOptions
612+
| EoaExecutionOptions;
589613
params: Array<{
590614
/**
591615
* The message to sign
@@ -661,7 +685,8 @@ export type SignTypedDataData = {
661685
executionOptions:
662686
| AutoExecutionOptions
663687
| AaExecutionOptions
664-
| AaZksyncExecutionOptions;
688+
| AaZksyncExecutionOptions
689+
| EoaExecutionOptions;
665690
params: Array<{
666691
domain: {
667692
chainId?: number | number;

packages/thirdweb/src/engine/server-wallet.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import {
22
type AaExecutionOptions,
33
type AaZksyncExecutionOptions,
4+
type EoaExecutionOptions,
45
sendTransaction,
56
signMessage,
67
signTypedData,
@@ -46,7 +47,8 @@ export type ServerWalletOptions = {
4647
*/
4748
executionOptions?:
4849
| Omit<AaExecutionOptions, "chainId">
49-
| Omit<AaZksyncExecutionOptions, "chainId">;
50+
| Omit<AaZksyncExecutionOptions, "chainId">
51+
| Omit<EoaExecutionOptions, "chainId">;
5052
};
5153

5254
export type ServerWallet = Account & {

0 commit comments

Comments
 (0)