Line Items
Line Items form the core of every Procurement Scorecard. Each line item represents an amount of spend allocated to a specific supplier for the defined reporting period. Line item amounts must exclude VAT. These records drive all downstream B-BBEE procurement calculations, including TMPS, recognition levels, and ownership weighting.
Line items are append-only: the API supports creating and reading line items, but does not allow updates or deletions. To correct a mistake, you must create a new line item that reflects the corrected spend.
You may insert line items individually or in bulk in a single request.
Endpoints
| Method | Path | Purpose |
|---|---|---|
| GET | /api/v1/procurement_scorecards/{procurement_scorecard_id}/heartbeat | Confirm API availability and authentication |
| GET | /api/v1/procurement_scorecards/{procurement_scorecard_id}/line_items | Retrieve all line items for the given scorecard |
| POST | /api/v1/procurement_scorecards/{procurement_scorecard_id}/line_items | Create one or more line items |
All requests must be authenticated using your API key and HMAC signature. See the Authentication section for details.
Line Item Attributes
| Attribute | Example | Description |
|---|---|---|
| supplier_vendor_code | "TS001" | The supplier’s vendor code. Must match an existing supplier you have created. |
| spend | 1000 | Spend amount for the given scorecard period. Excluding VAT. |
Notes
- Line items cannot be updated or deleted after creation.
- Use bulk create (multiple items in one request) for high‑volume data loads.
- Every line item must reference a valid supplier via
supplier_vendor_code.
Example: Creating Line Items
const url = "https://www.suppliermanagement.co.za/api/v1/procurement_scorecards/100/line_items";
const payload = {
line_items: [
{
supplier_vendor_code: "TS002",
spend: 1000
}
]
};
await axios.post(url, payload, {
headers: {
Accept: "application/json",
Authorization: "HMAC <your signature>",
"X-Api-Key": "<your account key>",
}
});