Skip to content

Commit

Permalink
increased rate limit, edited README
Browse files Browse the repository at this point in the history
  • Loading branch information
Nutlope committed Sep 22, 2023
1 parent a710de0 commit 00f1a66
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 12 deletions.
12 changes: 2 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,17 +7,9 @@
Generate beautiful AI QR Codes in seconds. Powered by Vercel and Replicate.
</p>

<!-- <p align="center">
<a href="https://twitter.com/nutlope">
<img src="https://img.shields.io/twitter/follow/steventey?style=flat&label=nutlope&logo=twitter&color=0bf&logoColor=fff" alt="Hassan's Twitter follower count" />
</a>
<a href="https://twitter.com/kevinhou22">
<img src="https://img.shields.io/twitter/follow/steventey?style=flat&label=kevinhou22&logo=twitter&color=0bf&logoColor=fff" alt="Kevin's Twitter follower count" />
</a>
</p> -->
<p align="center">
<a href="https://codeium.com?repo_name=nutlope%2Fqrgpt">
<img src="https://codeium.com/badges/main" alt="Hassan's Twitter follower count" />
<img src="https://codeium.com/badges/main" alt="Codium" />
</a>
</p>

Expand All @@ -41,7 +33,7 @@

You can deploy this template to Vercel with the button below:

<!-- [![Deploy with Vercel](https://vercel.com/button)](https://stey.me/spirals-deploy) -->
[![Deploy with Vercel](https://vercel.com/button)](https://vercel.fyi/qrGPT)

Note that you'll need to:

Expand Down
4 changes: 2 additions & 2 deletions app/api/generate/route.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ const validateRequest = (request: QrGenerateRequest) => {

const ratelimit = new Ratelimit({
redis: kv,
// Allow 15 requests from the same IP in 1 day.
limiter: Ratelimit.slidingWindow(15, '1 d'),
// Allow 20 requests from the same IP in 1 day.
limiter: Ratelimit.slidingWindow(20, '1 d'),
});

export async function POST(request: NextRequest) {
Expand Down

0 comments on commit 00f1a66

Please sign in to comment.