transferTransaction

طلب JSON-RPC

{
"jsonrpc": "2.0",
"id": 1,
"method": "transferTransaction",
"params": {
"amount": 1000000,
"token": "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v",
"source": "sourcePublicKey",
"destination": "destinationPublicKey"
}
}

استجابة JSON-RPC

{
"jsonrpc": "2.0",
"id": 1,
"result": {
"blockhash": "base58Blockhash",
"instructions": "exampleValue",
"message": "exampleValue",
"signer_pubkey": "3Z1Ef7YaxK8oUMoi6exf7wYZjZKWJJsrzJXSt1c3qrDE",
"transaction": "base64EncodedTransaction"
}
}

مثال cURL

curl -X POST http://localhost:8080 \
-H "Content-Type: application/json" \
-d '{"jsonrpc":"2.0","id":1,"method":"transferTransaction","params":{"amount":1000000,"token":"EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v","source":"sourcePublicKey","destination":"destinationPublicKey"}}'

TypeScript SDK

const transfer = await client.transferTransaction({
amount: 1000000, // 1 USDC (6 decimals)
token: "EPjFWdd5AufqSSqeM2qN1xzybapC8G4wEGGkZwyTDt1v",
source: "sourceWalletPublicKey",
destination: "destinationWalletPublicKey"
});
console.log("Transaction:", transfer.transaction);
console.log("Message:", transfer.message);
console.log("Instructions:", transfer.instructions);

Is this page helpful?

جدول المحتويات

تعديل الصفحة

تدار بواسطة

© 2026 مؤسسة سولانا.
جميع الحقوق محفوظة.
تواصل معنا