_mappings. No lookup table on your side, no extra call.erpId and billingRef.Asset.erpId. The API returns them as _mappings.erpId. Names start with a lowercase letter, then letters, digits or underscores, up to 63 characters.| Setting | One | Several |
|---|---|---|
| Identifiers per record | The API returns a single value. A second identifier on the same record is refused. | The API returns a list, and a record may have more than one. |
| Records per identifier | The same identifier on two records is refused. | Records may share an identifier. |
_mappings, keyed by the names you chose:{
"id": "0192f4b7-2e3f-7d40-9b5c-6d7e8f9a0b1c",
"code": "CNV-07",
"_displayValue": "Conveyor 7",
"name": "Conveyor 7",
"_mappings": {
"erpId": "EQ-10042",
"billingRefs": ["BR-201", "BR-305"]
}
}null and a list mapping is [] until you add identifiers. _mappings is on list reads, single-record reads and write responses._mappings in Makini Query Language with any:{ "query": "select id, name, _mappings from assets where 'EQ-10042' = any(_mappings.erpId)" }join.client_credentials token (see Management API authentication); reads need connections:read and changes need connections:write.{
"dataMapping": {
"id": "d6fa5763-7230-417c-827f-64a3e69076fd",
"entity": "Asset",
"key": "erpId",
"identifierCardinality": "one",
"recordCardinality": "one",
"revision": 1,
"entryCount": 0
}
}identifierCardinality is the identifiers a record may carry and recordCardinality is the records one identifier may point at. Both are one unless you send many.revision and entryCount, and the identifiers appear on /v4 within about a minute.| Route | Does |
|---|---|
GET /connections/{id}/data-mappings | Lists the connection's mappings. Add ?entity=Asset for one entity. |
POST /connections/{id}/data-mappings | Creates a mapping. |
GET /connections/{id}/data-mappings/{mappingId} | Reads one mapping. |
PUT /connections/{id}/data-mappings/{mappingId} | Changes its key or cardinality. |
GET /connections/{id}/data-mappings/{mappingId}/entries | Reads the pairs, a page at a time (limit, then after with the nextAfter from the page before). |
PUT /connections/{id}/data-mappings/{mappingId}/entries | Replaces the pairs. |
DELETE /connections/{id}/data-mappings/{mappingId} | Stops mapping the entity and discards its pairs. |