Get Unallocated Payments for a Bill Unit
get
/bcws/webresources/v1.0/payments/billunit/{id}
Gets the list of unallocated payments for the specified bill unit.
Request
Path Parameters
-
id(required): string
The ID of the bill unit.
Query Parameters
-
type(required): string
The type of payments to get. The only supported value is type=unallocated.
There's no request body for this operation.
Back to TopResponse
Supported Media Types
- application/xml
- application/json
200 Response
The unallocated payments were returned successfully.
Nested Schema : paymentList
Type:
Show Source
object
-
billingStatus: integer
(int32)
The billing status. Can be one of the following:
- 1 (Billed)
- 2 (Unbilled)
-
extension: object
extension
The extended attributes.
-
originalPaymentAmount(required): number
The original payment amount.
-
paymentAction: integer
(int32)
Whether the payment has been reversed or suspended. Can be one of the following:
- 0 (Not reversed)
- 1 (Reversed)
- 2 (Suspended)
-
paymentAmount(required): number
The amount of the payment.
-
paymentDate(required): string
(date-time)
The date and time the payment was made.
-
paymentId(required): string
The ID of the payment
-
paymentMethod: integer
(int32)
The payment method. Can be one of the following:
- 10011 (Cash)
- 10012 (Check)
- 10013 (Wire transfer)
- 10014 (Inter-bank payment order)
- 10015 (Postal order)
-
paymentRef: object
ResourceRef
-
unAllocatedAmount(required): number
The amount that is still unallocated.
Nested Schema : extension
Type:
object
The extended attributes.
Nested Schema : ResourceRef
Type:
Show Source
object
-
id(required): string
The ID.
-
uri: string
The Uniform Resource Identifier (URI) associated with the resource.
500 Response
An internal server error occurred.
Examples
This example shows how to get a bill unit's unallocated payments by submitting a GET request on the REST resource using cURL. For more information about cURL, see "Use cURL".
cURL Command
curl -X GET 'http://hostname:port/bcws/webresources/version/payments/billunit/0.0.0.1+-account+57615?type=unallocated'
where:
- hostname is the URL for the Billing Care REST server.
- port is the port for the Billing Care REST server.
- version is the version of the API you're using, such as v1.0.
Example of Response Body
This example shows the contents of the response body in JSON format.
[
{
"extension": null,
"paymentAmount": -200,
"paymentDate": 1585787580000,
"paymentId": "P1-66",
"paymentMethod": 10013,
"unAllocatedAmount": -200,
"originalPaymentAmount": null,
"paymentAction": null,
"billingStatus": null,
"paymentRef": {
"id": "0.0.0.1+-item-payment+119786",
"uri": null
}
},
{
"extension": null,
"paymentAmount": -2,
"paymentDate": 1590640735000,
"paymentId": "P1-48",
"paymentMethod": 10013,
"unAllocatedAmount": -2,
"originalPaymentAmount": null,
"paymentAction": null,
"billingStatus": null,
"paymentRef": {
"id": "0.0.0.1+-item-payment+126600",
"uri": null
}
},
{
"extension": null,
"paymentAmount": -25,
"paymentDate": 1590641129000,
"paymentId": "P1-49",
"paymentMethod": 10013,
"unAllocatedAmount": -25,
"originalPaymentAmount": null,
"paymentAction": null,
"billingStatus": null,
"paymentRef": {
"id": "0.0.0.1+-item-payment+118985",
"uri": null
}
},
{
"extension": null,
"paymentAmount": -25,
"paymentDate": 1590641616000,
"paymentId": "P1-50",
"paymentMethod": 10013,
"unAllocatedAmount": -25,
"originalPaymentAmount": null,
"paymentAction": null,
"billingStatus": null,
"paymentRef": {
"id": "0.0.0.1+-item-payment+122216",
"uri": null
}
}
]