Last updated
Was this helpful?
Last updated
Was this helpful?
In this page, we explore an example P256AccountFactory that allows the creation of blockchain accounts whose transactions can be signed using the P256 curve instead of the native secp256k1 provided by the blockchain protocol.
This is incredibly useful, as many IoT devices support this type of cryptography by default, empowering developers to create applications where users can, for example, sign transactions with their biometrics.
This example is based on the code created by the original author of the ERC-4337. The example is deployed on IoTeX and can be freely utilized by developers:
Mainnet Contract
0xD98d2B6cBca981c777037c5784721d8179D7030b
Testnet Contract
0x508Db1A73FcBA98594679aD4f5d8D0B880BbdaFB
The P256AccountFactory also supports a paymaster service, which is made out of two components, a VerifyingPaymaster contract (view ) and an off-chain service endpoint to generate payment proofs for the paymaster contract:
Testnet Endpoint:
The code below shows you how to interact with the p256 account implementation from a javascript client in order to create an account
The following code will show you how to transfer IOTX using bundler service and paymaster.
The rest of the example on how to interact with the p256 account implementation from a javascript client, can be found at .