UNPKG

@dstoken-solana/rwa-token-sdk

Version:

RWA Token SDK for the development of permissioned tokens on SVM blockchains.

55 lines 2.91 kB
import { type PublicKey, type TransactionInstruction } from "@solana/web3.js"; import { type SetupUserArgs } from "../asset-controller"; import { type IxReturn } from "../utils"; import { type AddLevelToIdentityAccountArgs, type RemoveLevelFromIdentityAccountArgs, AttachWalletToIdentityArgs, ChangeCountryArgs, RevokeIdentityAccountArgs } from "../identity-registry"; import { type RwaClient } from "./Client"; /** * Represents the client for Identity Registry for an RWA. */ export declare class IdentityRegistry { private readonly rwaClient; constructor(rwaClient: RwaClient); /** * Asynchronously generates instructions to setup a user. * @param - {@link SetupUserArgs} * @returns A Promise that resolves to the instructions to setup a user. * * It is required for at least a single user to be setup before issuing tokens. */ setupUserIxns(setupUserArgs: SetupUserArgs): Promise<IxReturn>; attachWalletToIdentity(attachWalletArgs: AttachWalletToIdentityArgs): Promise<TransactionInstruction>; detachWalletFromIdentity(detachWalletArgs: AttachWalletToIdentityArgs): Promise<TransactionInstruction>; changeCountry(changeCountryArgs: ChangeCountryArgs): Promise<TransactionInstruction>; /** * Asynchronously update user account identity * @param - {@link AddLevelToIdentityAccountArgs} * @returns A Promise that resolves to the instructions to update user account identity. * */ addIdentityLevelToUserAccount(addLevelArgs: AddLevelToIdentityAccountArgs): Promise<TransactionInstruction>; /** * Asynchronously reduces a user identity account level * @param - {@link RemoveLevelFromIdentityAccount} * @returns A Promise that resolves to the instructions to reduce the level of a user identity account. */ removeIdentityLevelFromUserAccount(removeLevelArgs: RemoveLevelFromIdentityAccountArgs): Promise<TransactionInstruction>; /** * Asynchronously revokes an identity account * @param - {@link RevokeIdentityAccountArgs} * @returns A Promise that resolves to the instructions to revoke an identity account. */ revokeIdentityAccount(revokeIdentityAccountArgs: RevokeIdentityAccountArgs): Promise<TransactionInstruction>; /** * Retrieves the identity registry pda account for a specific asset mint. * @param assetMint - The string representation of the asset's mint address. * @returns The identity registry pda as a public key. */ getIdentityRegistryPda(assetMint: string): PublicKey; /** * Retrieves the identity account pda public key for a specific asset mint. * @param assetMint - The string representation of the asset's mint address. * @param owner - The string representation of the asset's owner. * @returns The identity account pda. */ getIdentityAccountPda(assetMint: string, owner: string): PublicKey; } //# sourceMappingURL=IdentityRegistry.d.ts.map