githubEdit

Payers

PAYER_PUBKEY: Pubkey

Anchor currently does not support PDAs as payers for account initialization. This means that if one of your automated instructions initializes a new account, you must specify a keypair signer as the payer. For this, we provide a special Clockwork payer address:

C1ockworkPayer11111111111111111111111111111

You can import that address with the Typescript SDKarrow-up-right:

You can import that address with the Rust SDKarrow-up-right:

If an account in your automated instruction references the Clockwork payer account, workers will automatically inject their address in its place. By doing this, the worker node will pay for any account initializations your program needs to do, and Clockwork will reimburse the worker from your thread's account balance.

circle-info

When Anchor adds support for PDA payers (expected in the next release), this “dynamic payer” feature may be deprecated in favor of using PDAs to pay for account initializations.

https://github.com/coral-xyz/anchor/pull/1938arrow-up-right

Last updated