Questions tagged [solana-transaction-instruction]

66 questions
0
votes
1 answer

Token.createAccount vs Token.createInitAccountInstruction vs Token.createTransferInstruction in solana. What is the difference

I am new to solana and exploring the things. I came across these terms SystemProgram.createAccount Token.createInitAccountInstruction Token.createTransferInstruction What is the difference between these three?
0
votes
0 answers

How Can You Create a Solana PDA and then add Data to it?

I have figured out how to create a PDA in the rust contract, but each time I try to serialize the data into the new PDA account, it fails with the following message: WalletSendTransactionError: failed to send transaction: Transaction simulation…
0
votes
1 answer

Retry a transaction on Candy Machine

I am just finishing an upload of 8000 assets to candy machine (via the upload command). Everything seemed to be working well when it was creating the bundles and saving them to the cache, but once it started to write the indices I've started seeing…
0
votes
0 answers

Another way of binding the instructions

I know the most common and recommended way is separate "initialize" and "update" instructions and pack them inside the single transaction in the client-side. However, I am wondering is there any way to achieve the kind of logic on the…
0
votes
1 answer

How can I get the to-address of a transaction from a transaction hash in Solana

I'm trying to get all the information like from-address, to-address, amount, etc in my JS backend to confirm a transaction using it's hash. The transaction object returned from the getTransaction RPC call has a array for owner account…
0
votes
1 answer

Sending SOL using messages in web3/solana

I'm following the Solana docs and trying to send a transaction through message which according to Solana docs is another way to construct a transaction. I have no problem sending the transaction but nowhere I can mention the amount that I want to…
0
votes
0 answers

how to create a transaction to burn SPL tokens in react app?

I wrote a function burnSplToken which takes two inputs: (account(wallet address): string, {account(token address): string, amount: number(token amount)}) I am trying to create a transaction to burn specific amount of tokens. But it's giving me a…
0
votes
1 answer

How to send USDC from solana-cli command line

I am trying to send USDC from the solana-cli command line but I can't find any example in the documentation. Everything is references to how to do it in javascript importing these 2 libraries. import * as web3 from "@solana/web3.js"; import * as…
0
votes
1 answer

Use another Fee Payer for SOLANA spl-token Transfer

I was actually developing a token in SOLANA Blockchain and stuck in a place. The problem is. I need to transfer a custom token ( Eg: MyCustomToken ) I created ( Not SOL ) from one wallet to another and charge the gas fee from another wallet. So the…
0
votes
1 answer

Account vs Block in Blockchain Solana

What is the difference between an Account and a Block in Solana Blockchain technology? As per solana docs, Block: A contiguous set of entries on the ledger covered by a vote. A leader produces at most one block per slot. Account: A record in the…
0
votes
2 answers

How can I return an array of integers from Solana rust program function to front end?

I don't know how can I write a smart contract in Solana that after executing the logic, returns an array of integers, strings, ... to the client, and how can I fetch it using Web3?
0
votes
0 answers

About solana web3 minting Token with phantom wallet

I wanna create a mint token by phantom wallet, here are the code snippet, https://github.com/longmengua/contract-solana/blob/9231643fa85ff115404ad37f07453a3d47e160a1/solana/module/components/index/index.tsx#L88 Before minting a mint token, I need to…
0
votes
1 answer

Solana: ComputeBudget in Typescript SDK

I am currently trying to increase the Compute-Budget on my Solana Program on devnet. I am using solana version 1.9.9. I have checked the anchor discord, and found this implementation to request a larger compute-budget. however, when I run this…
0
votes
2 answers

Interact with solana program directly

I'm trying to use solana-py to interact with a solana program where i don't have documentation about. The program is the Solana Magic Eden NFT Marketplace . I already tried to get information about it from anchor but it has no data available. My…
T.W.
  • 149
  • 2
  • 6
0
votes
1 answer

How to send solana via my app in vanilla js?

Trying to do a simple send and receive function in Solana with vanilla JS. Below is my send function that works fine, and now I want a receive function. Where the provider would get Solana transferred from my treasury wallet. I'm not sure what…