crystara-sdk
Version:
Official SDK for Crystara NFT Marketplace
42 lines (41 loc) • 1.39 kB
TypeScript
export type Item = {
id: number;
token_id: string;
name: string;
description: string;
rarity: string;
image: string;
supply: number;
maxSupply: number;
};
export type Token = {
id: number;
tokenName: string;
tokenUri: string;
rarityName: string;
rarityWeight: number;
circulatingSupply: number;
maxSupply: number;
cachedUri: any;
};
export default function BlindBoxPage({ params, fetchMetadata, fetchLootboxStats, batchFetchMetadata, fetchLootboxInfo, fetchWhitelistAmount, }: {
params: {
lootboxUrl: string;
contractAddress: string;
contractModuleName: string;
supraRPCUrl: string;
apiUrl?: string | "test";
viewerAddress?: string;
sounds?: {
tick?: string;
open?: string;
win?: string;
error?: string;
};
};
fetchMetadata: (url: string) => Promise<any>;
fetchLootboxStats: (url: string, viewer?: string) => Promise<any>;
batchFetchMetadata: (urls: string[], bustCache?: boolean) => Promise<any>;
fetchLootboxInfo: (lootboxCreatorAddress: string, collectionName: string, viewerAddress: string | null) => Promise<any>;
fetchWhitelistAmount: (lootboxCreatorAddress: string, collectionName: string, currentAddress: string) => Promise<any>;
}): import("react/jsx-runtime").JSX.Element;