---
title: "Update Flashcard"
method: PUT
path: "/teacher/courses/{course_id}/flashcards/{flashcard_id}"
tags: ["Teacher Courses"]
---

# Update Flashcard

`PUT /teacher/courses/{course_id}/flashcards/{flashcard_id}`

## 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/courses/{course_id}/flashcards/{flashcard_id}`
- Auth: OAuth 2 (password, token URL `api/login`)

Update the front and/or back content of a flashcard within a teacher course.

Allows updating the front and back content of a flashcard that belongs
to a course owned by the authenticated teacher.

## Path parameters

- `course_id` string, required
- `flashcard_id` string, required

## Request body

- UpdateFlashcardRequest: Request model for updating flashcard fields.
  - `front` string, nullable
  - `back` string, nullable

## Response `200`

Successful Response

- Flashcard: Represents a flashcard generated from a course.
  - `_id` string
  - `course_id` string, required
  - `unit_id` string, nullable
  - `user_id` string, required
  - `front` string, required
  - `back` string, required
  - `revision_type` 'unit' | 'course_global', nullable
  - `anchor_unit_id` string, nullable
  - `anchor_block_id` string, nullable
  - `anchored_at` string, date-time, nullable
  - `created_at` string, date-time

## Other responses

- `422`: Validation Error

## Changes

> 55 revisions in range; 1 not diffed.

- **2026-09-30** `518c1e6178a3`: 3 info
  - added the optional property `anchor_block_id` to the response with the `200` status
  - added the optional property `anchor_unit_id` to the response with the `200` status
  - added the optional property `anchored_at` to the response with the `200` status

[Operation history](https://skmtc.dev/excellence-ai/apis/excellence-learning/changes/teacher/courses/:course_id/flashcards/:flashcard_id/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/379e4a57dee8?raw)
