Integrate with
to create an order. Given below is the sample code for Create an Order API. Pass theaccount_id
of the sub-merchant using X-Razorpay-Account
in the header.
curl -X POST https://api.razorpay.com/v1/orders \-u [CLIENT_ID]:[CLIENT_SECRET] \-H 'content-type:application/json' \-H 'X-Razorpay-Account: acc_Ef7ArAsdU5t0XL' \-d '{"amount": 50000,"currency": "INR","receipt": "rcptid_11"}'
Here is the list of parameters and their description for creating an order:
amount
mandatory
integer
The transaction amount, expressed in the currency subunits. For example, for an actual amount of ₹300.00, the value of this field should be 30000
.
currency
mandatory
string
The currency in which the transaction should be made. See the
receipt
optional
string
Your receipt id for this order should be passed here. Maximum length is 40 characters.
notes
optional
json object
Key-value pair that can be used to store additional information about the entity. Maximum 15 key-value pairs, 256 characters (maximum) each. For example, "note_key": "Beam me up Scotty”
.
partial_payment
optional
boolean
Indicates whether the customer can make a partial payment. Possible values:
true
: The customer can make partial payments.false
(default): The customer cannot make partial payments.