kokio-sdk 0.0.7 → 0.0.9

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "kokio-sdk",
3
- "version": "0.0.7",
3
+ "version": "0.0.9",
4
4
  "description": "",
5
5
  "type": "module",
6
6
  "main": "./dist/esm/config.js",
@@ -4,7 +4,8 @@ import {
4
4
  getEntryPoint,
5
5
  SmartContractAccount,
6
6
  toSmartContractAccount,
7
- split
7
+ split,
8
+ SmartAccountClient
8
9
  } from "@aa-sdk/core";
9
10
  import {
10
11
  http,
@@ -266,7 +267,7 @@ export const _getSmartWallet = async (
266
267
  });
267
268
  }
268
269
 
269
- export const _getSmartWalletClient = async (client: WalletClient, pimlicoAPIKey: string, gasPolicyId: string, account: SmartContractAccount) => {
270
+ export const _getSmartWalletClient = async (client: WalletClient, pimlicoAPIKey: string, gasPolicyId: string, account: SmartContractAccount): Promise<SmartAccountClient> => {
270
271
 
271
272
  const chainID = await client.getChainId();
272
273
  const rpcURL = client.transport.url;
@@ -195,8 +195,8 @@ export const _getChainSpecificConstants = (
195
195
  }
196
196
  else if (chainID == CHAIN_ID.BASE_MAINNET) {
197
197
  return {
198
- factoryAddresses: optimismMainnetFactoryAddresses,
199
- chain: optimism,
198
+ factoryAddresses: baseMainnetFactoryAddresses,
199
+ chain: base,
200
200
  rpcURL: rpcURL,
201
201
  pimlicoRpcURL: pimlicoAPIKey ? `https://api.pimlico.io/v2/${chainID}/rpc?apikey=${pimlicoAPIKey}` : "",
202
202
  customErrors: customErrors
@@ -204,8 +204,8 @@ export const _getChainSpecificConstants = (
204
204
  }
205
205
  else if (chainID == CHAIN_ID.BASE_SEPOLIA) {
206
206
  return {
207
- factoryAddresses: optimismSepoliaFactoryAddresses,
208
- chain: optimismSepolia,
207
+ factoryAddresses: baseSepoliaFactoryAddresses,
208
+ chain: baseSepolia,
209
209
  rpcURL: rpcURL,
210
210
  pimlicoRpcURL: pimlicoAPIKey ? `https://api.pimlico.io/v2/${chainID}/rpc?apikey=${pimlicoAPIKey}` : "",
211
211
  customErrors: customErrors