{"info":{"_postman_id":"58e45cee-be3a-4c63-9ffc-663d15516d75","name":"Apollo Finvest: NOC API","description":"<html><head></head><body><h1 id=\"get-noc-document-api\"><strong>Get NOC Document API</strong></h1>\n<p>This API is to generate NOC (No dues letter) from Apollo Finvest for the loans that are closed and there are no overdue.</p>\n<h2 id=\"overview\">Overview:</h2>\n<p>This API will help the partner generate NOC for the loans that are closed. The loans will be closed or completed in Apollo's Loan Management System when the borrower repays all the overdue EMIs and when there is no principal outstanding.</p>\n<p>This is a GET request API for UAT/ Test Environment to get the NOC document from Apollo. After successfully integrating this API, we will provide you with the production URL and credentials.</p>\n<h2 id=\"authenticationauthorization\">Authentication/Authorization:</h2>\n<p><code>x-API-key</code> and <code>access token</code> should be sent in request headers for authenticating the request. Apollo will provide <code>x-API-key</code>. <code>Access token</code> should be generated by the partners. Therefore please generate a new access token using the below code piece. The token will expire in 5 minutes.<br>Please refer to the API collection to understand more.</p>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-python\">import requests\nimport base64\nurl = \"will be shared by apollo\"\napp_client_id = \"will be shared by apollo\"\napp_secret = \"will be shared by apollo\"\nbasic = base64.b64encode((app_client_id+':'+app_secret).encode())\npayload = 'grant_type=client_credentials&amp;scope='\nheaders = {\n    'Authorization': 'Basic '+basic.decode(),\n    'Content-Type': 'application/x-www-form-urlencoded',\n}\nresponse = requests.request(\"POST\", url, headers=headers, data=payload)\nprint(response.json())\n\n</code></pre>\n<h2 id=\"required-query-parameters\">Required Query Parameters:</h2>\n<div class=\"click-to-expand-wrapper is-table-wrapper\"><table>\n<thead>\n<tr>\n<th><strong>Request</strong></th>\n<th><strong>Values</strong></th>\n<th><strong>Description</strong></th>\n</tr>\n</thead>\n<tbody>\n<tr>\n<td>partner_loan_id</td>\n<td>Unique Loan Id created and maintained by the partner</td>\n<td><strong><code>Required.</code></strong> This loan_id must be the same one used at the time of loan creation on Apollo's LMS. It should not be more than 10 digits. It is created by the partner</td>\n</tr>\n<tr>\n<td>loan_type</td>\n<td>PL/ML/CL</td>\n<td><strong><code>Required.</code></strong> Use the right input same as the one used at the time of loan creation for that particular loan_id. PL- Personal Loan, ML- Micro Loan, CL- Consumer Loan</td>\n</tr>\n<tr>\n<td>partner_tag</td>\n<td>Unique Partner Tag provided by Apollo</td>\n<td><strong><code>Required.</code></strong> This helps to identify the partner on Apollo's system. This is created by Apollo.</td>\n</tr>\n</tbody>\n</table>\n</div><h2 id=\"sample-response\">Sample Response:</h2>\n<h4 id=\"if-a-loan-is-closed-then-noc-will-get-generated-by-giving-the-below-response\">If a loan is closed then NOC will get generated by giving the below response</h4>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"partner_tag\": \"TEST\",\n    \"loan_type\": \"PL\",\n    \"partner_loan_id\": \"test\",\n    \"S3 key\": \"This would be the presigned url for the document\"\n}\n\n</code></pre>\n<h4 id=\"if-the-loan-is-not-closed-on-apollos-platform-then-the-following-response-will-be-provided-status-code-404\"><strong>If the loan is not closed on Apollo's platform then the following response will be provided (Status code 404):</strong></h4>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"message\": \"NOC cannot be generated as the requested loan is not closed yet\"\n}\n\n</code></pre>\n<h4 id=\"if-the-loan-doesnt-exist-on-apollos-platform-then-the-following-response-will-be-provided\">If the loan doesn't exist on Apollo's platform then the following response will be provided:</h4>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"message\": \"Loan does not exist\"\n}\n\n</code></pre>\n<h4 id=\"if-the-partner-tag-given-is-invalid-then-the-following-response-will-be-provided\">If the partner tag given is invalid then the following response will be provided:</h4>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"message\": \"Invalid partner tag\"\n}\n\n</code></pre>\n<h4 id=\"if-the-loan-type-given-is-invalid-then-the-following-response-will-be-provided\">If the loan type given is invalid then the following response will be provided:</h4>\n<pre class=\"click-to-expand-wrapper is-snippet-wrapper\"><code class=\"language-json\">{\n    \"message\": \"Unsupported loan type KL\"\n}\n\n</code></pre>\n<h2 id=\"response-status-codes\">Response status Codes:</h2>\n<h4 id=\"200\">200</h4>\n<p>Successful Request</p>\n<h4 id=\"400\">400</h4>\n<p>Invalid Request</p>\n<h4 id=\"401\">401</h4>\n<p>Unauthorized (The incoming token has expired)</p>\n<h4 id=\"403\">403</h4>\n<p>Forbidden (x-api-key is wrong or partner is not allowed to use this API)</p>\n<h4 id=\"404\">404</h4>\n<p>Not Found (Noc Not Found)</p>\n<h4 id=\"500\">500</h4>\n<p>Internal Server Error (Rare)</p>\n<h4 id=\"504\">504</h4>\n<p>Bad gateway</p>\n<h1 id=\"rate-limit\">Rate Limit</h1>\n<ul>\n<li><p><strong>Throttling:</strong><br>  :10000 requests per second</p>\n</li>\n<li><p><strong>Quota:</strong><br>  :Unlimited total number of API calls</p>\n</li>\n</ul>\n<h1 id=\"sla-breakdown\">SLA breakdown</h1>\n<ul>\n<li><strong>Standard Support</strong><br>  Apollo will provide standard technical support twenty-four (24) hours per day, five (5) days per week, excluding weekends and national Indian holidays. Standard Support will be offered via email.</li>\n<li><strong>Uptime commitment</strong><br>  Uptime is the percentage of total possible minutes API was available during a fiscal year. Our commitment is to maintain at least 99.99% uptime.</li>\n<li><strong>Scheduled downtime</strong><br>  Sometimes we need to perform maintenance to keep API working smoothly. If scheduled downtime is necessary, we’ll give you at least 48 hours advance notice. In a year, scheduled downtime won’t exceed 12 hours.</li>\n<li><strong>Updates</strong><br>  As our business evolves, we may change our service level agreement. Customers can review the most current version of the service level agreement at any time by visiting this page.</li>\n</ul>\n</body></html>","schema":"https://schema.getpostman.com/json/collection/v2.0.0/collection.json","toc":[{"content":"Get NOC Document API","slug":"get-noc-document-api"},{"content":"Rate Limit","slug":"rate-limit"},{"content":"SLA breakdown","slug":"sla-breakdown"}],"owner":"16291369","collectionId":"58e45cee-be3a-4c63-9ffc-663d15516d75","publishedId":"2s7YYsbiuU","public":true,"customColor":{"top-bar":"FFFFFF","right-sidebar":"303030","highlight":"EF5B25"},"publishDate":"2022-09-13T11:24:46.000Z"},"item":[{"name":"NOC Request API","id":"e0e77975-0661-4054-875a-ee3b1e0ace47","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"method":"GET","header":[{"key":"x-api-key","value":"*******","type":"text"},{"key":"Authorization","value":"*******","type":"text"}],"url":"https://{servername.com}/{env}/{version}/noc?partner_tag=TEST&loan_type=PL&partner_loan_id=TST10","urlObject":{"protocol":"https","path":["{env}","{version}","noc"],"host":["{servername","com}"],"query":[{"key":"partner_tag","value":"TEST"},{"key":"loan_type","value":"PL"},{"key":"partner_loan_id","value":"TST10"}],"variable":[]}},"response":[],"_postman_id":"e0e77975-0661-4054-875a-ee3b1e0ace47"},{"name":"Access Token Generator","id":"c630ea49-eb95-4308-846d-16441718e6cc","protocolProfileBehavior":{"disableBodyPruning":true},"request":{"auth":{"type":"oauth2","oauth2":{"basicConfig":[],"advancedConfig":[{"key":"accessTokenUrl","value":"<access-token-url>"},{"key":"clientSecret","value":"<client-secret>"},{"key":"clientId","value":"<client-id>"},{"key":"headerPrefix","value":"<header-prefix>"},{"key":"grant_type","value":"<grant_type>"},{"key":"authUrl","value":"<auth-url>"}]},"isInherited":false},"method":"GET","header":[],"body":{"mode":"formdata","formdata":[{"key":"grant_type","value":"client_credentials","type":"text"}]},"url":"https://{name-api-app.auth.ap-server-name-2.{servercognito}.com/{auth2}/token","urlObject":{"protocol":"https","path":["{auth2}","token"],"host":["{name-api-app","auth","ap-server-name-2","{servercognito}","com"],"query":[],"variable":[]}},"response":[],"_postman_id":"c630ea49-eb95-4308-846d-16441718e6cc"}]}