Download the PHP package gregurco/guzzle-bundle-oauth2-plugin without Composer
On this page you can find all versions of the php package gregurco/guzzle-bundle-oauth2-plugin. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Table of contents
Download gregurco/guzzle-bundle-oauth2-plugin
More information about gregurco/guzzle-bundle-oauth2-plugin
Files in gregurco/guzzle-bundle-oauth2-plugin
Download gregurco/guzzle-bundle-oauth2-plugin
More information about gregurco/guzzle-bundle-oauth2-plugin
Files in gregurco/guzzle-bundle-oauth2-plugin
Vendor gregurco
Package guzzle-bundle-oauth2-plugin
Short Description OAuth2 Plugin for Guzzle Bundle, a PHP HTTP client library and framework for building RESTful web service clients
License MIT
Homepage https://github.com/gregurco/GuzzleBundleOAuth2Plugin
Package guzzle-bundle-oauth2-plugin
Short Description OAuth2 Plugin for Guzzle Bundle, a PHP HTTP client library and framework for building RESTful web service clients
License MIT
Homepage https://github.com/gregurco/GuzzleBundleOAuth2Plugin
Please rate this library. Is it a good library?
Informations about the package guzzle-bundle-oauth2-plugin
Guzzle Bundle OAuth2 Plugin
This plugin integrates OAuth2 functionality into Guzzle Bundle, a bundle for building RESTful web service clients.
Prerequisites
- PHP 7.2 or above
- Guzzle Bundle
- guzzle-oauth2-plugin
Installation
To install this bundle, run the command below on the command line and you will get the latest stable version from Packagist.
Usage
Enable bundle
Find next lines in src/Kernel.php
:
and replace them by:
Basic configuration
With default grant type (client)
With password grant type
With client credentials in body
Options
Key | Description | Required | Example |
---|---|---|---|
base_uri | URL of oAuth2 server. | yes | https://example.com |
token_url | The path that will be concatenated with base_uri. Default: /oauth2/token |
no | /oauth/token |
client_id | The client identifier issued to the client during the registration process | yes | s6BhdRkqt3 |
client_secret | The client secret | no | 7Fjfp0ZBr1KtDRbnfVdmIw |
username | The resource owner username | for PasswordCredentials grant type | johndoe |
password | The resource owner password | for PasswordCredentials grant type | A3ddj3w |
auth_location | The place where to put client_id and client_secret in auth request. Default: headers. Allowed values: body, headers. |
no | body |
resource | The App ID URI of the web API (secured resource) | no | https://service.contoso.com/ |
private_key | Path to private key | for JwtBearer grant type | "%kernel.root_dir%/path/to/private.key" |
scope | One or more scope values indicating which parts of the user's account you wish to access | no | administration |
audience | no | ||
grant_type | Grant type class path. Class should implement GrantTypeInterface. Default: Sainsburys\\Guzzle\\Oauth2\\GrantType\\ClientCredentials |
no | Sainsburys\\Guzzle\\Oauth2\\GrantType\\PasswordCredentials Sainsburys\\Guzzle\\Oauth2\\GrantType\\AuthorizationCode Sainsburys\\Guzzle\\Oauth2\\GrantType\\JwtBearer |
persistent | Token will be stored in session unless grant_type is client credentials; in which case it will be stored in the app cache. Default: false |
no | |
retry_limit | How many times request will be repeated on failure. Default: 5 |
no |
See more information about middleware here.
License
This middleware is licensed under the MIT License - see the LICENSE file for details
All versions of guzzle-bundle-oauth2-plugin with dependencies
PHP Build Version
Package Version
Requires
php Version
>=7.2
guzzlehttp/guzzle Version ^6.5.8|^7.4.5
eightpoints/guzzle-bundle Version ^8.0
symfony/http-kernel Version ~5.0|~6.0|~7.0
symfony/config Version ~5.0|~6.0|~7.0
symfony/dependency-injection Version ~5.0|~6.0|~7.0
symfony/expression-language Version ~5.0|~6.0|~7.0
sainsburys/guzzle-oauth2-plugin Version ^3.0
guzzlehttp/guzzle Version ^6.5.8|^7.4.5
eightpoints/guzzle-bundle Version ^8.0
symfony/http-kernel Version ~5.0|~6.0|~7.0
symfony/config Version ~5.0|~6.0|~7.0
symfony/dependency-injection Version ~5.0|~6.0|~7.0
symfony/expression-language Version ~5.0|~6.0|~7.0
sainsburys/guzzle-oauth2-plugin Version ^3.0
The package gregurco/guzzle-bundle-oauth2-plugin contains the following files
Loading the files please wait ....