{"id":27398772,"url":"https://github.com/imanx/zarinpal-dotnet","last_synced_at":"2025-09-09T08:39:03.487Z","repository":{"id":34047243,"uuid":"166964651","full_name":"ImanX/zarinpal-dotNet","owner":"ImanX","description":"ZarinPal .NET SDK Payment","archived":false,"fork":false,"pushed_at":"2022-12-08T06:23:18.000Z","size":89,"stargazers_count":6,"open_issues_count":6,"forks_count":4,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-08-24T10:31:26.894Z","etag":null,"topics":["csharp","dotnet","payment-gateway","zarinpal"],"latest_commit_sha":null,"homepage":null,"language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ImanX.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2019-01-22T09:20:57.000Z","updated_at":"2025-01-11T17:06:27.000Z","dependencies_parsed_at":"2023-01-15T04:12:10.660Z","dependency_job_id":null,"html_url":"https://github.com/ImanX/zarinpal-dotNet","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/ImanX/zarinpal-dotNet","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ImanX%2Fzarinpal-dotNet","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ImanX%2Fzarinpal-dotNet/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ImanX%2Fzarinpal-dotNet/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ImanX%2Fzarinpal-dotNet/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ImanX","download_url":"https://codeload.github.com/ImanX/zarinpal-dotNet/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ImanX%2Fzarinpal-dotNet/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":274268378,"owners_count":25253389,"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-09-09T02:00:10.223Z","response_time":80,"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":["csharp","dotnet","payment-gateway","zarinpal"],"created_at":"2025-04-14T01:48:42.447Z","updated_at":"2025-09-09T08:39:03.458Z","avatar_url":"https://github.com/ImanX.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"# ZarinPal .NET SDK \n\n\n### Getting Started\nOpen your project and go to `nuget` then search `Zarinpal` when found it install library.\n\n### Requirement\n4.5.1 .NET framework is Require\n\n### Example in Payment Request Page:\n```C#\n           ZarinPal.ZarinPal zarinpal = ZarinPal.ZarinPal.Get();\n\n         String MerchantID = \"71c705f8-bd37-11e6-aa0c-000c295eb8fc\";\n         String CallbackURL = \"http://localhost:59701/VerficationPage.aspx\";\n         long Amount = 100;\n         String Description = \"This is Test Payment\";\n\n         ZarinPal.PaymentRequest pr = new ZarinPal.PaymentRequest(MerchantID, Amount, CallbackURL, Description);\n\n         zarinpal.EnableSandboxMode();\n         var res = zarinpal.InvokePaymentRequest(pr);\n         if (res.Status == 100) {\n             Response.Redirect(res.PaymentURL);\n         }\n          \n```\n\n\n### Example in Payment Verification Page: \n\n```C#\n\n            var collection = HttpUtility.ParseQueryString(this.ClientQueryString);\n            String Status = collection[\"Status\"];\n\n            if (Status != \"OK\")\n            {\n                Response.Write(\"\u003cscript\u003ealert('Purchase unsuccessfully')\u003c/script\u003e\");\n                return;\n            }\n\n            var zarinpal = ZarinPal.ZarinPal.Get();\n\n            String Authority = collection[\"Authority\"];\n            String MerchantID = \"71c705f8-bd37-11e6-aa0c-000c295eb8fc\";\n            long Amount = 100;\n\n            var pv = new ZarinPal.PaymentVerification(MerchantID, Amount, Authority);\n            var verificationResponse = zarinpal.InvokePaymentVerification(pv);\n            if (verificationResponse.Status == 100)\n            {\n                Response.Write(String.Format(\"\u003cscript\u003ealert('Purchase successfully with ref transaction {0}')\u003c/script\u003e\", verificationResponse.RefID));\n            }\n            else {\n\n                Response.Write(String.Format(\"\u003cscript\u003ealert('Purchase unsuccessfully Error code is: {0}')\u003c/script\u003e\",verificationResponse.Status));\n\n            }\n          \n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fimanx%2Fzarinpal-dotnet","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fimanx%2Fzarinpal-dotnet","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fimanx%2Fzarinpal-dotnet/lists"}