{"_id":"571749c3d2a6510e00840a89","githubsync":"","parentDoc":null,"sync_unique":"","user":"56a1c959842b650d0088899c","__v":30,"createdAt":"2016-04-04T08:58:43.574Z","hidden":false,"isReference":false,"link_external":false,"order":0,"slug":"overview-and-setup","api":{"results":{"codes":[]},"settings":"","url":"","auth":"required","params":[]},"body":"##How Instamojo works\n\nInstamojo works by creating payment requests.\n\nFor example: _Superstore_ wants to accept payments, they create a payment request which looks like this: \n\n`https://www.instamojo.com/@SuperStore/2f89f6a267ad4543a0906ff762481563`\n\nThey can share this link with their customers and receive payments online. \n\nThe Instamojo Marketplace flow is an extension of the above. You can create payment requests on behalf of a merchant in your marketplace/system, facilitate payments and payouts to them. \n\nThe Marketplace API can also be used to debit your commission from your merchants. While creating payment requests on behalf of merchants in your marketplace/system, you can receive a certain commission from each sale, while automatically transferring the rest of the amount to your merchant’s bank account. \n\n##Marketplace API use cases\n\n*Marketplace Model*\n\nThe marketplace API is used by aggregators where sellers are charged a certain commission for each product sold on the platform. This split of commission is automatically done with the marketplace API.\n\n> Eg: _Superstore_ registers on the marketplace _Mojocart_. _Mojocart_ uses the Instamojo marketplace API to create an account for _Superstore_ on Instamojo. _Mojocart_ then proceeds to use Instamojo for all payments, compliance, payouts, security, risk and fraud-protection for _Superstore_.\n\n*Franchisee Model*\n\nThe marketplace API allows the parent to set a commission for each transaction and hence, automates the process of reconciling payments with its branches. \n\n> Eg: _SuperStore HQ_ has branches like _SuperStore Mumbai_, _SuperStore Bangalore_, etc.\nEach branch will collect payments, however a small commission of each transaction should go to _SuperStore HQ_ too. \n\n*Vendor Model*\n\nThe API can also be used by an agency to collect commissions from payments collected by a product/software that was customised and built for a client.\n\n> Eg: _InvoiceWrite_ has an invoicing solution where they would like to integrate online payments and also collect a small percentage of each transaction processed.","category":"571749c2d2a6510e00840a85","type":"basic","version":"571749c2d2a6510e00840a82","excerpt":"An introduction","link_url":"","title":"Marketplace API","project":"56a1c9c13845200d0066d6fe","updates":[],"metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

Marketplace API

An introduction

##How Instamojo works Instamojo works by creating payment requests. For example: _Superstore_ wants to accept payments, they create a payment request which looks like this: `https://www.instamojo.com/@SuperStore/2f89f6a267ad4543a0906ff762481563` They can share this link with their customers and receive payments online. The Instamojo Marketplace flow is an extension of the above. You can create payment requests on behalf of a merchant in your marketplace/system, facilitate payments and payouts to them. The Marketplace API can also be used to debit your commission from your merchants. While creating payment requests on behalf of merchants in your marketplace/system, you can receive a certain commission from each sale, while automatically transferring the rest of the amount to your merchant’s bank account. ##Marketplace API use cases *Marketplace Model* The marketplace API is used by aggregators where sellers are charged a certain commission for each product sold on the platform. This split of commission is automatically done with the marketplace API. > Eg: _Superstore_ registers on the marketplace _Mojocart_. _Mojocart_ uses the Instamojo marketplace API to create an account for _Superstore_ on Instamojo. _Mojocart_ then proceeds to use Instamojo for all payments, compliance, payouts, security, risk and fraud-protection for _Superstore_. *Franchisee Model* The marketplace API allows the parent to set a commission for each transaction and hence, automates the process of reconciling payments with its branches. > Eg: _SuperStore HQ_ has branches like _SuperStore Mumbai_, _SuperStore Bangalore_, etc. Each branch will collect payments, however a small commission of each transaction should go to _SuperStore HQ_ too. *Vendor Model* The API can also be used by an agency to collect commissions from payments collected by a product/software that was customised and built for a client. > Eg: _InvoiceWrite_ has an invoicing solution where they would like to integrate online payments and also collect a small percentage of each transaction processed.
##How Instamojo works Instamojo works by creating payment requests. For example: _Superstore_ wants to accept payments, they create a payment request which looks like this: `https://www.instamojo.com/@SuperStore/2f89f6a267ad4543a0906ff762481563` They can share this link with their customers and receive payments online. The Instamojo Marketplace flow is an extension of the above. You can create payment requests on behalf of a merchant in your marketplace/system, facilitate payments and payouts to them. The Marketplace API can also be used to debit your commission from your merchants. While creating payment requests on behalf of merchants in your marketplace/system, you can receive a certain commission from each sale, while automatically transferring the rest of the amount to your merchant’s bank account. ##Marketplace API use cases *Marketplace Model* The marketplace API is used by aggregators where sellers are charged a certain commission for each product sold on the platform. This split of commission is automatically done with the marketplace API. > Eg: _Superstore_ registers on the marketplace _Mojocart_. _Mojocart_ uses the Instamojo marketplace API to create an account for _Superstore_ on Instamojo. _Mojocart_ then proceeds to use Instamojo for all payments, compliance, payouts, security, risk and fraud-protection for _Superstore_. *Franchisee Model* The marketplace API allows the parent to set a commission for each transaction and hence, automates the process of reconciling payments with its branches. > Eg: _SuperStore HQ_ has branches like _SuperStore Mumbai_, _SuperStore Bangalore_, etc. Each branch will collect payments, however a small commission of each transaction should go to _SuperStore HQ_ too. *Vendor Model* The API can also be used by an agency to collect commissions from payments collected by a product/software that was customised and built for a client. > Eg: _InvoiceWrite_ has an invoicing solution where they would like to integrate online payments and also collect a small percentage of each transaction processed.
{"_id":"571a0f2ef65d1922005dc0e8","excerpt":"","githubsync":"","next":{"description":"","pages":[]},"order":1,"parentDoc":null,"slug":"overview-and-setup-3","body":"##Basic integration flow\n\n\n1.\tCreate an account for your marketplace on Instamojo\n\n2.\tUse the [Merchant Signup API](doc:signup) to create accounts for your merchants on your marketplace. \n\n3.\tGet access tokens for your merchants.\n\n4.     Add their bank information.\n\n5.\tCreate payment links for your merchants and share them with buyers, or redirect the buyers to these payment links to receive payments. \n\n6.\tOnce a payment is made, it takes 3 business days to transfer the funds into your merchant’s bank account. \n\n##Setup\n\n1.\tIt’s recommended to test your integration in our sandbox environment. Sign up on https://test.instamojo.com and write to us at support@instamojo.com stating your username for us to send your `client_id`, `client_secret` and `referrer`. Note that in the base API endpoint for our sandbox environment is **https://test.instamojo.com/** not **https://api.instamojo.com/**.\n\n2.\tOnce you’re done with testing the API, please signup on https://www.instamojo.com and complete your KYC verification. Please allow our compliance team 48 hours to verify your account. \n3.\tOnce your account has been approved, please get in touch with support@instamojo.com for your `client_id`, `client_secret` and `referrer`. Please note that you must take precautions to safeguard this information, because if exposed, it can be misused.","createdAt":"2016-04-22T11:46:54.995Z","title":"Overview and Setup","category":"571749c2d2a6510e00840a85","hidden":false,"__v":15,"sync_unique":"","updates":[],"user":"56a1c959842b650d0088899c","api":{"settings":"","url":"","auth":"required","params":[],"results":{"codes":[{"code":"{}","name":"","status":200,"language":"json"},{"name":"","status":400,"language":"json","code":"{}"}]}},"link_url":"","project":"56a1c9c13845200d0066d6fe","type":"basic","version":"571749c2d2a6510e00840a82","isReference":false,"link_external":false,"metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

Overview and Setup


##Basic integration flow 1. Create an account for your marketplace on Instamojo 2. Use the [Merchant Signup API](doc:signup) to create accounts for your merchants on your marketplace. 3. Get access tokens for your merchants. 4. Add their bank information. 5. Create payment links for your merchants and share them with buyers, or redirect the buyers to these payment links to receive payments. 6. Once a payment is made, it takes 3 business days to transfer the funds into your merchant’s bank account. ##Setup 1. It’s recommended to test your integration in our sandbox environment. Sign up on https://test.instamojo.com and write to us at support@instamojo.com stating your username for us to send your `client_id`, `client_secret` and `referrer`. Note that in the base API endpoint for our sandbox environment is **https://test.instamojo.com/** not **https://api.instamojo.com/**. 2. Once you’re done with testing the API, please signup on https://www.instamojo.com and complete your KYC verification. Please allow our compliance team 48 hours to verify your account. 3. Once your account has been approved, please get in touch with support@instamojo.com for your `client_id`, `client_secret` and `referrer`. Please note that you must take precautions to safeguard this information, because if exposed, it can be misused.
##Basic integration flow 1. Create an account for your marketplace on Instamojo 2. Use the [Merchant Signup API](doc:signup) to create accounts for your merchants on your marketplace. 3. Get access tokens for your merchants. 4. Add their bank information. 5. Create payment links for your merchants and share them with buyers, or redirect the buyers to these payment links to receive payments. 6. Once a payment is made, it takes 3 business days to transfer the funds into your merchant’s bank account. ##Setup 1. It’s recommended to test your integration in our sandbox environment. Sign up on https://test.instamojo.com and write to us at support@instamojo.com stating your username for us to send your `client_id`, `client_secret` and `referrer`. Note that in the base API endpoint for our sandbox environment is **https://test.instamojo.com/** not **https://api.instamojo.com/**. 2. Once you’re done with testing the API, please signup on https://www.instamojo.com and complete your KYC verification. Please allow our compliance team 48 hours to verify your account. 3. Once your account has been approved, please get in touch with support@instamojo.com for your `client_id`, `client_secret` and `referrer`. Please note that you must take precautions to safeguard this information, because if exposed, it can be misused.
{"_id":"571749c3d2a6510e00840a8a","__v":34,"createdAt":"2016-04-04T10:53:29.247Z","hidden":false,"title":"Integration Guide","type":"basic","user":"56a1c959842b650d0088899c","excerpt":"","category":"571749c2d2a6510e00840a85","isReference":false,"link_url":"","parentDoc":null,"project":"56a1c9c13845200d0066d6fe","sync_unique":"","api":{"auth":"required","params":[],"results":{"codes":[{"status":200,"name":"","code":"{}","language":"json"},{"name":"","code":"{}","language":"json","status":400}]},"settings":"","url":""},"body":"##Integration Steps\n\n\n[block:callout]\n{\n  \"type\": \"danger\",\n  \"title\": \"Restricted Access\",\n  \"body\": \"The Marketplace API is available only to select customers based on their business needs.\\nRegular Instamojo API credentials will not work for the Marketplace API.\\n\\nFor credentials related to Marketplace API contact support@instamojo.com and specify your platform (production/sandbox).\"\n}\n[/block]\n##Authentication Flow\n\nAll API interactions required you to have a authentication credentials. Use the `client_id` and `client_secret` to authenticate yourself against the API. There are three kinds of authentication:\n\n1. [Application Based](doc:application-based-authentication) - This gives you extra privileges like creating an account on Instamojo.\n\n2. [User Based](doc:user-based-authentication) - This gives you privileges for performing actions on a user's account. For eg: updating their name and location, creating payment links on their behalf, etc.\n\n3. [Refresh Token Based](doc:refresh-token-based-authentication) - An `access_token` obtained via the User Based authentication will expire in `36000` seconds. But it also gives a `refresh_token`, which can be used to obtain a new pair of `access_token` and `refresh_token` without the need for the `username` and `password`.\n\n\n\n## Signup Flow\n\n1. Use **Application Based Authentication** to get an `access_token`.\n\n2. Use this `access_token` to create a user on Instamojo. Here you should use a valid email id and a  password. Ensure that you are not storing the password in your system. On signup, you will receive a unique `id` for the user, which will be used henceforth to identify the user.\n\n3. Use **User Based Authentication** to get an `access_token`. You will need the password for the first time when you are requesting an `access_token` in this step. Going forward, you must store the `access_token` and `refresh_token` safely in your database, and discard the password that you had used. If the current `access_token` expires, you should use the **Refresh Token Based** authentication to get a new pair of `access_token` and `refresh_token`.\n\n4. Use this `access_token` to update the bank account details of the user.\n\n\n\n## Payment flow\n\n1. Use **User Based Authentication** to get an `access_token`.\n\n2. Use this `access_token` to create a payment link.\n\n3. Send the payment link to the buyer.\n\n4. When the payment is complete, we will send you a `webhook` request or redirect the buyer to your `redirect_url` depending on the mode chosen by you while creating the payment link.\n\n\n\n## Additional Features\n\n1. Refunds - Use this feature if you want to refund the complete or partial amount for a payment. \n\n2. Collecting fees - Use this feature if you want to collect a commission fee on each transaction that you drive via your marketplace.\n\n3. Hold and Release - You can specify to hold a payment until you are confident that the buyer has received the services for their payment. Once you tell us to release the payment, only then the merchant will be paid out.\n\n4. Light Checkout - You can use this to display only the payment form. This is useful if you are going to use this in a mobile app or within your website. To use this feature, simply append `?embed` at the end of the payment link.","githubsync":"","link_external":false,"next":{"description":"","pages":[]},"order":2,"slug":"integration-guide","updates":["58412f6e426cf70f006f5054"],"version":"571749c2d2a6510e00840a82","metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

Integration Guide


##Integration Steps [block:callout] { "type": "danger", "title": "Restricted Access", "body": "The Marketplace API is available only to select customers based on their business needs.\nRegular Instamojo API credentials will not work for the Marketplace API.\n\nFor credentials related to Marketplace API contact support@instamojo.com and specify your platform (production/sandbox)." } [/block] ##Authentication Flow All API interactions required you to have a authentication credentials. Use the `client_id` and `client_secret` to authenticate yourself against the API. There are three kinds of authentication: 1. [Application Based](doc:application-based-authentication) - This gives you extra privileges like creating an account on Instamojo. 2. [User Based](doc:user-based-authentication) - This gives you privileges for performing actions on a user's account. For eg: updating their name and location, creating payment links on their behalf, etc. 3. [Refresh Token Based](doc:refresh-token-based-authentication) - An `access_token` obtained via the User Based authentication will expire in `36000` seconds. But it also gives a `refresh_token`, which can be used to obtain a new pair of `access_token` and `refresh_token` without the need for the `username` and `password`. ## Signup Flow 1. Use **Application Based Authentication** to get an `access_token`. 2. Use this `access_token` to create a user on Instamojo. Here you should use a valid email id and a password. Ensure that you are not storing the password in your system. On signup, you will receive a unique `id` for the user, which will be used henceforth to identify the user. 3. Use **User Based Authentication** to get an `access_token`. You will need the password for the first time when you are requesting an `access_token` in this step. Going forward, you must store the `access_token` and `refresh_token` safely in your database, and discard the password that you had used. If the current `access_token` expires, you should use the **Refresh Token Based** authentication to get a new pair of `access_token` and `refresh_token`. 4. Use this `access_token` to update the bank account details of the user. ## Payment flow 1. Use **User Based Authentication** to get an `access_token`. 2. Use this `access_token` to create a payment link. 3. Send the payment link to the buyer. 4. When the payment is complete, we will send you a `webhook` request or redirect the buyer to your `redirect_url` depending on the mode chosen by you while creating the payment link. ## Additional Features 1. Refunds - Use this feature if you want to refund the complete or partial amount for a payment. 2. Collecting fees - Use this feature if you want to collect a commission fee on each transaction that you drive via your marketplace. 3. Hold and Release - You can specify to hold a payment until you are confident that the buyer has received the services for their payment. Once you tell us to release the payment, only then the merchant will be paid out. 4. Light Checkout - You can use this to display only the payment form. This is useful if you are going to use this in a mobile app or within your website. To use this feature, simply append `?embed` at the end of the payment link.
##Integration Steps [block:callout] { "type": "danger", "title": "Restricted Access", "body": "The Marketplace API is available only to select customers based on their business needs.\nRegular Instamojo API credentials will not work for the Marketplace API.\n\nFor credentials related to Marketplace API contact support@instamojo.com and specify your platform (production/sandbox)." } [/block] ##Authentication Flow All API interactions required you to have a authentication credentials. Use the `client_id` and `client_secret` to authenticate yourself against the API. There are three kinds of authentication: 1. [Application Based](doc:application-based-authentication) - This gives you extra privileges like creating an account on Instamojo. 2. [User Based](doc:user-based-authentication) - This gives you privileges for performing actions on a user's account. For eg: updating their name and location, creating payment links on their behalf, etc. 3. [Refresh Token Based](doc:refresh-token-based-authentication) - An `access_token` obtained via the User Based authentication will expire in `36000` seconds. But it also gives a `refresh_token`, which can be used to obtain a new pair of `access_token` and `refresh_token` without the need for the `username` and `password`. ## Signup Flow 1. Use **Application Based Authentication** to get an `access_token`. 2. Use this `access_token` to create a user on Instamojo. Here you should use a valid email id and a password. Ensure that you are not storing the password in your system. On signup, you will receive a unique `id` for the user, which will be used henceforth to identify the user. 3. Use **User Based Authentication** to get an `access_token`. You will need the password for the first time when you are requesting an `access_token` in this step. Going forward, you must store the `access_token` and `refresh_token` safely in your database, and discard the password that you had used. If the current `access_token` expires, you should use the **Refresh Token Based** authentication to get a new pair of `access_token` and `refresh_token`. 4. Use this `access_token` to update the bank account details of the user. ## Payment flow 1. Use **User Based Authentication** to get an `access_token`. 2. Use this `access_token` to create a payment link. 3. Send the payment link to the buyer. 4. When the payment is complete, we will send you a `webhook` request or redirect the buyer to your `redirect_url` depending on the mode chosen by you while creating the payment link. ## Additional Features 1. Refunds - Use this feature if you want to refund the complete or partial amount for a payment. 2. Collecting fees - Use this feature if you want to collect a commission fee on each transaction that you drive via your marketplace. 3. Hold and Release - You can specify to hold a payment until you are confident that the buyer has received the services for their payment. Once you tell us to release the payment, only then the merchant will be paid out. 4. Light Checkout - You can use this to display only the payment form. This is useful if you are going to use this in a mobile app or within your website. To use this feature, simply append `?embed` at the end of the payment link.
{"_id":"5729f771fcecb90e00b0a9c5","title":"Application Based Authentication","user":"56a1c959842b650d0088899c","githubsync":"","link_url":"","sync_unique":"","editedParams2":true,"isReference":true,"project":"56a1c9c13845200d0066d6fe","slug":"application-based-authentication","createdAt":"2016-05-04T13:21:53.476Z","editedParams":true,"parentDoc":null,"type":"post","updates":["5926ecfd6c729e0f005963be","59a50906192dba000fc9c932","5a3e2ba8d757ef00120e963e"],"body":"","category":"5729f40a7f34182900ce9d52","order":0,"hidden":false,"link_external":false,"version":"571749c2d2a6510e00840a82","__v":4,"api":{"auth":"never","examples":{"codes":[{"code":"import requests\nrequests.post('https://api.instamojo.com/oauth2/token/', data={\n    \t'grant_type': 'client_credentials',\n  \t\t'client_id': '21fe14a60057ece6c76496175cb0238a2ffd87be',\n    \t'client_secret': '-KWPoDO!_l?MZQ-DsZeQ0TXXcvuDn;mxmAtGho8Xijn=iH6F'\n})\n              ","language":"python"}]},"method":"post","params":[{"desc":"This describes the type of authentication.","name":"grant_type","ref":"","required":true,"type":"string","in":"body","_id":"5729f771fcecb90e00b0a9c7","default":"client_credentials"},{"ref":"","required":true,"type":"string","in":"body","_id":"5729f771fcecb90e00b0a9c6","default":"","desc":"The client_id that is provided to you.","name":"client_id"},{"_id":"5729fe10fcecb90e00b0a9e3","default":"","desc":"The client_secret that is provided to you.","name":"client_secret","ref":"","required":true,"type":"string","in":"body"}],"results":{"codes":[{"code":"{\n  \"access_token\": \"y70kak2K0Rg7J4PAL8sdW0MutnGJEl\",\n  \"token_type\": \"Bearer\",\n  \"expires_in\": 36000,\n  \"scope\": \"read write\"\n}","language":"json","status":200,"name":""},{"name":"","code":"{\n  \"error\": \"unsupported_grant_type\"\n}","language":"json","status":400},{"status":401,"language":"json","code":"{\n  \"error\": \"invalid_client\"\n}"}]},"settings":"5729f56e7f34182900ce9d55","url":"/oauth2/token/"},"excerpt":"","next":{"pages":[]},"metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

postApplication Based Authentication


Body Params

grant_type:
required
stringclient_credentials
This describes the type of authentication.
client_id:
required
string
The client_id that is provided to you.
client_secret:
required
string
The client_secret that is provided to you.

User Information

Try It Out

post
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Examples


Result Format



{"_id":"57309f6d19c1e00e006d2070","excerpt":"","link_url":"","sync_unique":"","title":"User Based Authentication","updates":["579eefa0bf088a0e00b8cfbf"],"body":"","editedParams2":true,"user":"56a1c959842b650d0088899c","type":"post","githubsync":"","link_external":false,"order":1,"category":"5729f40a7f34182900ce9d52","hidden":false,"version":"571749c2d2a6510e00840a82","editedParams":true,"isReference":true,"parentDoc":null,"project":"56a1c9c13845200d0066d6fe","slug":"user-based-authentication","__v":2,"api":{"method":"post","params":[{"name":"grant_type","ref":"","required":true,"type":"string","in":"body","_id":"5729f771fcecb90e00b0a9c7","default":"password","desc":"This describes the type of authentication"},{"type":"string","in":"body","_id":"5729f771fcecb90e00b0a9c6","default":"","desc":"The client_id that is provided to you.","name":"client_id","ref":"","required":true},{"name":"client_secret","ref":"","required":true,"type":"string","in":"body","_id":"5729fe10fcecb90e00b0a9e3","default":"","desc":"The client_secret that is provided to you."},{"default":"","desc":"Email or Username of the user.","in":"body","name":"username","ref":"","required":true,"type":"string","_id":"57309f96b16ed73200ddd191"},{"desc":"Password of the user.","name":"password","ref":"","required":true,"type":"string","in":"body","_id":"57309f96b16ed73200ddd190","default":""}],"results":{"codes":[{"status":200,"language":"json","code":"{\n  \"access_token\": \"zsUhiZ9aiV1nG9nLRFPSXPS3smDREX\",\n  \"token_type\": \"Bearer\",\n  \"expires_in\": 36000,\n  \"refresh_token\": \"oPorohVcpY5n7v7cS8biUKQZcvV5fT\",\n  \"scope\": \"read write\"\n}","name":""},{"language":"json","code":"{\n  \"error\": \"unsupported_grant_type\"\n}","name":"","status":400},{"code":"{\n  \"error_description\": \"Invalid credentials given.\",\n  \"error\": \"invalid_grant\"\n}","language":"json","status":401}]},"settings":"5729f56e7f34182900ce9d55","url":"/oauth2/token/","auth":"never","examples":{"codes":[{"language":"python","code":"import requests\nrequests.post('https://api.instamojo.com/oauth2/token/', data={\n    \t'grant_type': 'password',\n  \t\t'client_id': '21fe14a60057ece6c76496175cb0238a2ffd87be',\n    \t'client_secret': '-KWPoDO!_l?MZQ-DsZeQ0TXXcvuDn;mxmAtGho8Xijn=iH6F',\n      'username': 'foo@example.com',\n      'password': 'bar',\n})\n              "}]}},"createdAt":"2016-05-09T14:32:13.236Z","metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

postUser Based Authentication


Body Params

grant_type:
required
stringpassword
This describes the type of authentication
client_id:
required
string
The client_id that is provided to you.
client_secret:
required
string
The client_secret that is provided to you.
username:
required
string
Email or Username of the user.
password:
required
string
Password of the user.

User Information

Try It Out

post
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Examples


Result Format



{"_id":"5730a09864726a2000043188","editedParams":true,"excerpt":"","next":{"description":"","pages":[]},"type":"post","updates":[],"user":"56a1c959842b650d0088899c","sync_unique":"","__v":1,"createdAt":"2016-05-09T14:37:12.755Z","editedParams2":true,"hidden":false,"isReference":true,"parentDoc":null,"body":"","githubsync":"","project":"56a1c9c13845200d0066d6fe","title":"Refresh Token Based Authentication","version":"571749c2d2a6510e00840a82","slug":"refresh-token-based-authentication","api":{"examples":{"codes":[{"code":"import requests\nrequests.post('https://api.instamojo.com/oauth2/token/', data={\n    \t'grant_type': 'refresh_token',\n  \t\t'client_id': '21fe14a60057ece6c76496175cb0238a2ffd87be',\n    \t'client_secret': '-KWPoDO!_l?MZQ-DsZeQ0TXXcvuDn;mxmAtGho8Xijn=iH6F',\n      'refresh_token': 'oPorohVcpY5n7v7cS8biUKQZcvV5fT',\n})\n              ","language":"python"}]},"method":"post","params":[{"in":"body","_id":"5729f771fcecb90e00b0a9c7","default":"refresh_token","desc":"This describes the type of authentication.","name":"grant_type","ref":"","required":true,"type":"string"},{"default":"","desc":"The client_id that is provided to you.","name":"client_id","ref":"","required":true,"type":"string","in":"body","_id":"5729f771fcecb90e00b0a9c6"},{"required":true,"type":"string","in":"body","_id":"5729fe10fcecb90e00b0a9e3","default":"","desc":"The client_secret that is provided to you.","name":"client_secret","ref":""},{"required":true,"type":"string","in":"body","_id":"5730a09864726a2000043189","default":"","desc":"The refresh_token obtained from User Based Authentication.","name":"refresh_token","ref":""}],"results":{"codes":[{"code":"{\n  \"access_token\": \"9692b5d5279143058062e0ea6547ee\",\n  \"token_type\": \"Bearer\",\n  \"expires_in\": 36000,\n  \"refresh_token\": \"6bf39817411b4102bff65ab85ef5ea\",\n  \"scope\": \"read write\"\n}","name":"","status":200,"language":"json"},{"name":"","status":400,"language":"json","code":"{\n  \"error\": \"unsupported_grant_type\"\n}"},{"language":"json","status":401,"code":"{\n  \"error\": \"invalid_grant\"\n}"}]},"settings":"5729f56e7f34182900ce9d55","url":"/oauth2/token/","auth":"never"},"category":"5729f40a7f34182900ce9d52","link_external":false,"link_url":"","order":2,"metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

postRefresh Token Based Authentication


Body Params

grant_type:
required
stringrefresh_token
This describes the type of authentication.
client_id:
required
string
The client_id that is provided to you.
client_secret:
required
string
The client_secret that is provided to you.
refresh_token:
required
string
The refresh_token obtained from User Based Authentication.

User Information

Try It Out

post
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Examples


Result Format



{"_id":"5730a1e826bd5a3600d3379f","createdAt":"2016-05-09T14:42:48.103Z","editedParams":true,"type":"post","user":"56a1c959842b650d0088899c","hidden":false,"parentDoc":null,"body":"","editedParams2":true,"githubsync":"","slug":"signup","updates":["58bb805920e8822300b0194a"],"api":{"params":[{"ref":"","in":"body","required":true,"desc":"Email id for the account.","default":"","type":"string","name":"email","_id":"5730a7346b55e93400b329ea"},{"in":"body","required":true,"desc":"The password for the account.","default":"","type":"string","name":"password","_id":"5730a22864726a200004318d","ref":""},{"required":true,"desc":"Phone number for the account","default":"","type":"string","name":"phone","_id":"5730a7346b55e93400b329e9","ref":"","in":"body"},{"ref":"","in":"body","required":true,"desc":"The referrer provided to you.","default":"","type":"string","name":"referrer","_id":"5730a7346b55e93400b329e8"}],"results":{"codes":[{"code":"{\n  \"id\": \"90f01dfdacbe4fe7892fc27dbdc30906\",\n  \"username\": \"foo\",\n  \"email\": \"foo@example.com\",\n  \"phone\": \"+919988776655\",\n  \"resource_uri\": \"https://api.instamojo.com/v2/users/90f01dfdacbe4fe7892fc27dbdc30906/\",\n  \"promo_code\": null\n}","name":"","status":200,"language":"json"},{"status":400,"language":"json","code":"{\n  \"username\": [\n    \"Username is not available.\"\n  ],\n  \"email\": [\n    \"Email already exists.\"\n  ]\n}","name":""},{"code":"{\n  \"success\": false,\n  \"message\": \"Authentication credentials were not provided.\"\n}","language":"json","status":401}]},"settings":"5729f56e7f34182900ce9d55","url":"/v2/users/","auth":"required","examples":{"codes":[{"code":"import requests\nrequests.post(\n  'https://api.instamojo.com/v2/users/', \n  data={\n      'email': 'foo@example.com',\n      'password': 'bar',\n      'phone': '+919988776655',\n      'referrer': 'value-provided-to-you-by-instamojo',\n  },\n  headers={\n \t\t\t'Authorization': 'Bearer y70kak2K0Rg7J4PAL8sdW0MutnGJEl' \n  }\n)\n              ","language":"python"}]},"method":"post"},"excerpt":"This will create an account on Instamojo. You need to use a token that is obtained using the Application Based Authentication.","link_external":false,"project":"56a1c9c13845200d0066d6fe","order":3,"sync_unique":"","title":"Signup","version":"571749c2d2a6510e00840a82","__v":5,"category":"5729f40a7f34182900ce9d52","isReference":true,"link_url":"","metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

postSignup

This will create an account on Instamojo. You need to use a token that is obtained using the Application Based Authentication.

Body Params

email:
required
string
Email id for the account.
password:
required
string
The password for the account.
phone:
required
string
Phone number for the account
referrer:
required
string
The referrer provided to you.

User Information

Try It Out

post
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Examples


Result Format



{"_id":"5730aa7bb16ed73200ddd1bc","type":"patch","user":"56a1c959842b650d0088899c","__v":3,"excerpt":"This will updated the details of an account on Instamojo. You need to use a token that is obtained using the User Based Authentication.","githubsync":"","order":4,"project":"56a1c9c13845200d0066d6fe","sync_unique":"","version":"571749c2d2a6510e00840a82","link_external":false,"parentDoc":null,"slug":"update-details-of-a-user","title":"Update details of a user","updates":[],"link_url":"","api":{"method":"patch","params":[{"desc":"First name of the account.","default":"","type":"string","name":"first_name","_id":"5730a1e826bd5a3600d337a0","ref":"","in":"body","required":false},{"name":"last_name","_id":"5730a22864726a200004318d","ref":"","in":"body","required":false,"desc":"Last name of the account.","default":"","type":"string"},{"type":"string","name":"location","_id":"5730a7346b55e93400b329ea","ref":"","in":"body","required":false,"desc":"Location of the user.","default":""},{"desc":"Phone number of the user.","default":"","type":"string","name":"phone","_id":"5730af1219c1e00e006d209f","ref":"","in":"body","required":false},{"name":"id","_id":"58007494456c950f000e57f6","ref":"","in":"path","required":false,"desc":"","default":"","type":"string"}],"results":{"codes":[{"name":"","code":"{\n  \"id\": \"90f01dfdacbe4fe7892fc27dbdc30906\",\n  \"username\": \"foo\",\n  \"first_name\": \"Foo\",\n  \"last_name\": \"Bar\",\n  \"phone\": \"+919988776655\",\n  \"email\": \"foo@example.com\",\n  \"date_joined\": \"2016-05-09T15:08:29.060Z\",\n  \"is_email_verified\": false,\n  \"is_phone_verified\": false,\n  \"bio\": \"\",\n  \"location\": \"India\",\n  \"public_phone\": null,\n  \"public_email\": null,\n  \"public_website\": null,\n  \"avatar_image_url\": null,\n  \"profile_image_url\": null,\n  \"tags\": [],\n  \"resource_uri\": \"https://api.instamojo.com/v2/users/90f01dfdacbe4fe7892fc27dbdc30906/\"\n}","language":"json","status":200},{"name":"","code":"{\n  \"phone\": [\n    \"Enter a valid phone number\"\n  ]\n}","language":"json","status":400},{"status":401,"language":"json","code":"{\n  \"success\": false,\n  \"message\": \"Authentication credentials were not provided.\"\n}"},{"code":"{\n  \"success\": false,\n  \"message\": \"Not found\"\n}","language":"json","status":404}]},"settings":"5729f56e7f34182900ce9d55","url":"/v2/users/:id/","auth":"required","examples":{"codes":[{"code":"import requests\nrequests.patch(\n  'https://api.instamojo.com/v2/users/90f01dfdacbe4fe7892fc27dbdc30906/', \n  data={\n    \t'first_name': 'Foo',\n      'last_name': 'Bar',\n      'location': 'India'\n    \t'phone': '+919988776655'\n  },\n  headers={\n \t\t\t'Authorization': 'Bearer n9kmKzF0DzbP5jIKZk8gJO0mOr4W0t' \n  }\n)\n              ","language":"python"}]}},"body":"","category":"5729f40a7f34182900ce9d52","createdAt":"2016-05-09T15:19:23.549Z","editedParams":true,"editedParams2":true,"hidden":false,"isReference":true,"metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

patchUpdate details of a user

This will updated the details of an account on Instamojo. You need to use a token that is obtained using the User Based Authentication.

Path Params

id:
string

Body Params

first_name:
string
First name of the account.
last_name:
string
Last name of the account.
location:
string
Location of the user.
phone:
string
Phone number of the user.

User Information

Try It Out

patch
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Examples


Result Format



{"_id":"5730afd16b55e93400b32a00","link_external":false,"order":5,"parentDoc":null,"slug":"update-bank-details-of-a-user","title":"Update bank details of a user","user":"56a1c959842b650d0088899c","body":"","editedParams":true,"hidden":false,"link_url":"","project":"56a1c9c13845200d0066d6fe","sync_unique":"","type":"put","version":"571749c2d2a6510e00840a82","api":{"auth":"required","examples":{"codes":[{"code":"import requests\nrequests.put(\n  'https://api.instamojo.com/v2/users/90f01dfdacbe4fe7892fc27dbdc30906/inrbankaccount/', \n  data={\n    \t'account_holder_name': 'Foo Bar',\n      'account_number': '123456789',\n      'ifsc_code': 'SBIN0000111'\n  },\n  headers={\n \t\t\t'Authorization': 'Bearer n9kmKzF0DzbP5jIKZk8gJO0mOr4W0t' \n  }\n)\n              ","language":"python"}]},"method":"put","params":[{"default":"","type":"string","name":"account_holder_name","_id":"5730a1e826bd5a3600d337a0","ref":"","in":"body","required":true,"desc":"Name of account holder."},{"default":"","type":"string","name":"account_number","_id":"5730a22864726a200004318d","ref":"","in":"body","required":true,"desc":"Bank account number."},{"in":"body","required":true,"desc":"IFSC code of the branch.","default":"","type":"string","name":"ifsc_code","_id":"5730a7346b55e93400b329ea","ref":""},{"required":false,"desc":"","default":"","type":"string","name":"id","_id":"58007520704ea60f0044acda","ref":"","in":"path"}],"results":{"codes":[{"name":"","code":"{\n  \"user\": \"https://api.instamojo.com/v2/users/90f01dfdacbe4fe7892fc27dbdc30906/\",\n  \"account_holder_name\": \"Foo Bar\",\n  \"bank_name\": \"\",\n  \"account_number\": \"123456789\",\n  \"ifsc_code\": \"SBIN0000111\",\n  \"updated_at\": \"2016-05-09T15:40:50.715Z\"\n}","language":"json","status":200},{"name":"","code":"{\n  \"ifsc_code\": [\n    \"This field is required.\"\n  ],\n  \"account_holder_name\": [\n    \"This field is required.\"\n  ],\n  \"account_number\": [\n    \"This field is required.\"\n  ]\n}","language":"json","status":400},{"status":401,"language":"json","code":"{\n  \"success\": false,\n  \"message\": \"Authentication credentials were not provided.\"\n}"},{"code":"{\n  \"success\": false,\n  \"message\": \"Not found\"\n}","language":"json","status":404}]},"settings":"5729f56e7f34182900ce9d55","url":"/v2/users/:id/inrbankaccount/"},"excerpt":"This will update the bank account details of an account on Instamojo. You need to use a token that is obtained using the User Based Authentication.","createdAt":"2016-05-09T15:42:09.464Z","updates":[],"__v":1,"githubsync":"","isReference":true,"category":"5729f40a7f34182900ce9d52","editedParams2":true,"metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

putUpdate bank details of a user

This will update the bank account details of an account on Instamojo. You need to use a token that is obtained using the User Based Authentication.

Path Params

id:
string

Body Params

account_holder_name:
required
string
Name of account holder.
account_number:
required
string
Bank account number.
ifsc_code:
required
string
IFSC code of the branch.

User Information

Try It Out

put
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Examples


Result Format



{"_id":"5730b6f626bd5a3600d337dd","order":6,"title":"Create a Payment Request","type":"post","link_external":false,"isReference":true,"next":{"description":"","pages":[]},"project":"56a1c9c13845200d0066d6fe","sync_unique":"","parentDoc":null,"slug":"create-a-payment-request","updates":[],"user":"56a1c959842b650d0088899c","version":"571749c2d2a6510e00840a82","editedParams2":true,"api":{"auth":"required","examples":{"codes":[{"code":"import requests\n\nheaders = { \n\t\"Authorization\": \"Bearer n9kmKzFODibP5jIKVk8gJO0NOr4W0t\"\n}\npayload = {\n  'purpose': 'FIFA 16',\n  'amount': '2500',\n  'buyer_name': 'John Doe',\n  'email': 'foo@example.com',\n  'phone': '9999999999',\n  'redirect_url': 'http://www.example.com/redirect/',\n  'send_email': 'True',\n  'send_sms': 'True',\n  'webhook': 'http://www.example.com/webhook/',\n  'allow_repeated_payments': 'False',\n}\nresponse = requests.post(\n  \"https://api.instamojo.com/v2/payment_requests/\", \n  data=payload, \n  headers=headers\n)              ","language":"python"}]},"method":"post","params":[{"_id":"5730b6f626bd5a3600d337e8","ref":"","in":"body","required":true,"desc":"The amount for the request. The minimum amount is 9. And the maximum is 200000.","default":"","type":"double","name":"amount"},{"_id":"5730b6f626bd5a3600d337e7","ref":"","in":"body","required":true,"desc":"Purpose of the payment request.","default":"","type":"string","name":"purpose"},{"_id":"5730b6f626bd5a3600d337e6","ref":"","in":"body","required":false,"desc":"Name of payer","default":"","type":"string","name":"buyer_name"},{"_id":"5730b6f626bd5a3600d337e5","ref":"","in":"body","required":false,"desc":"Email of payer","default":"","type":"string","name":"email"},{"_id":"5730b6f626bd5a3600d337e4","ref":"","in":"body","required":false,"desc":"Phone number of payer","default":"","type":"string","name":"phone"},{"_id":"5730b6f626bd5a3600d337e3","ref":"","in":"body","required":false,"desc":"URL where we redirect the user after a payment. If provided, we will redirect the user to `redirect_url` immediately after the payment has been processed. Three additional query arguments `payment_request_id`, `payment_status` and `payment_id` are also sent with the redirect URL.","default":"","type":"string","name":"redirect_url"},{"_id":"5730b6f626bd5a3600d337e2","ref":"","in":"body","required":false,"desc":"URL where our server do POST request after a payment  If provided, we will do a the POST request to the webhook (url) with full details of the payment","default":"","type":"string","name":"webhook"},{"_id":"5730b6f626bd5a3600d337e1","ref":"","in":"body","required":false,"desc":"If `allow_repeated_payments` is `false`, only one payment can be paid on a payment request link. `allow_repeated_payments` is `true` by default.","default":"True","type":"boolean","name":"allow_repeated_payments"},{"_id":"5730b6f626bd5a3600d337e0","ref":"","in":"body","required":false,"desc":"Allows you to receive a cut from from payments you facilitate. For fixed fee set this to `fixed`, or for percentage fee set it to `percent`.","default":"","type":"string","name":"partner_fee_type"},{"_id":"573b18576b49be2200c2e1e7","ref":"","in":"body","required":false,"desc":"This describes the fee that you would collect. It can be either a fixed amount, or a percentage of the original amount, depending on the value of `partner_fee_type`.","default":"","type":"double","name":"partner_fee"},{"_id":"5730b6f626bd5a3600d337df","ref":"","in":"body","required":false,"desc":"Flag to send request link via email.  If `send_email` is `true`, a request email will be sent to the email supplied. If `send_email` is `true` but no email is supplied, request creation will throw an error.","default":"False","type":"boolean","name":"send_email"},{"_id":"5730b6f626bd5a3600d337de","ref":"","in":"body","required":false,"desc":"Flag to send request link via SMS.  If `send_sms` is `true`, a request SMS will be sent to the phone number supplied. If `send_sms` is `true` but no phone number is supplied, request creation will throw an error.","default":"False","type":"boolean","name":"send_sms"},{"_id":"57c4259887a1060e00e36cd0","ref":"","in":"body","required":false,"desc":"Flag to determine if you want to put the payment on hold until you explicitly fulfil it. If `mark_fulfilled` is `True` the payment will be paid out to the merchant. If `mark_fulfilled` is `False`, then the payment will be put on hold until you explicitly fulfil the payment. See Fulfil a Payment below on how to fulfil a payment.","default":"True","type":"boolean","name":"mark_fulfilled"},{"_id":"58fdf14fc1e51e19004127ca","ref":"","in":"body","required":false,"desc":"Time after which the payment request will be expired in UTC timestamp. Max value is 600 seconds. Default is Null","default":"","type":"datetime","name":"expires_at"}],"results":{"codes":[{"name":"","code":"{\n  \"id\": \"05f317448ad84649aa1a9c7328edb015\",\n  \"user\": \"https://api.instamojo.com/v2/users/90f01dfdacbe4fe7892fc27dbdc30906/\",\n  \"phone\": \"+919999999999\",\n  \"email\": \"foo@example.com\",\n  \"buyer_name\": \"John Doe\",\n  \"amount\": \"2500\",\n  \"purpose\": \"FIFA 16\",\n  \"status\": \"Pending\",\n  \"payments\": [],\n  \"send_sms\": true,\n  \"send_email\": true,\n  \"sms_status\": \"Pending\",\n  \"email_status\": \"Pending\",\n  \"shorturl\": null,\n  \"longurl\": \"https://www.instamojo.com/@foo/05f317448ad84649aa1a9c7328edb015\",\n  \"redirect_url\": \"http://www.example.com/redirect/\",\n  \"webhook\": \"http://www.example.com/webhook/\",\n  \"created_at\": \"2016-05-09T16:10:13.786Z\",\n  \"modified_at\": \"2016-05-09T16:10:13.786Z\",\n  \"resource_uri\": \"https://api.instamojo.com/v2/payment_requests/05f317448ad84649aa1a9c7328edb015/\",\n  \"allow_repeated_payments\": false,\n  \"mark_fulfilled\": true\n}","language":"json","status":200},{"name":"","code":"{\n  \"purpose\": [\n    \"This field is required.\"\n  ],\n  \"amount\": [\n    \"This field is required.\"\n  ]\n}","language":"json","status":400},{"code":"{\n  \"success\": false,\n  \"message\": \"Authentication credentials were not provided.\"\n}","status":401,"language":"json"}]},"settings":"5729f56e7f34182900ce9d55","url":"/v2/payment_requests/"},"body":"","category":"5729f40a7f34182900ce9d52","createdAt":"2016-05-09T16:12:38.478Z","editedParams":true,"excerpt":"This will create a payment request on Instamojo. You need to use a token that is obtained using the User Based Authentication.","githubsync":"","__v":5,"link_url":"","hidden":false,"metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

postCreate a Payment Request

This will create a payment request on Instamojo. You need to use a token that is obtained using the User Based Authentication.

Body Params

amount:
required
double
The amount for the request. The minimum amount is 9. And the maximum is 200000.
purpose:
required
string
Purpose of the payment request.
buyer_name:
string
Name of payer
email:
string
Email of payer
phone:
string
Phone number of payer
redirect_url:
string
URL where we redirect the user after a payment. If provided, we will redirect the user to `redirect_url` immediately after the payment has been processed. Three additional query arguments `payment_request_id`, `payment_status` and `payment_id` are also sent with the redirect URL.
webhook:
string
URL where our server do POST request after a payment If provided, we will do a the POST request to the webhook (url) with full details of the payment
allow_repeated_payments:
booleanTrue
If `allow_repeated_payments` is `false`, only one payment can be paid on a payment request link. `allow_repeated_payments` is `true` by default.
partner_fee_type:
string
Allows you to receive a cut from from payments you facilitate. For fixed fee set this to `fixed`, or for percentage fee set it to `percent`.
partner_fee:
double
This describes the fee that you would collect. It can be either a fixed amount, or a percentage of the original amount, depending on the value of `partner_fee_type`.
send_email:
booleanFalse
Flag to send request link via email. If `send_email` is `true`, a request email will be sent to the email supplied. If `send_email` is `true` but no email is supplied, request creation will throw an error.
send_sms:
booleanFalse
Flag to send request link via SMS. If `send_sms` is `true`, a request SMS will be sent to the phone number supplied. If `send_sms` is `true` but no phone number is supplied, request creation will throw an error.
mark_fulfilled:
booleanTrue
Flag to determine if you want to put the payment on hold until you explicitly fulfil it. If `mark_fulfilled` is `True` the payment will be paid out to the merchant. If `mark_fulfilled` is `False`, then the payment will be put on hold until you explicitly fulfil the payment. See Fulfil a Payment below on how to fulfil a payment.
expires_at:
datetime
Time after which the payment request will be expired in UTC timestamp. Max value is 600 seconds. Default is Null

User Information

Try It Out

post
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Examples


Result Format



{"_id":"5730b7c019c1e00e006d20b2","api":{"method":"get","params":[{"desc":"","default":"","type":"string","name":"id","_id":"5800752e039bda2300152195","ref":"","in":"path","required":false}],"results":{"codes":[{"name":"","code":"{\n  \"id\": \"05f317448ad84649aa1a9c7328edb015\",\n  \"user\": \"https://api.instamojo.com/v2/users/90f01dfdacbe4fe7892fc27dbdc30906/\",\n  \"phone\": \"+919999999999\",\n  \"email\": \"foo@example.com\",\n  \"buyer_name\": \"John Doe\",\n  \"amount\": \"2500\",\n  \"purpose\": \"FIFA 16\",\n  \"status\": \"Pending\",\n  \"payments\": [],\n  \"send_sms\": true,\n  \"send_email\": true,\n  \"sms_status\": \"Pending\",\n  \"email_status\": \"Pending\",\n  \"shorturl\": null,\n  \"longurl\": \"https://www.instamojo.com/@foo/05f317448ad84649aa1a9c7328edb015\",\n  \"redirect_url\": \"http://www.example.com/redirect/\",\n  \"webhook\": \"http://www.example.com/webhook/\",\n  \"created_at\": \"2016-05-09T16:10:13.786Z\",\n  \"modified_at\": \"2016-05-09T16:10:13.786Z\",\n  \"resource_uri\": \"https://api.instamojo.com/v2/payment_requests/05f317448ad84649aa1a9c7328edb015/\",\n  \"allow_repeated_payments\": false,\n  \"mark_fulfilled\": true\n}","language":"json","status":200},{"status":401,"language":"json","code":"{\n  \"success\": false,\n  \"message\": \"Authentication credentials were not provided.\"\n}"}]},"settings":"5729f56e7f34182900ce9d55","url":"/v2/payment_requests/:id/","auth":"required","examples":{"codes":[{"code":"import requests\n\nheaders = { \n\t\"Authorization\": \"Bearer n9kmKzFODibP5jIKVk8gJO0NOr4W0t\"\n}\n\nresponse = requests.get(\n  \"https://api.instamojo.com/v2/payment_requests/9ef9b530ff8e440dbbc29f2157bc69ad/\", \n  headers=headers\n)              ","language":"python"}]}},"githubsync":"","isReference":true,"order":7,"project":"56a1c9c13845200d0066d6fe","sync_unique":"","body":"","link_external":false,"parentDoc":null,"type":"get","user":"56a1c959842b650d0088899c","category":"5729f40a7f34182900ce9d52","excerpt":"This will fetch the details of a payment request on Instamojo. You need to use a token that is obtained using the User Based Authentication.","link_url":"","slug":"get-a-payment-request","updates":[],"version":"571749c2d2a6510e00840a82","__v":6,"createdAt":"2016-05-09T16:16:00.073Z","hidden":false,"next":{"description":"","pages":[]},"title":"Get a Payment Request","metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

getGet a Payment Request

This will fetch the details of a payment request on Instamojo. You need to use a token that is obtained using the User Based Authentication.

Path Params

id:
string

User Information

Try It Out

get
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Examples


Result Format



{"_id":"5982d50cdb33c5002c74d36c","project":"56a1c9c13845200d0066d6fe","version":"571749c2d2a6510e00840a82","category":"5729f40a7f34182900ce9d52","user":"56a1c959842b650d0088899c","updates":[],"next":{"pages":[],"description":""},"createdAt":"2017-08-03T07:47:24.158Z","link_external":false,"link_url":"","githubsync":"","sync_unique":"","hidden":false,"api":{"examples":{"codes":[{"code":"import requests\n\nheaders = { \n\t\"Authorization\": \"Bearer n9kmKzFODibP5jIKVk8gJO0NOr4W0t\"\n}\n\nresponse = requests.get(\n  \"https://api.instamojo.com/v2/payments/MOJO7726005A06926769/\", \n  headers=headers\n)","language":"python"}]},"settings":"5729f56e7f34182900ce9d55","results":{"codes":[{"name":"","code":"{\n    \"id\": \"MOJO7726005A06926769\",\n    \"status\": true,\n    \"seller\": \"https://api.instamojo.com/v2/users/5b75694e1c1b498c9ceabed9cd5719cf/\",\n    \"currency\": \"INR\",\n    \"amount\": \"50.00\",\n    \"name\": \"Buyer Name\",\n    \"email\": \"buyer@instamojo.com\",\n    \"phone\": \"+919595959595\",\n    \"fees\": \"5.00\",\n    \"total_taxes\": \"0.50\",\n    \"instrument_type\": \"CARD\",\n\t\t\"billing_instrument\": \"Domestic Regular Credit Card (Visa/Mastercard)\",\n\t\t\n    \"payout\": {\n\t\t\"id\": \"MOJO8425001M94982125\",\n\t\t\"paid_out_at\": \"2017-07-30T09:24:45.987364Z\"\n\t\t},\n    \n    \"failure\": null,\n    \"created_at\": \"2017-07-26T12:45:23.431453Z\",\n    \"updated_at\": \"2017-07-26T23:31:39.020180Z\",\n    \"resource_uri\": \"https://api.instamojo.com/v2/payments/MOJO7726005A06926769/\"\n}","language":"json","status":200},{"status":401,"language":"json","code":"{\n  \"success\": false,\n  \"message\": \"Authentication credentials were not provided.\"\n}"}]},"method":"get","auth":"required","params":[{"_id":"5800752e039bda2300152195","ref":"","in":"path","required":false,"desc":"Payment ID","default":"","type":"string","name":"id"}],"url":"/v:version/payments/:id/"},"isReference":true,"order":8,"body":"[block:api-header]\n{\n  \"title\": \"Response Fields\"\n}\n[/block]\n\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Field Name\",\n    \"h-1\": \"Possible Values\",\n    \"h-2\": \"Description\",\n    \"0-0\": \"status\",\n    \"0-1\": \"* true\\n* false\\n* null\",\n    \"0-2\": \"Indicates the status of the payment.\\n\\n* **true** => Successful\\n* **false** => Failed\\n* **null** => Initiated\",\n    \"1-0\": \"instrument_type\",\n    \"1-1\": \"* CARD \\n* EMI\\n* NETBANKING\\n* UPI\\n* WALLET\",\n    \"1-2\": \"Indicates the instrument type used for the payment.\",\n    \"2-0\": \"failure\",\n    \"2-1\": \"* null\\n* Object:\\n  * reason\\n  * message\",\n    \"2-2\": \"Gives the failure reason of why the payment failed. This will have non-null values for failed payments only.\\n\\nreason => Type of failure.\\nmessage => Failure message returned by upstream provider.\",\n    \"3-0\": \"billing_instrument\",\n    \"3-1\": \"* null\\n* Unknown card\\n* Domestic Regular Credit Card (Visa/Mastercard)\\n* Domestic Premium Credit/Charge Card (Amex/Diners)\\n* Domestic Regular Debit Card (Visa/Mastercard)\\n* International Regular Credit Card (Visa/Mastercard)\\n* International Premium Credit/Charge Card (Amex/Diners)\\n* International Regular Debit Card\\n* Domestic Netbanking Category A (HDFC/ICICI)\\n* Domestic Netbanking Category B (Other banks)\\n* Wallet\\n* UPI\\n* Unknown netbanking choice\\n* EMI Payment\\n* Bank Transfer\",\n    \"3-2\": \"Gives the subcategory of the 'instrument_type' that was used to make the Payment.\",\n    \"4-0\": \"payout\",\n    \"4-1\": \"* null\\n* Object:\\n  * id\\n  * paid_out_at\",\n    \"4-2\": \"Gives you the Payout details once the Payout has been processed. \\n\\nThe response will be 'null' for the cases where the Payout has not been processed yet.\"\n  },\n  \"cols\": 3,\n  \"rows\": 5\n}\n[/block]","excerpt":"This will fetch the details of a payment on Instamojo. You need to use a token that is obtained using the User Based Authentication.","slug":"get-payment-details","type":"get","title":"Get Payment Details","__v":3,"parentDoc":null,"metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

getGet Payment Details

This will fetch the details of a payment on Instamojo. You need to use a token that is obtained using the User Based Authentication.

Path Params

id:
string
Payment ID
[block:api-header] { "title": "Response Fields" } [/block] [block:parameters] { "data": { "h-0": "Field Name", "h-1": "Possible Values", "h-2": "Description", "0-0": "status", "0-1": "* true\n* false\n* null", "0-2": "Indicates the status of the payment.\n\n* **true** => Successful\n* **false** => Failed\n* **null** => Initiated", "1-0": "instrument_type", "1-1": "* CARD \n* EMI\n* NETBANKING\n* UPI\n* WALLET", "1-2": "Indicates the instrument type used for the payment.", "2-0": "failure", "2-1": "* null\n* Object:\n * reason\n * message", "2-2": "Gives the failure reason of why the payment failed. This will have non-null values for failed payments only.\n\nreason => Type of failure.\nmessage => Failure message returned by upstream provider.", "3-0": "billing_instrument", "3-1": "* null\n* Unknown card\n* Domestic Regular Credit Card (Visa/Mastercard)\n* Domestic Premium Credit/Charge Card (Amex/Diners)\n* Domestic Regular Debit Card (Visa/Mastercard)\n* International Regular Credit Card (Visa/Mastercard)\n* International Premium Credit/Charge Card (Amex/Diners)\n* International Regular Debit Card\n* Domestic Netbanking Category A (HDFC/ICICI)\n* Domestic Netbanking Category B (Other banks)\n* Wallet\n* UPI\n* Unknown netbanking choice\n* EMI Payment\n* Bank Transfer", "3-2": "Gives the subcategory of the 'instrument_type' that was used to make the Payment.", "4-0": "payout", "4-1": "* null\n* Object:\n * id\n * paid_out_at", "4-2": "Gives you the Payout details once the Payout has been processed. \n\nThe response will be 'null' for the cases where the Payout has not been processed yet." }, "cols": 3, "rows": 5 } [/block]

User Information

Try It Out

get
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Examples


Result Format



[block:api-header] { "title": "Response Fields" } [/block] [block:parameters] { "data": { "h-0": "Field Name", "h-1": "Possible Values", "h-2": "Description", "0-0": "status", "0-1": "* true\n* false\n* null", "0-2": "Indicates the status of the payment.\n\n* **true** => Successful\n* **false** => Failed\n* **null** => Initiated", "1-0": "instrument_type", "1-1": "* CARD \n* EMI\n* NETBANKING\n* UPI\n* WALLET", "1-2": "Indicates the instrument type used for the payment.", "2-0": "failure", "2-1": "* null\n* Object:\n * reason\n * message", "2-2": "Gives the failure reason of why the payment failed. This will have non-null values for failed payments only.\n\nreason => Type of failure.\nmessage => Failure message returned by upstream provider.", "3-0": "billing_instrument", "3-1": "* null\n* Unknown card\n* Domestic Regular Credit Card (Visa/Mastercard)\n* Domestic Premium Credit/Charge Card (Amex/Diners)\n* Domestic Regular Debit Card (Visa/Mastercard)\n* International Regular Credit Card (Visa/Mastercard)\n* International Premium Credit/Charge Card (Amex/Diners)\n* International Regular Debit Card\n* Domestic Netbanking Category A (HDFC/ICICI)\n* Domestic Netbanking Category B (Other banks)\n* Wallet\n* UPI\n* Unknown netbanking choice\n* EMI Payment\n* Bank Transfer", "3-2": "Gives the subcategory of the 'instrument_type' that was used to make the Payment.", "4-0": "payout", "4-1": "* null\n* Object:\n * id\n * paid_out_at", "4-2": "Gives you the Payout details once the Payout has been processed. \n\nThe response will be 'null' for the cases where the Payout has not been processed yet." }, "cols": 3, "rows": 5 } [/block]
{"_id":"5730b9f7053a062b00cf4647","editedParams":true,"excerpt":"This will refund a payment made on Instamojo. You need to use a token that is obtained using the User Based Authentication.","hidden":false,"link_url":"","order":9,"parentDoc":null,"type":"post","editedParams2":true,"isReference":true,"updates":[],"__v":3,"api":{"settings":"5729f56e7f34182900ce9d55","url":"/v2/payments/:payment_id/refund/","auth":"required","examples":{"codes":[{"code":"import requests\n\nheaders = { \n\t\"Authorization\": \"Bearer n9kmKzFODibP5jIKVk8gJO0NOr4W0t\"\n}\n\npayload = {\n  'transaction_id': 'partial_refund_1',\n\t'type': 'TNR',\n  'body': 'Need to refund to the buyer.',\n  'refund_amount': '100'\n}\n\nresponse = requests.post(\n  \"https://api.instamojo.com/v2/payments/MOJO5c04000J30502939/refund/\", \n  headers=headers,\n  data=payload\n)              ","language":"python"}]},"method":"post","params":[{"_id":"5730b9f7053a062b00cf464a","ref":"","in":"body","required":true,"desc":"A three letter short-code identifying the reason for this case.","default":"","type":"string","name":"type"},{"_id":"5730b9f7053a062b00cf4649","ref":"","in":"body","required":true,"desc":"Additonal text explaining the refund.","default":"","type":"string","name":"body"},{"_id":"5730b9f7053a062b00cf4648","ref":"","in":"body","required":true,"desc":"This field can be used to specify the refund amount. For instance, you may want to issue a refund for an amount lesser than what was paid.","default":"","type":"string","name":"refund_amount"},{"_id":"58007538456c950f000e57f7","ref":"","in":"path","required":false,"desc":"","default":"","type":"string","name":"payment_id"},{"_id":"5cc182f36ad63801ab22c4ab","ref":"","in":"body","required":true,"desc":"Mandatory parameter in the body from the second case creation onwards for the payment to prevent duplicate case creations due to replay of APIs","default":"required","type":"string","name":"transaction_id"}],"results":{"codes":[{"name":"","code":"{\n    \"refund\": {\n        \"id\": \"C5c0751269\",\n        \"payment_id\": \"MOJO5c04000J30502939\",\n        \"status\": \"Refunded\",\n        \"type\": \"QFL\",\n        \"body\": \"Customer isn't satisfied with the quality\",\n        \"refund_amount\": \"100\",\n        \"total_amount\": \"100.00\",\n        \"created_at\": \"2015-12-07T11:01:37.640Z\"\n    },\n    \"success\": true\n}","language":"json","status":200},{"status":401,"language":"json","code":"{\n  \"success\": false,\n  \"message\": \"Authentication credentials were not provided.\"\n}"}]}},"link_external":false,"project":"56a1c9c13845200d0066d6fe","slug":"create-a-refund","title":"Create a Refund","version":"571749c2d2a6510e00840a82","body":"Valid values for type are:\n[block:parameters]\n{\n  \"data\": {\n    \"h-0\": \"Type\",\n    \"h-1\": \"Description\",\n    \"0-0\": \"RFD\",\n    \"0-1\": \"Duplicate/delayed payment.\",\n    \"1-1\": \"Product/service no longer available.\",\n    \"2-1\": \"Customer not satisfied.\",\n    \"3-1\": \"Product lost/damaged.\",\n    \"4-1\": \"Digital download issue.\",\n    \"5-1\": \"Event was canceled/changed.\",\n    \"6-1\": \"Problem not described above.\",\n    \"1-0\": \"TNR\",\n    \"2-0\": \"QFL\",\n    \"6-0\": \"PTH\",\n    \"5-0\": \"TAN\",\n    \"4-0\": \"EWN\",\n    \"3-0\": \"QNR\"\n  },\n  \"cols\": 2,\n  \"rows\": 7\n}\n[/block]","category":"5729f40a7f34182900ce9d52","createdAt":"2016-05-09T16:25:27.295Z","githubsync":"","sync_unique":"","user":"56a1c959842b650d0088899c","next":{"description":"","pages":[]},"metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

postCreate a Refund

This will refund a payment made on Instamojo. You need to use a token that is obtained using the User Based Authentication.

Path Params

payment_id:
string

Body Params

type:
required
string
A three letter short-code identifying the reason for this case.
body:
required
string
Additonal text explaining the refund.
refund_amount:
required
string
This field can be used to specify the refund amount. For instance, you may want to issue a refund for an amount lesser than what was paid.
transaction_id:
required
stringrequired
Mandatory parameter in the body from the second case creation onwards for the payment to prevent duplicate case creations due to replay of APIs
Valid values for type are: [block:parameters] { "data": { "h-0": "Type", "h-1": "Description", "0-0": "RFD", "0-1": "Duplicate/delayed payment.", "1-1": "Product/service no longer available.", "2-1": "Customer not satisfied.", "3-1": "Product lost/damaged.", "4-1": "Digital download issue.", "5-1": "Event was canceled/changed.", "6-1": "Problem not described above.", "1-0": "TNR", "2-0": "QFL", "6-0": "PTH", "5-0": "TAN", "4-0": "EWN", "3-0": "QNR" }, "cols": 2, "rows": 7 } [/block]

User Information

Try It Out

post
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Examples


Result Format



Valid values for type are: [block:parameters] { "data": { "h-0": "Type", "h-1": "Description", "0-0": "RFD", "0-1": "Duplicate/delayed payment.", "1-1": "Product/service no longer available.", "2-1": "Customer not satisfied.", "3-1": "Product lost/damaged.", "4-1": "Digital download issue.", "5-1": "Event was canceled/changed.", "6-1": "Problem not described above.", "1-0": "TNR", "2-0": "QFL", "6-0": "PTH", "5-0": "TAN", "4-0": "EWN", "3-0": "QNR" }, "cols": 2, "rows": 7 } [/block]
{"_id":"57c429e519b0bb0e00ee1642","__v":1,"body":"","category":"5729f40a7f34182900ce9d52","title":"Fulfil a Payment","type":"post","version":"571749c2d2a6510e00840a82","updates":[],"githubsync":"","isReference":true,"link_url":"","order":10,"parentDoc":null,"project":"56a1c9c13845200d0066d6fe","api":{"method":"post","params":[{"desc":"","default":"","type":"string","name":"payment_id","_id":"58007542704ea60f0044acdb","ref":"","in":"path","required":false}],"results":{"codes":[{"code":"{\n  \"fulfil\": true,\n  \"success\": true\n}","language":"json","status":200,"name":""},{"status":401,"language":"json","code":"{\n  \"success\": false,\n  \"message\": \"Authentication credentials were not provided.\"\n}"}]},"settings":"5729f56e7f34182900ce9d55","url":"/v2/payments/:payment_id/fulfil/","auth":"required","examples":{"codes":[{"language":"python","code":"import requests\n\nheaders = { \n\t\"Authorization\": \"Bearer y70kak2K0Rg7J4PAL8sdW0MutnGJEl\"\n}\n\nresponse = requests.post(\n  \"https://api.instamojo.com/v2/payments/MOJO5c04000J30502939/fulfil/\", \n  headers=headers\n)              "}]}},"excerpt":"This will fulfil a payment made on Instamojo. You need to use a token that is obtained using the Application Based Authentication.","hidden":false,"link_external":false,"sync_unique":"","createdAt":"2016-08-29T12:26:13.853Z","slug":"fulfil-a-payment","user":"56a1c959842b650d0088899c","metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

postFulfil a Payment

This will fulfil a payment made on Instamojo. You need to use a token that is obtained using the Application Based Authentication.

Path Params

payment_id:
string

User Information

Try It Out

post
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Examples


Result Format



{"_id":"583803120bd5ea190004b72c","type":"post","user":"56a1c959842b650d0088899c","body":"","githubsync":"","hidden":false,"isReference":true,"link_url":"","next":{"description":"","pages":[]},"version":"571749c2d2a6510e00840a82","__v":0,"excerpt":"This will create a Order on Instamojo. You need to use a token that is obtained using the User Based Authentication.","parentDoc":null,"project":"56a1c9c13845200d0066d6fe","sync_unique":"","slug":"create-an-order-using-payment-request-id","title":"Create an Order using Payment Request ID","updates":[],"api":{"settings":"5729f56e7f34182900ce9d55","url":"/v2/gateway/orders/payment-request/","auth":"required","examples":{"codes":[{"language":"python","code":"import requests\n\nheaders = { \n\t\"Authorization\": \"Bearer n9kmKzFODibP5jIKVk8gJO0NOr4W0t\"\n}\npayload = {\n  'id': '9c337d3c5e3242fca818937366b915b4',\n}\nresponse = requests.post(\n  \"https://api.instamojo.com/v2/gateway/orders/payment-request/\", \n  data=payload, \n  headers=headers\n)      "}]},"method":"post","params":[{"required":false,"desc":"Payment Request ID","default":"","type":"string","name":"id","_id":"583803120bd5ea190004b72d","ref":"","in":"body"}],"results":{"codes":[{"name":"","status":200,"language":"json","code":"{\n  \"order_id\": \"3b56d216-74c2-4189-83f3-9c2e93bad1be\",\n  \"name\": \"Vedhavyas\",\n  \"email\": \"vedhavyas@instamojo.com\",\n  \"phone\": \"+919663445546\",\n  \"amount\": \"100.00\"\n}"},{"status":400,"language":"json","code":"{\n  \"id\": [\n    \"This field is required.\"\n  ]\n}","name":""},{"status":401,"language":"text","code":"{\n  \"success\": false,\n  \"message\": \"Authentication credentials were not provided.\"\n}"}]}},"category":"5729f40a7f34182900ce9d52","createdAt":"2016-11-25T09:23:30.720Z","link_external":false,"order":11,"metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

postCreate an Order using Payment Request ID

This will create a Order on Instamojo. You need to use a token that is obtained using the User Based Authentication.

Body Params

id:
string
Payment Request ID

User Information

Try It Out

post
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Examples


Result Format



{"_id":"590b2d5ed0a41e23001aade5","api":{"url":"/v2/payment_requests/:id/disable/","auth":"required","examples":{"codes":[{"language":"python","code":"import requests\n\nheaders = { \n\t\"Authorization\": \"Bearer fRPB9REdsmD7C2qX9uJolWPhsIu4Tc\"\n}\nresponse = requests.post(\n \"https://api.instamojo.com/v2/payment_requests/6a04501b03964ce4874711566e84fabb/disable/\", headers=headers\n) "}]},"method":"post","params":[{"default":"","desc":"","in":"path","name":"id","ref":"","required":true,"type":"string","_id":"590b2d5ed0a41e23001aade6"}],"results":{"codes":[{"status":200,"language":"json","code":"{\n    \"success\": true\n}","name":""}]},"settings":"5729f56e7f34182900ce9d55"},"body":"","next":{"pages":[],"description":""},"sync_unique":"","user":"56a1c959842b650d0088899c","category":"5729f40a7f34182900ce9d52","createdAt":"2017-05-04T13:32:14.473Z","hidden":false,"isReference":true,"slug":"disable-a-request","title":"Disable a Request","type":"post","version":"571749c2d2a6510e00840a82","__v":0,"excerpt":"This will disable the payment request on Instamojo. You need to use a token that is obtained using the User Based Authentication.","link_external":false,"link_url":"","order":12,"project":"56a1c9c13845200d0066d6fe","updates":[],"githubsync":"","parentDoc":null,"metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

postDisable a Request

This will disable the payment request on Instamojo. You need to use a token that is obtained using the User Based Authentication.

Path Params

id:
required
string

User Information

Try It Out

post
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Examples


Result Format



{"_id":"590b2e39c0161e1900953776","body":"","excerpt":"This will enable the payment request on Instamojo. You need to use a token that is obtained using the User Based Authentication.","link_external":false,"slug":"enable-a-request","type":"post","__v":0,"hidden":false,"sync_unique":"","api":{"settings":"5729f56e7f34182900ce9d55","url":"/v2/payment_requests/:id/enable/","auth":"required","examples":{"codes":[{"language":"python","code":"import requests\n\nheaders = { \n\t\"Authorization\": \"Bearer fRPB9REdsmD7C2qX9uJolWPhsIu4Tc\"\n}\nresponse = requests.post(\n \"https://api.instamojo.com/v2/payment_requests/6a04501b03964ce4874711566e84fabb/enable/\", headers=headers\n) "}]},"method":"post","params":[{"ref":"","required":true,"type":"string","_id":"590b2e39c0161e1900953777","default":"","desc":"","in":"path","name":"id"}],"results":{"codes":[{"code":"{\n    \"success\": true\n}","name":"","status":200,"language":"json"}]}},"githubsync":"","order":13,"project":"56a1c9c13845200d0066d6fe","updates":[],"createdAt":"2017-05-04T13:35:53.608Z","isReference":true,"link_url":"","next":{"pages":[],"description":""},"title":"Enable a Request","user":"56a1c959842b650d0088899c","version":"571749c2d2a6510e00840a82","category":"5729f40a7f34182900ce9d52","parentDoc":null,"metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

postEnable a Request

This will enable the payment request on Instamojo. You need to use a token that is obtained using the User Based Authentication.

Path Params

id:
required
string

User Information

Try It Out

post
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Examples


Result Format



{"_id":"589c705f29523b23003ba24b","sync_unique":"","isReference":false,"next":{"pages":[],"description":""},"category":"589c3e328912591b00fd9506","githubsync":"","link_external":false,"parentDoc":null,"title":"Common API Response codes","type":"basic","api":{"settings":"","results":{"codes":[{"status":200,"language":"json","code":"{}","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"auth":"required","params":[],"url":""},"body":"* `200` : The API request was successful and you can find the API response in the body. \n\n* `201` : The API request successfully created a resource on our server. You will see this response when you create a new signup or a new payment request.\n\n* `301` : The API responded with a redirect request. You are most likely missing a trailing slash at the end of your request URL.\n\n* `400` : The API request you sent failed the validation requirements. You should look into the response body for more details about the error(s).\n\n* `401` : The API request you are sending does not have authentication headers or has incorrect authentication header names or the authentication token is expired or invalid. Also if you are using https://test.instamojo.com as your base URL, ensure that you are using the authentication credentials from https://test.instamojo.com/integrations. Similarly, if you are using https://www.instamojo.com as your base URL, use the authentication credentials from https://www.instamojo.com/integrations\n\n* `403` : You are using incorrect tokens or your token does not have the necessary permissions for performing the action. Check if you are using a [User Based Authentication](doc:user-based-authentication) on an API that requires you to use an [Application Based Authentication](doc:application-based-authentication)\n\n* `404` : The request URL is incorrect or does not exist.\n\n* `500` : There was an error on one of our servers with your request. Please reach out to us via [support@instamojo.com](mailto:support@instamojo.com)\n\n* `502` : There was an error on one of our servers with your request. Please reach out to us via [support@instamojo.com](mailto:support@instamojo.com)\n\n* `504` : There was an error on one of our servers with your request. Please reach out to us via [support@instamojo.com](mailto:support@instamojo.com)\n\n\nYou can also find a more comprehensive list of HTTP response codes here: http://httpstatuses.com/","updates":[],"createdAt":"2017-02-09T13:36:31.669Z","excerpt":"","hidden":false,"link_url":"","order":0,"project":"56a1c9c13845200d0066d6fe","__v":0,"version":"571749c2d2a6510e00840a82","slug":"common-api-response-codes","user":"56a1c959842b650d0088899c","metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

Common API Response codes


* `200` : The API request was successful and you can find the API response in the body. * `201` : The API request successfully created a resource on our server. You will see this response when you create a new signup or a new payment request. * `301` : The API responded with a redirect request. You are most likely missing a trailing slash at the end of your request URL. * `400` : The API request you sent failed the validation requirements. You should look into the response body for more details about the error(s). * `401` : The API request you are sending does not have authentication headers or has incorrect authentication header names or the authentication token is expired or invalid. Also if you are using https://test.instamojo.com as your base URL, ensure that you are using the authentication credentials from https://test.instamojo.com/integrations. Similarly, if you are using https://www.instamojo.com as your base URL, use the authentication credentials from https://www.instamojo.com/integrations * `403` : You are using incorrect tokens or your token does not have the necessary permissions for performing the action. Check if you are using a [User Based Authentication](doc:user-based-authentication) on an API that requires you to use an [Application Based Authentication](doc:application-based-authentication) * `404` : The request URL is incorrect or does not exist. * `500` : There was an error on one of our servers with your request. Please reach out to us via [support@instamojo.com](mailto:support@instamojo.com) * `502` : There was an error on one of our servers with your request. Please reach out to us via [support@instamojo.com](mailto:support@instamojo.com) * `504` : There was an error on one of our servers with your request. Please reach out to us via [support@instamojo.com](mailto:support@instamojo.com) You can also find a more comprehensive list of HTTP response codes here: http://httpstatuses.com/
* `200` : The API request was successful and you can find the API response in the body. * `201` : The API request successfully created a resource on our server. You will see this response when you create a new signup or a new payment request. * `301` : The API responded with a redirect request. You are most likely missing a trailing slash at the end of your request URL. * `400` : The API request you sent failed the validation requirements. You should look into the response body for more details about the error(s). * `401` : The API request you are sending does not have authentication headers or has incorrect authentication header names or the authentication token is expired or invalid. Also if you are using https://test.instamojo.com as your base URL, ensure that you are using the authentication credentials from https://test.instamojo.com/integrations. Similarly, if you are using https://www.instamojo.com as your base URL, use the authentication credentials from https://www.instamojo.com/integrations * `403` : You are using incorrect tokens or your token does not have the necessary permissions for performing the action. Check if you are using a [User Based Authentication](doc:user-based-authentication) on an API that requires you to use an [Application Based Authentication](doc:application-based-authentication) * `404` : The request URL is incorrect or does not exist. * `500` : There was an error on one of our servers with your request. Please reach out to us via [support@instamojo.com](mailto:support@instamojo.com) * `502` : There was an error on one of our servers with your request. Please reach out to us via [support@instamojo.com](mailto:support@instamojo.com) * `504` : There was an error on one of our servers with your request. Please reach out to us via [support@instamojo.com](mailto:support@instamojo.com) You can also find a more comprehensive list of HTTP response codes here: http://httpstatuses.com/
{"_id":"589c4fce0552cc2f00a61cc6","__v":0,"body":"1. [Create a Payment Request](doc:create-a-payment-request) with the buyer's name, email, and phone number. \n2. Fetch the `longurl` from the response body of the API request.\n3. Redirect the user to the `longurl` to complete the payment.\n4. If you are using Light Checkout, append `?embed=form` to the `longurl` before rendering the URL.","sync_unique":"","api":{"results":{"codes":[{"status":200,"language":"json","code":"{}","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","auth":"required","params":[],"url":""},"excerpt":"","githubsync":"","isReference":false,"link_external":false,"link_url":"","next":{"pages":[],"description":""},"parentDoc":null,"slug":"how-can-i-prefill-buyer-details-on-payment-forms","updates":[],"user":"56a1c959842b650d0088899c","version":"571749c2d2a6510e00840a82","category":"589c3e328912591b00fd9506","order":1,"project":"56a1c9c13845200d0066d6fe","title":"How can I prefill buyer details on payment forms?","type":"basic","createdAt":"2017-02-09T11:17:34.229Z","hidden":false,"metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

How can I prefill buyer details on payment forms?


1. [Create a Payment Request](doc:create-a-payment-request) with the buyer's name, email, and phone number. 2. Fetch the `longurl` from the response body of the API request. 3. Redirect the user to the `longurl` to complete the payment. 4. If you are using Light Checkout, append `?embed=form` to the `longurl` before rendering the URL.
1. [Create a Payment Request](doc:create-a-payment-request) with the buyer's name, email, and phone number. 2. Fetch the `longurl` from the response body of the API request. 3. Redirect the user to the `longurl` to complete the payment. 4. If you are using Light Checkout, append `?embed=form` to the `longurl` before rendering the URL.
{"_id":"589c51950552cc2f00a61cce","order":2,"project":"56a1c9c13845200d0066d6fe","slug":"can-instamojo-save-the-creditdebit-card-numbers-of-my-customers","sync_unique":"","api":{"results":{"codes":[{"language":"json","code":"{}","name":"","status":200},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","auth":"required","params":[],"url":""},"body":"No. Not yet.","isReference":false,"link_url":"","type":"basic","updates":[],"version":"571749c2d2a6510e00840a82","title":"Can Instamojo save the credit/debit card numbers of my customers?","createdAt":"2017-02-09T11:25:09.801Z","githubsync":"","hidden":false,"parentDoc":null,"category":"589c3e328912591b00fd9506","user":"56a1c959842b650d0088899c","__v":0,"excerpt":"","link_external":false,"next":{"pages":[],"description":""},"metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

Can Instamojo save the credit/debit card numbers of my customers?


No. Not yet.
{"_id":"589c52fe0552cc2f00a61cd5","updates":["5c7d5ee0bd57e9002a7f4386","5d1e1587d37787019103ac90"],"excerpt":"","hidden":false,"slug":"what-is-a-webhook","title":"What is a webhook?","api":{"results":{"codes":[{"code":"{}","name":"","status":200,"language":"json"},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","auth":"required","params":[],"url":""},"body":"Webhooks allow you to get notified of events that happen on Instamojo.\n\nFor example, when a buyer makes payment, Instamojo can send an HTTP POST request to your server. This avoids the need to keep polling Instamojo servers for updates.\n\nA webhook is not a redirect. The buyer or the browser will never see it. Its a communication channel between Instamojo servers and your servers.\n\nHere are some use cases where a webhook might be useful:\n\n1. Sending a custom email from your server at the end of every transaction\n2. Activation of a user's account on your service\n3. Sending a user the license key to your software\n4. Adding a user to your CRM software\n5. Adding the transaction to your accounting software\n\nBy default, a webhook is sent only on successful payments, but can be enabled\nfor failures too. Please get in touch with [support@instamojo.com](mailto:support@instamojo.com) for the same.\n\nA webhook URL should be an internet facing publicly accessible URL on your server, which accepts a POST request from instamojo.com. CSRF checks should be disabled and if the server is hosted over HTTPS, the SSL certificate should be valid and not expired. The URL should not have any kind of authentication.\n\nWe have a handy [https://www.instamojo.com/webhook-testing-tool/](webhook testing tool) which can be used to test your server. [https://requestb.in/](Request bin) is a useful service to explore the request sent by the server.\n\nThe webhook request is request with content-type `application/www-form-urlencoded`. Don't try to handle it like a JSON request.\n\nThe parameters for Payment requests are\n\n| Key                | Description                                                     |\n|--------------------|-----------------------------------------------------------------|\n| amount             | Amount related to the payment                                   |\n| buyer              | Buyer's email                                                   |\n| buyer_name         | Buyer's name                                                    |\n| buyer_phone        | Buyer's phone number                                            |\n| currency           | Currency related to the payment                                 |\n| fees               | Fees charged by Instamojo                                       |\n| longurl            | URL related to the payment request                              |\n| mac                | Message Authentication code of this webhook request             |\n| payment_id         | ID of the payment                                               |\n| payment_request_id | ID of the payment request                                       |\n| purpose            | Purpose of the Payment request                                  |\n| shorturl           | Short URL of the payment request                                |\n| status             | Status of the Payment. This can be either \"Credit\" or \"Failed\". |\n\nNOTE: This list of keys will get updated over time. So when you are integrating,\nwe recommend you to account for new keys that will be added to this.","next":{"pages":[],"description":""},"version":"571749c2d2a6510e00840a82","category":"589c3e328912591b00fd9506","isReference":false,"link_external":false,"link_url":"","project":"56a1c9c13845200d0066d6fe","sync_unique":"","type":"basic","user":"56a1c959842b650d0088899c","__v":2,"createdAt":"2017-02-09T11:31:10.579Z","githubsync":"","order":3,"parentDoc":null,"metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

What is a webhook?


Webhooks allow you to get notified of events that happen on Instamojo. For example, when a buyer makes payment, Instamojo can send an HTTP POST request to your server. This avoids the need to keep polling Instamojo servers for updates. A webhook is not a redirect. The buyer or the browser will never see it. Its a communication channel between Instamojo servers and your servers. Here are some use cases where a webhook might be useful: 1. Sending a custom email from your server at the end of every transaction 2. Activation of a user's account on your service 3. Sending a user the license key to your software 4. Adding a user to your CRM software 5. Adding the transaction to your accounting software By default, a webhook is sent only on successful payments, but can be enabled for failures too. Please get in touch with [support@instamojo.com](mailto:support@instamojo.com) for the same. A webhook URL should be an internet facing publicly accessible URL on your server, which accepts a POST request from instamojo.com. CSRF checks should be disabled and if the server is hosted over HTTPS, the SSL certificate should be valid and not expired. The URL should not have any kind of authentication. We have a handy [https://www.instamojo.com/webhook-testing-tool/](webhook testing tool) which can be used to test your server. [https://requestb.in/](Request bin) is a useful service to explore the request sent by the server. The webhook request is request with content-type `application/www-form-urlencoded`. Don't try to handle it like a JSON request. The parameters for Payment requests are | Key | Description | |--------------------|-----------------------------------------------------------------| | amount | Amount related to the payment | | buyer | Buyer's email | | buyer_name | Buyer's name | | buyer_phone | Buyer's phone number | | currency | Currency related to the payment | | fees | Fees charged by Instamojo | | longurl | URL related to the payment request | | mac | Message Authentication code of this webhook request | | payment_id | ID of the payment | | payment_request_id | ID of the payment request | | purpose | Purpose of the Payment request | | shorturl | Short URL of the payment request | | status | Status of the Payment. This can be either "Credit" or "Failed". | NOTE: This list of keys will get updated over time. So when you are integrating, we recommend you to account for new keys that will be added to this.
Webhooks allow you to get notified of events that happen on Instamojo. For example, when a buyer makes payment, Instamojo can send an HTTP POST request to your server. This avoids the need to keep polling Instamojo servers for updates. A webhook is not a redirect. The buyer or the browser will never see it. Its a communication channel between Instamojo servers and your servers. Here are some use cases where a webhook might be useful: 1. Sending a custom email from your server at the end of every transaction 2. Activation of a user's account on your service 3. Sending a user the license key to your software 4. Adding a user to your CRM software 5. Adding the transaction to your accounting software By default, a webhook is sent only on successful payments, but can be enabled for failures too. Please get in touch with [support@instamojo.com](mailto:support@instamojo.com) for the same. A webhook URL should be an internet facing publicly accessible URL on your server, which accepts a POST request from instamojo.com. CSRF checks should be disabled and if the server is hosted over HTTPS, the SSL certificate should be valid and not expired. The URL should not have any kind of authentication. We have a handy [https://www.instamojo.com/webhook-testing-tool/](webhook testing tool) which can be used to test your server. [https://requestb.in/](Request bin) is a useful service to explore the request sent by the server. The webhook request is request with content-type `application/www-form-urlencoded`. Don't try to handle it like a JSON request. The parameters for Payment requests are | Key | Description | |--------------------|-----------------------------------------------------------------| | amount | Amount related to the payment | | buyer | Buyer's email | | buyer_name | Buyer's name | | buyer_phone | Buyer's phone number | | currency | Currency related to the payment | | fees | Fees charged by Instamojo | | longurl | URL related to the payment request | | mac | Message Authentication code of this webhook request | | payment_id | ID of the payment | | payment_request_id | ID of the payment request | | purpose | Purpose of the Payment request | | shorturl | Short URL of the payment request | | status | Status of the Payment. This can be either "Credit" or "Failed". | NOTE: This list of keys will get updated over time. So when you are integrating, we recommend you to account for new keys that will be added to this.
{"_id":"58c24c379609c40f004b4b86","hidden":false,"sync_unique":"","title":"What if the webhook fails?","user":"56a1c959842b650d0088899c","body":"In case your server is down and fails to return an HTTP response or returns a 4xx or 5xx response to our server, we will attempt 4 retries.\n\nThe first retry is attempted after `15 minutes` since the original webhook attempt.\nThe second retry is attempted after `30 minutes` after the first retry.\nThe third retry is attempted after `60 minutes` after the second retry.\nThe fourth retry is attempted after `2 hours` after the third retry.\n\nThis is the last and final attempt, after which the webhook will not be sent anymore.\n\nWebhook retries is disabled by default. In case you want this to be enabled for your account, please send us an email to support@instamojo.com regarding this.","category":"589c3e328912591b00fd9506","excerpt":"","githubsync":"","link_url":"","order":4,"parentDoc":null,"project":"56a1c9c13845200d0066d6fe","api":{"auth":"required","params":[],"url":"","settings":"","results":{"codes":[{"status":200,"language":"json","code":"{}","name":""},{"status":400,"language":"json","code":"{}","name":""}]}},"createdAt":"2017-03-10T06:48:23.236Z","isReference":false,"next":{"description":"","pages":[]},"version":"571749c2d2a6510e00840a82","__v":0,"type":"basic","updates":[],"link_external":false,"slug":"what-if-the-webhook-fails","metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

What if the webhook fails?


In case your server is down and fails to return an HTTP response or returns a 4xx or 5xx response to our server, we will attempt 4 retries. The first retry is attempted after `15 minutes` since the original webhook attempt. The second retry is attempted after `30 minutes` after the first retry. The third retry is attempted after `60 minutes` after the second retry. The fourth retry is attempted after `2 hours` after the third retry. This is the last and final attempt, after which the webhook will not be sent anymore. Webhook retries is disabled by default. In case you want this to be enabled for your account, please send us an email to support@instamojo.com regarding this.
In case your server is down and fails to return an HTTP response or returns a 4xx or 5xx response to our server, we will attempt 4 retries. The first retry is attempted after `15 minutes` since the original webhook attempt. The second retry is attempted after `30 minutes` after the first retry. The third retry is attempted after `60 minutes` after the second retry. The fourth retry is attempted after `2 hours` after the third retry. This is the last and final attempt, after which the webhook will not be sent anymore. Webhook retries is disabled by default. In case you want this to be enabled for your account, please send us an email to support@instamojo.com regarding this.
{"_id":"589c56880552cc2f00a61ce1","user":"56a1c959842b650d0088899c","version":"571749c2d2a6510e00840a82","api":{"results":{"codes":[{"code":"{}","name":"","status":200,"language":"json"},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","auth":"required","params":[],"url":""},"githubsync":"","isReference":false,"title":"What are the values of status of a payment?","next":{"pages":[],"description":""},"order":5,"parentDoc":null,"type":"basic","category":"589c3e328912591b00fd9506","createdAt":"2017-02-09T11:46:16.178Z","hidden":false,"link_url":"","updates":[],"body":"Status of a payment describes the final state of the payment made by the customer. The value of Status can be:\n1. `Credit` : The payment made was successful.\n2. `Failed` : The payment made was not successful.","project":"56a1c9c13845200d0066d6fe","sync_unique":"","__v":0,"excerpt":"","link_external":false,"slug":"what-are-the-values-of-status-of-a-payment","metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

What are the values of status of a payment?


Status of a payment describes the final state of the payment made by the customer. The value of Status can be: 1. `Credit` : The payment made was successful. 2. `Failed` : The payment made was not successful.
Status of a payment describes the final state of the payment made by the customer. The value of Status can be: 1. `Credit` : The payment made was successful. 2. `Failed` : The payment made was not successful.
{"_id":"589c57b28912591b00fd9547","createdAt":"2017-02-09T11:51:14.877Z","githubsync":"","order":6,"title":"What are the values of status of a payment request?","body":"Status of a payment request describes the state of a payment request. \n\n1. `Pending` : This is the default status. The email and/or sms (whichever is applicable) have not been sent out yet.\n2. `Sent` : The email and/or sms (whichever is applicable) has been sent.\n3. `Failed` : The email and/or sms (whichever is applicable) were not sent successfully.\n4. `Completed` : Payment was made by a customer.","link_url":"","project":"56a1c9c13845200d0066d6fe","slug":"what-are-the-values-of-status-of-a-payment-request","api":{"results":{"codes":[{"status":200,"language":"json","code":"{}","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","auth":"required","params":[],"url":""},"category":"589c3e328912591b00fd9506","hidden":false,"link_external":false,"parentDoc":null,"__v":0,"excerpt":"","isReference":false,"next":{"pages":[],"description":""},"sync_unique":"","type":"basic","updates":[],"user":"56a1c959842b650d0088899c","version":"571749c2d2a6510e00840a82","metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

What are the values of status of a payment request?


Status of a payment request describes the state of a payment request. 1. `Pending` : This is the default status. The email and/or sms (whichever is applicable) have not been sent out yet. 2. `Sent` : The email and/or sms (whichever is applicable) has been sent. 3. `Failed` : The email and/or sms (whichever is applicable) were not sent successfully. 4. `Completed` : Payment was made by a customer.
Status of a payment request describes the state of a payment request. 1. `Pending` : This is the default status. The email and/or sms (whichever is applicable) have not been sent out yet. 2. `Sent` : The email and/or sms (whichever is applicable) has been sent. 3. `Failed` : The email and/or sms (whichever is applicable) were not sent successfully. 4. `Completed` : Payment was made by a customer.
{"_id":"589c5a488912591b00fd954c","category":"589c3e328912591b00fd9506","link_external":false,"link_url":"","parentDoc":null,"sync_unique":"","api":{"auth":"required","params":[],"url":"","results":{"codes":[{"language":"json","code":"{}","name":"","status":200},{"status":400,"language":"json","code":"{}","name":""}]},"settings":""},"next":{"pages":[],"description":""},"user":"56a1c959842b650d0088899c","version":"571749c2d2a6510e00840a82","githubsync":"","body":"1. Specify a webhook url while [creating the payment request](doc:create-a-request).\n2. Save the payment request ID in your database when the payment request is created.\n3. On successful payment completion, a webhook is sent which includes the payment request ID and  the payment ID. You can then map the payment request ID and the payment ID in your database accordingly.","slug":"how-do-i-fetch-the-payment-request-for-a-payment","title":"How do I verify the status of a payment?","updates":[],"__v":0,"createdAt":"2017-02-09T12:02:16.677Z","excerpt":"","hidden":false,"isReference":false,"order":7,"project":"56a1c9c13845200d0066d6fe","type":"basic","metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

How do I verify the status of a payment?


1. Specify a webhook url while [creating the payment request](doc:create-a-request). 2. Save the payment request ID in your database when the payment request is created. 3. On successful payment completion, a webhook is sent which includes the payment request ID and the payment ID. You can then map the payment request ID and the payment ID in your database accordingly.
1. Specify a webhook url while [creating the payment request](doc:create-a-request). 2. Save the payment request ID in your database when the payment request is created. 3. On successful payment completion, a webhook is sent which includes the payment request ID and the payment ID. You can then map the payment request ID and the payment ID in your database accordingly.
{"_id":"589c6ad5ccb0c72500327bf0","body":"Instamojo provides you with an option to create a sandbox account to test your integration before you go live on your website or application. \n\nYou do not have to submit documents or go through the regular onboarding flow when you create an account on the sandbox environment. You can sign up on the sandbox environment here: [https://test.instamojo.com](https://test.instamojo.com)\n\nThe base URL for all your API requests to the sandbox environment should be:\n`https://test.instamojo.com/`\n\nAll the credentials like API key, Auth Token and Private Salt will be \navailable at: [https://test.instamojo.com/integrations/](https://test.instamojo.com/integrations)\n\nTo test transaction, you can use the test card details, which are:\n```\nCard Number: 4242 4242 4242 4242\nExp MM/YY: 01/20\nCVV: 111\nSecond Factor Authentication code: 1221\n```\n\nThe production environment is the live Instamojo environment where you cannot use the test card details and need to use a valid card to make a transaction. The developer credentials for this environment are will be available at [https://www.instamojo.com/integrations/](https://www.instamojo.com/integrations/)\n\nThe base URL for all your API requests to the sandbox environment should be:\n`https://www.instamojo.com/`","category":"589c3e328912591b00fd9506","hidden":false,"link_external":false,"createdAt":"2017-02-09T13:12:53.618Z","githubsync":"","parentDoc":null,"type":"basic","updates":[],"version":"571749c2d2a6510e00840a82","api":{"results":{"codes":[{"status":200,"language":"json","code":"{}","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","auth":"required","params":[],"url":""},"link_url":"","slug":"what-is-the-difference-between-the-sandbox-and-production-environment","title":"What is the difference between the sandbox and production environment?","user":"56a1c959842b650d0088899c","__v":0,"excerpt":"","isReference":false,"next":{"pages":[],"description":""},"order":8,"project":"56a1c9c13845200d0066d6fe","sync_unique":"","metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

What is the difference between the sandbox and production environment?


Instamojo provides you with an option to create a sandbox account to test your integration before you go live on your website or application. You do not have to submit documents or go through the regular onboarding flow when you create an account on the sandbox environment. You can sign up on the sandbox environment here: [https://test.instamojo.com](https://test.instamojo.com) The base URL for all your API requests to the sandbox environment should be: `https://test.instamojo.com/` All the credentials like API key, Auth Token and Private Salt will be available at: [https://test.instamojo.com/integrations/](https://test.instamojo.com/integrations) To test transaction, you can use the test card details, which are: ``` Card Number: 4242 4242 4242 4242 Exp MM/YY: 01/20 CVV: 111 Second Factor Authentication code: 1221 ``` The production environment is the live Instamojo environment where you cannot use the test card details and need to use a valid card to make a transaction. The developer credentials for this environment are will be available at [https://www.instamojo.com/integrations/](https://www.instamojo.com/integrations/) The base URL for all your API requests to the sandbox environment should be: `https://www.instamojo.com/`
Instamojo provides you with an option to create a sandbox account to test your integration before you go live on your website or application. You do not have to submit documents or go through the regular onboarding flow when you create an account on the sandbox environment. You can sign up on the sandbox environment here: [https://test.instamojo.com](https://test.instamojo.com) The base URL for all your API requests to the sandbox environment should be: `https://test.instamojo.com/` All the credentials like API key, Auth Token and Private Salt will be available at: [https://test.instamojo.com/integrations/](https://test.instamojo.com/integrations) To test transaction, you can use the test card details, which are: ``` Card Number: 4242 4242 4242 4242 Exp MM/YY: 01/20 CVV: 111 Second Factor Authentication code: 1221 ``` The production environment is the live Instamojo environment where you cannot use the test card details and need to use a valid card to make a transaction. The developer credentials for this environment are will be available at [https://www.instamojo.com/integrations/](https://www.instamojo.com/integrations/) The base URL for all your API requests to the sandbox environment should be: `https://www.instamojo.com/`
{"_id":"589c6c6eccb0c72500327bf3","version":"571749c2d2a6510e00840a82","body":"No. We do not allow API calls over AJAX because it exposes your API credentials which can be easily misused.\n\nThe recommended way is to send a request to your server with the required data and from\nthere you should make a request to our API instead with the credentials being stored on your server. Once the API returns a response, you may then forward the result to your frontend.","isReference":false,"slug":"can-i-make-api-calls-using-ajax","link_external":false,"next":{"pages":[],"description":""},"parentDoc":null,"updates":[],"user":"56a1c959842b650d0088899c","api":{"results":{"codes":[{"status":200,"language":"json","code":"{}","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","auth":"required","params":[],"url":""},"githubsync":"","project":"56a1c9c13845200d0066d6fe","title":"Can I make API calls using AJAX?","category":"589c3e328912591b00fd9506","hidden":false,"link_url":"","order":9,"sync_unique":"","type":"basic","__v":0,"createdAt":"2017-02-09T13:19:42.560Z","excerpt":"","metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

Can I make API calls using AJAX?


No. We do not allow API calls over AJAX because it exposes your API credentials which can be easily misused. The recommended way is to send a request to your server with the required data and from there you should make a request to our API instead with the credentials being stored on your server. Once the API returns a response, you may then forward the result to your frontend.
No. We do not allow API calls over AJAX because it exposes your API credentials which can be easily misused. The recommended way is to send a request to your server with the required data and from there you should make a request to our API instead with the credentials being stored on your server. Once the API returns a response, you may then forward the result to your frontend.
{"_id":"589c6e420552cc2f00a61d2f","version":"571749c2d2a6510e00840a82","excerpt":"","parentDoc":null,"slug":"can-i-issue-multiple-partial-refunds-for-a-payment","sync_unique":"","title":"Can I issue multiple partial refunds for a payment?","updates":[],"githubsync":"","link_external":false,"link_url":"","next":{"description":"","pages":[]},"project":"56a1c9c13845200d0066d6fe","__v":0,"createdAt":"2017-02-09T13:27:30.355Z","order":10,"type":"basic","user":"56a1c959842b650d0088899c","isReference":false,"api":{"results":{"codes":[{"status":200,"language":"json","code":"{}","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","auth":"required","params":[],"url":""},"body":"No. This is not supported at the moment. You can only [create one refund](doc:create-a-refund)  per payment.","category":"589c3e328912591b00fd9506","hidden":false,"metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

Can I issue multiple partial refunds for a payment?


No. This is not supported at the moment. You can only [create one refund](doc:create-a-refund) per payment.
No. This is not supported at the moment. You can only [create one refund](doc:create-a-refund) per payment.
{"_id":"589c6ea40552cc2f00a61d34","createdAt":"2017-02-09T13:29:08.507Z","link_url":"","title":"Can I add custom fields to a payment request?","sync_unique":"","type":"basic","updates":[],"category":"589c3e328912591b00fd9506","hidden":false,"parentDoc":null,"project":"56a1c9c13845200d0066d6fe","user":"56a1c959842b650d0088899c","version":"571749c2d2a6510e00840a82","__v":0,"body":"No. This is not supported yet.\n\nHowever, you can use the `purpose` field for any information upto 30 characters regarding the payment request. We recommend you store and maintain any custom fields for a payment request at your end.","order":11,"slug":"can-i-add-custom-fields-to-a-payment-request","isReference":false,"link_external":false,"next":{"pages":[],"description":""},"api":{"settings":"","auth":"required","params":[],"url":"","results":{"codes":[{"status":200,"language":"json","code":"{}","name":""},{"code":"{}","name":"","status":400,"language":"json"}]}},"excerpt":"","githubsync":"","metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

Can I add custom fields to a payment request?


No. This is not supported yet. However, you can use the `purpose` field for any information upto 30 characters regarding the payment request. We recommend you store and maintain any custom fields for a payment request at your end.
No. This is not supported yet. However, you can use the `purpose` field for any information upto 30 characters regarding the payment request. We recommend you store and maintain any custom fields for a payment request at your end.
{"_id":"589c6f3e8912591b00fd959d","parentDoc":null,"sync_unique":"","__v":0,"createdAt":"2017-02-09T13:31:42.803Z","hidden":false,"isReference":false,"link_external":false,"link_url":"","order":12,"project":"56a1c9c13845200d0066d6fe","slug":"i-get-a-failed-to-connect-to-wwwinstamojocom-port-443-connection-timed-out-error-what-is-wrong","category":"589c3e328912591b00fd9506","githubsync":"","next":{"pages":[],"description":""},"updates":[],"version":"571749c2d2a6510e00840a82","api":{"results":{"codes":[{"code":"{}","name":"","status":200,"language":"json"},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","auth":"required","params":[],"url":""},"body":"This indicates that the port 443 is blocked on your server. This port should be open for our API to work as we communicate with our servers only over HTTPS.\n\nYou would have to get in touch with your server admin and ask them to open this port.","excerpt":"","title":"I get a \"Failed to connect to www.instamojo.com port 443: Connection timed out\" error. What is wrong?","type":"basic","user":"56a1c959842b650d0088899c","metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

I get a "Failed to connect to www.instamojo.com port 443: Connection timed out" error. What is wrong?


This indicates that the port 443 is blocked on your server. This port should be open for our API to work as we communicate with our servers only over HTTPS. You would have to get in touch with your server admin and ask them to open this port.
This indicates that the port 443 is blocked on your server. This port should be open for our API to work as we communicate with our servers only over HTTPS. You would have to get in touch with your server admin and ask them to open this port.
{"_id":"593fc8e36caab2002d67a5b1","project":"56a1c9c13845200d0066d6fe","version":"571749c2d2a6510e00840a82","category":"593fc8c86f2334000f6b0193","user":"56a1c959842b650d0088899c","updates":[],"next":{"pages":[],"description":""},"createdAt":"2017-06-13T11:13:39.581Z","link_external":false,"link_url":"https://docs.instamojo.com/docs/sdk","githubsync":"","sync_unique":"","hidden":false,"api":{"results":{"codes":[{"status":200,"language":"json","code":"{}","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","auth":"required","params":[],"url":""},"isReference":false,"order":0,"body":"Read more about Javascript SDK [here](https://docs.instamojo.com/docs/sdk).","excerpt":"Render Instamojo checkout form and collect payments on your webpage with just the instamojo-payment-url.","slug":"javascript-sdk","type":"basic","title":"Javascript SDK","__v":0,"parentDoc":null,"metadata":{"title":"","description":"","image":[]},"childrenPages":[]}

Javascript SDK

Render Instamojo checkout form and collect payments on your webpage with just the instamojo-payment-url.

Read more about Javascript SDK [here](https://docs.instamojo.com/docs/sdk).
Read more about Javascript SDK [here](https://docs.instamojo.com/docs/sdk).
{"_id":"5d95e048b2c61b002ed545f8","project":"56a1c9c13845200d0066d6fe","version":"571749c2d2a6510e00840a82","category":"5d95df8df1de56004a1bc525","user":"5c768f83cc5f9f004390f962","updates":[],"next":{"pages":[],"description":""},"createdAt":"2019-10-03T11:49:28.262Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"results":{"codes":[{"status":200,"language":"json","code":"{}","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","auth":"required","params":[],"url":""},"isReference":false,"order":0,"body":"Mojo developers program (MDP) is a developer platform created by Instamojo to collaborate with application developers across the globe. At Instamojo, we aspire to solve problems faced by MSMEs in our country along with other like-minded solution providers. The application developers can build applications and publish them on the Instamojo development platform. Instamojo sellers will be able to view the application from the Instamojo app store (Android and web) and will be able to subscribe to the app.\n\nThis is a unique one of a kind opportunity for a developer/solution provider to work closely with Instamojo, get access to over 1 Million MSMEs on the platform and create a new revenue stream.","excerpt":"","slug":"mojo-developers-program","type":"basic","title":"Mojo Developers Program (MDP)","__v":0,"parentDoc":null,"childrenPages":[]}

Mojo Developers Program (MDP)


Mojo developers program (MDP) is a developer platform created by Instamojo to collaborate with application developers across the globe. At Instamojo, we aspire to solve problems faced by MSMEs in our country along with other like-minded solution providers. The application developers can build applications and publish them on the Instamojo development platform. Instamojo sellers will be able to view the application from the Instamojo app store (Android and web) and will be able to subscribe to the app. This is a unique one of a kind opportunity for a developer/solution provider to work closely with Instamojo, get access to over 1 Million MSMEs on the platform and create a new revenue stream.
Mojo developers program (MDP) is a developer platform created by Instamojo to collaborate with application developers across the globe. At Instamojo, we aspire to solve problems faced by MSMEs in our country along with other like-minded solution providers. The application developers can build applications and publish them on the Instamojo development platform. Instamojo sellers will be able to view the application from the Instamojo app store (Android and web) and will be able to subscribe to the app. This is a unique one of a kind opportunity for a developer/solution provider to work closely with Instamojo, get access to over 1 Million MSMEs on the platform and create a new revenue stream.
{"_id":"5d95e1148cee720052aeff61","project":"56a1c9c13845200d0066d6fe","version":"571749c2d2a6510e00840a82","category":"5d95df8df1de56004a1bc525","user":"5c768f83cc5f9f004390f962","updates":[],"next":{"pages":[],"description":""},"createdAt":"2019-10-03T11:52:52.970Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"results":{"codes":[{"status":200,"language":"json","code":"{}","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","auth":"required","params":[],"url":""},"isReference":false,"order":1,"body":"[block:api-header]\n{\n  \"title\": \"Application programming interfaces (APIs)\"\n}\n[/block]\nInstamojo developer platform will allow developers to access merchant's data to create a solution. Following are the basic APIs Instamojo will expose in the first version\n\n  * Merchant Profile API (Name, email, etc)\n  * Merchant Payment API (Payment date, amount, etc)\n  * Merchant Payout API (date, type, amount, etc)\n  * Online Store API (Inventory, sales, etc)\n  * Create Payment Link API (create a link on behalf of the merchant)\n  * View Payment Link API (All created payment links info - link,amount,reason)","excerpt":"","slug":"features-of-mdp","type":"basic","title":"Features of MDP","__v":0,"parentDoc":null,"childrenPages":[]}

Features of MDP


[block:api-header] { "title": "Application programming interfaces (APIs)" } [/block] Instamojo developer platform will allow developers to access merchant's data to create a solution. Following are the basic APIs Instamojo will expose in the first version * Merchant Profile API (Name, email, etc) * Merchant Payment API (Payment date, amount, etc) * Merchant Payout API (date, type, amount, etc) * Online Store API (Inventory, sales, etc) * Create Payment Link API (create a link on behalf of the merchant) * View Payment Link API (All created payment links info - link,amount,reason)
[block:api-header] { "title": "Application programming interfaces (APIs)" } [/block] Instamojo developer platform will allow developers to access merchant's data to create a solution. Following are the basic APIs Instamojo will expose in the first version * Merchant Profile API (Name, email, etc) * Merchant Payment API (Payment date, amount, etc) * Merchant Payout API (date, type, amount, etc) * Online Store API (Inventory, sales, etc) * Create Payment Link API (create a link on behalf of the merchant) * View Payment Link API (All created payment links info - link,amount,reason)
{"_id":"5d95e72813a03800132bb8a0","project":"56a1c9c13845200d0066d6fe","version":"571749c2d2a6510e00840a82","category":"5d95df8df1de56004a1bc525","user":"5ce26a9d4c3d820056874747","updates":[],"next":{"pages":[],"description":""},"createdAt":"2019-10-03T12:18:48.201Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"results":{"codes":[{"status":200,"language":"json","code":"{}","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","auth":"required","params":[],"url":""},"isReference":false,"order":2,"body":"Instamojo developer platform will enable developers to publish an application that should be hosted by the developer on their end and will have the following information points shown on the Instamojo App store \n\n  * Application Logo\n  * Application Name\n  * Application Description\n  * Application Category\n  * Application Images (Up to 5 high-quality images)\n  * Application Video (Youtube video link - How to use the App)\n  * App URL (App to be hosted by the developer and a URL needs to be provided, this URL should \n     open in an iframe on Instamojo Appstore)\n  * Redirect URI (For OAuth redirection)\n  * Data Access Permissions requirement from the merchants","excerpt":"","slug":"publish-application","type":"basic","title":"Create/Publish Application","__v":0,"parentDoc":null,"childrenPages":[]}

Create/Publish Application


Instamojo developer platform will enable developers to publish an application that should be hosted by the developer on their end and will have the following information points shown on the Instamojo App store * Application Logo * Application Name * Application Description * Application Category * Application Images (Up to 5 high-quality images) * Application Video (Youtube video link - How to use the App) * App URL (App to be hosted by the developer and a URL needs to be provided, this URL should open in an iframe on Instamojo Appstore) * Redirect URI (For OAuth redirection) * Data Access Permissions requirement from the merchants
Instamojo developer platform will enable developers to publish an application that should be hosted by the developer on their end and will have the following information points shown on the Instamojo App store * Application Logo * Application Name * Application Description * Application Category * Application Images (Up to 5 high-quality images) * Application Video (Youtube video link - How to use the App) * App URL (App to be hosted by the developer and a URL needs to be provided, this URL should open in an iframe on Instamojo Appstore) * Redirect URI (For OAuth redirection) * Data Access Permissions requirement from the merchants
{"_id":"5d95e78140afb9004c0d1434","project":"56a1c9c13845200d0066d6fe","version":"571749c2d2a6510e00840a82","category":"5d95df8df1de56004a1bc525","user":"5ce26a9d4c3d820056874747","updates":[],"next":{"pages":[],"description":""},"createdAt":"2019-10-03T12:20:17.458Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"results":{"codes":[{"status":200,"language":"json","code":"{}","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","auth":"required","params":[],"url":""},"isReference":false,"order":3,"body":"The application developers can build apps where the Instamojo merchant will be able to make payment for the services they provide. The application developer should use the Instamojo payment gateway to accept payments. Instamojo will credit the amount to the application developer bank account in 3 days from the day the merchant pays for the service.","excerpt":"","slug":"in-app-purchases","type":"basic","title":"In-App Purchases","__v":0,"parentDoc":null,"childrenPages":[]}

In-App Purchases


The application developers can build apps where the Instamojo merchant will be able to make payment for the services they provide. The application developer should use the Instamojo payment gateway to accept payments. Instamojo will credit the amount to the application developer bank account in 3 days from the day the merchant pays for the service.
The application developers can build apps where the Instamojo merchant will be able to make payment for the services they provide. The application developer should use the Instamojo payment gateway to accept payments. Instamojo will credit the amount to the application developer bank account in 3 days from the day the merchant pays for the service.
{"_id":"5d95e7c078fe4e004b2d2410","project":"56a1c9c13845200d0066d6fe","version":"571749c2d2a6510e00840a82","category":"5d95df8df1de56004a1bc525","user":"5ce26a9d4c3d820056874747","updates":[],"next":{"pages":[],"description":""},"createdAt":"2019-10-03T12:21:20.812Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"results":{"codes":[{"status":200,"language":"json","code":"{}","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","auth":"required","params":[],"url":""},"isReference":false,"order":4,"body":"Merchants can view all the App details (Name, description, etc) when they click on the App in the Instamojo App store. Once they subscribe to the App, the App opens on the Instamojo platform and merchants can access all the App features. \n\nThe merchant needs to be validated by Instamojo before they can get access to all the App features in case they open the App URL directly on the developer's App/website. Once the merchant is authenticated by Instamojo and authorizes the data access, the developer can access merchant data from Instamojo on their website/App.\n\nDetailed view of Merchant/Developer Experience \n[block:embed]\n{\n  \"html\": \"<iframe class=\\\"embedly-embed\\\" src=\\\"//cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fdocs.google.com%2Fpresentation%2Fembed%3Fid%3D1-E_BWGOERbjLTnR9fnp_bzQmuY9D9FJDqud0--PWR7A%26size%3Dl&url=https%3A%2F%2Fdocs.google.com%2Fpresentation%2Fd%2F1-E_BWGOERbjLTnR9fnp_bzQmuY9D9FJDqud0--PWR7A%2Fedit%3Fusp%3Dsharing&image=https%3A%2F%2Flh6.googleusercontent.com%2F5TeXkHH2M4z0JmmkHnZir_w1AJGPUagdupI0feDCLZNbMlhza6EbUBREQQJSaUhReygwQQ%3Dw1200-h630-p&key=f2aa6fc3595946d0afc3d76cbbd25dc3&type=text%2Fhtml&schema=google\\\" width=\\\"700\\\" height=\\\"559\\\" scrolling=\\\"no\\\" frameborder=\\\"0\\\" allow=\\\"autoplay; fullscreen\\\" allowfullscreen=\\\"true\\\"></iframe>\",\n  \"url\": \"https://docs.google.com/presentation/d/1-E_BWGOERbjLTnR9fnp_bzQmuY9D9FJDqud0--PWR7A/edit?usp=sharing\",\n  \"title\": \"Merchant/Developer Experience\",\n  \"favicon\": \"https://ssl.gstatic.com/docs/presentations/images/favicon5.ico\",\n  \"image\": \"https://lh6.googleusercontent.com/5TeXkHH2M4z0JmmkHnZir_w1AJGPUagdupI0feDCLZNbMlhza6EbUBREQQJSaUhReygwQQ=w1200-h630-p\"\n}\n[/block]","excerpt":"","slug":"merchant-experience","type":"basic","title":"Merchant Experience","__v":0,"parentDoc":null,"childrenPages":[]}

Merchant Experience


Merchants can view all the App details (Name, description, etc) when they click on the App in the Instamojo App store. Once they subscribe to the App, the App opens on the Instamojo platform and merchants can access all the App features. The merchant needs to be validated by Instamojo before they can get access to all the App features in case they open the App URL directly on the developer's App/website. Once the merchant is authenticated by Instamojo and authorizes the data access, the developer can access merchant data from Instamojo on their website/App. Detailed view of Merchant/Developer Experience [block:embed] { "html": "<iframe class=\"embedly-embed\" src=\"//cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fdocs.google.com%2Fpresentation%2Fembed%3Fid%3D1-E_BWGOERbjLTnR9fnp_bzQmuY9D9FJDqud0--PWR7A%26size%3Dl&url=https%3A%2F%2Fdocs.google.com%2Fpresentation%2Fd%2F1-E_BWGOERbjLTnR9fnp_bzQmuY9D9FJDqud0--PWR7A%2Fedit%3Fusp%3Dsharing&image=https%3A%2F%2Flh6.googleusercontent.com%2F5TeXkHH2M4z0JmmkHnZir_w1AJGPUagdupI0feDCLZNbMlhza6EbUBREQQJSaUhReygwQQ%3Dw1200-h630-p&key=f2aa6fc3595946d0afc3d76cbbd25dc3&type=text%2Fhtml&schema=google\" width=\"700\" height=\"559\" scrolling=\"no\" frameborder=\"0\" allow=\"autoplay; fullscreen\" allowfullscreen=\"true\"></iframe>", "url": "https://docs.google.com/presentation/d/1-E_BWGOERbjLTnR9fnp_bzQmuY9D9FJDqud0--PWR7A/edit?usp=sharing", "title": "Merchant/Developer Experience", "favicon": "https://ssl.gstatic.com/docs/presentations/images/favicon5.ico", "image": "https://lh6.googleusercontent.com/5TeXkHH2M4z0JmmkHnZir_w1AJGPUagdupI0feDCLZNbMlhza6EbUBREQQJSaUhReygwQQ=w1200-h630-p" } [/block]
Merchants can view all the App details (Name, description, etc) when they click on the App in the Instamojo App store. Once they subscribe to the App, the App opens on the Instamojo platform and merchants can access all the App features. The merchant needs to be validated by Instamojo before they can get access to all the App features in case they open the App URL directly on the developer's App/website. Once the merchant is authenticated by Instamojo and authorizes the data access, the developer can access merchant data from Instamojo on their website/App. Detailed view of Merchant/Developer Experience [block:embed] { "html": "<iframe class=\"embedly-embed\" src=\"//cdn.embedly.com/widgets/media.html?src=https%3A%2F%2Fdocs.google.com%2Fpresentation%2Fembed%3Fid%3D1-E_BWGOERbjLTnR9fnp_bzQmuY9D9FJDqud0--PWR7A%26size%3Dl&url=https%3A%2F%2Fdocs.google.com%2Fpresentation%2Fd%2F1-E_BWGOERbjLTnR9fnp_bzQmuY9D9FJDqud0--PWR7A%2Fedit%3Fusp%3Dsharing&image=https%3A%2F%2Flh6.googleusercontent.com%2F5TeXkHH2M4z0JmmkHnZir_w1AJGPUagdupI0feDCLZNbMlhza6EbUBREQQJSaUhReygwQQ%3Dw1200-h630-p&key=f2aa6fc3595946d0afc3d76cbbd25dc3&type=text%2Fhtml&schema=google\" width=\"700\" height=\"559\" scrolling=\"no\" frameborder=\"0\" allow=\"autoplay; fullscreen\" allowfullscreen=\"true\"></iframe>", "url": "https://docs.google.com/presentation/d/1-E_BWGOERbjLTnR9fnp_bzQmuY9D9FJDqud0--PWR7A/edit?usp=sharing", "title": "Merchant/Developer Experience", "favicon": "https://ssl.gstatic.com/docs/presentations/images/favicon5.ico", "image": "https://lh6.googleusercontent.com/5TeXkHH2M4z0JmmkHnZir_w1AJGPUagdupI0feDCLZNbMlhza6EbUBREQQJSaUhReygwQQ=w1200-h630-p" } [/block]
{"_id":"5d95ea1528430e006cc30d8a","project":"56a1c9c13845200d0066d6fe","version":"571749c2d2a6510e00840a82","category":"5d95df8df1de56004a1bc525","user":"5ce26a9d4c3d820056874747","updates":[],"next":{"pages":[],"description":""},"createdAt":"2019-10-03T12:31:17.663Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"results":{"codes":[{"status":200,"language":"json","code":"{}","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","auth":"required","params":[],"url":""},"isReference":false,"order":5,"body":"Please note :\n  *  The base API endpoint for sandbox environment is https://test.instamojo.com/ (for OAuth and \n      APIs) - As of now we have kept all the URLs in this document as the production URLs\n  *  The developer signIn/dashboard URL for the test is developers-test.instamojo.com and for \n     production is developers.instamojo.com\n  *  The base API endpoint for the production environment is https://api.instamojo.com/ \n  *  Base OAuth endpoint for the production environment is https://www.instamojo.com/ \n\nIt’s recommended to test your integration in our sandbox environment. \n\nSteps to set up the environment (This needs to be done on the test before  with the URL as https://developers-test.instamojo.com)\n\n  * Sign up on https://developers.instamojo.com/\n  * Post sign up, go to the URL( https://developers.instamojo.com/)\n  * Click on the “Add New App” CTA\n  * Add all the required App details and click on “submit”\n  * Once the App is successfully submitted, you can view the App on the dashboard \n     (https://developers.instamojo.com/dashboard/)\n  * Click on the App to view the App details, on the App details page click on the three dots in the \n     right-hand side to view the options \n  * Among the options click on “View Credentials” to view the Client ID and Client Secret \n     (Example is shown below)\n  *  Save the Client ID and Client Secret with you as we will require these for the next steps.\n  \n[block:image]\n{\n  \"images\": [\n    {\n      \"image\": [\n        \"https://files.readme.io/ed1dc77-Screenshot_2019-10-03_17.54.02.png\",\n        \"Screenshot 2019-10-03 17.54.02.png\",\n        688,\n        576,\n        \"#43445a\"\n      ]\n    }\n  ]\n}\n[/block]","excerpt":"","slug":"setup","type":"basic","title":"SETUP","__v":0,"parentDoc":null,"childrenPages":[]}

SETUP


Please note : * The base API endpoint for sandbox environment is https://test.instamojo.com/ (for OAuth and APIs) - As of now we have kept all the URLs in this document as the production URLs * The developer signIn/dashboard URL for the test is developers-test.instamojo.com and for production is developers.instamojo.com * The base API endpoint for the production environment is https://api.instamojo.com/ * Base OAuth endpoint for the production environment is https://www.instamojo.com/ It’s recommended to test your integration in our sandbox environment. Steps to set up the environment (This needs to be done on the test before with the URL as https://developers-test.instamojo.com) * Sign up on https://developers.instamojo.com/ * Post sign up, go to the URL( https://developers.instamojo.com/) * Click on the “Add New App” CTA * Add all the required App details and click on “submit” * Once the App is successfully submitted, you can view the App on the dashboard (https://developers.instamojo.com/dashboard/) * Click on the App to view the App details, on the App details page click on the three dots in the right-hand side to view the options * Among the options click on “View Credentials” to view the Client ID and Client Secret (Example is shown below) * Save the Client ID and Client Secret with you as we will require these for the next steps. [block:image] { "images": [ { "image": [ "https://files.readme.io/ed1dc77-Screenshot_2019-10-03_17.54.02.png", "Screenshot 2019-10-03 17.54.02.png", 688, 576, "#43445a" ] } ] } [/block]
Please note : * The base API endpoint for sandbox environment is https://test.instamojo.com/ (for OAuth and APIs) - As of now we have kept all the URLs in this document as the production URLs * The developer signIn/dashboard URL for the test is developers-test.instamojo.com and for production is developers.instamojo.com * The base API endpoint for the production environment is https://api.instamojo.com/ * Base OAuth endpoint for the production environment is https://www.instamojo.com/ It’s recommended to test your integration in our sandbox environment. Steps to set up the environment (This needs to be done on the test before with the URL as https://developers-test.instamojo.com) * Sign up on https://developers.instamojo.com/ * Post sign up, go to the URL( https://developers.instamojo.com/) * Click on the “Add New App” CTA * Add all the required App details and click on “submit” * Once the App is successfully submitted, you can view the App on the dashboard (https://developers.instamojo.com/dashboard/) * Click on the App to view the App details, on the App details page click on the three dots in the right-hand side to view the options * Among the options click on “View Credentials” to view the Client ID and Client Secret (Example is shown below) * Save the Client ID and Client Secret with you as we will require these for the next steps. [block:image] { "images": [ { "image": [ "https://files.readme.io/ed1dc77-Screenshot_2019-10-03_17.54.02.png", "Screenshot 2019-10-03 17.54.02.png", 688, 576, "#43445a" ] } ] } [/block]
{"_id":"5d95f13ba6b678006244cb24","project":"56a1c9c13845200d0066d6fe","version":"571749c2d2a6510e00840a82","category":"5d95df8df1de56004a1bc525","user":"5ce26a9d4c3d820056874747","updates":[],"next":{"pages":[],"description":""},"createdAt":"2019-10-03T13:01:47.323Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"results":{"codes":[{"status":200,"language":"json","code":"{}","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"","auth":"required","params":[],"url":""},"isReference":false,"order":6,"body":"All API interactions require you to have authentication credentials. Use the client_id and client_secret obtained while creating an app to authenticate yourself against the API. We provide an access_token/refresh_token Oauth2 authentication.\n\nThe application can ask the following 8 scopes explicitly:\n\n  * user-info:read\n  * user-contact:read  \n  * products: read\n  * payments: read\n  * payouts: read\n  * orders: read\n  * links: write\n  * links: read\n  \n**  Steps to generate an access token for the app user\n**\n\n The oauth2 flow will work as described below  \n\nWe have taken some example values for all the data points like Client ID, Client Secret, Redirect URI and State. Please use the actual values.\n\n  * From the Frontend Make GET request on /oauth2/authorize\n\nExamples :\n\nSample Request 1 (one scope - payments:read):\n\nhttps://www.instamojo.com/oauth2/authorize?scope=payments:read &redirect_uri=https://app.example.com/oauth2/callback \n&response_type=code&client_id=812741506391&state=af0ifjsldkj\n\nSample Request 2\n(multiple scopes - all (space delimited)):\n\nhttps://www.instamojo.com/oauth2/authorize?scope=payments:read payouts:read orders:read user-info:read user-contact:read &redirect_uri=https://app.example.com/oauth2/callback \n&response_type=code&client_id=812741506391&state=af0ifjsldkj\n\n  * Above we have shown a couple of sample GET requests, with one and multiple scopes (In case of multiple scopes, scopes need to be separated by a space)\n  * The redirect_uri is the URL of the client application that the authorization grant should be returned to. \n  * The value of redirect_uri should match the value from the App registration process (at Instamojo). We need to make sure that the authorization is not being bounced back to a foreign application.\n  * Client ID can be accessed as shown in 7th step of the Setup process (Page 6)\n  * State is a security flag, similar to CSRF\n\n2. If the above request is valid then the user is redirected to an authorize page, shown below\n[block:image]\n{\n  \"images\": [\n    {\n      \"image\": [\n        \"https://files.readme.io/a6512be-Screenshot_2019-10-03_18.18.04.png\",\n        \"Screenshot 2019-10-03 18.18.04.png\",\n        1016,\n        660,\n        \"#e4e4e5\"\n      ]\n    }\n  ]\n}\n[/block]\nIf the user authorizes the app, the user is redirected to the application.\nResponse:\n\nHTTP/1.1 302 Found\nLocation: https://app.example.com/oauth2/callback?\ncode=MsCeLvIaQm6bTrgtp7&state=af0ifjsldkj\n\nThe code returned is the authorization grant and state is to ensure it's not forged and it's from the same request. The authorization code is valid for 60 seconds.\n[block:image]\n{\n  \"images\": [\n    {\n      \"image\": [\n        \"https://files.readme.io/78f9702-Screenshot_2019-10-03_18.24.48.png\",\n        \"Screenshot 2019-10-03 18.24.48.png\",\n        1134,\n        590,\n        \"#c5d3d7\"\n      ]\n    }\n  ]\n}\n[/block]\n  * After the Frontend process is done, a Backend flow needs to be triggered, exchanging the authorization code for an access token. The Developers (clients) application sends an access token request to the token endpoint on the Authorization Server with the client id and client secret. This process exchanges an Authorization Code for an Access Token and (optionally) a Refresh Token. The client can now access a protected resource with an Access Token.\n\nBelow is how this looks in raw HTTP (example).\n\nRequest:\nPOST /oauth2/token/ HTTP/1.1\nHost: www.instamojo.com\nContent-Type: application/x-www-form-urlencoded\ncode=MsCeLvIaQm6bTrgtp7&client_id=812741506391&client_secret={client_secret} &redirect_uri=https://app.example.com/oauth2/callback&grant_type=authorization_code\n\nThe grant_type is the extensibility part of OAuth. It's an authorization code from a precomputed perspective. \n\nResponse:\n{\n  \"access_token\": \"2YotnFZFEjr1zCsicMWpAA\",\n  \"token_type\": \"Bearer\",\n  \"expires_in\": 36000,\n  \"refresh_token\": \"tGzv3JOkF0XG5Qx2TlKWIA\"\n}\n\nAccess Token is valid for 36000 sec i.e. 10 hours. The application needs to store access token and refresh token, also expire time for an access token which is creation time + 36000 sec.\n\n  * Once the application has an access token, applications need to use the access token in an Authentication header (using the token_type as a prefix) to make protected resource requests.\n  \n  curl -H \"Authorization: Bearer 2YotnFZFEjr1zCsicMWpAA\" \\\n  https://api.instamojo.com/v2/user-info/\n\n**Note: Access token will get expired after 10 hours from the date of creation. The application should track for the expired access token and generate new access token by exchanging refresh token**\n\nTo exchange the Refresh Token you received during authorization for a new Access Token, make a POST request to the /OAuth/token endpoint in the Authentication API, using grant_type=refresh_token.\n\ncurl --request POST \\\n  --url 'https://www.instamojo.com/oauth2/token' \\\n  --header 'content-type: application/x-www-form-urlencoded' \\\n  --data grant_type=refresh_token \\\n  --data 'client_id=YOUR_CLIENT_ID' \\\n  --data client_secret=YOUR_CLIENT_SECRET \\\n  --data refresh_token=YOUR_REFRESH_TOKEN\n\n \n**Skip authorization form\n**\n\nDepending on the OAuth2 flow in use and the access token policy, users might be prompted for the same authorization multiple times, sometimes this is acceptable or even desirable but in some use cases, it isn’t. To control that behaviour you can use the approval_prompt parameter when hitting the authorization (/authorize) endpoint. Possible values are:\n\n  * force - users are always prompted for authorization.\n  * auto - users are prompted only for the first time, subsequent authorizations for the same application and scopes will be automatically accepted.\n  \nAccess token or Refresh token revocation\n\nTo revoke the access token or refresh token for the application user, please use the below post request\n\nPOST /o/revoke_token/ HTTP/1.1\nContent-Type: application/x-www-form-urlencoded\ntoken=XXXX&client_id=XXXX&client_secret=XXXX","excerpt":"","slug":"authentication-flow","type":"basic","title":"Authentication Flow","__v":0,"parentDoc":null,"childrenPages":[]}

Authentication Flow


All API interactions require you to have authentication credentials. Use the client_id and client_secret obtained while creating an app to authenticate yourself against the API. We provide an access_token/refresh_token Oauth2 authentication. The application can ask the following 8 scopes explicitly: * user-info:read * user-contact:read * products: read * payments: read * payouts: read * orders: read * links: write * links: read ** Steps to generate an access token for the app user ** The oauth2 flow will work as described below We have taken some example values for all the data points like Client ID, Client Secret, Redirect URI and State. Please use the actual values. * From the Frontend Make GET request on /oauth2/authorize Examples : Sample Request 1 (one scope - payments:read): https://www.instamojo.com/oauth2/authorize?scope=payments:read &redirect_uri=https://app.example.com/oauth2/callback &response_type=code&client_id=812741506391&state=af0ifjsldkj Sample Request 2 (multiple scopes - all (space delimited)): https://www.instamojo.com/oauth2/authorize?scope=payments:read payouts:read orders:read user-info:read user-contact:read &redirect_uri=https://app.example.com/oauth2/callback &response_type=code&client_id=812741506391&state=af0ifjsldkj * Above we have shown a couple of sample GET requests, with one and multiple scopes (In case of multiple scopes, scopes need to be separated by a space) * The redirect_uri is the URL of the client application that the authorization grant should be returned to. * The value of redirect_uri should match the value from the App registration process (at Instamojo). We need to make sure that the authorization is not being bounced back to a foreign application. * Client ID can be accessed as shown in 7th step of the Setup process (Page 6) * State is a security flag, similar to CSRF 2. If the above request is valid then the user is redirected to an authorize page, shown below [block:image] { "images": [ { "image": [ "https://files.readme.io/a6512be-Screenshot_2019-10-03_18.18.04.png", "Screenshot 2019-10-03 18.18.04.png", 1016, 660, "#e4e4e5" ] } ] } [/block] If the user authorizes the app, the user is redirected to the application. Response: HTTP/1.1 302 Found Location: https://app.example.com/oauth2/callback? code=MsCeLvIaQm6bTrgtp7&state=af0ifjsldkj The code returned is the authorization grant and state is to ensure it's not forged and it's from the same request. The authorization code is valid for 60 seconds. [block:image] { "images": [ { "image": [ "https://files.readme.io/78f9702-Screenshot_2019-10-03_18.24.48.png", "Screenshot 2019-10-03 18.24.48.png", 1134, 590, "#c5d3d7" ] } ] } [/block] * After the Frontend process is done, a Backend flow needs to be triggered, exchanging the authorization code for an access token. The Developers (clients) application sends an access token request to the token endpoint on the Authorization Server with the client id and client secret. This process exchanges an Authorization Code for an Access Token and (optionally) a Refresh Token. The client can now access a protected resource with an Access Token. Below is how this looks in raw HTTP (example). Request: POST /oauth2/token/ HTTP/1.1 Host: www.instamojo.com Content-Type: application/x-www-form-urlencoded code=MsCeLvIaQm6bTrgtp7&client_id=812741506391&client_secret={client_secret} &redirect_uri=https://app.example.com/oauth2/callback&grant_type=authorization_code The grant_type is the extensibility part of OAuth. It's an authorization code from a precomputed perspective. Response: { "access_token": "2YotnFZFEjr1zCsicMWpAA", "token_type": "Bearer", "expires_in": 36000, "refresh_token": "tGzv3JOkF0XG5Qx2TlKWIA" } Access Token is valid for 36000 sec i.e. 10 hours. The application needs to store access token and refresh token, also expire time for an access token which is creation time + 36000 sec. * Once the application has an access token, applications need to use the access token in an Authentication header (using the token_type as a prefix) to make protected resource requests. curl -H "Authorization: Bearer 2YotnFZFEjr1zCsicMWpAA" \ https://api.instamojo.com/v2/user-info/ **Note: Access token will get expired after 10 hours from the date of creation. The application should track for the expired access token and generate new access token by exchanging refresh token** To exchange the Refresh Token you received during authorization for a new Access Token, make a POST request to the /OAuth/token endpoint in the Authentication API, using grant_type=refresh_token. curl --request POST \ --url 'https://www.instamojo.com/oauth2/token' \ --header 'content-type: application/x-www-form-urlencoded' \ --data grant_type=refresh_token \ --data 'client_id=YOUR_CLIENT_ID' \ --data client_secret=YOUR_CLIENT_SECRET \ --data refresh_token=YOUR_REFRESH_TOKEN **Skip authorization form ** Depending on the OAuth2 flow in use and the access token policy, users might be prompted for the same authorization multiple times, sometimes this is acceptable or even desirable but in some use cases, it isn’t. To control that behaviour you can use the approval_prompt parameter when hitting the authorization (/authorize) endpoint. Possible values are: * force - users are always prompted for authorization. * auto - users are prompted only for the first time, subsequent authorizations for the same application and scopes will be automatically accepted. Access token or Refresh token revocation To revoke the access token or refresh token for the application user, please use the below post request POST /o/revoke_token/ HTTP/1.1 Content-Type: application/x-www-form-urlencoded token=XXXX&client_id=XXXX&client_secret=XXXX
All API interactions require you to have authentication credentials. Use the client_id and client_secret obtained while creating an app to authenticate yourself against the API. We provide an access_token/refresh_token Oauth2 authentication. The application can ask the following 8 scopes explicitly: * user-info:read * user-contact:read * products: read * payments: read * payouts: read * orders: read * links: write * links: read ** Steps to generate an access token for the app user ** The oauth2 flow will work as described below We have taken some example values for all the data points like Client ID, Client Secret, Redirect URI and State. Please use the actual values. * From the Frontend Make GET request on /oauth2/authorize Examples : Sample Request 1 (one scope - payments:read): https://www.instamojo.com/oauth2/authorize?scope=payments:read &redirect_uri=https://app.example.com/oauth2/callback &response_type=code&client_id=812741506391&state=af0ifjsldkj Sample Request 2 (multiple scopes - all (space delimited)): https://www.instamojo.com/oauth2/authorize?scope=payments:read payouts:read orders:read user-info:read user-contact:read &redirect_uri=https://app.example.com/oauth2/callback &response_type=code&client_id=812741506391&state=af0ifjsldkj * Above we have shown a couple of sample GET requests, with one and multiple scopes (In case of multiple scopes, scopes need to be separated by a space) * The redirect_uri is the URL of the client application that the authorization grant should be returned to. * The value of redirect_uri should match the value from the App registration process (at Instamojo). We need to make sure that the authorization is not being bounced back to a foreign application. * Client ID can be accessed as shown in 7th step of the Setup process (Page 6) * State is a security flag, similar to CSRF 2. If the above request is valid then the user is redirected to an authorize page, shown below [block:image] { "images": [ { "image": [ "https://files.readme.io/a6512be-Screenshot_2019-10-03_18.18.04.png", "Screenshot 2019-10-03 18.18.04.png", 1016, 660, "#e4e4e5" ] } ] } [/block] If the user authorizes the app, the user is redirected to the application. Response: HTTP/1.1 302 Found Location: https://app.example.com/oauth2/callback? code=MsCeLvIaQm6bTrgtp7&state=af0ifjsldkj The code returned is the authorization grant and state is to ensure it's not forged and it's from the same request. The authorization code is valid for 60 seconds. [block:image] { "images": [ { "image": [ "https://files.readme.io/78f9702-Screenshot_2019-10-03_18.24.48.png", "Screenshot 2019-10-03 18.24.48.png", 1134, 590, "#c5d3d7" ] } ] } [/block] * After the Frontend process is done, a Backend flow needs to be triggered, exchanging the authorization code for an access token. The Developers (clients) application sends an access token request to the token endpoint on the Authorization Server with the client id and client secret. This process exchanges an Authorization Code for an Access Token and (optionally) a Refresh Token. The client can now access a protected resource with an Access Token. Below is how this looks in raw HTTP (example). Request: POST /oauth2/token/ HTTP/1.1 Host: www.instamojo.com Content-Type: application/x-www-form-urlencoded code=MsCeLvIaQm6bTrgtp7&client_id=812741506391&client_secret={client_secret} &redirect_uri=https://app.example.com/oauth2/callback&grant_type=authorization_code The grant_type is the extensibility part of OAuth. It's an authorization code from a precomputed perspective. Response: { "access_token": "2YotnFZFEjr1zCsicMWpAA", "token_type": "Bearer", "expires_in": 36000, "refresh_token": "tGzv3JOkF0XG5Qx2TlKWIA" } Access Token is valid for 36000 sec i.e. 10 hours. The application needs to store access token and refresh token, also expire time for an access token which is creation time + 36000 sec. * Once the application has an access token, applications need to use the access token in an Authentication header (using the token_type as a prefix) to make protected resource requests. curl -H "Authorization: Bearer 2YotnFZFEjr1zCsicMWpAA" \ https://api.instamojo.com/v2/user-info/ **Note: Access token will get expired after 10 hours from the date of creation. The application should track for the expired access token and generate new access token by exchanging refresh token** To exchange the Refresh Token you received during authorization for a new Access Token, make a POST request to the /OAuth/token endpoint in the Authentication API, using grant_type=refresh_token. curl --request POST \ --url 'https://www.instamojo.com/oauth2/token' \ --header 'content-type: application/x-www-form-urlencoded' \ --data grant_type=refresh_token \ --data 'client_id=YOUR_CLIENT_ID' \ --data client_secret=YOUR_CLIENT_SECRET \ --data refresh_token=YOUR_REFRESH_TOKEN **Skip authorization form ** Depending on the OAuth2 flow in use and the access token policy, users might be prompted for the same authorization multiple times, sometimes this is acceptable or even desirable but in some use cases, it isn’t. To control that behaviour you can use the approval_prompt parameter when hitting the authorization (/authorize) endpoint. Possible values are: * force - users are always prompted for authorization. * auto - users are prompted only for the first time, subsequent authorizations for the same application and scopes will be automatically accepted. Access token or Refresh token revocation To revoke the access token or refresh token for the application user, please use the below post request POST /o/revoke_token/ HTTP/1.1 Content-Type: application/x-www-form-urlencoded token=XXXX&client_id=XXXX&client_secret=XXXX
{"_id":"5d95e4808940d80133243fda","project":"56a1c9c13845200d0066d6fe","version":"571749c2d2a6510e00840a82","category":"5d95df8df1de56004a1bc525","user":"5ce26a9d4c3d820056874747","updates":[],"next":{"pages":[],"description":""},"createdAt":"2019-10-03T12:07:28.791Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"method":"get","examples":{"codes":[]},"results":{"codes":[{"status":200,"language":"json","code":"[\n    {\n        \"full_name\": \"Gavin Belson\",\n        \"signup_date\": \"2019-06-03\",\n        \"username\": \"gavinbelson17\",\n        \"city\": null,\n        \"website\": \"https://www.hooli.com\"\n    }\n]","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"5729f56e7f34182900ce9d55","auth":"required","params":[{"_id":"5d95e4808940d80133243fdb","ref":"","in":"header","required":false,"desc":"","default":"Bearer <token>","type":"string","name":"Authorization"}],"url":"/v2/user-info"},"isReference":false,"order":7,"body":"","excerpt":"","slug":"user-info","type":"get","title":"User-info","__v":2,"parentDoc":null,"childrenPages":[]}

getUser-info


Headers

Authorization:
stringBearer <token>

User Information

Try It Out

get
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Result Format



{"_id":"5d95f40a3d45d5001c7f3225","project":"56a1c9c13845200d0066d6fe","version":"571749c2d2a6510e00840a82","category":"5d95df8df1de56004a1bc525","user":"5ce26a9d4c3d820056874747","updates":[],"next":{"pages":[],"description":""},"createdAt":"2019-10-03T13:13:46.698Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"method":"get","examples":{"codes":[]},"results":{"codes":[{"status":200,"language":"json","code":"[\n    {\n        \"full_name\": \"Gavin Belson\",\n        \"email\": \"gavinb@gmail.com\",\n        \"phone\": \"+919876543212\",\n        “username”: “gavin17”,\n        “account_id”: “0f9c251fc4d04765a1ccd246bf81b23b”,\n    }\n]\n","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"5729f56e7f34182900ce9d55","auth":"required","params":[{"_id":"5d95f40a3d45d5001c7f3226","ref":"","in":"header","required":false,"desc":"","default":"Bearer <your-token>","type":"string","name":"Authorization"}],"url":"/v2/user-contact"},"isReference":false,"order":999,"body":"","excerpt":"","slug":"user-contact","type":"get","title":"User-contact","__v":5,"childrenPages":[]}

getUser-contact


Headers

Authorization:
stringBearer <your-token>

User Information

Try It Out

get
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Result Format



{"_id":"5d96d1225d2d2a0073555aa6","project":"56a1c9c13845200d0066d6fe","version":"571749c2d2a6510e00840a82","category":"5d95df8df1de56004a1bc525","user":"5ce26a9d4c3d820056874747","updates":[],"next":{"pages":[],"description":""},"createdAt":"2019-10-04T04:57:06.777Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"method":"get","examples":{"codes":[]},"results":{"codes":[{"status":200,"language":"json","code":"{\n    \"count\": 192,\n    \"next\": \"https://test.instamojo.com/v2/payments/?page=2\",\n    \"previous\": null,\n    \"payments\": \n    [\n        {\n            \"id\": \"MOJO9520R12A973123120\",\n            \"title\": \"test payment\",\n          \t“payment_type”: \"instapay\",\n            \"status\": true,\n            \"link\":\"https://test.instamojo.com/v2/links/<value>/\",\n            \"product\": null,\n            \"seller\": \"https://test.instamojo.com/v2/users/<value>/\",\n            \"currency\": \"INR\",\n            \"amount\": \"9494.00\",\n            \"name\": \"buyer\",\n            \"email\": \"buyer@email.com\",\n            \"phone\": \"+919876543210\",\n            \"payout\": null,\n            \"fees\": \"192.88\",\n            \"total_taxes\": \"34.72\",\n            \"cases\": [],\n            \"instrument_type\": \"CARD\",\n            \"billing_instrument\": \"International Regular Credit Card (Visa/Mastercard)\",\n            \"failure\": null,\n            \"created_at\": \"2019-05-20T09:30:23.808234Z\",\n            \"updated_at\": \"2019-05-24T07:45:04.639332Z\",\n            \"tax_invoice_id\": \"0355221229/000006\",\n            \"resource_uri\": \"https://test.instamojo.com/v2/payments/<value>/\"\n        },\n    ]\n}\n","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"5729f56e7f34182900ce9d55","auth":"required","params":[{"_id":"5d96d1225d2d2a0073555aaa","ref":"","in":"header","required":false,"desc":"","default":"Bearer <your-token>","type":"string","name":"Authorization"},{"_id":"5d96d1225d2d2a0073555aa9","ref":"","in":"query","required":false,"desc":"","default":"MOJO9618N05A3131214","type":"string","name":"id"},{"_id":"5d96d1225d2d2a0073555aa8","ref":"","in":"query","required":false,"desc":"username or account id","default":"username","type":"string","name":"buyer"},{"_id":"5d96d61f5dff49005091607c","ref":"","in":"query","required":false,"desc":"username or account id","default":"username","type":"string","name":"seller"},{"_id":"5d96d61f5dff49005091607b","ref":"","in":"query","required":false,"desc":"payout id","default":"MOJO9423001M54251388","type":"string","name":"payout"},{"_id":"5d96d61f5dff49005091607a","ref":"","in":"query","required":false,"desc":"product slug","default":"product_slug","type":"string","name":"product"},{"_id":"5d96d61f5dff490050916079","ref":"","in":"query","required":false,"desc":"","default":"2019-06-18T08:54:39.1127","type":"datetime","name":"min_created_at"},{"_id":"5d96d61f5dff490050916078","ref":"","in":"query","required":false,"desc":"","default":"2019-06-18T08:54:39.1127","type":"datetime","name":"max_created_at"},{"_id":"5d96d61f5dff490050916077","ref":"","in":"query","required":false,"desc":"","default":"2019-06-18T08:54:39.1127","type":"datetime","name":"min_updated_at"},{"_id":"5d96d61f5dff490050916076","ref":"","in":"query","required":false,"desc":"","default":"2019-06-18T08:54:39.1127","type":"datetime","name":"max_updated_at"},{"_id":"5d96d61f5dff490050916075","ref":"","in":"query","required":false,"desc":"","default":"f0a3effe-21c1-450c-8bbb-a0066b09","type":"string","name":"order_id"}],"url":"/v2/payments"},"isReference":false,"order":999,"body":"","excerpt":"","slug":"payments","type":"get","title":"Payments","__v":5,"childrenPages":[]}

getPayments


Query Params

id:
stringMOJO9618N05A3131214
buyer:
stringusername
username or account id
seller:
stringusername
username or account id
payout:
stringMOJO9423001M54251388
payout id
product:
stringproduct_slug
product slug
min_created_at:
datetime2019-06-18T08:54:39.1127
max_created_at:
datetime2019-06-18T08:54:39.1127
min_updated_at:
datetime2019-06-18T08:54:39.1127
max_updated_at:
datetime2019-06-18T08:54:39.1127
order_id:
stringf0a3effe-21c1-450c-8bbb-a0066b09

Headers

Authorization:
stringBearer <your-token>

User Information

Try It Out

get
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Result Format



{"_id":"5d96d9099b619e00112d16a7","project":"56a1c9c13845200d0066d6fe","version":"571749c2d2a6510e00840a82","category":"5d95df8df1de56004a1bc525","user":"5ce26a9d4c3d820056874747","updates":[],"next":{"pages":[],"description":""},"createdAt":"2019-10-04T05:30:49.083Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"method":"get","examples":{"codes":[]},"results":{"codes":[{"status":200,"language":"json","code":"{\n    \"count\": 17,\n    \"next\": null,\n    \"previous\": null,\n    \"payouts\":\n    [\n        {\n            \"id\": \"MOJO9413001M10071018\",\n            \"recipient\": \"https://test.instamojo.com/v2/users/<value>/\",\n            \"status\": true,\n            \"paid_out_at\": \"2019-04-22T12:23:19.239722Z\",\n            \"currency\": \"INR\",\n            \"paid_amount\": \"1570.75\",\n            \"sales_amount\": \"26983.21\",\n            \"fee_amount\": \"1744.92\",\n            \"total_tax_amount\": \"314.24\",\n            \"held_amount\": \"0.00\",\n            \"reversed_amount\": \"3965.00\",\n            \"refunded_amount\": \"0.00\",\n            \"affiliate_commission_amount\": \"0.00\",\n            \"partner_commission_amount\": \"0.00\",\n            \"payout_type\": 0,\n            \"resource_uri\": \"https://test.instamojo.com/v2/payouts/<value>/\",\n            \"shipping_fee\": \"23386.42\"\n        },\n    ]\n}\n","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"5729f56e7f34182900ce9d55","auth":"required","params":[{"_id":"5d96d9099b619e00112d16ab","ref":"","in":"header","required":false,"desc":"","default":"Bearer <your-token>","type":"string","name":"Authorization"},{"_id":"5d96d9099b619e00112d16aa","ref":"","in":"query","required":false,"desc":"Payout Id","default":"MOJO9423001M54251388","type":"string","name":"id"},{"_id":"5d96d9099b619e00112d16a9","ref":"","in":"query","required":false,"desc":"paid out date-time","default":"2019-06-18T04:59:37.227712Z","type":"datetime","name":"start_time"},{"_id":"5d96d9099b619e00112d16a8","ref":"","in":"query","required":false,"desc":"paid out date-time","default":"2019-06-18T04:59:37.227712Z","type":"datetime","name":"end_time"}],"url":"/v2/payouts"},"isReference":false,"order":999,"body":"","excerpt":"","slug":"payouts","type":"get","title":"Payouts","__v":3,"childrenPages":[]}

getPayouts


Query Params

id:
stringMOJO9423001M54251388
Payout Id
start_time:
datetime2019-06-18T04:59:37.227712Z
paid out date-time
end_time:
datetime2019-06-18T04:59:37.227712Z
paid out date-time

Headers

Authorization:
stringBearer <your-token>

User Information

Try It Out

get
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Result Format



{"_id":"5d96dc9792f977012f2af86e","project":"56a1c9c13845200d0066d6fe","version":"571749c2d2a6510e00840a82","category":"5d95df8df1de56004a1bc525","user":"5ce26a9d4c3d820056874747","updates":[],"next":{"pages":[],"description":""},"createdAt":"2019-10-04T05:45:59.192Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"method":"get","examples":{"codes":[]},"results":{"codes":[{"status":200,"language":"json","code":"{\n    \"count\": 10,\n    \"next\": \"https://test.instamojo.com/v2/products/?page=2\",\n    \"previous\": null,\n    \"products\": \n    [\n        {\n            \"title\": \"test_product\",\n            \"description\": \"test product description\",\n            \"status\": \"Live\",\n            \"user\": \"https://test.instamojo.com/v2/users/<value>/\",\n            \"slug\": \"test_product\",\n            \"shorturl\": \"https://imojo.in/test_product\",\n            \"currency\": \"INR\",\n            \"base_price\": \"25.00\",\n            \"min_price\": \"25.00\",\n            \"max_price\": \"25.00\",\n            \"pay_what_you_want\": false,\n            \"limit_quantity\": null,\n            \"purchased_quantity\": 0,\n            \"discount_public\": false,\n\t          “product_type”:\"physical\",\n            \"requires_shipping\": true,\n            \"ships_within_days\": 25,\n            \"start_date\": null,\n            \"end_date\": null,\n            \"venue\": null,\n            \"timezone\": null,\n            \"redirect_url\": null,\n            \"redirect_time\": 2000,\n            \"webhook_url\": null,\n            \"custom_note_success\": \"\",\n            \"is_signing_mandatory\": false,\n            \"created_at\": \"2019-05-27T09:14:42.078152Z\",\n            \"resource_uri\": \"https://test.instamojo.com/v2/products/test_product/\"\n        },\n    ]\n}\n","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"5729f56e7f34182900ce9d55","auth":"required","params":[{"_id":"5d96dc9792f977012f2af872","ref":"","in":"header","required":false,"desc":"","default":"Bearer <your-token>","type":"string","name":"Authorization"},{"_id":"5d96dc9792f977012f2af871","ref":"","in":"query","required":false,"desc":"","default":"2019-06-18T04:59:37.227712Z","type":"datetime","name":"created_after"},{"_id":"5d96dc9792f977012f2af870","ref":"","in":"query","required":false,"desc":"","default":"2019-06-18T04:59:37.227712Z","type":"datetime","name":"created_before"},{"_id":"5d96dc9792f977012f2af86f","ref":"","in":"query","required":false,"desc":"Live = 20, Archived, 30, Pending Moderation = 33","default":"20","type":"int","name":"status"}],"url":"/v2/products"},"isReference":false,"order":999,"body":"**To get product images:\n**\nRequired Scope: products:read\nHeader: Authorization: Bearer <your-token>\nGET /v2/products/<product_slug>/covers/","excerpt":"","slug":"products","type":"get","title":"Products","__v":4,"childrenPages":[]}

getProducts


Query Params

created_after:
datetime2019-06-18T04:59:37.227712Z
created_before:
datetime2019-06-18T04:59:37.227712Z
status:
integer20
Live = 20, Archived, 30, Pending Moderation = 33

Headers

Authorization:
stringBearer <your-token>
**To get product images: ** Required Scope: products:read Header: Authorization: Bearer <your-token> GET /v2/products/<product_slug>/covers/

User Information

Try It Out

get
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Result Format



**To get product images: ** Required Scope: products:read Header: Authorization: Bearer <your-token> GET /v2/products/<product_slug>/covers/
{"_id":"5d96ddfa19789d002d1d0eb0","project":"56a1c9c13845200d0066d6fe","version":"571749c2d2a6510e00840a82","category":"5d95df8df1de56004a1bc525","user":"5ce26a9d4c3d820056874747","updates":[],"next":{"pages":[],"description":""},"createdAt":"2019-10-04T05:51:54.129Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"method":"get","examples":{"codes":[]},"results":{"codes":[{"status":200,"language":"json","code":"{\n    \"count\": 30,\n    \"num_pages\": 1,\n    \"next\": null,\n    \"previous\": null,\n    \"orders\": \n    [\n        {\n            \"id\": \"4d0d5054-5f19-4ce8-b0b7-ee7a01442297\",\n            \"title\": \"MacBook pro\",\n            \"currency\": \"INR\",\n            \"created_at\": \"2019-07-02T11:16:43.313684Z\",\n            \"buyer_email\": \"liteshpatil17@mail.com\",\n            \"buyer_name\": \"Litesh Patil\",\n            \"buyer_phone\": \"9790707007\",\n            \"buyer_address\": \"17, 7th Cross road, Bengaluru\",\n            \"buyer_city\": \"Bengaluru\",\n            \"buyer_state\": \"Karnataka\",\n            \"buyer_zip\": \"560034\",\n            \"buyer_country\": \"India\",\n            \"amount\": \"70000.00\",\n            \"order_status\": \"Fully Paid\",\n            \"payments_uri\": \"http://localhost:5000/v2/payments/?order_id=<>\",\n            \"payments\":\n             [\n                {\n                    \"payment_id\": \"MOJO9702J00A09128126\",\n                    \"amount\": \"70000.00\",\n                    \"instrument_type\": \"CARD\",\n                    \"status\": \"Success\",\n                    \"resource_uri\": \"http://localhost:5000/v2/payments/<>/\"\n                }\n             ],\n            \"items\": \n             [\n                {\n                    \"unit_price\": \"50000.00\",\n                    \"quantity\": 1,\n                    \"amount\": \"70000.00\",\n                    \"is_shipping_required\": true,\n                    \"seller\": \"http://localhost:5000/v2/users/<value>/\",\n                    \"shipping_charge_logic\": null,\n                    \"shipping_charges\": null,\n                    \"product\": \"http://localhost:5000/v2/products/macbook-pro/\",\n                    \"order\": \"http://localhost:5000/v2/orders/<value>/\",\n                    \"discount\": null,\n                    \"variants\": \n                    [\n                        \"<value>\"\n                    ]\n                }\n             ]\n        },\n    ]\n}","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"5729f56e7f34182900ce9d55","auth":"required","params":[{"_id":"5d96ddfa19789d002d1d0eb4","ref":"","in":"header","required":false,"desc":"","default":"Bearer <your-token>","type":"string","name":"Authorization"},{"_id":"5d96ddfa19789d002d1d0eb3","ref":"","in":"query","required":false,"desc":"","default":"2019-06-18T04:59:37.227712Z","type":"datetime","name":"created_after"},{"_id":"5d96ddfa19789d002d1d0eb2","ref":"","in":"query","required":false,"desc":"","default":"2019-06-18T04:59:37.227712Z","type":"datetime","name":"created_before"},{"_id":"5d96ddfa19789d002d1d0eb1","ref":"","in":"query","required":false,"desc":"Helps in excluding the orders with pending payments","default":"True","type":"boolean","name":"pending"}],"url":"/v2/orders"},"isReference":false,"order":999,"body":"","excerpt":"","slug":"orders","type":"get","title":"Orders","__v":3,"childrenPages":[]}

getOrders


Query Params

created_after:
datetime2019-06-18T04:59:37.227712Z
created_before:
datetime2019-06-18T04:59:37.227712Z
pending:
booleanTrue
Helps in excluding the orders with pending payments

Headers

Authorization:
stringBearer <your-token>

User Information

Try It Out

get
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Result Format



{"_id":"5d96e08b585ec20038b410db","project":"56a1c9c13845200d0066d6fe","version":"571749c2d2a6510e00840a82","category":"5d95df8df1de56004a1bc525","user":"5ce26a9d4c3d820056874747","updates":[],"next":{"pages":[],"description":""},"createdAt":"2019-10-04T06:02:51.624Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"method":"post","examples":{"codes":[]},"results":{"codes":[{"status":201,"language":"json","code":"{\n    \"id\": \"l5f46befbf9234028b25e7f689328e73f\",\n    \"user\": \"https://test.instamojo.com/v2/users/3f5c51c2124e0c88e5bea4943a2c03/\",\n    \"type\": 100,\n    \"amount\": \"999.00\",\n    \"title\": \"test\",\n    \"enabled\": true,\n    \"is_live\": true,\n    \"is_smart\": false,\n    \"shorturl\": \"https://imjo.in/nC38dn\",\n    \"created_at\": \"2019-09-26T09:49:34.054315Z\",\n    \"updated_at\": \"2019-09-26T09:49:34.142610Z\",\n    \"amount_editable\": null,\n    \"minimum_amount\": null,\n    \"description\": null,\n    \"max_payments\": null,\n    \"payments_made\": null,\n    \"colour\": null,\n    \"cover_image\": null,\n    \"note\": null,\n    \"custom_fields\": null,\n    \"redirect_url\": null,\n    \"webhook\": null,\n    \"expires_at\": null,\n                 \"template_type\": null,\n                 \"resource_uri\": \"https://test.instamojo.com/v2/links/<id>/\"\n}\n","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"5729f56e7f34182900ce9d55","auth":"required","params":[{"_id":"5d96e08b585ec20038b410e2","ref":"","in":"header","required":false,"desc":"","default":"Bearer <your-token>","type":"string","name":"Authorization"},{"_id":"5d96e08b585ec20038b410e1","ref":"","in":"body","required":false,"desc":"Input 100 for quick link creation","default":"100","type":"int","name":"type"},{"_id":"5d96e08b585ec20038b410e0","ref":"","in":"body","required":false,"desc":"Payment Amount","default":"999","type":"int","name":"Amount"},{"_id":"5d96e08b585ec20038b410df","ref":"","in":"body","required":false,"desc":"Description of purpose to collect payment","default":"Quick Link","type":"string","name":"Title"},{"_id":"5d96e08b585ec20038b410de","ref":"","in":"body","required":false,"desc":"","default":"True","type":"boolean","name":"Enabled"},{"_id":"5d96e08b585ec20038b410dd","ref":"","in":"body","required":false,"desc":"","default":"True","type":"boolean","name":"Is_live"},{"_id":"5d96e08b585ec20038b410dc","ref":"","in":"body","required":false,"desc":"","default":"False","type":"boolean","name":"Is_smart"}],"url":"/v2/links"},"isReference":false,"order":999,"body":"","excerpt":"","slug":"payment-links-creation","type":"post","title":"Payment Links Creation","__v":3,"childrenPages":[]}

postPayment Links Creation


Body Params

type:
integer100
Input 100 for quick link creation
Amount:
integer999
Payment Amount
Title:
stringQuick Link
Description of purpose to collect payment
Enabled:
booleanTrue
Is_live:
booleanTrue
Is_smart:
booleanFalse

Headers

Authorization:
stringBearer <your-token>

User Information

Try It Out

post
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Result Format



{"_id":"5d96e103285da7005c7e348c","project":"56a1c9c13845200d0066d6fe","version":"571749c2d2a6510e00840a82","category":"5d95df8df1de56004a1bc525","user":"5ce26a9d4c3d820056874747","updates":[],"next":{"pages":[],"description":""},"createdAt":"2019-10-04T06:04:51.857Z","link_external":false,"link_url":"","sync_unique":"","hidden":false,"api":{"method":"get","examples":{"codes":[]},"results":{"codes":[{"status":200,"language":"json","code":"{\n\t\"count\": 737,\n  \"next\": \"https://staging0.instamojo.com/v2/links/?page=2\",\n  \"previous\": null,\n  \"links\": \n\t[\n\t\t{\n      \"id\": \"l5f46befbf9234028b25e7f689328e73f\",\n      \"user\": \"https://test.instamojo.com/v2/users/3f5c51c2124e0c88e5bea4943a2c03/\",\n      \"type\": 100,\n      \"amount\": \"999.00\",\n      \"title\": \"test\",\n      \"enabled\": true,\n      \"is_live\": true,\n      \"is_smart\": false,\n      \"shorturl\": \"https://imjo.in/nC38dn\",\n      \"created_at\": \"2019-09-26T09:49:34.054315Z\",\n      \"updated_at\": \"2019-09-26T09:49:34.142610Z\",\n      \"amount_editable\": null,\n      \"minimum_amount\": null,\n      \"description\": null,\n      \"max_payments\": null,\n      \"payments_made\": null,\n      \"colour\": null,\n      \"cover_image\": null,\n      \"note\": null,\n      \"custom_fields\": null,\n      \"redirect_url\": null,\n      \"webhook\": null,\n      \"expires_at\": null,\n      \"template_type\": null,\n      \"resource_uri\": \"https://test.instamojo.com/v2/links/<value>/\"\t\n\t\t},\n\t]\t\n}\n","name":""},{"status":400,"language":"json","code":"{}","name":""}]},"settings":"5729f56e7f34182900ce9d55","auth":"required","params":[{"_id":"5d96e103285da7005c7e348e","ref":"","in":"header","required":false,"desc":"","default":"Bearer <your-token>","type":"string","name":"Authorization"},{"_id":"5d96e103285da7005c7e348d","ref":"","in":"query","required":false,"desc":"","default":"False","type":"boolean","name":"enabled"}],"url":"/v2/links"},"isReference":false,"order":999,"body":"","excerpt":"","slug":"payment-links-view","type":"get","title":"Payment Links View","__v":2,"childrenPages":[]}

getPayment Links View


Query Params

enabled:
booleanFalse

Headers

Authorization:
stringBearer <your-token>

User Information

Try It Out

get
{{ tryResults.results }}
Method{{ tryResults.method }}
Request Headers
{{ tryResults.requestHeaders }}
URL{{ tryResults.url }}
Request Data
{{ tryResults.data }}
Status
Response Headers
{{ tryResults.responseHeaders }}

Definition

{{ api_url }}{{ page_api_url }}

Result Format