Download the PHP package umanit/document-generator-bundle without Composer
On this page you can find all versions of the php package umanit/document-generator-bundle. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download umanit/document-generator-bundle
More information about umanit/document-generator-bundle
Files in umanit/document-generator-bundle
Package document-generator-bundle
Short Description This bundle is used to drive the document generator microservice developed by UmanIT: https://github.com/umanit/microservice-document-generator
License MIT
Homepage https://github.com/umanit/document-generator-bundle
Informations about the package document-generator-bundle
UmanIT - Document Generator Bundle
This bundle is used to drive the document generator microservice developed by UmanIT: https://github.com/umanit/microservice-document-generator
Installation
$ composer require umanit/document-generator-bundle
The bundle relies on HTTPlug to perform HTTP requests, so you will need to install a client implementation to use it. For example, the following will use the HTTPlug message factory and the Guzzle adapter.
$ composer require php-http/message php-http/guzzle6-adapter
Configuration
umanit_document_generator.base_uri
: Base URI of the API used to generate documents.umanit_document_generator.encryption_key
: (Optional) Key used to crypt message before calling the API. It must match the one defined in the micro-service.
Usage
The only exposed service is umanit_document_generator.document_generator
. It provides all the necessary methods to
communicate with the micro-service API.
You can generate PNG or PDF using an URL or a HTML source code string.
Examples:
Each methods provides an additional parameter to specify other supported options by the micro-service,
such as decode
for HTML generation or pageOptions
and scenario
for both types.
Data encryption
By default, messages are not encrypted before calling the API. If you want to enable this feature, ensure you have
define the umanit_document_generator.encryption_key
configuration the same as in the micro-service then call the
encryptData(true)
method on the service. The encryption could be disabled the same way by calling
encryptData(false)
.
All versions of document-generator-bundle with dependencies
ext-openssl Version *
ext-json Version *
psr/http-message Version ^1.0
php-http/httplug Version ^2.0
php-http/message-factory Version ^1.0
php-http/discovery Version ^1.7
symfony/options-resolver Version ^4.4|^5.0