Skip to content

Run settings migration

POST
/api/admin/settings/migrate
Code sample: Shell / cURL
curl --request POST \
--url https://auth.example.com/api/admin/settings/migrate \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "dryRun": true, "categories": [ "login", "security" ] }'

Dry-run or execute migration from legacy settings keys to v2 settings keys.

Execute or dry-run v1 to v2 settings migration.

Media type application/json
object
dryRun
required
boolean
categories
Array<string>
Example
{
"dryRun": true,
"categories": [
"login",
"security"
]
}

Settings migration result.

Media type application/json
object
dryRun
required
boolean
timestamp
required
string
changes
required
Array<object>
object
key
string
new_key
string
action
string
Allowed values: set skip conflict
category
string
reason
Any of:
string
summary
required
object
total
integer format: int64
set
integer format: int64
skipped
integer format: int64
conflicts
integer format: int64
warnings
required
Array<string>
errors
required
Array<string>
Example
{
"dryRun": true,
"timestamp": "2026-02-01T00:00:00.000Z",
"changes": [
{
"key": "settings:tenant:tenant_123:login",
"new_key": "settings:v2:tenant:tenant_123:login",
"action": "set",
"category": "login",
"reason": null
}
],
"summary": {
"total": 1,
"set": 1,
"skipped": 0,
"conflicts": 0
},
"warnings": [],
"errors": []
}

Error response.

Media type application/json
object
error
string
message
string
error_description
string
key
additional properties
Example generated
{
"error": "example",
"message": "example",
"error_description": "example"
}