Cashfree Verification API's.
Project description
Cashfree PG Python SDK
The Cashfree PG Python SDK offers a convenient solution to access Cashfree PG APIs from a server-side Go applications.
Documentation
Cashfree's PG API Documentation - https://docs.cashfree.com/reference/pg-new-apis-endpoint
Learn and understand payment gateway workflows at Cashfree Payments here
Try out our interactive guides at Cashfree Dev Studio !
Getting Started
Installation
pip install cashfree_pg
Configuration
from cashfree_pg.models.create_order_request import CreateOrderRequest
from cashfree_pg.api_client import Cashfree
from cashfree_pg.models.customer_details import CustomerDetails
Cashfree.XClientId = "<x-client-id>"
Cashfree.XClientSecret = "<x-client-secret>"
Cashfree.XEnvironment = Cashfree.SANDBOX
x_api_version = "2022-09-01"
Generate your API keys (x-client-id , x-client-secret) from Cashfree Merchant Dashboard
Basic Usage
Create Order
customerDetails = CustomerDetails(customer_id="walterwNrcMi", customer_phone="9999999999")
orderMeta = CreateOrderRequestOrderMeta(return_url="https://www.cashfree.com/devstudio/preview/pg/web/checkout?order_id={order_id}")
createOrderRequest = CreateOrderRequest(order_amount=1, order_currency="INR", customer_details=customerDetails, order_meta=orderMeta)
try:
api_response = Cashfree().PGCreateOrder(x_api_version, createOrderRequest, None, None)
print(api_response.data)
except Exception as e:
print(e)
Get Order
try:
api_response = Cashfree().PGFetchOrder(x_api_version, "order_3242X4jQ5f0S9KYxZO9mtDL1Kx2Y7u", None)
print(api_response.data)
except Exception as e:
print(e)
Supported Resources
Licence
Apache Licensed. See LICENSE.md for more details
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for cashfree_verification-1.0.1.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | d820a417f36f4183507d9ce076c85312f1a22eb9f95d36375c9524bef21b6bb2 |
|
MD5 | 73467d1ca03b629e1099cb0ca7d79ae9 |
|
BLAKE2b-256 | 9fe409c37dafee3f529075ee8cfc1bc5bdd6cd59c48c7a23c2671fb7a3f83a52 |
Close
Hashes for cashfree_verification-1.0.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 4bd85d9c0d72ebc4fcdf1b6877433c78d7a73196c94c06303177f3ac8a9e0ba5 |
|
MD5 | 7ead9a2d34c775207c98e75aaaf18641 |
|
BLAKE2b-256 | cba708e3d86c277fff494e96d18d7f74b5cd7d88ad1f0f65167d01c2beaee7da |