Comment
'/comments/{type}/{id}'
GET
async find(
@param.path.string('type') type: string,
@param.path.number('id') id: number,
@param.query.object('filter') filter?: Filter<Comment>,
): Promise<Comment[]>POST
async create(
@param.path.string('type') type: string,
@param.path.number('id') id: typeof Post.prototype.id,
@requestBody({
content: {
'application/json': {
schema: getModelSchemaRef(Comment, {
title: 'NewPostCommentInPost',
exclude: ['id'],
optional: ['parentId', 'parentType'],
}),
},
},
})
comment: Omit<Comment, 'id'>,
): Promise<Comment>'/commentCount/{type}/{id}'
GET
'/comments/{commentId}'
PATCH
DEL
Last updated