Skip to content

Fetching Database Changes (changes/database) #46

Closed

Description

@leogdion
No description provided.

Activity

  1. added this to the v1.0.0-alpha.3 milestone on Nov 27, 2025
  2. leogdion commented on Jan 8, 2026

    @leogdion
    MemberAuthor

    Status: NOT IMPLEMENTED

    The database changes endpoint is defined in the OpenAPI specification but has not been wrapped with convenience methods in MistKit.

    Current State

    What Exists:

    • OpenAPI endpoint definition in openapi.yaml:226: /database/{version}/{container}/{environment}/{database}/records/changes
    • Generated types in Sources/MistKit/Generated/Types.swift
    • Listed in README.md roadmap (line 326) as pending for v1.0.0-alpha.3

    What's Missing:

    • No public wrapper methods in CloudKitService
    • No convenience API for fetching database changes
    • No documentation or usage examples
    • No integration tests

    What Remains

    1. Create CloudKitService extension:

      • New file: Sources/MistKit/Service/CloudKitService+DatabaseChanges.swift
      • Implement convenience methods for fetching database changes
      • Handle change tokens and pagination
    2. Add documentation:

      • Usage examples
      • Parameter descriptions
      • Return value documentation
    3. Write tests:

      • Integration tests for database changes
      • Test change token handling
      • Test pagination scenarios
    4. Update README.md:

      • Update roadmap status
      • Add usage examples

    Files to Create/Modify

    • Sources/MistKit/Service/CloudKitService+DatabaseChanges.swift (new)
    • Tests/MistKitTests/CloudKitServiceDatabaseChangesTests.swift (new)
    • README.md (update roadmap)
  3. leogdion commented on Jan 9, 2026

    @leogdion
    MemberAuthor

    This issue is now tracked as part of parent issue #199 - Complete CloudKit API Coverage

  4. leogdion commented on Apr 29, 2026

    @leogdion
    MemberAuthor

    Completed and verified in codebase.

  5. leogdion commented on May 27, 2026

    @leogdion
    MemberAuthor

    Reopening — the "completed/verified in codebase" close was based on a mis-mapping to records/changes, which is a different Apple endpoint.

    Per Apple's CloudKit Web Services Reference, Fetching Database Changes is POST .../changes/database — it returns which zones have changed. Apple explicitly marks the older zones/changes ("Fetching Zone Changes") as deprecated and says to use changes/database instead.

    What openapi.yaml actually declares today:

    • records/changes → fetchRecordChanges — this is Apple's "Fetching Record Changes" (a different endpoint, not database changes).
    • zones/changes → fetchZoneChanges — this is the deprecated "Fetching Zone Changes" endpoint.

    The canonical changes/database path is not in the spec and has no CloudKitService wrapper. So this remains unimplemented; the spec should add changes/database (and fetchZoneChanges/zones/changes should be reconsidered as deprecated).

    Refs:


    Generated by Claude Code

  6. leogdion commented on Aug 28, 2026

    @leogdion
    MemberAuthor

    Resolved on v1.0.0-beta.4 via #429 (commit 0b6bea9) — changes/database as fetchDatabaseChanges / fetchAllDatabaseChanges. (Was still filed under the v1.0.0-alpha.5 milestone; it landed in beta.4.)

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

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions