verze-app / solana-php-sdk

Simple PHP SDK for Solana JSON RPC endpoints
MIT License
88 stars 45 forks source link

Example of transaction #28

Open keyserjaya opened 2 years ago

keyserjaya commented 2 years ago

Ready to use ;)

mattstauffer commented 2 years ago

Hey @keyserjaya! Is this meant to be documentation about how to use the tool? If so, maybe we should put it into either the readme, or in a folder dedicated to examples?

iamnotaprogrammer98 commented 2 years ago

$fromPublicKey = KeyPair::fromSecretKey(SecretKeyToKeypair('YourSecretKey'));

I have a question, the 'YourSecretKey' will be the payer's or receiver's secret key?

keyserjaya commented 2 years ago

Is this meant to be documentation about how to use the tool?

yep.

maybe we should put it into either the readme, or in a folder dedicated to examples?

Let's do both, i don't mind ^^

*ps: this example is for giving player reward (server send sol to player)

keyserjaya commented 2 years ago

$fromPublicKey = KeyPair::fromSecretKey(SecretKeyToKeypair('YourSecretKey'));

I have a question, the 'YourSecretKey' will be the payer's or receiver's secret key?

it's payer secret key

mattstauffer commented 2 years ago

maybe we should put it into either the readme, or in a folder dedicated to examples?

Let's do both, i don't mind ^^

Sounds good; please feel free to update this PR moving this to a docs folder and then mentioning it in the readme.

impozzible commented 2 years ago

Hi, please is there an example on how to transfer custom token?

neverything commented 2 years ago

Related to #48