ShurjopayPlugin 0.1.1
dotnet add package ShurjopayPlugin --version 0.1.1
NuGet\Install-Package ShurjopayPlugin -Version 0.1.1
<PackageReference Include="ShurjopayPlugin" Version="0.1.1" />
<PackageVersion Include="ShurjopayPlugin" Version="0.1.1" />
<PackageReference Include="ShurjopayPlugin" />
paket add ShurjopayPlugin --version 0.1.1
#r "nuget: ShurjopayPlugin, 0.1.1"
#addin nuget:?package=ShurjopayPlugin&version=0.1.1
#tool nuget:?package=ShurjopayPlugin&version=0.1.1
shurjoPay .NET Package (plugin)
Official shurjoPay .net package (plugin) for merchants or service providers to connect with shurjoPay Payment Gateway v2.1 developed and maintained by shurjoMukhi Limited.
This plugin package can be used with .NET Standert 2.1 applications (e.g. .NET Core - MVC, Web API etc.).
This plugin package makes it easy for you to integrate with shurjoPay v2.1 with just three method calls:
- MakePayment()
- VerifyPayment()
- CheckPayemnt()
Also reduces many of the things that you had to do manually
- Handles http request and errors
- JSON serialization and deserialization
- Authentication during checkout and verification of payments
Audience
This document is intended for the developers and technical personnel of merchants and service providers who want to integrate the shurjoPay online payment gateway using .net framework.
How to use this shurjoPay Plugin
Use
Package Manager
to install this plugin inside your project environment.
Install-Package ShurjopayPlugin
Add Shurjopay Configuration to your project's user secrets Here is a sample user-secrects configuration.
"Shurjopay": {
"SP_USERNAME": "sp_sandbox",
"SP_PASSWORD": "pyyk97hu&6u6",
"SP_CALLBACK": "https://www.sandbox.shurjopayment.com/response",
"SP_ENDPOINT": "https://sandbox.shurjopayment.com/api/"
"SP_PREFIX": "sp-dotnet"
}
Add the Configuration in Program.cs file.
// Shurjopay Secrets
builder.Services.Configure<ShurjopayConfig>(builder.Configuration.GetSection("Shurjopay"));
Instantiate ShurjopayPlugin with Shurjopay Configuration and Logger
private readonly ILogger<ShurjopayPlugin> _logger;
public ShurjopayPlugin _ShurjopayPlugin;
public ShurjopayController(IOptions<ShurjopayConfig> options, ILogger<ShurjopayPlugin> logger)
{
_ShurjopayPlugin = new ShurjopayPlugin(options.Value,logger);
_logger = logger;
}
Sample Payment Request Object
PaymentRequest paymentRequest = new PaymentRequest();
paymentRequest.Amount = 10;
paymentRequest.Prefix = "sp-dotnet";
paymentRequest.OrderID= "sp-dotnet-6.00";
paymentRequest.Currency= "BDT";
paymentRequest.CustomerName= "Mahabubul";
paymentRequest.CustomerAddress= "Haque Tower,Mohakhali";
paymentRequest.CustomerCity= "Dhaka";
paymentRequest.CustomerPhone = "01311310975";
paymentRequest.CustomerPostCode = "1229";
Make Payment Request
Task<PaymentDetails?> paymentDetailsTask = _ShurjopayPlugin.MakePayment(paymentRequest);
PaymentDetails? paymentDetails = paymentDetailsTask.Result;
return Redirect(paymentDetails.CheckOutUrl);
Payment verification can be done after each transaction with shurjopay order id.
Task<VerifiedPayment?> TVerfiedPayment = _ShurjopayPlugin.VerifyPayment(order_id);
VerifiedPayment? verifiedPayment = TVerfiedPayment.Result;
That's all! Now you are ready to use the python plugin to seamlessly integrate with shurjoPay to make your payment system easy and smooth.
References
- .Net Core Web MVC example application showing usage of the .Net plugin.
- Sample applications and projects in many different languages and frameworks showing shurjopay integration.
- shurjoPay Postman site illustrating the request and response flow using the sandbox system.
- shurjopay Plugins home page on github
License
This code is under the MIT open source License.
Please contact with shurjoPay team for more detail.
Copyright ©️2022 ShurjoMukhi Limited
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net5.0 was computed. net5.0-windows was computed. net6.0 was computed. net6.0-android was computed. net6.0-ios was computed. net6.0-maccatalyst was computed. net6.0-macos was computed. net6.0-tvos was computed. net6.0-windows was computed. net7.0 was computed. net7.0-android was computed. net7.0-ios was computed. net7.0-maccatalyst was computed. net7.0-macos was computed. net7.0-tvos was computed. net7.0-windows was computed. net8.0 was computed. net8.0-android was computed. net8.0-browser was computed. net8.0-ios was computed. net8.0-maccatalyst was computed. net8.0-macos was computed. net8.0-tvos was computed. net8.0-windows was computed. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. |
.NET Core | netcoreapp3.0 was computed. netcoreapp3.1 was computed. |
.NET Standard | netstandard2.1 is compatible. |
MonoAndroid | monoandroid was computed. |
MonoMac | monomac was computed. |
MonoTouch | monotouch was computed. |
Tizen | tizen60 was computed. |
Xamarin.iOS | xamarinios was computed. |
Xamarin.Mac | xamarinmac was computed. |
Xamarin.TVOS | xamarintvos was computed. |
Xamarin.WatchOS | xamarinwatchos was computed. |
-
.NETStandard 2.1
- Microsoft.Extensions.Logging.Abstractions (>= 7.0.0)
- NuGet.CommandLine (>= 2.8.6)
- System.Text.Json (>= 7.0.0)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.