{"id":21133000,"url":"https://github.com/raj457036/paytm-api-for-django","last_synced_at":"2026-04-27T17:04:08.431Z","repository":{"id":88809689,"uuid":"151257534","full_name":"raj457036/Paytm-api-for-django","owner":"raj457036","description":"High performance Paytm Gateway api for Django. Just plug and play app.","archived":false,"fork":false,"pushed_at":"2021-05-17T05:37:34.000Z","size":534,"stargazers_count":2,"open_issues_count":1,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2026-01-01T17:37:34.280Z","etag":null,"topics":["django","django2","gateway","payment-gateway","paytm-api","paytm-app","paytm-dajngo","paytm-gateway-django","paytm-gateway-python","paytm-merchant","paytm-payments","python3"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/raj457036.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2018-10-02T13:18:44.000Z","updated_at":"2021-05-17T05:37:36.000Z","dependencies_parsed_at":"2023-06-12T18:31:07.916Z","dependency_job_id":null,"html_url":"https://github.com/raj457036/Paytm-api-for-django","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/raj457036/Paytm-api-for-django","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raj457036%2FPaytm-api-for-django","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raj457036%2FPaytm-api-for-django/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raj457036%2FPaytm-api-for-django/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raj457036%2FPaytm-api-for-django/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/raj457036","download_url":"https://codeload.github.com/raj457036/Paytm-api-for-django/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/raj457036%2FPaytm-api-for-django/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32345850,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-26T23:26:28.701Z","status":"online","status_checked_at":"2026-04-27T02:00:06.769Z","response_time":128,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["django","django2","gateway","payment-gateway","paytm-api","paytm-app","paytm-dajngo","paytm-gateway-django","paytm-gateway-python","paytm-merchant","paytm-payments","python3"],"created_at":"2024-11-20T06:01:16.766Z","updated_at":"2026-04-27T17:04:08.415Z","avatar_url":"https://github.com/raj457036.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Paytm-api-for-django\r\nHigh performance Paytm Gateway api for Django. Just plug and play app. good luck.\r\n\r\n### Requirements\r\nPython 3+\r\nDjango 2+\r\n\r\n### Installation\r\n**Step 1** : clone this repo and paste it in your project directory\r\n**Step 2** : open **settings.py** file of your project and add **paytm** to **INSTALLED_APPS** paste the below settings\r\n\r\n```python\r\n# settings.py\r\n\r\nINSTALLED_APPS = [\r\n    .\r\n    .\r\n    .\r\n    'paytm',\r\n]\r\n\r\n# other settings...\r\n\r\nPAYTM_STAGING_URL = 'https://securegw-stage.paytm.in'\r\nPAYTM_PRODUCTION_URL = 'https://securegw.paytm.in'\r\n\r\nHOSTNAME = '127.0.0.1:8000'\r\n\r\nif DEBUG:\r\n    PAYTM_URL = PAYTM_STAGING_URL\r\nelse:\r\n    PAYTM_URL = PAYTM_PRODUCTION_URL\r\n\r\nPAYTM_MERCHANT_KEY = 'XXXXXXXXXXXX' # replace with original merchangt key\r\nPAYTM_GATEWAY_SETTINGS = {\r\n    'MID':'XXXXXXXXXXXXXXXXXXXX', # replace with original merchangt id or MID\r\n    'INDUSTRY_TYPE_ID':'Retail',\r\n    'WEBSITE':'APPSTAGING', # WEBSTAGING for websites --\u003e\u003e change this with production variables\r\n    'CHANNEL_ID':'WAP', #WEB for websites\r\n    'CALLBACK_URL':f'http://{HOSTNAME}/paytm/payment_response/', } # https:// if you are on production server\r\n\r\nPAYTM_SAVE_SUCCESS_TRANSECTIONS_ONLY = True  # if this is true paytm will save only successful transection else it willsave all transections\r\n```\r\n**Step 3** : Run **migrations and migrate** after that Replace \"XXXXX...\" above with respective **merchant key** and **MID**\r\n\r\n**Step 4** : open urls.py and add\r\n```python\r\n#urls.py\r\n\r\nurlpatterns = [\r\n  #other urls ...\r\n  path('paytm/', include('paytm.urls'))\r\n]\r\n```\r\n\r\n**Step 5** : Setup complete and you are good to go\r\n\r\n## Test your api\r\n\r\n - run the server and go to **http://127.0.0.1:8000/paytm/test/**\r\n \r\n ![](https://lh5.googleusercontent.com/aLLJJWemvZr-KaOtQhz-yxMx55Cvx0f2uCRZJdGpedPwk0BUshaitkPGKd6JifD7gd8FBf3BDYU6YQCoqm93=w1920-h976)\r\n \r\n - Fill the details and test your api\r\n \r\n \r\n## URLS\r\n    ### To request for payment\r\n    url: https://{HOST}/paytm/payment_response/ \r\n    method: POST\r\n    minimum requirements = ['ORDER_ID', 'TXN_AMOUNT', 'CUST_ID'] send these fields\r\n    NOTE: This api is also optimized for PAYMENT_MODE_ONLY field for more info go through paytm gateway docs below\r\n    \r\n    \r\n    ### To check status of transection\r\n    url: https://{HOST}/paytm/status/\r\n    method: POST\r\n    minimum requirements = ['ORDER_ID'] send these fields\r\n    \r\n    for all the available fields go through\r\n    PAYTM Gateway Documentation\r\n    https://business.paytm.com/developers-api/integration/payment-gateway/documentation\r\n\r\n\r\n# NOTES \r\n- Every api need the **user to be logged** in So if you dont want it to check for logged in just remove LoginRequiredMixin from views.py in paytm folder\r\n- All the response are in json format\r\n- Apis are checked and highly optimized for performance\r\n- This package also include **Refund API** But Paytm suggest not to use apis for this use **PAYTM DASHBOARD**\r\n- you will need to install **pycrypto** for paytm to work.  \r\n    ```sh\r\n    pip install pycrypto\r\n    ```\r\n    if above give error, i included pre-compiled wheel file\r\n    \r\n    ```sh\r\n    pip install pycrypto-2.6.1-cp36-cp36m-win_amd64.whl\r\n    ```\r\n    this will solve the problem for windows users too.\r\n\r\n### Any problem? raise an issue\r\n\r\n# LICENCE\r\n - MIT\r\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fraj457036%2Fpaytm-api-for-django","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fraj457036%2Fpaytm-api-for-django","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fraj457036%2Fpaytm-api-for-django/lists"}