duplicate
The duplicate function is used to log in as another user. It duplicates the active session.
svc=core/duplicate¶ms={"operateAs":"<text>",
"continueCurrentSession":<bool>,
"appName":"<text>",
"checkService":"<text>"}
Parameters
Name | Description |
---|---|
operateAs | The name of the user on whose behalf you want to log in to the system. The parameter should be empty if you want to log in as the main user. |
continueCurrentSession | The parameter defines whether the previous session should be continued. Possible values:
|
appName | An optional possibility to rename the app in the duplicated session. |
checkService | An optional possibility to validate the billing service of the current user. |
To get information about the current session without generating a new session, use the duplicate function with the following parameter:
svc=core/duplicate¶ms={"restore": 1}
Returned result
The format of the returned result is the same as for the login function.
Possible error codes:
Code | Description |
---|---|
1003 | No session. |
8 | Failed to fetch the subordinate user (the operateAs parameter) or failed to set the token ACLs for the new session. |
7 | Access denied due to the billing rules (only for the checkService parameter). |
1 | Invalid session. |