Skip to content

Commit

Permalink
docs: Add transfers methods to readme
Browse files Browse the repository at this point in the history
  • Loading branch information
peoray committed Jan 29, 2024
1 parent d80eadd commit 8a75752
Showing 1 changed file with 74 additions and 0 deletions.
74 changes: 74 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,11 @@ A Nodejs API wrapper for [Bloc](https://www.blochq.io/) banking services written
- [Transactions API](#transactions-api)
- [Get All Transactions](#get-all-transactions)
- [Get Transaction by Reference](#get-transaction-by-reference)
- [Transfers API](#transfer-api)
- [Transfer From A Fixed Account](#transfer-from-a-fixed-account)
- [Transfer From Organization Balance](#transfer-from-organization-balance)
- [Internal transfer](#internal-transfer)
- [Bulk transfer](#bulk-transfer)
- [Webhook API](#webhook-api)
- [Set Webhook](#set-webhook)
- [Get Webhook](#get-webhook)
Expand Down Expand Up @@ -571,6 +576,75 @@ console.log(response) // ITransactionByReferenceResponse

Find more details about the parameters and response for the above method [here](https://docs.blochq.io/reference/getalltransactions)


### Transfers API

Transfers API operations

#### Transfer From A Fixed Account

```ts
// import the transfers interfaces from the sdk
import type { ITransferFromAFixedAccountRequest, ITransferResponse } from 'bloc-nodejs';

const payload: ITransferFromAFixedAccountRequest = {
// payload data
}

const response = await bloc.transferFromAFixedAccount(payload)
console.log(response) // ITransferResponse
```

Find more details about the parameters and response for the above method [here](https://docs.blochq.io/reference/transferfromafixedaccount)

#### Transfer From Organization Balance

```ts
// import the transfers interfaces from the sdk
import type { ITransferFromOrganizationBalance, ITransferResponse } from 'bloc-nodejs';

const payload: ITransferFromOrganizationBalance = {
// payload data
}

const response = await bloc.transferFromOrganizationBalance(payload)
console.log(response) // ITransferResponse
```

Find more details about the parameters and response for the above method [here](https://docs.blochq.io/reference/transferfromorganizationbalance)

#### Internal Transfer

```ts
// import the transfers interfaces from the sdk
import type { IInternalTransferRequest, ITransferResponse } from 'bloc-nodejs';

const payload: IInternalTransferRequest = {
// payload data
}

const response = await bloc.internalTransfer(payload)
console.log(response) // ITransferResponse
```

Find more details about the parameters and response for the above method [here](https://docs.blochq.io/reference/internaltransfer)

#### Bulk Transfer

```ts
// import the transfers interfaces from the sdk
import type { IBulkTransferRequest, ITransferResponse } from 'bloc-nodejs';

const payload: IBulkTransferRequest = {
// payload data
}

const response = await bloc.bulkTransfer(payload)
console.log(response) // ITransferResponse
```

Find more details about the parameters and response for the above method [here](https://docs.blochq.io/reference/bulktransfer)

### Webhook API

Webhook API operations
Expand Down

0 comments on commit 8a75752

Please sign in to comment.