Skip to main content

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

MethodPathPurpose
GET/api/v1/procurement_scorecards/{procurement_scorecard_id}/heartbeatConfirm API availability and authentication
GET/api/v1/procurement_scorecards/{procurement_scorecard_id}/line_itemsRetrieve all line items for the given scorecard
POST/api/v1/procurement_scorecards/{procurement_scorecard_id}/line_itemsCreate one or more line items
Authentication

Include the following headers on every request:

  • Authorization: HMAC <signature>
  • X-Api-Key: <your account key>
  • Accept: application/json

See Authentication.


Attributes

FieldTypeRequiredDescription
supplier_vendor_codestringyesThe supplier's vendor code. Must match an existing supplier you have created.
spendnumberyesSpend amount for the given scorecard period. Excluding VAT.

System Fields (Response Only)

FieldTypeDescription
idstringLine item identifier.
supplier_trading_namestringTrading name of the linked supplier.
created_atstringCreation timestamp (DD/MM/YYYY HH:MM:SS).
updated_atstringLast update timestamp (DD/MM/YYYY HH:MM:SS).

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.

List line items

Retrieve all line items for a procurement scorecard.

GET /api/v1/procurement_scorecards/{procurement_scorecard_id}/line_items

Path parameters

NameTypeRequiredDescription
procurement_scorecard_idstringyesThe procurement scorecard identifier.

Code examples

curl -X GET "https://www.suppliermanagement.co.za/api/v1/procurement_scorecards/100/line_items" \
-H "Accept: application/json" \
-H "X-Api-Key: <your account key>" \
-H "Authorization: HMAC <your signature>"

Response

[
{
"spend": "1000.0",
"id": "3311",
"created_at": "16/02/2026 08:01:32",
"updated_at": "16/02/2026 08:01:32",
"supplier_vendor_code": "afr001",
"supplier_trading_name": "African Reinforcing Construction"
}
]

Create line items

Create one or more line items for a procurement scorecard.

POST /api/v1/procurement_scorecards/{procurement_scorecard_id}/line_items

Path parameters

NameTypeRequiredDescription
procurement_scorecard_idstringyesThe procurement scorecard identifier.

Request body

Send a JSON object with a line_items array:

{
"line_items": [
{
"supplier_vendor_code": "afr001",
"spend": 1000
}
]
}

Code examples

curl -X POST "https://www.suppliermanagement.co.za/api/v1/procurement_scorecards/100/line_items" \
-H "Accept: application/json" \
-H "Content-Type: application/json" \
-H "X-Api-Key: <your account key>" \
-H "Authorization: HMAC <your signature>" \
-d '{
"line_items": [
{
"supplier_vendor_code": "afr001",
"spend": 1000
}
]
}'

Response

[
{
"spend": "1000.0",
"id": "3311",
"created_at": "16/02/2026 08:01:32",
"updated_at": "16/02/2026 08:01:32",
"supplier_vendor_code": "afr001",
"supplier_trading_name": "African Reinforcing Construction"
}
]