New v3 API endpoints for bill approvals
We have introduced a set of API endpoints for bill approvals. With v3 bill approvals, you can now create and manage approval policies for bills based on a set of rules. In an approval policy, the approvers can be individual users or user groups.
When you create or update a bill with the v3 API, set billApprovals as true for BILL to add approvals information in the v3 bills response.
When you have approval policies set up for bills and a bill matches the policy, you now see an additional approvers array of objects in the v3 bills response. The array shows the list of individual users and/or user groups assigned as bill approvers. In addition, the array provides information about the status of the bill in the current approval flow.
For any approvers added to a v3 bill, the approvals must be complete before you can pay the bill with the API.
| Operation | API endpoint |
|---|---|
| Create a bill approval policy | POST /v3/bill-approvals |
| Get list of bill approval policies | GET /v3/bill-approvals/policies |
| Update a bill approval policy | PUT /v3/bill-approvals/policies/{policyId} |
| Delete a bill approval policy | DELETE /v3/bill-approvals/policies/{policyId} |
| Approve or deny a bill | POST /v3/bill-approvals/actions |
| Get list of bills pending approvals | GET /v3/bill-approvals/pending-user-approvals |
See Bill approvals for more information.
