Добавить комментарий
Request
POST
https://api.wiki.yandex.net/v1/pages/{idx}/comments
Path parameters
|
Name |
Description |
|
idx |
Type: integer |
Body
application/json
{
"body": "example",
"inline_text": "example",
"parent_id": 0,
"thread_id": 0
}
|
Name |
Description |
|
body |
Type: string Example: |
|
inline_text |
Type: string Example: |
|
parent_id |
Type: integer |
|
thread_id |
Type: integer |
Responses
200 OK
OK
Body
application/json
{
"id": 0,
"body": "example",
"inline_text": "example",
"parent_id": 0,
"author": {
"id": 0,
"identity": {
"uid": "example",
"cloud_uid": "example"
},
"username": "example",
"display_name": "example",
"is_dismissed": true,
"affiliation": "example"
},
"thread_id": 0,
"created_at": "2025-01-01T00:00:00Z",
"is_deleted": true,
"resolve_status": "resolved",
"reactions": [
{
"type": "like",
"author": null,
"created_at": "2025-01-01T00:00:00Z"
}
]
}
|
Name |
Description |
|
author |
Type: UserSchema Example
|
|
body |
Type: string Example: |
|
created_at |
Type: string<date-time> Example: |
|
id |
Type: integer |
|
is_deleted |
Type: boolean |
|
reactions |
Type: CommentReactionSchema[] Example
|
|
resolve_status |
Type: CommentResolveStatus An enumeration. Enum: |
|
inline_text |
Type: string Example: |
|
parent_id |
Type: integer |
|
thread_id |
Type: integer |
UserIdentity
|
Name |
Description |
|
cloud_uid |
Type: string Example: |
|
uid |
Type: string Example: |
Example
{
"uid": "example",
"cloud_uid": "example"
}
UserSchema
|
Name |
Description |
|
affiliation |
Type: string Example: |
|
display_name |
Type: string Example: |
|
id |
Type: integer |
|
is_dismissed |
Type: boolean |
|
username |
Type: string Example: |
|
identity |
Type: UserIdentity Example
|
Example
{
"id": 0,
"identity": {
"uid": "example",
"cloud_uid": "example"
},
"username": "example",
"display_name": "example",
"is_dismissed": true,
"affiliation": "example"
}
CommentResolveStatus
An enumeration.
Type: string
Enum: resolved, unresolved
ReactionType
An enumeration.
Type: string
Enum: like, hooray, confused, heart, rocket, eyes, fire, ok, facepalm, check, laugh, dislike
CommentReactionSchema
|
Name |
Description |
|
author |
Type: UserSchema Example
|
|
created_at |
Type: string<date-time> Example: |
|
type |
Type: ReactionType An enumeration. Enum: |
Example
{
"type": "like",
"author": {
"id": 0,
"identity": {
"uid": "example",
"cloud_uid": "example"
},
"username": "example",
"display_name": "example",
"is_dismissed": true,
"affiliation": "example"
},
"created_at": "2025-01-01T00:00:00Z"
}