Skip to main content

All Questions

Filter by
Sorted by
Tagged with
0 votes
1 answer
400 views

I sent Solana to an SPL token account on accident not realizing it can’t pay the fee to transfer it back - how to u retrieve? I have private key

How do i do this? Do i need to write a program? Is there an existing repo than can be cloned and run? I have tried using CLI in a terminal but haven’t had any luck.
Bryan's user avatar
  • 1
0 votes
2 answers
663 views

Can you send Custom tokens and NFTs to a PDA account?

I have used PDA account to send and receive sol, now I want to send spl token to PDA Account. What is the implementation for that?
frawd's user avatar
  • 391
2 votes
1 answer
182 views

Why is AssociatedToken Program not needed when using associated_token constraint in anchor?

I wrote a piece of code that uses associated_token::mint and associated_token::authority and I passed the Token Program but did not pass the Associated Token Program. Considering All Accounts must be ...
chinepun.sol's user avatar
0 votes
1 answer
2k views

Error: failed to get accounts owned by program TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA excluded from account secondary indexes; this RPC

I am trying to find all the token accounts that belong to a specific wallet address however i keep getting this error: Error: failed to get accounts owned by program ...
shauna vayne's user avatar
2 votes
1 answer
91 views

Trying to send specific SPL Token but creates new token instead

I'm trying to send a SPL Token but when I execute the code below it creates an unknown token and sends it, It does not recognize the token address / programID. Where should I pass the token address? ...
korimusk's user avatar
0 votes
1 answer
37 views

What's the best practice around supporting token accounts other than associated token accounts

In my program, suppose I want to take tokens from a user, or send tokens to that user, etc. Should I support any token accounts (given the mint and the owner matches of course), or only the associated ...
Sumit Ghosh's user avatar
1 vote
2 answers
760 views

Error processing Instruction 0: custom program error: 0x12

I am getting this error when trying to do an SPL token transfer. Solana Docs makes it seem as if this is a 'Frozen Account' error. I am not sure why the account of the sender or the newly created ...
Andrew Melbourne's user avatar
6 votes
2 answers
604 views

Looking for implementation example of anchor_spl::token::initialize_account

I want to use the initialize_account function from anchor_spl::token. The function is given below: pub fn initialize_account<'a, 'b, 'c, 'info>( ctx: CpiContext<'a, 'b, 'c, 'info, ...
fahad's user avatar
  • 399
2 votes
1 answer
377 views

Solana can't mint to a different token account

Folks, I'm starting with Solana and it's been rough to learn. Despite the poor error messages and the learning curve of Rust, I'm making my way through it. I'm trying to develop a new token that will ...
Dinaiscoding's user avatar
0 votes
1 answer
152 views

Amount not showing in wallet for spl-token transfer

I am working on some code to transfer some spl-tokens from a user connected wallet. But when I send the transfer instructions, the amount does not show up in the wallet for user approval; and ...
PutCallTheta's user avatar
1 vote
3 answers
880 views

Failing to create associated token account in rust tests. It says insufficient account keys for instruction

https://github.com/SushantChandla/test-mint-bug/blob/main/programs/mint-bug/tests/mint.rs I am trying to create an associated token account please have a look at the github file. The error I get is ...
Sushant Chandla's user avatar

1
2