diff --git a/Adyen/Model/BalancePlatform/AccountHolder.cs b/Adyen/Model/BalancePlatform/AccountHolder.cs index de391f35..01cdc760 100644 --- a/Adyen/Model/BalancePlatform/AccountHolder.cs +++ b/Adyen/Model/BalancePlatform/AccountHolder.cs @@ -33,9 +33,9 @@ namespace Adyen.Model.BalancePlatform public partial class AccountHolder : IEquatable, IValidatableObject { /// - /// The status of the account holder. Possible values: * **active**: The account holder is active. This is the default status when creating an account holder. * **suspended**: The account holder is permanently deactivated by Adyen. This action cannot be undone. * **closed**: The account holder is permanently deactivated by you. This action cannot be undone. + /// The status of the account holder. Possible values: * **active**: The account holder is active and allowed to use its capabilities. This is the initial status for account holders and balance accounts. You can change this status to **suspended** or **closed**. * **suspended**: The account holder is temporarily disabled and payouts are blocked. You can change this status to **active** or **closed**. * **closed**: The account holder and all of its capabilities are permanently disabled. This is a final status and cannot be changed. /// - /// The status of the account holder. Possible values: * **active**: The account holder is active. This is the default status when creating an account holder. * **suspended**: The account holder is permanently deactivated by Adyen. This action cannot be undone. * **closed**: The account holder is permanently deactivated by you. This action cannot be undone. + /// The status of the account holder. Possible values: * **active**: The account holder is active and allowed to use its capabilities. This is the initial status for account holders and balance accounts. You can change this status to **suspended** or **closed**. * **suspended**: The account holder is temporarily disabled and payouts are blocked. You can change this status to **active** or **closed**. * **closed**: The account holder and all of its capabilities are permanently disabled. This is a final status and cannot be changed. [JsonConverter(typeof(StringEnumConverter))] public enum StatusEnum { @@ -61,9 +61,9 @@ public enum StatusEnum /// - /// The status of the account holder. Possible values: * **active**: The account holder is active. This is the default status when creating an account holder. * **suspended**: The account holder is permanently deactivated by Adyen. This action cannot be undone. * **closed**: The account holder is permanently deactivated by you. This action cannot be undone. + /// The status of the account holder. Possible values: * **active**: The account holder is active and allowed to use its capabilities. This is the initial status for account holders and balance accounts. You can change this status to **suspended** or **closed**. * **suspended**: The account holder is temporarily disabled and payouts are blocked. You can change this status to **active** or **closed**. * **closed**: The account holder and all of its capabilities are permanently disabled. This is a final status and cannot be changed. /// - /// The status of the account holder. Possible values: * **active**: The account holder is active. This is the default status when creating an account holder. * **suspended**: The account holder is permanently deactivated by Adyen. This action cannot be undone. * **closed**: The account holder is permanently deactivated by you. This action cannot be undone. + /// The status of the account holder. Possible values: * **active**: The account holder is active and allowed to use its capabilities. This is the initial status for account holders and balance accounts. You can change this status to **suspended** or **closed**. * **suspended**: The account holder is temporarily disabled and payouts are blocked. You can change this status to **active** or **closed**. * **closed**: The account holder and all of its capabilities are permanently disabled. This is a final status and cannot be changed. [DataMember(Name = "status", EmitDefaultValue = false)] public StatusEnum? Status { get; set; } /// @@ -82,7 +82,7 @@ protected AccountHolder() { } /// A set of key and value pairs for general use. The keys do not have specific names and may be used for storing miscellaneous data as desired. > Note that during an update of metadata, the omission of existing key-value pairs will result in the deletion of those key-value pairs.. /// The ID of the account holder's primary balance account. By default, this is set to the first balance account that you create for the account holder. To assign a different balance account, send a PATCH request.. /// Your reference for the account holder.. - /// The status of the account holder. Possible values: * **active**: The account holder is active. This is the default status when creating an account holder. * **suspended**: The account holder is permanently deactivated by Adyen. This action cannot be undone. * **closed**: The account holder is permanently deactivated by you. This action cannot be undone.. + /// The status of the account holder. Possible values: * **active**: The account holder is active and allowed to use its capabilities. This is the initial status for account holders and balance accounts. You can change this status to **suspended** or **closed**. * **suspended**: The account holder is temporarily disabled and payouts are blocked. You can change this status to **active** or **closed**. * **closed**: The account holder and all of its capabilities are permanently disabled. This is a final status and cannot be changed.. /// The time zone of the account holder. For example, **Europe/Amsterdam**. Defaults to the time zone of the balance platform if no time zone is set. For possible values, see the [list of time zone codes](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones).. public AccountHolder(string balancePlatform = default(string), Dictionary capabilities = default(Dictionary), ContactDetails contactDetails = default(ContactDetails), string description = default(string), string legalEntityId = default(string), Dictionary metadata = default(Dictionary), string primaryBalanceAccount = default(string), string reference = default(string), StatusEnum? status = default(StatusEnum?), string timeZone = default(string)) { diff --git a/Adyen/Model/BalancePlatform/AccountHolderUpdateRequest.cs b/Adyen/Model/BalancePlatform/AccountHolderUpdateRequest.cs index 47e57537..14828149 100644 --- a/Adyen/Model/BalancePlatform/AccountHolderUpdateRequest.cs +++ b/Adyen/Model/BalancePlatform/AccountHolderUpdateRequest.cs @@ -33,9 +33,9 @@ namespace Adyen.Model.BalancePlatform public partial class AccountHolderUpdateRequest : IEquatable, IValidatableObject { /// - /// The status of the account holder. Possible values: * **active**: The account holder is active. This is the default status when creating an account holder. * **suspended**: The account holder is permanently deactivated by Adyen. This action cannot be undone. * **closed**: The account holder is permanently deactivated by you. This action cannot be undone. + /// The status of the account holder. Possible values: * **active**: The account holder is active and allowed to use its capabilities. This is the initial status for account holders and balance accounts. You can change this status to **suspended** or **closed**. * **suspended**: The account holder is temporarily disabled and payouts are blocked. You can change this status to **active** or **closed**. * **closed**: The account holder and all of its capabilities are permanently disabled. This is a final status and cannot be changed. /// - /// The status of the account holder. Possible values: * **active**: The account holder is active. This is the default status when creating an account holder. * **suspended**: The account holder is permanently deactivated by Adyen. This action cannot be undone. * **closed**: The account holder is permanently deactivated by you. This action cannot be undone. + /// The status of the account holder. Possible values: * **active**: The account holder is active and allowed to use its capabilities. This is the initial status for account holders and balance accounts. You can change this status to **suspended** or **closed**. * **suspended**: The account holder is temporarily disabled and payouts are blocked. You can change this status to **active** or **closed**. * **closed**: The account holder and all of its capabilities are permanently disabled. This is a final status and cannot be changed. [JsonConverter(typeof(StringEnumConverter))] public enum StatusEnum { @@ -61,9 +61,9 @@ public enum StatusEnum /// - /// The status of the account holder. Possible values: * **active**: The account holder is active. This is the default status when creating an account holder. * **suspended**: The account holder is permanently deactivated by Adyen. This action cannot be undone. * **closed**: The account holder is permanently deactivated by you. This action cannot be undone. + /// The status of the account holder. Possible values: * **active**: The account holder is active and allowed to use its capabilities. This is the initial status for account holders and balance accounts. You can change this status to **suspended** or **closed**. * **suspended**: The account holder is temporarily disabled and payouts are blocked. You can change this status to **active** or **closed**. * **closed**: The account holder and all of its capabilities are permanently disabled. This is a final status and cannot be changed. /// - /// The status of the account holder. Possible values: * **active**: The account holder is active. This is the default status when creating an account holder. * **suspended**: The account holder is permanently deactivated by Adyen. This action cannot be undone. * **closed**: The account holder is permanently deactivated by you. This action cannot be undone. + /// The status of the account holder. Possible values: * **active**: The account holder is active and allowed to use its capabilities. This is the initial status for account holders and balance accounts. You can change this status to **suspended** or **closed**. * **suspended**: The account holder is temporarily disabled and payouts are blocked. You can change this status to **active** or **closed**. * **closed**: The account holder and all of its capabilities are permanently disabled. This is a final status and cannot be changed. [DataMember(Name = "status", EmitDefaultValue = false)] public StatusEnum? Status { get; set; } /// @@ -76,7 +76,7 @@ public enum StatusEnum /// A set of key and value pairs for general use. The keys do not have specific names and may be used for storing miscellaneous data as desired. > Note that during an update of metadata, the omission of existing key-value pairs will result in the deletion of those key-value pairs.. /// The ID of the account holder's primary balance account. By default, this is set to the first balance account that you create for the account holder. To assign a different balance account, send a PATCH request.. /// Your reference for the account holder.. - /// The status of the account holder. Possible values: * **active**: The account holder is active. This is the default status when creating an account holder. * **suspended**: The account holder is permanently deactivated by Adyen. This action cannot be undone. * **closed**: The account holder is permanently deactivated by you. This action cannot be undone.. + /// The status of the account holder. Possible values: * **active**: The account holder is active and allowed to use its capabilities. This is the initial status for account holders and balance accounts. You can change this status to **suspended** or **closed**. * **suspended**: The account holder is temporarily disabled and payouts are blocked. You can change this status to **active** or **closed**. * **closed**: The account holder and all of its capabilities are permanently disabled. This is a final status and cannot be changed.. /// The time zone of the account holder. For example, **Europe/Amsterdam**. Defaults to the time zone of the balance platform if no time zone is set. For possible values, see the [list of time zone codes](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones).. public AccountHolderUpdateRequest(string balancePlatform = default(string), Dictionary capabilities = default(Dictionary), ContactDetails contactDetails = default(ContactDetails), string description = default(string), Dictionary metadata = default(Dictionary), string primaryBalanceAccount = default(string), string reference = default(string), StatusEnum? status = default(StatusEnum?), string timeZone = default(string)) { diff --git a/Adyen/Model/BalancePlatform/AssociationDelegatedAuthenticationData.cs b/Adyen/Model/BalancePlatform/AssociationDelegatedAuthenticationData.cs new file mode 100644 index 00000000..6f77c400 --- /dev/null +++ b/Adyen/Model/BalancePlatform/AssociationDelegatedAuthenticationData.cs @@ -0,0 +1,140 @@ +/* +* Configuration API +* +* +* The version of the OpenAPI document: 2 +* +* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). +* https://openapi-generator.tech +* Do not edit the class manually. +*/ + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Adyen.ApiSerialization.OpenAPIDateConverter; + +namespace Adyen.Model.BalancePlatform +{ + /// + /// AssociationDelegatedAuthenticationData + /// + [DataContract(Name = "AssociationDelegatedAuthenticationData")] + public partial class AssociationDelegatedAuthenticationData : IEquatable, IValidatableObject + { + /// + /// Initializes a new instance of the class. + /// + [JsonConstructorAttribute] + protected AssociationDelegatedAuthenticationData() { } + /// + /// Initializes a new instance of the class. + /// + /// A base64-encoded block with the data required to authenticate the request. You obtain this information by using our authentication SDK. (required). + public AssociationDelegatedAuthenticationData(string sdkOutput = default(string)) + { + this.SdkOutput = sdkOutput; + } + + /// + /// A base64-encoded block with the data required to authenticate the request. You obtain this information by using our authentication SDK. + /// + /// A base64-encoded block with the data required to authenticate the request. You obtain this information by using our authentication SDK. + [DataMember(Name = "sdkOutput", IsRequired = false, EmitDefaultValue = false)] + public string SdkOutput { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + StringBuilder sb = new StringBuilder(); + sb.Append("class AssociationDelegatedAuthenticationData {\n"); + sb.Append(" SdkOutput: ").Append(SdkOutput).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as AssociationDelegatedAuthenticationData); + } + + /// + /// Returns true if AssociationDelegatedAuthenticationData instances are equal + /// + /// Instance of AssociationDelegatedAuthenticationData to be compared + /// Boolean + public bool Equals(AssociationDelegatedAuthenticationData input) + { + if (input == null) + { + return false; + } + return + ( + this.SdkOutput == input.SdkOutput || + (this.SdkOutput != null && + this.SdkOutput.Equals(input.SdkOutput)) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.SdkOutput != null) + { + hashCode = (hashCode * 59) + this.SdkOutput.GetHashCode(); + } + return hashCode; + } + } + /// + /// To validate all properties of the instance + /// + /// Validation context + /// Validation Result + public IEnumerable Validate(ValidationContext validationContext) + { + // SdkOutput (string) maxLength + if (this.SdkOutput != null && this.SdkOutput.Length > 20000) + { + yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for SdkOutput, length must be less than 20000.", new [] { "SdkOutput" }); + } + + yield break; + } + } + +} diff --git a/Adyen/Model/BalancePlatform/AssociationFinaliseRequest.cs b/Adyen/Model/BalancePlatform/AssociationFinaliseRequest.cs new file mode 100644 index 00000000..a5989c12 --- /dev/null +++ b/Adyen/Model/BalancePlatform/AssociationFinaliseRequest.cs @@ -0,0 +1,183 @@ +/* +* Configuration API +* +* +* The version of the OpenAPI document: 2 +* +* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). +* https://openapi-generator.tech +* Do not edit the class manually. +*/ + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Adyen.ApiSerialization.OpenAPIDateConverter; + +namespace Adyen.Model.BalancePlatform +{ + /// + /// AssociationFinaliseRequest + /// + [DataContract(Name = "AssociationFinaliseRequest")] + public partial class AssociationFinaliseRequest : IEquatable, IValidatableObject + { + /// + /// The type of resource that you are associating with the SCA device. Possible value: **PaymentInstrument** + /// + /// The type of resource that you are associating with the SCA device. Possible value: **PaymentInstrument** + [JsonConverter(typeof(StringEnumConverter))] + public enum TypeEnum + { + /// + /// Enum PaymentInstrument for value: PaymentInstrument + /// + [EnumMember(Value = "PaymentInstrument")] + PaymentInstrument = 1 + + } + + + /// + /// The type of resource that you are associating with the SCA device. Possible value: **PaymentInstrument** + /// + /// The type of resource that you are associating with the SCA device. Possible value: **PaymentInstrument** + [DataMember(Name = "type", IsRequired = false, EmitDefaultValue = false)] + public TypeEnum Type { get; set; } + /// + /// Initializes a new instance of the class. + /// + [JsonConstructorAttribute] + protected AssociationFinaliseRequest() { } + /// + /// Initializes a new instance of the class. + /// + /// The list of unique identifiers of the resources that you are associating with the SCA device. Maximum: 5 strings. (required). + /// strongCustomerAuthentication (required). + /// The type of resource that you are associating with the SCA device. Possible value: **PaymentInstrument** (required). + public AssociationFinaliseRequest(List ids = default(List), AssociationDelegatedAuthenticationData strongCustomerAuthentication = default(AssociationDelegatedAuthenticationData), TypeEnum type = default(TypeEnum)) + { + this.Ids = ids; + this.StrongCustomerAuthentication = strongCustomerAuthentication; + this.Type = type; + } + + /// + /// The list of unique identifiers of the resources that you are associating with the SCA device. Maximum: 5 strings. + /// + /// The list of unique identifiers of the resources that you are associating with the SCA device. Maximum: 5 strings. + [DataMember(Name = "ids", IsRequired = false, EmitDefaultValue = false)] + public List Ids { get; set; } + + /// + /// Gets or Sets StrongCustomerAuthentication + /// + [DataMember(Name = "strongCustomerAuthentication", IsRequired = false, EmitDefaultValue = false)] + public AssociationDelegatedAuthenticationData StrongCustomerAuthentication { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + StringBuilder sb = new StringBuilder(); + sb.Append("class AssociationFinaliseRequest {\n"); + sb.Append(" Ids: ").Append(Ids).Append("\n"); + sb.Append(" StrongCustomerAuthentication: ").Append(StrongCustomerAuthentication).Append("\n"); + sb.Append(" Type: ").Append(Type).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as AssociationFinaliseRequest); + } + + /// + /// Returns true if AssociationFinaliseRequest instances are equal + /// + /// Instance of AssociationFinaliseRequest to be compared + /// Boolean + public bool Equals(AssociationFinaliseRequest input) + { + if (input == null) + { + return false; + } + return + ( + this.Ids == input.Ids || + this.Ids != null && + input.Ids != null && + this.Ids.SequenceEqual(input.Ids) + ) && + ( + this.StrongCustomerAuthentication == input.StrongCustomerAuthentication || + (this.StrongCustomerAuthentication != null && + this.StrongCustomerAuthentication.Equals(input.StrongCustomerAuthentication)) + ) && + ( + this.Type == input.Type || + this.Type.Equals(input.Type) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.Ids != null) + { + hashCode = (hashCode * 59) + this.Ids.GetHashCode(); + } + if (this.StrongCustomerAuthentication != null) + { + hashCode = (hashCode * 59) + this.StrongCustomerAuthentication.GetHashCode(); + } + hashCode = (hashCode * 59) + this.Type.GetHashCode(); + return hashCode; + } + } + /// + /// To validate all properties of the instance + /// + /// Validation context + /// Validation Result + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } + +} diff --git a/Adyen/Model/BalancePlatform/AssociationFinaliseResponse.cs b/Adyen/Model/BalancePlatform/AssociationFinaliseResponse.cs new file mode 100644 index 00000000..e0b38748 --- /dev/null +++ b/Adyen/Model/BalancePlatform/AssociationFinaliseResponse.cs @@ -0,0 +1,184 @@ +/* +* Configuration API +* +* +* The version of the OpenAPI document: 2 +* +* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). +* https://openapi-generator.tech +* Do not edit the class manually. +*/ + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Adyen.ApiSerialization.OpenAPIDateConverter; + +namespace Adyen.Model.BalancePlatform +{ + /// + /// AssociationFinaliseResponse + /// + [DataContract(Name = "AssociationFinaliseResponse")] + public partial class AssociationFinaliseResponse : IEquatable, IValidatableObject + { + /// + /// The type of resource that you associated with the SCA device. + /// + /// The type of resource that you associated with the SCA device. + [JsonConverter(typeof(StringEnumConverter))] + public enum TypeEnum + { + /// + /// Enum PAYMENTINSTRUMENT for value: PAYMENT_INSTRUMENT + /// + [EnumMember(Value = "PAYMENT_INSTRUMENT")] + PAYMENTINSTRUMENT = 1 + + } + + + /// + /// The type of resource that you associated with the SCA device. + /// + /// The type of resource that you associated with the SCA device. + [DataMember(Name = "type", IsRequired = false, EmitDefaultValue = false)] + public TypeEnum Type { get; set; } + /// + /// Initializes a new instance of the class. + /// + [JsonConstructorAttribute] + protected AssociationFinaliseResponse() { } + /// + /// Initializes a new instance of the class. + /// + /// The unique identifier of the SCA device you associated with a resource.. + /// The list of unique identifiers of the resources that you associated with the SCA device.. + /// The type of resource that you associated with the SCA device. (required). + public AssociationFinaliseResponse(string deviceId = default(string), List ids = default(List), TypeEnum type = default(TypeEnum)) + { + this.Type = type; + this.DeviceId = deviceId; + this.Ids = ids; + } + + /// + /// The unique identifier of the SCA device you associated with a resource. + /// + /// The unique identifier of the SCA device you associated with a resource. + [DataMember(Name = "deviceId", EmitDefaultValue = false)] + public string DeviceId { get; set; } + + /// + /// The list of unique identifiers of the resources that you associated with the SCA device. + /// + /// The list of unique identifiers of the resources that you associated with the SCA device. + [DataMember(Name = "ids", EmitDefaultValue = false)] + public List Ids { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + StringBuilder sb = new StringBuilder(); + sb.Append("class AssociationFinaliseResponse {\n"); + sb.Append(" DeviceId: ").Append(DeviceId).Append("\n"); + sb.Append(" Ids: ").Append(Ids).Append("\n"); + sb.Append(" Type: ").Append(Type).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as AssociationFinaliseResponse); + } + + /// + /// Returns true if AssociationFinaliseResponse instances are equal + /// + /// Instance of AssociationFinaliseResponse to be compared + /// Boolean + public bool Equals(AssociationFinaliseResponse input) + { + if (input == null) + { + return false; + } + return + ( + this.DeviceId == input.DeviceId || + (this.DeviceId != null && + this.DeviceId.Equals(input.DeviceId)) + ) && + ( + this.Ids == input.Ids || + this.Ids != null && + input.Ids != null && + this.Ids.SequenceEqual(input.Ids) + ) && + ( + this.Type == input.Type || + this.Type.Equals(input.Type) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.DeviceId != null) + { + hashCode = (hashCode * 59) + this.DeviceId.GetHashCode(); + } + if (this.Ids != null) + { + hashCode = (hashCode * 59) + this.Ids.GetHashCode(); + } + hashCode = (hashCode * 59) + this.Type.GetHashCode(); + return hashCode; + } + } + /// + /// To validate all properties of the instance + /// + /// Validation context + /// Validation Result + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } + +} diff --git a/Adyen/Model/BalancePlatform/AssociationInitiateRequest.cs b/Adyen/Model/BalancePlatform/AssociationInitiateRequest.cs new file mode 100644 index 00000000..6fca20ca --- /dev/null +++ b/Adyen/Model/BalancePlatform/AssociationInitiateRequest.cs @@ -0,0 +1,165 @@ +/* +* Configuration API +* +* +* The version of the OpenAPI document: 2 +* +* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). +* https://openapi-generator.tech +* Do not edit the class manually. +*/ + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Adyen.ApiSerialization.OpenAPIDateConverter; + +namespace Adyen.Model.BalancePlatform +{ + /// + /// AssociationInitiateRequest + /// + [DataContract(Name = "AssociationInitiateRequest")] + public partial class AssociationInitiateRequest : IEquatable, IValidatableObject + { + /// + /// The type of resource that you are associating with the SCA device. Possible value: **PaymentInstrument** + /// + /// The type of resource that you are associating with the SCA device. Possible value: **PaymentInstrument** + [JsonConverter(typeof(StringEnumConverter))] + public enum TypeEnum + { + /// + /// Enum PaymentInstrument for value: PaymentInstrument + /// + [EnumMember(Value = "PaymentInstrument")] + PaymentInstrument = 1 + + } + + + /// + /// The type of resource that you are associating with the SCA device. Possible value: **PaymentInstrument** + /// + /// The type of resource that you are associating with the SCA device. Possible value: **PaymentInstrument** + [DataMember(Name = "type", IsRequired = false, EmitDefaultValue = false)] + public TypeEnum Type { get; set; } + /// + /// Initializes a new instance of the class. + /// + [JsonConstructorAttribute] + protected AssociationInitiateRequest() { } + /// + /// Initializes a new instance of the class. + /// + /// The list of unique identifiers of the resources that you are associating with the SCA device. Maximum: 5 strings. (required). + /// The type of resource that you are associating with the SCA device. Possible value: **PaymentInstrument** (required). + public AssociationInitiateRequest(List ids = default(List), TypeEnum type = default(TypeEnum)) + { + this.Ids = ids; + this.Type = type; + } + + /// + /// The list of unique identifiers of the resources that you are associating with the SCA device. Maximum: 5 strings. + /// + /// The list of unique identifiers of the resources that you are associating with the SCA device. Maximum: 5 strings. + [DataMember(Name = "ids", IsRequired = false, EmitDefaultValue = false)] + public List Ids { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + StringBuilder sb = new StringBuilder(); + sb.Append("class AssociationInitiateRequest {\n"); + sb.Append(" Ids: ").Append(Ids).Append("\n"); + sb.Append(" Type: ").Append(Type).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as AssociationInitiateRequest); + } + + /// + /// Returns true if AssociationInitiateRequest instances are equal + /// + /// Instance of AssociationInitiateRequest to be compared + /// Boolean + public bool Equals(AssociationInitiateRequest input) + { + if (input == null) + { + return false; + } + return + ( + this.Ids == input.Ids || + this.Ids != null && + input.Ids != null && + this.Ids.SequenceEqual(input.Ids) + ) && + ( + this.Type == input.Type || + this.Type.Equals(input.Type) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.Ids != null) + { + hashCode = (hashCode * 59) + this.Ids.GetHashCode(); + } + hashCode = (hashCode * 59) + this.Type.GetHashCode(); + return hashCode; + } + } + /// + /// To validate all properties of the instance + /// + /// Validation context + /// Validation Result + public IEnumerable Validate(ValidationContext validationContext) + { + yield break; + } + } + +} diff --git a/Adyen/Model/BalancePlatform/AssociationInitiateResponse.cs b/Adyen/Model/BalancePlatform/AssociationInitiateResponse.cs new file mode 100644 index 00000000..2bda544c --- /dev/null +++ b/Adyen/Model/BalancePlatform/AssociationInitiateResponse.cs @@ -0,0 +1,135 @@ +/* +* Configuration API +* +* +* The version of the OpenAPI document: 2 +* +* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). +* https://openapi-generator.tech +* Do not edit the class manually. +*/ + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Adyen.ApiSerialization.OpenAPIDateConverter; + +namespace Adyen.Model.BalancePlatform +{ + /// + /// AssociationInitiateResponse + /// + [DataContract(Name = "AssociationInitiateResponse")] + public partial class AssociationInitiateResponse : IEquatable, IValidatableObject + { + /// + /// Initializes a new instance of the class. + /// + /// A string that you must pass to the authentication SDK to continue with the association process.. + public AssociationInitiateResponse(string sdkInput = default(string)) + { + this.SdkInput = sdkInput; + } + + /// + /// A string that you must pass to the authentication SDK to continue with the association process. + /// + /// A string that you must pass to the authentication SDK to continue with the association process. + [DataMember(Name = "sdkInput", EmitDefaultValue = false)] + public string SdkInput { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + StringBuilder sb = new StringBuilder(); + sb.Append("class AssociationInitiateResponse {\n"); + sb.Append(" SdkInput: ").Append(SdkInput).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as AssociationInitiateResponse); + } + + /// + /// Returns true if AssociationInitiateResponse instances are equal + /// + /// Instance of AssociationInitiateResponse to be compared + /// Boolean + public bool Equals(AssociationInitiateResponse input) + { + if (input == null) + { + return false; + } + return + ( + this.SdkInput == input.SdkInput || + (this.SdkInput != null && + this.SdkInput.Equals(input.SdkInput)) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.SdkInput != null) + { + hashCode = (hashCode * 59) + this.SdkInput.GetHashCode(); + } + return hashCode; + } + } + /// + /// To validate all properties of the instance + /// + /// Validation context + /// Validation Result + public IEnumerable Validate(ValidationContext validationContext) + { + // SdkInput (string) maxLength + if (this.SdkInput != null && this.SdkInput.Length > 20000) + { + yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for SdkInput, length must be less than 20000.", new [] { "SdkInput" }); + } + + yield break; + } + } + +} diff --git a/Adyen/Model/BalancePlatform/NetworkToken.cs b/Adyen/Model/BalancePlatform/NetworkToken.cs index 7fadd091..6b290172 100644 --- a/Adyen/Model/BalancePlatform/NetworkToken.cs +++ b/Adyen/Model/BalancePlatform/NetworkToken.cs @@ -82,7 +82,7 @@ public enum StatusEnum /// The unique identifier of the payment instrument to which this network token belongs to.. /// The status of the network token. Possible values: **active**, **inactive**, **suspended**, **closed**.. /// The last four digits of the network token `id`.. - /// The type of wallet the network token is associated with. For example, **applePay**.. + /// The type of network token. For example, **wallet**, **cof**.. public NetworkToken(string brandVariant = default(string), DateTime creationDate = default(DateTime), DeviceInfo device = default(DeviceInfo), string id = default(string), string paymentInstrumentId = default(string), StatusEnum? status = default(StatusEnum?), string tokenLastFour = default(string), string type = default(string)) { this.BrandVariant = brandVariant; @@ -137,9 +137,9 @@ public enum StatusEnum public string TokenLastFour { get; set; } /// - /// The type of wallet the network token is associated with. For example, **applePay**. + /// The type of network token. For example, **wallet**, **cof**. /// - /// The type of wallet the network token is associated with. For example, **applePay**. + /// The type of network token. For example, **wallet**, **cof**. [DataMember(Name = "type", EmitDefaultValue = false)] public string Type { get; set; } diff --git a/Adyen/Model/BalancePlatform/PriorityRestriction.cs b/Adyen/Model/BalancePlatform/TokenRequestorsRestriction.cs similarity index 67% rename from Adyen/Model/BalancePlatform/PriorityRestriction.cs rename to Adyen/Model/BalancePlatform/TokenRequestorsRestriction.cs index f220d9b3..9f0f8761 100644 --- a/Adyen/Model/BalancePlatform/PriorityRestriction.cs +++ b/Adyen/Model/BalancePlatform/TokenRequestorsRestriction.cs @@ -27,67 +27,22 @@ namespace Adyen.Model.BalancePlatform { /// - /// PriorityRestriction + /// TokenRequestorsRestriction /// - [DataContract(Name = "PriorityRestriction")] - public partial class PriorityRestriction : IEquatable, IValidatableObject + [DataContract(Name = "TokenRequestorsRestriction")] + public partial class TokenRequestorsRestriction : IEquatable, IValidatableObject { /// - /// Defines Value - /// - [JsonConverter(typeof(StringEnumConverter))] - public enum ValueEnum - { - /// - /// Enum CrossBorder for value: crossBorder - /// - [EnumMember(Value = "crossBorder")] - CrossBorder = 1, - - /// - /// Enum Fast for value: fast - /// - [EnumMember(Value = "fast")] - Fast = 2, - - /// - /// Enum Instant for value: instant - /// - [EnumMember(Value = "instant")] - Instant = 3, - - /// - /// Enum IntraBank for value: intraBank - /// - [EnumMember(Value = "intraBank")] - IntraBank = 4, - - /// - /// Enum Regular for value: regular - /// - [EnumMember(Value = "regular")] - Regular = 5 - - } - - - - /// - /// Gets or Sets Value - /// - [DataMember(Name = "value", EmitDefaultValue = false)] - public List Value { get; set; } - /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class. /// [JsonConstructorAttribute] - protected PriorityRestriction() { } + protected TokenRequestorsRestriction() { } /// - /// Initializes a new instance of the class. + /// Initializes a new instance of the class. /// /// Defines how the condition must be evaluated. (required). /// value. - public PriorityRestriction(string operation = default(string), List value = default(List)) + public TokenRequestorsRestriction(string operation = default(string), List value = default(List)) { this.Operation = operation; this.Value = value; @@ -100,6 +55,12 @@ protected PriorityRestriction() { } [DataMember(Name = "operation", IsRequired = false, EmitDefaultValue = false)] public string Operation { get; set; } + /// + /// Gets or Sets Value + /// + [DataMember(Name = "value", EmitDefaultValue = false)] + public List Value { get; set; } + /// /// Returns the string presentation of the object /// @@ -107,7 +68,7 @@ protected PriorityRestriction() { } public override string ToString() { StringBuilder sb = new StringBuilder(); - sb.Append("class PriorityRestriction {\n"); + sb.Append("class TokenRequestorsRestriction {\n"); sb.Append(" Operation: ").Append(Operation).Append("\n"); sb.Append(" Value: ").Append(Value).Append("\n"); sb.Append("}\n"); @@ -130,15 +91,15 @@ public virtual string ToJson() /// Boolean public override bool Equals(object input) { - return this.Equals(input as PriorityRestriction); + return this.Equals(input as TokenRequestorsRestriction); } /// - /// Returns true if PriorityRestriction instances are equal + /// Returns true if TokenRequestorsRestriction instances are equal /// - /// Instance of PriorityRestriction to be compared + /// Instance of TokenRequestorsRestriction to be compared /// Boolean - public bool Equals(PriorityRestriction input) + public bool Equals(TokenRequestorsRestriction input) { if (input == null) { @@ -152,6 +113,8 @@ public bool Equals(PriorityRestriction input) ) && ( this.Value == input.Value || + this.Value != null && + input.Value != null && this.Value.SequenceEqual(input.Value) ); } @@ -169,7 +132,10 @@ public override int GetHashCode() { hashCode = (hashCode * 59) + this.Operation.GetHashCode(); } - hashCode = (hashCode * 59) + this.Value.GetHashCode(); + if (this.Value != null) + { + hashCode = (hashCode * 59) + this.Value.GetHashCode(); + } return hashCode; } } diff --git a/Adyen/Model/BalancePlatform/TransactionRuleRestrictions.cs b/Adyen/Model/BalancePlatform/TransactionRuleRestrictions.cs index 100b6dd8..7edae221 100644 --- a/Adyen/Model/BalancePlatform/TransactionRuleRestrictions.cs +++ b/Adyen/Model/BalancePlatform/TransactionRuleRestrictions.cs @@ -49,15 +49,15 @@ public partial class TransactionRuleRestrictions : IEquatablemccs. /// merchantNames. /// merchants. - /// priority. /// processingTypes. /// riskScores. /// sameAmountRestriction. /// sameCounterpartyRestriction. /// sourceAccountTypes. /// timeOfDay. + /// tokenRequestors. /// totalAmount. - public TransactionRuleRestrictions(ActiveNetworkTokensRestriction activeNetworkTokens = default(ActiveNetworkTokensRestriction), BrandVariantsRestriction brandVariants = default(BrandVariantsRestriction), CounterpartyBankRestriction counterpartyBank = default(CounterpartyBankRestriction), CounterpartyTypesRestriction counterpartyTypes = default(CounterpartyTypesRestriction), CountriesRestriction countries = default(CountriesRestriction), DayOfWeekRestriction dayOfWeek = default(DayOfWeekRestriction), DifferentCurrenciesRestriction differentCurrencies = default(DifferentCurrenciesRestriction), EntryModesRestriction entryModes = default(EntryModesRestriction), InternationalTransactionRestriction internationalTransaction = default(InternationalTransactionRestriction), MatchingTransactionsRestriction matchingTransactions = default(MatchingTransactionsRestriction), MatchingValuesRestriction matchingValues = default(MatchingValuesRestriction), MccsRestriction mccs = default(MccsRestriction), MerchantNamesRestriction merchantNames = default(MerchantNamesRestriction), MerchantsRestriction merchants = default(MerchantsRestriction), PriorityRestriction priority = default(PriorityRestriction), ProcessingTypesRestriction processingTypes = default(ProcessingTypesRestriction), RiskScoresRestriction riskScores = default(RiskScoresRestriction), SameAmountRestriction sameAmountRestriction = default(SameAmountRestriction), SameCounterpartyRestriction sameCounterpartyRestriction = default(SameCounterpartyRestriction), SourceAccountTypesRestriction sourceAccountTypes = default(SourceAccountTypesRestriction), TimeOfDayRestriction timeOfDay = default(TimeOfDayRestriction), TotalAmountRestriction totalAmount = default(TotalAmountRestriction)) + public TransactionRuleRestrictions(ActiveNetworkTokensRestriction activeNetworkTokens = default(ActiveNetworkTokensRestriction), BrandVariantsRestriction brandVariants = default(BrandVariantsRestriction), CounterpartyBankRestriction counterpartyBank = default(CounterpartyBankRestriction), CounterpartyTypesRestriction counterpartyTypes = default(CounterpartyTypesRestriction), CountriesRestriction countries = default(CountriesRestriction), DayOfWeekRestriction dayOfWeek = default(DayOfWeekRestriction), DifferentCurrenciesRestriction differentCurrencies = default(DifferentCurrenciesRestriction), EntryModesRestriction entryModes = default(EntryModesRestriction), InternationalTransactionRestriction internationalTransaction = default(InternationalTransactionRestriction), MatchingTransactionsRestriction matchingTransactions = default(MatchingTransactionsRestriction), MatchingValuesRestriction matchingValues = default(MatchingValuesRestriction), MccsRestriction mccs = default(MccsRestriction), MerchantNamesRestriction merchantNames = default(MerchantNamesRestriction), MerchantsRestriction merchants = default(MerchantsRestriction), ProcessingTypesRestriction processingTypes = default(ProcessingTypesRestriction), RiskScoresRestriction riskScores = default(RiskScoresRestriction), SameAmountRestriction sameAmountRestriction = default(SameAmountRestriction), SameCounterpartyRestriction sameCounterpartyRestriction = default(SameCounterpartyRestriction), SourceAccountTypesRestriction sourceAccountTypes = default(SourceAccountTypesRestriction), TimeOfDayRestriction timeOfDay = default(TimeOfDayRestriction), TokenRequestorsRestriction tokenRequestors = default(TokenRequestorsRestriction), TotalAmountRestriction totalAmount = default(TotalAmountRestriction)) { this.ActiveNetworkTokens = activeNetworkTokens; this.BrandVariants = brandVariants; @@ -73,13 +73,13 @@ public partial class TransactionRuleRestrictions : IEquatable - /// Gets or Sets Priority - /// - [DataMember(Name = "priority", EmitDefaultValue = false)] - public PriorityRestriction Priority { get; set; } - /// /// Gets or Sets ProcessingTypes /// @@ -209,6 +203,12 @@ public partial class TransactionRuleRestrictions : IEquatable + /// Gets or Sets TokenRequestors + /// + [DataMember(Name = "tokenRequestors", EmitDefaultValue = false)] + public TokenRequestorsRestriction TokenRequestors { get; set; } + /// /// Gets or Sets TotalAmount /// @@ -237,13 +237,13 @@ public override string ToString() sb.Append(" Mccs: ").Append(Mccs).Append("\n"); sb.Append(" MerchantNames: ").Append(MerchantNames).Append("\n"); sb.Append(" Merchants: ").Append(Merchants).Append("\n"); - sb.Append(" Priority: ").Append(Priority).Append("\n"); sb.Append(" ProcessingTypes: ").Append(ProcessingTypes).Append("\n"); sb.Append(" RiskScores: ").Append(RiskScores).Append("\n"); sb.Append(" SameAmountRestriction: ").Append(SameAmountRestriction).Append("\n"); sb.Append(" SameCounterpartyRestriction: ").Append(SameCounterpartyRestriction).Append("\n"); sb.Append(" SourceAccountTypes: ").Append(SourceAccountTypes).Append("\n"); sb.Append(" TimeOfDay: ").Append(TimeOfDay).Append("\n"); + sb.Append(" TokenRequestors: ").Append(TokenRequestors).Append("\n"); sb.Append(" TotalAmount: ").Append(TotalAmount).Append("\n"); sb.Append("}\n"); return sb.ToString(); @@ -350,11 +350,6 @@ public bool Equals(TransactionRuleRestrictions input) (this.Merchants != null && this.Merchants.Equals(input.Merchants)) ) && - ( - this.Priority == input.Priority || - (this.Priority != null && - this.Priority.Equals(input.Priority)) - ) && ( this.ProcessingTypes == input.ProcessingTypes || (this.ProcessingTypes != null && @@ -385,6 +380,11 @@ public bool Equals(TransactionRuleRestrictions input) (this.TimeOfDay != null && this.TimeOfDay.Equals(input.TimeOfDay)) ) && + ( + this.TokenRequestors == input.TokenRequestors || + (this.TokenRequestors != null && + this.TokenRequestors.Equals(input.TokenRequestors)) + ) && ( this.TotalAmount == input.TotalAmount || (this.TotalAmount != null && @@ -457,10 +457,6 @@ public override int GetHashCode() { hashCode = (hashCode * 59) + this.Merchants.GetHashCode(); } - if (this.Priority != null) - { - hashCode = (hashCode * 59) + this.Priority.GetHashCode(); - } if (this.ProcessingTypes != null) { hashCode = (hashCode * 59) + this.ProcessingTypes.GetHashCode(); @@ -485,6 +481,10 @@ public override int GetHashCode() { hashCode = (hashCode * 59) + this.TimeOfDay.GetHashCode(); } + if (this.TokenRequestors != null) + { + hashCode = (hashCode * 59) + this.TokenRequestors.GetHashCode(); + } if (this.TotalAmount != null) { hashCode = (hashCode * 59) + this.TotalAmount.GetHashCode(); diff --git a/Adyen/Model/Checkout/BalanceCheckRequest.cs b/Adyen/Model/Checkout/BalanceCheckRequest.cs index 8bd8d49e..c1be17e2 100644 --- a/Adyen/Model/Checkout/BalanceCheckRequest.cs +++ b/Adyen/Model/Checkout/BalanceCheckRequest.cs @@ -148,7 +148,7 @@ protected BalanceCheckRequest() { } /// Specifies the sales channel, through which the shopper gives their card details, and whether the shopper is a returning customer. For the web service API, Adyen assumes Ecommerce shopper interaction by default. This field has the following possible values: * `Ecommerce` - Online transactions where the cardholder is present (online). For better authorisation rates, we recommend sending the card security code (CSC) along with the request. * `ContAuth` - Card on file and/or subscription transactions, where the cardholder is known to the merchant (returning customer). If the shopper is present (online), you can supply also the CSC to improve authorisation (one-click payment). * `Moto` - Mail-order and telephone-order transactions where the shopper is in contact with the merchant via email or telephone. * `POS` - Point-of-sale transactions where the shopper is physically present to make a payment using a secure payment terminal.. /// The combination of a language code and a country code to specify the language to be used in the payment.. /// shopperName. - /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address.. + /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address.. /// The text to be shown on the shopper's bank statement. We recommend sending a maximum of 22 characters, otherwise banks might truncate the string. Allowed characters: **a-z**, **A-Z**, **0-9**, spaces, and special characters **. , ' _ - ? + * /_**.. /// The shopper's social security number.. /// An array of objects specifying how the payment should be split when using either Adyen for Platforms for [marketplaces](https://docs.adyen.com/marketplaces/split-payments) or [platforms]((https://docs.adyen.com/platforms/split-payments), or standalone [Issuing](https://docs.adyen.com/issuing/add-manage-funds#split).. @@ -420,9 +420,9 @@ protected BalanceCheckRequest() { } public Name ShopperName { get; set; } /// - /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address. + /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address. /// - /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address. + /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address. [DataMember(Name = "shopperReference", EmitDefaultValue = false)] public string ShopperReference { get; set; } diff --git a/Adyen/Model/Checkout/CardDetails.cs b/Adyen/Model/Checkout/CardDetails.cs index 51282469..1d87040d 100644 --- a/Adyen/Model/Checkout/CardDetails.cs +++ b/Adyen/Model/Checkout/CardDetails.cs @@ -126,6 +126,7 @@ public enum TypeEnum /// The encrypted card verification code.. /// The card expiry month. Only collect raw card data if you are [fully PCI compliant](https://docs.adyen.com/development-resources/pci-dss-compliance-guide).. /// The card expiry year. Only collect raw card data if you are [fully PCI compliant](https://docs.adyen.com/development-resources/pci-dss-compliance-guide).. + /// The encoded fastlane data blob. /// The funding source that should be used when multiple sources are available. For Brazilian combo cards, by default the funding source is credit. To use debit, set this value to **debit**.. /// The name of the card holder.. /// The transaction identifier from card schemes. This is the [`networkTxReference`](https://docs.adyen.com/api-explorer/#/CheckoutService/latest/post/payments__resParam_additionalData-ResponseAdditionalDataCommon-networkTxReference) from the response to the first payment.. @@ -139,7 +140,7 @@ public enum TypeEnum /// This is the `recurringDetailReference` returned in the response when you created the token.. /// Required for mobile integrations. Version of the 3D Secure 2 mobile SDK.. /// Default payment method details. Common for scheme payment methods, and for simple payment method details. (default to TypeEnum.Scheme). - public CardDetails(string brand = default(string), string checkoutAttemptId = default(string), string cupsecureplusSmscode = default(string), string cvc = default(string), string encryptedCard = default(string), string encryptedCardNumber = default(string), string encryptedExpiryMonth = default(string), string encryptedExpiryYear = default(string), string encryptedSecurityCode = default(string), string expiryMonth = default(string), string expiryYear = default(string), FundingSourceEnum? fundingSource = default(FundingSourceEnum?), string holderName = default(string), string networkPaymentReference = default(string), string number = default(string), string recurringDetailReference = default(string), string shopperNotificationReference = default(string), string srcCorrelationId = default(string), string srcDigitalCardId = default(string), string srcScheme = default(string), string srcTokenReference = default(string), string storedPaymentMethodId = default(string), string threeDS2SdkVersion = default(string), TypeEnum? type = TypeEnum.Scheme) + public CardDetails(string brand = default(string), string checkoutAttemptId = default(string), string cupsecureplusSmscode = default(string), string cvc = default(string), string encryptedCard = default(string), string encryptedCardNumber = default(string), string encryptedExpiryMonth = default(string), string encryptedExpiryYear = default(string), string encryptedSecurityCode = default(string), string expiryMonth = default(string), string expiryYear = default(string), string fastlaneData = default(string), FundingSourceEnum? fundingSource = default(FundingSourceEnum?), string holderName = default(string), string networkPaymentReference = default(string), string number = default(string), string recurringDetailReference = default(string), string shopperNotificationReference = default(string), string srcCorrelationId = default(string), string srcDigitalCardId = default(string), string srcScheme = default(string), string srcTokenReference = default(string), string storedPaymentMethodId = default(string), string threeDS2SdkVersion = default(string), TypeEnum? type = TypeEnum.Scheme) { this.Brand = brand; this.CheckoutAttemptId = checkoutAttemptId; @@ -152,6 +153,7 @@ public enum TypeEnum this.EncryptedSecurityCode = encryptedSecurityCode; this.ExpiryMonth = expiryMonth; this.ExpiryYear = expiryYear; + this.FastlaneData = fastlaneData; this.FundingSource = fundingSource; this.HolderName = holderName; this.NetworkPaymentReference = networkPaymentReference; @@ -244,6 +246,13 @@ public enum TypeEnum [DataMember(Name = "expiryYear", EmitDefaultValue = false)] public string ExpiryYear { get; set; } + /// + /// The encoded fastlane data blob + /// + /// The encoded fastlane data blob + [DataMember(Name = "fastlaneData", EmitDefaultValue = false)] + public string FastlaneData { get; set; } + /// /// The name of the card holder. /// @@ -341,6 +350,7 @@ public override string ToString() sb.Append(" EncryptedSecurityCode: ").Append(EncryptedSecurityCode).Append("\n"); sb.Append(" ExpiryMonth: ").Append(ExpiryMonth).Append("\n"); sb.Append(" ExpiryYear: ").Append(ExpiryYear).Append("\n"); + sb.Append(" FastlaneData: ").Append(FastlaneData).Append("\n"); sb.Append(" FundingSource: ").Append(FundingSource).Append("\n"); sb.Append(" HolderName: ").Append(HolderName).Append("\n"); sb.Append(" NetworkPaymentReference: ").Append(NetworkPaymentReference).Append("\n"); @@ -444,6 +454,11 @@ public bool Equals(CardDetails input) (this.ExpiryYear != null && this.ExpiryYear.Equals(input.ExpiryYear)) ) && + ( + this.FastlaneData == input.FastlaneData || + (this.FastlaneData != null && + this.FastlaneData.Equals(input.FastlaneData)) + ) && ( this.FundingSource == input.FundingSource || this.FundingSource.Equals(input.FundingSource) @@ -562,6 +577,10 @@ public override int GetHashCode() { hashCode = (hashCode * 59) + this.ExpiryYear.GetHashCode(); } + if (this.FastlaneData != null) + { + hashCode = (hashCode * 59) + this.FastlaneData.GetHashCode(); + } hashCode = (hashCode * 59) + this.FundingSource.GetHashCode(); if (this.HolderName != null) { diff --git a/Adyen/Model/Checkout/CardDonations.cs b/Adyen/Model/Checkout/CardDonations.cs index c8b4c31e..13a88d4f 100644 --- a/Adyen/Model/Checkout/CardDonations.cs +++ b/Adyen/Model/Checkout/CardDonations.cs @@ -126,6 +126,7 @@ public enum TypeEnum /// The encrypted card verification code.. /// The card expiry month. Only collect raw card data if you are [fully PCI compliant](https://docs.adyen.com/development-resources/pci-dss-compliance-guide).. /// The card expiry year. Only collect raw card data if you are [fully PCI compliant](https://docs.adyen.com/development-resources/pci-dss-compliance-guide).. + /// The encoded fastlane data blob. /// The funding source that should be used when multiple sources are available. For Brazilian combo cards, by default the funding source is credit. To use debit, set this value to **debit**.. /// The name of the card holder.. /// The transaction identifier from card schemes. This is the [`networkTxReference`](https://docs.adyen.com/api-explorer/#/CheckoutService/latest/post/payments__resParam_additionalData-ResponseAdditionalDataCommon-networkTxReference) from the response to the first payment.. @@ -139,7 +140,7 @@ public enum TypeEnum /// This is the `recurringDetailReference` returned in the response when you created the token.. /// Required for mobile integrations. Version of the 3D Secure 2 mobile SDK.. /// Default payment method details. Common for scheme payment methods, and for simple payment method details. (default to TypeEnum.Scheme). - public CardDonations(string brand = default(string), string checkoutAttemptId = default(string), string cupsecureplusSmscode = default(string), string cvc = default(string), string encryptedCard = default(string), string encryptedCardNumber = default(string), string encryptedExpiryMonth = default(string), string encryptedExpiryYear = default(string), string encryptedSecurityCode = default(string), string expiryMonth = default(string), string expiryYear = default(string), FundingSourceEnum? fundingSource = default(FundingSourceEnum?), string holderName = default(string), string networkPaymentReference = default(string), string number = default(string), string recurringDetailReference = default(string), string shopperNotificationReference = default(string), string srcCorrelationId = default(string), string srcDigitalCardId = default(string), string srcScheme = default(string), string srcTokenReference = default(string), string storedPaymentMethodId = default(string), string threeDS2SdkVersion = default(string), TypeEnum? type = TypeEnum.Scheme) + public CardDonations(string brand = default(string), string checkoutAttemptId = default(string), string cupsecureplusSmscode = default(string), string cvc = default(string), string encryptedCard = default(string), string encryptedCardNumber = default(string), string encryptedExpiryMonth = default(string), string encryptedExpiryYear = default(string), string encryptedSecurityCode = default(string), string expiryMonth = default(string), string expiryYear = default(string), string fastlaneData = default(string), FundingSourceEnum? fundingSource = default(FundingSourceEnum?), string holderName = default(string), string networkPaymentReference = default(string), string number = default(string), string recurringDetailReference = default(string), string shopperNotificationReference = default(string), string srcCorrelationId = default(string), string srcDigitalCardId = default(string), string srcScheme = default(string), string srcTokenReference = default(string), string storedPaymentMethodId = default(string), string threeDS2SdkVersion = default(string), TypeEnum? type = TypeEnum.Scheme) { this.Brand = brand; this.CheckoutAttemptId = checkoutAttemptId; @@ -152,6 +153,7 @@ public enum TypeEnum this.EncryptedSecurityCode = encryptedSecurityCode; this.ExpiryMonth = expiryMonth; this.ExpiryYear = expiryYear; + this.FastlaneData = fastlaneData; this.FundingSource = fundingSource; this.HolderName = holderName; this.NetworkPaymentReference = networkPaymentReference; @@ -244,6 +246,13 @@ public enum TypeEnum [DataMember(Name = "expiryYear", EmitDefaultValue = false)] public string ExpiryYear { get; set; } + /// + /// The encoded fastlane data blob + /// + /// The encoded fastlane data blob + [DataMember(Name = "fastlaneData", EmitDefaultValue = false)] + public string FastlaneData { get; set; } + /// /// The name of the card holder. /// @@ -341,6 +350,7 @@ public override string ToString() sb.Append(" EncryptedSecurityCode: ").Append(EncryptedSecurityCode).Append("\n"); sb.Append(" ExpiryMonth: ").Append(ExpiryMonth).Append("\n"); sb.Append(" ExpiryYear: ").Append(ExpiryYear).Append("\n"); + sb.Append(" FastlaneData: ").Append(FastlaneData).Append("\n"); sb.Append(" FundingSource: ").Append(FundingSource).Append("\n"); sb.Append(" HolderName: ").Append(HolderName).Append("\n"); sb.Append(" NetworkPaymentReference: ").Append(NetworkPaymentReference).Append("\n"); @@ -444,6 +454,11 @@ public bool Equals(CardDonations input) (this.ExpiryYear != null && this.ExpiryYear.Equals(input.ExpiryYear)) ) && + ( + this.FastlaneData == input.FastlaneData || + (this.FastlaneData != null && + this.FastlaneData.Equals(input.FastlaneData)) + ) && ( this.FundingSource == input.FundingSource || this.FundingSource.Equals(input.FundingSource) @@ -562,6 +577,10 @@ public override int GetHashCode() { hashCode = (hashCode * 59) + this.ExpiryYear.GetHashCode(); } + if (this.FastlaneData != null) + { + hashCode = (hashCode * 59) + this.FastlaneData.GetHashCode(); + } hashCode = (hashCode * 59) + this.FundingSource.GetHashCode(); if (this.HolderName != null) { diff --git a/Adyen/Model/Checkout/CheckoutPaymentMethod.cs b/Adyen/Model/Checkout/CheckoutPaymentMethod.cs index 84f3bf0b..f371f0cd 100644 --- a/Adyen/Model/Checkout/CheckoutPaymentMethod.cs +++ b/Adyen/Model/Checkout/CheckoutPaymentMethod.cs @@ -262,6 +262,18 @@ public CheckoutPaymentMethod(EftDetails actualInstance) this.ActualInstance = actualInstance ?? throw new ArgumentException("Invalid instance found. Must not be null."); } + /// + /// Initializes a new instance of the class + /// with the class + /// + /// An instance of FastlaneDetails. + public CheckoutPaymentMethod(FastlaneDetails actualInstance) + { + this.IsNullable = false; + this.SchemaType= "oneOf"; + this.ActualInstance = actualInstance ?? throw new ArgumentException("Invalid instance found. Must not be null."); + } + /// /// Initializes a new instance of the class /// with the class @@ -736,6 +748,10 @@ public override Object ActualInstance { this._actualInstance = value; } + else if (value.GetType() == typeof(FastlaneDetails)) + { + this._actualInstance = value; + } else if (value.GetType() == typeof(GenericIssuerPaymentMethodDetails)) { this._actualInstance = value; @@ -866,7 +882,7 @@ public override Object ActualInstance } else { - throw new ArgumentException("Invalid instance found. Must be the following types: AchDetails, AffirmDetails, AfterpayDetails, AmazonPayDetails, AncvDetails, AndroidPayDetails, ApplePayDetails, BacsDirectDebitDetails, BillDeskDetails, BlikDetails, CardDetails, CashAppDetails, CellulantDetails, DokuDetails, DotpayDetails, DragonpayDetails, EBankingFinlandDetails, EcontextVoucherDetails, EftDetails, GenericIssuerPaymentMethodDetails, GiropayDetails, GooglePayDetails, IdealDetails, KlarnaDetails, MasterpassDetails, MbwayDetails, MobilePayDetails, MolPayDetails, OpenInvoiceDetails, PayByBankAISDirectDebitDetails, PayByBankDetails, PayPalDetails, PayPayDetails, PayToDetails, PayUUpiDetails, PayWithGoogleDetails, PaymentDetails, PseDetails, RatepayDetails, RivertyDetails, SamsungPayDetails, SepaDirectDebitDetails, StoredPaymentMethodDetails, TwintDetails, UpiCollectDetails, UpiIntentDetails, VippsDetails, VisaCheckoutDetails, WeChatPayDetails, WeChatPayMiniProgramDetails, ZipDetails"); + throw new ArgumentException("Invalid instance found. Must be the following types: AchDetails, AffirmDetails, AfterpayDetails, AmazonPayDetails, AncvDetails, AndroidPayDetails, ApplePayDetails, BacsDirectDebitDetails, BillDeskDetails, BlikDetails, CardDetails, CashAppDetails, CellulantDetails, DokuDetails, DotpayDetails, DragonpayDetails, EBankingFinlandDetails, EcontextVoucherDetails, EftDetails, FastlaneDetails, GenericIssuerPaymentMethodDetails, GiropayDetails, GooglePayDetails, IdealDetails, KlarnaDetails, MasterpassDetails, MbwayDetails, MobilePayDetails, MolPayDetails, OpenInvoiceDetails, PayByBankAISDirectDebitDetails, PayByBankDetails, PayPalDetails, PayPayDetails, PayToDetails, PayUUpiDetails, PayWithGoogleDetails, PaymentDetails, PseDetails, RatepayDetails, RivertyDetails, SamsungPayDetails, SepaDirectDebitDetails, StoredPaymentMethodDetails, TwintDetails, UpiCollectDetails, UpiIntentDetails, VippsDetails, VisaCheckoutDetails, WeChatPayDetails, WeChatPayMiniProgramDetails, ZipDetails"); } } } @@ -1061,6 +1077,16 @@ public EftDetails GetEftDetails() return (EftDetails)this.ActualInstance; } + /// + /// Get the actual instance of `FastlaneDetails`. If the actual instance is not `FastlaneDetails`, + /// the InvalidClassException will be thrown + /// + /// An instance of FastlaneDetails + public FastlaneDetails GetFastlaneDetails() + { + return (FastlaneDetails)this.ActualInstance; + } + /// /// Get the actual instance of `GenericIssuerPaymentMethodDetails`. If the actual instance is not `GenericIssuerPaymentMethodDetails`, /// the InvalidClassException will be thrown @@ -1560,6 +1586,13 @@ public static CheckoutPaymentMethod FromJson(string jsonString) matchedTypes.Add("EftDetails"); match++; } + // Check if the jsonString type enum matches the FastlaneDetails type enums + if (ContainsValue(type)) + { + newCheckoutPaymentMethod = new CheckoutPaymentMethod(JsonConvert.DeserializeObject(jsonString, CheckoutPaymentMethod.SerializerSettings)); + matchedTypes.Add("FastlaneDetails"); + match++; + } // Check if the jsonString type enum matches the GenericIssuerPaymentMethodDetails type enums if (ContainsValue(type)) { diff --git a/Adyen/Model/Checkout/CreateCheckoutSessionRequest.cs b/Adyen/Model/Checkout/CreateCheckoutSessionRequest.cs index 921c3b2f..9dc7a6d0 100644 --- a/Adyen/Model/Checkout/CreateCheckoutSessionRequest.cs +++ b/Adyen/Model/Checkout/CreateCheckoutSessionRequest.cs @@ -289,7 +289,7 @@ protected CreateCheckoutSessionRequest() { } /// Specifies the sales channel, through which the shopper gives their card details, and whether the shopper is a returning customer. For the web service API, Adyen assumes Ecommerce shopper interaction by default. This field has the following possible values: * `Ecommerce` - Online transactions where the cardholder is present (online). For better authorisation rates, we recommend sending the card security code (CSC) along with the request. * `ContAuth` - Card on file and/or subscription transactions, where the cardholder is known to the merchant (returning customer). If the shopper is present (online), you can supply also the CSC to improve authorisation (one-click payment). * `Moto` - Mail-order and telephone-order transactions where the shopper is in contact with the merchant via email or telephone. * `POS` - Point-of-sale transactions where the shopper is physically present to make a payment using a secure payment terminal.. /// The combination of a language code and a country code to specify the language to be used in the payment.. /// shopperName. - /// Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address.. + /// Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address.. /// The text to be shown on the shopper's bank statement. We recommend sending a maximum of 22 characters, otherwise banks might truncate the string. Allowed characters: **a-z**, **A-Z**, **0-9**, spaces, and special characters **. , ' _ - ? + * /_**.. /// Set to true to show the payment amount per installment.. /// Set to **true** to show a button that lets the shopper remove a stored payment method.. @@ -644,9 +644,9 @@ protected CreateCheckoutSessionRequest() { } public Name ShopperName { get; set; } /// - /// Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address. + /// Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address. /// - /// Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address. + /// Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address. [DataMember(Name = "shopperReference", EmitDefaultValue = false)] public string ShopperReference { get; set; } diff --git a/Adyen/Model/Checkout/CreateCheckoutSessionResponse.cs b/Adyen/Model/Checkout/CreateCheckoutSessionResponse.cs index 1404c88a..4ed256ea 100644 --- a/Adyen/Model/Checkout/CreateCheckoutSessionResponse.cs +++ b/Adyen/Model/Checkout/CreateCheckoutSessionResponse.cs @@ -290,7 +290,7 @@ protected CreateCheckoutSessionResponse() { } /// Specifies the sales channel, through which the shopper gives their card details, and whether the shopper is a returning customer. For the web service API, Adyen assumes Ecommerce shopper interaction by default. This field has the following possible values: * `Ecommerce` - Online transactions where the cardholder is present (online). For better authorisation rates, we recommend sending the card security code (CSC) along with the request. * `ContAuth` - Card on file and/or subscription transactions, where the cardholder is known to the merchant (returning customer). If the shopper is present (online), you can supply also the CSC to improve authorisation (one-click payment). * `Moto` - Mail-order and telephone-order transactions where the shopper is in contact with the merchant via email or telephone. * `POS` - Point-of-sale transactions where the shopper is physically present to make a payment using a secure payment terminal.. /// The combination of a language code and a country code to specify the language to be used in the payment.. /// shopperName. - /// Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address.. + /// Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address.. /// The text to be shown on the shopper's bank statement. We recommend sending a maximum of 22 characters, otherwise banks might truncate the string. Allowed characters: **a-z**, **A-Z**, **0-9**, spaces, and special characters **. , ' _ - ? + * /_**.. /// Set to true to show the payment amount per installment.. /// Set to **true** to show a button that lets the shopper remove a stored payment method.. @@ -661,9 +661,9 @@ protected CreateCheckoutSessionResponse() { } public Name ShopperName { get; set; } /// - /// Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address. + /// Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address. /// - /// Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address. + /// Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address. [DataMember(Name = "shopperReference", EmitDefaultValue = false)] public string ShopperReference { get; set; } diff --git a/Adyen/Model/Checkout/FastlaneDetails.cs b/Adyen/Model/Checkout/FastlaneDetails.cs new file mode 100644 index 00000000..4eb2cce3 --- /dev/null +++ b/Adyen/Model/Checkout/FastlaneDetails.cs @@ -0,0 +1,228 @@ +/* +* Adyen Checkout API +* +* +* The version of the OpenAPI document: 71 +* +* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). +* https://openapi-generator.tech +* Do not edit the class manually. +*/ + +using System; +using System.Collections; +using System.Collections.Generic; +using System.Collections.ObjectModel; +using System.Linq; +using System.IO; +using System.Runtime.Serialization; +using System.Text; +using System.Text.RegularExpressions; +using Newtonsoft.Json; +using Newtonsoft.Json.Converters; +using Newtonsoft.Json.Linq; +using System.ComponentModel.DataAnnotations; +using OpenAPIDateConverter = Adyen.ApiSerialization.OpenAPIDateConverter; + +namespace Adyen.Model.Checkout +{ + /// + /// FastlaneDetails + /// + [DataContract(Name = "FastlaneDetails")] + public partial class FastlaneDetails : IEquatable, IValidatableObject + { + /// + /// **fastlane** + /// + /// **fastlane** + [JsonConverter(typeof(StringEnumConverter))] + public enum TypeEnum + { + /// + /// Enum Fastlane for value: fastlane + /// + [EnumMember(Value = "fastlane")] + Fastlane = 1 + + } + + + /// + /// **fastlane** + /// + /// **fastlane** + [DataMember(Name = "type", IsRequired = false, EmitDefaultValue = false)] + public TypeEnum Type { get; set; } + /// + /// Initializes a new instance of the class. + /// + [JsonConstructorAttribute] + protected FastlaneDetails() { } + /// + /// Initializes a new instance of the class. + /// + /// The checkout attempt identifier.. + /// The encoded fastlane data blob (required). + /// This is the `recurringDetailReference` returned in the response when you created the token.. + /// This is the `recurringDetailReference` returned in the response when you created the token.. + /// **fastlane** (required) (default to TypeEnum.Fastlane). + public FastlaneDetails(string checkoutAttemptId = default(string), string fastlaneData = default(string), string recurringDetailReference = default(string), string storedPaymentMethodId = default(string), TypeEnum type = TypeEnum.Fastlane) + { + this.FastlaneData = fastlaneData; + this.Type = type; + this.CheckoutAttemptId = checkoutAttemptId; + this.RecurringDetailReference = recurringDetailReference; + this.StoredPaymentMethodId = storedPaymentMethodId; + } + + /// + /// The checkout attempt identifier. + /// + /// The checkout attempt identifier. + [DataMember(Name = "checkoutAttemptId", EmitDefaultValue = false)] + public string CheckoutAttemptId { get; set; } + + /// + /// The encoded fastlane data blob + /// + /// The encoded fastlane data blob + [DataMember(Name = "fastlaneData", IsRequired = false, EmitDefaultValue = false)] + public string FastlaneData { get; set; } + + /// + /// This is the `recurringDetailReference` returned in the response when you created the token. + /// + /// This is the `recurringDetailReference` returned in the response when you created the token. + [DataMember(Name = "recurringDetailReference", EmitDefaultValue = false)] + [Obsolete("Deprecated since Adyen Checkout API v49. Use `storedPaymentMethodId` instead.")] + public string RecurringDetailReference { get; set; } + + /// + /// This is the `recurringDetailReference` returned in the response when you created the token. + /// + /// This is the `recurringDetailReference` returned in the response when you created the token. + [DataMember(Name = "storedPaymentMethodId", EmitDefaultValue = false)] + public string StoredPaymentMethodId { get; set; } + + /// + /// Returns the string presentation of the object + /// + /// String presentation of the object + public override string ToString() + { + StringBuilder sb = new StringBuilder(); + sb.Append("class FastlaneDetails {\n"); + sb.Append(" CheckoutAttemptId: ").Append(CheckoutAttemptId).Append("\n"); + sb.Append(" FastlaneData: ").Append(FastlaneData).Append("\n"); + sb.Append(" RecurringDetailReference: ").Append(RecurringDetailReference).Append("\n"); + sb.Append(" StoredPaymentMethodId: ").Append(StoredPaymentMethodId).Append("\n"); + sb.Append(" Type: ").Append(Type).Append("\n"); + sb.Append("}\n"); + return sb.ToString(); + } + + /// + /// Returns the JSON string presentation of the object + /// + /// JSON string presentation of the object + public virtual string ToJson() + { + return Newtonsoft.Json.JsonConvert.SerializeObject(this, Newtonsoft.Json.Formatting.Indented); + } + + /// + /// Returns true if objects are equal + /// + /// Object to be compared + /// Boolean + public override bool Equals(object input) + { + return this.Equals(input as FastlaneDetails); + } + + /// + /// Returns true if FastlaneDetails instances are equal + /// + /// Instance of FastlaneDetails to be compared + /// Boolean + public bool Equals(FastlaneDetails input) + { + if (input == null) + { + return false; + } + return + ( + this.CheckoutAttemptId == input.CheckoutAttemptId || + (this.CheckoutAttemptId != null && + this.CheckoutAttemptId.Equals(input.CheckoutAttemptId)) + ) && + ( + this.FastlaneData == input.FastlaneData || + (this.FastlaneData != null && + this.FastlaneData.Equals(input.FastlaneData)) + ) && + ( + this.RecurringDetailReference == input.RecurringDetailReference || + (this.RecurringDetailReference != null && + this.RecurringDetailReference.Equals(input.RecurringDetailReference)) + ) && + ( + this.StoredPaymentMethodId == input.StoredPaymentMethodId || + (this.StoredPaymentMethodId != null && + this.StoredPaymentMethodId.Equals(input.StoredPaymentMethodId)) + ) && + ( + this.Type == input.Type || + this.Type.Equals(input.Type) + ); + } + + /// + /// Gets the hash code + /// + /// Hash code + public override int GetHashCode() + { + unchecked // Overflow is fine, just wrap + { + int hashCode = 41; + if (this.CheckoutAttemptId != null) + { + hashCode = (hashCode * 59) + this.CheckoutAttemptId.GetHashCode(); + } + if (this.FastlaneData != null) + { + hashCode = (hashCode * 59) + this.FastlaneData.GetHashCode(); + } + if (this.RecurringDetailReference != null) + { + hashCode = (hashCode * 59) + this.RecurringDetailReference.GetHashCode(); + } + if (this.StoredPaymentMethodId != null) + { + hashCode = (hashCode * 59) + this.StoredPaymentMethodId.GetHashCode(); + } + hashCode = (hashCode * 59) + this.Type.GetHashCode(); + return hashCode; + } + } + /// + /// To validate all properties of the instance + /// + /// Validation context + /// Validation Result + public IEnumerable Validate(ValidationContext validationContext) + { + // StoredPaymentMethodId (string) maxLength + if (this.StoredPaymentMethodId != null && this.StoredPaymentMethodId.Length > 64) + { + yield return new System.ComponentModel.DataAnnotations.ValidationResult("Invalid value for StoredPaymentMethodId, length must be less than 64.", new [] { "StoredPaymentMethodId" }); + } + + yield break; + } + } + +} diff --git a/Adyen/Model/Checkout/FundRecipient.cs b/Adyen/Model/Checkout/FundRecipient.cs index 30660f77..eb14fa2e 100644 --- a/Adyen/Model/Checkout/FundRecipient.cs +++ b/Adyen/Model/Checkout/FundRecipient.cs @@ -86,7 +86,7 @@ public enum WalletPurposeEnum /// paymentMethod. /// The email address of the shopper.. /// shopperName. - /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address.. + /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address.. /// This is the `recurringDetailReference` returned in the response when you created the token.. /// subMerchant. /// The telephone number of the shopper.. @@ -142,9 +142,9 @@ public enum WalletPurposeEnum public Name ShopperName { get; set; } /// - /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address. + /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address. /// - /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address. + /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address. [DataMember(Name = "shopperReference", EmitDefaultValue = false)] public string ShopperReference { get; set; } diff --git a/Adyen/Model/Checkout/PaymentLinkRequest.cs b/Adyen/Model/Checkout/PaymentLinkRequest.cs index af1f3abe..c7e3ebea 100644 --- a/Adyen/Model/Checkout/PaymentLinkRequest.cs +++ b/Adyen/Model/Checkout/PaymentLinkRequest.cs @@ -185,7 +185,7 @@ protected PaymentLinkRequest() { } /// The shopper's email address.. /// The language to be used in the payment page, specified by a combination of a language and country code. For example, `en-US`. For a list of shopper locales that Pay by Link supports, refer to [Language and localization](https://docs.adyen.com/unified-commerce/pay-by-link/payment-links/api#language).. /// shopperName. - /// Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address.. + /// Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address.. /// The text to be shown on the shopper's bank statement. We recommend sending a maximum of 22 characters, otherwise banks might truncate the string. Allowed characters: **a-z**, **A-Z**, **0-9**, spaces, and special characters **. , ' _ - ? + * /_**.. /// Set to **false** to hide the button that lets the shopper remove a stored payment method. (default to true). /// The shopper's social security number.. @@ -438,9 +438,9 @@ protected PaymentLinkRequest() { } public Name ShopperName { get; set; } /// - /// Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address. + /// Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address. /// - /// Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address. + /// Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address. [DataMember(Name = "shopperReference", EmitDefaultValue = false)] public string ShopperReference { get; set; } diff --git a/Adyen/Model/Checkout/PaymentLinkResponse.cs b/Adyen/Model/Checkout/PaymentLinkResponse.cs index 35b3d62b..003774ba 100644 --- a/Adyen/Model/Checkout/PaymentLinkResponse.cs +++ b/Adyen/Model/Checkout/PaymentLinkResponse.cs @@ -231,7 +231,7 @@ protected PaymentLinkResponse() { } /// The shopper's email address.. /// The language to be used in the payment page, specified by a combination of a language and country code. For example, `en-US`. For a list of shopper locales that Pay by Link supports, refer to [Language and localization](https://docs.adyen.com/unified-commerce/pay-by-link/payment-links/api#language).. /// shopperName. - /// Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address.. + /// Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address.. /// The text to be shown on the shopper's bank statement. We recommend sending a maximum of 22 characters, otherwise banks might truncate the string. Allowed characters: **a-z**, **A-Z**, **0-9**, spaces, and special characters **. , ' _ - ? + * /_**.. /// Set to **false** to hide the button that lets the shopper remove a stored payment method. (default to true). /// The shopper's social security number.. @@ -495,9 +495,9 @@ protected PaymentLinkResponse() { } public Name ShopperName { get; set; } /// - /// Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address. + /// Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address. /// - /// Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address. + /// Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address. [DataMember(Name = "shopperReference", EmitDefaultValue = false)] public string ShopperReference { get; set; } diff --git a/Adyen/Model/Checkout/PaymentMethodsRequest.cs b/Adyen/Model/Checkout/PaymentMethodsRequest.cs index 0310420b..758d9779 100644 --- a/Adyen/Model/Checkout/PaymentMethodsRequest.cs +++ b/Adyen/Model/Checkout/PaymentMethodsRequest.cs @@ -118,7 +118,7 @@ protected PaymentMethodsRequest() { } /// order. /// A unique ID that can be used to associate `/paymentMethods` and `/payments` requests with the same shopper transaction, offering insights into conversion rates.. /// The combination of a language code and a country code to specify the language to be used in the payment.. - /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address.. + /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address.. /// Boolean value indicating whether the card payment method should be split into separate debit and credit options. (default to false). /// Required for Adyen for Platforms integrations if you are a platform model. This is your [reference](https://docs.adyen.com/api-explorer/Management/3/post/merchants/(merchantId)/stores#request-reference) (on [balance platform](https://docs.adyen.com/platforms)) or the [storeReference](https://docs.adyen.com/api-explorer/Account/latest/post/updateAccountHolder#request-accountHolderDetails-storeDetails-storeReference) (in the [classic integration](https://docs.adyen.com/classic-platforms/processing-payments/route-payment-to-store/#route-a-payment-to-a-store)) for the ecommerce or point-of-sale store that is processing the payment.. /// Specifies how payment methods should be filtered based on the 'store' parameter: - 'exclusive': Only payment methods belonging to the specified 'store' are returned. - 'inclusive': Payment methods from the 'store' and those not associated with any other store are returned.. @@ -202,9 +202,9 @@ protected PaymentMethodsRequest() { } public string ShopperLocale { get; set; } /// - /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address. + /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address. /// - /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address. + /// Required for recurring payments. Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address. [DataMember(Name = "shopperReference", EmitDefaultValue = false)] public string ShopperReference { get; set; } diff --git a/Adyen/Model/Checkout/PaymentRefundResponse.cs b/Adyen/Model/Checkout/PaymentRefundResponse.cs index a635b222..a4478de8 100644 --- a/Adyen/Model/Checkout/PaymentRefundResponse.cs +++ b/Adyen/Model/Checkout/PaymentRefundResponse.cs @@ -109,6 +109,7 @@ protected PaymentRefundResponse() { } /// Initializes a new instance of the class. /// /// amount (required). + /// This is only available for PayPal refunds. The [`pspReference`](https://docs.adyen.com/api-explorer/#/CheckoutService/latest/post/payments__resParam_pspReference) of the specific capture to refund.. /// Price and product information of the refunded items, required for [partial refunds](https://docs.adyen.com/online-payments/refund#refund-a-payment). > This field is required for partial refunds with 3x 4x Oney, Affirm, Afterpay, Atome, Clearpay, Klarna, Ratepay, Walley, and Zip.. /// The merchant account that is used to process the payment. (required). /// Your reason for the refund request.. @@ -118,13 +119,14 @@ protected PaymentRefundResponse() { } /// An array of objects specifying how the amount should be split between accounts when using Adyen for Platforms. For more information, see how to process payments for [marketplaces](https://docs.adyen.com/marketplaces/split-payments) or [platforms](https://docs.adyen.com/platforms/online-payments/split-payments/).. /// The status of your request. This will always have the value **received**. (required). /// The online store or [physical store](https://docs.adyen.com/point-of-sale/design-your-integration/determine-account-structure/#create-stores) that is processing the refund. This must be the same as the store name configured in your Customer Area. Otherwise, you get an error and the refund fails.. - public PaymentRefundResponse(Amount amount = default(Amount), List lineItems = default(List), string merchantAccount = default(string), MerchantRefundReasonEnum? merchantRefundReason = default(MerchantRefundReasonEnum?), string paymentPspReference = default(string), string pspReference = default(string), string reference = default(string), List splits = default(List), StatusEnum status = default(StatusEnum), string store = default(string)) + public PaymentRefundResponse(Amount amount = default(Amount), string capturePspReference = default(string), List lineItems = default(List), string merchantAccount = default(string), MerchantRefundReasonEnum? merchantRefundReason = default(MerchantRefundReasonEnum?), string paymentPspReference = default(string), string pspReference = default(string), string reference = default(string), List splits = default(List), StatusEnum status = default(StatusEnum), string store = default(string)) { this.Amount = amount; this.MerchantAccount = merchantAccount; this.PaymentPspReference = paymentPspReference; this.PspReference = pspReference; this.Status = status; + this.CapturePspReference = capturePspReference; this.LineItems = lineItems; this.MerchantRefundReason = merchantRefundReason; this.Reference = reference; @@ -138,6 +140,13 @@ protected PaymentRefundResponse() { } [DataMember(Name = "amount", IsRequired = false, EmitDefaultValue = false)] public Amount Amount { get; set; } + /// + /// This is only available for PayPal refunds. The [`pspReference`](https://docs.adyen.com/api-explorer/#/CheckoutService/latest/post/payments__resParam_pspReference) of the specific capture to refund. + /// + /// This is only available for PayPal refunds. The [`pspReference`](https://docs.adyen.com/api-explorer/#/CheckoutService/latest/post/payments__resParam_pspReference) of the specific capture to refund. + [DataMember(Name = "capturePspReference", EmitDefaultValue = false)] + public string CapturePspReference { get; set; } + /// /// Price and product information of the refunded items, required for [partial refunds](https://docs.adyen.com/online-payments/refund#refund-a-payment). > This field is required for partial refunds with 3x 4x Oney, Affirm, Afterpay, Atome, Clearpay, Klarna, Ratepay, Walley, and Zip. /// @@ -196,6 +205,7 @@ public override string ToString() StringBuilder sb = new StringBuilder(); sb.Append("class PaymentRefundResponse {\n"); sb.Append(" Amount: ").Append(Amount).Append("\n"); + sb.Append(" CapturePspReference: ").Append(CapturePspReference).Append("\n"); sb.Append(" LineItems: ").Append(LineItems).Append("\n"); sb.Append(" MerchantAccount: ").Append(MerchantAccount).Append("\n"); sb.Append(" MerchantRefundReason: ").Append(MerchantRefundReason).Append("\n"); @@ -245,6 +255,11 @@ public bool Equals(PaymentRefundResponse input) (this.Amount != null && this.Amount.Equals(input.Amount)) ) && + ( + this.CapturePspReference == input.CapturePspReference || + (this.CapturePspReference != null && + this.CapturePspReference.Equals(input.CapturePspReference)) + ) && ( this.LineItems == input.LineItems || this.LineItems != null && @@ -305,6 +320,10 @@ public override int GetHashCode() { hashCode = (hashCode * 59) + this.Amount.GetHashCode(); } + if (this.CapturePspReference != null) + { + hashCode = (hashCode * 59) + this.CapturePspReference.GetHashCode(); + } if (this.LineItems != null) { hashCode = (hashCode * 59) + this.LineItems.GetHashCode(); diff --git a/Adyen/Model/Checkout/StoredPaymentMethodResource.cs b/Adyen/Model/Checkout/StoredPaymentMethodResource.cs index ce5e5adf..8ec3b3ef 100644 --- a/Adyen/Model/Checkout/StoredPaymentMethodResource.cs +++ b/Adyen/Model/Checkout/StoredPaymentMethodResource.cs @@ -49,7 +49,7 @@ public partial class StoredPaymentMethodResource : IEquatableReturned in the response if you are not tokenizing with Adyen and are using the Merchant-initiated transactions (MIT) framework from Mastercard or Visa. This contains either the Mastercard Trace ID or the Visa Transaction ID.. /// The name of the bank account holder.. /// The shopper’s email address.. - /// Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address.. + /// Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address.. /// Defines a recurring payment type. Allowed values: * `Subscription` – A transaction for a fixed or variable amount, which follows a fixed schedule. * `CardOnFile` – With a card-on-file (CoF) transaction, card details are stored to enable one-click or omnichannel journeys, or simply to streamline the checkout process. Any subscription not following a fixed schedule is also considered a card-on-file transaction. * `UnscheduledCardOnFile` – An unscheduled card-on-file (UCoF) transaction is a transaction that occurs on a non-fixed schedule and/or have variable amounts. For example, automatic top-ups when a cardholder's balance drops below a certain amount.. /// The type of payment method.. public StoredPaymentMethodResource(string brand = default(string), string expiryMonth = default(string), string expiryYear = default(string), string externalResponseCode = default(string), string externalTokenReference = default(string), string holderName = default(string), string iban = default(string), string id = default(string), string issuerName = default(string), string lastFour = default(string), string name = default(string), string networkTxReference = default(string), string ownerName = default(string), string shopperEmail = default(string), string shopperReference = default(string), List supportedRecurringProcessingModels = default(List), string type = default(string)) @@ -172,9 +172,9 @@ public partial class StoredPaymentMethodResource : IEquatable - /// Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address. + /// Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address. /// - /// Your reference to uniquely identify this shopper, for example user ID or account ID. Minimum length: 3 characters. > Your reference must not include personally identifiable information (PII), for example name or email address. + /// Your reference to uniquely identify this shopper, for example user ID or account ID. The value is case-sensitive and must be at least three characters. > Your reference must not include personally identifiable information (PII) such as name or email address. [DataMember(Name = "shopperReference", EmitDefaultValue = false)] public string ShopperReference { get; set; } diff --git a/Adyen/Model/ConfigurationWebhooks/AccountHolder.cs b/Adyen/Model/ConfigurationWebhooks/AccountHolder.cs index 39f7f94d..90511844 100644 --- a/Adyen/Model/ConfigurationWebhooks/AccountHolder.cs +++ b/Adyen/Model/ConfigurationWebhooks/AccountHolder.cs @@ -33,9 +33,9 @@ namespace Adyen.Model.ConfigurationWebhooks public partial class AccountHolder : IEquatable, IValidatableObject { /// - /// The status of the account holder. Possible values: * **active**: The account holder is active. This is the default status when creating an account holder. * **suspended**: The account holder is permanently deactivated by Adyen. This action cannot be undone. * **closed**: The account holder is permanently deactivated by you. This action cannot be undone. + /// The status of the account holder. Possible values: * **active**: The account holder is active and allowed to use its capabilities. This is the initial status for account holders and balance accounts. You can change this status to **suspended** or **closed**. * **suspended**: The account holder is temporarily disabled and payouts are blocked. You can change this status to **active** or **closed**. * **closed**: The account holder and all of its capabilities are permanently disabled. This is a final status and cannot be changed. /// - /// The status of the account holder. Possible values: * **active**: The account holder is active. This is the default status when creating an account holder. * **suspended**: The account holder is permanently deactivated by Adyen. This action cannot be undone. * **closed**: The account holder is permanently deactivated by you. This action cannot be undone. + /// The status of the account holder. Possible values: * **active**: The account holder is active and allowed to use its capabilities. This is the initial status for account holders and balance accounts. You can change this status to **suspended** or **closed**. * **suspended**: The account holder is temporarily disabled and payouts are blocked. You can change this status to **active** or **closed**. * **closed**: The account holder and all of its capabilities are permanently disabled. This is a final status and cannot be changed. [JsonConverter(typeof(StringEnumConverter))] public enum StatusEnum { @@ -61,9 +61,9 @@ public enum StatusEnum /// - /// The status of the account holder. Possible values: * **active**: The account holder is active. This is the default status when creating an account holder. * **suspended**: The account holder is permanently deactivated by Adyen. This action cannot be undone. * **closed**: The account holder is permanently deactivated by you. This action cannot be undone. + /// The status of the account holder. Possible values: * **active**: The account holder is active and allowed to use its capabilities. This is the initial status for account holders and balance accounts. You can change this status to **suspended** or **closed**. * **suspended**: The account holder is temporarily disabled and payouts are blocked. You can change this status to **active** or **closed**. * **closed**: The account holder and all of its capabilities are permanently disabled. This is a final status and cannot be changed. /// - /// The status of the account holder. Possible values: * **active**: The account holder is active. This is the default status when creating an account holder. * **suspended**: The account holder is permanently deactivated by Adyen. This action cannot be undone. * **closed**: The account holder is permanently deactivated by you. This action cannot be undone. + /// The status of the account holder. Possible values: * **active**: The account holder is active and allowed to use its capabilities. This is the initial status for account holders and balance accounts. You can change this status to **suspended** or **closed**. * **suspended**: The account holder is temporarily disabled and payouts are blocked. You can change this status to **active** or **closed**. * **closed**: The account holder and all of its capabilities are permanently disabled. This is a final status and cannot be changed. [DataMember(Name = "status", EmitDefaultValue = false)] public StatusEnum? Status { get; set; } /// @@ -84,7 +84,7 @@ protected AccountHolder() { } /// The unique identifier of the migrated account holder in the classic integration.. /// The ID of the account holder's primary balance account. By default, this is set to the first balance account that you create for the account holder. To assign a different balance account, send a PATCH request.. /// Your reference for the account holder.. - /// The status of the account holder. Possible values: * **active**: The account holder is active. This is the default status when creating an account holder. * **suspended**: The account holder is permanently deactivated by Adyen. This action cannot be undone. * **closed**: The account holder is permanently deactivated by you. This action cannot be undone.. + /// The status of the account holder. Possible values: * **active**: The account holder is active and allowed to use its capabilities. This is the initial status for account holders and balance accounts. You can change this status to **suspended** or **closed**. * **suspended**: The account holder is temporarily disabled and payouts are blocked. You can change this status to **active** or **closed**. * **closed**: The account holder and all of its capabilities are permanently disabled. This is a final status and cannot be changed.. /// The time zone of the account holder. For example, **Europe/Amsterdam**. Defaults to the time zone of the balance platform if no time zone is set. For possible values, see the [list of time zone codes](https://en.wikipedia.org/wiki/List_of_tz_database_time_zones).. /// List of verification deadlines and the capabilities that will be disallowed if verification errors are not resolved.. public AccountHolder(string balancePlatform = default(string), Dictionary capabilities = default(Dictionary), ContactDetails contactDetails = default(ContactDetails), string description = default(string), string id = default(string), string legalEntityId = default(string), Dictionary metadata = default(Dictionary), string migratedAccountHolderCode = default(string), string primaryBalanceAccount = default(string), string reference = default(string), StatusEnum? status = default(StatusEnum?), string timeZone = default(string), List verificationDeadlines = default(List)) diff --git a/Adyen/Model/LegalEntityManagement/LegalEntityAssociation.cs b/Adyen/Model/LegalEntityManagement/LegalEntityAssociation.cs index 4f1920ae..988259eb 100644 --- a/Adyen/Model/LegalEntityManagement/LegalEntityAssociation.cs +++ b/Adyen/Model/LegalEntityManagement/LegalEntityAssociation.cs @@ -166,7 +166,7 @@ protected LegalEntityAssociation() { } /// /// The individual's job title if the `type` is **uboThroughControl** or **signatory**.. /// The unique identifier of the associated [legal entity](https://docs.adyen.com/api-explorer/legalentity/latest/post/legalEntities#responses-200-id). (required). - /// Default value: **false**Indicates if the `type` **director**, **secondaryPartner** or **shareholder** is a nominee. Only applicable to New Zealand.. + /// Default value: **false** Set to **true** if the entity association `type` **director**, **secondaryPartner** or **shareholder** is also a nominee. Only applicable to New Zealand.. /// The individual's relationship to a legal representative if the `type` is **legalRepresentative**. Possible values: **parent**, **guardian**.. /// Defines the KYC exemption reason for a settlor associated with a trust. Only applicable to trusts in Australia. For example, **professionalServiceProvider**, **deceased**, or **contributionBelowThreshold**.. /// Defines the relationship of the legal entity to the current legal entity. Possible value for individuals: **legalRepresentative**. Possible values for organizations: **director**, **signatory**, **trustOwnership**, **uboThroughOwnership**, **uboThroughControl**, or **ultimateParentCompany**. Possible values for sole proprietorships: **soleProprietorship**. Possible value for trusts: **trust**. Possible values for trust members: **definedBeneficiary**, **protector**, **secondaryTrustee**, **settlor**, **uboThroughControl**, or **uboThroughOwnership**. Possible value for unincorporated partnership: **unincorporatedPartnership**. Possible values for unincorporated partnership members: **secondaryPartner**, **uboThroughControl**, **uboThroughOwnership** (required). @@ -216,9 +216,9 @@ protected LegalEntityAssociation() { } public string Name { get; private set; } /// - /// Default value: **false**Indicates if the `type` **director**, **secondaryPartner** or **shareholder** is a nominee. Only applicable to New Zealand. + /// Default value: **false** Set to **true** if the entity association `type` **director**, **secondaryPartner** or **shareholder** is also a nominee. Only applicable to New Zealand. /// - /// Default value: **false**Indicates if the `type` **director**, **secondaryPartner** or **shareholder** is a nominee. Only applicable to New Zealand. + /// Default value: **false** Set to **true** if the entity association `type` **director**, **secondaryPartner** or **shareholder** is also a nominee. Only applicable to New Zealand. [DataMember(Name = "nominee", EmitDefaultValue = false)] public bool? Nominee { get; set; } diff --git a/Adyen/Model/LegalEntityManagement/SourceOfFunds.cs b/Adyen/Model/LegalEntityManagement/SourceOfFunds.cs index 5820c30a..86af0a8e 100644 --- a/Adyen/Model/LegalEntityManagement/SourceOfFunds.cs +++ b/Adyen/Model/LegalEntityManagement/SourceOfFunds.cs @@ -57,7 +57,7 @@ public enum TypeEnum /// /// Initializes a new instance of the class. /// - /// The unique identifier of the business line that will be the source of funds.This must be a business line for a **receivePayments** or **receiveFromPlatformPayments** capability.. + /// The unique identifier of the business line that is the source of funds.This must be a business line for a **receivePayments** or **receiveFromPlatformPayments** capability.. /// Indicates whether the funds are coming from transactions processed by Adyen. If **false**, a `description` is required.. /// Text describing the source of funds. For example, for `type` **business**, provide a description of where the business transactions come from, such as payments through bank transfer. Required when `adyenProcessedFunds` is **false**.. /// The type of the source of funds. Possible value: **business**.. @@ -70,9 +70,9 @@ public enum TypeEnum } /// - /// The unique identifier of the business line that will be the source of funds.This must be a business line for a **receivePayments** or **receiveFromPlatformPayments** capability. + /// The unique identifier of the business line that is the source of funds.This must be a business line for a **receivePayments** or **receiveFromPlatformPayments** capability. /// - /// The unique identifier of the business line that will be the source of funds.This must be a business line for a **receivePayments** or **receiveFromPlatformPayments** capability. + /// The unique identifier of the business line that is the source of funds.This must be a business line for a **receivePayments** or **receiveFromPlatformPayments** capability. [DataMember(Name = "acquiringBusinessLineId", EmitDefaultValue = false)] [Obsolete("Deprecated since Legal Entity Management API v3. This field will be removed in v4.")] public string AcquiringBusinessLineId { get; set; } diff --git a/Adyen/Service/BalancePlatform/GrantAccountsService.cs b/Adyen/Service/BalancePlatform/GrantAccountsService.cs index 9dbb44bc..28bbcbc5 100644 --- a/Adyen/Service/BalancePlatform/GrantAccountsService.cs +++ b/Adyen/Service/BalancePlatform/GrantAccountsService.cs @@ -30,6 +30,7 @@ public interface IGrantAccountsService /// - The unique identifier of the grant account. /// - Additional request options. /// . + [Obsolete("Deprecated since Configuration API v2. Use the `/grantAccounts/{id}` endpoint from the [Capital API](https://docs.adyen.com/api-explorer/capital/latest/get/grantAccounts/(id)) instead.")] Model.BalancePlatform.CapitalGrantAccount GetGrantAccount(string id, RequestOptions requestOptions = default); /// @@ -39,6 +40,7 @@ public interface IGrantAccountsService /// - Additional request options. /// A CancellationToken enables cooperative cancellation between threads, thread pool work items, or Task objects. /// Task of . + [Obsolete("Deprecated since Configuration API v2. Use the `/grantAccounts/{id}` endpoint from the [Capital API](https://docs.adyen.com/api-explorer/capital/latest/get/grantAccounts/(id)) instead.")] Task GetGrantAccountAsync(string id, RequestOptions requestOptions = default, CancellationToken cancellationToken = default); } @@ -55,11 +57,13 @@ public GrantAccountsService(Client client) : base(client) _baseUrl = CreateBaseUrl("https://balanceplatform-api-test.adyen.com/bcl/v2"); } + [Obsolete("Deprecated since Configuration API v2. Use the `/grantAccounts/{id}` endpoint from the [Capital API](https://docs.adyen.com/api-explorer/capital/latest/get/grantAccounts/(id)) instead.")] public Model.BalancePlatform.CapitalGrantAccount GetGrantAccount(string id, RequestOptions requestOptions = default) { return GetGrantAccountAsync(id, requestOptions).ConfigureAwait(false).GetAwaiter().GetResult(); } + [Obsolete("Deprecated since Configuration API v2. Use the `/grantAccounts/{id}` endpoint from the [Capital API](https://docs.adyen.com/api-explorer/capital/latest/get/grantAccounts/(id)) instead.")] public async Task GetGrantAccountAsync(string id, RequestOptions requestOptions = default, CancellationToken cancellationToken = default) { var endpoint = _baseUrl + $"/grantAccounts/{id}"; diff --git a/Adyen/Service/BalancePlatform/GrantOffersService.cs b/Adyen/Service/BalancePlatform/GrantOffersService.cs index 80c4ceef..347f55d5 100644 --- a/Adyen/Service/BalancePlatform/GrantOffersService.cs +++ b/Adyen/Service/BalancePlatform/GrantOffersService.cs @@ -30,6 +30,7 @@ public interface IGrantOffersService /// - The unique identifier of the grant account. /// - Additional request options. /// . + [Obsolete("Deprecated since Configuration API v2. Use the `/grantOffers` endpoint from the [Capital API](https://docs.adyen.com/api-explorer/capital/latest/get/grantOffers) instead.")] Model.BalancePlatform.GrantOffers GetAllAvailableGrantOffers(string accountHolderId, RequestOptions requestOptions = default); /// @@ -39,6 +40,7 @@ public interface IGrantOffersService /// - Additional request options. /// A CancellationToken enables cooperative cancellation between threads, thread pool work items, or Task objects. /// Task of . + [Obsolete("Deprecated since Configuration API v2. Use the `/grantOffers` endpoint from the [Capital API](https://docs.adyen.com/api-explorer/capital/latest/get/grantOffers) instead.")] Task GetAllAvailableGrantOffersAsync(string accountHolderId, RequestOptions requestOptions = default, CancellationToken cancellationToken = default); /// @@ -47,6 +49,7 @@ public interface IGrantOffersService /// - The unique identifier of the grant offer. /// - Additional request options. /// . + [Obsolete("Deprecated since Configuration API v2. Use the `/grantOffers/{id}` endpoint from the [Capital API](https://docs.adyen.com/api-explorer/capital/latest/get/grantOffers/(id)) instead.")] Model.BalancePlatform.GrantOffer GetGrantOffer(string grantOfferId, RequestOptions requestOptions = default); /// @@ -56,6 +59,7 @@ public interface IGrantOffersService /// - Additional request options. /// A CancellationToken enables cooperative cancellation between threads, thread pool work items, or Task objects. /// Task of . + [Obsolete("Deprecated since Configuration API v2. Use the `/grantOffers/{id}` endpoint from the [Capital API](https://docs.adyen.com/api-explorer/capital/latest/get/grantOffers/(id)) instead.")] Task GetGrantOfferAsync(string grantOfferId, RequestOptions requestOptions = default, CancellationToken cancellationToken = default); } @@ -72,11 +76,13 @@ public GrantOffersService(Client client) : base(client) _baseUrl = CreateBaseUrl("https://balanceplatform-api-test.adyen.com/bcl/v2"); } + [Obsolete("Deprecated since Configuration API v2. Use the `/grantOffers` endpoint from the [Capital API](https://docs.adyen.com/api-explorer/capital/latest/get/grantOffers) instead.")] public Model.BalancePlatform.GrantOffers GetAllAvailableGrantOffers(string accountHolderId, RequestOptions requestOptions = default) { return GetAllAvailableGrantOffersAsync(accountHolderId, requestOptions).ConfigureAwait(false).GetAwaiter().GetResult(); } + [Obsolete("Deprecated since Configuration API v2. Use the `/grantOffers` endpoint from the [Capital API](https://docs.adyen.com/api-explorer/capital/latest/get/grantOffers) instead.")] public async Task GetAllAvailableGrantOffersAsync(string accountHolderId, RequestOptions requestOptions = default, CancellationToken cancellationToken = default) { // Build the query string @@ -87,11 +93,13 @@ public Model.BalancePlatform.GrantOffers GetAllAvailableGrantOffers(string accou return await resource.RequestAsync(null, requestOptions, new HttpMethod("GET"), cancellationToken).ConfigureAwait(false); } + [Obsolete("Deprecated since Configuration API v2. Use the `/grantOffers/{id}` endpoint from the [Capital API](https://docs.adyen.com/api-explorer/capital/latest/get/grantOffers/(id)) instead.")] public Model.BalancePlatform.GrantOffer GetGrantOffer(string grantOfferId, RequestOptions requestOptions = default) { return GetGrantOfferAsync(grantOfferId, requestOptions).ConfigureAwait(false).GetAwaiter().GetResult(); } + [Obsolete("Deprecated since Configuration API v2. Use the `/grantOffers/{id}` endpoint from the [Capital API](https://docs.adyen.com/api-explorer/capital/latest/get/grantOffers/(id)) instead.")] public async Task GetGrantOfferAsync(string grantOfferId, RequestOptions requestOptions = default, CancellationToken cancellationToken = default) { var endpoint = _baseUrl + $"/grantOffers/{grantOfferId}"; diff --git a/Adyen/Service/BalancePlatform/ManageSCADevicesService.cs b/Adyen/Service/BalancePlatform/ManageSCADevicesService.cs index 7a572d50..be9278d7 100644 --- a/Adyen/Service/BalancePlatform/ManageSCADevicesService.cs +++ b/Adyen/Service/BalancePlatform/ManageSCADevicesService.cs @@ -24,6 +24,25 @@ namespace Adyen.Service.BalancePlatform /// public interface IManageSCADevicesService { + /// + /// Complete an association between an SCA device and a resource + /// + /// - The unique identifier of the SCA device that you are associating with a resource. + /// - + /// - Additional request options. + /// . + Model.BalancePlatform.AssociationFinaliseResponse CompleteAssociationBetweenScaDeviceAndResource(string deviceId, AssociationFinaliseRequest associationFinaliseRequest = default, RequestOptions requestOptions = default); + + /// + /// Complete an association between an SCA device and a resource + /// + /// - The unique identifier of the SCA device that you are associating with a resource. + /// - + /// - Additional request options. + /// A CancellationToken enables cooperative cancellation between threads, thread pool work items, or Task objects. + /// Task of . + Task CompleteAssociationBetweenScaDeviceAndResourceAsync(string deviceId, AssociationFinaliseRequest associationFinaliseRequest = default, RequestOptions requestOptions = default, CancellationToken cancellationToken = default); + /// /// Complete the registration of an SCA device /// @@ -60,6 +79,25 @@ public interface IManageSCADevicesService /// A CancellationToken enables cooperative cancellation between threads, thread pool work items, or Task objects. Task DeleteRegistrationOfScaDeviceAsync(string id, string paymentInstrumentId, RequestOptions requestOptions = default, CancellationToken cancellationToken = default); + /// + /// Initiate an association between an SCA device and a resource + /// + /// - The unique identifier of the SCA device that you are associating with a resource. + /// - + /// - Additional request options. + /// . + Model.BalancePlatform.AssociationInitiateResponse InitiateAssociationBetweenScaDeviceAndResource(string deviceId, AssociationInitiateRequest associationInitiateRequest = default, RequestOptions requestOptions = default); + + /// + /// Initiate an association between an SCA device and a resource + /// + /// - The unique identifier of the SCA device that you are associating with a resource. + /// - + /// - Additional request options. + /// A CancellationToken enables cooperative cancellation between threads, thread pool work items, or Task objects. + /// Task of . + Task InitiateAssociationBetweenScaDeviceAndResourceAsync(string deviceId, AssociationInitiateRequest associationInitiateRequest = default, RequestOptions requestOptions = default, CancellationToken cancellationToken = default); + /// /// Initiate the registration of an SCA device /// @@ -112,6 +150,18 @@ public ManageSCADevicesService(Client client) : base(client) _baseUrl = CreateBaseUrl("https://balanceplatform-api-test.adyen.com/bcl/v2"); } + public Model.BalancePlatform.AssociationFinaliseResponse CompleteAssociationBetweenScaDeviceAndResource(string deviceId, AssociationFinaliseRequest associationFinaliseRequest = default, RequestOptions requestOptions = default) + { + return CompleteAssociationBetweenScaDeviceAndResourceAsync(deviceId, associationFinaliseRequest, requestOptions).ConfigureAwait(false).GetAwaiter().GetResult(); + } + + public async Task CompleteAssociationBetweenScaDeviceAndResourceAsync(string deviceId, AssociationFinaliseRequest associationFinaliseRequest = default, RequestOptions requestOptions = default, CancellationToken cancellationToken = default) + { + var endpoint = _baseUrl + $"/registeredDevices/{deviceId}/associations"; + var resource = new ServiceResource(this, endpoint); + return await resource.RequestAsync(associationFinaliseRequest.ToJson(), requestOptions, new HttpMethod("PATCH"), cancellationToken).ConfigureAwait(false); + } + public Model.BalancePlatform.RegisterSCAFinalResponse CompleteRegistrationOfScaDevice(string id, RegisterSCARequest registerSCARequest = default, RequestOptions requestOptions = default) { return CompleteRegistrationOfScaDeviceAsync(id, registerSCARequest, requestOptions).ConfigureAwait(false).GetAwaiter().GetResult(); @@ -139,6 +189,18 @@ public async Task DeleteRegistrationOfScaDeviceAsync(string id, string paymentIn await resource.RequestAsync(null, requestOptions, new HttpMethod("DELETE"), cancellationToken).ConfigureAwait(false); } + public Model.BalancePlatform.AssociationInitiateResponse InitiateAssociationBetweenScaDeviceAndResource(string deviceId, AssociationInitiateRequest associationInitiateRequest = default, RequestOptions requestOptions = default) + { + return InitiateAssociationBetweenScaDeviceAndResourceAsync(deviceId, associationInitiateRequest, requestOptions).ConfigureAwait(false).GetAwaiter().GetResult(); + } + + public async Task InitiateAssociationBetweenScaDeviceAndResourceAsync(string deviceId, AssociationInitiateRequest associationInitiateRequest = default, RequestOptions requestOptions = default, CancellationToken cancellationToken = default) + { + var endpoint = _baseUrl + $"/registeredDevices/{deviceId}/associations"; + var resource = new ServiceResource(this, endpoint); + return await resource.RequestAsync(associationInitiateRequest.ToJson(), requestOptions, new HttpMethod("POST"), cancellationToken).ConfigureAwait(false); + } + public Model.BalancePlatform.RegisterSCAResponse InitiateRegistrationOfScaDevice(RegisterSCARequest registerSCARequest = default, RequestOptions requestOptions = default) { return InitiateRegistrationOfScaDeviceAsync(registerSCARequest, requestOptions).ConfigureAwait(false).GetAwaiter().GetResult();