From 465eac709ad28bdee4fb8203eb2f846ea698fef4 Mon Sep 17 00:00:00 2001 From: aresastro Date: Wed, 10 May 2023 08:36:19 +0800 Subject: [PATCH] added imports --- ts/cluster1/spl_mint.ts | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/ts/cluster1/spl_mint.ts b/ts/cluster1/spl_mint.ts index e69de29..0c0df5f 100644 --- a/ts/cluster1/spl_mint.ts +++ b/ts/cluster1/spl_mint.ts @@ -0,0 +1,24 @@ +import { Keypair, PublicKey, Connection, Commitment } from "@solana/web3.js"; +import { getOrCreateAssociatedTokenAccount, mintTo } from '@solana/spl-token'; +import wallet from "../wba-wallet.json" + +// Import our keypair from the wallet file +const keypair = Keypair.fromSecretKey(new Uint8Array(wallet)); + +//Create a Solana devnet connection +const commitment: Commitment = "confirmed"; +const connection = new Connection("https://api.devnet.solana.com", commitment); + +const token_decimals = 1_000_000n; + + +// Mint address +const mint = new PublicKey(""); + +(async () => { + try { + // Start here + } catch(error) { + console.log(`Oops, something went wrong: ${error}`) + } +})() \ No newline at end of file