diff --git a/src/Mollie.Api/Models/Chargeback/ChargebackResponse.cs b/src/Mollie.Api/Models/Chargeback/ChargebackResponse.cs
index 0d45a384..ec6a4cae 100644
--- a/src/Mollie.Api/Models/Chargeback/ChargebackResponse.cs
+++ b/src/Mollie.Api/Models/Chargeback/ChargebackResponse.cs
@@ -11,13 +11,13 @@ public class ChargebackResponse : IResponseObject {
///
/// The amount charged back.
///
- public Amount Amount { get; set; }
+ public required Amount Amount { get; init; }
///
/// This optional field will contain the amount that will be deducted from your account, converted to the currency
/// your account is settled in. It follows the same syntax as the amount property.
///
- public Amount SettlementAmount { get; set; }
+ public Amount? SettlementAmount { get; set; }
///
/// The date and time the chargeback was issued, in ISO 8601 format.
@@ -32,17 +32,17 @@ public class ChargebackResponse : IResponseObject {
///
/// The id of the payment this chargeback belongs to.
///
- public string PaymentId { get; set; }
+ public required string PaymentId { get; init; }
///
/// The reason given for a Chargeback, this can help determine the cost for the chargeback
///
- public ChargebackResponseReason Reason { get; set; }
+ public ChargebackResponseReason? Reason { get; set; }
///
/// An object with several URL objects relevant to the chargeback. Every URL object will contain an href and a type field.
///
[JsonProperty("_links")]
- public ChargebackResponseLinks Links { get; set; }
+ public required ChargebackResponseLinks Links { get; init; }
}
}
diff --git a/src/Mollie.Api/Models/Chargeback/ChargebackResponseLinks.cs b/src/Mollie.Api/Models/Chargeback/ChargebackResponseLinks.cs
index 2ab59af8..bcc500c2 100644
--- a/src/Mollie.Api/Models/Chargeback/ChargebackResponseLinks.cs
+++ b/src/Mollie.Api/Models/Chargeback/ChargebackResponseLinks.cs
@@ -7,17 +7,17 @@ public class ChargebackResponseLinks {
///
/// The API resource URL of the chargeback itself.
///
- public UrlObjectLink Self { get; set; }
+ public required UrlObjectLink Self { get; init; }
///
/// The API resource URL of the payment this chargeback belongs to.
///
- public UrlObjectLink Payment { get; set; }
+ public required UrlObjectLink Payment { get; init; }
///
/// The API resource URL of the settlement this payment has been settled with. Not present if not yet settled.
///
- public UrlObjectLink Settlement { get; set; }
+ public UrlObjectLink? Settlement { get; set; }
///
/// The URL to the chargeback retrieval endpoint documentation.
diff --git a/src/Mollie.Api/Models/Chargeback/ChargebackResponseReason.cs b/src/Mollie.Api/Models/Chargeback/ChargebackResponseReason.cs
index 412c5b71..6c429a0b 100644
--- a/src/Mollie.Api/Models/Chargeback/ChargebackResponseReason.cs
+++ b/src/Mollie.Api/Models/Chargeback/ChargebackResponseReason.cs
@@ -1,16 +1,12 @@
-using System;
-using System.Collections.Generic;
-using System.Text;
-
namespace Mollie.Api.Models.Chargeback {
public class ChargebackResponseReason {
///
/// The reason for the chargeback, these are documented here on Mollie's webiste https://help.mollie.com/hc/en-us/articles/115000309865-Why-did-my-direct-debit-payment-fail-
///
- public string Code { get; set; }
+ public required string Code { get; init; }
///
/// an accompanying note to the code
///
- public string Description { get; set; }
+ public required string Description { get; init; }
}
}