scanpay 0.1.4
There is a newer version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package scanpay --version 0.1.4
NuGet\Install-Package scanpay -Version 0.1.4
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="scanpay" Version="0.1.4" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add scanpay --version 0.1.4
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: scanpay, 0.1.4"
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install scanpay as a Cake Addin
#addin nuget:?package=scanpay&version=0.1.4
// Install scanpay as a Cake Tool
#tool nuget:?package=scanpay&version=0.1.4
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
Scanpay .NET library
Documentation
See the docs.
Installation
From the command line:
$ nuget install scanpay
Usage
Define a Scanpay client:
var apikey = "1089:bx2a4DATi8ad87Nm4uaxg5nggYA8J/Hv99CON977YiEdvYa6DmMwdoRPoYWyBJSi";
var client = new Scanpay.Client(apikey);
New Payment Link
Create a payment link to which you can redirect customers.
var data = new Scanpay.NewURLReq
{
orderid = "999",
items = new Scanpay.Item[]
{
new Scanpay.Item
{
name = "Ultra Bike 7000",
total = "1337.01 DKK",
quantity = 2,
},
}
};
var url = client.newURL(data);
Console.WriteLine("Payment URL is " + url);
Seq Request
Get an array with a number of changes since the supplied sequence number:
var oldSeq = 3
var seqRes = client.seq(oldSeq);
foreach(var change in seqRes.changes)
{
// Update your database with change...
}
Console.WriteLine("New seq number is " + seqRes.seq);
Handle Pings
Verify the ping signature and extract the seq number.
var ping = client.handlePing(body, request.Headers["X-Signature"]);
Console.WriteLine("Ping seq=" + ping.seq + ", shopid=" + ping.shopid);
See the tests/ folder for more advanced examples.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET Framework | net40 is compatible. net403 was computed. net45 is compatible. net451 was computed. net452 was computed. net46 was computed. net461 was computed. net462 was computed. net463 was computed. net47 was computed. net471 was computed. net472 was computed. net48 was computed. net481 was computed. |
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
-
- Newtonsoft.Json (>= 10.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.
Initial release.