Admin
Endpoints for managing admin users.
'/admins'
POST
async create(
@requestBody({
content: {
'application/json': {
schema: {
type: 'object',
},
},
},
})
admin: DTO<Admin & User>,
): Promise<Admin>Auth: Yes RBAC: Admin
Creates an admin user.
GET
async find(@param.filter(Admin) filter?: Filter<Admin>): Promise<Admin[]>Auth: Yes RBAC: Admin
Searches for admin users.
PATCH
async updateAll(
@requestBody({
content: {
'application/json': {
schema: getModelSchemaRef(Admin, { partial: true }),
},
},
})
admin: Admin,
@param.where(Admin) where?: Where<Admin>,
): Promise<Count>Auth: Yes RBAC: Admin
Searches for admin users.
'/admins/{id}'
GET
async findById(
@param.path.string('id') id: string,
@param.filter(Admin, { exclude: 'where' })
filter?: FilterExcludingWhere<Admin>,
): Promise<Admin>Auth: Yes RBAC: Admin
Find an admin by ID.
PATCH
async updateById(
@param.path.string('id') id: string,
@requestBody({
content: {
'application/json': {
schema: getModelSchemaRef(Admin, { partial: true }),
},
},
})
admin: Admin,
): Promise<void>Auth: Yes RBAC: Admin
Update an admin by ID.
PUT
async replaceById(
@param.path.string('id') id: string,
@requestBody() admin: Admin,
): Promise<void>Auth: Yes RBAC: Admin
Overwrites an admin by ID.
TODO: Investigate if this is needed.
DEL
async deleteById(@param.path.string('id') id: string): Promise<void>Auth: Yes RBAC: Admin
Delete an admin by ID
'/admins/order-chips'
GET
async getChipOrders(
): Promise<OrderChip[]>Auth: Yes RBAC: Admin
Allows an admin to retrieve all completed chip orders.
Last updated