DEV Community

Cover image for devto gist testing
testacc127000
testacc127000

Posted on

1 1

devto gist testing

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 instance

  • From a Bucket instance

  • From 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.

from django.urls import path
from django.contrib import admin
from . import views
urlpatterns = [
path("admin/", admin.site.urls),
path("", views.home, name="home"),
path("payment/", views.order_payment, name="payment"),
path("callback/", views.callback, name="callback"),
]
view raw urls.py hosted with ❤ by GitHub
class PaymentStatus:
SUCCESS = "Success"
FAILURE = "Failure"
PENDING = "Pending"
view raw constants.py hosted with ❤ by GitHub

AWS Security LIVE!

Tune in for AWS Security LIVE!

Join AWS Security LIVE! for expert insights and actionable tips to protect your organization and keep security teams prepared.

Learn More

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs

👋 Kindness is contagious

Explore a sea of insights with this enlightening post, highly esteemed within the nurturing DEV Community. Coders of all stripes are invited to participate and contribute to our shared knowledge.

Expressing gratitude with a simple "thank you" can make a big impact. Leave your thanks in the comments!

On DEV, exchanging ideas smooths our way and strengthens our community bonds. Found this useful? A quick note of thanks to the author can mean a lot.

Okay