---
title: "storeConfig"
method: POST
path: "/v1/mappings"
tags: ["mappings"]
---

# storeConfig

`POST /v1/mappings`

Store new MappingConfig

## Query parameters

- `with_id` string

## Request body

- MappingConfig
  - `id` string, required
  - `source` SourceConfig, required
    - `type` 'journey' | 'entity'
    - `config` union
      - JourneyRef
        - `journey_id` string
      - EntityRef
        - `entity_id` string, required — id of the source entity to be mapped
        - `entity_schema` string — schema of the source entity
  - `targets` TargetConfig[], required
    - `id` string — Identifier for target configuration. Useful for later usages when trying to identify which target config to map to.
    - `name` string — A name for this configuration
    - `allow_failure` boolean — Pass it as true, when you don't want failures to interrupt the mapping process.
    - `target_schema` string, required — Schema of target entity
    - `target_unique` string[] — Unique key for target entity (see upsertEntity of Entity API)
    - `use_uniqueness_criteria` boolean — Execution wire flag set per automation by automation-workers: resolve the target entity via the organization's global uniqueness criteria (deduplication-api) instead of target_unique. Never persisted in stored mapping configs.
    - `loop_config` object — contains config in case of running in loop mode
      - `source_path` string — path to the array from the entity payload
      - `length` number — a hard limit of how many times the loop is allowed to run.
    - `conditionMode` 'oneOf' | 'anyOf' | 'allOf' — Mode of how conditions are considered valid
    - `conditions` MapCondition[] — Conditions necessary to hold for the target entity to be mapped
      - `_exists` ConditionNode
        - `source` string
        - `value` union
          - string
          - number
          - object
          - object[]
      - `_equals` ConditionNode
        - `source` string
        - `value` union
          - string
          - number
          - object
          - object[]
      - `_not_exists` ConditionNode
        - `source` string
        - `value` union
          - string
          - number
          - object
          - object[]
      - `_any_of` ConditionNode
        - `source` string
        - `value` union
          - string
          - number
          - object
          - object[]
    - `mapping_attributes` union[], required — Attribute mappings
      - union
        - MappingAttributeV2
          - `target` string, required — Target JSON path for the attribute to set
          - `operation` union, required — Mapping operation nodes are either primitive values or operation node objects
            - OperationObjectNode
              - …
            - union — Represents any primitive JSON value
              - …
          - `origin` 'system_recommendation' | 'user_manually' | 'entity_updating_system_recommendation' — Origin of an attribute.
        - union
          - SetValueMapper
            - `mode` 'copy_if_exists' | 'append_if_exists' | 'set_value', required — - copy_if_exists - it replaces the target attribute with the source value - append_if_exists - it currently replaces target attribute with array like values. Useful when you have multiple values to be added into one attribute. - set_value - it sets a value to a predefined value. Must be used together with value property.
            - `target` string, required — JSON like target path for the attribute. Eg. last_name
            - `value` unknown, required
          - CopyValueMapper
            - `mode` 'copy_if_exists' | 'append_if_exists' | 'set_value', required — - copy_if_exists - it replaces the target attribute with the source value - append_if_exists - it currently replaces target attribute with array like values. Useful when you have multiple values to be added into one attribute. - set_value - it sets a value to a predefined value. Must be used together with value property.
            - `target` string, required — JSON like target path for the attribute. Eg. last_name
            - `source` string, required — JSON source path for the value to be extracted from the main entity. Eg: steps[1].['Product Info'].price
          - AppendValueMapper
            - `mode` 'copy_if_exists' | 'append_if_exists' | 'set_value', required — - copy_if_exists - it replaces the target attribute with the source value - append_if_exists - it currently replaces target attribute with array like values. Useful when you have multiple values to be added into one attribute. - set_value - it sets a value to a predefined value. Must be used together with value property.
            - `target` string, required — JSON like target path for the attribute. Eg. last_name
            - `source` string — JSON source path for the value to be extracted from the main entity. Eg: steps[1].['Product Info'].price
            - `value_json` string, required — To be provided only when mapping json objects into a target attribute. Eg array of addresses.
            - `target_unique` string[] — Array of keys which should be used when checking for uniqueness. Eg: [country, city, postal_code]
    - `relation_attributes` RelationAttribute[] — Relation mappings
      - `target` string, required — Target attribute to store the relation in
      - `target_tags` string[] — Relation tags (labels) to set for the stored relations
      - `target_tags_include_source` boolean — Include all relation tags (labels) present on the main entity relation
      - `target_entity_tags` string[] — Tags to add to the matched target entity's _tags array during mapping. Useful for assigning file collections to file entities.
      - `override_with_source_filter` boolean — Whether to override the relation source_filter with the specified one
      - `source_filter` object — A filter to identify which source entities to pick as relations from main entity
        - `limit` integer — Limit relations to maximum number (default, all matched relations)
        - `schema` string — Filter by specific schema
        - `attribute` string — Filter by a specific relation attribute on the main entity
        - `relation_tag` string — Filter by relation tag (label) on the main entity
        - `tag` string — Filter by a specific tag on the related entity
        - `self` boolean — Picks main entity as relation (overrides other filters)
      - `related_to` object
      - `mode` 'append' | 'prepend' | 'set', required
      - `origin` 'system_recommendation' | 'user_manually' | 'entity_updating_system_recommendation' — Origin of an attribute.
    - `linkback_relation_attribute` string — Relation attribute on the main entity where the target entity will be linked. Set to false to disable linkback
    - `linkback_relation_tags` string[] — Relation tags (labels) to include in main entity linkback relation attribute
  - `created_at` string, date-time
  - `updated_at` string, date-time
  - `created_by` Owner
    - `type` 'user' | 'internal_service', required
    - `org_id` string
    - `user_id` string
  - `last_updated_by` Owner
    - `type` 'user' | 'internal_service', required
    - `org_id` string
    - `user_id` string
  - `org_id` string, required
  - `version` integer, required

## Response `201`

The updated entity mapping config

- MappingConfig
  - `id` string, required
  - `source` SourceConfig, required
    - `type` 'journey' | 'entity'
    - `config` union
      - JourneyRef
        - `journey_id` string
      - EntityRef
        - `entity_id` string, required — id of the source entity to be mapped
        - `entity_schema` string — schema of the source entity
  - `targets` TargetConfig[], required
    - `id` string — Identifier for target configuration. Useful for later usages when trying to identify which target config to map to.
    - `name` string — A name for this configuration
    - `allow_failure` boolean — Pass it as true, when you don't want failures to interrupt the mapping process.
    - `target_schema` string, required — Schema of target entity
    - `target_unique` string[] — Unique key for target entity (see upsertEntity of Entity API)
    - `use_uniqueness_criteria` boolean — Execution wire flag set per automation by automation-workers: resolve the target entity via the organization's global uniqueness criteria (deduplication-api) instead of target_unique. Never persisted in stored mapping configs.
    - `loop_config` object — contains config in case of running in loop mode
      - `source_path` string — path to the array from the entity payload
      - `length` number — a hard limit of how many times the loop is allowed to run.
    - `conditionMode` 'oneOf' | 'anyOf' | 'allOf' — Mode of how conditions are considered valid
    - `conditions` MapCondition[] — Conditions necessary to hold for the target entity to be mapped
      - `_exists` ConditionNode
        - `source` string
        - `value` union
          - string
          - number
          - object
          - object[]
      - `_equals` ConditionNode
        - `source` string
        - `value` union
          - string
          - number
          - object
          - object[]
      - `_not_exists` ConditionNode
        - `source` string
        - `value` union
          - string
          - number
          - object
          - object[]
      - `_any_of` ConditionNode
        - `source` string
        - `value` union
          - string
          - number
          - object
          - object[]
    - `mapping_attributes` union[], required — Attribute mappings
      - union
        - MappingAttributeV2
          - `target` string, required — Target JSON path for the attribute to set
          - `operation` union, required — Mapping operation nodes are either primitive values or operation node objects
            - OperationObjectNode
              - …
            - union — Represents any primitive JSON value
              - …
          - `origin` 'system_recommendation' | 'user_manually' | 'entity_updating_system_recommendation' — Origin of an attribute.
        - union
          - SetValueMapper
            - `mode` 'copy_if_exists' | 'append_if_exists' | 'set_value', required — - copy_if_exists - it replaces the target attribute with the source value - append_if_exists - it currently replaces target attribute with array like values. Useful when you have multiple values to be added into one attribute. - set_value - it sets a value to a predefined value. Must be used together with value property.
            - `target` string, required — JSON like target path for the attribute. Eg. last_name
            - `value` unknown, required
          - CopyValueMapper
            - `mode` 'copy_if_exists' | 'append_if_exists' | 'set_value', required — - copy_if_exists - it replaces the target attribute with the source value - append_if_exists - it currently replaces target attribute with array like values. Useful when you have multiple values to be added into one attribute. - set_value - it sets a value to a predefined value. Must be used together with value property.
            - `target` string, required — JSON like target path for the attribute. Eg. last_name
            - `source` string, required — JSON source path for the value to be extracted from the main entity. Eg: steps[1].['Product Info'].price
          - AppendValueMapper
            - `mode` 'copy_if_exists' | 'append_if_exists' | 'set_value', required — - copy_if_exists - it replaces the target attribute with the source value - append_if_exists - it currently replaces target attribute with array like values. Useful when you have multiple values to be added into one attribute. - set_value - it sets a value to a predefined value. Must be used together with value property.
            - `target` string, required — JSON like target path for the attribute. Eg. last_name
            - `source` string — JSON source path for the value to be extracted from the main entity. Eg: steps[1].['Product Info'].price
            - `value_json` string, required — To be provided only when mapping json objects into a target attribute. Eg array of addresses.
            - `target_unique` string[] — Array of keys which should be used when checking for uniqueness. Eg: [country, city, postal_code]
    - `relation_attributes` RelationAttribute[] — Relation mappings
      - `target` string, required — Target attribute to store the relation in
      - `target_tags` string[] — Relation tags (labels) to set for the stored relations
      - `target_tags_include_source` boolean — Include all relation tags (labels) present on the main entity relation
      - `target_entity_tags` string[] — Tags to add to the matched target entity's _tags array during mapping. Useful for assigning file collections to file entities.
      - `override_with_source_filter` boolean — Whether to override the relation source_filter with the specified one
      - `source_filter` object — A filter to identify which source entities to pick as relations from main entity
        - `limit` integer — Limit relations to maximum number (default, all matched relations)
        - `schema` string — Filter by specific schema
        - `attribute` string — Filter by a specific relation attribute on the main entity
        - `relation_tag` string — Filter by relation tag (label) on the main entity
        - `tag` string — Filter by a specific tag on the related entity
        - `self` boolean — Picks main entity as relation (overrides other filters)
      - `related_to` object
      - `mode` 'append' | 'prepend' | 'set', required
      - `origin` 'system_recommendation' | 'user_manually' | 'entity_updating_system_recommendation' — Origin of an attribute.
    - `linkback_relation_attribute` string — Relation attribute on the main entity where the target entity will be linked. Set to false to disable linkback
    - `linkback_relation_tags` string[] — Relation tags (labels) to include in main entity linkback relation attribute
  - `created_at` string, date-time
  - `updated_at` string, date-time
  - `created_by` Owner
    - `type` 'user' | 'internal_service', required
    - `org_id` string
    - `user_id` string
  - `last_updated_by` Owner
    - `type` 'user' | 'internal_service', required
    - `org_id` string
    - `user_id` string
  - `org_id` string, required
  - `version` integer, required

## Changes

- **2026-08-12** `ac038dfc97a1` — 2 info
  - added the new optional request property `allOf[#/components/schemas/MappingConfigCommonFields]/targets/items/use_uniqueness_criteria`
  - added the optional property `allOf[#/components/schemas/MappingConfigCommonFields]/targets/items/use_uniqueness_criteria` to the response with the `201` status

[Change history](https://skmtc.dev/epilot/apis/entity-mapping-api/changes/v1/mappings/post.md)

---

[API](https://skmtc.dev/epilot/apis/entity-mapping-api.md) · [All operations](https://skmtc.dev/epilot/apis/entity-mapping-api/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/epilot/entity-mapping-api/revisions/ac038dfc97a1/schema)
