forked from finlabsuk/open-banking-connector
-
Notifications
You must be signed in to change notification settings - Fork 0
chore: sync fork with upstream master #4
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Dan Jake Neal (DanJakeNeal)
merged 11 commits into
master
from
chore/sync-upstream-master
Jul 27, 2026
Merged
Changes from all commits
Commits
Show all changes
11 commits
Select commit
Hold shift + click to select a range
4e9afbe
Upgrade to .NET 10
markm77 f6ac7f9
Update HSBC
markm77 f48bf5d
Remove support for SQLite
markm77 fc13e04
Extend DomesticVrpRefundConverter to support v4.0 API
markm77 04bc206
Update NatWest sandboxes
markm77 1de29ed
[DCR] Accept single-value array for certain fields
markm77 f366501
Update Tide
markm77 9b5162f
Update Coutts
markm77 7ce65a0
[Docs] Update docs
markm77 46808d5
Update Dockerfile for .NET 10
markm77 212220c
chore: merge upstream/master to sync fork
DanJakeNeal File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
43 changes: 43 additions & 0 deletions
43
src/OpenBanking.Library.BankApiModels/Json/SingleOrArrayConverter.cs
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,43 @@ | ||
| // Licensed to Finnovation Labs Limited under one or more agreements. | ||
| // Finnovation Labs Limited licenses this file to you under the MIT license. | ||
| // See the LICENSE file in the project root for more information. | ||
|
|
||
| using System; | ||
| using Newtonsoft.Json; | ||
| using Newtonsoft.Json.Linq; | ||
|
|
||
| namespace FinnovationLabs.OpenBanking.Library.BankApiModels.Json; | ||
|
|
||
| /// <summary> | ||
| /// Custom converter for deserialising a field that may be returned either as a single value or as a JSON array containing a single value. | ||
| /// </summary> | ||
| public class SingleOrArrayConverter<T> : JsonConverter | ||
| { | ||
| public override bool CanConvert(Type objectType) => true; | ||
|
|
||
| public override object? ReadJson( | ||
| JsonReader reader, | ||
| Type objectType, | ||
| object? existingValue, | ||
| JsonSerializer serializer) | ||
| { | ||
| JToken token = JToken.Load(reader); | ||
| if (token.Type == JTokenType.Array) | ||
| { | ||
| var array = (JArray) token; | ||
| if (array.Count != 1) | ||
| { | ||
| throw new JsonSerializationException( | ||
| $"We can accept JSON array with exactly one element when deserialising {typeof(T).Name}, but received array with {array.Count} elements."); | ||
| } | ||
| return array[0].ToObject<T>(serializer); | ||
| } | ||
|
|
||
| return token.ToObject<T>(serializer); | ||
| } | ||
|
|
||
| public override void WriteJson(JsonWriter writer, object? value, JsonSerializer serializer) | ||
| { | ||
| serializer.Serialize(writer, value); | ||
| } | ||
| } | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
2 changes: 1 addition & 1 deletion
2
src/OpenBanking.Library.Connector.Web/OpenBanking.Library.Connector.Web.csproj
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.