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

# Create a Kafka user

> Creates a Kafka user. Strimzi generates its password, which is returned if the user becomes active within a few seconds; otherwise the response has a warning and the user's password is available from the credentials endpoint once it is active. Producer/consumer users can read every topic under the company's prefix, which includes all data Artie replicates, and write to topics under the company's customer prefix. Admin-profile users are managed under /admin-users.

`POST /kafka-clusters/{uuid}/users`

## Authorization

* `Authorization` (header): API key passed as a Bearer token in the Authorization header.

## Path parameters

* `uuid` (string, required)

## Body (application/json)

* `accessProfile` (string, required): Must be producer_consumer; create admin-profile users with POST /kafka-clusters/{uuid}/admin-users.
* `username` (string, required)

## Example request

```bash
curl --request POST \
  --url https://api.artie.com/kafka-clusters/{uuid}/users \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
  "accessProfile": "<string>",
  "username": "<string>"
}'
```

## Responses

### 200 OK

* `kafkaUser` (object, required)
  * `accessProfile` (string, required)
  * `consumerGroupPrefix` (string, required)
  * `createdAt` (string<date-time>, required)
  * `status` (string, required)
  * `username` (string, required)
  * `uuid` (string<uuid>, required)
* `password` (string): The SCRAM-SHA-512 password Strimzi generated, returned when the user is already active. Otherwise get it from the credentials endpoint once the user is active.
* `warning` (string)

```json
{
  "kafkaUser": {
    "accessProfile": "<string>",
    "consumerGroupPrefix": "<string>",
    "createdAt": "2023-11-07T05:31:56Z",
    "status": "<string>",
    "username": "<string>",
    "uuid": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
  },
  "password": "<string>",
  "warning": "<string>"
}
```

### 400 Bad Request

### 404 Not Found

### 409 Conflict

### 500 Internal Server Error