Skip to content

REST API, part 3: writes (Phase 2) #490

Open

Description

@caseysoftware

Intent: every create, edit and delete flow in the UI has an API equivalent with identical side effects.

Depends on: #489; file upload also on #394.

Steps

  • POST, PATCH (JSON Merge Patch) and DELETE for the Phase 1 resources, all through the services.
  • Task sub-resources: assignments and dependencies (PUT replaces), logs, POST /tasks/{id}/move, /notify; POST /projects/{id}/duplicate.
  • Custom fields in request bodies; only the fields sent are changed.
  • Extract the remaining services (contacts, companies, events, files, users, task logs, Project Designer bulk actions) and point their do_* handlers at them.
  • ETag / If-Match (412 on conflict); optional Idempotency-Key on POST (api_idempotency).
  • Migrations: *_updated columns on companies, contacts, departments, files, links, task_log, users, forum_messages, resources (backfilled from history); api_events outbox table written by a listener on the shared dispatcher.
  • Request-body validation with opis/json-schema against the OpenAPI schemas.
  • Multipart file upload on the storage facade from Rearchitect the Files Module, part 2: storage abstraction (Phase 1) #394.
  • Parity tests: the same input through the legacy handler and the API produces the same rows.

Goal: parity tests pass for every write, and writes appear in history and in api_events.

Spec: REST API and MCP server proposal (#471), sections 6–8 and 12.

Activity

  1. added
    api
    on Oct 23, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    api

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions