API Error: Too Many Attempts #2782

Closed
opened 2026-02-05 05:11:26 +03:00 by OVERLORD · 3 comments
Owner

Originally created by @IceWreck on GitHub (May 8, 2022).

Describe the Bug

So I made a program which uses the API to periodically download my entire wiki as markdown, change URLs in pages to preserve interlinking, save it with git and generate a static site of the wiki with Hugo.

It downloads less than half the wiki and then all page downloads start erroring out with:

{"error":{"message":"Too Many Attempts.","code":429}}

I limited my concurrency to 10 page downloads at a time but its still happening. Any slower than that and it'll take hours to download my wiki.

Can I tweak the rate limiter ?

Steps to Reproduce

I'll put the entire code on github after cleaning it up but basically its downloading pages using /api/pages/<pageid>/export/markdown 10 at a time

Expected Behaviour

No rate limits when using the API, especially for admin users.

Screenshots or Additional Context

No response

Browser Details

No response

Exact BookStack Version

BookStack v22.04.1

PHP Version

No response

Hosting Environment

Linuxserver container image running on rootless Podman + mariadb from Rocky Linux repos

Originally created by @IceWreck on GitHub (May 8, 2022). ### Describe the Bug So I made a program which uses the API to periodically download my entire wiki as markdown, change URLs in pages to preserve interlinking, save it with git and generate a static site of the wiki with Hugo. It downloads less than half the wiki and then all page downloads start erroring out with: ```json {"error":{"message":"Too Many Attempts.","code":429}} ``` I limited my concurrency to 10 page downloads at a time but its still happening. Any slower than that and it'll take hours to download my wiki. Can I tweak the rate limiter ? ### Steps to Reproduce I'll put the entire code on github after cleaning it up but basically its downloading pages using `/api/pages/<pageid>/export/markdown` 10 at a time ### Expected Behaviour No rate limits when using the API, especially for admin users. ### Screenshots or Additional Context _No response_ ### Browser Details _No response_ ### Exact BookStack Version BookStack v22.04.1 ### PHP Version _No response_ ### Hosting Environment Linuxserver container image running on rootless Podman + mariadb from Rocky Linux repos
OVERLORD added the 🛠️ Enhancement🐛 Bug🔩 API Request labels 2026-02-05 05:11:26 +03:00
Author
Owner

@ssddanbrown commented on GitHub (May 9, 2022):

Hi @IceWreck,
You should be able to configure this rate limit by using adding the following options to your .env file then tweaking:

ca09ed916f/.env.example.complete (L346-L347)

It does look like we need to add this option to our documentation though since it's quite hidden right now.

@ssddanbrown commented on GitHub (May 9, 2022): Hi @IceWreck, You should be able to configure this rate limit by using adding the following options to your `.env` file then tweaking: https://github.com/BookStackApp/BookStack/blob/ca09ed916f73ae53998703bfe0e3489798485971/.env.example.complete#L346-L347 It does look like we need to add this option to our documentation though since it's quite hidden right now.
Author
Owner

@IceWreck commented on GitHub (May 9, 2022):

Thanks. Its working now.

@IceWreck commented on GitHub (May 9, 2022): Thanks. Its working now.
Author
Owner

@ssddanbrown commented on GitHub (May 9, 2022):

The in-built API docs have now been updated with a new "Rate Limits" section. This will be part of the next release.

@ssddanbrown commented on GitHub (May 9, 2022): The in-built API docs have now been updated with a new "Rate Limits" section. This will be part of the next release.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/BookStack#2782