Skip to content

Commit 5e4544d

Browse files
authored
Merge pull request #150 from bunq/1.15.0
Regenerated code based on the latest tag 1.15.0
2 parents bdbc65b + 3fa6c03 commit 5e4544d

File tree

245 files changed

+9799
-11065
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

245 files changed

+9799
-11065
lines changed
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
1-
using System.Collections.Generic;
1+
using Bunq.Sdk.Context;
22
using Bunq.Sdk.Http;
3+
using Bunq.Sdk.Json;
34
using Bunq.Sdk.Model.Core;
5+
using Newtonsoft.Json;
6+
using System.Collections.Generic;
7+
using System.Text;
8+
using System;
49

510
namespace Bunq.Sdk.Model.Generated.Endpoint
611
{
@@ -14,41 +19,38 @@ public class AttachmentConversationContent : BunqModel
1419
/// Endpoint constants.
1520
/// </summary>
1621
protected const string ENDPOINT_URL_LISTING = "user/{0}/chat-conversation/{1}/attachment/{2}/content";
17-
22+
1823
/// <summary>
1924
/// Object type.
2025
/// </summary>
2126
private const string OBJECT_TYPE_GET = "AttachmentConversationContent";
22-
27+
2328
/// <summary>
2429
/// Get the raw content of a specific attachment.
2530
/// </summary>
26-
public static BunqResponse<byte[]> List(int chatConversationId, int attachmentId,
27-
IDictionary<string, string> customHeaders = null)
31+
public static BunqResponse<byte[]> List(int chatConversationId, int attachmentId, IDictionary<string, string> customHeaders = null)
2832
{
2933
if (customHeaders == null) customHeaders = new Dictionary<string, string>();
30-
34+
3135
var apiClient = new ApiClient(GetApiContext());
32-
var responseRaw =
33-
apiClient.Get(string.Format(ENDPOINT_URL_LISTING, DetermineUserId(), chatConversationId, attachmentId),
34-
new Dictionary<string, string>(), customHeaders);
35-
36+
var responseRaw = apiClient.Get(string.Format(ENDPOINT_URL_LISTING, DetermineUserId(), chatConversationId, attachmentId), new Dictionary<string, string>(), customHeaders);
37+
3638
return new BunqResponse<byte[]>(responseRaw.BodyBytes, responseRaw.Headers);
3739
}
38-
39-
40+
41+
4042
/// <summary>
4143
/// </summary>
4244
public override bool IsAllFieldNull()
4345
{
4446
return true;
4547
}
46-
48+
4749
/// <summary>
4850
/// </summary>
4951
public static AttachmentConversationContent CreateFromJsonString(string json)
5052
{
51-
return CreateFromJsonString<AttachmentConversationContent>(json);
53+
return BunqModel.CreateFromJsonString<AttachmentConversationContent>(json);
5254
}
5355
}
54-
}
56+
}
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,12 @@
1-
using System.Collections.Generic;
1+
using Bunq.Sdk.Context;
22
using Bunq.Sdk.Http;
3+
using Bunq.Sdk.Json;
34
using Bunq.Sdk.Model.Core;
45
using Bunq.Sdk.Model.Generated.Object;
56
using Newtonsoft.Json;
7+
using System.Collections.Generic;
8+
using System.Text;
9+
using System;
610

711
namespace Bunq.Sdk.Model.Generated.Endpoint
812
{
@@ -16,42 +20,38 @@ public class AttachmentMonetaryAccount : BunqModel
1620
/// Endpoint constants.
1721
/// </summary>
1822
protected const string ENDPOINT_URL_CREATE = "user/{0}/monetary-account/{1}/attachment";
19-
20-
23+
24+
2125
/// <summary>
2226
/// The attachment.
2327
/// </summary>
2428
[JsonProperty(PropertyName = "attachment")]
2529
public Attachment Attachment { get; set; }
26-
30+
2731
/// <summary>
2832
/// The ID of the attachment created.
2933
/// </summary>
3034
[JsonProperty(PropertyName = "id")]
3135
public int? Id { get; set; }
32-
33-
36+
37+
3438
/// <summary>
3539
/// Create a new monetary account attachment. Create a POST request with a payload that contains the binary
3640
/// representation of the file, without any JSON wrapping. Make sure you define the MIME type (i.e. image/jpeg)
3741
/// in the Content-Type header. You are required to provide a description of the attachment using the
3842
/// X-Bunq-Attachment-Description header.
3943
/// </summary>
40-
public static BunqResponse<int> Create(byte[] requestBytes, int? monetaryAccountId = null,
41-
IDictionary<string, string> customHeaders = null)
44+
public static BunqResponse<int> Create(byte[] requestBytes, int? monetaryAccountId= null, IDictionary<string, string> customHeaders = null)
4245
{
4346
if (customHeaders == null) customHeaders = new Dictionary<string, string>();
44-
47+
4548
var apiClient = new ApiClient(GetApiContext());
46-
var responseRaw =
47-
apiClient.Post(
48-
string.Format(ENDPOINT_URL_CREATE, DetermineUserId(),
49-
DetermineMonetaryAccountId(monetaryAccountId)), requestBytes, customHeaders);
50-
49+
var responseRaw = apiClient.Post(string.Format(ENDPOINT_URL_CREATE, DetermineUserId(), DetermineMonetaryAccountId(monetaryAccountId)), requestBytes, customHeaders);
50+
5151
return ProcessForId(responseRaw);
5252
}
53-
54-
53+
54+
5555
/// <summary>
5656
/// </summary>
5757
public override bool IsAllFieldNull()
@@ -60,20 +60,20 @@ public override bool IsAllFieldNull()
6060
{
6161
return false;
6262
}
63-
63+
6464
if (this.Id != null)
6565
{
6666
return false;
6767
}
68-
68+
6969
return true;
7070
}
71-
71+
7272
/// <summary>
7373
/// </summary>
7474
public static AttachmentMonetaryAccount CreateFromJsonString(string json)
7575
{
76-
return CreateFromJsonString<AttachmentMonetaryAccount>(json);
76+
return BunqModel.CreateFromJsonString<AttachmentMonetaryAccount>(json);
7777
}
7878
}
79-
}
79+
}
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
1-
using System.Collections.Generic;
1+
using Bunq.Sdk.Context;
22
using Bunq.Sdk.Http;
3+
using Bunq.Sdk.Json;
34
using Bunq.Sdk.Model.Core;
5+
using Newtonsoft.Json;
6+
using System.Collections.Generic;
7+
using System.Text;
8+
using System;
49

510
namespace Bunq.Sdk.Model.Generated.Endpoint
611
{
@@ -14,43 +19,38 @@ public class AttachmentMonetaryAccountContent : BunqModel
1419
/// Endpoint constants.
1520
/// </summary>
1621
protected const string ENDPOINT_URL_LISTING = "user/{0}/monetary-account/{1}/attachment/{2}/content";
17-
22+
1823
/// <summary>
1924
/// Object type.
2025
/// </summary>
2126
private const string OBJECT_TYPE_GET = "AttachmentMonetaryAccountContent";
22-
27+
2328
/// <summary>
2429
/// Get the raw content of a specific attachment.
2530
/// </summary>
26-
public static BunqResponse<byte[]> List(int attachmentId, int? monetaryAccountId = null,
27-
IDictionary<string, string> customHeaders = null)
31+
public static BunqResponse<byte[]> List(int attachmentId, int? monetaryAccountId= null, IDictionary<string, string> customHeaders = null)
2832
{
2933
if (customHeaders == null) customHeaders = new Dictionary<string, string>();
30-
34+
3135
var apiClient = new ApiClient(GetApiContext());
32-
var responseRaw =
33-
apiClient.Get(
34-
string.Format(ENDPOINT_URL_LISTING, DetermineUserId(),
35-
DetermineMonetaryAccountId(monetaryAccountId), attachmentId), new Dictionary<string, string>(),
36-
customHeaders);
37-
36+
var responseRaw = apiClient.Get(string.Format(ENDPOINT_URL_LISTING, DetermineUserId(), DetermineMonetaryAccountId(monetaryAccountId), attachmentId), new Dictionary<string, string>(), customHeaders);
37+
3838
return new BunqResponse<byte[]>(responseRaw.BodyBytes, responseRaw.Headers);
3939
}
40-
41-
40+
41+
4242
/// <summary>
4343
/// </summary>
4444
public override bool IsAllFieldNull()
4545
{
4646
return true;
4747
}
48-
48+
4949
/// <summary>
5050
/// </summary>
5151
public static AttachmentMonetaryAccountContent CreateFromJsonString(string json)
5252
{
53-
return CreateFromJsonString<AttachmentMonetaryAccountContent>(json);
53+
return BunqModel.CreateFromJsonString<AttachmentMonetaryAccountContent>(json);
5454
}
5555
}
56-
}
56+
}
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,12 @@
1-
using System.Collections.Generic;
1+
using Bunq.Sdk.Context;
22
using Bunq.Sdk.Http;
3+
using Bunq.Sdk.Json;
34
using Bunq.Sdk.Model.Core;
45
using Bunq.Sdk.Model.Generated.Object;
56
using Newtonsoft.Json;
7+
using System.Collections.Generic;
8+
using System.Text;
9+
using System;
610

711
namespace Bunq.Sdk.Model.Generated.Endpoint
812
{
@@ -17,71 +21,69 @@ public class AttachmentPublic : BunqModel
1721
/// </summary>
1822
protected const string ENDPOINT_URL_CREATE = "attachment-public";
1923
protected const string ENDPOINT_URL_READ = "attachment-public/{0}";
20-
24+
2125
/// <summary>
2226
/// Object type.
2327
/// </summary>
2428
private const string OBJECT_TYPE_POST = "Uuid";
2529
private const string OBJECT_TYPE_GET = "AttachmentPublic";
26-
30+
2731
/// <summary>
2832
/// The UUID of the attachment.
2933
/// </summary>
3034
[JsonProperty(PropertyName = "uuid")]
3135
public string Uuid { get; set; }
32-
36+
3337
/// <summary>
3438
/// The timestamp of the attachment's creation.
3539
/// </summary>
3640
[JsonProperty(PropertyName = "created")]
3741
public string Created { get; set; }
38-
42+
3943
/// <summary>
4044
/// The timestamp of the attachment's last update.
4145
/// </summary>
4246
[JsonProperty(PropertyName = "updated")]
4347
public string Updated { get; set; }
44-
48+
4549
/// <summary>
4650
/// The attachment.
4751
/// </summary>
4852
[JsonProperty(PropertyName = "attachment")]
4953
public Attachment Attachment { get; set; }
50-
51-
54+
55+
5256
/// <summary>
5357
/// Create a new public attachment. Create a POST request with a payload that contains a binary representation
5458
/// of the file, without any JSON wrapping. Make sure you define the MIME type (i.e. image/jpeg, or image/png)
5559
/// in the Content-Type header. You are required to provide a description of the attachment using the
5660
/// X-Bunq-Attachment-Description header.
5761
/// </summary>
58-
public static BunqResponse<string> Create(byte[] requestBytes, IDictionary<string, string> customHeaders = null)
62+
public static BunqResponse<string> Create(byte[] requestBytes, IDictionary<string, string> customHeaders = null)
5963
{
6064
if (customHeaders == null) customHeaders = new Dictionary<string, string>();
61-
65+
6266
var apiClient = new ApiClient(GetApiContext());
6367
var responseRaw = apiClient.Post(ENDPOINT_URL_CREATE, requestBytes, customHeaders);
64-
68+
6569
return ProcessForUuid(responseRaw);
6670
}
67-
71+
6872
/// <summary>
6973
/// Get a specific attachment's metadata through its UUID. The Content-Type header of the response will describe
7074
/// the MIME type of the attachment file.
7175
/// </summary>
72-
public static BunqResponse<AttachmentPublic> Get(string attachmentPublicUuid,
73-
IDictionary<string, string> customHeaders = null)
76+
public static BunqResponse<AttachmentPublic> Get(string attachmentPublicUuid, IDictionary<string, string> customHeaders = null)
7477
{
7578
if (customHeaders == null) customHeaders = new Dictionary<string, string>();
76-
79+
7780
var apiClient = new ApiClient(GetApiContext());
78-
var responseRaw = apiClient.Get(string.Format(ENDPOINT_URL_READ, attachmentPublicUuid),
79-
new Dictionary<string, string>(), customHeaders);
80-
81+
var responseRaw = apiClient.Get(string.Format(ENDPOINT_URL_READ, attachmentPublicUuid), new Dictionary<string, string>(), customHeaders);
82+
8183
return FromJson<AttachmentPublic>(responseRaw, OBJECT_TYPE_GET);
8284
}
83-
84-
85+
86+
8587
/// <summary>
8688
/// </summary>
8789
public override bool IsAllFieldNull()
@@ -90,30 +92,30 @@ public override bool IsAllFieldNull()
9092
{
9193
return false;
9294
}
93-
95+
9496
if (this.Created != null)
9597
{
9698
return false;
9799
}
98-
100+
99101
if (this.Updated != null)
100102
{
101103
return false;
102104
}
103-
105+
104106
if (this.Attachment != null)
105107
{
106108
return false;
107109
}
108-
110+
109111
return true;
110112
}
111-
113+
112114
/// <summary>
113115
/// </summary>
114116
public static AttachmentPublic CreateFromJsonString(string json)
115117
{
116-
return CreateFromJsonString<AttachmentPublic>(json);
118+
return BunqModel.CreateFromJsonString<AttachmentPublic>(json);
117119
}
118120
}
119-
}
121+
}

0 commit comments

Comments
 (0)