title: Create User keywords: - create user - post - create - user # Create User Create a new user. #### Request Body **`email`** string required The email parameter. **`first_name`** string optional The first name parameter. **`last_name`** string optional The last name parameter. **`password`** string required Password (min 8 characters) ## Returns **`email`** string Email **`first_name`** string or null First Name **`last_name`** string or null Last Name **`id`** string User ID with usr_ prefix **`is_active`** boolean Is Active **`last_verified`** string or null Last Verified **`global_role_id`** string or null Global Role Id **`created_at`** string Created At **`updated_at`** string Updated At Example ```bash cURL curl -X POST "https://api.aitronos.com/v1/user/" \ -H "X-API-Key: $FREDDY_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "email": "your_email", "password": "your_password" }' ``` ```python Python import os import requests api_key = os.environ["FREDDY_API_KEY"] response = requests.post( "https://api.aitronos.com/v1/user/", headers={"X-API-Key": api_key}, json={'email': 'your_email', 'password': 'your_password'} ) print(response.json()) ``` ```javascript JavaScript const apiKey = process.env.FREDDY_API_KEY; const response = await fetch('https://api.aitronos.com/v1/user/', { method: 'POST', headers: { 'X-API-Key': apiKey, 'Content-Type': 'application/json' }, body: JSON.stringify({"email": "your_email", "password": "your_password"}) }); const data = await response.json(); console.log(data); ``` **Response:** ```json 201 OK { "email": "user@example.com", "first_name": "example_first_name", "last_name": "example_last_name", "id": "usr_abc123def456", "is_active": true, "last_verified": "2025-11-15T10:30:00Z", "global_role_id": "abc123def456", "created_at": "2025-11-15T10:30:00Z", "updated_at": "2025-11-15T10:30:00Z" } ``` Errors ```json 401 Unauthorized { "success": false, "error": { "code": "AUTHENTICATION_REQUIRED", "message": "Authentication required. Please provide a valid API key.", "system_message": "Missing or invalid authorization header", "type": "authentication_error", "status": 401, "trace_id": "req_abc123xyz", "timestamp": "2025-11-11T10:30:00Z", "details": {} } } ``` ```json 403 Forbidden { "success": false, "error": { "code": "INSUFFICIENT_PERMISSIONS", "message": "You do not have permission to access this resource.", "system_message": "Insufficient permissions for this operation", "type": "authorization_error", "status": 403, "trace_id": "req_def456uvw", "timestamp": "2025-11-11T10:30:00Z", "details": {} } } ``` ## Related Resources - [Get Profile](/docs/api-reference/users/get-profile)