---
title: "Create a single or shared user with the specified data"
method: POST
path: "/users"
tags: ["Users"]
---

# Create a single or shared user with the specified data

`POST /users`

## Request

- Base URL: `https://api.kontainer.com/jsonapi/v2`
- URL: `https://api.kontainer.com/jsonapi/v2/users`
- Auth: HTTP bearer
- TypeScript: <https://skmtc.dev/kontainer/apis/kontainer-api-documentation/docs/users/post.ts> (a function with typed inputs; its response is checked against the schema)

## Create User
Endpoint for creating a User.

A `normal` user (the default) requires a `name` and an `email`. A `shared` user requires a `name`, `username` and `password`; its `email` is optional and it must not set `isClientAdmin`. Creating a `shared` user requires the shared users feature to be enabled for the client, otherwise the request is rejected with a 403.

When `sendInvite` is true and the created user has an email, an invite (welcome) email containing the invite link is sent.

## Query parameters

- `sendInvite` string

## Request body

- object
  - `data` object, required
    - `type` string: Resource Type
    - `attributes` object: Attributes
      - `name` string: Name
      - `type` 'normal' | 'shared': User type. Defaults to `normal`. Use `shared` to create a shared user (requires the shared users feature).
      - `email` string: Email (must be unique across the organization). Required for `normal` users; optional for `shared` users.
      - `username` string: Login username. Required for `shared` users; must not be set for `normal` users.
      - `password` string, password: Login password. Required for `shared` users; must not be set for `normal` users.
      - `company` string: The title of the company the user is associated with
      - `active` boolean: You may create an inactive `normal` user. Ignored for `shared` users, which are always created active.
      - `show_brand_section` boolean: Show Contact Section in Folder Menu
      - `hide_menu_by_default` boolean: Hide content menu by default
      - `custom_metadata` string: Custom metadata on a user, visible in the user edit screen UI and also searchable
      - `internal_metadata` string: Internal metadata on a user, hidden and only accessible through JsonApi

## Response `201`

created

- UserResponse
  - `data` User
    - `id` string
    - `type` string
    - `attributes` UserAttributes
      - `name` string
      - `username` string
      - `email` string
      - `active` boolean
      - `last_login` union
        - string, date-time
        - 'Never'
      - `status` 'created' | 'invited' | 'verified': Invitation status of the user. `created` is the default state for a freshly created user. `invited` means the user has a non-expired invite/welcome email token. `verified` means the user has logged in at least once.
      - `is_client_admin` boolean
      - `is_delegated_admin` boolean
      - `is_adfs_user` boolean
      - `is_sso_user` boolean
      - `signature` string, nullable
      - `company` string
      - `expires` union: Wall clock in the client timezone, or `NEVER`
        - string
        - 'NEVER'
      - `type` 'normal' | 'shared' | 'admin' | 'direct-link'
      - `user_type` string: Deprecated: use `type` instead. Removal scheduled 2027-01-13.
      - `can_create_lightbox` boolean
      - `can_edit_profile` boolean
      - `can_post_comments` boolean
      - `can_folder_share` boolean
      - `can_internal_folder_share` boolean
      - `can_share_folders_and_files` boolean
      - `can_internal_folder_and_file_share` boolean
      - `can_direct_login` boolean
      - `show_brand_section` boolean
      - `hide_menu_by_default` boolean
      - `is_direct_link_user` boolean
      - `can_request_api` boolean
      - `notify_active` boolean
      - `notify_frequency` 0 | 1 | 2 | 3: How often notification emails are sent, in enum order: immediately, daily, weekly, monthly
      - `is_allowed_url_copy_with_direct_access` boolean
      - `custom_metadata` string
      - `internal_metadata` string

## Other responses

- `401`: Unauthorized
- `403`: Shared users are not enabled for this client
- `422`: Unprocessable Entity

---

[API](https://skmtc.dev/kontainer/apis/kontainer-api-documentation.md) - [All operations](https://skmtc.dev/kontainer/apis/kontainer-api-documentation/llms.txt) - [OpenAPI document](https://skmtc.dev/kontainer/apis/kontainer-api-documentation/revisions/b80a5167e09a?raw)
