sirumobile / infobip-notifier
Symfony Infobip Notifier Bridge
Installs: 144
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 3
Forks: 0
Open Issues: 0
Type:symfony-bridge
Requires
- php: >=7.2.5
- symfony/event-dispatcher: ^4.3|^5.0|^6.0
- symfony/http-client: ^4.3|^5.0|^6.0
- symfony/notifier: ^5.2|^6.0
Requires (Dev)
- phpunit/phpunit: ^8.0
README
Provides Infobip integration for Symfony Notifier.
Requirements
- PHP 7.2
- Symfony Notifier 5.2+, HttpClient and EventDispatcher components
- Your API key and base url from Infobip
Installation
$ composer require sirumobile/infobip-notifier
Add correct DSN with your Infobip credentials to ENV. Then configure notifier and add InfobipTransportFactory to your services.
# .env INFOBIP_DSN=infobip://YOUR_APIKEY@YOUR_API_HOST?from=SENDER_NAME
# ./config/packages/notifier.yaml framework: notifier: texter_transports: infobip: '%env(INFOBIP_DSN)%'
# ./config/services.yaml Siru\Notifier\Bridge\Infobip\InfobipTransportFactory: tags: [ texter.transport_factory ]
Delivery reports
You can add notifyUrl-option where Infobip will send delivery reports for each message. You will need to implement the callback controller yourself. Check Infobip API documentation for example payload.
# .env INFOBIP_DSN=infobip://YOUR_APIKEY@YOUR_API_HOST?from=SENDER_NAME¬ifyUrl=https://yourapplication/callback/path