UNPKG

textiot

Version:

A framework for building web and native (IoT) Dapps on the IPFS network

85 lines (84 loc) 3.24 kB
import { ISummary, IMobileWalletAccount } from './model'; import * as account from './account'; import * as cafes from './cafes'; import * as comments from './comments'; import * as contacts from './contacts'; import * as feed from './feed'; import * as files from './files'; import * as flags from './flags'; import * as ignores from './ignores'; import * as invites from './invites'; import * as ipfs from './ipfs'; import * as likes from './likes'; import * as logs from './logs'; import * as messages from './messages'; import * as notifications from './notifications'; import * as profile from './profile'; import * as schemas from './schemas'; import * as threads from './threads'; import * as events from './events'; import * as util from './util'; /** * Create a new Textile wallet * @param wordCount The number of words the wallet recovery phrase should contain * @returns The new wallet recovery phrase Promise */ export declare function newWallet(wordCount: number): Promise<string>; /** * Resolve a wallet account * @param phrase The wallet recovery phrase * @param index The index of the account to resolve * @param password The optional wallet password * @returns The wallet account Promise */ export declare function walletAccountAt(phrase: string, index: number, password?: string): Promise<IMobileWalletAccount>; /** * Check if Textile is already initialized * @param repoPath The path to the Textile repo * @returns A boolean Promise value indicating if Textile is initialized or not */ export declare function isInitialized(repoPath: string): Promise<boolean>; /** * Initialize the shared Textile instance with an existing account seed * @param repoPath The path to the Textile repo * @param seed The account seed * @param debug Sets the log level to debug or not * @param logToDisk Whether or not to write Textile logs to disk */ export declare function initialize(repoPath: string, seed: string, debug: boolean, logToDisk: boolean): Promise<void>; /** * Initialize the shared Textile instance, creating a new wallet * @param repoPath The path to the Textile repo * @param debug Sets the log level to debug or not * @param logToDisk Whether or not to write Textile logs to disk * @returns The wallet recovery phrase Promise */ export declare function initializeCreatingNewWalletAndAccount(repoPath: string, debug: boolean, logToDisk: boolean): Promise<string>; /** * After initialization is complete, launch Textile * @param repoPath The path to the Textile repo * @param debug Sets the log level to debug or not */ export declare function launch(repoPath: string, debug: boolean): Promise<void>; /** * Get the Textile node version * ```typescript * Textile.version(); * ``` */ export declare function version(): Promise<string>; /** * Get the latest git summary * ```typescript * Textile.gitSummary(); * ``` */ export declare function gitSummary(): Promise<string>; /** * Get the summary of node data * ```typescript * Textile.summary(); * ``` */ export declare function summary(): Promise<ISummary>; export { account, cafes, comments, contacts, feed, files, flags, ignores, invites, ipfs, likes, logs, messages, notifications, profile, schemas, threads, events, util };