forum.upload-image
Upload an editor image for a writable topic or category.
POST
/api/v1/{locale}/forum/imagesAPI scope forum.upload-image
Request
Send Authorization: Bearer <key> with each request.
Requires a signed-in player and applicable permission.
Path parameters
| Field | Type | Requirement | Description |
|---|---|---|---|
locale | tr or en | Required | Request locale. |
Query parameters
| Field | Type | Requirement | Description |
|---|---|---|---|
operation | create | reply | edit | edit-reply | Required | Editor operation that will use this image. |
slug | string | Optional | Topic slug when replying or editing. |
replyId | integer | Optional | Reply ID when editing a reply. |
Request body
| Field | Type | Requirement | Description |
|---|---|---|---|
image | file | Required | Image file sent with multipart/form-data. |
category | string | Optional | Writable category slug when operation=create. |
Run samples from your application server. See Quickstart for variables and sessions.
Request with a file
curl --fail-with-body --request POST \
-H "Authorization: Bearer $MINEXON_API_KEY" \
-b "$MINEXON_COOKIE_JAR" -c "$MINEXON_COOKIE_JAR" \
--form-string category=announcements \
--form [email protected] \
"${MINEXON_BASE_URL}/api/v1/en/forum/images?operation=create"Response
HTTP 201 · application/json
| Field | Type | Requirement | Description |
|---|---|---|---|
url | string | Required | Image URL to insert in the editor. |
{
"url": "/_forum/images/0123456789abcdef0123456789abcdef"
}Flow and error cases
Invalid images return 422; upload limits can return 429. The response body can be an empty JSON array.
HTTP 422 · application/json
{
"error": "category"
}