Skip to main content

upstash-ratelimit-js

Lightweight guidance for using the Upstash Redis RateLimit TypeScript/JavaScript SDK, including setup steps, basic usage, and pointers to advanced algorithm, features, pricing, and traffic‑protection docs.

الانتقال إلى التثبيت

معلومات المصدر

المستودع
vn7n24fzkq/github-profile-summary-cards
آخر نشاط في المصدر
١٦ يوليو ٢٠٢٦ في ١٤:٢٥
لغة SKILL.md المكتشفة
الإنجليزية
النجوم
٣٬٦٥٨
التفرعات
٥١٧

خيارات التثبيت

يُحدَّد Prompt الذي يراجع المصدر أولًا بشكل افتراضي. يمكنك التبديل إلى أمر مباشر أو تنزيل نسخة محلية.

مراجعة ملفات المصدر

اقرأ SKILL.md وأي ملفات مرافقة يعرضها SkillsMP قبل أن تقرر التثبيت.

مستكشف الملفات
6 ملفات

عرض SKILL.md

SKILL.md
تعليمات المصدر · معاينة للقراءة فقط
name
upstash-ratelimit-js
description
Lightweight guidance for using the Upstash Redis RateLimit TypeScript/JavaScript SDK, including setup steps, basic usage, and pointers to advanced algorithm, features, pricing, and traffic‑protection docs.
# Rate Limit TS SDK ## Quick Start - Install the SDK and connect to Redis. - Create a rate limiter and apply it to incoming operations. Example: ```ts import { Ratelimit } from "@upstash/ratelimit"; import { Redis } from "@upstash/redis"; const redis = new Redis({ url: "<url>", token: "<token>" }); const limiter = new Ratelimit({ redis, limiter: Ratelimit.slidingWindow(5, "10s") }); const { success } = await limiter.limit("user-id"); if (!success) { // throttled } ``` ## Other Skill Files - **algorithms.md**: Describes all available rate‑limiting algorithms and how they behave. - **pricing-cost.md**: Explains pricing, Redis cost implications, and operational considerations. - **features.md**: Lists SDK features such as prefixes, custom keys, and behavioral options. - **methods-getting-started.md**: Full method reference for the SDK's API and getting started guide. - **traffic-protection.md**: Guidance on applying rate limiting for traffic shaping, abuse prevention, and protection patterns.
عرض على GitHub