Implement catalog metadata reads for geneds, instructors, and programs #14

Open
opened 2026-11-07 20:27:02 +00:00 by etashj · 0 comments
Member

Goal

Restore the remaining read-only catalog endpoints in crates/courses-web-api/src/backend/catalog.rs.

Scope

  • Implement GET /api/geneds, /api/instructors, /api/instructors/{id}, /api/programs, and /api/programs/{id} from the catalog database.
  • Match sites/web/src/lib/contracts.ts and the existing frontend usage; use parameterized queries and appropriate empty/not-found responses.
  • Apply the public/member audience rules to instructor and other restricted fields.
  • Add OpenAPI coverage and tests for valid reads, invalid IDs, missing records, and anonymous/member responses.

Done when

The corresponding frontend pages load real catalog data without 501 responses, and sites/docs/src/features.md reflects the behavior.

Professor-based search remains tracked in #8. See sites/docs/src/backend-development.md and sites/docs/src/api/data.md.

## Goal Restore the remaining read-only catalog endpoints in `crates/courses-web-api/src/backend/catalog.rs`. ## Scope - Implement `GET /api/geneds`, `/api/instructors`, `/api/instructors/{id}`, `/api/programs`, and `/api/programs/{id}` from the catalog database. - Match `sites/web/src/lib/contracts.ts` and the existing frontend usage; use parameterized queries and appropriate empty/not-found responses. - Apply the public/member audience rules to instructor and other restricted fields. - Add OpenAPI coverage and tests for valid reads, invalid IDs, missing records, and anonymous/member responses. ## Done when The corresponding frontend pages load real catalog data without 501 responses, and `sites/docs/src/features.md` reflects the behavior. Professor-based search remains tracked in #8. See `sites/docs/src/backend-development.md` and `sites/docs/src/api/data.md`.
Sign in to join this conversation.
No description provided.