---
title: "Create User"
method: POST
path: "/setup/user"
tags: ["Organizations"]
---

# Create User

`POST /setup/user`

Create a new user and link it to the creator's organization (the organization ID from the personal token attached to the API call). If the role is a viewer, the user is also linked to the default account for the organization.

## Query parameters

- `generateToken` boolean

## Request body

- object
  - `firstName` string — The first name of the user. Note: names cannot include these characters: + = @
  - `lastName` string — The last name of the user. Note: names cannot include these characters: + = @
  - `email` string — Email
  - `password` string — Password
  - `role` string — User's role

## Response `200`

Create User Response

- object
  - `request` object — Original request properties
    - `id` string — Unique ID associated with this request
    - `url` string — The URL that was used for the request
    - `method` string — The HTTP **METHOD** used for the request
    - `timestamp` string — When the request was received by Spot
  - `response` object — Response package that includes, status, type and any relevant data.
    - `status` object
      - `code` integer — HTTP status code assigned to this response
      - `message` string — HTTP status message for the respective status code
    - `kind` string — The data type of each item in the response
    - `items` object[] — Array of data objects
      - `id` integer — User's old ID (DEPRECATED)
      - `firstName` string — First Name
      - `lastName` string — Last Name
      - `displayName` string — First Name + Last Name
      - `email` string — Email
      - `organizationId` integer — ID of Organization in Spot Console
      - `personalAccessToken` integer — ID of Organization in Spot Console
      - `userId` string — User's ID
    - `count` integer — Size of the data object array

## Other responses

- `400` — Bad Request

---

[API](https://skmtc.net/spot/apis/spot-by-flexera-api.md) · [All operations](https://skmtc.net/spot/apis/spot-by-flexera-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/spot/spot-by-flexera-api/versions/2e5445f30576/schema)
