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

# Update Assignment Sharing

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

Share a devoir as an objet commun (colleagues or whole school), update
its sharing, or make it private again (empty values). Any collaborator
with write access can manage the sharing, not only the owner ("un truc
très partagé"). Unlike the historical share-with-teacher endpoint this
does not copy anything: everyone edits the same devoir until a class
somewhere starts working on it, which freezes it (see
services/assignment_sharing.py).

## Path parameters

- `assignment_id` string, required

## Request body

- UpdateAssignmentSharingRequest
  - `sharing_options` SharingOptions, required — Model for sharing configuration across folders, exams, and exercises
    - `shared_with_school` boolean
    - `shared_with` string[]
    - `read_only` boolean

## Response `200`

Successful Response

- AssignmentSharingResponse
  - `status` string, required
  - `message` string, required
  - `sharing` SharingOptions, required — Model for sharing configuration across folders, exams, and exercises
    - `shared_with_school` boolean
    - `shared_with` string[]
    - `read_only` boolean

## Other responses

- `409` — Business rule violated
- `422` — Validation Error

## Changes

- **2026-09-14** `0a41d91c9d20` — 1 info
  - endpoint added

[Change history](https://skmtc.dev/excellence-ai/apis/excellence-learning/changes/teacher/assignments/:assignment_id/sharing/put.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/2a0c1636fd3b?raw)
