Create a Purchase Register Entry
Creates a document in the purchase register. Use entry_type PURCHASE or PURCHASE_ADJUSTMENT and document_type INVOICE or CREDIT_NOTE. Include org_id when your API requires it. A valid bearer token is required.
Rate limit
60 requests/minute per authenticated account. See Rate limiting for response headers (X-RateLimit-*) and retry guidance.
Path parameter
POST /api/document-registers/{profile_id}
Authorization: Bearer {jwt_token}
X-MARMIN-VERSION: 20260507Document register request – all fields
Fields in the register request body. Rows are ordered Required → Conditional → Optional.
Do not send: accounting_customer_party — the API sets the customer from profile_id in the URL.
Non-AED register entries
When document_currency_code is not AED, include tax_exchange_rate with target_currency_code = AED.
Party (accounting_supplier_party / accounting_customer_party)
Address object
Party postal_address uses the address object structure.
Document line (each item in `document_lines`)
Tax category object
Line-item classified_tax_category uses the shared tax category structure.
Supplier and customer from profile
For purchase and purchase adjustments:
Use the same request body structure for all purchase scenarios; only entry_type and document_type change.
Request body
Send a JSON object with the fields described in the request fields below. Typical combinations:
Include org_id when your API requires it.
Response
Status code: 201 Created
Response body:
Returns the created register entry with request data and system‑generated fields (id, uuid, source_type, line ids, created_at, updated_at). When provided, org_id is included in the response.
Error responses
400 Bad Request
Invalid request body or validation failed. The response returns an errors object with field names as keys and error messages as values.
401 Unauthorized
Authentication required or invalid token.
500 Internal Server Error
An error occurred while processing the request.
