Constructors
constructor
- new AtellixClient(provider, apiUrl): AtellixClient
-
Parameters
-
provider: AnchorProvider
-
apiUrl: undefined | string
Methods
associatedTokenAddress
- associatedTokenAddress(walletAddress, tokenMintAddress): Promise<{
nonce: number;
pubkey: string;
}>
-
Parameters
-
walletAddress: PublicKey
-
tokenMintAddress: PublicKey
Returns Promise<{
nonce: number;
pubkey: string;
}>
checkout
- checkout(payments, walletPK, paymentToken): Promise<CheckoutResult>
-
Parameters
-
-
walletPK: PublicKey
-
paymentToken: string
getAdminToken
- getAdminToken(tokenType, apiKey): Promise<AdminTokenResult>
-
Parameters
-
tokenType: string
-
apiKey: string
getLamports
- getLamports(walletPK): Promise<number>
-
Returns Promise<number>
getOrder
- getOrder(orderUuid): Promise<any>
-
Returns Promise<any>
getPaymentTokens
- getPaymentTokens(): Promise<any>
-
Returns Promise<any>
getTokenBalance
- getTokenBalance(mintPK, walletPK): Promise<string>
-
Parameters
-
mintPK: PublicKey
-
walletPK: PublicKey
Returns Promise<string>
getTokenBalances
- getTokenBalances(tokens, walletPK): Promise<{
[key: string]: string;
}>
-
Parameters
-
tokens: string[]
-
walletPK: PublicKey
Returns Promise<{
[key: string]: string;
}>
getVendureClient
- getVendureClient(apiKey): Promise<VendureClient>
-
hasTokenAccount
- hasTokenAccount(ataPK): Promise<boolean>
-
Returns Promise<boolean>
merchantCheckout
- merchantCheckout(params, walletPK): Promise<CheckoutResult>
-
programAddress
- programAddress(inputs, program): Promise<{
nonce: number;
pubkey: string;
}>
-
Parameters
-
inputs: any[]
-
program: PublicKey
Returns Promise<{
nonce: number;
pubkey: string;
}>
registerSignature
- registerSignature(sig, orderUuid, pubkey): Promise<boolean>
-
Parameters
-
sig: string
-
orderUuid: string
-
pubkey: string
Returns Promise<boolean>
sendAndConfirmRawTransaction
- sendAndConfirmRawTransaction(connection, rawTransaction, options?): Promise<string>
-
Parameters
-
connection: Connection
-
rawTransaction: Uint8Array | Buffer
-
Optional
options: ConfirmOptions
Returns Promise<string>
sendRegistered
- sendRegistered(tx, register, signers): Promise<string>
-
Parameters
-
tx: Transaction
-
register: ((sig) => Promise<boolean>)
-
- (sig): Promise<boolean>
-
Returns Promise<boolean>
-
signers: Signer[]
Returns Promise<string>
updateNetData
- updateNetData(data): void
-
Returns void
updateOrderData
- updateOrderData(data): void
-
Returns void
updateSwapData
- updateSwapData(data): void
-
Returns void
updateTokenData
- updateTokenData(data): void
-
Returns void