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

⚡ Write a sendMessage() Function using Python #3956 #48

Merged
merged 29 commits into from
Dec 20, 2022

Conversation

Rinshin-Jalal
Copy link
Contributor

@Rinshin-Jalal Rinshin-Jalal commented Oct 5, 2022

Closes #3956

Description

According to the issue #3956 on appwrite,

I created a Python Cloud Function for sending a message using a specific channel to a receiver

It can send mail (using mailgun), send discord messages (webhook), send a tweet, and send SMS (using Twilio)

Screenshots

1. Sending SMS

payload and response

image

message received

image

2. Sending Email

payload and response

image

email received

image

3. Tweet

payload and response

image

Tweeted

image

4. Sending Discord message

payload and response

image

message received
image

Copy link
Contributor

@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.

@Rinshin-Jalal Great PR! 🤯 We left some comments during the review, please check them out.

python/send_message/README.md Outdated Show resolved Hide resolved
python/send_message/README.md Outdated Show resolved Hide resolved
python/send_message/main.py Outdated Show resolved Hide resolved
python/send_message/main.py Outdated Show resolved Hide resolved
python/send_message/README.md Outdated Show resolved Hide resolved

* **TWITTER_ACCESS_TOKEN** - Access Token from Twitter

* **TWITTER_API_KEY_SECRET** - Access Token Secret from Twitter
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
* **TWITTER_API_KEY_SECRET** - Access Token Secret from Twitter
* **TWITTER_ACCESS_TOKEN_SECRET** - Access Token Secret from Twitter

A duplicate of TWITTER_API_KEY_SECRET, should be TWITTER_ACCESS_TOKEN_SECRET.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

fixed in commit

@Rinshin-Jalal
Copy link
Contributor Author

Fixed more things

Co-authored-by: Afzal Ansari <afzal442@gmail.com>
@stnguyen90 stnguyen90 requested review from thinkverse and afzal442 and removed request for thinkverse and afzal442 October 24, 2022 16:11
Copy link
Contributor

@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.

@Rinshin-Jalal, I left some comments during the review, please check them out.

python/send_message/main.py Outdated Show resolved Hide resolved
@stnguyen90 stnguyen90 requested review from thinkverse and removed request for afzal442 October 24, 2022 16:20
Co-authored-by: Steven <1477010+stnguyen90@users.noreply.github.com>
@Rinshin-Jalal Rinshin-Jalal requested review from stnguyen90 and removed request for thinkverse and stnguyen90 October 24, 2022 17:46
Rinshin-Jalal and others added 3 commits October 29, 2022 22:29
Co-authored-by: Aditya Oberai <adityaoberai1@gmail.com>
Co-authored-by: Aditya Oberai <adityaoberai1@gmail.com>
Co-authored-by: Aditya Oberai <adityaoberai1@gmail.com>
@Rinshin-Jalal
Copy link
Contributor Author

@adityaoberai thanks for the review

I have committed the changes

@stnguyen90 stnguyen90 self-requested a review October 30, 2022 01:20
@Meldiron
Copy link
Contributor

Thank you so much for the PR 🤩. We're adding the hacktoberfest-accepted label to ensure this PR counts towards your Hacktoberfest contributions count. With that said, please stay active on this PR to address any comments once you receive a review. Happy Hacktoberfest! 🎃

python/send_message/README.md Outdated Show resolved Hide resolved
python/send_message/main.py Outdated Show resolved Hide resolved
Copy link
Contributor

@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.

Some problems from the last change.

@Rinshin-Jalal
Copy link
Contributor Author

Rinshin-Jalal commented Nov 2, 2022

@stnguyen90 fixed everything ( I think so )

Full working rn!

Copy link
Contributor

@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.

The code is looking beautiful! 🤩 Just 2 more comments 🙏🏼

python/send_message/functions/send_email_mailgun.py Outdated Show resolved Hide resolved
python/send_message/README.md Outdated Show resolved Hide resolved
Copy link
Contributor

@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.

The curl command is still incorrect.

python/send_message/README.md Outdated Show resolved Hide resolved
Copy link
Contributor

@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!

@christyjacob4 christyjacob4 merged commit e9de214 into open-runtimes:main Dec 20, 2022
@christyjacob4
Copy link
Contributor

THANK YOU! All changes merged 🥳

Please reach out to me on our Discord server if you would like to claim your Appwrite swags! As a way of saying thank you, we would also love to invite you to join the Appwrite organization on GitHub. Please share your GitHub username with us on Discord.  

You can accept the invite by visiting https://github.com/orgs/appwrite/invitation. By joining our team, you will officially be an Appwrite maintainer on GitHub.

You can change your membership visibility settings, so your new Appwrite team membership badge will show up on your personal GitHub profile.

Please feel free to look for more PRs you might be interested in helping with on our long list of Hacktoberfest friendly issues and help make Appwrite better :)

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.

⚡ Write a sendMessage() Function using Python
7 participants