@heyanon/sdk 2.0.0 → 2.0.1

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.
@@ -1,6 +1,6 @@
1
1
  import { AiTool } from '../ai';
2
2
  import { EVM, Solana } from '../blockchain';
3
- import { Hex, PublicClient, SignMessageReturnType, SignTypedDataParameters as ViemSignTypedDataParameters, SignTypedDataReturnType } from 'viem';
3
+ import { Hex, PublicClient, SignMessageReturnType, SignTypedDataParameters as ViemSignTypedDataParameters, SignTypedDataReturnType, Address } from 'viem';
4
4
  import { Connection, PublicKey } from '@solana/web3.js';
5
5
  export interface FunctionReturn {
6
6
  readonly success: boolean;
@@ -9,14 +9,16 @@ export interface FunctionReturn {
9
9
  type SignTypedDataParameters = Omit<ViemSignTypedDataParameters, 'account'>;
10
10
  export interface EvmFunctionOptions {
11
11
  readonly getProvider: (chainId: number) => PublicClient;
12
+ readonly getRecipient: () => Promise<Address>;
12
13
  readonly sendTransactions: (props: EVM.types.SendTransactionProps) => Promise<EVM.types.TransactionReturn>;
13
14
  readonly signMessages?: (messages: Hex[]) => Promise<SignMessageReturnType[]>;
14
15
  readonly signTypedDatas?: (args: SignTypedDataParameters[]) => Promise<SignTypedDataReturnType[]>;
15
16
  }
16
17
  export interface SolanaFunctionOptions {
17
18
  readonly getConnection: () => Connection;
18
- readonly sendTransactions: (props: Solana.types.SendTransactionProps) => Promise<Solana.types.TransactionReturn>;
19
+ readonly getRecipient: () => Promise<PublicKey>;
19
20
  readonly getPublicKey: () => Promise<PublicKey>;
21
+ readonly sendTransactions: (props: Solana.types.SendTransactionProps) => Promise<Solana.types.TransactionReturn>;
20
22
  }
21
23
  export interface FunctionOptions {
22
24
  readonly evm: EvmFunctionOptions;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@heyanon/sdk",
3
- "version": "2.0.0",
3
+ "version": "2.0.1",
4
4
  "license": "MIT",
5
5
  "main": "dist/index.js",
6
6
  "typings": "dist/index.d.ts",