Пример #1
0
 /// <summary>
 /// Initializes a new instance of the <see cref="PaymentResponse" /> class.
 /// </summary>
 /// <param name="action">Action to be taken for completing the payment..</param>
 /// <param name="additionalData">This field contains additional data, which may be required to return in a particular payment response. To choose data fields to be returned, go to **Customer Area** &gt; **Account** &gt; **API URLs** &gt; **Additional data settings**..</param>
 /// <param name="amount">amount.</param>
 /// <param name="authentication">Contains &#x60;threeds2.fingerprint&#x60; or &#x60;threeds2.challengeToken&#x60; values to be used in further calls to &#x60;/payments/details&#x60; endpoint. .</param>
 /// <param name="details">When non-empty, contains all the fields that you must submit to the &#x60;/payments/details&#x60; endpoint..</param>
 /// <param name="donationToken">donationToken.</param>
 /// <param name="fraudResult">fraudResult.</param>
 /// <param name="merchantReference">The reference to uniquely identify a payment. This reference is used in all communication with you about the payment status. We recommend using a unique value per payment; however, it is not a requirement. If you need to provide multiple references for a transaction, separate them with hyphens (\&quot;-\&quot;). Maximum length: 80 characters..</param>
 /// <param name="order">order.</param>
 /// <param name="outputDetails">Contains the details that will be presented to the shopper..</param>
 /// <param name="paymentData">When non-empty, contains a value that you must submit to the &#x60;/payments/details&#x60; endpoint..</param>
 /// <param name="pspReference">Adyen&#x27;s 16-character string reference associated with the transaction/request. This value is globally unique; quote it when communicating with us about this request.  &gt; &#x60;pspReference&#x60; is returned only for non-redirect payment methods..</param>
 /// <param name="redirect">redirect.</param>
 /// <param name="refusalReason">If the payment&#x27;s authorisation is refused or an error occurs during authorisation, this field holds Adyen&#x27;s mapped reason for the refusal or a description of the error. When a transaction fails, the authorisation response includes &#x60;resultCode&#x60; and &#x60;refusalReason&#x60; values.  For more information, see [Refusal reasons](https://docs.adyen.com/development-resources/refusal-reasons)..</param>
 /// <param name="refusalReasonCode">Code that specifies the refusal reason. For more information, see [Authorisation refusal reasons](https://docs.adyen.com/development-resources/refusal-reasons)..</param>
 /// <param name="resultCode">The result of the payment. For more information, see [Result codes](https://docs.adyen.com/checkout/payment-result-codes).  Possible values:  * **AuthenticationFinished** – The payment has been successfully authenticated with 3D Secure 2. Returned for 3D Secure 2 authentication-only transactions. * **AuthenticationNotRequired** – The transaction does not require 3D Secure authentication. Returned for [standalone authentication-only integrations](https://docs.adyen.com/checkout/3d-secure/other-3ds-flows/authentication-only). * **Authorised** – The payment was successfully authorised. This state serves as an indicator to proceed with the delivery of goods and services. This is a final state. * **Cancelled** – Indicates the payment has been cancelled (either by the shopper or the merchant) before processing was completed. This is a final state. * **ChallengeShopper** – The issuer requires further shopper interaction before the payment can be authenticated. Returned for 3D Secure 2 transactions. * **Error** – There was an error when the payment was being processed. The reason is given in the &#x60;refusalReason&#x60; field. This is a final state. * **IdentifyShopper** – The issuer requires the shopper&#x27;s device fingerprint before the payment can be authenticated. Returned for 3D Secure 2 transactions. * **Pending** – Indicates that it is not possible to obtain the final status of the payment. This can happen if the systems providing final status information for the payment are unavailable, or if the shopper needs to take further action to complete the payment. * **PresentToShopper** – Indicates that the response contains additional information that you need to present to a shopper, so that they can use it to complete a payment. * **Received** – Indicates the payment has successfully been received by Adyen, and will be processed. This is the initial state for all payments. * **RedirectShopper** – Indicates the shopper should be redirected to an external web page or app to complete the authorisation. * **Refused** – Indicates the payment was refused. The reason is given in the &#x60;refusalReason&#x60; field. This is a final state..</param>
 public PaymentResponse(IPaymentResponseAction action = default(IPaymentResponseAction),
                        Dictionary <string, string> additionalData = default(Dictionary <string, string>),
                        Amount amount = default(Amount),
                        Dictionary <string, string> authentication = default(Dictionary <string, string>),
                        List <InputDetail> details  = default(List <InputDetail>), string donationToken = default(string),
                        FraudResult fraudResult     = default(FraudResult), string merchantReference    = default(string),
                        CheckoutOrderResponse order = default(CheckoutOrderResponse),
                        Dictionary <string, string> outputDetails = default(Dictionary <string, string>),
                        string paymentData       = default(string), string pspReference       = default(string),
                        Redirect redirect        = default(Redirect), string refusalReason    = default(string),
                        string refusalReasonCode = default(string), ResultCodeEnum?resultCode = default(ResultCodeEnum?))
 {
     this.Action            = action;
     this.AdditionalData    = additionalData;
     this.Amount            = amount;
     this.Authentication    = authentication;
     this.Details           = details;
     this.DonationToken     = donationToken;
     this.FraudResult       = fraudResult;
     this.MerchantReference = merchantReference;
     this.Order             = order;
     this.OutputDetails     = outputDetails;
     this.PaymentData       = paymentData;
     this.PspReference      = pspReference;
     this.Redirect          = redirect;
     this.RefusalReason     = refusalReason;
     this.RefusalReasonCode = refusalReasonCode;
     this.ResultCode        = resultCode;
 }
 /// <summary>
 /// Initializes a new instance of the <see cref="PaymentsResponse" /> class.
 /// </summary>
 /// <param name="additionalData">This field contains additional data, which may be required to return in a particular payment response. To choose data fields to be returned, go to **Customer Area** &gt; **Account** &gt; **API URLs**..</param>
 /// <param name="authentication">Contains &#x60;threeds2.fingerprint&#x60; or &#x60;threeds2.challengeToken&#x60; values to be used in further calls to &#x60;/payments/details&#x60; endpoint. .</param>
 /// <param name="details">When non-empty, contains all the fields that you must submit to the &#x60;/payments/details&#x60; endpoint..</param>
 /// <param name="fraudResult">fraudResult.</param>
 /// <param name="merchantReference">The reference to uniquely identify a payment. This reference is used in all communication with you about the payment status. We recommend using a unique value per payment; however, it is not a requirement. If you need to provide multiple references for a transaction, separate them with hyphens (\&quot;-\&quot;). Maximum length: 80 characters. (required).</param>
 /// <param name="outputDetails">Contains the details that will be presented to the shopper..</param>
 /// <param name="paymentData">When non-empty, contains a value that you must submit to the &#x60;/payments/details&#x60; endpoint..</param>
 /// <param name="pspReference">Adyen&#x27;s 16-character string reference associated with the transaction/request. This value is globally unique; quote it when communicating with us about this request.  &gt; &#x60;pspReference&#x60; is returned only for non-redirect payment methods..</param>
 /// <param name="redirect">redirect.</param>
 /// <param name="refusalReason">If the payment&#x27;s authorisation is refused or an error occurs during authorisation, this field holds Adyen&#x27;s mapped reason for the refusal or a description of the error.  When a transaction fails, the authorisation response includes &#x60;resultCode&#x60; and &#x60;refusalReason&#x60; values..</param>
 /// <param name="refusalReasonCode">Code that specifies the refusal reason. For more information, see [Authorisation refusal reasons](https://docs.adyen.com/development-resources/refusal-reasons)..</param>
 /// <param name="resultCode">The result of the payment. Possible values:  * **AuthenticationFinished** – The payment has been successfully authenticated with 3D Secure 2. Returned for 3D Secure 2 authentication-only transactions. * **Authorised** – The payment was successfully authorised. This state serves as an indicator to proceed with the delivery of goods and services. This is a final state. * **Cancelled** – Indicates the payment has been cancelled (either by the shopper or the merchant) before processing was completed. This is a final state. * **ChallengeShopper** – The issuer requires further shopper interaction before the payment can be authenticated. Returned for 3D Secure 2 transactions. * **Error** – There was an error when the payment was being processed. The reason is given in the &#x60;refusalReason&#x60; field. This is a final state. * **IdentifyShopper** – The issuer requires the shopper&#x27;s device fingerprint before the payment can be authenticated. Returned for 3D Secure 2 transactions. * **Refused** – Indicates the payment was refused. The reason is given in the &#x60;refusalReason&#x60; field. This is a final state. * **Pending** – Indicates that it is not possible to obtain the final status of the payment. This can happen if the systems providing final status information for the payment are unavailable, or if the shopper needs to take further action to complete the payment. For more information on handling a pending payment, refer to [Payments with pending status](https://docs.adyen.com/development-resources/payments-with-pending-status). * **Received** – Indicates the payment has successfully been received by Adyen, and will be processed. This is the initial state for all payments. * **RedirectShopper** – Indicates the shopper should be redirected to an external web page or app to complete the authorisation. .</param>
 /// <param name="action">If your server received an action object in the/payments response, pass the object back to your front end. Make sure that you only pass the action object and not the full response.</param>
 /// <param name="threeDS2Result">Send the property below within the threeDS2Result object to submit the results of the challenge flow</param>
 /// <param name="serviceError"></param>
 public PaymentsResponse(Dictionary <string, string> additionalData = default(Dictionary <string, string>), Dictionary <string, string> authentication = default(Dictionary <string, string>), List <InputDetail> details = default(List <InputDetail>), FraudResult fraudResult = default(FraudResult), string merchantReference = default(string), Dictionary <string, string> outputDetails = default(Dictionary <string, string>), string paymentData = default(string), string pspReference = default(string), Redirect redirect = default(Redirect), string refusalReason = default(string), string refusalReasonCode = default(string), ResultCodeEnum?resultCode = default(ResultCodeEnum?), CheckoutPaymentsAction action = default(CheckoutPaymentsAction), ThreeDS2Result threeDS2Result = default(ThreeDS2Result), ServiceError serviceError = default(ServiceError))
 {
     this.AdditionalData    = additionalData;
     this.Authentication    = authentication;
     this.Details           = details;
     this.FraudResult       = fraudResult;
     this.OutputDetails     = outputDetails;
     this.PaymentData       = paymentData;
     this.PspReference      = pspReference;
     this.Redirect          = redirect;
     this.RefusalReason     = refusalReason;
     this.RefusalReasonCode = refusalReasonCode;
     this.ResultCode        = resultCode;
     this.Action            = action;
     this.MerchantReference = merchantReference;
     this.ServiceError      = serviceError;
     this.ThreeDS2Result    = threeDS2Result;
 }
Пример #3
0
 /// <summary>
 /// Initializes a new instance of the <see cref="PaymentsResponse" /> class.
 /// </summary>
 /// <param name="AdditionalData">This field contains additional data, which may be required to return in a particular payment response. To choose data fields to be returned, go to **Customer Area** &gt; **Account** &gt; **API URLs**..</param>
 /// <param name="Details">When non-empty, contains all the fields that you must submit to the &#x60;/payments/details&#x60; endpoint..</param>
 /// <param name="FraudResult">The fraud result properties of the payment..</param>
 /// <param name="PaymentData">When non-empty, contains a value that you must submit to the &#x60;/payments/details&#x60; endpoint..</param>
 /// <param name="PspReference">Adyen&#39;s 16-character string reference associated with the transaction/request. This value is globally unique; quote it when communicating with us about this request.  &gt; &#x60;pspReference&#x60; is returned only for non-redirect payment methods..</param>
 /// <param name="Redirect">When the payment flow requires a redirect, this object contains information about the redirect URL..</param>
 /// <param name="RefusalReason">If the payment&#39;s authorisation is refused or an error occurs during authorisation, this field holds Adyen&#39;s mapped reason for the refusal or a description of the error.  When a transaction fails, the authorisation response includes &#x60;resultCode&#x60; and &#x60;refusalReason&#x60; values..</param>
 /// <param name="RefusalReasonCode">Code that specifies the refusal reason. For more information, see [Authorisation refusal reasons](https://docs.adyen.com/developers/development-resources/response-handling#authorisationrefusalreasons)..</param>
 /// <param name="ResultCode">The result of the payment. Possible values:  * **Authorised** – Indicates the payment authorisation was successfully completed. This state serves as an indicator to proceed with the delivery of goods and services. This is a final state. * **Refused** – Indicates the payment was refused. The reason is given in the &#x60;refusalReason&#x60; field. This is a final state. * **RedirectShopper** – Indicates the shopper should be redirected to an external web page or app to complete the authorisation. * **Received** – Indicates the payment has successfully been received by Adyen, and will be processed. This is the initial state for all payments. * **Cancelled** – Indicates the payment has been cancelled (either by the shopper or the merchant) before processing was completed. This is a final state. * **Pending** – Indicates that it is not possible to obtain the final status of the payment. This can happen if the systems providing final status information for the payment are unavailable, or if the shopper needs to take further action to complete the payment. For more information on handling a pending payment, refer to [Payments with pending status](https://docs.adyen.com/developers/development-resources/payments-with-pending-status). * **Error** – Indicates an error occurred during processing of the payment. The reason is given in the &#x60;refusalReason&#x60; field. This is a final state..</param>
 public PaymentsResponse(Dictionary <string, string> Authentication = default(Dictionary <string, string>), Dictionary <string, string> AdditionalData = default(Dictionary <string, string>), List <InputDetail> Details = default(List <InputDetail>), FraudResult FraudResult = default(FraudResult), string PaymentData = default(string), string PspReference = default(string), Redirect Redirect = default(Redirect), string RefusalReason = default(string), string RefusalReasonCode = default(string), ResultCodeEnum?ResultCode = default(ResultCodeEnum?))
 {
     this.AdditionalData    = AdditionalData;
     this.Authentication    = Authentication;
     this.Details           = Details;
     this.FraudResult       = FraudResult;
     this.PaymentData       = PaymentData;
     this.PspReference      = PspReference;
     this.Redirect          = Redirect;
     this.RefusalReason     = RefusalReason;
     this.RefusalReasonCode = RefusalReasonCode;
     this.ResultCode        = ResultCode;
 }