Skip to content

feat(api): add anniversaries ICS feed endpoint - #792

Open
elig-45 wants to merge 5 commits into
gramps-project:masterfrom
elig-45:anniversary-ics-api-feed
Open

feat(api): add anniversaries ICS feed endpoint#792
elig-45 wants to merge 5 commits into
gramps-project:masterfrom
elig-45:anniversary-ics-api-feed

Conversation

@elig-45

@elig-45 elig-45 commented Mar 31, 2026

Copy link
Copy Markdown
Contributor

Summary

Add the public anniversaries ICS endpoint using the persistent scoped token infrastructure merged in #790.

Context

This branch has been rebuilt on current master, so this PR now only contains the anniversaries ICS endpoint changes.

What’s included in this step

  • Add GET /api/anniversaries.ics?token=....
  • Resolve token via the scoped persistent token infrastructure from feat(api): add scoped persistent access token infrastructure #790.
  • Apply filters: event_types, anchor_gramps_id, generation_depth.
  • Return text/calendar ICS with yearly recurring VEVENTs.
  • Add endpoint tests for token validity, revoke flow, filters, anchor scope, disabled user/tree.

Related

@elig-45

elig-45 commented May 30, 2026

Copy link
Copy Markdown
Contributor Author

I updated this pr following the modifications on #790

@elig-45
elig-45 force-pushed the anniversary-ics-api-feed branch from ae82436 to 5d10bc5 Compare June 29, 2026 16:46
@elig-45

elig-45 commented Jun 29, 2026

Copy link
Copy Markdown
Contributor Author

Updated this PR now that #790 has been merged.

I rebuilt the branch on top of current master so the PR now only contains the anniversaries ICS endpoint changes:

  • GET /api/anniversaries.ics?token=...
  • ICS filtering by event_types, anchor_gramps_id, and generation_depth
  • endpoint tests for token validity, revoke flow, filtering, anchor scope, disabled users, and disabled trees

@elig-45
elig-45 marked this pull request as ready for review June 29, 2026 16:54
@DavidMStraub
DavidMStraub requested a review from Copilot June 30, 2026 09:46

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new public ICS (iCalendar) feed endpoint for anniversaries that authenticates via the scoped persistent access-token infrastructure introduced in #790, enabling calendar clients to subscribe to filtered, recurring anniversary events.

Changes:

  • Add GET /api/anniversaries.ics?token=... resource that generates a text/calendar ICS payload with yearly VEVENTs.
  • Implement query filtering (event_types, anchor_gramps_id, generation_depth) and scope/disabled checks (user + tree).
  • Add endpoint tests covering token validity/revocation, filters, anchor scope, and disabled user/tree behavior.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
gramps_webapi/api/resources/anniversaries.py Implements the anniversaries ICS endpoint, filtering logic, and ICS serialization.
gramps_webapi/api/__init__.py Registers the new /anniversaries.ics endpoint in the API router.
tests/test_endpoints/test_anniversaries_ics.py Adds test coverage for endpoint access control and core filtering behavior.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread gramps_webapi/api/resources/anniversaries.py
Comment thread gramps_webapi/api/resources/anniversaries.py Outdated
Comment thread gramps_webapi/api/resources/anniversaries.py Outdated
@DavidMStraub

Copy link
Copy Markdown
Member

Thanks!

The next step is to add the persistent token management UI in the frontend; once we have that, I think this can be merged.

@elig-45

elig-45 commented Jul 23, 2026

Copy link
Copy Markdown
Contributor Author

Ok, I'm on it.

@elig-45

elig-45 commented Jul 23, 2026

Copy link
Copy Markdown
Contributor Author

Done in gramps-project/gramps-web#1007

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants