Skip to content

Commit

Permalink
Merge pull request #45 from gocardless/template-changes
Browse files Browse the repository at this point in the history
Changes from gocardless-dotnet-template
  • Loading branch information
paprikati authored Apr 8, 2020
2 parents 83b0fe8 + 8064e3f commit 08ed286
Show file tree
Hide file tree
Showing 4 changed files with 26 additions and 5 deletions.
4 changes: 2 additions & 2 deletions GoCardless/GoCardless.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<PackageId>GoCardless</PackageId>
<PackageVersion>3.5.1</PackageVersion>
<PackageVersion>3.5.2</PackageVersion>
<Authors>GoCardless Ltd</Authors>
<Description>Client for the GoCardless API - a powerful, simple solution for the collection of recurring bank-to-bank payments</Description>
<PackageRequireLicenseAcceptance>false</PackageRequireLicenseAcceptance>
Expand All @@ -11,7 +11,7 @@
<Copyright>GoCardless Ltd</Copyright>
<PackageTags>gocardless payments rest api direct debit</PackageTags>
<PackageLicenseUrl>https://github.com/gocardless/gocardless-dotnet/blob/master/LICENSE.txt</PackageLicenseUrl>
<PackageReleaseNotes>https://github.com/gocardless/gocardless-dotnet/releases/tag/v3.5.1</PackageReleaseNotes>
<PackageReleaseNotes>https://github.com/gocardless/gocardless-dotnet/releases/tag/v3.5.2</PackageReleaseNotes>
<TargetFrameworks>netstandard1.6;netstandard2.0;net46</TargetFrameworks>
<GeneratePackageOnBuild>True</GeneratePackageOnBuild>
<GenerateDocumentationFile>true</GenerateDocumentationFile>
Expand Down
4 changes: 2 additions & 2 deletions GoCardless/GoCardlessClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -252,9 +252,9 @@ private HttpRequestMessage BuildHttpRequestMessage<T>(string method, string path
var httpMethod = new HttpMethod(method);

var requestMessage = new HttpRequestMessage(httpMethod, new Uri(_baseUrl, path));
requestMessage.Headers.Add("User-Agent", "gocardless-dotnet/3.5.1");
requestMessage.Headers.Add("User-Agent", "gocardless-dotnet/3.5.2");
requestMessage.Headers.Add("GoCardless-Version", "2015-07-06");
requestMessage.Headers.Add("GoCardless-Client-Version", "3.5.1");
requestMessage.Headers.Add("GoCardless-Client-Version", "3.5.2");
requestMessage.Headers.Add("GoCardless-Client-Library", "gocardless-dotnet");
requestMessage.Headers.Authorization =
new System.Net.Http.Headers.AuthenticationHeaderValue("Bearer", _accessToken);
Expand Down
21 changes: 21 additions & 0 deletions GoCardless/Resources/Event.cs
Original file line number Diff line number Diff line change
Expand Up @@ -149,13 +149,27 @@ public enum EventCustomerNotificationType {

public class EventDetails
{
/// <summary>
/// When we send a creditor `new_payout_currency_added` webhook, we also
/// send the bank account id of the new account
/// </summary>
[JsonProperty("bank_account_id")]
public string BankAccountId { get; set; }

/// <summary>
/// What triggered the event. _Note:_ `cause` is our simplified and
/// predictable key indicating what triggered the event.
/// </summary>
[JsonProperty("cause")]
public string Cause { get; set; }

/// <summary>
/// When we send a creditor `new_payout_currency_added` webhook, we also
/// send the currency of the new account
/// </summary>
[JsonProperty("currency")]
public string Currency { get; set; }

/// <summary>
/// Human readable description of the cause. _Note:_ Changes to event
/// descriptions are not considered breaking.
Expand All @@ -176,6 +190,13 @@ public class EventDetails
[JsonProperty("origin")]
public EventDetailsOrigin? Origin { get; set; }

/// <summary>
/// When we send a creditor `creditor_updated` webhook, this tells you
/// which property on the creditor has been updated
/// </summary>
[JsonProperty("property")]
public string Property { get; set; }

/// <summary>
/// Set when a `bank` is the origin of the event. This is the reason
/// code received in the report from the customer's bank. See the
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ For full details of the GoCardless API, see the [API docs](https://developer.goc

To install `GoCardless`, run the following command in the [Package Manager Console](https://docs.microsoft.com/en-us/nuget/tools/package-manager-console)

`Install-Package GoCardless -Version 3.5.1`
`Install-Package GoCardless -Version 3.5.2`


## Usage
Expand Down

0 comments on commit 08ed286

Please sign in to comment.