Skip to content

Commit

Permalink
fix(Connectors & Webhook): add new types to Connector, add eventId
Browse files Browse the repository at this point in the history
…to Webhook model and deprecate `id` field. (#16)

* fix(ConnectorType): add new types.

* fix(Webhook): add eventId and deprecate id.

* fix.

* fix(PluggyClient): reference local pluggy-sdk.

* fix(Webhook): change isError flag to false in Obsolete.

---------

Co-authored-by: NicolasMontone <[email protected]>
  • Loading branch information
sebipap and NicolasMontone authored May 2, 2023
1 parent b6afc94 commit 2225c4e
Show file tree
Hide file tree
Showing 4 changed files with 13 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Pluggy.Client/Pluggy.Client.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<PackageReference Include="Microsoft.Extensions.Configuration.FileExtensions" Version="3.1.7" />
<PackageReference Include="Microsoft.Extensions.Configuration.Json" Version="3.1.7" />
<PackageReference Include="Newtonsoft.Json" Version="13.0.1" />
<PackageReference Include="Pluggy.SDK" Version="0.13.0" />
<ProjectReference Include="..\Pluggy.SDK\Pluggy.SDK.csproj" />
</ItemGroup>
<ItemGroup>
<None Update="appsettings.json">
Expand Down
5 changes: 4 additions & 1 deletion Pluggy.Client/Program.cs
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,10 @@ private static async Task CreateItem(SDK.PluggyAPI sdk)
Types = new List<ConnectorType> {
ConnectorType.PERSONAL_BANK,
ConnectorType.BUSINESS_BANK,
ConnectorType.INVESTMENT
ConnectorType.INVESTMENT,
ConnectorType.INVOICE,
ConnectorType.TELECOMMUNICATION,
ConnectorType.OTHER
},
Name = "",
Sandbox = true
Expand Down
5 changes: 4 additions & 1 deletion Pluggy.SDK/Model/ConnectorType.cs
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@ public enum ConnectorType
{
PERSONAL_BANK,
BUSINESS_BANK,
INVESTMENT
INVESTMENT,
INVOICE,
TELECOMMUNICATION,
OTHER,
}
}
4 changes: 4 additions & 0 deletions Pluggy.SDK/Model/Webhook.cs
Original file line number Diff line number Diff line change
Expand Up @@ -51,9 +51,13 @@ public WebhookEvent Event

public class WebhookEventPayload
{
[Obsolete("Use EventId instead", false)]
[JsonProperty("id")]
public Guid Id { get; set; }

[JsonProperty("eventId")]
public Guid EventId { get; set; }

[JsonProperty("itemId")]
public Guid ItemId { get; set; }

Expand Down

0 comments on commit 2225c4e

Please sign in to comment.