import * as web3 from "@solana/web3.js"; import { Honeycomb, HoneycombProject, Operation } from "@honeycomb-protocol/hive-control"; import { CreateCurrencyArgs } from "../generated"; /** * Represents the arguments for creating a "Create Currency" operation. * @category Types */ type CreateCurrencyArgsPack = (CreateCurrencyArgs & { useMint?: web3.Keypair; }) | { mint: web3.PublicKey; mintAuthority: web3.Keypair | web3.PublicKey; freezeAuthority: web3.Keypair | web3.PublicKey; }; /** * Represents the arguments for creating a "Create Currency" operation. * @category Types */ type CreateCreateCurrencyOperationArgs = { args: CreateCurrencyArgsPack; project: HoneycombProject; programId?: web3.PublicKey; }; /** * Creates a "Create Currency" operation for the given project and arguments, either * wrapping an existing mint or creating a new currency with a new mint. * @category Operation Builders * @param honeycomb The Honeycomb instance. * @param args The arguments for creating the "Create Currency" operation. * @returns An object containing the "Create Currency" operation and the currency address. * @example * const honeycomb = new Honeycomb(...); // Initialize Honeycomb instance * const project = ...; // HoneycombProject instance * const mintPublicKey = ...; // Mint public key for wrapping an existing currency * const createCurrencyArgs = { * name: "My Token", * symbol: "MTK", * decimals: 6, * kind: CurrencyKind.Token, * permissions: { * mint: [mintAuthorityPublicKey], * freeze: [], * admin: [adminPublicKey], * tokenOwner: [], * }, * }; * * // Create a "Create Currency" operation * const operationArgs: CreateCreateCurrencyOperationArgs = { * args: mintPublicKey ? { mint: mintPublicKey } : createCurrencyArgs, * project, * }; * const { operation } = await createCreateCurrencyOperation(honeycomb, operationArgs); * operation.send(); */ export declare function createCreateCurrencyOperation(honeycomb: Honeycomb, args: CreateCreateCurrencyOperationArgs): Promise<{ operation: Operation; currency: web3.PublicKey; }>; export {};