import type { NetworkId } from '@iota/iota-sdk/client'; import type { PaginationArguments, IotaClient } from '@iota/iota-sdk/client'; import type { BaseRulePackageIds, TransferPolicyRule } from '../constants.js'; import type { FetchKioskOptions, KioskClientOptions, KioskData, OwnedKiosks } from '../types/index.js'; /** * A Client that allows you to interact with kiosk. * Offers utilities to query kiosk, craft transactions to edit your own kiosk, * purchase, manage transfer policies, create new kiosks etc. * If you pass packageIds, all functionality will be managed using these packages. */ export declare class KioskClient { client: IotaClient; network: NetworkId; rules: TransferPolicyRule[]; packageIds?: BaseRulePackageIds; constructor(options: KioskClientOptions); /** * Get an addresses's owned kiosks. * @param address The address for which we want to retrieve the kiosks. * @param pagination Optional pagination arguments. * @returns An Object containing all the `kioskOwnerCap` objects as well as the kioskIds. */ getOwnedKiosks({ address, pagination, }: { address: string; pagination?: PaginationArguments; }): Promise; /** * Fetches the kiosk contents. * @param id The ID of the kiosk to fetch. * @param options Optional to control the fetch behavior. * @returns */ getKiosk({ id, options, }: { id: string; options?: FetchKioskOptions; }): Promise; /** * Fetch the extension data (if any) for a kiosk, by type * @param kioskId The ID of the kiosk to lookup * @param extensionType The Type of the extension (can be used from by using the type returned by `getKiosk()`) */ getKioskExtension({ kioskId, type }: { kioskId: string; type: string; }): Promise; /** * Query the Transfer Policy(ies) for type `T`. * @param type The Type we're querying for (E.g `0xMyAddress::hero::Hero`) */ getTransferPolicies({ type }: { type: string; }): Promise; /** * Query all the owned transfer policies for an address. * Returns `TransferPolicyCap` which includes `policyId, policyCapId, type`. * @param address The address we're searching the owned transfer policies for. */ getOwnedTransferPolicies({ address }: { address: string; }): Promise; /** * Query the Transfer Policy Cap for type `T`, owned by `address` * @param type The Type `T` for the object * @param address The address that owns the cap. */ getOwnedTransferPoliciesByType({ type, address }: { type: string; address: string; }): Promise; addRuleResolver(rule: TransferPolicyRule): void; /** * A convenient helper to get the packageIds for our supported ruleset, * based on `kioskClient` configuration. */ getRulePackageId(rule: 'kioskLockRulePackageId' | 'royaltyRulePackageId' | 'personalKioskRulePackageId' | 'floorPriceRulePackageId'): string; }