Skip to content

Commit d1db869

Browse files
committed
#5 Add missing endpoint and fields
1 parent 8d92eb3 commit d1db869

File tree

3 files changed

+58
-0
lines changed

3 files changed

+58
-0
lines changed

BunqSdk/Model/Generated/Card.cs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,8 @@ public class Card : BunqModel
2424
public const string FIELD_MAG_STRIPE_PERMISSION = "mag_stripe_permission";
2525
public const string FIELD_COUNTRY_PERMISSION = "country_permission";
2626
public const string FIELD_MONETARY_ACCOUNT_CURRENT_ID = "monetary_account_current_id";
27+
public const string FIELD_PIN_CODE_ASSIGNMENT = "pin_code_assignment";
28+
public const string FIELD_MONETARY_ACCOUNT_ID_FALLBACK = "monetary_account_id_fallback";
2729

2830
/// <summary>
2931
/// Endpoint constants.
@@ -130,6 +132,12 @@ public class Card : BunqModel
130132
[JsonProperty(PropertyName = "label_monetary_account_current")]
131133
public MonetaryAccountReference LabelMonetaryAccountCurrent { get; private set; }
132134

135+
/// <summary>
136+
/// Array of Types, PINs, account IDs assigned to the card.
137+
/// </summary>
138+
[JsonProperty(PropertyName = "pin_code_assignment")]
139+
public CardPinAssignment PinCodeAssignment { get; private set; }
140+
133141
public static BunqResponse<Card> Update(ApiContext apiContext, IDictionary<string, object> requestMap,
134142
int userId, int cardId)
135143
{
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
using Newtonsoft.Json;
2+
3+
namespace Bunq.Sdk.Model.Generated.Object
4+
{
5+
/// <summary>
6+
/// </summary>
7+
public class CardPinAssignment : BunqModel
8+
{
9+
/// <summary>
10+
/// PIN type. Can be PRIMARY, SECONDARY or TERTIARY
11+
/// </summary>
12+
[JsonProperty(PropertyName = "type")]
13+
public string Type { get; set; }
14+
15+
/// <summary>
16+
/// The 4 digit PIN to be assigned to this account.
17+
/// </summary>
18+
[JsonProperty(PropertyName = "pin_code")]
19+
public string PinCode { get; set; }
20+
21+
/// <summary>
22+
/// The ID of the monetary account to assign to this pin for the card.
23+
/// </summary>
24+
[JsonProperty(PropertyName = "monetary_account_id")]
25+
public string MonetaryAccountId { get; set; }
26+
27+
public CardPinAssignment(string type)
28+
{
29+
Type = type;
30+
}
31+
}
32+
}

BunqSdk/Model/Generated/UserCredentialPasswordIp.cs

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,24 @@ public class UserCredentialPasswordIp : BunqModel
2323
/// </summary>
2424
private const string OBJECT_TYPE = "CredentialPasswordIp";
2525

26+
/// <summary>
27+
/// The id of the credential.
28+
/// </summary>
29+
[JsonProperty(PropertyName = "id")]
30+
public int? Id { get; private set; }
31+
32+
/// <summary>
33+
/// The timestamp of the credential object's creation.
34+
/// </summary>
35+
[JsonProperty(PropertyName = "created")]
36+
public string Created { get; private set; }
37+
38+
/// <summary>
39+
/// The timestamp of the credential object's last update.
40+
/// </summary>
41+
[JsonProperty(PropertyName = "updated")]
42+
public string Updated { get; private set; }
43+
2644
/// <summary>
2745
/// The status of the credential.
2846
/// </summary>

0 commit comments

Comments
 (0)