DefaultService
Constructors
new DefaultService()
new DefaultService(
httpRequest
):DefaultService
Parameters
• httpRequest: BaseHttpRequest
Returns
Defined in
services.gen.ts:8
Properties
httpRequest
readonly
httpRequest:BaseHttpRequest
Defined in
services.gen.ts:8
Methods
createWallet()
createWallet(
data
):CancelablePromise
<APIV1POSTWalletResponse
>
Create a wallet Create a new wallet (collection of keys) with the given parameters.
Parameters
• data: CreateWalletData
The data for the request.
Returns
CancelablePromise
<APIV1POSTWalletResponse
>
APIV1POSTWalletResponse Response to POST /v1/wallet
Throws
ApiError
Defined in
services.gen.ts:268
deleteKey()
deleteKey(
data
):CancelablePromise
<APIV1DELETEKeyResponse
>
Delete a key Deletes the key with the passed public key from the wallet.
Parameters
• data: DeleteKeyData
The data for the request.
Returns
CancelablePromise
<APIV1DELETEKeyResponse
>
APIV1DELETEKeyResponse Response to DELETE /v1/key
Throws
ApiError
Defined in
services.gen.ts:51
deleteMultisig()
deleteMultisig(
data
):CancelablePromise
<APIV1DELETEMultisigResponse
>
Delete a multisig Deletes multisig preimage information for the passed address from the wallet.
Parameters
• data: DeleteMultisigData
The data for the request.
Returns
CancelablePromise
<APIV1DELETEMultisigResponse
>
APIV1DELETEMultisigResponse Response to POST /v1/multisig/delete
Throws
ApiError
Defined in
services.gen.ts:134
exportKey()
exportKey(
data
):CancelablePromise
<APIV1POSTKeyExportResponse
>
Export a key Export the secret key associated with the passed public key.
Parameters
• data: ExportKeyData
The data for the request.
Returns
CancelablePromise
<APIV1POSTKeyExportResponse
>
APIV1POSTKeyExportResponse Response to POST /v1/key/export
Throws
ApiError
Defined in
services.gen.ts:67
exportMasterKey()
exportMasterKey(
data
):CancelablePromise
<APIV1POSTMasterKeyExportResponse
>
Export the master derivation key from a wallet
Export the master derivation key from the wallet. This key is a master “backup” key for the underlying wallet. With it, you can regenerate all of the wallets that have been generated with this wallet’s POST /v1/key
endpoint. This key will not allow you to recover keys imported from other wallets, however.
Parameters
• data: ExportMasterKeyData
The data for the request.
Returns
CancelablePromise
<APIV1POSTMasterKeyExportResponse
>
APIV1POSTMasterKeyExportResponse Response to POST /v1/master-key/export
Throws
ApiError
Defined in
services.gen.ts:117
exportMultisig()
exportMultisig(
data
):CancelablePromise
<APIV1POSTMultisigExportResponse
>
Export multisig address metadata Given a multisig address whose preimage this wallet stores, returns the information used to generate the address, including public keys, threshold, and multisig version.
Parameters
• data: ExportMultisigData
The data for the request.
Returns
CancelablePromise
<APIV1POSTMultisigExportResponse
>
APIV1POSTMultisigExportResponse Response to POST /v1/multisig/export
Throws
ApiError
Defined in
services.gen.ts:151
generateKey()
generateKey(
data
):CancelablePromise
<APIV1POSTKeyResponse
>
Generate a key Generates the next key in the deterministic key sequence (as determined by the master derivation key) and adds it to the wallet, returning the public key.
Parameters
• data: GenerateKeyData
The data for the request.
Returns
CancelablePromise
<APIV1POSTKeyResponse
>
APIV1POSTKeyResponse Response to POST /v1/key
Throws
ApiError
Defined in
services.gen.ts:35
getVersion()
getVersion(
data
):CancelablePromise
<VersionsResponse
>
Retrieves the current version
Parameters
• data: GetVersionData
= {}
The data for the request.
Returns
CancelablePromise
<VersionsResponse
>
VersionsResponse Response to GET /versions
Throws
ApiError
Defined in
services.gen.ts:381
getWalletInfo()
getWalletInfo(
data
):CancelablePromise
<APIV1POSTWalletInfoResponse
>
Get wallet info Returns information about the wallet associated with the passed wallet handle token. Additionally returns expiration information about the token itself.
Parameters
• data: GetWalletInfoData
The data for the request.
Returns
CancelablePromise
<APIV1POSTWalletInfoResponse
>
APIV1POSTWalletInfoResponse Response to POST /v1/wallet/info
Throws
ApiError
Defined in
services.gen.ts:285
importKey()
importKey(
data
):CancelablePromise
<APIV1POSTKeyImportResponse
>
Import a key Import an externally generated key into the wallet. Note that if you wish to back up the imported key, you must do so by backing up the entire wallet database, because imported keys were not derived from the wallet’s master derivation key.
Parameters
• data: ImportKeyData
The data for the request.
Returns
CancelablePromise
<APIV1POSTKeyImportResponse
>
APIV1POSTKeyImportResponse Response to POST /v1/key/import
Throws
ApiError
Defined in
services.gen.ts:84
importMultisig()
importMultisig(
data
):CancelablePromise
<APIV1POSTMultisigImportResponse
>
Import a multisig account Generates a multisig account from the passed public keys array and multisig metadata, and stores all of this in the wallet.
Parameters
• data: ImportMultisigData
The data for the request.
Returns
CancelablePromise
<APIV1POSTMultisigImportResponse
>
APIV1POSTMultisigImportResponse Response to POST /v1/multisig/import
Throws
ApiError
Defined in
services.gen.ts:168
initWalletHandleToken()
initWalletHandleToken(
data
):CancelablePromise
<APIV1POSTWalletInitResponse
>
Initialize a wallet handle token
Unlock the wallet and return a wallet handle token that can be used for subsequent operations. These tokens expire periodically and must be renewed. You can POST
the token to /v1/wallet/info
to see how much time remains until expiration, and renew it with /v1/wallet/renew
. When you’re done, you can invalidate the token with /v1/wallet/release
.
Parameters
• data: InitWalletHandleTokenData
The data for the request.
Returns
CancelablePromise
<APIV1POSTWalletInitResponse
>
APIV1POSTWalletInitResponse Response to POST /v1/wallet/init
Throws
ApiError
Defined in
services.gen.ts:302
listKeysInWallet()
listKeysInWallet(
data
):CancelablePromise
<APIV1POSTKeyListResponse
>
List keys in wallet Lists all of the public keys in this wallet. All of them have a stored private key.
Parameters
• data: ListKeysInWalletData
The data for the request.
Returns
CancelablePromise
<APIV1POSTKeyListResponse
>
APIV1POSTKeyListResponse Response to POST /v1/key/list
Throws
ApiError
Defined in
services.gen.ts:100
listMultisg()
listMultisg(
data
):CancelablePromise
<APIV1POSTMultisigListResponse
>
List multisig accounts Lists all of the multisig accounts whose preimages this wallet stores
Parameters
• data: ListMultisgData
The data for the request.
Returns
CancelablePromise
<APIV1POSTMultisigListResponse
>
APIV1POSTMultisigListResponse Response to POST /v1/multisig/list
Throws
ApiError
Defined in
services.gen.ts:184
listWallets()
listWallets(
data
):CancelablePromise
<APIV1GETWalletsResponse
>
List wallets Lists all of the wallets that kmd is aware of.
Parameters
• data: ListWalletsData
= {}
The data for the request.
Returns
CancelablePromise
<APIV1GETWalletsResponse
>
APIV1GETWalletsResponse Response to GET /v1/wallets
Throws
ApiError
Defined in
services.gen.ts:366
releaseWalletHandleToken()
releaseWalletHandleToken(
data
):CancelablePromise
<APIV1POSTWalletReleaseResponse
>
Release a wallet handle token Invalidate the passed wallet handle token, making it invalid for use in subsequent requests.
Parameters
• data: ReleaseWalletHandleTokenData
The data for the request.
Returns
CancelablePromise
<APIV1POSTWalletReleaseResponse
>
APIV1POSTWalletReleaseResponse Response to POST /v1/wallet/release
Throws
ApiError
Defined in
services.gen.ts:318
renameWallet()
renameWallet(
data
):CancelablePromise
<APIV1POSTWalletRenameResponse
>
Rename a wallet Rename the underlying wallet to something else
Parameters
• data: RenameWalletData
The data for the request.
Returns
CancelablePromise
<APIV1POSTWalletRenameResponse
>
APIV1POSTWalletRenameResponse Response to POST /v1/wallet/rename
Throws
ApiError
Defined in
services.gen.ts:334
renewWalletHandleToken()
renewWalletHandleToken(
data
):CancelablePromise
<APIV1POSTWalletRenewResponse
>
Renew a wallet handle token Renew a wallet handle token, increasing its expiration duration to its initial value
Parameters
• data: RenewWalletHandleTokenData
The data for the request.
Returns
CancelablePromise
<APIV1POSTWalletRenewResponse
>
APIV1POSTWalletRenewResponse Response POST /v1/wallet/renew
Throws
ApiError
Defined in
services.gen.ts:350
signMultisigProgram()
signMultisigProgram(
data
):CancelablePromise
<APIV1POSTMultisigProgramSignResponse
>
Sign a program for a multisig account Start a multisig signature, or add a signature to a partially completed multisig signature object.
Parameters
• data: SignMultisigProgramData
The data for the request.
Returns
CancelablePromise
<APIV1POSTMultisigProgramSignResponse
>
APIV1POSTMultisigProgramSignResponse Response to POST /v1/multisig/signdata
Throws
ApiError
Defined in
services.gen.ts:218
signMultisigTransaction()
signMultisigTransaction(
data
):CancelablePromise
<APIV1POSTMultisigTransactionSignResponse
>
Sign a multisig transaction Start a multisig signature, or add a signature to a partially completed multisig signature object.
Parameters
• data: SignMultisigTransactionData
The data for the request.
Returns
CancelablePromise
<APIV1POSTMultisigTransactionSignResponse
>
APIV1POSTMultisigTransactionSignResponse Response to POST /v1/multisig/sign
Throws
ApiError
Defined in
services.gen.ts:201
signProgram()
signProgram(
data
):CancelablePromise
<APIV1POSTProgramSignResponse
>
Sign program Signs the passed program with a key from the wallet, determined by the account named in the request.
Parameters
• data: SignProgramData
The data for the request.
Returns
CancelablePromise
<APIV1POSTProgramSignResponse
>
APIV1POSTProgramSignResponse Response to POST /v1/data/sign
Throws
ApiError
Defined in
services.gen.ts:235
signTransaction()
signTransaction(
data
):CancelablePromise
<APIV1POSTTransactionSignResponse
>
Sign a transaction Signs the passed transaction with a key from the wallet, determined by the sender encoded in the transaction.
Parameters
• data: SignTransactionData
The data for the request.
Returns
CancelablePromise
<APIV1POSTTransactionSignResponse
>
APIV1POSTTransactionSignResponse Response to POST /v1/transaction/sign
Throws
ApiError
Defined in
services.gen.ts:252
swaggerHandler()
swaggerHandler():
CancelablePromise
<string
>
Gets the current swagger spec. Returns the entire swagger spec in json.
Returns
CancelablePromise
<string
>
string The current swagger spec
Throws
ApiError
Defined in
services.gen.ts:16