You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
*[Integrating with OpenAPI Generator API Client Libraries](#integrating-with-openapi-generator-api-client-libraries)
21
22
22
23
## Overview <aname="overview"></a>
23
-
Zero dependency library for generating a Mastercard API compliant OAuth signature.
24
+
*`OAuth1Signer.Core` is a zero dependency library for generating a Mastercard API compliant OAuth signature
25
+
*`OAuth1Signer.RestSharpV2` is an extension dedicated to [RestSharp](https://restsharp.dev/)
26
+
*`OAuth1Signer.RestSharp` is an extension dedicated to [RestSharp Portable](https://github.com/FubarDevelopment/restsharp.portable) (project no longer maintained)
24
27
25
28
### Compatibility <aname="compatibility"></a>
26
29
27
30
#### .NET <aname="net"></a>
28
-
This library requires a .NET Framework implementing [.NET Standard](https://docs.microsoft.com/en-us/dotnet/standard/net-standard) 1.3.
31
+
*`OAuth1Signer.Core` and `OAuth1Signer.RestSharp` require a .NET Framework implementing [.NET Standard](https://docs.microsoft.com/en-us/dotnet/standard/net-standard) 1.3.
32
+
*`OAuth1Signer.RestSharpV2` requires a .NET Framework implementing [.NET Standard](https://docs.microsoft.com/en-us/dotnet/standard/net-standard) 2.0.
29
33
30
34
#### Strong Naming <aname="strong-naming"></a>
31
35
Assemblies are strong-named as per [Strong naming and .NET libraries](https://docs.microsoft.com/en-us/dotnet/standard/library-guidance/strong-naming).
@@ -44,18 +48,15 @@ As part of this set up, you'll receive credentials for your app:
44
48
* A consumer key (displayed on the Mastercard Developer Portal)
45
49
* A private request signing key (matching the public certificate displayed on the Mastercard Developer Portal)
46
50
47
-
### Adding the Libraries to Your Project <aname="adding-the-libraries-to-your-project"></a>
48
-
51
+
### Adding the Libraries to Your Project <aname="adding-the-libraries-to-your-project"></a>
### Loading the Signing Key <aname="loading-the-signing-key"></a>
@@ -69,7 +70,7 @@ var signingKey = AuthenticationUtils.LoadSigningKey(
69
70
```
70
71
71
72
### Creating the OAuth Authorization Header <aname="creating-the-oauth-authorization-header"></a>
72
-
The method that does all the heavy lifting is `OAuth.GetAuthorizationHeader`, in the `Mastercard.Developer.OAuth1Signer.Core` package.
73
+
The method that does all the heavy lifting is `OAuth.GetAuthorizationHeader`, in the `OAuth1Signer.Core` package.
73
74
You can call into it directly and as long as you provide the correct parameters, it will return a string that you can add into your request's `Authorization` header.
74
75
75
76
```cs
@@ -90,11 +91,11 @@ These classes will modify the provided request object in-place and will add the
90
91
Usage briefly described below, but you can also refer to the test project for examples.
The `RestSharpSigner` classislocatedinthe `Mastercard.Developer.OAuth1Signer.RestSharp` package.
126
+
A `RestSharpSigner` classisprovidedforbothRestSharpandRestSharpPortable. Itcanbefoundinthe `OAuth1Signer.RestSharp` and `OAuth1Signer.RestSharpV2` packages.
126
127
127
128
Usage:
128
129
```cs
@@ -148,28 +149,75 @@ It provides generators and library templates for supporting multiple languages a
0 commit comments