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

# Create a user

> Creates a new end-user within an environment.



## OpenAPI

````yaml post /v1/users
openapi: 3.0.0
info:
  title: Revstack API
  version: 1.0.0
  description: >-
    Open Source Billing OS for Developers. The scalable, developer-first billing
    engine with subscriptions, invoicing, usage metering, and entitlements.
servers:
  - url: http://localhost:6900
    description: Revstack API (Local Development)
security: []
paths:
  /v1/users:
    post:
      tags:
        - Users
      summary: Create a user
      description: Creates a new end-user within an environment.
      requestBody:
        content:
          application/json:
            schema:
              type: object
              properties:
                environmentId:
                  type: string
                  minLength: 1
                email:
                  type: string
                  format: email
                name:
                  type: string
                role:
                  type: string
                  minLength: 1
                metadata:
                  type: object
                  additionalProperties:
                    nullable: true
              required:
                - environmentId
                - email
                - role
      responses:
        '201':
          description: User created
          content:
            application/json:
              schema:
                nullable: true

````