Skip to main content

Questions tagged [spl-token-program]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
2 votes
1 answer
33 views

Observing a contract's behavior and withdrawing tokens from it

I recently encountered an error while trying to withdraw stSOL from the Tulip Protocol's "Lending" section: Program Error: "Instruction #3 Failed - null" At first, I thought it ...
2 votes
0 answers
22 views

Decoding an instruction for a token on the spl token program

Hello you may have seen my last post, Error : TypeError: Cannot read properties of undefined (reading 'equals') This is a follow up to that post. I decided to experiment more with ...
3 votes
0 answers
190 views

How to Bridge ERC-20 Tokens to a Similar Contract on Solana Using Wormhole or Equivalent Platform?

I am currently working on a blockchain project where I’ve encountered a challenge that I hope to get some insights on. Background: I have an existing ERC-20 token contract on Ethereum, which includes ...
0 votes
0 answers
16 views

How to Set Token Metadata Immutable upon Creation in Solana without Using createUpdateAuthorityInstruction?

my name is Tirta. Long story short, Blowfish.xyz has incorrectly flagged my dApp as malcious. my dApp is solana token2022 creator. it's simple. I managed to talk with them via email, giving them all ...
2 votes
1 answer
126 views

how to transfer spl token with transfer-hook extension

I used the Solana Playground wallet to deploy a program and obtained the program ID. The ID is 6baxXgMr7HypeTBhN64rbrt31UwbSeRtsQQxGw1KBi5b. Then, I used the following script to create an SPL token. //...
0 votes
3 answers
240 views

Getting dapp could be malicious warning during phantom wallet transaction

Hi I have deployed my spl-token program to mainnet-beta recently, so its publicly available but from last two days I am getting warning "This dapp could be malicios" warning on phantom ...
1 vote
2 answers
577 views

How to get the price of an spl token relative to solana?

The thing is that I need to calculate the price of a tokan in sol or in usd. I would use one of the publicly available APIs, such as birdeye or jupiter, but they do not display the price of tokens ...
5 votes
1 answer
34 views

({"err":{"InstructionError":[2,"PrivilegeEscalation"]}})

use anchor_lang::prelude::*; use anchor_spl::token::{Mint, Token, TokenAccount, Transfer}; declare_id!("5L3ky71YgB1rRMbJMxw9iH2vw9A59wZ2krWW7vdwfn61"); #[program] pub mod hodl_token_lock { ...
4 votes
3 answers
2k views

TokenAccountNotFoundError when sending SPL tokens in React

When I try to send my SPL tokens I get this error: OrderRow.js:72 TokenAccountNotFoundError at unpackAccount (account.ts:170:1) at getAccount (account.ts:103:1) at async ...
2 votes
0 answers
21 views

How to identify liquidity pool burns in Sol Incinerator and determine authority in Solana?

When a liquidity pool is burned in Sol Incinerator on Solana, will the associated token always have Raydium as the authority? Additionally, how can I filter transactions to specifically identify when ...
0 votes
0 answers
26 views

'Octal escape sequences are not allowed in strict mode' error when generating keypair

I started Solana and web 3 dev recently Have been having this issue for like 3 days, tried checking online for solutions and nothing. Please help anyone CODE import { Keypair } from "@solana/web3....
0 votes
0 answers
20 views

Is there anyway I can make my spl token transfer consistent despite the congestion just like phantom wallet?

I am trying to send spl tokens and make it consistent despite this congestion. I've been getting 2 successful transactions in 50 tries even though I am using a function from Jupiter that forcefully ...
2 votes
1 answer
17 views

SNS - Retrieve all Domains+Subdomains of an User

The following code is used to retrieve all Sub-Domains of a Public-Key. const getAllSNSProgramAccounts = async () => { const accounts = await connection.getProgramAccounts(new PublicKey('...
3 votes
1 answer
108 views

Metaplex Transfer pNFT failing

I am trying to transfer a pNFT via an anchor program, but it is failing at the TokenProgram. Logs below
2 votes
1 answer
66 views

Transfer specific token to and from a known account

Given that I have the following program use anchor_lang::prelude::*; use anchor_spl::token::{self, Mint, Token, TokenAccount, Transfer as SplTransfer}; declare_id!("...
0 votes
0 answers
23 views

Token 2022 Program: FreezeAccount (Program Error: "Invalid account state for operation")

I bought YUKI tokens and got this message when I tried to sell them, "Token 2022 Program: FreezeAccount (Program Error: "Invalid account state for operation")" what do I do to get ...
1 vote
2 answers
2k views

how to decode data instructions with javascript

upd: https://docs.solana.com/developing/programming-model/transactions#instruction-data here, my task is to decode this data using js I tried to solve the issue with this post How to get Solana ...
1 vote
1 answer
69 views

Why do we close WSOL Token Program accounts?

Background: If I understand correctly: During transactions where we transfer SOL to/from wallets, we need to wrap the SOL in a temporarily created WSOL Token Program account. Then use that to transfer ...
2 votes
2 answers
546 views

Using @solana/spl-token-swap package on devnet

I'm following along with this site https://www.soldev.app/course/token-swap. However, there seems to be a version difference in the use of TokenSwap.withdrawAllTokenTypesInstruction: I'm using the ...
0 votes
3 answers
827 views

how to find a new token in the block

I searched for a similar question but couldn't find one. So, I get the last block, then inside this, block I parsing all transactions. My task is to find information that a new token has been created. ...
0 votes
2 answers
92 views

Verified token creators?

we are looking into launching a token on the Solana chain but with our little experience we doubt our own process a little and due to the 'set in stone' principe of blockchain we went looking on the ...
0 votes
1 answer
20 views

How to filter most recently created pdas of a program

How to filter most recently created pdas of a program, How should date be store in pda data so that we can directly filter based on the data stored in pda. For ex. filtering all pda of a program ...
3 votes
1 answer
52 views

Confidential Transfer Solana Setup script failing

I am trying to understand Solana Confidential Transfers, so I ran this script from the official Solana repository for a simple demonstration https://github.com/solana-labs/solana-program-library/blob/...
1 vote
1 answer
42 views

How to create associated token account for a new mint?

I created a new token with metadata with this guide. Now I want to create the corresponding token account by using const tokenAccount = await getOrCreateAssociatedTokenAccount( ...
2 votes
0 answers
36 views

What function should I use to purchase a token transfer with program_id?

I am trying to repeat this transaction (4Ku7oqwPAwRLPm7jNp2oTigYv8XpcTPLJwF49dLVS6ypi35vH9orwRAPcfMj37jj8FwmpMFuP5j8cS1hwdoXJp67) programmatically on solana or solana cli (I will be grateful for any ...
1 vote
0 answers
16 views

Fund associated token account

I am trying to swap SOL to USDC on the devnet. I get this error "Input token account empty". I know that this means that the associated token accounts A and B have to have some funds. I am ...
1 vote
0 answers
65 views

The provided token program does not match the token program expected by the swap

import { logger } from "../helpers"; import * as web3 from "@solana/web3.js"; import * as token from "@solana/spl-token"; import { TokenSwap, TOKEN_SWAP_PROGRAM_ID, ...
1 vote
1 answer
68 views

How can I resolve this "Error processing Instruction 1: custom program error: 0x1004"

I'm running into the following error trying to work through the transfer hook docs. https://solana.com/developers/guides/token-extensions/transfer-hook I am using Ubuntu on Windows WSL: I am running ...
1 vote
1 answer
159 views

expected a sequence of length 32 (got 43) error when using solana in Python

Solana community! I'm working on a Python script to filter transactions executed through the SPL Token Program. I aim to specifically identify and list new token creation transactions. However, I'm ...
0 votes
1 answer
26 views

Are funds sent into an adress with IsOnCurve Retreivable?

was wondering if you can answer my question , I sent usdc to an adresse with IsOnCurve False, it was an exchange adress , from what i read i understood that funds are lost because nobody really has ...
0 votes
1 answer
2k views

How to transfer SPL Tokens? [duplicate]

I'm running a Solana node and I'd like to send a transfer request to my running node. I can transfer SOL but I don't know what I need to do for transferring SPL Tokens like GMT or SRM. I was looking ...
0 votes
1 answer
60 views

Issue in Adding Token Metadata using SPL Token CLI

I have created a new SPLToken on DevNet and added the following account - 2ePFwPK3coTPqzirUaM9fugKnQL1V6zQp5TbPmopipiH I am trying to add the metadata to the newly created SPL Token using the ...
0 votes
1 answer
71 views

How to specify the amount to be minted and total supply in "createAndMint(...)"?

Fungible tokens The createAndMint(...) function accepts the parameter amount. This is an amount of tokens to be minted immediately, right? Then how to specify the total supply?
1 vote
1 answer
51 views

InvalidAccountData error on token transfer function ( using metaplex-toolbox )

I've created a dApp on React which uses the Solana blockchain to create, mint, and send utility tokens. I'm using @metaplex-foundation/umi and @mpl-toolbox to create the token, mint it to the creator'...
1 vote
1 answer
339 views

"Program log: Instruction: GetAccountDataSize", "Program log: Error: IncorrectProgramId", "Program TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA

Based on reading [https://github.com/solana-labs/solana-program-library/blob/master/token/program/src/instruction.rs#L426][1] It looks like the Token program does in fact have GetAccountDataSize so I ...
1 vote
1 answer
68 views

SPL Token Metadata Initialization Error - Transaction Simulation Failed

I am trying the SPL Token Program to configure the metadata for the token deployed on DevNet. I have validated the token mint address. It is displaying the following error. Could you please help to ...
0 votes
1 answer
46 views

Token Creation Issue on DevNet

I am trying to create a token after setting my wallet using the following command. solana-keygen grind --starts-with ott:1 The wallet creation is successful. I have also configured the connection to ...
1 vote
2 answers
865 views

Error: unable to confirm transaction. This can happen in situations such as transaction expiration and insufficient fee-payer funds

1. Description of my context on api.mainnet-beta.solana.com Token machine made with Windows 11 remote PC Connected to Sol network by api.mainnet-beta.solana.com 1.1 Detailed description coming from ...
4 votes
2 answers
276 views

Check mint to create either Token or Token2022 on demand

Solana's Token 22 tutorial tells you how to upgrade to 2022, but most deployed programs need to support existing accounts that were made with the Token program. Let's say we have an ix that makes a ...
0 votes
0 answers
24 views

Filtering all transaction of a particular mint address

Filtering all transaction of a particular mint address, getSignaturesForAddress functions returns transactions, but still some of the transaction are missing in the returned list. Like actual number ...
0 votes
0 answers
25 views

Is it possible to send SPL token from a wallet to another wallet using laravel?

I want to try writing code to send SPL tokens from one wallet to another. I've tried it before using a JS framework, but now I want to try using Laravel. I managed to create a wallet connection, but ...
0 votes
0 answers
45 views

Transfer SPL Token only using Plain HTML and JS

I want to ask, is it actually possible to make transactions using only HTML and JS without using a framework? I am currently trying to transfer an SPL token, but I am always getting stuck using only ...
2 votes
1 answer
72 views

Transfer Hook vulnerabilities

I can't tell how safe it is to arbitrarily support transfers on "transfer hook" enabled tokens via CPI from my program. At the moment i am setting is_signer and is_writable to false on all ...
0 votes
0 answers
1k views

How to listen to liquidity burns on the solana chain

Using the solana websocket url I'm listening to the solana blockchain logs and then filter those logs based on a certain criteria. async function main(connection, programAddress) { console.log("...
0 votes
1 answer
278 views

How to charge transaction fee in my token insteed of SOL if any one tranfer my XYZ token they pay in XYZ instead SOL, Ithey don't need to hold SOL

I'm seeking for help any body can help regarding spl, token, I'm working on app it has in app wallet, if some did dum task I'll provide my token as mining reward, so what I need that, when they ...
0 votes
0 answers
77 views

solana pnft staking program

I'm trying to escrow the user NFT in the stake instructions bu using transferbuilder and using sign invoked with master edition nft as i assume it has the freeze authority on pnfts and getting this ...
1 vote
1 answer
73 views

How to use the key pair of the user connecting on my website to mint SPL token

I want to create a website for users to connect their wallets (phantom etc) to my website, then they can generate tokens into their wallets themselves. I looked at the example on https://spl.solana....
1 vote
1 answer
61 views

what should be value of tokenswapStateAccount when trying to swap

I am using node js @solana/web3 and @solana/spl-token and spl-token-swap libraries to perform a swap of token. I am confused with what should be the value of tokenSwapStateAccount and where would I ...
0 votes
0 answers
690 views

Solana SPL token holder count

I'm trying to find an efficient way to get the total token holders of an SPL token. For ETH ERC-20 tokens I use Etherscan API, this returns me an integer of the total holders of the token address used ...
1 vote
1 answer
206 views

Creating SPL token Non-Transferable Extension with metadata on React

I'm trying to create SPL token with Non-Transferable Extension with metadata. Right now I can create token with each features only follow these guides, and fails to combine them. below is how I tried ...