View Fund
The View Fund API is designed to retrieve the current balance of the fund for a business unit of a supplier organization.
-
Method:
GET
-
URL:
https://<PA_RM_END_POINT>/rm/1.0/fund/{businessUnitId}
infoPlease refer to the Supplier API documentation for detailed instructions on how to retrieve the
businessUnitId
. -
Headers:
Content-Type: application/json
Authorization: Bearer ACCESS_TOKEN
-
Response Codes:
-
200 OK
Successful request. The response body will include the current balance of the fund:
{
"payload": {
"id": "xxxxxxxxxxxxxxxxxxxxxxx",
"credits": 1000.00,
"spent": 800.00
}
}-
id (GUID)
: The unique identifier for the fund. -
credits (float)
: Total amount that has been added. -
spent (float)
: Total amount that has been spent.
infoThe available fund will be the difference between the
credits
andspent
amounts. -
-
Non-200 Responses
If an error occurs (e.g., bad request, unauthorized access, or fund not found), the server will respond with an appropriate non-200 status code and include an error message in the response body:
{
"error": "Error message"
}noteIt is important to handle fund data securely and ensure that access is restricted to authorized users only.
-