Skip to content
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

Feat 6396 Postmark Messaging Adapter #26

Open
wants to merge 9 commits into
base: main
Choose a base branch
from

Conversation

thinkverse
Copy link

@thinkverse thinkverse commented Oct 2, 2023

What does this PR do?

This PR implements a simple Postmark Email adapter.

Test Plan

Included test suite has been marked as skipped given no API key is available in CI. But the test plan is described as follows:

While Postmark provides an API key for testing the key only verifies the data is correct. So I opted to include a new E2E test for Postmark. To run it, a Postmark account with a domain attached and two email accounts are required.

  1. Create a new account on https://postmarkapp.com/
  2. Follow the steps outlined by Postmark for a Sender Signature.
  3. Have two email addresses available on your attached domain.
  4. Grab your API key from Servers > My First Server > API tokens
  5. Open utopia-php/messaging root directory in a terminal.
  6. Run composer install to install PHPUnit and related packages.

Now the E2E can be executed with the provided API key as the environment variable POSTMARK_API_KEY. The TEST_EMAIL and TEST_FROM_EMAIL must be open, real email addresses and are required to be of the same domain. Namely, the same domain as your Sender Signature.

POSTMARK_API_KEY= TEST_EMAIL= TEST_FROM_EMAIL= ./vendor/bin/phpunit tests/e2e/Email/PostmarkTest.php

Included below is a video showing the E2E test running:

Screen.Recording.2023-10-02.at.04.25.07.mov

Related PRs and Issues

Closes: appwrite/appwrite#6396

Have you read the Contributing Guidelines on issues?

Yes. 👍

@stnguyen90 stnguyen90 self-requested a review October 5, 2023 15:50
Copy link

@stnguyen90 stnguyen90 left a comment

Choose a reason for hiding this comment

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

This looks great! Thanks for the video as well!

Copy link

@stnguyen90 stnguyen90 left a comment

Choose a reason for hiding this comment

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

Hey 👋 awesome work on your PR! We've approved your work and it'll be merged soon!

@gewenyu99
Copy link

Hey there! There were a lot of big PRs during this Hacktoberfest, and we wanted to give everyone ample time to collaborate with our engineering team. If you were able to merge your PRs during October, amazing. If it’s still not merged, don’t worry about it either. Either way, we’ve got your Hacktoberfest swag minted and ready to ship.

Please comment with your Discord username here so we can contact you about your shipping information to deliver your Hacktoberfest swag.

@thinkverse
Copy link
Author

Please comment with your Discord username here so we can contact you about your shipping information to deliver your Hacktoberfest swag.

thinkverse

@gewenyu99
Copy link

@thinkverse Will reach out soon. Trying to put forms together for everyone. Thank you for your patience!

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.

💬 Improve Appwrite Messaging with Postmark Adapter
4 participants