---
title: "Create a new user. Only avaialble to admin user."
method: POST
path: "/accounts"
tags: ["User Management"]
---

# Create a new user. Only avaialble to admin user.

`POST /accounts`

## Request body

- AccountCreationRequest — An account to create/add to the system. If already exists will return 400.
  - `name` string, required — The account name to use. This will identify the account and must be globally unique in the system.
  - `email` string — An optional email to associate with the account for contact purposes

## Response `200`

Account Record

- Account — Account information
  - `name` string, required — The account identifier, not updatable after creation
  - `type` 'user' | 'admin' | 'service' — The user type (admin vs user). If not specified in a POST request, 'user' is default
  - `state` 'enabled' | 'disabled' | 'deleting' — State of the account. Disabled accounts prevent member users from logging in, deleting accounts are disabled and pending deletion and will be removed once all owned resources are garbage collected by the system
  - `email` string — Optional email address associated with the account
  - `created_at` string, date-time — The timestamp when the account was created
  - `last_updated` string, date-time — The timestamp of the last update to the account metadata itself (not users or creds)

## Other responses

- `409` — Conflicting user information. User already exists.
- `500` — Internal error

---

[API](https://skmtc.net/banzaicloud/apis/anchore-engine-api-server.md) · [All operations](https://skmtc.net/banzaicloud/apis/anchore-engine-api-server/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/banzaicloud/anchore-engine-api-server/versions/38e5705e0b21/schema)
