0

ot error -32603 (Internal Error | Something went wrong within Phantom.)

My Code:

const createAndMintIx = createAndMint(umi, {
      mint,
      authority: umi.identity,
      name: metadata.name,
      symbol: metadata.symbol,
      uri: metadata.uri,
      sellerFeeBasisPoints: percentAmount(0),
      decimals: Number(formData.decimals),
      amount: Number(formData.supply) * 10 ** Number(formData.decimals),
      tokenOwner: umi.identity.publicKey,
      isMutable: !immutable,
      tokenStandard: TokenStandard.Fungible,
    });

const instructions = [
        ...createAndMintIx.getInstructions().map(toWeb3JsInstruction)
      ];

      const messageV0 = new TransactionMessage({
        payerKey: toWeb3JsPublicKey(umi.identity.publicKey),
        recentBlockhash: (await connection.getLatestBlockhash()).blockhash,
        instructions,
      }).compileToV0Message();

      const transactionV0 = new VersionedTransaction(messageV0);

      const res = await provider.signAndSendTransaction(transactionV0);

if (res) {
        return {
          success: true,
          mint: mint.publicKey,
          message: "Token Created",
        };
      } else {
        return {
          success: false,
          message: "Transaction failed",
        };
      }
1
  • can you skip preflight checks and share the tx hash.
    – Jimii
    Commented Oct 27 at 9:59

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.