---
title: "Apply Exam Chat Action"
method: POST
path: "/teacher-exams/{exam_id}/subjects/exercises/chat-action"
tags: ["Teacher Exams Subjects"]
---

# Apply Exam Chat Action

`POST /teacher-exams/{exam_id}/subjects/exercises/chat-action`

## Request

- Base URL: `https://api.excellence-ai.com` (the document declares no server; this is the origin it was published from)
- URL: `https://api.excellence-ai.com/teacher-exams/{exam_id}/subjects/exercises/chat-action`
- Auth: OAuth 2 (password, token URL `api/login`)

Apply one teacher-confirmed chat proposal atomically as a new version.
Shared with the évaluation page's chat write tools (EXC-1260); the
answers keep their historical status codes, which the legacy card reads.

## Path parameters

- `exam_id` string, required

## Request body

- ExamChatActionRequest
  - `action` 'add' | 'edit' | 'remove' | 'reorder', required
  - `exercise_ids` integer[]
  - `exercises` ExamChatExercisePayload[]
    - `exercise_id` integer, nullable
    - `title` string, nullable
    - `statement` string, nullable
    - `solution` string, nullable
    - `points` number, nullable
    - `figure` string, nullable
    - `solution_figure` string, nullable
    - `remove_figure` boolean
    - `remove_solution_figure` boolean

## Response `200`

Successful Response

- object

## Other responses

- `422`: Validation Error

## Changes

> 55 revisions in range; 1 not diffed.

- **2026-09-30** `518c1e6178a3`: 1 info
  - added the new `reorder` enum value to the request property `action`

[Operation history](https://skmtc.dev/excellence-ai/apis/excellence-learning/changes/teacher-exams/:exam_id/subjects/exercises/chat-action/post.md)

---

[API](https://skmtc.dev/excellence-ai/apis/excellence-learning.md) - [All operations](https://skmtc.dev/excellence-ai/apis/excellence-learning/llms.txt) - [OpenAPI document](https://skmtc.dev/excellence-ai/apis/excellence-learning/revisions/379e4a57dee8?raw)
