Skip to content

Commit ed87afb

Browse files
authored
fix: Boolean correction in doc (#298)
1 parent 283773b commit ed87afb

File tree

13 files changed

+150
-104
lines changed

13 files changed

+150
-104
lines changed

documents/card.md

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ client.customer.create({
66
"name": "Gaurav Kumar",
77
"email": "gaurav.kumar@example.com",
88
"contact": "9123456780",
9-
"fail_existing": "0",
9+
"fail_existing": "1",
1010
"notes":{
1111
"note_key_1": "September",
1212
"note_key_2": "Make it so."
@@ -21,7 +21,7 @@ client.customer.create({
2121
| name* | string | Name of the customer |
2222
| email | string | Email of the customer |
2323
| contact | string | Contact number of the customer |
24-
| fail_existing | string | If a customer with the same details already exists, the request throws an exception by default. Possible value is `0` or `1`|
24+
| fail_existing | string | If a customer with the same details already exists, the request throws an exception by default. Possible value is `1` or `0`|
2525
| notes | object | A key-value pair |
2626

2727
**Response:**
@@ -121,8 +121,8 @@ client.registration_link.create({
121121
"expire_at":1644737663
122122
},
123123
"receipt":"Receipt No. #11",
124-
"email_notify":1,
125-
"sms_notify":1,
124+
"email_notify": True,
125+
"sms_notify": True,
126126
"expire_by":1644737663,
127127
"notes":{
128128
"note_key 1":"Beam me up Scotty",
@@ -141,8 +141,8 @@ client.registration_link.create({
141141
| description* | string | A brief description of the payment. |
142142
| subscription_registration | object | All keys listed [here](https://razorpay.com/docs/api/recurring-payments/cards/authorization-transaction/#121-create-a-registration-link) are supported |
143143
| receipt | string | Your system order reference id. |
144-
| sms_notify | boolean | SMS notifications are to be sent by Razorpay (default : 1) |
145-
| email_notify | boolean | Email notifications are to be sent by Razorpay (default : 1) |
144+
| sms_notify | boolean | SMS notifications are to be sent by Razorpay (default : True) |
145+
| email_notify | boolean | Email notifications are to be sent by Razorpay (default : True) |
146146
| expire_by | integer | The timestamp, in Unix format, till when the customer can make the authorization payment. |
147147
| notes | object | A key-value pair |
148148

@@ -279,7 +279,7 @@ client.payment.createRecurring({
279279
"order_id": "order_IDts8IQBJT40aQ",
280280
"customer_id": "cust_Hwq7Ba6TDXl1ga",
281281
"token": "token_1Aa00000000001",
282-
"recurring": 1,
282+
"recurring": True,
283283
"description": "Creating recurring payment for Gaurav Kumar",
284284
"notes": {
285285
"note_key 1": "Beam me up Scotty",
@@ -298,7 +298,7 @@ client.payment.createRecurring({
298298
| orderId* | string | The id of the order to be fetched |
299299
| customerId* | string | The id of the customer to be fetched |
300300
| tokenId* | string | The id of the token to be fetched |
301-
| recurring* | boolean | Possible values is `0` or `1` |
301+
| recurring* | boolean | Possible values is `True` or `False` |
302302
| description | string | A brief description of the payment. |
303303
| notes | object | A key-value pair |
304304

@@ -581,7 +581,7 @@ client.card.requestCardReference({"number":"4854980604708430"})
581581
| Name | Type | Description |
582582
|-------------|---------|------------------------------------------------------------------------------|
583583
| number* | string | The card number whose PAR or network reference id should be retrieved. |
584-
| tokenised | string | Determines if the card is saved as a token. Possible value is `true` or `false` |
584+
| tokenised | string | Determines if the card is saved as a token. Possible value is `True` or `False` |
585585

586586
**Response:**
587587
```json

documents/customer.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ client.customer.create({
66
"name": "Gaurav Kumar",
77
"contact": 9123456780,
88
"email": "gaurav.kumar@example.com",
9-
"fail_existing": 0,
9+
"fail_existing": "1",
1010
"gstin": "29XAbbA4369J1PA",
1111
"notes": {
1212
"notes_key_1": "Tea, Earl Grey, Hot",
@@ -22,7 +22,7 @@ client.customer.create({
2222
| name* | string | Name of the customer |
2323
| email | string | Email of the customer |
2424
| contact | string | Contact number of the customer |
25-
| fail_existing | string | If a customer with the same details already exists, the request throws an exception by default. Possible value is `0` or `1`|
25+
| fail_existing | string | If a customer with the same details already exists, the request throws an exception by default. Possible value is `1` or `0`|
2626
| gstin | string | Customer's GST number, if available. For example, 29XAbbA4369J1PA |
2727
| notes | object | A key-value pair |
2828

documents/emandate.md

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ client.customer.create({
66
"name": "Gaurav Kumar",
77
"contact": 9123456780,
88
"email": "gaurav.kumar@example.com",
9-
"fail_existing": 0,
9+
"fail_existing": "1",
1010
"gstin": "29XAbbA4369J1PA",
1111
"notes": {
1212
"notes_key_1": "Tea, Earl Grey, Hot",
@@ -22,7 +22,7 @@ client.customer.create({
2222
| name* | string | Name of the customer |
2323
| email | string | Email of the customer |
2424
| contact | string | Contact number of the customer |
25-
| fail_existing | string | If a customer with the same details already exists, the request throws an exception by default. Possible value is `0` or `1`|
25+
| fail_existing | string | If a customer with the same details already exists, the request throws an exception by default. Possible value is `1` or `0`|
2626
| notes | object | A key-value pair |
2727

2828
**Response:**
@@ -126,8 +126,8 @@ client.registration_link.create({
126126
},
127127
"receipt": "Receipt no. 1",
128128
"expire_by": 1880480689,
129-
"sms_notify": 1,
130-
"email_notify": 1,
129+
"sms_notify": True,
130+
"email_notify": True,
131131
"notes": {
132132
"note_key 1": "Beam me up Scotty",
133133
"note_key 2": "Tea. Earl Gray. Hot."
@@ -145,7 +145,8 @@ client.registration_link.create({
145145
| amount* | integer | The payment amount in the smallest currency sub-unit. |
146146
| description* | string | A description that appears on the hosted page. For example, `12:30 p.m. Thali meals (Gaurav Kumar`). |
147147
| subscription_registration | array | All parameters listed [here](https://razorpay.com/docs/api/payments/recurring-payments/emandate/create-authorization-transaction/#121-create-a-registration-link) are supported |
148-
| email_notify | boolean | Email notifications are to be sent by Razorpay (default : 1) |
148+
| email_notify | boolean | Email notifications are to be sent by Razorpay (default : True) |
149+
| sms_notify | boolean | SMS notifications are to be sent by Razorpay (default : True) |
149150
| expire_by | integer | The timestamp, in Unix format, till when the customer can make the authorization payment. |
150151
| receipt | string | Your system order reference id. |
151152
| notes | array | A key-value pair |
@@ -430,7 +431,7 @@ client.payment.createRecurring({
430431
"order_id": "order_1Aa00000000002",
431432
"customer_id": "cust_1Aa00000000001",
432433
"token": "token_1Aa00000000001",
433-
"recurring": "1",
434+
"recurring": True,
434435
"description": "Creating recurring payment for Gaurav Kumar",
435436
"notes": {
436437
"note_key 1": "Beam me up Scotty",
@@ -450,7 +451,7 @@ client.payment.createRecurring({
450451
| order_id* | string | The unique identifier of the order created. |
451452
| customer_id* | string | The `customer_id` for the customer you want to charge. |
452453
| token* | string | The `token_id` generated when the customer successfully completes the authorization payment. Different payment instruments for the same customer have different `token_id`.|
453-
| recurring* | string | Determines if recurring payment is enabled or not. Possible values:<br>* `1` - Recurring is enabled.* `0` - Recurring is not enabled.|
454+
| recurring* | string | Determines if recurring payment is enabled or not. Possible values:<br>* `True` - Recurring is enabled.* `False` - Recurring is not enabled.|
454455
| description | string | A user-entered description for the payment.|
455456
| notes | object | Key-value pair that can be used to store additional information about the entity. Maximum 15 key-value pairs, 256 characters (maximum) each. |
456457

documents/invoice.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,8 +39,8 @@ client.invoice.create({
3939
"quantity": 1
4040
}
4141
],
42-
"sms_notify": 1,
43-
"email_notify": 1,
42+
"sms_notify": True,
43+
"email_notify": True,
4444
"currency": "USD",
4545
"expire_by": 1589765167
4646
})

documents/order.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -275,7 +275,7 @@ client.order.edit(orderId,{
275275
### View RTO/Risk Reasons
276276

277277
```py
278-
orderId = "order_DaaS6LOUAASb7Y";
278+
orderId = "order_DaaS6LOUAASb7Y"
279279

280280
client.order.viewRtoReview(orderId)
281281
```

documents/papernach.md

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ client.customer.create({
66
"name": "Gaurav Kumar",
77
"contact": 9123456780,
88
"email": "gaurav.kumar@example.com",
9-
"fail_existing": 0,
9+
"fail_existing": "1",
1010
"gstin": "29XAbbA4369J1PA",
1111
"notes": {
1212
"notes_key_1": "Tea, Earl Grey, Hot",
@@ -23,7 +23,7 @@ client.customer.create({
2323
| email | string | Email of the customer |
2424
| contact | string | Contact number of the customer |
2525
| notes | object | A key-value pair |
26-
| fail_existing | string | If a customer with the same details already exists, the request throws an exception by default. Possible value is `0` or `1`|
26+
| fail_existing | string | If a customer with the same details already exists, the request throws an exception by default. Possible value is `1` or `0`|
2727

2828
**Response:**
2929
```json
@@ -188,8 +188,8 @@ client.registration_link.create({
188188
"max_amount": 50000
189189
},
190190
"receipt": "Receipt No. 1",
191-
"sms_notify": 1,
192-
"email_notify": 1,
191+
"sms_notify": True,
192+
"email_notify": True,
193193
"expire_by": 1647483647,
194194
"notes": {
195195
"note_key 1": "Beam me up Scotty",
@@ -647,7 +647,7 @@ client.payment.createRecurring({
647647
"order_id": "order_1Aa00000000002",
648648
"customer_id": "cust_1Aa00000000001",
649649
"token": "token_1Aa00000000001",
650-
"recurring": "1",
650+
"recurring": True,
651651
"description": "Creating recurring payment for Gaurav Kumar",
652652
"notes": {
653653
"note_key 1": "Beam me up Scotty",
@@ -667,7 +667,7 @@ client.payment.createRecurring({
667667
| order_id* | string | The unique identifier of the order created. |
668668
| customer_id* | string | The `customer_id` for the customer you want to charge. |
669669
| token* | string | The `token_id` generated when the customer successfully completes the authorization payment. Different payment instruments for the same customer have different `token_id`.|
670-
| recurring* | string | Determines if recurring payment is enabled or not. Possible values:<br>* `1` - Recurring is enabled.* `0` - Recurring is not enabled.|
670+
| recurring* | string | Determines if recurring payment is enabled or not. Possible values:<br>* `True` - Recurring is enabled.* `False` - Recurring is not enabled.|
671671
| description | string | A user-entered description for the payment.|
672672
| notes | object | Key-value pair that can be used to store additional information about the entity. Maximum 15 key-value pairs, 256 characters (maximum) each. |
673673

documents/payment.md

Lines changed: 27 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -410,19 +410,30 @@ client.order.create({
410410

411411
```py
412412
client.payment.createPaymentJson({
413-
"amount": 100,
414-
"currency": "INR",
415-
"order_id": "order_EAkbvXiCJlwhHR",
416-
"email": "gaurav.kumar@example.com",
417-
"contact": 9090909090,
418-
"method": "card",
419-
"card":{
420-
"number": 4111111111111111,
421-
"name": "Gaurav",
422-
"expiry_month": 11,
423-
"expiry_year": 23,
424-
"cvv": 100
425-
}
413+
"amount": 100,
414+
"currency": "INR",
415+
"contact": "9000090000",
416+
"email": "gaurav.kumar@example.com",
417+
"order_id": "order_DPzFe1Q1dEOKed",
418+
"method": "card",
419+
"card": {
420+
"number": "4386289407660153",
421+
"name": "Gaurav",
422+
"expiry_month": 11,
423+
"expiry_year": 30,
424+
"cvv": 100
425+
},
426+
"authentication": {
427+
"authentication_channel": "browser"
428+
},
429+
"browser": {
430+
"java_enabled": False,
431+
"javascript_enabled": False,
432+
"timezone_offset": 11,
433+
"color_depth": 23,
434+
"screen_width": 23,
435+
"screen_height": 100
436+
}
426437
})
427438
```
428439

@@ -498,7 +509,7 @@ client.payment.createUpi({
498509
"contact": "9123456789",
499510
"method": "upi",
500511
"customer_id": "cust_EIW4T2etiweBmG",
501-
"save": 1,
512+
"save": True,
502513
"ip": "192.168.0.103",
503514
"referer": "http",
504515
"user_agent": "Mozilla/5.0",
@@ -525,7 +536,7 @@ client.payment.createUpi({
525536
| contact* | string | Contact number of the customer |
526537
| notes | array | A key-value pair |
527538
| description | string | Descriptive text of the payment. |
528-
| save | boolean | Specifies if the VPA should be stored as tokens.Possible value is `0`, `1` |
539+
| save | boolean | Specifies if the VPA should be stored as tokens.Possible value is `True`, `False` |
529540
| callback_url | string | URL where Razorpay will submit the final payment status. |
530541
| ip* | string | The client's browser IP address. For example `117.217.74.98` |
531542
| referer* | string | Value of `referer` header passed by the client's browser. For example, `https://example.com/` |
@@ -573,7 +584,7 @@ client.payment.createUpi({
573584
| contact* | string | Contact number of the customer |
574585
| notes | array | A key-value pair |
575586
| description | string | Descriptive text of the payment. |
576-
| save | boolean | Specifies if the VPA should be stored as tokens.Possible value is `0`, `1` |
587+
| save | boolean | Specifies if the VPA should be stored as tokens.Possible value is `True`, `False` |
577588
| callback_url | string | URL where Razorpay will submit the final payment status. |
578589
| ip* | string | The client's browser IP address. For example `117.217.74.98` |
579590
| referer* | string | Value of `referer` header passed by the client's browser. For example, `https://example.com/` |

0 commit comments

Comments
 (0)