Questions tagged [spl-token]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
0 votes
0 answers
9 views

transfer SPL Tokens? what wrong?

I'm attempting to transfer SPL tokens using Solana's Web3.js, but I'm encountering a SendTransactionError related to invalid account data during the transaction simulation. I need help understanding ...
Joe's user avatar
  • 1
1 vote
1 answer
27 views

Block tokens on someone else's address

I'm looking for a way to block tokens created on the Solana blockchain. Ideally I would like to do this using Python. Please provide code samples. Situation: I need to block an account that has my ...
Atr118's user avatar
  • 21
1 vote
1 answer
8 views

Issues with @solana/spl-tokens pnpm is not saving this package to where I can't connect to the blockchain with the following .js file:

const { Token, TOKEN_PROGRAM_ID } = require("@solana/spl-token"); const { Connection, PublicKey, Keypair } = require("@solana/web3.js"); async function main() { // Your existing ...
Brennen Segura's user avatar
0 votes
0 answers
7 views

how to find thhe eddsa for updating my spl-token

I'm looking for a way to update my eddsa variable, am using metaplex, am new to updating a token in using metaplex. there is my code `import * as mpl from "@metaplex-foundation/mpl-token-...
Emmanuel uzoezie's user avatar
0 votes
2 answers
30 views

Is it possible to have reflection tokens like safemoon on solona?

A reminder on how reflection tokens like safemoon work is every ones balance is simply an equation instead of a fixed number. That way everyone's balance can be instantly updated with no gas needed ...
OPP's user avatar
  • 1
0 votes
2 answers
29 views

How to transfer large number of SPL tokens?

pub fn transfer<'info>(ctx: CpiContext<'_, '_, '_, 'info, Transfer<'info>>, amount: u64) -> Result<()> The above code is the method defenition used in rust to transfer SPL ...
Aravind Makam's user avatar
0 votes
0 answers
19 views

I keep getting error in this typescript code

import { clusterApiUrl, Connection, Keypair, PublicKey, } from "@solana/web3.js"; import { createMint, createAccount, mintTo,getAccount,getMint, getOrCreateAssociatedTokenAccount,...
Encrypted's user avatar
1 vote
1 answer
36 views

How do I initialize the transfer-hook account using the provided CLI?

I am trying to follow the examples provided on the Solana website to create and implement a transfer-hook program. I have successfully built and deployed the example program provided here, then minted ...
tonton's user avatar
  • 33
2 votes
2 answers
48 views

Is it possible yet to use mint tokens supporting both transfer fees and confidential transfers?

I can see in the documentation that Token-2022's transfer fees and confidential transfers are supported (or intended to be supported) when used together. However, when I attempt to mint a token with ...
JTB's user avatar
  • 23
1 vote
1 answer
66 views

Does token-2022 allow selling fees instead of a basic transfer fee?

I understand now that the token-2022 standard allows transfer fees but does this also allow a fee that only enforces itself when the coin is being sold just like on Ethereum.
lolswag's user avatar
  • 11
0 votes
2 answers
44 views

newly created SPL-tokens are not displaying in phantom

I created some SPL-tokens via spl-token create-token ..., and applied some metadata (name, symbol, description, image) via metaboss create metadata .... They appear correctly on solscan, but are not ...
Ivaldi's user avatar
  • 1
0 votes
1 answer
35 views

createTransferCheckedInstruction - invalid account data for instruction

I'm trying to write instructions for transferring spl-tokens(not nft): const transfer = createTransferCheckedInstruction( account_from.publicKey, mintId, account_desc.publicKey, ...
Leo Loki's user avatar
  • 278
0 votes
1 answer
19 views

AccountOwnedByWrongProgram

I've been working on Solana program that should hold two different tokens for me in a Vault in an ATA. The first token should be deposited during Vault initialisation, the second will be deposited by ...
Kamil Słuszniak's user avatar
1 vote
2 answers
75 views

Get "Account is Frozen" error when sending NFT to another account on Solana

I've recently tried to transfer nfts to another account by using @solana/spl-token https://solscan.io/account/9xaaESgAuDeQ9bHm6TArg11zuQem7WjSVf5ioK2jZPNR I have ...
weatherstar's user avatar
2 votes
2 answers
234 views

SPL Token Renounce Ownership

Question how would you renounce ownership for spl token you created ? So like no one can mint or freeze ever again basically making it immutable
Chiemeka Kehinde's user avatar
0 votes
1 answer
52 views

SPL token transactions check

I figured out how to make my token and check incoming applications in the solana network with the usual transfer of solana. But how do I track an incoming transfer with a certain amount of my token to ...
Atr118's user avatar
  • 21
0 votes
0 answers
49 views

Embedded wallets, USDC and account rental

I'm evaluating Solana as an option to support Generate an embedded, user owned, wallet per sign-up (BYO as secondary option). Only deal with USDC in and between these wallets, i.e. no customer ...
uxcxdx's user avatar
  • 101
1 vote
1 answer
106 views

Confused about Tokens

I am very new to Solana and am going through the Bootcamp on SOLANA YT channel. Can someone explain me what are tokens? Why do we need tokens? What is Mint? How is SPL different from SOL?
rossexotic's user avatar
1 vote
1 answer
38 views

freeze_authority being null

This isn't a very technical question but more of a theoretical. I've heard in different places where the in Solana freeze authority violates the idea of immutability or decentralization if an SPL ...
WowBow's user avatar
  • 123
2 votes
1 answer
131 views

How do I create a basic program to use as a Token-22 transfer hook in Anchor? Is it even possible now?

I want to create a counter PDA that counts the number of times a token has been transferred. I understand how to create the counter PDA using the Solana Playground tutorial as the basis and I know how ...
tonton's user avatar
  • 33
0 votes
0 answers
27 views

Can't realloc and SPL transfer in the same instruction

I am trying to transfer an SPL token, and reallocating space in a PDA in one instruction. I am able to realloc (increase and decrease) if I remove the token transfer code in the instruction. I'm also ...
Joey B's user avatar
  • 1
0 votes
1 answer
29 views

having issues with the token programme ID when trying to send SPL tokens from my game to the connected users wallet

I'm trying to perform a token transfer using postman with the script I have, I want the script to be my backend server for token transfers in my unity game. I have tried multiple debug logs attached ...
Solana_dean's user avatar
1 vote
1 answer
47 views

Active delegates on a SPL token account

I am working on an application where it is required for the backend system to invoke transfer of funds at a later time(By later time, here means when the account owner is not present). Delegation ...
not-available's user avatar
0 votes
1 answer
34 views

Need Help Displaying Token and NFT Holdings in Solana Dapp Portfolio

I'm currently working on a Solana Dapp portfolio project where users can connect their wallets and view their token and NFT holdings. I am done making the wallet connection buttons and installing ...
M.amanullah behlim's user avatar
1 vote
2 answers
109 views

Can invoke_signed Be Used in Solana Native Programs to Handle SPL Tokens for Staking?

While reviewing the Solana codebase, I came across the invoke_signed function, which is commonly used for cross-program invocations. I'm particularly interested in understanding if it's possible to ...
Syed Ghazanfer Anwar's user avatar
1 vote
2 answers
58 views

Does Solana have a clear-cut distinction between SOL and SPL tokens?

In Ethereum, the only native asset is Ether (ETH). It's the only asset that gets first-class treatment in terms of cost and ability to be pushed and pulled through contract calls. Is there a similarly ...
Paul Razvan Berg's user avatar
0 votes
1 answer
33 views

How can I query all the owners of an SPL token?

My background is in Ethereum, where it is easy to get the full list of owners for a particular token (e.g. USDC) using The Graph or a node (by filtering Transfer events). How can I do this with an SPL ...
Paul Razvan Berg's user avatar
0 votes
2 answers
33 views

Can assosiated addresses be generated on an account with no SOL on it?

Let's say, I've generated 1000 accounts manually, via code. I also want to generate USDT and USDC addresses for each of them. Then I'll give them to the users of my service for them to send USDT and ...
Camila326's user avatar
  • 149
0 votes
2 answers
66 views

I need to understand the escrow flow in Rust on Solana

I want to create an escrow program in Rust on Solana with the following requirements: Anyone can send an amount to the escrow, a lottery function runs on the backend to select a winner, and the NFT is ...
Umaid Khalid's user avatar
0 votes
1 answer
52 views

How to generate an associated token account when generating the one in SOL?

I have a web service in which I'll be generating to my users wallets in SOL and in USDT/USDC. The wallets will be custodial, for deposits, and it has to be this way. And I need to obtain and parse ...
Camila326's user avatar
  • 149
0 votes
3 answers
102 views

How to create a metadata account with python?

Original Question I would like to write a python script that can create tokens. Since the Metaplex Python API seems outdated and only targeted to NFTs, I decided to do it myself. With the help of the (...
KingKevin23's user avatar
1 vote
3 answers
54 views

Do I have to explicitly create a USDC account to be able to receive USDC coins?

I have a Solana (#1) and USDT (#2) adddresses on the same account. I have some USDT coins in it. There's no USDC, though. I've already sent some USDC to the #1 in testnet, from a faucet, but none of ...
Camila326's user avatar
  • 149
1 vote
1 answer
85 views

How to send SPL tokens from a contract in Solang?

I'm trying to use the lever/hand example together with the SPL token example, but I keep getting: Error: failed to send transaction: Transaction simulation failed: Error processing Instruction 0: ...
Jonat Yellow's user avatar
1 vote
1 answer
163 views

Making NFTs (or tokens) soulbound / non-transferable on Solana

So far, I have identified two ways to make uncompressed NFTs non-transferable or soulbound, are there any other ways? And what about compressed NFTs? For uncompressed NFTS with TOKEN_PROGRAM_ID: ...
jonasXchen's user avatar
0 votes
0 answers
39 views

Send SPL-tokens to unfunded account + set fee payer

I'm trying to create a seamless process for my clients via paying for the transaction fees when initiating a tokenswap (token A to token B) via jupiter. In this scenario, the user doesn't have any sol ...
Franny's user avatar
  • 1
1 vote
1 answer
43 views

Creating token accounts using InterfaceAccount

I'm using Anchor 0.28.0 and want to use this new feature that lets you specify which token program to use. It looks very practical because it's used almost the same way as standard SPL accounts but I'...
Dodecahedr0x's user avatar
0 votes
1 answer
76 views

Getting error when I'm going to mint NFT on testnet using Metaplex

Here is my mint contract use anchor_lang::prelude::*; use anchor_lang::solana_program::program::invoke; use anchor_spl::token::mint_to; use anchor_spl::token::{MintTo, Token}; use mpl_token_metadata::...
Isha Padalia's user avatar
3 votes
1 answer
59 views

Error while initializing Account in Solana

I'm new to Solana development and I'm currently trying to initialize an Account using the following code: import { Connection, Keypair, PublicKey, Transaction, SystemProgram, ...
K T's user avatar
  • 33
3 votes
1 answer
42 views

Getting SendTransactionError

I'm getting "SendTransactionError: failed to send transaction: Transaction simulation failed: Error processing Instruction 0: Program failed to complete" Where did i go wrong? const ...
Aru Arshad's user avatar
4 votes
2 answers
142 views

Can I create an ATA of PDA account?

I get this error: "Program ATokenGPvbdGVxr1b2hvZbsiqW5xWH25efTNsLJA8knL invoke [2]", "Program log: Create", "Program TokenkegQfeZyiNwAJbNbGKPFXCWuBvf9Ss623VQ5DA invoke [3]...
Abhishek Faliya's user avatar
0 votes
1 answer
31 views

InstructionError: [ 0, 'ComputationalBudgetExceeded' ] Program failed to complete

//lib.rs code use anchor_lang::prelude::*; pub mod mint; pub mod sell; //pub mod swap; use mint::*; use sell::*; //use swap::*; declare_id!("H5sYvvHMEVSJb2QEwrhCmxGKsMHuntiWz3bmVfxUcBnt")...
Shivam Soni's user avatar
4 votes
1 answer
140 views

custom program error 0x11

I'm trying to transfer NFT using the following code which const transferInstruction = createTransferInstruction( sourceAta, recAta, walletAccount.publicKey, 1, [...
Icus1's user avatar
  • 411
2 votes
0 answers
27 views

Loan Execution using sharkysdk

I was hoping to get some help here we were able to integrate wallet to our platform and we are close to integrating sharky sdk so users can take loans from us, but we had an error in the last step ...
Youssef Massabi's user avatar
2 votes
2 answers
74 views

How to get an SPL Token logo from Mint Address?

So, let's say I have a mint address, take USDC's mint address as an example: EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v How can I now get the logo for that token with just the mint address? => I'...
Morpheus's user avatar
3 votes
1 answer
27 views

Token Rewards Calculation and Distribution

I'm doing a script to calculate rewards for a handful of addresses (from sensors). The script runs weekly where it takes a bunch of addresses from our DB, cleans the data and calculates the associated ...
gritty's user avatar
  • 61
0 votes
1 answer
56 views

How to create the seeds for invoking spl cpi instruction?

I need a program owned token account to hold WSOL. I am creating it like thus #[derive(Accounts)] pub struct InitializeProgramTokenAccount<'...
guccimane's user avatar
1 vote
2 answers
37 views

How to close token accounts using @solana/spl-token v: "0.3.8" and wallet adapter

I'm trying to close token accounts using the wallet adapter,I'm facing the following issues const closeAcc = async (tokenpubkey: PublicKey) => { if (wallet.publicKey) { let tx = new ...
Siddharth's user avatar
2 votes
1 answer
183 views

How to transfer SPL tokens via CPI in Anchor

I'm trying to transfer SPL tokens from a PDA to an user account via CPI but I'm facing "instruction spent from the balance of an account it does not own" error. The PDA is initialized via ...
0xMukesh's user avatar
  • 273
0 votes
1 answer
58 views

Invalid account data on multisig token transfer from nodejs

I have a multisig address with 3 other signers. Not sure if this was created with cli or serum project (the developer that created it is working anymore). When trying to transfer a token, I get this ...
recoverySol's user avatar
5 votes
1 answer
293 views

spl-token-2022 compilation error in anchor build

I am running anchor build and faced into an issue mentioned on Anchor discord. After fixing this issue by adding to dependencies, now I am facing this error even if I do not use spl-token-2022. Here ...
gud's user avatar
  • 365

1
2 3 4 5
7