exp:expusersessions
Available since Exponential 6.0.15 (in development, not in a release yet).
Summary
The tracked sessions of an account (Your devices): list them, end all of them or one, as an administrator does on user/sessions (ending is a dry run unless --apply)
Usage
./console exp:expusersessions [options] php bin/php/expusersessions.php [options] ./console exp:user:sessions [options]
Aliases
exp:user:sessions
Help
The output of ./console help exp:expusersessions (the script run with --help), without the standard options:
Usage: bin/php/expusersessions.php [OPTION]... [USER] The sessions of an account Lists the account's running sessions as Your devices shows them: id, how it signed in, device and browser, the approximate address and the last activity. --end ends all of them, --session=<id> ends one, as an administrator does on user/sessions; the person has to sign in again there. The audit records access.session.revoke. Without --apply nothing is ended. ./console exp:user:sessions jane ./console exp:user:sessions jane --end --apply ./console exp:user:sessions jane --session=812 --apply Options: --end End every tracked session of the account (Your devices) --session=VALUE End only the session with this id (from the list) --apply Make the change; without it the command only lists what it would change (a dry run) --dry-run The default, kept for scripts that pass it: list what would change, change nothing --as=VALUE Act as this user (login, e-mail or id; default the user of [UserSettings] UserCreatorID); the audit records it as who did it --format=VALUE text (default) or json (the machine output exp-user/1)
Options
| Option | Value | Description |
|---|---|---|
| --end | - | End every tracked session of the account (Your devices) |
| --session | required | End only the session with this id (from the list) |
| --apply | - | Make the change; without it the command only lists what it would change (a dry run) |
| --dry-run | - | The default, kept for scripts that pass it: list what would change, change nothing |
| --as | required | Act as this user (login, e-mail or id; default the user of [UserSettings] UserCreatorID); the audit records it as who did it |
| --format | required | text (default) or json (the machine output exp-user/1) |
Arguments
[user]
Standard options
Every script also takes the standard options of the script framework: --help, --quiet, --siteaccess, --debug, --colors, --no-colors, --logfiles, --no-logfiles, --verbose and --allow-root-user.
Source
bin/php/expusersessions.php, kernel/private/classes/commands/expusersessions.php
See also
Generated example: exp:expusersessions
Added to the reference for Exponential 6.0.15.
Contributors
- Graham Brookins Updated
Comments
Add a comment