{"id":49551389,"url":"https://github.com/irvaniamirali/payman","last_synced_at":"2026-05-02T22:43:30.115Z","repository":{"id":294016635,"uuid":"972519857","full_name":"irvaniamirali/payman","owner":"irvaniamirali","description":"A unified payment gateway SDK for Iranian gateways.","archived":false,"fork":false,"pushed_at":"2025-11-17T16:38:15.000Z","size":872,"stargazers_count":16,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2026-05-02T22:43:23.674Z","etag":null,"topics":["iran-payment","payment-gateway","payment-integration","python","zarinpal","zibal"],"latest_commit_sha":null,"homepage":"https://irvaniamirali.github.io/payman/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/irvaniamirali.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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-04-25T07:59:45.000Z","updated_at":"2026-04-19T10:09:20.000Z","dependencies_parsed_at":"2025-09-25T18:07:34.007Z","dependency_job_id":"5a957df6-6b75-45e8-9933-dff84a76c023","html_url":"https://github.com/irvaniamirali/payman","commit_stats":null,"previous_names":["irvaniamirali/parspay"],"tags_count":2,"template":false,"template_full_name":null,"purl":"pkg:github/irvaniamirali/payman","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/irvaniamirali%2Fpayman","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/irvaniamirali%2Fpayman/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/irvaniamirali%2Fpayman/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/irvaniamirali%2Fpayman/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/irvaniamirali","download_url":"https://codeload.github.com/irvaniamirali/payman/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/irvaniamirali%2Fpayman/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":32552377,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-02T22:28:24.418Z","status":"ssl_error","status_checked_at":"2026-05-02T22:28:14.225Z","response_time":132,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["iran-payment","payment-gateway","payment-integration","python","zarinpal","zibal"],"created_at":"2026-05-02T22:43:29.525Z","updated_at":"2026-05-02T22:43:30.107Z","avatar_url":"https://github.com/irvaniamirali.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Payman — Unified Payment Gateway Integration for Python\n\n**Payman** is a Python package for integrating with Iranian payment gateways like **ZarinPal** and **Zibal**.\nIt provides a clean and flexible interface for handling payments in async Python applications.\n\n## Key Features\n- **Simple and consistent API**  \n You can focus on your business logic — HTTP calls, serialization, and gateway-specific details are handled internally.\n\n- **Supports Async**  \n Compatible with asynchronous code, including FastAPI and background tasks.\n\n- **Pydantic models for inputs and outputs**  \n  Type-safe, auto-validating models make integration predictable and IDE-friendly.\n\n- **Modular and extensible design**  \n Each gateway integration is separated. You can include only what you need or extend the package with your own gateway.\n\n- **Unified error handling**  \n Common exception classes are used across gateways, with optional gateway-specific errors when needed.\n\n- **Suitable for real projects**  \n Designed to be usable in real applications, from small services to larger deployments.\n\n\n## Supported Payment Gateways (Currently)\n- [Zibal](https://zibal.ir/)\n- [ZarinPal](https://www.zarinpal.com/)\n- *More gateways will be added soon...*\n\n## Installation\n\n```bash\npip install -U payman[zibal]\n```\n\n## Quick Start: Async Zibal Integration (Create, Redirect, Verify)\n\n```python\nimport asyncio\n\nfrom payman import Payman\n\ngateway = Payman(\"zibal\", merchant_id=\"abc\")\n\nasync def main():\n    payment_request = await gateway.initiate_payment(\n        amount=10_000,\n        callback_url=\"https://your-site.com/callback\",\n        description=\"Test payment\"\n    )\n\n    if not payment_request.success:\n        print(f\"Payment creation failed: {payment_request.message}\")\n        return\n\n    print(\"Redirect user to:\", gateway.get_payment_redirect_url(payment_request.track_id))\n\n    payment_verification = await gateway.verify_payment(track_id=payment_request.track_id)\n\n    if payment_verification.success:\n        print(\"Payment successful. Ref ID:\", payment_verification.ref_id)\n    elif payment_verification.already_verified:\n        print(\"Payment already verified.\")\n    else:\n        print(\"Payment verification failed.\")\n\nasyncio.run(main())\n```\n\n## Full Documentation\nFor detailed instructions on using Zibal and other gateways with Payman, including all parameters, response codes, and integration tips, please refer to the complete guide:\n- [documentation](https://irvaniamirali.github.io/payman)\n\n\n## License\n\nLicensed under the GNU General Public License v3.0 (GPL-3.0). See the LICENSE file for details.\n\n## Contributing\n\nContributions to Payman are welcome and highly appreciated. If you wish to contribute, please follow these guidelines:\n\n- Fork the repository and create a new branch for your feature or bugfix.  \n- Ensure your code adheres to the project's coding standards and passes all tests.  \n- Write clear, concise commit messages and provide documentation for new features.  \n- Submit a pull request with a detailed description of your changes for review.\n\nBy contributing, you agree that your work will be licensed under the project's license.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Firvaniamirali%2Fpayman","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Firvaniamirali%2Fpayman","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Firvaniamirali%2Fpayman/lists"}