---
updatedAt: 2026-01-05T23:40:05.000Z
---

# Retrieves a user from the provided username. This route is admin-only.

Retrieves a user from the provided username. This route is admin-only.

# OpenAPI definition

```json
{
  "openapi": "3.0.0",
  "info": {
    "title": "LogRhythm Network Monitor API",
    "version": "v1",
    "description": "Network Monitor REST API communicates over HTTPS using JSON. The available routes and methods can be used to get session information, general appliance information, capture configurations, as well as download PCAPs and reconstructed file attachments. API requests will be done on behalf of an API account, identified by the API token passed in with each request. **The base URL (/api) should be prefixed to each API path below.**"
  },
  "paths": {
    "/users/{username}": {
      "get": {
        "operationId": "getUser",
        "summary": "Retrieves a user from the provided username. This route is admin-only.",
        "security": [
          {
            "bearerAuth": []
          }
        ],
        "parameters": [
          {
            "$ref": "#/components/parameters/username"
          }
        ],
        "description": "Retrieves a user from the provided username. This route is admin-only.",
        "responses": {
          "200": {
            "description": "Details for the requested user.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/UserResponse"
                }
              }
            }
          },
          "default": {
            "description": "In case of an error, an error payload containing error code, name, and description is returned.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ErrorObject"
                }
              }
            }
          }
        }
      }
    }
  },
  "servers": [
    {
      "url": "https://localhost:3000/api"
    }
  ],
  "components": {
    "parameters": {
      "username": {
        "in": "path",
        "name": "username",
        "required": true,
        "description": "Username of the user on which you want to perform the operation.",
        "schema": {
          "type": "string"
        }
      }
    },
    "securitySchemes": {
      "bearerAuth": {
        "type": "oauth2",
        "description": "API requests are authenticated using HTTP Bearer Authorization. The Token is generated that user, which can be found in the API Token panel that appears at the top of the User tab under the Configuration top navigation option. Certain routes may be restricted to the admin user.",
        "flows": {
          "implicit": {
            "authorizationUrl": "localhost:3000",
            "scopes": {}
          }
        }
      }
    },
    "schemas": {
      "ErrorObject": {
        "properties": {
          "statusCode": {
            "type": "integer",
            "description": "HTTP status code associated with the error."
          },
          "name": {
            "type": "string",
            "description": "HTTP message associated with the HTTP status code."
          },
          "message": {
            "type": "string",
            "description": "Description of the error returned by Network Monitor. This field can contain one or more error messages."
          }
        }
      },
      "UserResponse": {
        "type": "object",
        "properties": {
          "username": {
            "type": "string",
            "description": "The user's unique username."
          },
          "firstName": {
            "type": "string",
            "description": "The user's first name."
          },
          "lastName": {
            "type": "string",
            "description": "The user's last name."
          },
          "email": {
            "type": "string",
            "description": "The user's email address."
          },
          "lastModifiedDate": {
            "type": "string",
            "description": "The ISO 8601 timestamp of when the user was last edited."
          },
          "passwordExpirationDate": {
            "type": "string",
            "description": "The ISO 8601 timestamp of when the user's password will expire."
          },
          "role": {
            "type": "string",
            "description": "The role that determines the user's access permissions. Either 'admin' or 'analyst'."
          }
        }
      }
    }
  }
}
```