Developed with love by KnpLabs Hire us for your project!
105

HttplugBundle

by php-http

Symfony Framework Integration for HTTPlug

No readme file found in bundle.
Copyright (c) 2015 PHP HTTP Team <team@php-http.org>

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is furnished
to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
httplug:
clients:

# Prototype
name:

# The service id of a factory to use when creating the adapter.
factory: httplug.factory.auto

# Set to true to get the client wrapped in a FlexibleHttpClient which emulates async or sync behavior.
flexible_client: false

# Set to true to get the client wrapped in a HttpMethodsClient which emulates provides functions for HTTP verbs.
http_methods_client: false

# Set to true to get the client wrapped in a BatchClient which allows you to send multiple request at the same time.
batch_client: false
config: Array

# A list of plugin service ids and client specific plugin definitions. The order is important.
plugins:
authentication:

# Prototype
name:
type: ~ # Required
username: ~
password: ~
token: ~
service: ~
cache:
enabled: false

# This must be a service id to a service implementing Psr\Cache\CacheItemPoolInterface
cache_pool: ~ # Required

# This must be a service id to a service implementing Http\Message\StreamFactory
stream_factory: httplug.stream_factory
config:

# This must be a service id to a service implementing Http\Client\Common\Plugin\Cache\Generator\CacheKeyGenerator
cache_key_generator: ~

# The minimum time we should store a cache item
cache_lifetime: ~

# The default max age of a Response
default_ttl: ~

# Hashing algorithm to use
hash_algo: ~

# Which request methods to cache
methods:

# Defaults:
- GET
- HEAD

# Whether we should care about cache headers or not [DEPRECATED]
respect_cache_headers: ~

# A list of cache directives to respect when caching responses
respect_response_cache_directives: ~
cookie:
enabled: false

# This must be a service id to a service implementing Http\Message\CookieJar
cookie_jar: ~ # Required
history:
enabled: false

# This must be a service id to a service implementing Http\Client\Common\Plugin\Journal
journal: ~ # Required
decoder:
enabled: false
use_content_encoding: true
logger:
enabled: false

# This must be a service id to a service implementing Psr\Log\LoggerInterface
logger: logger

# This must be a service id to a service implementing Http\Message\Formatter
formatter: ~
redirect:
enabled: false
preserve_header: true
use_default_for_multiple: true
retry:
enabled: false
retry: 1
stopwatch:
enabled: false

# This must be a service id to a service extending Symfony\Component\Stopwatch\Stopwatch
stopwatch: debug.stopwatch

# Reference to a plugin service
reference:
enabled: false

# Service id of a plugin
id: ~ # Required

# Set scheme, host and port in the request URI.
add_host:
enabled: false

# Host name including protocol and optionally the port number, e.g. https://api.local:8000
host: ~ # Required

# Whether to replace the host if request already specifies one
replace: false

# Set a base URI to the request.
base_uri:
enabled: false

# Base Uri including protocol, optionally the port number and prepend path, e.g. https://api.local:8000/api
uri: ~ # Required

# Whether to replace the host if request already specifies one
replace: false

# Append headers to the request. If the header already exists the value will be appended to the current value.
header_append:
enabled: false

# Keys are the header names, values the header values
headers:

# Prototype
name: []

# Set header to default value if it does not exist.
header_defaults:
enabled: false

# Keys are the header names, values the header values
headers:

# Prototype
name: []

# Set headers to requests. If the header does not exist it wil be set, if the header already exists it will be replaced.
header_set:
enabled: false

# Keys are the header names, values the header values
headers:

# Prototype
name: []

# Remove headers from requests.
header_remove:
enabled: false

# List of header names to remove
headers: []

# Global plugin configuration. Plugins need to be explicitly added to clients.
plugins:
authentication:

# Prototype
name:
type: ~ # Required
username: ~
password: ~
token: ~
service: ~
cache:
enabled: false

# This must be a service id to a service implementing Psr\Cache\CacheItemPoolInterface
cache_pool: ~ # Required

# This must be a service id to a service implementing Http\Message\StreamFactory
stream_factory: httplug.stream_factory
config:

# This must be a service id to a service implementing Http\Client\Common\Plugin\Cache\Generator\CacheKeyGenerator
cache_key_generator: ~

# The minimum time we should store a cache item
cache_lifetime: ~

# The default max age of a Response
default_ttl: ~

# Hashing algorithm to use
hash_algo: ~

# Which request methods to cache
methods:

# Defaults:
- GET
- HEAD

# Whether we should care about cache headers or not [DEPRECATED]
respect_cache_headers: ~

# A list of cache directives to respect when caching responses
respect_response_cache_directives: ~
cookie:
enabled: false

# This must be a service id to a service implementing Http\Message\CookieJar
cookie_jar: ~ # Required
history:
enabled: false

# This must be a service id to a service implementing Http\Client\Common\Plugin\Journal
journal: ~ # Required
decoder:
enabled: true
use_content_encoding: true
logger:
enabled: true

# This must be a service id to a service implementing Psr\Log\LoggerInterface
logger: logger

# This must be a service id to a service implementing Http\Message\Formatter
formatter: ~
redirect:
enabled: true
preserve_header: true
use_default_for_multiple: true
retry:
enabled: true
retry: 1
stopwatch:
enabled: true

# This must be a service id to a service extending Symfony\Component\Stopwatch\Stopwatch
stopwatch: debug.stopwatch

# Configure which service the main alias point to.
main_alias:
client: httplug.client.default
message_factory: httplug.message_factory.default
uri_factory: httplug.uri_factory.default
stream_factory: httplug.stream_factory.default

# Overwrite a service class instead of using the discovery mechanism.
classes:
client: ~
message_factory: ~
uri_factory: ~
stream_factory: ~

# Extend the debug profiler with information about requests.
profiling:

# Turn the toolbar on or off. Defaults to kernel debug mode.
enabled: false
formatter: ~

# Limit long HTTP message bodies to x characters. If set to 0 we do not read the message body. Only available with the default formatter (FullHttpMessageFormatter).
captured_body_length: 0

# Control what clients should be found by the discovery.
discovery:

# Set to "auto" to see auto discovered client in the web profiler. If provided a service id for a client then this client will be found by auto discovery.
client: auto

# Set to "auto" to see auto discovered client in the web profiler. If provided a service id for a client then this client will be found by auto discovery.
async_client: ~
  • prepare release
    By dbu, 2 months ago
  • Merge pull request #254 from stof/patch-2
    By web-flow, 3 months ago
  • Make main aliases public
    By web-flow, 3 months ago
  • Add BaseUriPlugin support. fix #235 (#240)
    By dbu, 3 months ago
  • Removed symfony/asset depedency by inlining js/css (#251)
    By fbourigault, 3 months ago
  • Merge pull request #252 from php-http/patch-1
    By web-flow, 3 months ago
  • Empty configuration should not contain any data.
    By Nyholm, 3 months ago
  • Add mock client factory for test purpose. (#242)
    By dbu, 4 months ago
  • Don't remove abstract plugins (#247)
    By fbourigault, 4 months ago
  • symfony 4 has been released, remove stability=rc (#246)
    By Nyholm, 4 months ago
  • Work around same-name import bug in PHP 5.6 (#239)
    By web-flow, 5 months ago
  • Share some data with a secret test tool by Nyholm (#237)
    By dbu, 5 months ago
  • Removed "end year" form the license file (#236)
    By web-flow, 5 months ago
  • Full symfony 4 dependencies (#232)
    By Nyholm, 5 months ago
  • improve changelog (#233)
    By Nyholm, 5 months ago
  • Merge pull request #229 from xabbuh/dependencies
    By web-flow, 5 months ago
  • update the list of required dependencies
    By xabbuh, 5 months ago
  • Merge pull request #231 from php-http/nyholm-changelog
    By web-flow, 5 months ago
  • Added some change log
    By Nyholm, 5 months ago
  • Merge pull request #228 from fbourigault/feature/symfony4
    By web-flow, 5 months ago
  • don't make clients explicitly public
    By fbourigault, 5 months ago
  • add a hack to allow testing against private services without rewriting a large part of tests
    By fbourigault, 5 months ago
  • Update composer.json for Symfony 4.
    By fbourigault, 5 months ago
  • Use flex client wrapper for profiling if needed (#209)
    By fbourigault, 5 months ago
  • Merge pull request #226 from xabbuh/silence-tests
    By web-flow, 5 months ago
  • Merge pull request #227 from php-http/Nyholm-patch-1
    By web-flow, 5 months ago
  • turn off unneeded noise in tests
    By xabbuh, 5 months ago
  • Fixed typo
    By web-flow, 5 months ago
  • Merge pull request #225 from xabbuh/dev-job
    By web-flow, 5 months ago
  • Merge pull request #224 from xabbuh/cache-phpunit-bridge-install
    By web-flow, 5 months ago