v1

latestOpenAPI 3.0.32026-08-06138294578.6 KB
Model Sync

Update Sync

Updates a model sync's configuration.

Updating a model sync is a full replacement of the sync's configuration. Every field in the request body is written to the sync; any field you omit is cleared or reset to its default value.

To make a partial change — for example, toggling active or adjusting a single field mapping — fetch the current sync with GET /api/syncs/{id}, modify the fields you want to change, and send the complete object back in the update request.

Updates to active, schedule, and policies take effect immediately. Changes to source fields, target configuration, filters, or field mappings take effect on the sync's next execution.

put/api/syncs/{id}

Path parameters

idstring uuid required
Example:248df4b7-aa70-47b8-a036-33ac447e668d

Headers

X-Polytomic-Versionstring

Request body

activeboolean

Whether the sync is enabled and scheduled.

encryption_passphrasestring

Passphrase for encrypting the sync data.

filter_logicstring

Logical expression to combine filters.

mode'create' | 'update' | 'updateOrCreate' | 'replace' | 'append' | 'remove' | 'snapshot' required
namestring required
only_enrich_updatesboolean

Whether to use enrichment models as a source of possible changes to sync. If true, only changes to the base models will cause a record to sync.

organization_idstring uuid nullable

Organization ID for the sync; read-only with a partner key.

policiesstring[] nullable
skip_initial_backfillboolean

Whether to skip the initial backfill of records; if true only records seen after the sync is enabled will be synced.

sync_all_recordsboolean

Whether to sync all records from the source, regardless of whether they've changed since the previous execution.

Example request

{
  "active": true,
  "fields": [
    {
      "override_value": "fixed_value",
      "source": {
        "field": "id",
        "model_id": "248df4b7-aa70-47b8-a036-33ac447e668d"
      },
      "sync_mode": "create",
      "target": "name"
    }
  ],
  "filter_logic": "A and B or C",
  "filters": [
    {
      "field": {
        "field": "id",
        "model_id": "248df4b7-aa70-47b8-a036-33ac447e668d"
      },
      "field_id": "field1",
      "label": "A",
      "value": "value"
    }
  ],
  "identity": {
    "remote_field_type_id": "string",
    "source": {
      "field": "id",
      "model_id": "248df4b7-aa70-47b8-a036-33ac447e668d"
    },
    "target": "name"
  },
  "name": "Users Sync",
  "organization_id": "248df4b7-aa70-47b8-a036-33ac447e668d",
  "override_fields": [
    {
      "override_value": "fixed_value",
      "source": {
        "field": "id",
        "model_id": "248df4b7-aa70-47b8-a036-33ac447e668d"
      },
      "sync_mode": "create",
      "target": "name"
    }
  ],
  "overrides": [
    {
      "field": {
        "field": "id",
        "model_id": "248df4b7-aa70-47b8-a036-33ac447e668d"
      },
      "field_id": "field1",
      "override": "new_value",
      "value": "value"
    }
  ],
  "policies": [
    "248df4b7-aa70-47b8-a036-33ac447e668d"
  ],
  "schedule": {
    "connection_id": "248df4b7-aa70-47b8-a036-33ac447e668d",
    "day_of_month": "1",
    "day_of_week": "monday",
    "hour": "12",
    "minute": "30",
    "month": "1",
    "run_after": {
      "bulk_sync_ids": [
        "248df4b7-aa70-47b8-a036-33ac447e668d"
      ],
      "sync_ids": [
        "248df4b7-aa70-47b8-a036-33ac447e668d"
      ]
    }
  },
  "target": {
    "configuration": {
      "key": "value"
    },
    "connection_id": "248df4b7-aa70-47b8-a036-33ac447e668d",
    "create": {
      "name": "value"
    },
    "object": "Users",
    "search_values": {
      "name": "value"
    }
  }
}

Response

OK

Example response

{
  "data": {
    "active": true,
    "created_by": {
      "id": "12345678-1234-1234-1234-123456789012",
      "name": "John Doe",
      "type": "user"
    },
    "fields": [
      {
        "override_value": "fixed_value",
        "source": {
          "field": "id",
          "model_id": "248df4b7-aa70-47b8-a036-33ac447e668d"
        },
        "sync_mode": "create",
        "target": "name"
      }
    ],
    "filters": [
      {
        "field": {
          "field": "id",
          "model_id": "248df4b7-aa70-47b8-a036-33ac447e668d"
        },
        "field_id": "field1",
        "label": "A",
        "value": "value"
      }
    ],
    "id": "248df4b7-aa70-47b8-a036-33ac447e668d",
    "identity": {
      "remote_field_type_id": "string",
      "source": {
        "field": "id",
        "model_id": "248df4b7-aa70-47b8-a036-33ac447e668d"
      },
      "target": "name"
    },
    "name": "Users Sync",
    "organization_id": "248df4b7-aa70-47b8-a036-33ac447e668d",
    "override_fields": [
      {
        "override_value": "fixed_value",
        "sync_mode": "create",
        "target": "name"
      }
    ],
    "overrides": [
      {
        "field": {
          "field": "id",
          "model_id": "248df4b7-aa70-47b8-a036-33ac447e668d"
        },
        "field_id": "field1",
        "override": "new_value",
        "value": "value"
      }
    ],
    "policies": [
      "248df4b7-aa70-47b8-a036-33ac447e668d"
    ],
    "schedule": {
      "connection_id": "248df4b7-aa70-47b8-a036-33ac447e668d",
      "day_of_month": "1",
      "day_of_week": "monday",
      "hour": "12",
      "minute": "30",
      "month": "1",
      "run_after": {
        "bulk_sync_ids": [
          "248df4b7-aa70-47b8-a036-33ac447e668d"
        ],
        "sync_ids": [
          "248df4b7-aa70-47b8-a036-33ac447e668d"
        ]
      }
    },
    "target": {
      "configuration": {
        "key": "value"
      },
      "connection_id": "248df4b7-aa70-47b8-a036-33ac447e668d",
      "create": {
        "name": "value"
      },
      "object": "Users",
      "search_values": {
        "name": "value"
      }
    },
    "updated_by": {
      "id": "12345678-1234-1234-1234-123456789012",
      "name": "John Doe",
      "type": "user"
    }
  }
}