-
Notifications
You must be signed in to change notification settings - Fork 80
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Readme files for account, paymaster and bundler package #229
Conversation
packages/account/Readme.md
Outdated
import { IPaymaster, BiconomyPaymaster } from '@biconomy/paymaster' | ||
|
||
const paymaster: IPaymaster = new BiconomyPaymaster({ | ||
paymasterUrl: '' // you can get this value from biconomy dashboard. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: we should add link to the biconomy dashboard whenever we mention to get a value from it
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good
packages/account/Readme.md
Outdated
@@ -0,0 +1,133 @@ | |||
# Biconomy SDK | |||
The Biconomy Software Development Kit (SDK) build purely on atop of ERC4337 solution, presents a comprehensive range of solutions, from user onboarding to sustained engagement, specifically designed for decentralised applications (dApps). This SDK functions in a non-custodial fashion, provides a unified solution that enhances the user experience within your dApp. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
on * the top of
ERC4337 solution can have a better word.
packages/account/Readme.md
Outdated
signer: wallet.getSigner(), | ||
chainId: ChainId.POLYGON_MAINNET, | ||
rpcUrl: '', | ||
paymaster: paymaster, //you can skip paymaster instance if not interested in transaction sposoring |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for how to create paymaster instance, refer to paymaster docs.
one can also create their custom paymaster as long as it implements IPaymaster interface. this should be mentioned here/somewhere
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have already added the snippet to create a Paymaster instance before this step
packages/account/Readme.md
Outdated
// building userOperation | ||
const builtUserOp = await biconomySmartAccount.buildUserOp([transaction]) | ||
|
||
const biconomyPaymaster = biconomySmartAccount.paymaster as IHybridPaymaster<SponsorUserOperationDto> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this part is specific to paymaster and biconomy paymaster. this should not be here but instead in paymaster readme.
packages/paymaster/Readme.md
Outdated
|
||
**getPaymasterFeeQuotesOrData** | ||
|
||
This function is used to fetch quote information or data base on provider userOperation and paymasterServiceData. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
*based on
packages/paymaster/Readme.md
Outdated
|
||
**buildTokenApprovalTransaction** | ||
|
||
This function is specifically used for token paymaster sponsorship. The primary purpose of this function is to create an approve transaction that gets batched with the rest of your transactions. This way, you will be paying the paymaster in ERC20 tokens, which will result in the paymaster paying on your behalf in native tokens. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
*token approval transaction
explain here spender will be paymaster
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"which will result in the paymaster paying on your behalf in native tokens" this is not needed and is rather confusing
packages/paymaster/Readme.md
Outdated
|
||
**getPaymasterAndData** | ||
|
||
This function accepts a **`Partial<UserOperation>`** object that includes all properties of **`userOp`** except for the **`signature`** field. It returns **`paymasterAndData`** as part of the **`PaymasterAndDataResponse`**. The **`paymasterAndData`** string is signed by the paymaster's verifier signer, which will eventually result in the payment of your transaction fee by the paymaster. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
correct this as well.
The paymasterAndData
string is signed by the paymaster's verifier signer. this is misleading
packages/paymaster/Readme.md
Outdated
SponsorUserOperationDto, | ||
} from '@biconomy/paymaster' | ||
|
||
const bundler: IBundler = new Bundler({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this readme should only showcase how to create paymaster instance and different methods available. and minimal info on how to use it with userop. actually just say that once you get paymasterAndData you can update your userop.
All specific about attributes passed in case of hybrid paymaster can be added separately here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
gave some comments. do pass your whole files for grammar checker and update accordingly with it's suggestions and checks. I will update these more tomorrow.
we also need updated Readme for common and core-types packages. |
This PR includes Readme files for account, paymaster and bundler package