<!-- Generated by scripts/build-docs.js. Edit docs/swagger.yaml or docs/guides/, then run `npm run docs:build`. -->

# Get one employee

`GET https://{apiId}.execute-api.us-west-1.amazonaws.com/{stage}/v1/users/{id}`

Module: Users · operationId: `getUser` · Auth: `Authorization: Bearer <token>`
Web page: https://apidocs.sequipay.com/#/api/get-user

Returns a single employee by id, scoped to the authenticated company. A terminated employee is reachable by id (only the default list hides them); soft-deleted and draft employees are not.

Requires the `users:read` scope.

## Path parameters

- `id` (integer (int64), **required**): The employee's numeric id. Minimum: 1. Example: `1024`.

## Example request

```bash
curl -X GET "https://{apiId}.execute-api.us-west-1.amazonaws.com/{stage}/v1/users/1024" \
  -H "Authorization: Bearer $SEQUIFI_TOKEN"
```

## Responses

### 200: The employee.

- `status` (integer) Example: `200`.
- `message` (string) Example: `success`.
- `data` (object): A company employee. Core fields the legacy API could not back are omitted rather than faked; sensitive Core columns (SSN, bank, compensation) are never returned.
  - `id` (integer (int64)) Example: `1024`.
  - `first_name` (string) Example: `Alice`.
  - `last_name` (string) Example: `Nguyen`.
  - `middle_name` (string, nullable) Example: `R`.
  - `name_suffix` (string, nullable) Example: `Jr`.
  - `email` (string (email), nullable) Example: `alice@acme.com`.
  - `worker_type` (string): Employment classification (Core `classification`). Example: `w2`.
  - `dob` (string (date), nullable) Example: `1990-05-01`.
  - `mobile_no` (string, nullable) Example: `555-0100`.
  - `home_address_line_1` (string, nullable) Example: `1 Main St`.
  - `home_address_line_2` (string, nullable) Example: `Apt 4`.
  - `home_address_city` (string, nullable) Example: `Austin`.
  - `home_address_state` (string, nullable) Example: `TX`.
  - `home_address_zip` (string, nullable) Example: `78701`.
  - `position_id` (integer (int64), nullable) Example: `7`.
  - `position_name` (string, nullable) Example: `Sales Rep`.
  - `status` (string): Derived from the end date — `inactive` once it has passed. One of: `active`, `inactive`.
  - `onboarding_complete` (boolean): True when the employee has verification steps and all are complete.
  - `start_date` (string (date), nullable) Example: `2024-01-15`.
  - `end_date` (string (date), nullable)
  - `pay_type` (string) Example: `salary`.
  - `created_at` (string (date-time), nullable) Example: `2024-01-15T12:00:00.000Z`.
  - `updated_at` (string (date-time), nullable) Example: `2024-06-01T09:30:00.000Z`.

### 400: The id is not a positive integer.

```json
{
  "status": 400,
  "message": "invalid user id",
  "data": null
}
```

### 401: Missing, invalid, expired, or revoked token (from the authorizer).

### 403: The token lacks the required scope.

```json
{
  "error": "insufficient_scope",
  "required": "users:read"
}
```

### 404: No such employee for this company.

```json
{
  "status": 404,
  "message": "not found",
  "data": null
}
```

### 500: An infrastructure or data error. The endpoint fails closed — a 500, never a partial or empty-looking result.

```json
{
  "status": 500,
  "message": "internal error",
  "data": null
}
```
