---
title: "Create a user"
method: POST
path: "/api/v1/users"
tags: ["Users"]
---

# Create a user

`POST /api/v1/users`

## Request body

- AddUser
  - `adminFlags` 0 | 1 — Admin flags for the user (None = `0`, Bypass video blocklist = `1`)
  - `channelName` string — immutable name of the channel, used to interact with its actor
  - `email` string, email, required — The user email
  - `password` string, password, required
  - `role` 0 | 1 | 2, required — The user role (Admin = `0`, Moderator = `1`, User = `2`)
  - `username` string, required — immutable name of the user, used to find or mention its actor
  - `videoQuota` integer, required — The user video quota in bytes
  - `videoQuotaDaily` integer, required — The user daily video quota in bytes

## Response `200`

user created

- AddUserResponse
  - `user` object
    - `account` object
      - `id` integer
    - `id` integer

## Other responses

- `403` — insufficient authority to create an admin or moderator

---

[API](https://skmtc.net/cpy/apis/peertube.md) · [All operations](https://skmtc.net/cpy/apis/peertube/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/cpy/peertube/revisions/efe11b159e43/schema)
