Skip to navigation

Create or replace the Journal mapping

This endpoint is an idempotent upsert of your Journal mapping. It is a full replace: Journal Line fields omitted from the body are no longer mapped.

To create the mapping, send no If-Match, or send If-None-Match: * to make the request fail if a mapping already exists. To replace it, If-Match is required and must carry the ETag from your last read - omitting it is rejected with 428, and a stale value with 412.

The Journal Line Definition and the Business Event Definition must exist first, because the mapping refers to fields of both.

Every change is saved as a new version together with the comment. Sending a mapping identical to the saved one saves nothing, so a request that is retried is safe.

The change takes effect immediately and does not go through an approval workflow, so the response is always 201 or 200.

Authentication

AuthorizationBearer

OAuth authentication of the form <token>.

Headers

If-MatchstringOptional

The ETag from your last read of the resource. Required when replacing an existing resource, and omitted when creating one.

If-None-MatchenumOptional

Send * for create-only semantics - the request then fails if the resource already exists.

Allowed values:

Query parameters

commentstringOptional

Comment recorded against the change in the audit trail. Defaults to Changed through the configuration API.

Request

This endpoint expects an object.
fieldMappingslist of objectsOptional
One entry per mapped Journal Line field, in order. A write replaces the whole list, so a field left out is no longer mapped.

Response headers

ETagstringOptional

Current entity tag of the resource. Supply it as If-Match on a subsequent update or deactivation.

Response

OK
fieldMappingslist of objectsOptional
One entry per mapped Journal Line field, in order. A write replaces the whole list, so a field left out is no longer mapped.

Errors

400
Bad Request Error
401
Unauthorized Error
412
Precondition Failed Error
428
Precondition Error
429
Too Many Requests Error
5XX
Server Error