Files sharing should show a clearer message when share creation is rate limited
Nobody has claimed this yet.
Assessment
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Newbie friendliness
- 72/100
- Issue type
- Feature
- Clarity
- Mostly clear
- Activity status
- Quiet
- Tech stack
- javascript, php
Research direction
Start by tracing the Files sharing frontend's share creation request and compare its handling with ShareAPIController::createShare and the generic 429 response from RateLimitingMiddleware. Add a translated, dedicated message for HTTP 429 that explains the temporary per-user creation limit, then verify other share-creation errors still use their existing handling.
Written by the indexing model from the issue text.
Description
Steps to reproduce
- Sign in as a normal user.
- Open the sharing dialog for a file or folder.
- Create public link shares repeatedly until the
ShareAPIController::createShareuser rate limit is reached. - Try to create another share, either on the same item or another item.
Expected behavior
The UI should explain that share creation is temporarily rate limited, for example:
Share creation is temporarily rate limited. Please wait a few minutes before creating more shares.
Ideally it should also make clear that this is a per-user/time-window creation limit, not a per-file or per-folder share limit.
Actual behavior
The request returns HTTP 429 / Too Many Requests, but the Files sharing UI does not give enough context for admins or users to understand why share creation stopped. This can be mistaken for a per-file share limit or a broken sharing dialog.
Technical context
OCA\Files_Sharing\Controller\ShareAPIController::createShare is intentionally protected with:
#[UserRateLimit(limit: 20, period: 600)]
When the limit is exceeded, RateLimitingMiddleware returns a generic 429 response. The frontend currently falls back to the response metadata, if available, or a generic share creation error.
Suggested improvement
Handle 429 responses from the share creation request in the Files sharing frontend and show a dedicated translated message. This should avoid implying that the file/folder has reached a permanent sharing limit.
Notes
This issue is only about improving the user-facing error message. It does not request changing the existing rate limit.
- Dominant language
- PHP
- Stars
- 36.9k
- Forks
- 5.2k
- Avg merge
- 2d
- Merged PRs (30d)
- 725
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from nextcloud/server
-
3. to review
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
0. Needs triage 33-feedback bug feature: dashboard feature: files feature: theming needs info
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
0. Needs triage bug
Difficulty 2/5 1-3 hours Newbie friendliness 76/100
-
.htaccess whitelist missing .json/.ftl → files_pdfviewer locale 404s, PDF viewer stuck in English Open
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
0. Needs triage 34-feedback bug
Difficulty 1/5 1-3 hours Newbie friendliness 88/100
All issues in nextcloud/server
Similar issues
-
priority: p3
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
googleapis/librarian#7636 ·
-
0. Needs triage bug
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
nextcloud/fulltextsearch#1011 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 84/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
phpstan/phpstan-doctrine#794 ·
-
Difficulty 2/5 1-3 hours Newbie friendliness 74/100
Automattic/static-site-importer#1767 ·