2 unstable releases

0.1.0 Oct 30, 2025
0.0.0 Oct 28, 2025

#1524 in Cryptography

Download history 47/week @ 2025-10-26 456/week @ 2025-11-02 1092/week @ 2025-11-09 1489/week @ 2025-11-16 1710/week @ 2025-11-23 2154/week @ 2025-11-30 2537/week @ 2025-12-07 2717/week @ 2025-12-14 1420/week @ 2025-12-21 1721/week @ 2025-12-28 2258/week @ 2026-01-04 2874/week @ 2026-01-11 5807/week @ 2026-01-18 8155/week @ 2026-01-25 11487/week @ 2026-02-01

28,450 downloads per month
Used in 22 crates (2 directly)

Apache-2.0

61KB
956 lines

Token 2022

Programs

The token-2022 repo contains two on-chain programs, the token-2022 program in program, which you can build / test / format using the following commands:

make build-sbf-program
make test-program
make format-check-program
make clippy-program

There's also the ElGamal pubkey registry program in confidential/elgamal-registry, which you can build and test with the following commands:

make build-sbf-confidential-elgamal-registry
make test-confidential-elgamal-registry
make format-check-confidential-elgamal-registry
make clippy-confidential-elgamal-registry

IDL

The token-2022 program has the following IDL.

Generating clients

Once your program's IDL has been generated, you can generate clients for them using the following commands.

pnpm install # only need to run this once
pnpm generate:clients

Managing clients

The following clients are available. You may use the following links to learn more about each client:

Starting and stopping the local validator

The following script is available to start your local validator. In order to run the local validator you must also have the token-2022 and elgamal registry programs built.

make build-sbf-program # you only need to run this once
make build-sbf-confidential-elgamal-registry # you only need to run this once
make restart-test-validator

Finally, you may stop the local validator using the following command.

make stop-test-validator

Dependencies

~13MB
~221K SLoC