---
title: "Create Home owner"
method: POST
path: "/api/v4/users"
tags: ["Home Owner"]
---

# Create Home owner

`POST /api/v4/users`

## Request

- Base URL: `https://api-qa2.enphaseenergy.com`
- URL: `https://api-qa2.enphaseenergy.com/api/v4/users`
- Auth: none declared
- TypeScript: <https://skmtc.dev/enphase/apis/commissioning-api/docs/api/v4/users/post.ts> (a function with typed inputs; its response is checked against the schema)

Create a home owner user. Email, First Name, and Last Name are mandatory fields in the user. Any unneeded fields passed in the request parameter will be skipped and not stored.
Pass body param in 'application/x-www-form-urlencoded' format, in this endpoint, key will be 'user' and value will be a JSON dictionary of user fields. Using this API to create both homeowner as well as a company user. If you want to create company user, then pass company_id inside the user object.

## Request body `application/x-www-form-urlencoded`

- object
  - `email` string, required: The email address of the user. Must be unique within Enlighten. Required
  - `enlighten_emails` boolean: Whether the user receives automated emails from Enlighten. Default false.
  - `enlighten_view` string: Which view of Enlighten the user has. Options 'my' for MyEnlighten, 'manager' for Enlighten Manager. Default 'my'. Users who do not belong to companies should be set to 'my'. You must have an agreement with Enphase Energy to set a user to 'manager'. Company id is required when enlighten_view is 'manager'
  - `first_name` string, required: The user's first name. Required
  - `last_name` string, required: The user's last name. Required
  - `phone` string: The telephone number of the user. Optional. Max length 255.
  - `company_id` integer: The Enlighten-generated ID of the company to which the user belongs, if any.

## Response `201`

Created

- object
  - `active` boolean: Whether the user is allowed to log in to Enlighten.
  - `user_roles` string[]: What type of user this is in Enlighten. Possible values are ['self_installer']. For self installer user user_roles will be ['self_installer']. For other users user_roles will be empty.
  - `email` string: The email address of the user
  - `enlighten_emails` boolean: Whether the user receives automated emails from Enlighten
  - `enlighten_view` string: Which view of Enlighten the user has
  - `first_name` string: The user's first name
  - `last_name` string: The user's last name
  - `phone` string: The telephone number of the user.
  - `uri` string: URI to the show() method for the user. System-generated.
  - `user_id` integer: The Enlighten ID of the user. System-generated.
  - `updated_at` integer: Last updated date and time in Epoch format.

## Other responses

- `401`: Unauthorized
- `405`: Method Not Allowed
- `422`: Unprocessable entity. The body contains error information in a hash of errorMessages and an optional errorCode
- `429`: Too Many Requests
- `501`: Not Implemented

---

[API](https://skmtc.dev/enphase/apis/commissioning-api.md) - [All operations](https://skmtc.dev/enphase/apis/commissioning-api/llms.txt) - [OpenAPI document](https://skmtc.dev/enphase/apis/commissioning-api/revisions/73a4001046e2?raw)
