Create a new comment for a chart
POST
https://api.datawrapper.de/v3/charts/{id}/comments Requires scope chart:write.
Example Request
curl --request POST \
--url https://api.datawrapper.de/v3/charts/example-id/comments \
--header 'Authorization: Bearer <YOUR_TOKEN_HERE>' \
--header 'Content-Type: application/json' \
--data '{
"body": "string",
"json": {}
}'Headers
| Name | Value | Required | Description |
|---|---|---|---|
Content-Type | application/json | Yes | The format of the request body. |
Path Parameters
| Name | Type | Allowed values | Required | Description |
|---|---|---|---|---|
id | string | 5 characters | Yes |
Request Body
| Field | Type | Allowed values | Required | Description |
|---|---|---|---|---|
body | string | Yes | ||
json | object | Default: [object Object] | No | |
json.type | string | Yes | ||
json.attrs | object | No | ||
json.attrs.id | string | No | ||
json.marks | object[] | No | ||
json.marks.type | string | Yes | ||
json.marks.attrs | object | No | ||
json.marks.attrs.id | string | No | ||
json.text | string | No | ||
json.content | string[] | No | ||
parentId | integer | No |