Internal
Public Access
Document self-registration toggle
This commit is contained in:
@@ -162,7 +162,12 @@ X-RateLimit-Reset: 1234567890
|
||||
|
||||
**POST** `/api/users/register/` (Public)
|
||||
|
||||
Creates new user account and sends verification email.
|
||||
Creates a new user account and sends a verification email when self-registration is enabled.
|
||||
|
||||
**Availability:**
|
||||
- Controlled by `ALLOW_SELF_REGISTRATION`
|
||||
- Disabled by default
|
||||
- Returns `403 Forbidden` when self-registration is off
|
||||
|
||||
**Request:**
|
||||
```json
|
||||
@@ -1056,7 +1061,7 @@ Use `page` query parameter to navigate: `?page=2`
|
||||
|
||||
### Complete Workflow Example
|
||||
|
||||
**1. Register:**
|
||||
**1. Register:** `ALLOW_SELF_REGISTRATION=True` only
|
||||
```bash
|
||||
POST /api/users/register/
|
||||
{
|
||||
@@ -1067,6 +1072,8 @@ POST /api/users/register/
|
||||
}
|
||||
```
|
||||
|
||||
**If self-registration is disabled:** create the user through Django admin or another internal provisioning flow, then continue with verification/approval as needed.
|
||||
|
||||
**2. Verify Email:**
|
||||
```bash
|
||||
POST /api/users/verify-email/
|
||||
|
||||
Reference in New Issue
Block a user