Search in sources :

Example 1 with BtcWalletAddress

use of io.bisq.api.model.BtcWalletAddress in project bisq-api by mrosseel.

the class BtcWalletResource method getOrCreateBtcWalletAddresses.

@ApiOperation("Get or create wallet addresses")
@POST
@Path("/addresses")
public BtcWalletAddress getOrCreateBtcWalletAddresses(@Valid CreateBtcWalletAddress payload) {
    final AddressEntry addressEntry = bisqProxy.getOrCreateBtcWalletAddresses(payload.context, payload.unused);
    final BtcWalletAddress btcWalletAddress = new BtcWalletAddress();
    btcWalletAddress.address = addressEntry.getAddressString();
    return btcWalletAddress;
}
Also used : AddressEntry(io.bisq.core.btc.AddressEntry) BtcWalletAddress(io.bisq.api.model.BtcWalletAddress) CreateBtcWalletAddress(io.bisq.api.model.CreateBtcWalletAddress) Path(javax.ws.rs.Path) POST(javax.ws.rs.POST) ApiOperation(io.swagger.annotations.ApiOperation)

Aggregations

BtcWalletAddress (io.bisq.api.model.BtcWalletAddress)1 CreateBtcWalletAddress (io.bisq.api.model.CreateBtcWalletAddress)1 AddressEntry (io.bisq.core.btc.AddressEntry)1 ApiOperation (io.swagger.annotations.ApiOperation)1 POST (javax.ws.rs.POST)1 Path (javax.ws.rs.Path)1