Get Approval Policy by ID API
Overview
Retrieves full details of an approval policy and its configured levels.
- Endpoint:
/api/approval-policies/get-by-id - Method:
POST - Access: Corporate Admin / Manager
Request Body Schema
| Field | Type | Required | Description |
|---|---|---|---|
id | String (UUID) | Yes | Target approval policy ID |
Request Body Example
{
"id": "p123-uuid"
}
Success Response (200 OK)
{
"success": true,
"message": "Approval Policy details retrieved successfully",
"data": {
"id": "p123-uuid",
"name": "Standard Travel Policy",
"autoApprovalLimit": "7000.00",
"company": {
"id": "c478a846-993d-4c8d-bf8d-d77cb3370e01",
"name": "Abbott Healthcare"
},
"levels": [
{
"id": "pl1-uuid",
"level": 1,
"roleRequired": "COMPANY_MANAGER",
"minAmount": "7001.00",
"maxAmount": "20000.00"
}
]
}
}
Database Impact
- Tables:
approval_policies,approval_policy_levels - Operations:
SELECTby primary key with relations.