简体   繁体   English

solana spl-token 转移费用“错误:程序(IncorrectProgramId)”

[英]solana spl-token transfer fee "Error: Program(IncorrectProgramId)"

I want to create my own Solana token that takes %2 fee to all transactions and total supply should be 100k token.我想创建我自己的 Solana 代币,它对所有交易收取 %2 的费用,总供应量应该是 100k 代币。 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这就是为什么我为此spl-token create-token --transfer-fee 50 1000使用spl-token cli 的原因,但是在执行此命令后我收到如下错误

Error: Program(IncorrectProgramId)错误:程序(不正确的程序 ID)

How can i fix this error or how can i create my own token with transaction fee.我该如何修复此错误或如何使用交易费创建自己的令牌。

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:创建带有转账费用的新代币时,您必须将程序 ID 指定为TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb的 token-2022 程序 ID,因此,改为:

spl-token --program-id TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb create-token --transfer-fee 50 1000

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM