From d78786cd0433aba48cac4cffd5ce8056c40980b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Roman=20M=C3=A1tyus?= Date: Thu, 18 Apr 2024 12:36:10 +0200 Subject: [PATCH] Add readme and changelog --- CHANGELOG.md | 2 ++ README.md | 8 ++++++++ 2 files changed, 10 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 736e287..1197c87 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,8 @@ All notable changes to this project will be documented in this file. Updates should follow the [Keep a CHANGELOG](http://keepachangelog.com/) principles. ## [Unreleased][unreleased] +#### Added +* MultiAuthorizator - for multiple types of authorization for handler #### Added * CorsPreflightHandlerInterface - resolve multiple service registered handler error diff --git a/README.md b/README.md index 786f1bc..6d146cc 100644 --- a/README.md +++ b/README.md @@ -371,6 +371,14 @@ services: - addApi(\Tomaj\NetteApi\EndpointIdentifier('GET', 1, 'users', 'cookie'), Tomaj\NetteApi\Authorization\CookieApiKeyAuthentication('api_key', @staticTokenRepository)) ``` +### Multiple authentication +You can use multiple types of authorization of API. + +```neon +services: + - Tomaj\NetteApi\Authorization\MultiAuthorizator([@Tomaj\NetteApi\Authorization\BearerTokenAuthorization, @Tomaj\NetteApi\Authorization\QueryApiKeyAuthentication]) +``` + ## Rate limit This library provides simple interface for API rate limit. All you need to do is implement this interface like in example below: