Commit Graph

55 Commits

Author SHA1 Message Date
Julien Calixte
62f981dd93 feat: fire webhooks on jetstream events, cap at 10 per DID
- db.ts: getWebhooksByDid returns the 10 most recent subscriptions (ORDER BY id DESC LIMIT 10)
- jetstream.ts: fireWebhooks fans out to registered URLs via Promise.allSettled after each create/update/delete event
2026-02-25 22:51:48 +01:00
Julien Calixte
373b7a6777 feat: add webhook_subscription table and CRUD endpoints
- Migration: CREATE TABLE webhook_subscription (id, did, method, url) with index on did
- db.ts: addWebhookSubscription and deleteWebhooksByDid helpers
- server.ts: POST /:did/webhooks (201) and DELETE /:did/webhooks (204)
2026-02-25 22:46:45 +01:00
Julien Calixte
6cc7866080 chore: move to France Relay 2026-02-19 11:51:25 +01:00
Julien Calixte
cce66e26d5 logs: remove log of cursors 2026-02-17 15:38:37 +01:00
Julien Calixte
c9edd63e76 refacto: use @db/sqlite for better usage 2026-02-17 15:32:05 +01:00
Julien Calixte
1c7a4d3a11 fix: remove db-journal from git 2026-02-17 14:07:09 +01:00
Julien Calixte
8e6ac4faa9 fix: add multiple access to db 2026-02-17 14:02:39 +01:00
Julien Calixte
c84b4c5f97 robustness: split jetstream into own container, add cursor persistence
Jetstream was running backgrounded in the same container as the API server,
so crashes went undetected and Docker never restarted it. Now each process
runs as a separate docker-compose service with independent restart policies.

Also adds cursor persistence to SQLite (saved every 5s) so restarts resume
from where they left off, moves event destructuring inside try/catch blocks,
and adds global unhandled error/rejection handlers for crash visibility.
2026-02-17 01:17:42 +01:00
Julien Calixte
1a7841b728 adding logs again... 2026-02-16 22:21:21 +01:00
Julien Calixte
37b95d9196 revert to not polute logs 2026-02-16 22:16:20 +01:00
Julien Calixte
627168cf30 logs: add log for intention 2026-02-16 22:06:55 +01:00
Julien Calixte
d1afdd6499 prune: remove unused imports 2026-02-15 13:10:50 +01:00
Julien Calixte
5c31be6aa9 logs: better error handling 2026-02-15 12:35:44 +01:00
Julien Calixte
e0e095f7e5 fix: deletion should come from pds events 2026-02-15 09:24:40 +01:00
Julien Calixte
efb78ff14e logs: add ISO timestamp to all log output 2026-02-15 08:59:37 +01:00
Julien Calixte
562a3b061f refacto: no magic numbers 2026-02-14 22:47:48 +01:00
Julien Calixte
d950d5cb48 logs: add log for upserts 2026-02-14 22:47:06 +01:00
Julien Calixte
a7a90ea075 feat: authenticate DELETE endpoint with AT Protocol identity
Verify the caller owns the DID by resolving their PDS via plc.directory
and validating the session token before allowing note deletion.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-14 20:38:40 +01:00
Julien Calixte
51ea8a8f17 feat: implement delete note endpoint in server
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-14 20:28:30 +01:00
Julien Calixte
1534b1be4f rebranding to Remanso 2026-02-14 12:08:22 +01:00
Julien Calixte
50204b72ef feat: add theme and fonts to lexicon 2026-02-14 01:02:07 +01:00
Julien Calixte
a30c1ce43e fix: default dates to now 2026-02-13 20:26:15 +01:00
Julien Calixte
c44c2bac3f logs: add logs for jetstream 2026-02-13 20:14:12 +01:00
Julien Calixte
de92a554ee feat: handle note deletion from jetstream 2026-02-10 17:43:00 +01:00
Julien Calixte
958eb063dc logs: simplify logs 2026-02-10 10:21:16 +01:00
Julien Calixte
59b3db29c3 fix: remove one value in upsert note 2026-02-09 23:02:16 +01:00
Julien Calixte
8ca67971f2 chore: add volume 2026-02-09 22:49:08 +01:00
Julien Calixte
07ce1f29b1 chore: fix variables 2026-02-09 22:34:20 +01:00
Julien Calixte
e46714230f prune: remove content prop 2026-02-09 22:12:58 +01:00
Julien Calixte
069951dff2 fix: run database migration before starting services in Dockerfile
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-09 22:02:13 +01:00
Julien Calixte
5fb8167263 refacto: add extension 2026-02-09 22:01:32 +01:00
Julien Calixte
f72f622860 docs: update README to reflect Deno setup and project details
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-09 21:26:18 +01:00
Julien Calixte
575852c124 chore: add CLAUDE.md with project guidance for Claude Code
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-09 21:14:23 +01:00
Julien Calixte
f5f02dbc6d feat: add CORS middleware to allow all origins
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-09 19:33:47 +01:00
Julien Calixte
6e22fd2f56 feat: add endpoints to get notes 2026-02-09 14:07:17 +01:00
Julien Calixte
ed157cb4df lint: format and lint 2026-02-09 12:03:27 +01:00
Julien Calixte
878847b5d2 chore: deno activated 2026-02-09 12:00:05 +01:00
Julien Calixte
55699f0727 feat: add a server for querying notes 2026-02-09 11:53:49 +01:00
Julien Calixte
d677ed24c3 chore: migrate to deno 2026-02-09 10:28:12 +01:00
Julien Calixte
ee8421c773 feat: add Dockerfile and GitLab CI/CD pipeline
Add Docker containerization with Deno and persistent SQLite volume.
Add GitLab CI pipeline with build and deploy stages.
Use SQLITE_PATH env var for configurable DB location.
2026-02-09 00:30:21 +01:00
Julien Calixte
6988450446 feat: upsert is easier 2026-02-09 00:17:38 +01:00
Julien Calixte
7e956c3293 chore: allow read write 2026-02-08 23:37:05 +01:00
Julien Calixte
893fdfadd8 remove db 2026-02-08 23:36:24 +01:00
Julien Calixte
ef2c5c2a85 no db in git 2026-02-08 23:35:57 +01:00
Julien Calixte
2312240d10 feat: init db 2026-02-08 23:26:52 +01:00
Julien Calixte
ab1be0efb6 chore: migrate to deno 2026-02-08 20:53:15 +01:00
Julien Calixte
6616c35ba4 prune: remove deadcode 2026-02-08 20:33:06 +01:00
Julien Calixte
3c69c8a241 lint 2026-02-08 15:28:25 +01:00
Julien Calixte
9f2a34554b feat: blob images 2026-02-08 15:12:41 +01:00
Julien Calixte
fa3481b071 feat: on error too 2026-02-08 13:52:03 +01:00