Skip to main content
POST
/
api
/
admin
/
users
/
merge
Merge a source user into a target user
curl --request POST \
  --url https://pria.praxislxp.com/api/admin/users/merge \
  --header 'Content-Type: application/json' \
  --header 'x-access-token: <api-key>' \
  --data '
{
  "sourceUserId": "<string>",
  "targetUserId": "<string>",
  "dryRun": false,
  "confirm": true
}
'
{
  "success": true,
  "summary": {}
}

Authorizations

x-access-token
string
header
required

JWT token passed in x-access-token header

Body

application/json
sourceUserId
string
required

The user to merge FROM. Hard-deleted on a successful apply; must not be a super-admin.

targetUserId
string
required

The user to merge INTO (survives). Every ref:'user' on the source is repointed here.

dryRun
boolean
default:false

When true, returns the preview (per-collection counts + conflicts) and writes nothing.

confirm
boolean

Required (true) to APPLY a merge (when dryRun is not true). Forces dry-run-then-confirm.

Response

Preview (dryRun) or merge result

success
boolean
mode
enum<string>
Available options:
merge,
dryRun
summary
object

On dryRun: the preview. On apply: { success, repointed, institutions, credits, auditId }.