You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
put:
|
|
|
|
tags:
|
|
|
|
- posts
|
|
|
|
summary: edit a post
|
|
|
|
description: This operation edits a post
|
|
|
|
parameters:
|
|
|
|
- in: path
|
|
|
|
name: pid
|
|
|
|
schema:
|
|
|
|
type: string
|
|
|
|
required: true
|
|
|
|
description: a valid post id
|
|
|
|
example: 1
|
|
|
|
requestBody:
|
|
|
|
required: true
|
|
|
|
content:
|
|
|
|
application/json:
|
|
|
|
schema:
|
|
|
|
type: object
|
|
|
|
properties:
|
|
|
|
content:
|
|
|
|
type: string
|
|
|
|
description: New post content
|
|
|
|
title:
|
|
|
|
type: string
|
|
|
|
description: Topic title, only accepted for main posts
|
|
|
|
required:
|
|
|
|
- content
|
|
|
|
example:
|
|
|
|
content: 'New post content'
|
|
|
|
title: 'New title'
|
|
|
|
responses:
|
|
|
|
'200':
|
|
|
|
description: Post successfully edited
|
|
|
|
content:
|
|
|
|
application/json:
|
|
|
|
schema:
|
|
|
|
type: object
|
|
|
|
properties:
|
|
|
|
status:
|
|
|
|
$ref: ../../components/schemas/Status.yaml#/Status
|
|
|
|
response:
|
|
|
|
$ref: ../../components/schemas/PostsObject.yaml#/PostsObject
|
|
|
|
delete:
|
|
|
|
tags:
|
|
|
|
- posts
|
|
|
|
summary: purge a post
|
|
|
|
description: This operation purges a post.
|
|
|
|
parameters:
|
|
|
|
- in: path
|
|
|
|
name: pid
|
|
|
|
schema:
|
|
|
|
type: string
|
|
|
|
required: true
|
|
|
|
description: a valid post id
|
|
|
|
example: 1
|
|
|
|
responses:
|
|
|
|
'200':
|
|
|
|
description: Post successfully purged
|
|
|
|
content:
|
|
|
|
application/json:
|
|
|
|
schema:
|
|
|
|
type: object
|
|
|
|
properties:
|
|
|
|
status:
|
|
|
|
$ref: ../../components/schemas/Status.yaml#/Status
|
|
|
|
response:
|
|
|
|
type: object
|
|
|
|
properties: {}
|