UNPKG

@tatumio/tatum-v1

Version:

Tatum API client allows browsers and Node.js clients to interact with Tatum API.

115 lines (114 loc) 6.24 kB
/// <reference types="node" /> import { AddMinter, CeloBurnErc721, CeloDeployErc721, CeloMintErc721, CeloMintMultipleErc721, CeloTransferErc721, CeloUpdateCashbackErc721, Currency, DeployErc721, EthBurnErc721, EthDeployErc721, EthMintErc721, EthMintMultipleErc721, EthTransferErc721, FlowBurnNft, FlowDeployNft, FlowMintMultipleNft, FlowMintNft, FlowTransferNft, OneMint721, TransactionHash, TransferAlgoNft, TronBurnTrc721, TronDeployTrc721, TronMintTrc721, TronTransferTrc721, TronUpdateCashbackTrc721, UpdateCashbackErc721 } from '../model'; export declare const mintNFT: (body: CeloMintErc721 | EthMintErc721 | OneMint721) => Promise<TransactionHash>; /** * For more details, see <a href="https://apidoc.tatum.io/#operation/NftGetBalanceErc721" target="_blank">Tatum API documentation</a> */ export declare const getNFTsByAddress: (chain: Currency, contractAddress: string, address: string) => Promise<string[]>; /** * For more details, see <a href="https://apidoc.tatum.io/#operation/NftProvenanceReadData" target="_blank">Tatum API documentation</a> */ export declare const getNFTProvenanceData: (chain: Currency, contractAddress: string, tokenId: string) => Promise<any>; /** * For more details, see <a href="https://apidoc.tatum.io/#operation/NftGetContractAddress" target="_blank">Tatum API documentation</a> */ export declare const getNFTContractAddress: (chain: Currency, txId: string) => Promise<{ contractAddress: string; }>; /** * For more details, see <a href="https://apidoc.tatum.io/#operation/NftGetMetadataErc721" target="_blank">Tatum API documentation</a> */ export declare const getNFTMetadataURI: (chain: Currency, contractAddress: string, tokenId: string, account?: string | undefined) => Promise<{ data: string; }>; /** * Get IPFS image URL from the NFT with the IPFS Metadata scheme. URL * @param chain chain where NFT token is * @param contractAddress contract address of the NFT token * @param tokenId ID of the token * @param account FLOW only - account where the token is minted */ export declare const getNFTImage: (chain: Currency, contractAddress: string, tokenId: string, account?: string | undefined) => Promise<{ originalUrl: string; publicUrl: string; }>; /** * For more details, see <a href="https://apidoc.tatum.io/#operation/NftGetRoyaltyErc721" target="_blank">Tatum API documentation</a> */ export declare const getNFTRoyalty: (chain: Currency, contractAddress: string, tokenId: string) => Promise<{ data: string; }>; /** * Deploy new NFT smart contract, which will be used for later minting. * @param testnet if we use testnet or not * @param body body of the mint request * @param provider optional provider do broadcast tx */ export declare const deployNFT: (testnet: boolean, body: CeloDeployErc721 | EthDeployErc721 | TronDeployTrc721 | FlowDeployNft | DeployErc721, provider?: string | undefined) => Promise<TransactionHash>; /** * Mint new NFT token with metadata stored on the IPFS. * @param testnet if we use testnet or not * @param body body of the mint request * @param file file to be stored on the IPFS * @param name name of the file * @param description description of the file * @param scheme optional JSON Metadata scheme * @param provider optional provider do broadcast tx */ export declare const createNFT: (testnet: boolean, body: CeloMintErc721 | EthMintErc721 | TronMintTrc721 | FlowMintNft, file: Buffer, name: string, description?: string | undefined, scheme?: any, provider?: string | undefined) => Promise<{ metadataUrl: string; metadataPublicUrl: string; imageUrl: string; imagePublicUrl: string; txId: string; tokenId: any; }>; /** * Mint new NFT token. * @param testnet if we use testnet or not * @param body body of the mint request * @param provider optional provider do broadcast tx */ export declare const mintNFTWithUri: (testnet: boolean, body: CeloMintErc721 | EthMintErc721 | TronMintTrc721 | FlowMintNft, provider?: string | undefined) => Promise<TransactionHash>; /** * Mint multiple new NFT tokens. * @param testnet if we use testnet or not * @param body body of the mint request * @param provider optional provider do broadcast tx */ export declare const mintMultipleNFTWithUri: (testnet: boolean, body: CeloMintMultipleErc721 | EthMintMultipleErc721 | FlowMintMultipleNft, provider?: string | undefined) => Promise<TransactionHash>; /** * Burn new NFT token. Token will no longer exists. * @param testnet if we use testnet or not * @param body body of the mint request * @param provider optional provider do broadcast tx */ export declare const burnNFT: (testnet: boolean, body: CeloBurnErc721 | EthBurnErc721 | TronBurnTrc721 | FlowBurnNft, provider?: string | undefined) => Promise<TransactionHash>; /** * Update royalty cashback as author of the NFT token. * @param testnet if we use testnet or not * @param body body of the mint request * @param provider optional provider do broadcast tx */ export declare const updateCashbackForAuthorNFT: (testnet: boolean, body: UpdateCashbackErc721 | TronUpdateCashbackTrc721 | CeloUpdateCashbackErc721, provider?: string | undefined) => Promise<TransactionHash>; /** * Transfer new NFT token to new recipient. * @param testnet if we use testnet or not * @param body body of the mint request * @param provider optional provider do broadcast tx */ export declare const transferNFT: (testnet: boolean, body: CeloTransferErc721 | EthTransferErc721 | TronTransferTrc721 | FlowTransferNft | TransferAlgoNft, provider?: string | undefined) => Promise<TransactionHash>; /** * Prepare add new minter to the NFT contract transaction. * @param testnet if we use testnet or not * @param body body of the add minter request * @param provider optional provider do broadcast tx */ export declare const prepareAddNFTMinter: (testnet: boolean, body: AddMinter, provider?: string | undefined) => Promise<string>; /** * Add new minter to the NFT contract. * @param testnet if we use testnet or not * @param body body of the add minter request * @param provider optional provider do broadcast tx */ export declare const sendAddNFTMinter: (testnet: boolean, body: AddMinter, provider?: string | undefined) => Promise<unknown>;