GET /batches

Gets a list of payment batches based on supplied filter criteria defined below.

Results will be limited to 1000 items if skip/take is not supplied. Results are returned ordered by CreatedAt descending.

A list of valid statusCode's can be obtained by calling GET /batch/statusCodes.

Request

Ensure the bearer token is included in the Header of the GET operation:

Header
Mandatory
Description

Authorization

Yes

Parameter
Type
Mandatory
Description

statusCode

string

No

externalId

string

No

Filter Batches by External ID

skip

int

No

Items to skip when searching

take

int

No

Items to take when searching

Response

An empty result set will be returned if no matches are found for supplied search criteria.

An array of Batches will be returned, with a Summary for each Batch:

[
  {
    "id": "string($guid)",
    "name": "string",
    "statusCode": "string",
    "externalId": "string",
    "createdAt": "string($date-time)",
    "summary": {
      "paymentsAmount": decimal,
      "paymentsCount": int32,
      "referralsAmount": decimal,
      "settledAmount": decimal,
      "settledCount": int32,
      "cancelledAmount": decimal,
      "cancelledCount": int32
    }
  }
]
Field
Response Type
Description

id

string($guid)

Unique ID for the Batch. Used for subsequent calls to other Batch operations.

name

string

Name of the Batch as supplied in the request.

externalId

string

External ID of the Batch as supplied in the request.

statusCode

string

Status of the Batch. A new Batch will always have a DRAFT status code.

createdAt

string($date-time)

Date and time when the Batch was created.

summary

Standard Batch Summary response model.

BatchSummary

Field
Response Type
Description

paymentsAmount

decimal

Total value of payments to be made.

paymentsCount

int32

Total count of payments to be made.

referralsAmount

decimal

Total value of referral payments to be made.

settledAmount

decimal

Total value of payments that have been settled to users (i.e. paid to their accounts). The balance (paymentsAmount less settledAmount) is the value of payments pending to non-6DOT50 members (i.e. still to join)

settledCount

int32

Total count of Payments settled

cancelledAmount

decimal

Total amount of Payments cancelled in the batch (e.g. by using cancel operation)

cancelledCount

int32

Total count of Payments cancelled

Example Response
[  
  {
    "id": "26828622-cf47-4416-b9fa-3ba65d4d4d19",
    "name": "Test Batch X",
    "statusCode": "CLOSED",
    "createdAt": "2022-10-31T08:39:12.06",
    "summary": {
      "paymentsAmount": 30,
      "paymentsCount": 2,
      "referralsAmount": 0,
      "settledAmount": 10,
      "settledCount": 1,
      "cancelledAmount": 20,
      "cancelledCount": 1
    }
  },
  {
    "id": "f915671c-b00f-4f77-8175-253093d51a21",
    "name": "Test Batch Y",
    "statusCode": "DRAFT",
    "createdAt": "2022-06-14T06:26:43.473",
    "summary": {
      "paymentsAmount": 18500,
      "paymentsCount": 185,
      "referralsAmount": 0,
      "settledAmount": 0,
      "settledCount": 0,
      "cancelledAmount": 0,
      "cancelledCount": 0
    }
  },
  {
    "id": "ee1f02aa-40c5-48f3-a430-2f0ad86e5f5d",
    "name": "Test Batch Z",
    "statusCode": "CLOSED",
    "createdAt": "2022-03-11T11:56:25.493",
    "summary": {
      "paymentsAmount": 30,
      "paymentsCount": 3,
      "referralsAmount": 0,
      "settledAmount": 15,
      "settledCount": 2,
      "cancelledAmount": 15,
      "cancelledCount": 1
    }
  }
]

Last updated