> ## Documentation Index
> Fetch the complete documentation index at: https://docs.enginy.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Users

> Fetch users/owners for assignment (optional endpoint)

<Card title="Your Implementation Required" icon="triangle-exclamation" color="#f59e0b">
  This endpoint must be implemented on **your server**
</Card>

<Info>
  **Optional Endpoint**: This endpoint is optional. If not implemented, Enginy will gracefully disable owner
  selection features. Return `404`, `501`, or `405` to indicate the endpoint is not available.
</Info>

Enginy calls this endpoint to fetch the list of users/owners that can be assigned to contacts, companies, tasks, and activities in your CRM.

## Detection

When you connect your Custom CRM to Enginy, we test this endpoint:

* **2xx response** - Users feature enabled, owner selection available in exports
* **404/501/405** - Users feature disabled gracefully (not an error)
* **Other errors** - Users feature disabled, connection proceeds normally

## Request

No request body required. Enginy will send the API key in the configured header.

<RequestExample>`bash GET /users X-API-Key: your-api-key `</RequestExample>

## Response

Return an array of user objects.

<ResponseField name="id" type="string" required>
  Unique identifier for the user in your CRM
</ResponseField>

<ResponseField name="name" type="string" required>
  Display name of the user
</ResponseField>

<ResponseField name="email" type="string">
  Email address of the user (optional, used for display)
</ResponseField>

<ResponseExample>
  ```json theme={null}
  [
    {
      "id": "user-123",
      "name": "John Smith",
      "email": "john@example.com"
    },
    {
      "id": "user-456",
      "name": "Jane Doe",
      "email": "jane@example.com"
    },
    {
      "id": "user-789",
      "name": "Sales Bot"
    }
  ]
  ```
</ResponseExample>

## Error Responses

| Status | Meaning                                             |
| ------ | --------------------------------------------------- |
| `200`  | Success - users returned                            |
| `401`  | Invalid or missing API key                          |
| `404`  | Endpoint not implemented (disables owner selection) |
| `405`  | Method not allowed (disables owner selection)       |
| `501`  | Not implemented (disables owner selection)          |
| `500`  | Server error                                        |

<Tip>
  If you don't want to support owner selection, simply don't implement this endpoint or return `404`. Enginy
  will detect this during connection and hide owner-related UI elements.
</Tip>

## Usage

When users are available, Enginy shows an owner dropdown in:

* Export modal (assign owner to exported contacts)
* Task creation (assign task owner)
* Activity logging (associate activities with owners)

The `id` field from your response will be sent back when creating tasks or activities that should be assigned to a specific owner.
