PHPackages                             bigchicchicken/api-platform-rate-limiter-bundle - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Security](/categories/security)
4. /
5. bigchicchicken/api-platform-rate-limiter-bundle

ActiveApi-platform-bundle[Security](/categories/security)

bigchicchicken/api-platform-rate-limiter-bundle
===============================================

Bundle to controls how frequently certain APIs are allowed to be called for ApiPlatform

v1.0.0(3y ago)1161MITPHPPHP &gt;=8.1

Since Sep 21Pushed 3y ago1 watchersCompare

[ Source](https://github.com/BigChicChicken/ApiPlatformRateLimiterBundle)[ Packagist](https://packagist.org/packages/bigchicchicken/api-platform-rate-limiter-bundle)[ Docs](https://github.com/BigChicChicken/ApiPlatformRateLimiterBundle)[ RSS](/packages/bigchicchicken-api-platform-rate-limiter-bundle/feed)WikiDiscussions main Synced 1mo ago

READMEChangelogDependencies (10)Versions (2)Used By (0)

ApiPlatformRateLimiterBundle
============================

[](#apiplatformratelimiterbundle)

[![Packagist](https://camo.githubusercontent.com/ed3de0773fb986454d83d54eff3a8f92bdcec4e6a21445ee19a667c87eda3f42/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f62696763686963636869636b656e2f6170692d706c6174666f726d2d726174652d6c696d697465722d62756e646c65)](https://packagist.org/packages/bigchicchicken/api-platform-rate-limiter-bundle)

Bundle to controls how frequently certain APIs are allowed to be called for [ApiPlatform](https://api-platform.com/).

Installation
------------

[](#installation)

Install ApiPlatformRateLimiterBundle library using [Composer](https://getcomposer.org/):

```
composer require bigchicchicken/api-platform-rate-limiter-group-bundle
```

Add/Check activation in the file `config/bundles.php`:

```
// config/bundles.php

return [
    // ...
    ApiPlatformRateLimiterBundle\ApiPlatformRateLimiterBundle::class => ['all' => true],
];
```

Configure the [rate limiter](https://symfony.com/doc/current/rate_limiter.html) of Symfony :

```
# config/packages/rate_limiter.yaml

framework:
    rate_limiter:
        fixed_window_5_requests_every_10_minutes:
            policy: 'fixed_window'
            limit: 5
            interval: '10 minutes'
```

And pass the rate limiter to your API's operation :

```
