Skip to content

Instantly share code, notes, and snippets.

@rusintez
Last active June 27, 2024 12:46
Show Gist options
  • Save rusintez/cd5d9d57bcb435dc1147f26920b43ebb to your computer and use it in GitHub Desktop.
Save rusintez/cd5d9d57bcb435dc1147f26920b43ebb to your computer and use it in GitHub Desktop.

Solana Pay Interface

Installation

npm install gist:cd5d9d57bcb435dc1147f26920b43ebb
{
"version": "0.1.1",
"name": "solanapay-ts",
"main": "solanapay.ts"
}
export interface SolanaPaySpecGetResponse {
label: string;
icon: string;
}
export interface SolanaPaySpecPostRequestBody {
account: string; // transaction signer public key
}
export interface SolanaPaySpecPostResponse {
transaction: string; // base64-encoded serialized transaction
message?: string; // the nature of the transaction response e.g. the name of an item being purchased
redirect?: string; // redirect URL after the transaction is successful
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment