make some documentation

This commit is contained in:
Nomi Nonsense (Nonszy) 2023-09-08 00:15:46 +07:00
parent 5bf0eb08af
commit ec7e692c25
4 changed files with 23 additions and 1 deletions

19
README.md Normal file
View File

@ -0,0 +1,19 @@
# OTP with meme image
Leisure project. A REST API that sends a one-time authentication code (a.k.a OTP) but the code is in the text of a meme image.
## Summary
If it works perfectly the result will be like this:
![Example Outpus](./docs/example.png)
## Why this meme?
The meme used in this project is Shannon Smiling or better known as *The Guy Smiling And Wearing A Suit*, which is often paired with a negative text or _"My Reaction For That Information"_.
![Guy with suit](./docs/guy-with-suit.gif)
the reason why I chose this meme was inspired by a meme where a man screenshot the OTP sender's chat and he replied by sending a photo of himself posing cool. suddenly it gave me the idea to make an OTP system by sending pictures of people posing cool with the OTP code text.
Idk why I chose the photo of Shannon smiling, it's because I think with the meme photo of Shannon in addition to making a sense of humor but also as a sign of welcome and strengthens security.

BIN
docs/example.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 478 KiB

BIN
docs/guy-with-suit.gif Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 MiB

View File

@ -30,7 +30,10 @@ def hello():
@app.route('/send-otp', methods=['POST'])
def send_email():
mail_sender = "norman25.projects2@gmail.com"
# Create an .env file at the root of this project
# There are two values required here, EMAIL_SENDER_2 and EMAIL_PASSWORD_2
# Or you can change the value here and in .env file
mail_sender = os.environ.get("EMAIL_SENDER_2")
mail_password = os.environ.get("EMAIL_PASSWORD_2")
mail_receiver = request.args.get('email')