Skip to content

fix(files_sharing): show clearer message when share creation is rate limited - #64705

Open
sundeep8967 wants to merge 2 commits into
nextcloud:masterfrom
sundeep8967:fix/sharing-rate-limit-message-60729
Open

sundeep8967 wants to merge 2 commits into
nextcloud:masterfrom
sundeep8967:fix/sharing-rate-limit-message-60729

Conversation

@sundeep8967

Copy link
Copy Markdown

Summary

When share creation hits the per-user rate limit (#[UserRateLimit(limit: 20, period: 600)] on ShareAPIController::createShare), the API returns HTTP 429 (Too Many Requests). Previously, the Files sharing frontend fell back to generic error notifications, leading users to believe the file or sharing dialog was broken.

This change:

  1. Catches HTTP 429 in ShareRequests.js (getErrorMessage) and surfaces a clear, dedicated translated notification:

    "Share creation is temporarily rate limited. Please wait a few minutes before creating more shares."

  2. Updates SharingEntryLink.vue and NewFileRequestDialog.vue to also display this dedicated message upon encountering HTTP 429 instead of generic failure alerts.
  3. Adds comprehensive unit tests covering 429 rate limit responses, custom backend error messages, and fallback defaults in ShareRequests.spec.ts.

Checklist

  • Code is properly formatted
  • Sign-off message is added to all commits
  • Tests (unit) are included
  • Documentation has been updated or is not required

…limited

Handle HTTP 429 response when creating shares by displaying a dedicated
translated rate-limiting message instead of a generic failure notice.

Signed-off-by: sundeep8967 <sundeep8967@gmail.com>
@sundeep8967
sundeep8967 requested a review from a team as a code owner September 23, 2026 20:22
@sundeep8967
sundeep8967 requested review from kristian-zendato, skjnldsv and sorbaugh and removed request for a team September 23, 2026 20:22

This branch has not been deployed

No deployments
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.

Files sharing should show a clearer message when share creation is rate limited

1 participant