Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/everlutionsk/sendin-blue-bundle
https://github.com/everlutionsk/sendin-blue-bundle
Last synced: about 1 month ago
JSON representation
- Host: GitHub
- URL: https://github.com/everlutionsk/sendin-blue-bundle
- Owner: everlutionsk
- Created: 2017-04-20T16:26:11.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2017-12-11T10:38:02.000Z (about 7 years ago)
- Last Synced: 2024-11-15T17:42:37.535Z (about 2 months ago)
- Language: PHP
- Size: 14.6 KB
- Stars: 0
- Watchers: 4
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# SendinBlueBundle
This Symfony bundle provides *mail system* for [Email Bundle](https://github.com/everlutionsk/EmailBundle2). Bundle uses [SendinBlue](https://www.sendinblue.com) transactional email platform.
# Installation
```sh
composer require everlutionsk/sendin-blue-bundle
```### Enable the bundle
```php
// app/AppKernel.php
public function registerBundles()
{
return array(
// ...
new Everlution\EmailBundle\EverlutionEmailBundle(),
new Everlution\SendinBlueBundle\EverlutionSendinBlueBundle(),
);
}
```### Configure the bundle
Following configuration snippet describes how to configure the bundle.
Firstly, you must modify EmailBundle configuration to work with SendinBlueBundle's services.
```yml
# app/config/config.yml# EmailBundle Configuration
everlution_email:
domain_name: '%domain%' # example.com
mail_system: everlution.sendin_blue.mail_system
async_stream: everlution.email.stream.kernel_terminate
request_processors:
inbound: everlution.sendin_blue.inbound.request_processor
outbound_message_event: everlution.sendin_blue.outbound.message_event.request_processor
```Secondly, you must configure SendinBlueBundle itself
```yml
# app/config/config.yml# SendinBlueBundle Configuration
everlution_sendin_blue:
api_key: SECRET_API_KEY
timeout: int|null
```**timeout** - [Optional] Email timeout in ms, default is 30000 (max. 60000)
# Usage### Message transformers
*Mail system* service provided by this bundle transform [OutboundMessage](https://github.com/everlutionsk/EmailBundle2/blob/master/Outbound/Message/OutboundMessage.php) into JSON and then POST this JSON to [SendinBlue API](https://apidocs.sendinblue.com/).
However, this JSON can be modified just before it is posted to SendinBlue. To do this you must create a service, which implements [RawMessageTransformer interface](Outbound/MailSystem/RawMessageTransformer.php) and add following tag:```yml
everlution.sendin_blue.outbound.raw_message_transformer
```# TODO
----
- Request Processors
- Request signature calculation
- Webhook keys configuration