Commit Graph

266 Commits

Author SHA1 Message Date
408325db40 test: remove no longer needed mock data 2025-12-06 18:27:57 -05:00
bdac969be9 test: migrate from bun to pnpm and vitest 2025-12-06 18:14:01 -05:00
20ad68669c ci: disable ci for now 2025-12-06 17:51:05 -05:00
dbc78727bd refactor: cleaned up REST code
Some checks failed
Deploy / Deploy (push) Has been cancelled
also removed any references to Anify
2025-12-06 10:01:16 -05:00
ec42ac4026 fix: currentPage not incrementing when loading watched titles 2025-12-06 10:01:12 -05:00
6f93c46f1e fix: 'retry-after' headers not being read properly 2025-12-06 09:11:57 -05:00
5f0302d25a feat: Implement home feed GraphQL resolver 2025-12-06 08:27:52 -05:00
4b4eac20a7 feat: Introduce HomeCategory enum and home feed query to schema 2025-12-06 08:27:52 -05:00
b0650fc840 feat: Implement and register user profile GraphQL resolver 2025-12-06 08:27:52 -05:00
fedc5e46da feat: Define User GraphQL types and user profile query 2025-12-06 08:27:52 -05:00
a2702db794 feat: Integrate asynchronous GraphQL context in Hono handler 2025-12-06 08:27:51 -05:00
311d575c09 feat: Refactor GraphQL context for user data and async creation 2025-12-06 08:27:49 -05:00
cc4f518de7 feat: add type safety to AniList fetching methods 2025-12-06 08:11:48 -05:00
9b5cc7ea62 refactor: move getWatchingTitles to AniList Durable Object
introduces caching to that method
2025-12-06 08:08:35 -05:00
c24ff62b30 chore: rename getUser to getUserProfile 2025-12-06 07:56:58 -05:00
495506935e refactor!: migrate from REST API to GraphQL
- Replace OpenAPI/REST endpoints with a single  route.
- Remove  and Swagger UI configuration.
- Disable OpenAPI schema extensions in Zod types.
- Refactor  to be request-agnostic.
- Update episode URL fetching to return standardized success/failure objects.
- Update project dependencies.
2025-12-06 07:30:51 -05:00
ad26cd6da3 feat: set up mock data to be used to generate baseline profiles 2025-12-06 07:27:14 -05:00
9d71199943 fix: make updatedAt in mediaListEntry optional 2025-11-29 10:48:28 -05:00
24d507a48f feat(tasks): implement long-term delayed tasks with KV and Cron 2025-11-29 09:03:21 -05:00
40fa0080b5 feat(api): expose updatedAt in watching titles 2025-11-29 09:03:10 -05:00
3bc1f9f2b7 chore: remove unused TURSO_URL 2025-11-29 09:02:20 -05:00
8ca710d30d fix(anilist): improve rate limit header parsing 2025-11-29 08:58:02 -05:00
0ca6705e26 chore: add worker-configuration.d.ts to .prettierignore 2025-11-29 08:55:15 -05:00
25f5f80696 refactor: Replace generic AnilistDurableObject fetch endpoint with dedicated methods and update their usage. 2025-11-29 06:22:08 -05:00
b1e46ad6eb feat: Centralize Anilist GraphQL queries, generalize Durable Object for multiple operations with caching, and add new controllers for search, popular titles, user data, and episode tracking. 2025-11-29 05:03:57 -05:00
a25111acbf feat: Re-enable Anilist response caching and configure proxy URL via environment variable. 2025-11-28 17:00:18 +08:00
bd958fb1ab feat: migrate to cloudflare d1 and queues 2025-11-28 16:32:35 +08:00
00e1f82d85 refactor: introduce a script runner for local development 2025-11-28 16:29:16 +08:00
6ff1d96017 build: migrate from bun to pnpm 2025-11-28 16:28:59 +08:00
2ec861473a chore: intellij generated files 2025-11-14 13:10:32 +08:00
959265484c feat: Add durable object for Anilist requests (#2)
This commit introduces a durable object to handle Anilist GraphQL requests, with the goal of preventing request duplication.

The durable object is designed to cache responses from the Anilist API, with a TTL based on the `nextAiringEpisode` field in the response.

Co-authored-by: google-labs-jules[bot] <161369871+google-labs-jules[bot]@users.noreply.github.com>
2025-11-14 13:07:36 +08:00
f6a3ea2649 fix(anilist): ️ improve SSE streaming
Fixes issues with SSE streaming by explicitly setting the content type and encoding headers.

Also, removes unnecessary destructuring in fetchEpisodes.
2025-10-31 13:13:34 -04:00
26037d592e test: mock Cloudflare worker environment
Adds a mock for cloudflare workers to enable testing
of code that relies on the cloudflare workers environment.
2025-08-10 19:52:54 -04:00
6de8c594b7 chore: Adds .env to .gitignore
Adds the `.env` file to the `.gitignore` to prevent accidental commits of environment variables.
2025-08-10 19:52:07 -04:00
8175d73df1 refactor: ♻️emoves Env parameter
Removes the `Env` parameter from several functions to simplify their signatures and rely on the global `env` for configuration.

This change reduces the number of arguments passed around, making the code cleaner and easier to maintain.
2025-08-10 19:22:14 -04:00
0b0078328c fix(aniplay): Migrates to Aniwatch only
Removes Consumet and consolidates episode fetching to use Aniwatch as the sole provider.

This simplifies the codebase and ensures a consistent data source for episodes and URLs.
Also updates `wrangler` and sets `ENABLE_ANIFY` to false.
2025-08-08 08:17:47 -07:00
d680c97bc6 Removes console logs from title matching
Cleans up the code by removing console log statements used for debugging during the title matching process. This improves code readability and avoids unnecessary logging in the production environment.
2025-04-23 10:21:26 -04:00
9c51aaa2b5 chore: updates dependencies, including libsql
Updates various dependencies to their latest versions, addressing potential bugs and security vulnerabilities. Specifically, it updates the libsql client to address an identified issue.
2025-04-23 10:16:44 -04:00
99f37a0684 fix: freeze zx version
Should hopefully unblock deployment
2025-04-23 10:09:46 -04:00
e71177acc7 delete test file 2025-04-23 10:03:04 -04:00
b8ae211956 feat(aniwatch): Improves title matching logic
- Enhances title matching accuracy when fetching Aniwatch IDs.
- Prioritizes user-preferred titles and falls back to English titles.
- Ensures only one fetch call is made per title if both english and userPreferred title are same.
- Adds a score threshold to filter low-quality matches.
- Fixes a bug where the episode list was not being returned.
2025-04-23 09:49:06 -04:00
00720565b4 feat: update Aniwatch provider to include headers 2025-04-08 08:41:57 -04:00
d1306f06ba Improves episode source retrieval from Aniwatch
Refactors episode source fetching to handle multiple servers.

It now attempts to retrieve the episode URL from multiple servers if the initial request fails, improving the chances of finding a valid source.
2025-03-06 09:35:10 -05:00
d589087ad9 fix: limit search query for aniwatch to 100 characters
more than that and the search fails automatically with a 404
2025-01-15 02:48:49 -05:00
da8a81a777 fix: return null for anify provider if filtered episodes returning nothing 2025-01-15 02:48:10 -05:00
51bfad78ce fix: filter out animepahe in anify
issue with animepahe is can't skip ahead (most likely because of the missing header that's not being used)
2025-01-15 02:47:41 -05:00
c7d8f3ffa4 feat: add id to User 2024-11-17 09:44:09 -05:00
d6a27e1fa4 fix: treat title as "unreleased" if title is too far away to schedule 2024-11-14 07:42:55 -05:00
ce82ae8990 feat: return user data when marking episode as watched 2024-11-14 07:37:04 -05:00
0a07cdc415 fix: upcoming query not working 2024-11-02 18:24:32 -04:00