@vafanassieff/bitcoin-cli-ts
Version:
Auto-generated Bitcoin client library for bitcoind JSON-RPC API
26 lines (22 loc) • 712 B
text/typescript
// Auto synced from github actions. Don't change this file
import { Bitcoind } from '../../types.js'
import request from '../../rpc-request.js'
type GetRawChangeAddressParams = {
bitcoind: Bitcoind
/* The address type to use. Options are "legacy", "p2sh-segwit", "bech32", and "bech32m". */
address_type?: string
}
/**
* getrawchangeaddress ( "address_type" )
*
* Returns a new Bitcoin address, for receiving change.
* This is for use with raw transactions, NOT normal use.
*
*/
export function getRawChangeAddress(params: GetRawChangeAddressParams) {
const { bitcoind, ...methodParams } = params
return request(
{ method: 'getrawchangeaddress', params: methodParams },
bitcoind
)
}