{"id":22122598,"url":"https://github.com/thorgate/django-thorbanks","last_synced_at":"2025-07-29T13:10:41.357Z","repository":{"id":19515330,"uuid":"22762222","full_name":"thorgate/django-thorbanks","owner":"thorgate","description":"Django application for Estonian banklinks","archived":false,"fork":false,"pushed_at":"2024-01-03T09:51:41.000Z","size":368,"stargazers_count":6,"open_issues_count":4,"forks_count":4,"subscribers_count":20,"default_branch":"main","last_synced_at":"2025-07-25T19:04:55.509Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/thorgate.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":"2014-08-08T15:24:47.000Z","updated_at":"2023-03-30T11:16:21.000Z","dependencies_parsed_at":"2024-12-01T15:40:08.067Z","dependency_job_id":null,"html_url":"https://github.com/thorgate/django-thorbanks","commit_stats":{"total_commits":83,"total_committers":7,"mean_commits":"11.857142857142858","dds":"0.32530120481927716","last_synced_commit":"54335137790bb76e9be77738bd8adcb3d085cabc"},"previous_names":[],"tags_count":21,"template":false,"template_full_name":null,"purl":"pkg:github/thorgate/django-thorbanks","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thorgate%2Fdjango-thorbanks","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thorgate%2Fdjango-thorbanks/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thorgate%2Fdjango-thorbanks/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thorgate%2Fdjango-thorbanks/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thorgate","download_url":"https://codeload.github.com/thorgate/django-thorbanks/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thorgate%2Fdjango-thorbanks/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267693160,"owners_count":24129131,"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-07-29T02:00:12.549Z","response_time":2574,"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":[],"created_at":"2024-12-01T15:26:37.973Z","updated_at":"2025-07-29T13:10:41.304Z","avatar_url":"https://github.com/thorgate.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# django-thorbanks\n\n[![Build Status](https://travis-ci.org/thorgate/django-thorbanks.svg?branch=master)](https://travis-ci.org/thorgate/django-thorbanks)\n[![Coverage Status](https://coveralls.io/repos/github/thorgate/django-thorbanks/badge.svg?branch=master)](https://coveralls.io/github/thorgate/django-thorbanks?branch=master)\n[![PyPI release](https://badge.fury.io/py/django-thorbanks.png)](https://badge.fury.io/py/django-thorbanks)\n\n\nDjango app for integrating Estonian banklinks into your project.\n\n## Features\n\nBank            | Protocol    | Authentication      | Payment\n--------------- | ----------- | ------------------- | -------\nSwedbank        | iPizza      | :heavy_check_mark:  | :heavy_check_mark:\nSEB             | iPizza      | :heavy_check_mark:  | :heavy_check_mark:\nDanske          | iPizza      | :heavy_check_mark:  | :heavy_check_mark:\nLHV             | iPizza      | :heavy_check_mark:  | :heavy_check_mark:\nKrediidipank    | iPizza      | :heavy_check_mark:  | :heavy_check_mark:\nNordea          | iPizza      | :heavy_check_mark:  | :heavy_check_mark:\n\n## Usage\n\n### 1. Install it:\n\n**Pip:**\n\n```bash\npip install django-thorbanks\n```\n\n**Pipenv:**\n\n```bash\npipenv install django-thorbanks\n```\n\n**Poetry:**\n\n```bash\npoetry add django-thorbanks\n```\n\n### 2. Add to installed apps\n\n```python\nINSTALLED_APPS = (\n    # Add the following apps:\n    \"thorbanks\",\n    \"thorbanks_models\",\n)\n```\n\n### 3. Configure and create migrations:\n\n**With MANUAL_MODELS:**\n\n- Remove `\"thorbanks_models\"` from `INSTALLED_APPS`\n- follow instructions from [thorbanks.settings.get_model](./thorbanks/settings.py#L59).\n\n**With default models:**\n\nMake django aware that thorbanks migrations are in your local apps folder via settings.MIGRATION_MODULES:\n\n\u003e Note: Replace `shop` with the name of an existing app in your project.\n\n```python\n# Tell django that thorbanks_models migrations are in shop app (in thorbanks_migrations module)\nMIGRATION_MODULES = {\"thorbanks_models\": \"shop.thorbanks_migrations\"}\n```\n\nNow run `makemigrations thorbanks_models` and `migrate` management commands to create and apply the migrations.\n\n### 4. Add settings.BANKLINKS\n\nFor a working example see the definitions in [example/settings.py](example/settings.py).\n\n\u003e Note:\n\u003eYou will need a public and private key for each bank integration.\n\u003eIn case you don't have the public key, you can generate one out of a certificate by:\n\u003e```\n\u003eopenssl x509 -pubkey -noout -in cert.pem  \u003e pubkey.pem\n\u003e```\n\n### 5. Link Transaction to your Order model\n\n\u003e Note: When using MANUAL_MODELS replace `thorbanks_models` with your local app name\n\n```python\nclass Order(models.Model):\n    # ... other fields\n    transaction = models.OneToOneField(\n        \"thorbanks_models.Transaction\", null=True, on_delete=models.SET_NULL\n    )\n```\n\n### 6. Include thorbanks urls\n\n```python\nurlpatterns = [\n    # This is where the user will be redirected after returning from the banklink page\n    url(r\"^banks/\", include(\"thorbanks.urls\")),\n]\n```\n\n### 7. Add listeners to banklinks success \u0026 failure callbacks:\n\nSee [example.shop.models.banklink_success_callback](example/shop/models.py#L23) and [example.shop.models.banklink_failed_callback](example/shop/models.py#L44).\n\n### 8. Create views and forms for payments:\n\nsee [example.shop.views](example/shop/views.py) and [example.shop.forms](example/shop/forms.py).\n\n## iPizza protocol\n\n- [Test service](https://banks.pastel.thorgate.eu/et/info)\n- [Swedbank](https://www.swedbank.ee/business/cash/ecommerce/ecommerce?language=EST)\n    - [Spec](https://www.swedbank.ee/static/pdf/business/d2d/paymentcollection/Pangalingi_paringute_tehniline_spetsifikatsioon_09_10_2014.pdf)\n- [SEB](https://www.seb.ee/ariklient/igapaevapangandus/pangalink)\n- [LHV Bank](https://www.lhv.ee/pangateenused/pangalink/)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthorgate%2Fdjango-thorbanks","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthorgate%2Fdjango-thorbanks","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthorgate%2Fdjango-thorbanks/lists"}