Skip to content

[2026 API] Generate a typed frontend client from the OpenAPI spec #999

Description

@Nanle-code

Objective

Remove hand-written fetch calls to the dashboard API and catch contract changes at compile time.

Target area

src/api, docs/api, scripts/generate-api-docs.mjs

Context

The frontend calls the dashboard API with hand-written fetch wrappers, so server changes break the UI at runtime instead of at build time.

Acceptance criteria

  • A script generates a typed client from the OpenAPI spec into src/api/generated/.
  • Existing API calls move to the generated client, including auth headers and idempotency keys.
  • CI regenerates the client and fails if the committed output is stale.
  • Errors map to the app's error taxonomy ([2026 Platform] Standardize error boundary messaging across all dashboard routes #822).
  • Automated tests cover the primary flow, at least one boundary case, and at least one failure case.
  • User-facing documentation or developer guidance is updated, including compatibility, security, or migration notes where applicable.

Pull request requirements

  • All continuous integration checks must pass before a pull request may be merged.
  • The branch must be free of merge conflicts with the target branch at the time of merge.
  • Do not request merge with failing workflows, skipped required checks, or unresolved conflicts.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions