# BitcoinTransferService

Transfer bitcoin in and out of the platform. Fetch information about past
 bitcoin transfers.

## Fetch bitcoin deposit destinations

 - [GET /v1/deposit-destinations/bitcoin](https://dev.barebitcoin.no/api/openapi/bitcointransferservice/bitcointransferservice_depositdestinations.md): Fetches bitcoin deposit destinations. These destinations are always valid,
 and can be used for receiving arbitrary amounts. Onchain addresses are refreshed
 every time a deposit is made, but all prior generated addresses are still valid.

## Create a new Lightning invoice

 - [POST /v1/deposit-destinations/bitcoin/invoice](https://dev.barebitcoin.no/api/openapi/bitcointransferservice/bitcointransferservice_newlightninginvoice.md): Creates a new BOLT11 Lightning invoice. Lightning invoices are requests to receive a specific
 amount of bitcoin within a set amount of time. If you don't a specific amount, consider
 using the destinations returned from /v1/deposit-destinations/bitcoin.

## Fetch a Lightning invoice

 - [GET /v1/deposit-destinations/bitcoin/invoice/{id}](https://dev.barebitcoin.no/api/openapi/bitcointransferservice/bitcointransferservice_getlightninginvoice.md): Fetches a Lightning invoice.

## Initiate withdrawal

 - [POST /v1/withdrawals/bitcoin](https://dev.barebitcoin.no/api/openapi/bitcointransferservice/bitcointransferservice_sendbitcoin.md): Initiates a bitcoin withdrawal. The transaction is not completed until
 it is confirmed by the network it is sent onto. A success response from
 this endpoint means the transaction was successfully initiated, but
 does not guarantee completion.

## Fetch withdrawal

 - [GET /v1/withdrawals/bitcoin/{withdrawalId}](https://dev.barebitcoin.no/api/openapi/bitcointransferservice/bitcointransferservice_getbitcoinwithdrawal.md): Fetches a bitcoin withdrawal.

