Skip to content

Commit

Permalink
Release 4.1.2
Browse files Browse the repository at this point in the history
  • Loading branch information
sauliususoniswallee committed Sep 2, 2022
1 parent 49f6e84 commit b0e91ae
Show file tree
Hide file tree
Showing 4 changed files with 25 additions and 13 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,13 @@ NOTE: RestSharp versions greater than 106.2.1 have a bug which causes file uploa
## Installation
```
# Package Manager
Install-Package Wallee -Version 4.1.1
Install-Package Wallee -Version 4.1.2
# .NET CLI
dotnet add package Wallee --version 4.1.1
dotnet add package Wallee --version 4.1.2
# Paket CLI
paket add Wallee --version 4.1.1
paket add Wallee --version 4.1.2
# PackageReference
<PackageReference Include="Wallee" Version="4.1.1" />
<PackageReference Include="Wallee" Version="4.1.2" />
```

Then include the DLL (under the `bin` folder) in the C# project, and use the namespaces:
Expand Down
16 changes: 14 additions & 2 deletions src/Wallee/Client/ApiClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ public ApiClient(String basePath = "https://app-wallee.com:443/api")
// Creates and sets up a RestRequest prior to a call.
private RestRequest PrepareRequest(
String path, RestSharp.Method method, List<KeyValuePair<String, String>> queryParams, Object postBody,
Dictionary<String, String> headerParams, Dictionary<String, String> formParams,
Dictionary<String, String> headerParams, Dictionary<String, String> defaultHeaderParams, Dictionary<String, String> formParams,
Dictionary<String, FileParameter> fileParams, Dictionary<String, String> pathParams,
String contentType)
{
Expand All @@ -104,6 +104,10 @@ private RestRequest PrepareRequest(
foreach(var param in headerParams)
request.AddHeader(param.Key, param.Value);

// add default header parameters
foreach(var param in defaultHeaderParams)
request.AddHeader(param.Key, param.Value);

// add authentication headers
foreach (var param in AuthenticationHeaders(method, path, queryParams))
request.AddHeader(param.Key, param.Value);
Expand Down Expand Up @@ -149,8 +153,16 @@ public Object CallApi(
Dictionary<String, FileParameter> fileParams, Dictionary<String, String> pathParams,
String contentType)
{

Dictionary<String, String> defaultHeaderParams = new Dictionary<String, String>() {
{"x-meta-sdk-version", "4.1.2"},
{"x-meta-sdk-language", "csharp"},
{"x-meta-sdk-provider", "wallee"},
{"x-meta-sdk-language-version", Environment.Version.ToString()}
};

var request = PrepareRequest(
path, method, queryParams, postBody, headerParams, formParams, fileParams,
path, method, queryParams, postBody, headerParams, defaultHeaderParams, formParams, fileParams,
pathParams, contentType);

// set user agent
Expand Down
8 changes: 4 additions & 4 deletions src/Wallee/Client/Configuration.cs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ public class Configuration : IReadableConfiguration
/// Version of the package.
/// </summary>
/// <value>Version of the package.</value>
public const string Version = "4.1.1";
public const string Version = "4.1.2";

/// <summary>
/// Identifier for ISO 8601 DateTime Format
Expand Down Expand Up @@ -90,7 +90,7 @@ public Configuration(string applicationUserID, string authenticationKey)
}
_authenticationKey = authenticationKey;
_applicationUserID = applicationUserID;
UserAgent = "Wallee/4.1.1/csharp";
UserAgent = "Wallee/4.1.2/csharp";
BasePath = "https://app-wallee.com:443/api";
DefaultHeader = new ConcurrentDictionary<string, string>();
ApiKey = new ConcurrentDictionary<string, string>();
Expand Down Expand Up @@ -338,8 +338,8 @@ public static String ToDebugReport()
String report = "C# SDK (Wallee) Debug Report:\n";
report += " OS: " + System.Environment.OSVersion + "\n";
report += " .NET Framework Version: " + System.Environment.Version + "\n";
report += " Version of the API: 4.1.1\n";
report += " SDK Package Version: 4.1.1\n";
report += " Version of the API: 4.1.2\n";
report += " SDK Package Version: 4.1.2\n";

return report;
}
Expand Down
6 changes: 3 additions & 3 deletions src/Wallee/Wallee.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -20,12 +20,12 @@
<PackageId>Wallee</PackageId>
<PackageLicense>https://www.apache.org/licenses/LICENSE-2.0.txt</PackageLicense>
<PackageProjectUrl>https:/wallee-payment/csharp-sdk</PackageProjectUrl>
<PackageVersion>4.1.1</PackageVersion>
<Version>4.1.1</Version>
<PackageVersion>4.1.2</PackageVersion>
<Version>4.1.2</Version>
<PackageTags>Wallee;payment;sdk;Payment Integration</PackageTags>
<OutputType>Library</OutputType>
<Owners>customweb</Owners>
<ReleaseVersion>4.1.1</ReleaseVersion>
<ReleaseVersion>4.1.2</ReleaseVersion>
<RepositoryType>git</RepositoryType>
<RepositoryUrl>https:/wallee-payment/csharp-sdk.git</RepositoryUrl>
<RootNamespace>Wallee</RootNamespace>
Expand Down

0 comments on commit b0e91ae

Please sign in to comment.