Procurement API
Price Agreements
Resolve negotiated prices and organization-specific commercial agreements during procurement.
Strategic pricing
Negotiated commercial terms
Validity control
Start / end dates
Volume tiers
Quantity-based pricing
Multiple terms
Price, discount, tax, currency
Fully integrated
POs, invoices and suppliers
Agreement model
| Field | Description |
|---|---|
| organization_id | Purchasing organization |
| supplier_id | Supplier party |
| scope | Products/categories covered |
| valid_from / valid_to | Validity window |
| pricing_terms | Fixed price, discount or tier rules |
| status | draft, active, expired, terminated |
Eligibility
Only active agreements matching the purchasing organization, supplier, product scope and validity window are eligible during price resolution.
Price resolution
GET
/v1/price-agreementsGET
/v1/price-agreements/{id}POST
/v1/price-agreementsPATCH
/v1/price-agreements/{id}DELETE
/v1/price-agreements/{id}Validity & priority
| Rule | Resolution |
|---|---|
| Specific product before category | Most specific eligible scope wins |
| Explicit negotiated agreement | Preferred over standard catalog price |
| Validity overlap | Use configured priority / most specific agreement |
| Expired agreement | Never applied to a new order |
Audit trail
Every purchase order line should retain the agreement reference and resolved unit price used when the order was approved so later commercial changes do not alter historical orders.
Example request
cURLJavaScriptPython
curl "https://api.mediloop.com/v1/price-agreements?status=active&supplier_id=sup_42" \
-H "Authorization: Bearer $MEDILOOP_API_KEY" \
-H "X-Tenant-Id: $TENANT_ID"List active agreements
Response200 OK
{
"data":[{ "id":"agr_88", "supplier_id":"sup_42", "status":"active", "valid_to":"2026-12-31" }]
}