@iota/kiosk
v0.3.0
Published
IOTA Kiosk library
Downloads
124
Readme
Kiosk SDK
@iota/kiosk
is part of the IOTA Rebased SDK, designed specifically for interacting with the IOTA Rebased protocol.
Note: This package is currently supported only in Testnet and Devnet, it is not yet supported in Mainnet.
This Kiosk SDK library provides different utilities to interact/create/manage a Kiosk.
You can read the documentation and see examples by clicking here.
Install
To use the Kiosk SDK in your project, run the following command in your project root:
npm i @iota/kiosk @iota/iota-sdk
To use the Kiosk SDK, you must create a KioskClient instance.
Setup
You can follow this example to create a KioskClient.
import { KioskClient } from '@iota/kiosk';
import { getFullnodeUrl, IotaClient, Network } from '@iota/iota-sdk/client';
// We need a IOTA Client. You can re-use the IotaClient of your project
// (it's not recommended to create a new one).
const client = new IotaClient({ url: getFullnodeUrl(Network.Testnet) });
// Now we can use it to create a kiosk Client.
const kioskClient = new KioskClient({
client,
network: Network.Testnet,
});
You can read the KioskClient documentation to query kiosk data here.