/mapping/apply
Writes mapping records across integrations. It validates every record exactly as POST /v1/mapping/validate does, stores the valid ones and returns the refused ones in failed. This is the write path for agents and bulk uploads.
Mode. overwrite (default) inserts or replaces the value for each (integration, level, entity, field). append only writes keys that have no stored row yet; an existing value, empty row or wnm row all count as set, and those records are counted in skipped. Array values replace the stored array entirely.
Values. wnm: true stores a will-not-map acknowledgement and discards value: it clears the completeness warning but doesn’t block inherited values. An empty value (null, "" or []) is stored as an empty row that resolution skips. To remove a row, use DELETE /v1/mapping.
Rebuilds. Writes queue tag rebuild checks for every publisher the change can reach: all publishers using the integration (integration level), publishers with units on the ad stack, publishers in the organisation and its child organisations, the publisher itself, or the ad unit’s publisher. Only real config changes rebuild.
Response. Always 200 with per-row results, even when nothing was written. applied counts rows written, skipped rows left alone by append, failed the refused records (same shape as validate’s rows). Numeric-looking strings in the response come back as numbers.
Typical chain: GET /v1/mapping/gaps (or GET /v1/mapping/schema/) → fill in values → POST /v1/mapping/validate → POST /v1/mapping/apply → GET /v1/mapping/gaps to confirm.
Requires the integration.edit permission.
Authorizations
Query Parameters
Optional publisher uid. Integrations available to that publisher's organisation chain (its organisation, its parents and CORE) are accepted for every record, in place of the caller's own chain. The caller must be able to access the publisher (404 Not Found otherwise). Rarely needed: a record's integration is accepted anyway when it is available to the organisation of the record's own entity.
Body
overwrite inserts or replaces each (integration, level, entity, field) value. append only writes keys with no stored row yet (an existing value, empty row or wnm row counts as set) and counts the rest as skipped. Any other value behaves as overwrite. Array values always replace the stored array.
overwrite, append