Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 16 additions & 2 deletions source/reference/method/db.getUser.txt
Original file line number Diff line number Diff line change
Expand Up @@ -127,10 +127,24 @@ Required Access
Example
-------

The following sequence of operations returns information about the
``appClient`` user on the ``accounts`` database:
The following operations return information about an example
``appClient`` user in an ``accounts`` database:

.. code-block:: javascript

use accounts
db.getUser("appClient")

Example output:

.. code-block:: javascript
:copyable: false

{
_id: 'accounts.appClient',
userId: UUID("1c2fc1bf-c4dc-4a22-8b04-3971349ce0dc"),
user: 'appClient',
db: 'accounts',
roles: [],
mechanisms: [ 'SCRAM-SHA-1', 'SCRAM-SHA-256' ]
}