Get Unallocated Payments for an Account
get
/bcws/webresources/v1.0/payments/account/{id}
Gets the list of unallocated payments for an account.
Both the id parameter and the type query parameter are required.
Request
Path Parameters
-
id(required): string
The ID of the account you are retrieving payments for, such as 0.0.0.1+-account+123123.
Query Parameters
-
type(required): string
The type of payments to retrieve. The only supported value is 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 an account'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/account/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": -8.5,
"paymentDate": 1590641967000,
"paymentId": "P1-56",
"paymentMethod": 10011,
"unAllocatedAmount": -1.55,
"originalPaymentAmount": null,
"paymentAction": null,
"billingStatus": null,
"paymentRef": {
"id": "0.0.0.1+-item-payment+122952",
"uri": null
}
},
{
"extension": null,
"paymentAmount": -3,
"paymentDate": 1594928886000,
"paymentId": "P1-216",
"paymentMethod": 10011,
"unAllocatedAmount": -3,
"originalPaymentAmount": null,
"paymentAction": null,
"billingStatus": null,
"paymentRef": {
"id": "0.0.0.1+-item-payment+122389",
"uri": null
}
},
{
"extension": null,
"paymentAmount": -1,
"paymentDate": 1600689352000,
"paymentId": "P1-281",
"paymentMethod": 10011,
"unAllocatedAmount": -1,
"originalPaymentAmount": null,
"paymentAction": null,
"billingStatus": null,
"paymentRef": {
"id": "0.0.0.1+-item-payment+156894",
"uri": null
}
},
{
"extension": null,
"paymentAmount": -1,
"paymentDate": 1600689439000,
"paymentId": "P1-282",
"paymentMethod": 10011,
"unAllocatedAmount": -2,
"originalPaymentAmount": null,
"paymentAction": null,
"billingStatus": null,
"paymentRef": {
"id": "0.0.0.1+-item-payment+157440",
"uri": null
}
},
{
"extension": null,
"paymentAmount": -1,
"paymentDate": 1608705956000,
"paymentId": "P1-390",
"paymentMethod": 10011,
"unAllocatedAmount": -1,
"originalPaymentAmount": null,
"paymentAction": null,
"billingStatus": null,
"paymentRef": {
"id": "0.0.0.1+-item-payment+216361",
"uri": null
}
},
{
"extension": null,
"paymentAmount": -1,
"paymentDate": 1608706413000,
"paymentId": "P1-391",
"paymentMethod": 10011,
"unAllocatedAmount": -1,
"originalPaymentAmount": null,
"paymentAction": null,
"billingStatus": null,
"paymentRef": {
"id": "0.0.0.1+-item-payment+210777",
"uri": null
}
},
{
"extension": null,
"paymentAmount": -1,
"paymentDate": 1608719228000,
"paymentId": "P1-402",
"paymentMethod": 10011,
"unAllocatedAmount": -1,
"originalPaymentAmount": null,
"paymentAction": null,
"billingStatus": null,
"paymentRef": {
"id": "0.0.0.1+-item-payment+216776",
"uri": null
}
}
]