@silvana-one/abi
Version:
Silvana ABI Experimental Library
80 lines (79 loc) • 2.83 kB
TypeScript
import { IndexedMapSerialized } from "@silvana-one/storage";
import { NftTransactionType, NftTransactionParams, LaunchNftCollectionStandardAdminParams, LaunchNftCollectionAdvancedAdminParams, NftMintTransactionParams } from "@silvana-one/api";
import { blockchain } from "../types.js";
import { PublicKey, Transaction } from "o1js";
export type NftAdminType = "standard" | "advanced" | "unknown";
export declare function buildNftCollectionLaunchTransaction(params: {
chain: blockchain;
args: LaunchNftCollectionStandardAdminParams | LaunchNftCollectionAdvancedAdminParams;
developerAddress?: string;
provingKey?: string;
provingFee?: number;
}): Promise<{
request: LaunchNftCollectionStandardAdminParams | LaunchNftCollectionAdvancedAdminParams;
tx: Transaction<false, false>;
adminType: NftAdminType;
collectionName: string;
nftName: string;
verificationKeyHashes: string[];
metadataRoot: string;
storage: string;
privateMetadata?: string;
map?: IndexedMapSerialized;
}>;
export declare function buildNftTransaction(params: {
chain: blockchain;
args: Exclude<NftTransactionParams, LaunchNftCollectionStandardAdminParams | LaunchNftCollectionAdvancedAdminParams | NftMintTransactionParams>;
developerAddress?: string;
provingKey?: string;
provingFee?: number;
}): Promise<{
request: Exclude<NftTransactionParams, LaunchNftCollectionStandardAdminParams | LaunchNftCollectionAdvancedAdminParams | NftMintTransactionParams>;
tx: Transaction<false, false>;
adminType: NftAdminType;
adminContractAddress: PublicKey;
symbol: string;
collectionName: string;
nftName: string;
verificationKeyHashes: string[];
metadataRoot: string;
storage: string;
privateMetadata?: string;
map?: IndexedMapSerialized;
}>;
export declare function buildNftMintTransaction(params: {
chain: blockchain;
args: NftMintTransactionParams;
developerAddress?: string;
provingKey?: string;
provingFee?: number;
}): Promise<{
request: NftMintTransactionParams;
tx: Transaction<false, false>;
adminType: NftAdminType;
adminContractAddress: PublicKey;
symbol: string;
collectionName: string;
nftName: string;
verificationKeyHashes: string[];
metadataRoot: string;
storage: string;
privateMetadata?: string;
map?: IndexedMapSerialized;
}>;
export declare function getNftSymbolAndAdmin(params: {
txType: NftTransactionType;
nftAddress?: PublicKey;
collectionAddress: PublicKey;
chain: blockchain;
}): Promise<{
adminContractAddress: PublicKey;
symbol: string;
collectionName: string;
adminType: NftAdminType;
verificationKeyHashes: string[];
nftName?: string;
storage?: string;
approved?: PublicKey;
metadataRoot?: string;
}>;