@alchemy/aa-accounts v3.19.0
@alchemy/aa-accounts
This package contains various implementations of the BaseSmartContractAccount class defined in aa-core. This repo is community maintained and we welcome contributions!
Getting started
If you are already using the @alchemy/aa-core package, you can simply install this package and start using the accounts. If you are not using @alchemy/aa-core, you can install it and follow the instructions in the Getting started docs to get started.
via yarn
yarn add @alchemy/aa-accountsvia npm
npm i -s @alchemy/aa-accountsvia pnpm
pnpm i @alchemy/aa-accountsContributing
If you are looking to add a new account type, please follow the following structure.
- Create a new folder in
srcwith the name of your account type inkebab-case(we are following kebab casing for files throughout the project). - Create a new file in the folder you just created called
account.tsand add your implementation forBaseSmartContractAccount - If needed, create a sub-folder in your account folder called
abisand add your abis as.tsfiles. eg:
export const MyContractAbi = [] as const; // the as const is important so we can get correct typing from viem- If you need to extend the
SmartAccountProviderclass, add a file calledprovider.tsand add your implementation forSmartAccountProvider.
- Ideally, your
Accountimpl should just work with the base provider provided byaa-core. - If not, consider generalizing the use case and updating SmartAccountProvider
- Add some tests for your account and provider (if created) by creating a subfolder in your
account/my-accountcalled__tests__and make sure your files end with the.test.tssuffix - export the classes and types you have defined in
src/index.ts - Open a PR and we will review it as soon as possible!
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
1 year ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago