Skip to content

feat(for-you): switch useForYouFeed to dedicated /users/{id}/feed/for-you endpoint#14388

Merged
dylanjeffers merged 2 commits into
mainfrom
feat/for-you-feed-new-endpoint
May 22, 2026
Merged

feat(for-you): switch useForYouFeed to dedicated /users/{id}/feed/for-you endpoint#14388
dylanjeffers merged 2 commits into
mainfrom
feat/for-you-feed-new-endpoint

Conversation

@dylanjeffers
Copy link
Copy Markdown
Contributor

Summary

  • Adds getUserFeedForYou method to the generated UsersApi SDK (mirrors the pattern of getUserRecommendedTracks — same request shape minus timeRange, same Tracks response type)
  • Updates useForYouFeed to call the new method, dropping the now-unused timeRange param
  • The previous implementation fell back to the generic recommended-tracks endpoint; this wires the hook to the purpose-built pipeline introduced in feat(for-you): re-introduce /users/{id}/feed/for-you with lean 3-source pipeline api#817

Test plan

  • Feed page For You tab loads tracks from the new endpoint
  • Pagination (load more) works correctly
  • Unauthenticated users see an empty state (hook is disabled when currentUserId is null)
  • Explore page recommended tracks are unaffected (still use getUserRecommendedTracks)

🤖 Generated with Claude Code

…-you endpoint

The endpoint was re-introduced in AudiusProject/api#817 with a lean
3-source pipeline (in-network, trending, underground) + linear ranking +
diversity pass. Previous implementation fell back to the generic
recommended-tracks endpoint; this wires the hook to the purpose-built one.

Changes:
- Add GetUserFeedForYouRequest interface + getUserFeedForYou method to
  the generated UsersApi (mirrors the pattern of getUserRecommendedTracks)
- Update useForYouFeed to call getUserFeedForYou, dropping the now-unused
  timeRange param

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented May 22, 2026

⚠️ No Changeset found

Latest commit: d6c3742

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@github-actions
Copy link
Copy Markdown
Contributor

github-actions Bot commented May 22, 2026

🌐 Web preview ready

Preview URL: https://audius-web-preview-pr-14388.audius.workers.dev

Unique preview for this PR (deployed from this branch).
Workflow run

… hand-editing

The prior commit on this branch hand-added getUserFeedForYou to the generated
UsersApi.ts, which is the wrong layer — those files are produced by
openapi-generator from the API repo's swagger spec. Manual edits get wiped on
the next codegen run and the method name doesn't match the spec's operationId.

This re-runs `node ./src/sdk/api/generator/gen.js --spec <swagger>` against the
swagger from AudiusProject/api main (the for-you endpoint isn't in prod
swagger yet, so --env prod can't be used until it deploys). The generated
method is named `getUserForYouFeed` (from operationId "Get User For You Feed"),
not `getUserFeedForYou` as the hand-edit assumed — hook updated to match.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
@dylanjeffers dylanjeffers merged commit 57bf817 into main May 22, 2026
14 checks passed
@dylanjeffers dylanjeffers deleted the feat/for-you-feed-new-endpoint branch May 22, 2026 23:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant