{"id":18517724,"url":"https://github.com/midtrans/midtrans-python-client","last_synced_at":"2025-08-21T03:32:32.049Z","repository":{"id":33231714,"uuid":"154629419","full_name":"Midtrans/midtrans-python-client","owner":"Midtrans","description":"Official Midtrans Payment API Client for Python | https://midtrans.com","archived":false,"fork":false,"pushed_at":"2023-10-18T10:54:07.000Z","size":178,"stargazers_count":39,"open_issues_count":3,"forks_count":28,"subscribers_count":8,"default_branch":"master","last_synced_at":"2025-08-18T01:53:20.974Z","etag":null,"topics":["api-client","midtrans","payment","payment-gateway","python","python-library","python2","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/Midtrans.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-25T07:37:48.000Z","updated_at":"2025-01-30T17:58:41.000Z","dependencies_parsed_at":"2024-06-19T13:33:54.715Z","dependency_job_id":"64068d1c-b3dd-43d7-a6ff-340e7d484cfb","html_url":"https://github.com/Midtrans/midtrans-python-client","commit_stats":{"total_commits":121,"total_committers":11,"mean_commits":11.0,"dds":0.5619834710743802,"last_synced_commit":"72883f5b47132e50632346b46c5af37c50c27f49"},"previous_names":[],"tags_count":4,"template":false,"template_full_name":null,"purl":"pkg:github/Midtrans/midtrans-python-client","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Midtrans%2Fmidtrans-python-client","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Midtrans%2Fmidtrans-python-client/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Midtrans%2Fmidtrans-python-client/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Midtrans%2Fmidtrans-python-client/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Midtrans","download_url":"https://codeload.github.com/Midtrans/midtrans-python-client/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Midtrans%2Fmidtrans-python-client/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":271420513,"owners_count":24756580,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-21T02:00:08.990Z","response_time":74,"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":["api-client","midtrans","payment","payment-gateway","python","python-library","python2","python3"],"created_at":"2024-11-06T17:07:59.018Z","updated_at":"2025-08-21T03:32:31.759Z","avatar_url":"https://github.com/Midtrans.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"Midtrans Client - Python\n===============\n\n[![PyPI version](https://badge.fury.io/py/midtransclient.svg)](https://badge.fury.io/py/midtransclient)\n[![Downloads](https://pepy.tech/badge/midtransclient/month)](https://pepy.tech/project/midtransclient)\n[![Downloads](https://pepy.tech/badge/midtransclient)](https://pepy.tech/project/midtransclient)\n\nMidtrans ❤️ Python! 🐍\n\nThis is the Official Python API client/library for Midtrans Payment API. Visit [https://midtrans.com](https://midtrans.com). More information about the product and see documentation at [http://docs.midtrans.com](https://docs.midtrans.com) for more technical details.\n\n## 1. Installation\n\n### 1.a Using Pip\n\n```\npip install midtransclient\n```\n\n### 1.b Manual Installation\n\nIf you are not using Pip, you can clone or [download](https://github.com/midtrans/midtrans-python-client/archive/master.zip) this repository.\nThen import from `midtransclient` folder.\n\nOr run Pip install from the repo folder.\n```\npip install .\n```\n\n## 2. Usage\n\n### 2.1 Choose Product/Method\n\nWe have [2 different products](https://docs.midtrans.com/en/welcome/index.html) of payment that you can use:\n- [Snap](#22A-snap) - Customizable payment popup will appear on **your web/app** (no redirection). [doc ref](https://snap-docs.midtrans.com/)\n- [Snap Redirect](#22B-snap-redirect) - Customer need to be redirected to payment url **hosted by midtrans**. [doc ref](https://snap-docs.midtrans.com/)\n- [Core API (VT-Direct)](#22C-core-api-vt-direct) - Basic backend implementation, you can customize the frontend embedded on **your web/app** as you like (no redirection). [doc ref](https://api-docs.midtrans.com/)\n\nChoose one that you think best for your unique needs.\n\n### 2.2 Client Initialization and Configuration\n\nGet your client key and server key from [Midtrans Dashboard](https://dashboard.midtrans.com)\n\nCreate API client object\n\n```python\n# Create Core API instance\ncore_api = midtransclient.CoreApi(\n    is_production=False,\n    server_key='YOUR_SERVER_KEY',\n    client_key='YOUR_CLIENT_KEY'\n)\n```\n\n\n```python\n# Create Snap API instance\nsnap = midtransclient.Snap(\n    is_production=False,\n    server_key='YOUR_SERVER_KEY',\n    client_key='YOUR_CLIENT_KEY'\n)\n```\n\nYou can also re-set config using `Snap.api_config.set( ... )`\nexample:\n\n```python\n\n# initialize object, empty config\nsnap = midtransclient.Snap()\n\n# re-set full config\nsnap.api_config.set(\n    is_production=False,\n    server_key='YOUR_SERVER_KEY',\n    client_key='YOUR_CLIENT_KEY'\n)\n\n# re-set server_key only\nsnap.api_config.set(server_key='YOUR_SERVER_KEY')\n\n# re-set is_production only\nsnap.api_config.set(is_production=True)\n```\n\nYou can also set config directly from attribute\n```python\n# initialize object, empty config\nsnap = midtransclient.Snap()\n\n# set config\nsnap.api_config.is_production=False\nsnap.api_config.server_key='YOUR_SERVER_KEY'\nsnap.api_config.client='YOUR_CLIENT_KEY'\n```\n\n\n### 2.2.A Snap\nYou can see Snap example [here](examples/snap).\n\nAvailable methods for `Snap` class\n```python\n# return Snap API /transaction response as Dictionary\ndef create_transactions(parameter):\n\n# return Snap API /transaction token as String\ndef create_transactions_token(parameter):\n\n# return Snap API /transaction redirect_url as String\ndef create_transactions_redirect_url(parameter):\n```\n`parameter` is Dictionary or String of JSON of [SNAP Parameter](https://snap-docs.midtrans.com/#json-objects)\n\n\n#### Get Snap Token\n\n```python\n# Create Snap API instance\nsnap = midtransclient.Snap(\n    is_production=False,\n    server_key='YOUR_SERVER_KEY',\n    client_key='YOUR_CLIENT_KEY'\n)\n# Prepare parameter\nparam = {\n    \"transaction_details\": {\n        \"order_id\": \"test-transaction-123\",\n        \"gross_amount\": 200000\n    }, \"credit_card\":{\n        \"secure\" : True\n    }\n}\n\ntransaction = snap.create_transaction(param)\n\ntransaction_token = transaction['token']\n# alternative way to create transaction_token:\n# transaction_token = snap.create_transaction_token(param)\n```\n\n\n#### Initialize Snap JS when customer click pay button\n\nReplace `PUT_TRANSACTION_TOKEN_HERE` with `transaction_token` acquired above\n```html\n\u003chtml\u003e\n  \u003cbody\u003e\n    \u003cbutton id=\"pay-button\"\u003ePay!\u003c/button\u003e\n    \u003cpre\u003e\u003cdiv id=\"result-json\"\u003eJSON result will appear here after payment:\u003cbr\u003e\u003c/div\u003e\u003c/pre\u003e\n\n\u003c!-- TODO: Remove \".sandbox\" from script src URL for production environment. Also input your client key in \"data-client-key\" --\u003e\n    \u003cscript src=\"https://app.sandbox.midtrans.com/snap/snap.js\" data-client-key=\"\u003cSet your ClientKey here\u003e\"\u003e\u003c/script\u003e\n    \u003cscript type=\"text/javascript\"\u003e\n      document.getElementById('pay-button').onclick = function(){\n        // SnapToken acquired from previous step\n        snap.pay('PUT_TRANSACTION_TOKEN_HERE', {\n          // Optional\n          onSuccess: function(result){\n            /* You may add your own js here, this is just example */ document.getElementById('result-json').innerHTML += JSON.stringify(result, null, 2);\n          },\n          // Optional\n          onPending: function(result){\n            /* You may add your own js here, this is just example */ document.getElementById('result-json').innerHTML += JSON.stringify(result, null, 2);\n          },\n          // Optional\n          onError: function(result){\n            /* You may add your own js here, this is just example */ document.getElementById('result-json').innerHTML += JSON.stringify(result, null, 2);\n          }\n        });\n      };\n    \u003c/script\u003e\n  \u003c/body\u003e\n\u003c/html\u003e\n```\n\n#### Implement Notification Handler\n[Refer to this section](#23-handle-http-notification)\n\n### 2.2.B Snap Redirect\n\nAlso available as examples [here](examples/snap).\n\n#### Get Redirection URL of a Payment Page\n\n```python\n# Create Snap API instance\nsnap = midtransclient.Snap(\n    is_production=False,\n    server_key='YOUR_SERVER_KEY',\n    client_key='YOUR_CLIENT_KEY'\n)\n# Prepare parameter\nparam = {\n    \"transaction_details\": {\n        \"order_id\": \"test-transaction-123\",\n        \"gross_amount\": 200000\n    }, \"credit_card\":{\n        \"secure\" : True\n    }\n}\n\ntransaction = snap.create_transaction(param)\n\ntransaction_redirect_url = transaction['redirect_url']\n# alternative way to create redirect_url:\n# transaction_redirect_url = snap.create_redirect_url(param)\n```\n#### Implement Notification Handler\n[Refer to this section](#23-handle-http-notification)\n\n### 2.2.C Core API (VT-Direct)\n\nYou can see some Core API examples [here](examples/core_api).\n\nAvailable methods for `CoreApi` class\n```python\ndef charge(self,parameters=dict()):\n    \"\"\"\n    Trigger `/charge` API call to Core API\n    :param parameters: dictionary of Core API JSON body as parameter, will be converted to JSON\n    (more params detail refer to: https://api-docs.midtrans.com)\n\n    :return: Dictionary from JSON decoded response\n    \"\"\"\n\ndef capture(self,parameters=dict()):\n    \"\"\"\n    Trigger `/capture` API call to Core API\n    Capture is only used for pre-authorize transaction only\n    :param parameters: dictionary of Core API JSON body as parameter, will be converted to JSON\n    (more params detail refer to: https://api-docs.midtrans.com)\n\n    :return: Dictionary from JSON decoded response\n    \"\"\"\n\ndef card_register(self,parameters=dict()):\n    \"\"\"\n    Trigger `/card/register` API call to Core API\n    :param parameters: dictionary of Core API JSON body as parameter, will be converted to JSON\n    (more params detail refer to: https://api-docs.midtrans.com)\n\n    :return: Dictionary from JSON decoded response\n    \"\"\"\n\ndef card_token(self,parameters=dict()):\n    \"\"\"\n    Trigger `/token` API call to Core API\n    :param parameters: dictionary of Core API JSON body as parameter, will be converted to JSON\n    (more params detail refer to: https://api-docs.midtrans.com)\n\n    :return: Dictionary from JSON decoded response\n    \"\"\"\n\ndef card_point_inquiry(self,token_id):\n    \"\"\"\n    Trigger `/point_inquiry/\u003ctoken-id\u003e` API call to Core API\n    :param parameters: dictionary of Core API JSON body as parameter, will be converted to JSON\n    (more params detail refer to: https://api-docs.midtrans.com)\n\n    :return: Dictionary from JSON decoded response\n    \"\"\"\n```\n`parameter` is Dictionary or String of JSON of [Core API Parameter](https://api-docs.midtrans.com/#json-objects)\n\n#### Credit Card Get Token\n\nGet token should be handled on  Frontend please refer to [API docs](https://api-docs.midtrans.com)\n\n#### Credit Card Charge\n\n```python\n# Create Core API instance\ncore_api = midtransclient.Snap(\n    is_production=False,\n    server_key='YOUR_SERVER_KEY',\n    client_key='YOUR_CLIENT_KEY'\n)\n# Prepare parameter\nparam = {\n    \"payment_type\": \"credit_card\",\n    \"transaction_details\": {\n        \"gross_amount\": 12145,\n        \"order_id\": \"test-transaction-54321\",\n    },\n    \"credit_card\":{\n        \"token_id\": 'CREDIT_CARD_TOKEN', # change with your card token\n        \"authentication\": True\n    }\n}\n\n# charge transaction\ncharge_response = core_api.charge(param)\nprint('charge_response:')\nprint(charge_response)\n```\n\n#### Credit Card 3DS Authentication\n\nThe credit card charge result may contains `redirect_url` for 3DS authentication. 3DS Authentication should be handled on Frontend please refer to [API docs](https://api-docs.midtrans.com/#card-features-3d-secure)\n\nFor full example on Credit Card 3DS transaction refer to:\n- [Flask App examples](/examples/flask_app) that implement Snap \u0026 Core Api\n\n### 2.2.D Subscription API\n\nYou can see some Subscription API examples [here](examples/subscription), [Subscription API Docs](https://api-docs.midtrans.com/#subscription-api)\n\n#### Subscription API for Credit Card\n\nTo use subscription API for credit card, you should first obtain the 1-click saved token, [refer to this docs.](https://docs.midtrans.com/en/core-api/advanced-features?id=recurring-transaction-with-subscriptions-api) \n\nYou will receive `saved_token_id` as part of the response when the initial card payment is accepted (will also available in the HTTP notification's JSON), [refer to this docs.](https://docs.midtrans.com/en/core-api/advanced-features?id=sample-3ds-authenticate-json-response-for-the-first-transaction)\n\n```python\n# Create Subscription API instance\ncore_api = midtransclient.CoreApi(\n    is_production=False,\n    server_key='YOUR_SERVER_KEY',\n    client_key='YOUR_CLIENT_KEY'\n)\n# Prepare parameter\nparam = {\n    \"name\": \"SUBSCRIPTION-STARTER-1\",\n    \"amount\": \"100000\",\n    \"currency\": \"IDR\",\n    \"payment_type\": \"credit_card\",\n    \"token\": \"436502qFfqfAQKScMtPRPdZDOaeg7199\",\n    \"schedule\": {\n      \"interval\": 1,\n      \"interval_unit\": \"month\",\n      \"max_interval\": 3,\n      \"start_time\": \"2021-10-01 07:25:01 +0700\"\n    },\n    \"metadata\": {\n      \"description\": \"Recurring payment for STARTER 1\"\n    },\n    \"customer_details\": {\n      \"first_name\": \"John A\",\n      \"last_name\": \"Doe A\",\n      \"email\": \"johndoe@email.com\",\n      \"phone\": \"+62812345678\"\n    }\n}\ncreate_subscription_response = core_api.create_subscription(param)\n\nsubscription_id_response = create_subscription_response['id']\n# get subscription by subscription_id\nget_subscription_response = core_api.get_subscription(subscription_id_response)\n\n# disable subscription by subscription_id\ndisable_subscription_response = core_api.disable_subscription(subscription_id_response)\n\n# enable subscription by subscription_id\nenable_subscription_response = core_api.enable_subscription(subscription_id_response)\n\n# update subscription by subscription_id\nupdate_param = {\n    \"name\": \"SUBSCRIPTION-STARTER-1-UPDATE\",\n    \"amount\": \"100000\",\n    \"currency\": \"IDR\",\n    \"token\": \"436502qFfqfAQKScMtPRPdZDOaeg7199\",\n    \"schedule\": {\n      \"interval\": 1\n}\nupdate_subscription_response = core_api.update_subscription(subscription_id_response, update_param)\n```\n\n#### Subscription API for Gopay\n\nTo use subscription API for gopay, you should first link your customer gopay account with gopay tokenization API, [refer to this section](#22e-tokenization-api)\n\nYou will receive gopay payment token using `get_payment_account` API call \n\nYou can see some Subscription API examples [here](examples/subscription)\n\n### 2.2.E Tokenization API\nYou can see some Tokenization API examples [here](examples/tokenization), [Tokenization API Docs](https://api-docs.midtrans.com/#gopay-tokenization)\n\n```python\n# Create Tokenization API instance\ncore_api = midtransclient.CoreApi(\n    is_production=False,\n    server_key='YOUR_SERVER_KEY',\n    client_key='YOUR_CLIENT_KEY'\n)\n# Prepare parameter\nparam = {\n  \"payment_type\": \"gopay\",\n  \"gopay_partner\": {\n    \"phone_number\": \"81234567891\",\n    \"country_code\": \"62\",\n    \"redirect_url\": \"https://mywebstore.com/gopay-linking-finish\" #please update with your redirect URL\n  }\n}\n\n# link payment account\nlink_payment_account_response = core_api.link_payment_account(param)\n\n# get payment account\nget_payment_account_response = core_api.get_payment_account(active_account_id)\n\n# unlink account\nunlink_payment_account_response = core_api.unlink_payment_account(active_account_id)\n```\n\n### 2.3 Handle HTTP Notification\n\n\u003e **IMPORTANT NOTE**: To update transaction status on your backend/database, **DO NOT** solely rely on frontend callbacks! For security reason to make sure the status is authentically coming from Midtrans, only update transaction status based on HTTP Notification or API Get Status.\n\nCreate separated web endpoint (notification url) to receive HTTP POST notification callback/webhook.\nHTTP notification will be sent whenever transaction status is changed.\nExample also available [here](examples/transaction_actions/notification_example.py)\n\n```python\n# Create Core API / Snap instance (both have shared `transactions` methods)\napi_client = midtransclient.CoreApi(\n    is_production=False,\n    server_key='YOUR_SERVER_KEY',\n    client_key='YOUR_CLIENT_KEY'\n)\nstatus_response = api_client.transactions.notification(mock_notification)\n\norder_id = status_response['order_id']\ntransaction_status = status_response['transaction_status']\nfraud_status = status_response['fraud_status']\n\nprint('Transaction notification received. Order ID: {0}. Transaction status: {1}. Fraud status: {3}'.format(order_id,\n    transaction_status,\n    fraud_status))\n\n# Sample transaction_status handling logic\n\nif transaction_status == 'capture':\n  if fraud_status == 'challenge':\n    # TODO set transaction status on your databaase to 'challenge'\n  else if fraud_status == 'accept':\n    # TODO set transaction status on your databaase to 'success'\nelse if transaction_status == 'cancel' or\n  transaction_status == 'deny' or\n  transaction_status == 'expire':\n  # TODO set transaction status on your databaase to 'failure'\nelse if transaction_status == 'pending':\n  # TODO set transaction status on your databaase to 'pending' / waiting payment\n```\n\n### 2.4 Transaction Action\nAlso available as examples [here](examples/transaction_actions)\n#### Get Status\n```python\n# get status of transaction that already recorded on midtrans (already `charge`-ed)\nstatus_response = api_client.transactions.status('YOUR_ORDER_ID OR TRANSACTION_ID')\n```\n#### Get Status B2B\n```python\n# get transaction status of VA b2b transaction\nstatusb2b_response = api_client.transactions.statusb2b('YOUR_ORDER_ID OR TRANSACTION_ID')\n```\n#### Approve Transaction\n```python\n# approve a credit card transaction with `challenge` fraud status\napprove_response = api_client.transactions.approve('YOUR_ORDER_ID OR TRANSACTION_ID')\n```\n#### Deny Transaction\n```python\n# deny a credit card transaction with `challenge` fraud status\ndeny_response = api_client.transactions.deny('YOUR_ORDER_ID OR TRANSACTION_ID')\n```\n#### Cancel Transaction\n```python\n# cancel a credit card transaction or pending transaction\ncancel_response = api_client.transactions.cancel('YOUR_ORDER_ID OR TRANSACTION_ID')\n```\n#### Expire Transaction\n```python\n# expire a pending transaction\nexpire_response = api_client.transactions.expire('YOUR_ORDER_ID OR TRANSACTION_ID')\n```\n#### Refund Transaction\n```python\n# refund a transaction (not all payment channel allow refund via API)\nparam = {\n    \"refund_key\": \"order1-ref1\",\n    \"amount\": 5000,\n    \"reason\": \"Item out of stock\"\n}\nrefund_response = api_client.transactions.refund('YOUR_ORDER_ID OR TRANSACTION_ID',param)\n```\n\n#### Refund Transaction with Direct Refund\n```python\n# refund a transaction (not all payment channel allow refund via API) with Direct Refund\nparam = {\n    \"refund_key\": \"order1-ref1\",\n    \"amount\": 5000,\n    \"reason\": \"Item out of stock\"\n}\nrefund_response = api_client.transactions.refundDirect('YOUR_ORDER_ID OR TRANSACTION_ID',param)\n```\n\n## 3. Handling Error / Exception\nWhen using function that result in Midtrans API call e.g: `core.charge(...)` or `snap.create_transaction(...)`\nthere's a chance it may throw error (`MidtransAPIError` object), the error object will contains below properties that can be used as information to your error handling logic:\n```python\nerr = None\ntry:\n    transaction = snap.create_transaction(param)\nexcept Exception as e:\n    err = e\nerr.message\nerr.api_response_dict\nerr.http_status_code\nerr.raw_http_client_data\n```\n## 4. Advanced Usage\n\n### Custom Http Headers\n\nYou can set custom headers via the value of this `\u003capi-client-instance\u003e.api_config.custom_headers` dict, e.g:\n```python\n# Create Snap API instance\nsnap = midtransclient.Snap(\n    is_production=False,\n    server_key='YOUR_SERVER_KEY',\n    client_key='YOUR_CLIENT_KEY'\n)\n\n# set custom HTTP header for every request from this instance\nsnap.api_config.custom_headers = {\n    'my-custom-header':'my value',\n    'x-override-notification':'https://example.org',\n}\n```\n\n### Override/Append Http Notification Url\nAs [described in API docs](https://snap-docs.midtrans.com/#override-notification-url), merchant can opt to change or add custom notification urls on every transaction. It can be achieved by adding additional HTTP headers into charge request.\n\nThis can be achived by:\n```python\n# create instance of api client\nsnap = midtransclient.Snap(\n    is_production=False,\n    server_key='YOUR_SERVER_KEY',\n    client_key='YOUR_CLIENT_KEY'\n)\n# set custom HTTP header that will be used by Midtrans API to override notification url:\nsnap.api_config.custom_headers = {\n    'x-override-notification':'https://example.org',\n}\n```\n\nor append notification:\n```python\nsnap.api_config.custom_headers = {\n    'x-append-notification':'https://example.org',\n}\n```\n\n### Custom Http Proxy\n\nYou can set custom http(s) proxies via the value of this `\u003capi-client-instance\u003e.api_config.proxies` dict, e.g:\n\n```python\n# create instance of api client\nsnap = midtransclient.Snap(\n    is_production=False,\n    server_key='YOUR_SERVER_KEY',\n    client_key='YOUR_CLIENT_KEY'\n)\n\nsnap.api_config.proxies = {\n  'http': 'http://10.10.1.10:3128',\n  'https': 'http://10.10.1.10:1080',\n}\n```\n\nUnder the hood this API wrapper is using [Requests](https://github.com/requests/requests) as http client. You can further [learn about proxies on its documentation](https://requests.readthedocs.io/en/master/user/advanced/#proxies)\n\n## Examples\nExamples are available on [/examples](/examples) folder.\nThere are:\n- [Core Api examples](/examples/core_api)\n- [Subscription examples](/examples/subscription)\n- [Tokenization examples](/examples/tokenization)\n- [Snap examples](/examples/snap)\n- [Flask App examples](/examples/flask_app) that implement Snap \u0026 Core Api\n\n## Important Changes\n### v1.3.0\n- **Drop support for Python 2** (because Python 2 has reached its end of life), in favor of better compatibility with Python 3 and to prevent package unable to be properly installed on Windows OS env.\n\n#### Get help\n\n* [Midtrans Docs](https://docs.midtrans.com)\n* [Midtrans Dashboard ](https://dashboard.midtrans.com/)\n* [SNAP documentation](http://snap-docs.midtrans.com)\n* [Core API documentation](http://api-docs.midtrans.com)\n* Can't find answer you looking for? email to [support@midtrans.com](mailto:support@midtrans.com)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmidtrans%2Fmidtrans-python-client","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmidtrans%2Fmidtrans-python-client","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmidtrans%2Fmidtrans-python-client/lists"}