> ## Documentation Index
> Fetch the complete documentation index at: https://docs.chift.eu/llms.txt
> Use this file to discover all available pages before exploring further.

# Run a sync manually

Chift runs each flow of a sync on its trigger. You can also start an execution yourself, and pass options to select the period, to export data again, or to test without writing. This page applies to all syncs.

New to the model? Read [What is a sync?](https://docs.chift.eu/syncs/overview.md) first.

## Start an execution

You can start an execution in two ways:

* **From the Platform:** open the consumer page and click the play button next to the sync. See [Trigger an execution](https://docs.chift.eu/platform/advanced/syncs/trigger-an-execution.md).
* **With the API:** call `POST /syncs/{syncid}/flows/{flowid}/execute`.

```bash theme={null}
curl -X POST https://api.chift.eu/syncs/{syncid}/flows/{flowid}/execute \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "consumers": ["your-consumer-id"],
    "settings": {
      "force_from_date": "2026-10-01",
      "force_to_date": "2026-10-31"
    }
  }'
```

| Field | Notes |
| - | - |
| `consumers` | The consumer IDs, or the single value `all` for every consumer of the sync. `all` is not available on marketplace accounts. |
| `settings` | The options of the execution. Options apply to one consumer: pass exactly one consumer ID with them. |
| `preflight` | `true` checks the request and starts nothing. See [Check a request first](#check-a-request-first). |

Without `settings`, the flow runs as configured for each consumer. The response returns the `chainexecutionid`, the `resolved_settings` and the `warnings` of the execution.

> [!NOTE]
>
> Chift runs one execution at a time for a flow and a consumer. A request during a running execution returns a `409` with `ERROR_EXECUTION_ALREADY_RUNNING`.

[API reference: Run a flow now ↗](https://docs.chift.eu/api-reference/endpoints/syncs/run-a-flow-now.md)

## Options

The options are the same for all syncs. Each option controls one thing and does not change the others.

![Four cards. Period: two dates, from and to. When empty, the execution goes from the last execution up to today. Synchronised data (import\_mode): only what is missing or failed (default), or everything in the period, again. A re-import needs both dates and deletes nothing. Writes (write\_mode): write normally (default), write nothing and report only, or write nothing and record a preview. Logs (verbose\_logs): detailed logs, off by default. Errors, warnings and information are always logged.](https://mintcdn.com/chift/I3RPpVNIg8r7IkKj/assets/docs/syncs/sync-manual-execution-options.png?fit=max\&auto=format\&n=I3RPpVNIg8r7IkKj\&q=85\&s=0646ad9bb407ee5cabf19f22cf95e5d1)

The four common options of a manual execution, with their default values.

> [accordion] Period: force\_from\_date and force\_to\_date
>
> `force_from_date` is the first day of the period. The execution starts from this date instead of the point where the last execution stopped. It ignores the lookback limit of the sync and the start date of the configuration.
>
> `force_to_date` is the last day of the period. The execution stops at this date instead of today.
>
> Both dates use the format `YYYY-MM-DD`. A forced period does not move the cursor of the sync, so the next scheduled execution is not affected.

> [accordion] Synchronised data: import\_mode
>
> * `normal` (default): the execution exports only the data that is missing or failed.
> * `force_reimport`: the execution exports everything in the period again, also the data that is already synchronised.
>
> `force_reimport` needs both `force_from_date` and `force_to_date`. Without them, the request returns a `422`.
>
> A re-import never deletes data in the target software. See [Export a period again](#export-a-period-again).

> [accordion] Writes: write\_mode
>
> * `normal` (default): the execution writes in the target software.
> * `debug`: the execution writes nothing. It reports what the next real execution would do.
> * `preview`: the execution writes nothing and records what it would create. It needs both `force_from_date` and `force_to_date`. Only the flows that allow previews accept it. See [Ledger preview](https://docs.chift.eu/platform/advanced/syncs/ledger-preview.md).
>
> The write mode does not change the period or the data that the execution skips.

> [accordion] Logs: verbose\_logs
>
> `true` adds the debug logs to the execution logs. The default is `false`. Errors, warnings and information are always logged.

> [accordion] Options of one sync
>
> A sync can add its own options. For example, `location_ids` limits an execution of the POS sync or the PMS sync to some locations.
>
> Pass these options in `settings`, next to the common options. [List the options of a flow](#list-the-options-of-a-flow) to find them.

## Common cases

These are the requests for the most frequent needs. Each example shows the `settings` object only.

### Import the missing data now

Send no `settings`. The execution does the same as a scheduled execution: it exports what is missing or failed.

### Import a period that was skipped or failed

Pass the two dates of the period. The execution exports only what is missing or failed in this period.

```json theme={null}
{
  "force_from_date": "2026-10-01",
  "force_to_date": "2026-10-31"
}
```

### Export a period again

Pass the two dates and `force_reimport`. The execution exports everything in the period again.

```json theme={null}
{
  "force_from_date": "2026-10-01",
  "force_to_date": "2026-10-31",
  "import_mode": "force_reimport"
}
```

> [!WARNING]
>
> A re-import does not remove the data that the sync already created in the target software. Remove this data in the target software first, or the re-import creates duplicates. First confirm with the end-user that a re-import is safe.

### Test without writing

Pass `debug`. The execution writes nothing and reports what the next real execution would do.

```json theme={null}
{
  "write_mode": "debug"
}
```

## Check a request first

Send the same request with `"preflight": true` to check it before you run it. Chift checks the request the same way and starts nothing.

* `blocked` is `true` when the same request, sent for real, is refused.
* `warnings` lists what you need to know. Each warning has a `code`, a `message` and a `blocking` flag.

| Warning code | Meaning |
| - | - |
| `FORCE_REIMPORT_WILL_REBOOK` | The period is exported again. The data already created in the target software is not removed. |
| `DEBUG_WRITES_NOTHING` | Nothing is written. The execution only reports. |
| `PREVIEW_WRITES_NOTHING` | Nothing is written. The execution records what it would create. |

A real execution returns the same warnings in its response.

## List the options of a flow

Not every sync accepts every option. Call `GET /syncs/{syncid}/flows/{flowid}/settings` to read the options that a flow accepts.

```bash theme={null}
curl "https://api.chift.eu/syncs/{syncid}/flows/{flowid}/settings" \
  -H "Authorization: Bearer YOUR_ACCESS_TOKEN"
```

| Field | Meaning |
| - | - |
| `configurable` | `true` when the flow declares the options it accepts. `false` when the flow does not use these options yet: run it with the deprecated event route instead. |
| `groups` | The groups of options: period, what gets written, already synchronised data, logs and scope. |
| `settings` | The options that the flow accepts, each with its key, type, default value, options, title and explanation. The options that the flow cannot apply are not listed. |

Use the `language` query parameter to select the language of the titles and the explanations. The default is English.

A request with an option that the flow cannot apply returns a `422` with `ERROR_SETTING_NOT_APPLICABLE`. The message names the option.

For a flow with `configurable` at `false`, see [Send a custom event for a specific flow (deprecated)](https://docs.chift.eu/api-reference/endpoints/syncs/send-a-custom-event-for-a-specific-flow-deprecated.md).

[API reference: Settings this flow accepts when you run it ↗](https://docs.chift.eu/api-reference/endpoints/syncs/settings-this-flow-accepts-when-you-run-it.md)

## Related

* [Monitor executions](https://docs.chift.eu/syncs/monitor-executions.md)
* [Trigger an execution from the Platform](https://docs.chift.eu/platform/advanced/syncs/trigger-an-execution.md)
* [Sync errors](https://docs.chift.eu/home/errors.md#sync-errors)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.