Skip to main content

Nhóm nhóm người dùng

Mô tả

Các API hỗ trợ:

  • GET /roles: Lấy danh sách các nhóm người dùng.

API


GET /api/roles

Lấy danh sách các nhóm người dùng, hỗ trợ các tham số filter sau:

Tên trườngKiểu dữ liệuMô tả
codestringMã nhóm
namestringTên nhóm
descriptionstringMô tả
statusstringTrạng thái
sortintegerTên trường sắp xếp
orderintegerThứ tự sắp xếp
pageintegerTrang
sizeintegerSố bản ghi trên trang

Trạng thái bao gồm: 0 (Khóa) | 1 (Hoạt động)

GET /api/roles?page=1&size=10&sort=name&order=asc&code=1&name=role&description=&status=1

Response Body
{
"code": 200,
"message": "Success",
"result": [
{
"id": "m032_g010",
"name": "Role 1",
"description": null,
"default_for_user_type": null,
"status": 1,
"merchant_id": "00000000-0000-0000-0000-000000000004",
"deleted": 0,
"created_at": "2024-01-22T04:21:42.000Z",
"created_by": "admin",
"updated_at": "2024-01-22T04:21:42.000Z",
"updated_by": null
},
{
"id": "m032_g011",
"name": "Role 2",
"description": null,
"default_for_user_type": null,
"status": 1,
"merchant_id": "00000000-0000-0000-0000-000000000004",
"deleted": 0,
"created_at": "2024-01-22T04:21:47.000Z",
"created_by": "admin",
"updated_at": "2024-01-22T04:21:47.000Z",
"updated_by": null
}
],
"page": 1,
"page_size": 10,
"total": 2
}