Lead-Benutzerverwaltung
GET https://leads.qreq.com/api/users/
curl --request GET \
--url 'https://leads.qreq.com/api/users' \
--header 'Authorization: Bearer {api_key}' \
--url 'https://leads.qreq.com/api/users' \
--header 'Authorization: Bearer {api_key}' \
{
"message": "Users retrieved successfully.",
"users": {
"current_page": 1,
"data": [
{
"id": 24,
"name": "kamran",
"email": "[email protected]",
"email_verified_at": null,
"lang": "en",
"avatar": null,
"type": "staff",
"plan_id": null,
"plan_expire_date": null,
"requested_plan": 0,
"created_by": 9,
"mode": "light",
"plan_is_active": 1,
"storage_limit": 0,
"is_enable_login": 1,
"google2fa_enable": 0,
"status": "active",
"is_trial": null,
"trial_day": 0,
"trial_expire_date": null,
"active_module": null,
"referral_code": 0,
"used_referral_code": 0,
"commission_amount": 0,
"created_at": "2025-11-01T06:50:43.000000Z",
"updated_at": "2025-11-01T06:50:43.000000Z",
"roles": [
{
"id": 3,
"name": "staff",
"guard_name": "web",
"label": "staff",
"description": "staff",
"created_by": 9,
"created_at": "2025-11-01T06:50:16.000000Z",
"updated_at": "2025-11-01T06:50:16.000000Z",
"is_system_role": false,
"pivot": {
"model_type": "App\\Models\\User",
"model_id": 24,
"role_id": 3
}
}
],
"creator": {
"id": 9,
"name": "marshall",
"email": "[email protected]",
"email_verified_at": "2025-10-31T10:59:33.000000Z",
"lang": "en",
"avatar": null,
"type": "company",
"plan_id": 1,
"plan_expire_date": null,
"requested_plan": 0,
"created_by": 0,
"mode": "light",
"plan_is_active": 1,
"storage_limit": 0,
"is_enable_login": 1,
"google2fa_enable": 0,
"status": "active",
"is_trial": null,
"trial_day": 0,
"trial_expire_date": null,
"active_module": null,
"referral_code": 634410,
"used_referral_code": 0,
"commission_amount": 0,
"created_at": "2025-10-31T10:59:06.000000Z",
"updated_at": "2025-10-31T10:59:33.000000Z"
}
}
],
"first_page_url": "https://leads.qreq.com/api/users?page=1",
"from": 1,
"last_page": 1,
"last_page_url": "https://leads.qreq.com/api/users?page=1",
"links": [
{
"url": null,
"label": "« Previous",
"page": null,
"active": false
},
{
"url": "https://leads.qreq.com/api/users?page=1",
"label": "1",
"page": 1,
"active": true
},
{
"url": null,
"label": "Next »",
"page": null,
"active": false
}
],
"next_page_url": null,
"path": "https://leads.qreq.com/api/users",
"per_page": 10,
"prev_page_url": null,
"to": 1,
"total": 1
},
"roles": [
{
"id": 3,
"name": "staff",
"guard_name": "web",
"label": "staff",
"description": "staff",
"created_by": 9,
"created_at": "2025-11-01T06:50:16.000000Z",
"updated_at": "2025-11-01T06:50:16.000000Z",
"is_system_role": false
}
],
"planLimits": {
"current_users": 1,
"max_users": 2,
"can_create": true
},
"filters": {
"search": "",
"role": "all",
"per_page": 10,
"sort_field": "created_at",
"sort_direction": "desc"
}
}
POST https://leads.qreq.com/api/users
| Parameter | Einzelheiten | Beschreibung |
|---|---|---|
| name | Erforderlich Zeichenfolge | User's full name |
| Erforderlich Zeichenfolge | User's email address | |
| password | Erforderlich Zeichenfolge | Password for the user (min 8 characters) |
| password Confirmation | Erforderlich Zeichenfolge | Same as password |
| roles | Optional Ganzzahl | Role ID to assign user |
curl --request POST \
--url 'https://leads.qreq.com/api/users' \
--header 'Authorization: Bearer {api_key}' \
--header 'Content-Type: application/json' \
--data '{ "name": "John Doe", "email": "[email protected]", "password": "secret123", "roles": 3 }'
--url 'https://leads.qreq.com/api/users' \
--header 'Authorization: Bearer {api_key}' \
--header 'Content-Type: application/json' \
--data '{ "name": "John Doe", "email": "[email protected]", "password": "secret123", "roles": 3 }'
{
"message": "User created successfully.",
"user": {
"name": "farhan",
"email": "[email protected]",
"created_by": 9,
"lang": "en",
"updated_at": "2025-11-01T10:12:39.000000Z",
"created_at": "2025-11-01T10:12:39.000000Z",
"id": 29,
"type": "staff",
"roles": [
{
"id": 3,
"name": "staff",
"guard_name": "web",
"label": "staff",
"description": "staff",
"created_by": 9,
"created_at": "2025-11-01T06:50:16.000000Z",
"updated_at": "2025-11-01T06:50:16.000000Z",
"is_system_role": false,
"pivot": {
"model_type": "App\\Models\\User",
"model_id": 29,
"role_id": 3
}
}
]
}
}
GET https://leads.qreq.com/api/users/{user_id}
curl --request GET \
--url 'https://leads.qreq.com/api/users/{user_id}' \
--header 'Authorization: Bearer {api_key}'
--url 'https://leads.qreq.com/api/users/{user_id}' \
--header 'Authorization: Bearer {api_key}'
{
"message": "User details retrieved successfully.",
"user": {
"id": 29,
"name": "farhan",
"email": "[email protected]",
"email_verified_at": null,
"lang": "en",
"avatar": null,
"type": "staff",
"plan_id": null,
"plan_expire_date": null,
"requested_plan": 0,
"created_by": 9,
"mode": "light",
"plan_is_active": 1,
"storage_limit": 0,
"is_enable_login": 1,
"google2fa_enable": 0,
"status": "active",
"is_trial": null,
"trial_day": 0,
"trial_expire_date": null,
"active_module": null,
"referral_code": 0,
"used_referral_code": 0,
"commission_amount": 0,
"created_at": "2025-11-01T10:12:39.000000Z",
"updated_at": "2025-11-01T10:12:39.000000Z",
"roles": [
{
"id": 3,
"name": "staff",
"guard_name": "web",
"label": "staff",
"description": "staff",
"created_by": 9,
"created_at": "2025-11-01T06:50:16.000000Z",
"updated_at": "2025-11-01T06:50:16.000000Z",
"is_system_role": false,
"pivot": {
"model_type": "App\\Models\\User",
"model_id": 29,
"role_id": 3
}
}
],
"creator": {
"id": 9,
"name": "marshall",
"email": "[email protected]",
"email_verified_at": "2025-10-31T10:59:33.000000Z",
"lang": "en",
"avatar": null,
"type": "company",
"plan_id": 1,
"plan_expire_date": null,
"requested_plan": 0,
"created_by": 0,
"mode": "light",
"plan_is_active": 1,
"storage_limit": 0,
"is_enable_login": 1,
"google2fa_enable": 0,
"status": "active",
"is_trial": null,
"trial_day": 0,
"trial_expire_date": null,
"active_module": null,
"referral_code": 634410,
"used_referral_code": 0,
"commission_amount": 0,
"created_at": "2025-10-31T10:59:06.000000Z",
"updated_at": "2025-10-31T10:59:33.000000Z"
}
},
"meetings": []
}
PUT https://leads.qreq.com/api/users/{user_id}
| Parameter | Einzelheiten | Beschreibung |
|---|---|---|
| name | Optional Zeichenfolge | New name of the user |
| Optional Zeichenfolge | New email of the user | |
| roles | Optional Ganzzahl | Role ID to assign |
curl --request PUT \
--url 'https://leads.qreq.com/api/users/{user_id}' \
--header 'Authorization: Bearer {api_key}' \
--header 'Content-Type: application/json' \
--data '{ "name": "John Doe Updated", "email": "[email protected]", "roles": 3 }'
--url 'https://leads.qreq.com/api/users/{user_id}' \
--header 'Authorization: Bearer {api_key}' \
--header 'Content-Type: application/json' \
--data '{ "name": "John Doe Updated", "email": "[email protected]", "roles": 3 }'
{
"message": "User updated successfully.",
"user": {
"id": 29,
"name": "faisal",
"email": "[email protected]",
"email_verified_at": null,
"lang": "en",
"avatar": null,
"type": "staff",
"plan_id": null,
"plan_expire_date": null,
"requested_plan": 0,
"created_by": 9,
"mode": "light",
"plan_is_active": 1,
"storage_limit": 0,
"is_enable_login": 1,
"google2fa_enable": 0,
"status": "active",
"is_trial": null,
"trial_day": 0,
"trial_expire_date": null,
"active_module": null,
"referral_code": 0,
"used_referral_code": 0,
"commission_amount": 0,
"created_at": "2025-11-01T10:12:39.000000Z",
"updated_at": "2025-11-01T10:21:08.000000Z",
"roles": [
{
"id": 3,
"name": "staff",
"guard_name": "web",
"label": "staff",
"description": "staff",
"created_by": 9,
"created_at": "2025-11-01T06:50:16.000000Z",
"updated_at": "2025-11-01T06:50:16.000000Z",
"is_system_role": false,
"pivot": {
"model_type": "App\\Models\\User",
"model_id": 29,
"role_id": 3
}
}
]
}
}
DELETE https://leads.qreq.com/api/users/{user_id}
curl --request DELETE \
--url 'https://leads.qreq.com/api/users/{user_id}' \
--header 'Authorization: Bearer {api_key}'
--url 'https://leads.qreq.com/api/users/{user_id}' \
--header 'Authorization: Bearer {api_key}'
{
"message": "User deleted successfully."
}
PUT https://leads.qreq.com/api/users/{user_id}/reset-password
| Parameter | Einzelheiten | Beschreibung |
|---|---|---|
| password | Erforderlich Zeichenfolge | New password |
| password_confirmation | Erforderlich Zeichenfolge | Confirm password |
curl --request PUT \
--url 'https://leads.qreq.com/api/users/{user_id}/reset-password' \
--header 'Authorization: Bearer {api_key}' \
--header 'Content-Type: application/json' \
--data '{ "password": "newpass123", "password_confirmation": "newpass123" }'
--url 'https://leads.qreq.com/api/users/{user_id}/reset-password' \
--header 'Authorization: Bearer {api_key}' \
--header 'Content-Type: application/json' \
--data '{ "password": "newpass123", "password_confirmation": "newpass123" }'
{
"message": "Password reset successfully."
}
PUT https://leads.qreq.com/api/users/{user_id}/toggle-status
curl --request PUT \
--url 'https://leads.qreq.com/api/users/{user_id}/toggle-status' \
--header 'Authorization: Bearer {api_key}'
--url 'https://leads.qreq.com/api/users/{user_id}/toggle-status' \
--header 'Authorization: Bearer {api_key}'
{
"message": "User status updated successfully.",
"user": {
"id": 30,
"name": "farhan",
"email": "[email protected]",
"email_verified_at": null,
"lang": "en",
"avatar": null,
"type": "staff",
"plan_id": null,
"plan_expire_date": null,
"requested_plan": 0,
"created_by": 9,
"mode": "light",
"plan_is_active": 1,
"storage_limit": 0,
"is_enable_login": 1,
"google2fa_enable": 0,
"status": "inactive",
"is_trial": null,
"trial_day": 0,
"trial_expire_date": null,
"active_module": null,
"referral_code": 0,
"used_referral_code": 0,
"commission_amount": 0,
"created_at": "2025-11-01T10:26:20.000000Z",
"updated_at": "2025-11-01T10:34:00.000000Z"
}
}