import { AddressString , AttributeTypeModel , Hash256String , NetworkType , PublicKeyString } from '@neo-one/client-common' ; /**
 * Information about the provider of a Dapi
 */ export interface DapiProvider { /**
     * Name of the `DapiProvider`.
     */ readonly name : string ; /**
     * Website of the `DapiProvider`.
     */ readonly website : string ; /**
     * Version of the `DapiProvider`.
     */ readonly version : string ; example readonly compatibility : readonly string [ ] ; /**
     * This object can contain any attributes specific to the `DapiProvider`, such as an app theme.
     */ readonly extra : object ; } /**
 * Networks the `DapiProvider` has available to connect to, along with the default network.
 */ export interface DapiNetworks { /**
     * Networks the `DapiProvider` has available to connect to.
     */ readonly networks : readonly NetworkType [ ] ; /**
     * Default network of the `DapiProvider`.
     */ readonly defaultNetwork : NetworkType ; } /**
 * An account provided by a `DapiProvider`.
 */ export interface DapiAccount { /**
     * `AddressString` of the connected account
     */ readonly address : AddressString ; /**
     * A label the user has set to identify their wallet.
     */ readonly label ? : string ; } /**
 * A public key associated with a `DapiAccount`.
 */ export interface DapiPublicKey { /**
     * `AddressString` of the connected account
     */ readonly address : AddressString ; /**
     * `PublicKeyString` for the associated `AddressString`.
     */ readonly publicKey : PublicKeyString ; } /**
 * Options for `invokeRead`.
 */ export interface InvokeReadArgs { /**
     * script hash of the smart contract to invoke a read on
     */ readonly scriptHash : string ; /**
     * operation on the smart contract to call
     */ readonly operation : string ; /**
     * any input arguments for the operation
     */ readonly args : readonly Argument [ ] ; /**
     * Network to submit this request to. If omitted, will default to network the wallet is currently set to.
     */ readonly network ? : string ; } /**
 * Allowed types for invocation parameters.
 */ export type ArgumentDataType = 'String' | 'Boolean' | 'Hash160' | 'Hash256' | 'Integer' | 'ByteArray' | 'Array' | 'Address' ; /**
 * Definition of a single invocation parameter.
 */ export interface Argument { /**
     * Type of the parameter.
     */ readonly type : ArgumentDataType ; /**
     * Value of the parameter.
     */ readonly value : any ; } /**
 * Options for invoking a transfer of an `Asset`.
 */ export interface SendArgs { /**
     * `AddressString` of the connected account to send the `Asset`s from.
     */ readonly fromAddress : AddressString ; /**
     * `AddressString` of the receiver of the `Asset`s to be sent.
     */ readonly toAddress : string ; /**
     * `Asset` script hash to be sent.
     */ readonly asset : Hash256String ; /**
     * The parsed amount of the `Asset` to be sent.
     */ readonly amount : string ; /**
     * Description of the transaction to be made.
     */ readonly remark ? : string ; /**
     * The parsed amount of network fee (in GAS) to include with transaction.
     */ readonly fee ? : string ; /**
     * `NetworkType` to submit this request to. If omitted, will default to network the wallet is currently set to..
     */ readonly network ? : NetworkType ; /**
     * In the case that the dApp would like to be responsible for broadcasting the signed transaction rather than the wallet provider.
     */ readonly broadcastOverride ? : boolean ; } /**
 * NEO and GAS attached to an invocation.
 */ export interface AttachedAssets { /**
     * NEO attached to an invocation.
     */ readonly NEO ? : string ; /**
     * GAS attached to an invocation.
     */ readonly GAS ? : string ; } /**
 * Hash `Attribute` attached to a transaction.
 * TODO: removed `extends Argument` but kept `Argument` definition, as it may be
 * needed after Preview 3 when they add back transaction attributes
 */ export interface TxHashAttribute { /**
     * Allowed `Attribute` types.
     */ readonly txAttrType : AttributeTypeModel ; } /**
 * Options for invoking a write method.
 */ export interface InvokeArgs extends InvokeReadArgs { /**
     * NEO and GAS attached to this invocation.
     */ readonly attachedAssets ? : AttachedAssets ; /**
     * The parsed amount of network fee (in GAS) to include with transaction.
     */ readonly fee ? : string ; /**
     * Adds the instruction to invoke the contract verification trigger.
     */ readonly triggerContractVerification ? : boolean ; /**
     * Adds transaction attributes.
     */ readonly txHashAttributes ? : readonly TxHashAttribute [ ] ; } /**
 * `Input` defining the origin of an `Asset`.
 */ export interface AssetInput { /**
     * Hash of the `Transaction` this input references.
     */ readonly txid : string ; /**
     * `Output` index within the `Transaction` this input references.
     */ readonly index : number ; } /**
 * `Output`s represent the destination `Address` and amount transferred of a given `Asset`.
 */ export interface AssetOutput { /**
     * Hash of the `Asset` that was transferred.
     */ readonly asset : Hash256String ; /**
     * Destination `AddressString`.
     */ readonly address : AddressString ; /**
     * Amount transferred.
     */ readonly value : string ; } /**
 * Result of a write method for the `DapiProvider`.
 */ export interface WriteResult { /**
     * Hash of the `Transaction`.
     */ readonly txid : string ; /**
     * The node which the `Transaction` was broadcast to. Returned if `Transaction` is broadcast by wallet provider.
     */ readonly nodeUrl : string ; } export const ACCOUNT_CHANGED = 'ACCOUNT_CHANGED' ; export const NETWORK_CHANGED = 'NETWORK_CHANGED' ; /**
 *
 */ export type Event = 'READY' | typeof ACCOUNT_CHANGED | typeof NETWORK_CHANGED | 'DISCONNECTED' | 'BLOCK_HEIGHT_CHANGED' | 'TRANSACTION_CONFIRMED' ; export interface DapiError { readonly type : `NO_PROVIDER` | `CONNECTION_DENIED` ; readonly description : string ; readonly data : string ; } /**
 * a common API interface for dApps to communicate with external wallet providers.
 */ export interface Dapi { /**
     * Returns information about the `DapiProvider`, including who this provider is, the version of their dAPI, and the NEP that the interface is compatible with.
     */ /**
     * Returns the networks the wallet provider has available to connect to, along with the default network the wallet is currently set to.
     */ readonly getNetworks : ( ) => Promise < DapiNetworks > ; /**
     * Return the `DapiAccount` that is currently connected to the dApp.
     */ readonly getAccount : ( ) => Promise < DapiAccount > ; /**
     * Return the public key of the `DapiAccount` that is currently connected to the dApp.
     */ readonly getPublicKey : ( ) => Promise < DapiPublicKey > ; /**
     * Return balance of a specific asset for the given account. If the asset is omited from a request to MainNet, all asset and token balances will be returned.
     */ /**
     * Reads the raw value in smart contract storage.
     */ /**
     * Execute a contract invocation in read-only mode.
     */ /**
     * Returns whether the provided signature data matches the provided message and was signed by the account of the provided public key. unused.
     */ /**
     * Get information about a specific block. unused.
     */ /**
     * Get information about a specific transaction. unused.
     */ /**
     * Get the application log for a given transaction. unused.
     */ /**
     * Invoke a transfer of a specified amount of a given asset from the connected account to another account.
     */ readonly send : ( args : SendArgs ) => Promise < WriteResult > ; /**
     * Execute a contract invocation.
     */ readonly invoke : ( args : InvokeArgs ) => Promise < WriteResult > ; /**
     * Signs a provided messaged with an account selected by user. A randomized salt prefix is added to the input string before it is signed, and it is encased in a non-executable transaction before signed. This ensures allow compatibility with Ledger devices. unused.
     */ /**
     * Will deploy a compiled smart contract to the blockchain with the provided input parameters. The GAS cost for deploying the contract will be calculated by the provider, and displayed to the user upon tx acceptance or rejection. unused.
     */ /**
     * dApps can listen for events emitted by the wallet provider using the `addEventListener` method.
     */ readonly addEventListener : ( event : Event , callback : ( ... args : any ) => void ) => void ; /**
     * Removes any callback listeners previously set for a given event.
     */ readonly removeEventListener : ( event : Event ) => void ; } /**
 * Unused Dapi interfaces
 */