<span id="追加保存的响应文本"></span>

# Append saved response text

```{raw} html
<div class="mo-api-page-show-toc" aria-hidden="true"></div>
```

Append text to an existing modified_response.


```http
POST https://api.moi.matrixorigin.cn/v5/workspaces/{workspace_id}/llm/sessions/{session_id}/messages/{message_id}/append-modified-response
```

<span id="调用前准备"></span>

## Before you call this API

`BASE_URL` uses the product API prefix `https://api.moi.matrixorigin.cn/v5`. For a dedicated deployment, use its corresponding product API address.

[Configure Workspace identity and variables in the same environment](objects.md#request-prerequisites).

<span id="请求"></span>

## Request

:::::::{div} mo-api-tabs
::::::{tab-set}
:::::{tab-item} Request example

```bash
curl --request POST \
  "$BASE_URL/workspaces/$WORKSPACE_ID/llm/sessions/$SESSION_ID/messages/$MESSAGE_ID/append-modified-response" \
  --header "X-API-Key: $MOI_KEY" \
  --header "X-Workspace-ID: $WORKSPACE_ID" \
  --header "Content-Type: application/json" \
  --data-raw '{"append_content":" 补充内容"}'
```

:::::
:::::{tab-item} Parameters

| Parameter | Location | Type | Required | Description |
| --- | --- | --- | --- | --- |
| `workspace_id` | Path | string | Yes | Target Workspace, matching X-Workspace-ID. |
| `session_id` | Path | integer | Yes | Positive integer ID returned by this service. |
| `message_id` | Path | integer | Yes | Positive integer ID returned by this service. |
| `append_content` | Body | string | No | Text to append. Omitted/null/empty string appends an empty string. |

Appending starts from existing modified_response, not original response. No business request deduplication is provided. Read the message when the result is unknown rather than automatically repeating the same append.

:::::
::::::
:::::::

<span id="成功响应"></span>

## Successful response

:::::::{div} mo-api-tabs mo-api-response-tabs
::::::{tab-set}
:::::{tab-item} Response example

```http
HTTP/1.1 204 No Content
```

:::::
:::::{tab-item} Fields

HTTP 204 with no body. This operation returns no JSON data object.

:::::
::::::
:::::::

<span id="错误响应"></span>

## Error response

[Error formats and read scope](objects.md#error-contract) explains differing identity, parameter, resource-read, and storage-failure outcomes.
