export interface AddressBalance { /** @format address */ address: string; /** @format uint256 */ balance: string; /** @format x.x ALPH */ balanceHint: string; /** @format uint256 */ lockedBalance: string; /** @format x.x ALPH */ lockedBalanceHint: string; warning?: string; } export interface AddressInfo { /** @format address */ address: string; /** @format public-key */ publicKey: string; /** @format group-index */ group: number; path: string; } export interface Addresses { /** @format address */ activeAddress: string; addresses: AddressInfo[]; } export interface AssetInput { outputRef: OutputRef; /** @format hex-string */ unlockScript: string; } export interface AssetOutput { hint: number; /** @format 32-byte-hash */ key: string; /** @format uint256 */ alphAmount: string; /** @format address */ address: string; tokens: Token[]; /** @format int64 */ lockTime: number; /** @format hex-string */ message: string; type: string; } export interface AssetState { /** @format uint256 */ alphAmount: string; tokens?: Token[]; } export interface BadRequest { detail: string; } export interface Balance { /** @format uint256 */ balance: string; /** @format x.x ALPH */ balanceHint: string; /** @format uint256 */ lockedBalance: string; /** @format x.x ALPH */ lockedBalanceHint: string; utxoNum: number; warning?: string; } export interface Balances { /** @format uint256 */ totalBalance: string; /** @format x.x ALPH */ totalBalanceHint: string; balances: AddressBalance[]; } export interface Ban { peers: string[]; type: string; } export interface Banned { /** @format int64 */ until: number; type: string; } export interface BlockEntry { /** @format block-hash */ hash: string; /** @format int64 */ timestamp: number; chainFrom: number; chainTo: number; height: number; deps: string[]; transactions: Transaction[]; /** @format hex-string */ nonce: string; version: number; /** @format 32-byte-hash */ depStateHash: string; /** @format 32-byte-hash */ txsHash: string; /** @format hex-string */ target: string; } export interface BlockHeaderEntry { /** @format block-hash */ hash: string; /** @format int64 */ timestamp: number; chainFrom: number; chainTo: number; height: number; deps: string[]; } export interface BrokerInfo { /** @format clique-id */ cliqueId: string; brokerId: number; brokerNum: number; /** @format inet-socket-address */ address: string; } export interface BuildDeployContractTx { /** @format public-key */ fromPublicKey: string; /** @format hex-string */ bytecode: string; /** @format uint256 */ initialAlphAmount?: string; initialTokenAmounts?: Token[]; /** @format uint256 */ issueTokenAmount?: string; /** @format gas */ gasAmount?: number; /** @format uint256 */ gasPrice?: string; } export interface BuildDeployContractTxResult { fromGroup: number; toGroup: number; unsignedTx: string; /** @format gas */ gasAmount: number; /** @format uint256 */ gasPrice: string; /** @format 32-byte-hash */ txId: string; /** @format address */ contractAddress: string; } export interface BuildExecuteScriptTx { /** @format public-key */ fromPublicKey: string; /** @format hex-string */ bytecode: string; /** @format uint256 */ alphAmount?: string; tokens?: Token[]; /** @format gas */ gasAmount?: number; /** @format uint256 */ gasPrice?: string; } export interface BuildExecuteScriptTxResult { fromGroup: number; toGroup: number; unsignedTx: string; /** @format gas */ gasAmount: number; /** @format uint256 */ gasPrice: string; /** @format 32-byte-hash */ txId: string; } export interface BuildInfo { releaseVersion: string; commit: string; } export interface BuildMultisig { /** @format address */ fromAddress: string; fromPublicKeys: string[]; destinations: Destination[]; /** @format gas */ gas?: number; /** @format uint256 */ gasPrice?: string; } export interface BuildMultisigAddress { keys: string[]; mrequired: number; } export interface BuildMultisigAddressResult { /** @format address */ address: string; } export interface BuildSweepAddressTransactions { /** @format public-key */ fromPublicKey: string; /** @format address */ toAddress: string; /** @format int64 */ lockTime?: number; /** @format gas */ gasAmount?: number; /** @format uint256 */ gasPrice?: string; } export interface BuildSweepAddressTransactionsResult { unsignedTxs: SweepAddressTransaction[]; fromGroup: number; toGroup: number; } export interface BuildTransaction { /** @format public-key */ fromPublicKey: string; destinations: Destination[]; utxos?: OutputRef[]; /** @format gas */ gasAmount?: number; /** @format uint256 */ gasPrice?: string; } export interface BuildTransactionResult { unsignedTx: string; /** @format gas */ gasAmount: number; /** @format uint256 */ gasPrice: string; /** @format 32-byte-hash */ txId: string; fromGroup: number; toGroup: number; } export interface CallContract { group: number; /** @format block-hash */ worldStateBlockHash?: string; /** @format 32-byte-hash */ txId?: string; /** @format address */ address: string; methodIndex: number; args?: Val[]; existingContracts?: string[]; inputAssets?: TestInputAsset[]; } export interface CallContractResult { returns: Val[]; gasUsed: number; contracts: ContractState[]; txInputs: string[]; txOutputs: Output[]; events: ContractEventByTxId[]; } export interface ChainInfo { currentHeight: number; } export interface ChainParams { networkId: number; numZerosAtLeastInHash: number; groupNumPerBroker: number; groups: number; } export interface ChangeActiveAddress { /** @format address */ address: string; } export interface CompileContractResult { bytecode: string; /** @format 32-byte-hash */ codeHash: string; fields: FieldsSig; functions: FunctionSig[]; events: EventSig[]; } export interface CompileScriptResult { bytecodeTemplate: string; fields: FieldsSig; functions: FunctionSig[]; } export interface Confirmed { /** @format block-hash */ blockHash: string; txIndex: number; chainConfirmations: number; fromGroupConfirmations: number; toGroupConfirmations: number; type: string; } export interface Contract { code: string; } export interface ContractEvent { /** @format block-hash */ blockHash: string; /** @format 32-byte-hash */ txId: string; eventIndex: number; fields: Val[]; } export interface ContractEventByTxId { /** @format block-hash */ blockHash: string; /** @format address */ contractAddress: string; eventIndex: number; fields: Val[]; } export interface ContractEvents { events: ContractEvent[]; nextStart: number; } export interface ContractEventsByTxId { events: ContractEventByTxId[]; nextStart: number; } export interface ContractOutput { hint: number; /** @format 32-byte-hash */ key: string; /** @format uint256 */ alphAmount: string; /** @format address */ address: string; tokens: Token[]; type: string; } export interface ContractState { /** @format address */ address: string; /** @format contract */ bytecode: string; /** @format 32-byte-hash */ codeHash: string; /** @format 32-byte-hash */ initialStateHash?: string; fields: Val[]; asset: AssetState; } export interface DecodeUnsignedTx { unsignedTx: string; } export interface DecodeUnsignedTxResult { fromGroup: number; toGroup: number; unsignedTx: UnsignedTx; } export interface Destination { /** @format address */ address: string; /** @format uint256 */ alphAmount: string; tokens?: Token[]; /** @format int64 */ lockTime?: number; /** @format hex-string */ message?: string; } export declare type DiscoveryAction = Reachable | Unreachable; export interface EventSig { name: string; signature: string; fieldNames: string[]; fieldTypes: string[]; } export interface FetchResponse { blocks: BlockEntry[][]; } export interface FieldsSig { signature: string; names: string[]; types: string[]; } export interface FixedAssetOutput { hint: number; /** @format 32-byte-hash */ key: string; /** @format uint256 */ alphAmount: string; /** @format address */ address: string; tokens: Token[]; /** @format int64 */ lockTime: number; /** @format hex-string */ message: string; } export interface FunctionSig { name: string; signature: string; argNames: string[]; argTypes: string[]; returnTypes: string[]; } export interface Group { group: number; } export interface HashesAtHeight { headers: string[]; } export interface InterCliquePeerInfo { /** @format clique-id */ cliqueId: string; brokerId: number; groupNumPerBroker: number; /** @format inet-socket-address */ address: string; isSynced: boolean; clientVersion: string; } export interface InternalServerError { detail: string; } export interface MemPooled { type: string; } export interface MinerAddresses { addresses: string[]; } export interface MinerAddressesInfo { addresses: AddressInfo[]; } export declare type MisbehaviorAction = Ban | Unban; export interface NodeInfo { buildInfo: BuildInfo; upnp: boolean; /** @format inet-socket-address */ externalAddress?: string; } export interface NodeVersion { version: ReleaseVersion; } export interface NotFound { detail: string; resource: string; } export declare type Output = AssetOutput | ContractOutput; export interface OutputRef { hint: number; /** @format 32-byte-hash */ key: string; } export interface PeerAddress { /** @format inet-address */ address: string; restPort: number; wsPort: number; minerApiPort: number; } export interface PeerMisbehavior { /** @format inet-address */ peer: string; status: PeerStatus; } export declare type PeerStatus = Banned | Penalty; export interface Penalty { value: number; type: string; } export interface Reachable { peers: string[]; type: string; } export interface ReleaseVersion { major: number; minor: number; patch: number; } export interface RevealMnemonic { password: string; } export interface RevealMnemonicResult { mnemonic: string; } export interface Script { code: string; } export interface SelfClique { /** @format clique-id */ cliqueId: string; nodes: PeerAddress[]; selfReady: boolean; synced: boolean; } export interface ServiceUnavailable { detail: string; } export interface Sign { data: string; } export interface SignResult { /** @format signature */ signature: string; } export interface SubmitMultisig { unsignedTx: string; signatures: string[]; } export interface SubmitTransaction { unsignedTx: string; /** @format signature */ signature: string; } export interface SubmitTxResult { /** @format 32-byte-hash */ txId: string; fromGroup: number; toGroup: number; } export interface Sweep { /** @format address */ toAddress: string; /** @format int64 */ lockTime?: number; /** @format gas */ gasAmount?: number; /** @format uint256 */ gasPrice?: string; utxosLimit?: number; } export interface SweepAddressTransaction { /** @format 32-byte-hash */ txId: string; unsignedTx: string; /** @format gas */ gasAmount: number; /** @format uint256 */ gasPrice: string; } export interface TestContract { group?: number; /** @format block-hash */ blockHash?: string; /** @format 32-byte-hash */ txId?: string; /** @format address */ address?: string; /** @format contract */ bytecode: string; initialFields?: Val[]; initialAsset?: AssetState; methodIndex?: number; args?: Val[]; existingContracts?: ContractState[]; inputAssets?: TestInputAsset[]; } export interface TestContractResult { /** @format address */ address: string; /** @format 32-byte-hash */ codeHash: string; returns: Val[]; gasUsed: number; contracts: ContractState[]; txInputs: string[]; txOutputs: Output[]; events: ContractEventByTxId[]; } export interface TestInputAsset { /** @format address */ address: string; asset: AssetState; } export interface Token { /** @format 32-byte-hash */ id: string; /** @format uint256 */ amount: string; } export interface Transaction { unsigned: UnsignedTx; scriptExecutionOk: boolean; contractInputs: OutputRef[]; generatedOutputs: Output[]; inputSignatures: string[]; scriptSignatures: string[]; } export interface TransactionTemplate { unsigned: UnsignedTx; inputSignatures: string[]; scriptSignatures: string[]; } export interface Transfer { destinations: Destination[]; /** @format gas */ gas?: number; /** @format uint256 */ gasPrice?: string; utxosLimit?: number; } export interface TransferResult { /** @format 32-byte-hash */ txId: string; /** @format group-index */ fromGroup: number; /** @format group-index */ toGroup: number; } export interface TransferResults { results: TransferResult[]; } export interface TxNotFound { type: string; } export declare type TxStatus = Confirmed | MemPooled | TxNotFound; export interface UTXO { ref: OutputRef; /** @format uint256 */ amount: string; tokens: Token[]; /** @format int64 */ lockTime: number; /** @format hex-string */ additionalData: string; } export interface UTXOs { utxos: UTXO[]; warning?: string; } export interface Unauthorized { detail: string; } export interface Unban { peers: string[]; type: string; } export interface UnconfirmedTransactions { fromGroup: number; toGroup: number; unconfirmedTransactions: TransactionTemplate[]; } export interface Unreachable { peers: string[]; type: string; } export interface UnsignedTx { /** @format 32-byte-hash */ txId: string; version: number; networkId: number; /** @format script */ scriptOpt?: string; gasAmount: number; /** @format uint256 */ gasPrice: string; inputs: AssetInput[]; fixedOutputs: FixedAssetOutput[]; } export declare type Val = ValAddress | ValArray | ValBool | ValByteVec | ValI256 | ValU256; export interface ValAddress { /** @format address */ value: string; type: string; } export interface ValArray { value: Val[]; type: string; } export interface ValBool { value: boolean; type: string; } export interface ValByteVec { /** @format hex-string */ value: string; type: string; } export interface ValI256 { value: string; type: string; } export interface ValU256 { /** @format uint256 */ value: string; type: string; } export interface VerifySignature { /** @format hex-string */ data: string; /** @format signature */ signature: string; /** @format public-key */ publicKey: string; } export interface WalletCreation { password: string; walletName: string; isMiner?: boolean; mnemonicPassphrase?: string; mnemonicSize?: number; } export interface WalletCreationResult { walletName: string; mnemonic: string; } export interface WalletDeletion { password: string; } export interface WalletRestore { password: string; mnemonic: string; walletName: string; isMiner?: boolean; mnemonicPassphrase?: string; } export interface WalletRestoreResult { walletName: string; } export interface WalletStatus { walletName: string; locked: boolean; } export interface WalletUnlock { password: string; mnemonicPassphrase?: string; } import fetch from 'cross-fetch'; export declare type QueryParamsType = Record; export declare type ResponseFormat = keyof Omit; export interface FullRequestParams extends Omit { /** set parameter to `true` for call `securityWorker` for this request */ secure?: boolean; /** request path */ path: string; /** content type of request body */ type?: ContentType; /** query params */ query?: QueryParamsType; /** format of response (i.e. response.json() -> format: "json") */ format?: ResponseFormat; /** request body */ body?: unknown; /** base url */ baseUrl?: string; /** request cancellation token */ cancelToken?: CancelToken; } export declare type RequestParams = Omit; export interface ApiConfig { baseUrl?: string; baseApiParams?: Omit; securityWorker?: (securityData: SecurityDataType | null) => Promise | RequestParams | void; customFetch?: typeof fetch; } export interface HttpResponse extends Response { data: D; error: E; } declare type CancelToken = Symbol | string | number; export declare enum ContentType { Json = "application/json", FormData = "multipart/form-data", UrlEncoded = "application/x-www-form-urlencoded" } export declare class HttpClient { baseUrl: string; private securityData; private securityWorker?; private abortControllers; private customFetch; private baseApiParams; constructor(apiConfig?: ApiConfig); setSecurityData: (data: SecurityDataType | null) => void; private encodeQueryParam; private addQueryParam; private addArrayQueryParam; protected toQueryString(rawQuery?: QueryParamsType): string; protected addQueryParams(rawQuery?: QueryParamsType): string; private contentFormatters; private mergeRequestParams; private createAbortSignal; abortRequest: (cancelToken: CancelToken) => void; request: ({ body, secure, path, type, query, format, baseUrl, cancelToken, ...params }: FullRequestParams) => Promise>; } /** * @title Alephium API * @version 1.4.0 * @baseUrl {protocol}://{host}:{port} */ export declare class Api extends HttpClient { wallets: { /** * No description * * @tags Wallets * @name GetWallets * @summary List available wallets * @request GET:/wallets */ getWallets: (params?: RequestParams) => Promise; /** * No description * * @tags Wallets * @name PutWallets * @summary Restore a wallet from your mnemonic * @request PUT:/wallets */ putWallets: (data: WalletRestore, params?: RequestParams) => Promise; /** * @description A new wallet will be created and respond with a mnemonic. Make sure to keep that mnemonic safely as it will allows you to recover your wallet. Default mnemonic size is 24, (options: 12, 15, 18, 21, 24). * * @tags Wallets * @name PostWallets * @summary Create a new wallet * @request POST:/wallets */ postWallets: (data: WalletCreation, params?: RequestParams) => Promise; /** * No description * * @tags Wallets * @name GetWalletsWalletName * @summary Get wallet's status * @request GET:/wallets/{wallet_name} */ getWalletsWalletName: (walletName: string, params?: RequestParams) => Promise; /** * No description * * @tags Wallets * @name DeleteWalletsWalletName * @summary Delete your wallet file (can be recovered with your mnemonic) * @request DELETE:/wallets/{wallet_name} */ deleteWalletsWalletName: (walletName: string, data: WalletDeletion, params?: RequestParams) => Promise; /** * No description * * @tags Wallets * @name PostWalletsWalletNameLock * @summary Lock your wallet * @request POST:/wallets/{wallet_name}/lock */ postWalletsWalletNameLock: (walletName: string, params?: RequestParams) => Promise; /** * No description * * @tags Wallets * @name PostWalletsWalletNameUnlock * @summary Unlock your wallet * @request POST:/wallets/{wallet_name}/unlock */ postWalletsWalletNameUnlock: (walletName: string, data: WalletUnlock, params?: RequestParams) => Promise; /** * No description * * @tags Wallets * @name GetWalletsWalletNameBalances * @summary Get your total balance * @request GET:/wallets/{wallet_name}/balances */ getWalletsWalletNameBalances: (walletName: string, params?: RequestParams) => Promise; /** * No description * * @tags Wallets * @name PostWalletsWalletNameRevealMnemonic * @summary Reveal your mnemonic. !!! use it with caution !!! * @request POST:/wallets/{wallet_name}/reveal-mnemonic */ postWalletsWalletNameRevealMnemonic: (walletName: string, data: RevealMnemonic, params?: RequestParams) => Promise; /** * No description * * @tags Wallets * @name PostWalletsWalletNameTransfer * @summary Transfer ALPH from the active address * @request POST:/wallets/{wallet_name}/transfer */ postWalletsWalletNameTransfer: (walletName: string, data: Transfer, params?: RequestParams) => Promise; /** * No description * * @tags Wallets * @name PostWalletsWalletNameSweepActiveAddress * @summary Transfer all unlocked ALPH from the active address to another address * @request POST:/wallets/{wallet_name}/sweep-active-address */ postWalletsWalletNameSweepActiveAddress: (walletName: string, data: Sweep, params?: RequestParams) => Promise; /** * No description * * @tags Wallets * @name PostWalletsWalletNameSweepAllAddresses * @summary Transfer unlocked ALPH from all addresses (including all mining addresses if applicable) to another address * @request POST:/wallets/{wallet_name}/sweep-all-addresses */ postWalletsWalletNameSweepAllAddresses: (walletName: string, data: Sweep, params?: RequestParams) => Promise; /** * No description * * @tags Wallets * @name PostWalletsWalletNameSign * @summary Sign the given data and return back the signature * @request POST:/wallets/{wallet_name}/sign */ postWalletsWalletNameSign: (walletName: string, data: Sign, params?: RequestParams) => Promise; /** * No description * * @tags Wallets * @name GetWalletsWalletNameAddresses * @summary List all your wallet's addresses * @request GET:/wallets/{wallet_name}/addresses */ getWalletsWalletNameAddresses: (walletName: string, params?: RequestParams) => Promise; /** * No description * * @tags Wallets * @name GetWalletsWalletNameAddressesAddress * @summary Get address' info * @request GET:/wallets/{wallet_name}/addresses/{address} */ getWalletsWalletNameAddressesAddress: (walletName: string, address: string, params?: RequestParams) => Promise; /** * @description This endpoint can only be called if the wallet was created with the `isMiner = true` flag * * @tags Miners * @name GetWalletsWalletNameMinerAddresses * @summary List all miner addresses per group * @request GET:/wallets/{wallet_name}/miner-addresses */ getWalletsWalletNameMinerAddresses: (walletName: string, params?: RequestParams) => Promise; /** * @description Cannot be called from a miner wallet * * @tags Wallets * @name PostWalletsWalletNameDeriveNextAddress * @summary Derive your next address * @request POST:/wallets/{wallet_name}/derive-next-address */ postWalletsWalletNameDeriveNextAddress: (walletName: string, query?: { group?: number | undefined; } | undefined, params?: RequestParams) => Promise; /** * @description Your wallet need to have been created with the miner flag set to true * * @tags Miners * @name PostWalletsWalletNameDeriveNextMinerAddresses * @summary Derive your next miner addresses for each group * @request POST:/wallets/{wallet_name}/derive-next-miner-addresses */ postWalletsWalletNameDeriveNextMinerAddresses: (walletName: string, params?: RequestParams) => Promise; /** * No description * * @tags Wallets * @name PostWalletsWalletNameChangeActiveAddress * @summary Choose the active address * @request POST:/wallets/{wallet_name}/change-active-address */ postWalletsWalletNameChangeActiveAddress: (walletName: string, data: ChangeActiveAddress, params?: RequestParams) => Promise; }; infos: { /** * No description * * @tags Infos * @name GetInfosNode * @summary Get info about that node * @request GET:/infos/node */ getInfosNode: (params?: RequestParams) => Promise; /** * No description * * @tags Infos * @name GetInfosVersion * @summary Get version about that node * @request GET:/infos/version */ getInfosVersion: (params?: RequestParams) => Promise; /** * No description * * @tags Infos * @name GetInfosChainParams * @summary Get key params about your blockchain * @request GET:/infos/chain-params */ getInfosChainParams: (params?: RequestParams) => Promise; /** * No description * * @tags Infos * @name GetInfosSelfClique * @summary Get info about your own clique * @request GET:/infos/self-clique */ getInfosSelfClique: (params?: RequestParams) => Promise; /** * No description * * @tags Infos * @name GetInfosInterCliquePeerInfo * @summary Get infos about the inter cliques * @request GET:/infos/inter-clique-peer-info */ getInfosInterCliquePeerInfo: (params?: RequestParams) => Promise; /** * No description * * @tags Infos * @name GetInfosDiscoveredNeighbors * @summary Get discovered neighbors * @request GET:/infos/discovered-neighbors */ getInfosDiscoveredNeighbors: (params?: RequestParams) => Promise; /** * No description * * @tags Infos * @name GetInfosMisbehaviors * @summary Get the misbehaviors of peers * @request GET:/infos/misbehaviors */ getInfosMisbehaviors: (params?: RequestParams) => Promise; /** * No description * * @tags Infos * @name PostInfosMisbehaviors * @summary Ban/Unban given peers * @request POST:/infos/misbehaviors */ postInfosMisbehaviors: (data: MisbehaviorAction, params?: RequestParams) => Promise; /** * No description * * @tags Infos * @name GetInfosUnreachable * @summary Get the unreachable brokers * @request GET:/infos/unreachable */ getInfosUnreachable: (params?: RequestParams) => Promise; /** * No description * * @tags Infos * @name PostInfosDiscovery * @summary Set brokers to be unreachable/reachable * @request POST:/infos/discovery */ postInfosDiscovery: (data: DiscoveryAction, params?: RequestParams) => Promise; /** * No description * * @tags Infos * @name GetInfosHistoryHashrate * @summary Get history average hashrate on the given time interval * @request GET:/infos/history-hashrate */ getInfosHistoryHashrate: (query: { fromTs: number; toTs?: number; }, params?: RequestParams) => Promise; /** * No description * * @tags Infos * @name GetInfosCurrentHashrate * @summary Get average hashrate from `now - timespan(millis)` to `now` * @request GET:/infos/current-hashrate */ getInfosCurrentHashrate: (query?: { timespan?: number | undefined; } | undefined, params?: RequestParams) => Promise; }; blockflow: { /** * No description * * @tags Blockflow * @name GetBlockflow * @summary List blocks on the given time interval * @request GET:/blockflow */ getBlockflow: (query: { fromTs: number; toTs?: number; }, params?: RequestParams) => Promise; /** * No description * * @tags Blockflow * @name GetBlockflowBlocksBlockHash * @summary Get a block with hash * @request GET:/blockflow/blocks/{block_hash} */ getBlockflowBlocksBlockHash: (blockHash: string, params?: RequestParams) => Promise; /** * No description * * @tags Blockflow * @name GetBlockflowIsBlockInMainChain * @summary Check if the block is in main chain * @request GET:/blockflow/is-block-in-main-chain */ getBlockflowIsBlockInMainChain: (query: { blockHash: string; }, params?: RequestParams) => Promise; /** * No description * * @tags Blockflow * @name GetBlockflowHashes * @summary Get all block's hashes at given height for given groups * @request GET:/blockflow/hashes */ getBlockflowHashes: (query: { fromGroup: number; toGroup: number; height: number; }, params?: RequestParams) => Promise; /** * No description * * @tags Blockflow * @name GetBlockflowChainInfo * @summary Get infos about the chain from the given groups * @request GET:/blockflow/chain-info */ getBlockflowChainInfo: (query: { fromGroup: number; toGroup: number; }, params?: RequestParams) => Promise; /** * No description * * @tags Blockflow * @name GetBlockflowHeadersBlockHash * @summary Get block header * @request GET:/blockflow/headers/{block_hash} */ getBlockflowHeadersBlockHash: (blockHash: string, params?: RequestParams) => Promise; }; addresses: { /** * No description * * @tags Addresses * @name GetAddressesAddressBalance * @summary Get the balance of an address * @request GET:/addresses/{address}/balance */ getAddressesAddressBalance: (address: string, params?: RequestParams) => Promise; /** * No description * * @tags Addresses * @name GetAddressesAddressUtxos * @summary Get the UTXOs of an address * @request GET:/addresses/{address}/utxos */ getAddressesAddressUtxos: (address: string, params?: RequestParams) => Promise; /** * No description * * @tags Addresses * @name GetAddressesAddressGroup * @summary Get the group of an address * @request GET:/addresses/{address}/group */ getAddressesAddressGroup: (address: string, params?: RequestParams) => Promise; }; transactions: { /** * No description * * @tags Transactions * @name GetTransactionsUnconfirmed * @summary List unconfirmed transactions * @request GET:/transactions/unconfirmed */ getTransactionsUnconfirmed: (params?: RequestParams) => Promise; /** * No description * * @tags Transactions * @name PostTransactionsBuild * @summary Build an unsigned transaction to a number of recipients * @request POST:/transactions/build */ postTransactionsBuild: (data: BuildTransaction, params?: RequestParams) => Promise; /** * No description * * @tags Transactions * @name PostTransactionsSweepAddressBuild * @summary Build unsigned transactions to send all unlocked balanced of one address to another address * @request POST:/transactions/sweep-address/build */ postTransactionsSweepAddressBuild: (data: BuildSweepAddressTransactions, params?: RequestParams) => Promise; /** * No description * * @tags Transactions * @name PostTransactionsSubmit * @summary Submit a signed transaction * @request POST:/transactions/submit */ postTransactionsSubmit: (data: SubmitTransaction, params?: RequestParams) => Promise; /** * No description * * @tags Transactions * @name PostTransactionsDecodeUnsignedTx * @summary Decode an unsigned transaction * @request POST:/transactions/decode-unsigned-tx */ postTransactionsDecodeUnsignedTx: (data: DecodeUnsignedTx, params?: RequestParams) => Promise; /** * No description * * @tags Transactions * @name GetTransactionsStatus * @summary Get tx status * @request GET:/transactions/status */ getTransactionsStatus: (query: { txId: string; fromGroup?: number; toGroup?: number; }, params?: RequestParams) => Promise; }; contracts: { /** * No description * * @tags Contracts * @name PostContractsCompileScript * @summary Compile a script * @request POST:/contracts/compile-script */ postContractsCompileScript: (data: Script, params?: RequestParams) => Promise; /** * No description * * @tags Contracts * @name PostContractsUnsignedTxExecuteScript * @summary Build an unsigned script * @request POST:/contracts/unsigned-tx/execute-script */ postContractsUnsignedTxExecuteScript: (data: BuildExecuteScriptTx, params?: RequestParams) => Promise; /** * No description * * @tags Contracts * @name PostContractsCompileContract * @summary Compile a smart contract * @request POST:/contracts/compile-contract */ postContractsCompileContract: (data: Contract, params?: RequestParams) => Promise; /** * No description * * @tags Contracts * @name PostContractsUnsignedTxDeployContract * @summary Build an unsigned contract * @request POST:/contracts/unsigned-tx/deploy-contract */ postContractsUnsignedTxDeployContract: (data: BuildDeployContractTx, params?: RequestParams) => Promise; /** * No description * * @tags Contracts * @name GetContractsAddressState * @summary Get contract state * @request GET:/contracts/{address}/state */ getContractsAddressState: (address: string, query: { group: number; }, params?: RequestParams) => Promise; /** * No description * * @tags Contracts * @name PostContractsTestContract * @summary Test contract * @request POST:/contracts/test-contract */ postContractsTestContract: (data: TestContract, params?: RequestParams) => Promise; /** * No description * * @tags Contracts * @name PostContractsCallContract * @summary Call contract * @request POST:/contracts/call-contract */ postContractsCallContract: (data: CallContract, params?: RequestParams) => Promise; }; multisig: { /** * No description * * @tags Multi-signature * @name PostMultisigAddress * @summary Create the multisig address and unlock script * @request POST:/multisig/address */ postMultisigAddress: (data: BuildMultisigAddress, params?: RequestParams) => Promise; /** * No description * * @tags Multi-signature * @name PostMultisigBuild * @summary Build a multisig unsigned transaction * @request POST:/multisig/build */ postMultisigBuild: (data: BuildMultisig, params?: RequestParams) => Promise; /** * No description * * @tags Multi-signature * @name PostMultisigSubmit * @summary Submit a multi-signed transaction * @request POST:/multisig/submit */ postMultisigSubmit: (data: SubmitMultisig, params?: RequestParams) => Promise; }; utils: { /** * No description * * @tags Utils * @name PostUtilsVerifySignature * @summary Verify the SecP256K1 signature of some data * @request POST:/utils/verify-signature */ postUtilsVerifySignature: (data: VerifySignature, params?: RequestParams) => Promise; /** * No description * * @tags Utils * @name PutUtilsCheckHashIndexing * @summary Check and repair the indexing of block hashes * @request PUT:/utils/check-hash-indexing */ putUtilsCheckHashIndexing: (params?: RequestParams) => Promise; }; miners: { /** * No description * * @tags Miners * @name PostMinersCpuMining * @summary Execute an action on CPU miner. !!! for test only !!! * @request POST:/miners/cpu-mining */ postMinersCpuMining: (query: { action: string; }, params?: RequestParams) => Promise; /** * No description * * @tags Miners * @name GetMinersAddresses * @summary List miner's addresses * @request GET:/miners/addresses */ getMinersAddresses: (params?: RequestParams) => Promise; /** * No description * * @tags Miners * @name PutMinersAddresses * @summary Update miner's addresses, but better to use user.conf instead * @request PUT:/miners/addresses */ putMinersAddresses: (data: MinerAddresses, params?: RequestParams) => Promise; }; events: { /** * No description * * @tags Events * @name GetEventsContractContractaddress * @summary Get events for a contract within a counter range * @request GET:/events/contract/{contractAddress} */ getEventsContractContractaddress: (contractAddress: string, query: { start: number; end?: number; group?: number; }, params?: RequestParams) => Promise; /** * No description * * @tags Events * @name GetEventsContractContractaddressCurrentCount * @summary Get current value of the events counter for a contract * @request GET:/events/contract/{contractAddress}/current-count */ getEventsContractContractaddressCurrentCount: (contractAddress: string, params?: RequestParams) => Promise; /** * No description * * @tags Events * @name GetEventsTxIdTxid * @summary Get events for a TxScript * @request GET:/events/tx-id/{txId} */ getEventsTxIdTxid: (txId: string, query?: { group?: number | undefined; } | undefined, params?: RequestParams) => Promise; }; } export {};