Maalam Developers
Integration

Create or replace many units in one request

Up to 100 units, each handled like a single `PUT`. Not a transaction: every item reports its own outcome, and one that fails does not undo the others. Always 200.

POST
/v1/integration/units/batch

Up to 100 units, each handled like a single PUT. Not a transaction: every item reports its own outcome, and one that fails does not undo the others. Always 200.

AuthorizationBearer <token>

An API key from the back office (settings → API), sent as Authorization: Bearer mlm_live_….

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

curl -X POST "https://example.com/v1/integration/units/batch" \  -H "Content-Type: application/json" \  -d '{    "items": [      {        "type": "string",        "areaSqm": 1,        "priceSar": 1,        "project": "string",        "code": "string"      }    ]  }'
{  "results": [    {      "project": "string",      "code": "string",      "outcome": "created",      "error": {        "code": "string",        "message": "string",        "details": null      }    }  ]}