---
title: "Update Assignment Classes"
method: PUT
path: "/teacher/assignments/{assignment_id}/classes"
tags: ["teacher_assignments"]
---

# Update Assignment Classes

`PUT /teacher/assignments/{assignment_id}/classes`

Set the requesting teacher's classes on this devoir.

The payload is the caller's OWN class list for the devoir, and only that:
on a shared devoir (objet commun) every collaborator assigns their own
classes to the same document, so the endpoint merges — colleagues'
classes are kept untouched, the caller's subset is replaced. Assigning
stays possible after the shared freeze (the frozen content is exactly
what makes it safe).

## Path parameters

- `assignment_id` string, required

## Request body

- UpdateAssignmentClassesRequest
  - `class_ids` string[]

## Response `200`

Successful Response

- UpdateAssignmentClassesResponse
  - `status` string, required
  - `class_ids` string[], required
  - `class_names` string[], required

## Other responses

- `422` — Validation Error

---

[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/2a0c1636fd3b?raw)
