Export and import login flows
You can export and import login flow definitions to back them up, copy them to another environment, create duplicates, or restore a previous version. These features are available through the Management Service API.
Before you begin
To call the export and import endpoints, you need a valid access token from an M2M (machine-to-machine) client configured in the access admin console with the following settings:
| Requirement | Value |
|---|---|
| Audience | ujo-management |
| Scope — Export | ujo-management:journeys:get |
| Scope — Import (all modes) | ujo-management:journeys:post |
For information about configuring an M2M client in the Access component, see M2M clients.
Export a login flow
To export a login flow, send a GET request:
GET /ujo-management-service/api/v1/journeys/{id}/export
Replace {id} with the journey ID of the login flow that you want to export. You can find the journey ID on the Login flows page in the OneWelcome Identity Platform console.
The response includes the complete login flow definition — steps, transitions, conditions, and settings — together with export metadata:
{
"exportMetadata": {
"exportDate": "2026-01-12T16:18:00Z",
"schemaVersion": "1.0"
},
"id": "550e8400-e29b-41d4-a716-446655440000",
"name": "Standard login",
"blocks": [ ... ],
"sequenceFlows": [ ... ],
"conditionGroups": [ ... ],
"settings": { ... }
}
Notes on exported content
- The export always reflects the current saved state of the login flow, including unpublished changes.
- The
archivedflag is not included in the export. Importing a flow always creates or restores it in an active (non-archived) state. - The export payload can be used directly as the request body for any of the import endpoints.
The endpoint returns 404 if the journey ID is not found.
Import a login flow
The following three modes for importing login flows are available:
| Mode | Endpoint | Use case |
|---|---|---|
| Duplicate | POST /ujo-management-service/api/v1/journeys/import?mode=duplicate |
Create a copy with a new ID |
| Restore | POST /ujo-management-service/api/v1/journeys/import?mode=restore |
Bring back a flow under its original ID |
| Overwrite | POST /ujo-management-service/api/v1/journeys/{id}/import?mode=overwrite |
Replace an existing flow |
All import endpoints accept the export payload as the request body.
Note
By default, all import operations run in dry-run mode (dryRun=true), which validates the import and returns any warnings without making changes. Set dryRun=false to apply the import.
Duplicate mode
Duplicate mode creates a new login flow with a freshly generated ID. The flow ID in the payload is ignored. Use this mode to create a copy of a flow in the same environment.
POST /ujo-management-service/api/v1/journeys/import?mode=duplicate
duplicate is the default mode. If you omit the mode parameter, the endpoint behaves as duplicate.
The resulting flow is unpublished.
The default flag in the source payload is ignored.
Restore mode
Restore mode recovers a login flow using the flow ID from the export payload.
POST /ujo-management-service/api/v1/journeys/import?mode=restore
| Target state | Result |
|---|---|
| Flow ID does not exist | 201 Created — flow created with the original ID |
| Flow ID exists and flow is inactive | 200 OK — flow definition replaced |
| Flow ID exists and flow is active | 409 Conflict — use Overwrite instead |
The default flag in the source payload is ignored.
Overwrite mode
Overwrite mode replaces an existing login flow while preserving its identity and operational state.
POST /ujo-management-service/api/v1/journeys/{id}/import?mode=overwrite
- Journey ID — unchanged (determined by the path parameter, not the payload)
- Default flag — unchanged (the source payload's
defaultflag is always ignored) - Publishing state — unchanged
If the target flow is currently published, the endpoint returns 409 Conflict to prevent silent disruption of active authentication. To proceed, add force=true:
POST /ujo-management-service/api/v1/journeys/{id}/import?mode=overwrite&force=true
With force=true, the overwrite proceeds and the target's default flag and publishing state are preserved.
Preview an import action
All import endpoints default to dryRun=true. In dry-run mode, the endpoint validates the import and returns any warnings or errors, but does not save any changes.
| Parameter | Value | Behavior |
|---|---|---|
dryRun |
true (default) |
Validate only. Do not save changes. |
dryRun |
false |
Apply the import and save changes |
Always implement a dry run first to review warnings before you commit an import:
POST /ujo-management-service/api/v1/journeys/import?mode=duplicate&dryRun=true
Template updates during import
When you import a login flow, the steps are updated to the latest compatible version of each step-template. That is, the steps are re-created using the latest minor version associated with the major version that was used in the exported flow.
The import response includes a warning that describes any version changes:
| Code | Severity | Meaning |
|---|---|---|
NEWER_MINOR_VERSION_AVAILABLE |
Warning | The step was automatically updated to a newer minor version. No action required. |
MAJOR_VERSION_CONFLICT |
Error | The step references an outdated major version that is not compatible with the current platform. You must upgrade the step manually before the flow can be used. |
{
"warning": {
"code": "STEP_VERSION_IMPORT_VALIDATION",
"message": "Step version validation detected issues during journey import",
"validationErrors": [
{
"stepId": "550e8400-e29b-41d4-a716-446655440000",
"stepName": "Password",
"functionId": "login.password",
"field": "version",
"code": "NEWER_MINOR_VERSION_AVAILABLE",
"severity": "warning",
"currentVersion": "1.1",
"availableVersion": "1.2",
"message": "Step was updated to the latest minor version."
},
{
"stepId": "7f3c4e12-9a8b-4d5e-a1c3-2b6d8e4f9a7c",
"stepName": "Google",
"functionId": "login.idbroker.identify",
"field": "version",
"code": "MAJOR_VERSION_CONFLICT",
"severity": "error",
"currentVersion": 1,
"availableVersion": 3,
"message": "Major version conflict detected. The imported step uses an outdated template that may be incompatible.",
"action": "UPGRADE_REQUIRED"
}
],
"summary": {
"totalSteps": 2,
"warnings": 1,
"errors": 1
},
"timestamp": "2026-01-12T16:18:00Z"
}
}