All format testing (local testing)
testacc127000
Posted on March 7, 2022
Steps to integrate Razorpay
Setting up Razorpay account.
Storing API keys in settings.py
Installing Razorpay library.
Creating order using Razorpay API.
-
Creating order at backend and also creating Razorpay order.
- Show template
- render to payment.html
- Get info of call back URL
- Done with creating an order.
Uploading a File
There are three ways you can upload a file:
From an
Object
instanceFrom a
Bucket
instanceFrom the
client
In each case, you have to provide the Filename
, which is the path of the file you want to upload. You’ll now explore the three alternatives. Feel free to pick whichever you like most to upload the first_file_name
to S3.
@app.action("submit_your_response")
def submit_response(ack, body, client, logger):
reference_id = body["actions"][0]["value"]
# form_data = SlackForm.objects.filter(reference_id=reference_id).first()
form_data = form_data_2
form_view = utils.get_form_view_data(form_data)
form_view["private_metadata"] = reference_id
try:
ack()
result = client.views_open(trigger_id=body["trigger_id"], view=form_view)
logger.info("User clicked submit button")
except Exception as e:
logger.error(e)
https://gist.github.com/Nishant127/13898538d35a024b4d93a592b1b4a6ea
💖 💪 🙅 🚩
testacc127000
Posted on March 7, 2022
Join Our Newsletter. No Spam, Only the good stuff.
Sign up to receive the latest update from our blog.