-1

I want to create my own Solana token that takes %2 fee to all transactions and total supply should be 100k token. That's why i used spl-token cli for this spl-token create-token --transfer-fee 50 1000, however after executing this command i get an error like

Error: Program(IncorrectProgramId)

How can i fix this error or how can i create my own token with transaction fee.

Machavity
  • 30,841
  • 27
  • 92
  • 100
OXI
  • 1
  • 1

1 Answers1

1

When creating a new token with transfer fees, you must specify the program id as the token-2022 program id of TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb, so instead, do:

spl-token --program-id TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb create-token --transfer-fee 50 1000
Jon C
  • 7,019
  • 10
  • 17