> For the complete documentation index, see [llms.txt](https://kb.theloops.io/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://kb.theloops.io/agentstudio/skills-library/projects/check-milestone-payment-approval-readiness.md). Agents can also search and read this documentation through its [MCP server](https://kb.theloops.io/~gitbook/mcp).

# Check Milestone Payment Approval Readiness

Purchase orders in IFS can carry a payment schedule of down-payment and retention lines (PurOrdPaySchedLine).

| Business area | Action type                                |
| ------------- | ------------------------------------------ |
| Projects      | Updates IFS Cloud data after user approval |

## Overview

Retention lines withhold part of each supplier invoice. When the supplier has met the conditions, a buyer approves the retention line for payment.

IFS Cloud OData integration.

## How it works

{% stepper %}
{% step %}
Line: PaymentSchedulesHandling.
{% endstep %}

{% step %}
Header: PaymentScheduleForPurchaseOrderHandling.
{% endstep %}

{% step %}
Matches: PaymentScheduleAnalysis.
{% endstep %}

{% step %}
Evaluate: Local rules.
{% endstep %}

{% step %}
Return structured results and any escalation guidance.
{% endstep %}
{% endstepper %}

## Key capabilities

* Read one payment-schedule line with type, planned, matched and amortized amounts, due date, release and approval flags.
* Read PO / change-order state and payment-schedule totals (retention planned, approved, paid).
* List invoice matches on the line (ledger items, matched and amortized amounts).
* Apply the IFS command gate ChgOrderNo = "" and PaySchedType = "Retention" and not ApprovedForPay and (ReleasedDb or Objstate != "Planned").
* Apply server rules: only Retention lines can be approved (WRONGPSCHDTYPE), not twice (RETAPPROVEDERR).
* Add business readiness checks: matched invoices exist, matched coverage %, due date reached, PO not Cancelled/Stopped.
* Explain down-payment lines (not approvable, amortization status instead).
* Return verdict, blockers and the next permissible step with owner role.

{% hint style="info" %}
This skill keeps a human in the loop. It previews every change and updates IFS Cloud only after a user approves it.
{% endhint %}

## Requirements

The following IFS Cloud components and projections must be available, with permission sets that grant access to each projection.

| Component                                | Projection                              |
| ---------------------------------------- | --------------------------------------- |
| PURCH (PURCHASE ORDER PAYMENT SCHEDULES) | PaymentSchedulesHandling                |
| INVOIC (SUPPLIER INVOICE PAYMENT PLANS   | PaymentScheduleForPurchaseOrderHandling |
| REFERENCED)                              | PaymentScheduleAnalysis                 |

## Version compatibility

| Projection                              | Supported IFS Cloud releases |
| --------------------------------------- | ---------------------------- |
| PaymentSchedulesHandling                | 24R2, 25R1, 25R2, 26R1, 26R2 |
| PaymentScheduleForPurchaseOrderHandling | 24R2, 25R1, 25R2, 26R1, 26R2 |
| PaymentScheduleAnalysis                 | 24R2, 25R1, 25R2, 26R1, 26R2 |

## Known limitations

* Write paths require explicit user confirmation or authorization where configured.
