Skip to content

[Notifier] Add MessageBird notifier bridge #40646

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Apr 15, 2021
Merged

[Notifier] Add MessageBird notifier bridge #40646

merged 1 commit into from
Apr 15, 2021

Conversation

StaffNowa
Copy link
Contributor

@StaffNowa StaffNowa commented Mar 31, 2021

Q A
Branch? 5.x
Bug fix? no
New feature? yes
Deprecations? no
License MIT
Doc PR symfony/symfony-docs#15180
Recipe PR symfony/recipes/pull/922

MessageBird notifier https://developers.messagebird.com/docs/conversations/send-messages-curl/

Copy link
Contributor

@OskarStark OskarStark left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please see my comments 👍

@OskarStark
Copy link
Contributor

CleanShot 2021-03-31 at 14 07 03

It looks like your commiter email is not associated with your Github account 🤔

Copy link
Contributor

@OskarStark OskarStark left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@StaffNowa
Copy link
Contributor Author

Added recipes for message bird #40646

@StaffNowa
Copy link
Contributor Author

Added docs for message bird symfony/symfony-docs#15180

@StaffNowa
Copy link
Contributor Author

MessageBird documentation issue solved 👍

@StaffNowa
Copy link
Contributor Author

@fabpot updated composer.json

OskarStark added a commit that referenced this pull request Apr 6, 2021
…, StaffNowa)

This PR was merged into the 5.3-dev branch.

Discussion
----------

[Notifier] Add LightSms notifier bridge

| Q             | A
| ------------- | ---
| Branch?       | 5.x
| Bug fix?      | no
| New feature?  | yes <!-- please update src/**/CHANGELOG.md files -->
| Deprecations? | no <!-- please update UPGRADE-*.md and src/**/CHANGELOG.md files -->
| License       | MIT
| Doc PR        | symfony/symfony-docs/pull/15178
| Recipe PR | symfony/recipes#921

LightSms notifier https://github.com/D4DLab/lightsms-notifier

Commits
-------

37c665e * LightSmsTransport.php - make fabbot happy
68a12fa * fix tests
f1f83b9 * LightSmsTransport.php - use query string parameters
026dcd9 * LightSmsTransport.php - isset
2a9ac2d * LightSmsTransport.php - fix
4213564 * composer.json - fix Fabien comment from another pull request #40646
21e972a * coding standard
bea5256 * type cast. On success lightsms return error code like string. On error return integer.
9b2e2d0 * type cast. On success lightsms return error code like string. On error return integer.
0d7488b * type cast. On success lightsms return error code like string. On error return integer.
9a832ef * LightSmsTransport.php - via mistake removed www which return (Closing direction to the user). Removed additional isset which in reality not needed. Added new method which allow to return "unknown error" and throw exception if not successfully
178d9c2 * pull request #40696
95e82f6 Update LightSmsTransport.php
a197dee * LightSmsTransport.php - better to remove if we do not have it?
83d2598 * Coding Standard patch
1ff97e4 * LightSmsTransport.php - build signature and use http_build_query, timestamp int
1c993b7 * ERROR_CODES -> int * www. - bug * isset validate ['error']
1b59a7d * LightSmsTransport.php - string param
58ac708 * LightSmsTransport.php - return back www (without will not work). Now fail tests
b9f9ff8 * LightSmsTransport.php - tests fail
265f776 * LightSmsTransport.php - issue with Symfony\Component\Notifier\Bridge\LightSms\Tests\LightSmsTransportTest
23a446a * LightSmsTransport.php - issue with Symfony\Component\Notifier\Bridge\LightSms\Tests\LightSmsTransportTest
08235e5 * LightSmsTransport.php - bug fix
80ef5ba * LightSmsTransport.php - Unable to send the SMS: Closing direction to the user
08b0729 Update LightSmsTransport.php
7180c1f Update LightSmsTransport.php
f16b4d2 * phone changed to from
7f13dbf * sender changed to from
e20ef1e * LightSmsTransport.php - change + to 00
b0e64b9 * LightSmsTransport.php - not ok throw exception
fc13bb2 * LightSmsTransport.php - changed login for validation (the same like we have all places)
5d2e692 * LightSmsTransport.php - escape phone number
8620e82 * LightSmsTransport.php - move timestamp
66c34ba Update README.md
2e0e1d7 Update README.md
7b51e0d Update src/Symfony/Component/Notifier/Bridge/LightSms/LightSmsTransport.php
079406e Update src/Symfony/Component/Notifier/Bridge/LightSms/LightSmsTransport.php
0e41bc9 Update src/Symfony/Component/Notifier/Bridge/LightSms/Tests/LightSmsTransportFactoryTest.php
3d0d79c Update src/Symfony/Component/Notifier/Bridge/LightSms/Tests/LightSmsTransportFactoryTest.php
e0a68bd Update src/Symfony/Component/Notifier/Bridge/LightSms/LightSmsTransport.php
1b073c2 Update src/Symfony/Component/Notifier/Bridge/LightSms/LightSmsTransport.php
b0891be Update src/Symfony/Component/Notifier/Bridge/LightSms/LightSmsTransport.php
49b4780 Update src/Symfony/Component/Notifier/Bridge/LightSms/LightSmsTransport.php
b2e4638 Update src/Symfony/Component/Notifier/Bridge/LightSms/LightSmsTransport.php
c02dbbd Update src/Symfony/Component/Notifier/Bridge/LightSms/README.md
9f89014 Update src/Symfony/Component/Notifier/Bridge/LightSms/README.md
5e54dfe * LightSmsTransport.php - quick fix for private constant.
3cbbc85 * HOST split into two parts
9e1809e * small changes
febff46 Update src/Symfony/Component/Notifier/Bridge/LightSms/LICENSE
4a11b94 * github account author
728a3e2 * Transport.php - missing use
ce41756 * notifier_transports.php - Coding Standard
d1ccd46 * Attached file changes which are required to run the lightsms notifier
a0fae7d * tests
15686c0 * LightSmsTransport.php - Coding Standard
2f65b92 * LightSmsTransport.php - Coding Standard
6792535 * composer.json - requirements bug fix
167f325 * LightSmsTransport.php - logic error
be8f994 * LightSmsTransport.php - return type
f2ba226 * LightSmsTransport.php - bug fix
b075c0e * LightSms notifier
@OskarStark
Copy link
Contributor

CleanShot 2021-04-09 at 14 05 00@2x

Please add CHANGELOG file

@symfony symfony deleted a comment from StaffNowa Apr 9, 2021
Copy link
Contributor

@OskarStark OskarStark left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍🏻✅

@StaffNowa
Copy link
Contributor Author

Documentation too prepared symfony/symfony-docs#15180 :)

Copy link
Member

@Nyholm Nyholm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you.

I have a few comments that I would like to see addressed.


if (201 !== $response->getStatusCode()) {
if (!isset($response->toArray(false)['errors'])) {
throw new TransportException('Unable to send the SMS.');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Too few arguments for Symfony\Component\Notifier\Exception\TransportException::__construct - expecting 2 but saw 1

looks like $response is missing

@OskarStark
Copy link
Contributor

Please rebase, thanks

@StaffNowa
Copy link
Contributor Author

@OskarStark rebase, but still get the same strange error

Run ./vendor/bin/psalm.phar --output-format=github --no-progress
Error: Too few arguments for Symfony\Component\Notifier\Exception\TransportException::__construct - expecting 2 but saw 1
Error: Process completed with exit code 2.

Copy link
Member

@Nyholm Nyholm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you. Well done

@StaffNowa
Copy link
Contributor Author

Travis CI show errors @OskarStark

@OskarStark
Copy link
Contributor

It took time, but here we go, this is in now. Thank you very much Vasilij.

@OskarStark OskarStark merged commit 1ca10f5 into symfony:5.x Apr 15, 2021
@StaffNowa StaffNowa deleted the message-bird branch April 15, 2021 15:38
OskarStark added a commit to symfony/symfony-docs that referenced this pull request Apr 16, 2021
This PR was merged into the 5.3-dev branch.

Discussion
----------

[Notifier] [MessageBird] add docs

symfony/symfony#40646

Commits
-------

ee5ee00 * notifier.rst - message bird
@fabpot fabpot mentioned this pull request Apr 18, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

9 participants