@goequitize/rwa-token-sdk
Version:
SDK for creating and managing RWA token transactions with compliance features
44 lines (43 loc) • 2.03 kB
TypeScript
import { ethers } from 'ethers';
import { UnsignedTransaction, MintParams, BurnParams } from '../types';
/**
* Module for handling token-related operations
*/
export declare class TokenModule {
private provider;
private chainId;
/**
* Create a new instance of the TokenModule
* @param provider The JSON-RPC provider instance
* @param chainId The chain ID of the connected network
*/
constructor(provider: ethers.JsonRpcProvider, chainId: number);
/**
* Create an unsigned transaction for minting tokens
* @param params The parameters for the mint operation
* @returns An unsigned transaction object that can be sent to a wallet for signing
*/
createMintTransaction(params: MintParams): Promise<UnsignedTransaction>;
/**
* Create an unsigned transaction for burning tokens
* @param params The parameters for the burn operation
* @returns An unsigned transaction object that can be sent to a wallet for signing
*/
createBurnTransaction(params: BurnParams): Promise<UnsignedTransaction>;
/**
* Create an unsigned transaction for approving another address to spend tokens
* @param contractAddress The address of the token contract
* @param spender The address being approved to spend tokens
* @param amount The amount of tokens to approve
* @returns An unsigned transaction object that can be sent to a wallet for signing
*/
createApproveTransaction(contractAddress: string, spender: string, amount: string): Promise<UnsignedTransaction>;
/**
* Create an unsigned transaction for transferring tokens
* @param contractAddress The address of the token contract
* @param recipient The address to receive the tokens
* @param amount The amount of tokens to transfer
* @returns An unsigned transaction object that can be sent to a wallet for signing
*/
createTransferTransaction(contractAddress: string, recipient: string, amount: string): Promise<UnsignedTransaction>;
}