1111
1212package com .adyen .model .acswebhooks ;
1313
14+ import com .fasterxml .jackson .annotation .JsonCreator ;
1415import com .fasterxml .jackson .annotation .JsonInclude ;
1516import com .fasterxml .jackson .annotation .JsonProperty ;
1617import com .fasterxml .jackson .annotation .JsonPropertyOrder ;
18+ import com .fasterxml .jackson .annotation .JsonValue ;
1719import com .fasterxml .jackson .core .JsonProcessingException ;
20+ import java .time .OffsetDateTime ;
1821import java .util .Objects ;
1922
2023/** RelayedAuthenticationRequest */
2124@ JsonPropertyOrder ({
25+ RelayedAuthenticationRequest .JSON_PROPERTY_ENVIRONMENT ,
2226 RelayedAuthenticationRequest .JSON_PROPERTY_ID ,
2327 RelayedAuthenticationRequest .JSON_PROPERTY_PAYMENT_INSTRUMENT_ID ,
24- RelayedAuthenticationRequest .JSON_PROPERTY_PURCHASE
28+ RelayedAuthenticationRequest .JSON_PROPERTY_PURCHASE ,
29+ RelayedAuthenticationRequest .JSON_PROPERTY_THREE_D_S_REQUESTOR_APP_U_R_L ,
30+ RelayedAuthenticationRequest .JSON_PROPERTY_TIMESTAMP ,
31+ RelayedAuthenticationRequest .JSON_PROPERTY_TYPE
2532})
2633public class RelayedAuthenticationRequest {
34+ public static final String JSON_PROPERTY_ENVIRONMENT = "environment" ;
35+ private String environment ;
36+
2737 public static final String JSON_PROPERTY_ID = "id" ;
2838 private String id ;
2939
@@ -33,8 +43,85 @@ public class RelayedAuthenticationRequest {
3343 public static final String JSON_PROPERTY_PURCHASE = "purchase" ;
3444 private Purchase purchase ;
3545
46+ public static final String JSON_PROPERTY_THREE_D_S_REQUESTOR_APP_U_R_L = "threeDSRequestorAppURL" ;
47+ private String threeDSRequestorAppURL ;
48+
49+ public static final String JSON_PROPERTY_TIMESTAMP = "timestamp" ;
50+ private OffsetDateTime timestamp ;
51+
52+ /** Type of notification. */
53+ public enum TypeEnum {
54+ BALANCEPLATFORM_AUTHENTICATION_RELAYED (
55+ String .valueOf ("balancePlatform.authentication.relayed" ));
56+
57+ private String value ;
58+
59+ TypeEnum (String value ) {
60+ this .value = value ;
61+ }
62+
63+ @ JsonValue
64+ public String getValue () {
65+ return value ;
66+ }
67+
68+ @ Override
69+ public String toString () {
70+ return String .valueOf (value );
71+ }
72+
73+ @ JsonCreator
74+ public static TypeEnum fromValue (String value ) {
75+ for (TypeEnum b : TypeEnum .values ()) {
76+ if (b .value .equals (value )) {
77+ return b ;
78+ }
79+ }
80+ throw new IllegalArgumentException ("Unexpected value '" + value + "'" );
81+ }
82+ }
83+
84+ public static final String JSON_PROPERTY_TYPE = "type" ;
85+ private TypeEnum type ;
86+
3687 public RelayedAuthenticationRequest () {}
3788
89+ /**
90+ * The environment from which the webhook originated. Possible values: **test**, **live**.
91+ *
92+ * @param environment The environment from which the webhook originated. Possible values:
93+ * **test**, **live**.
94+ * @return the current {@code RelayedAuthenticationRequest} instance, allowing for method chaining
95+ */
96+ public RelayedAuthenticationRequest environment (String environment ) {
97+ this .environment = environment ;
98+ return this ;
99+ }
100+
101+ /**
102+ * The environment from which the webhook originated. Possible values: **test**, **live**.
103+ *
104+ * @return environment The environment from which the webhook originated. Possible values:
105+ * **test**, **live**.
106+ */
107+ @ JsonProperty (JSON_PROPERTY_ENVIRONMENT )
108+ @ JsonInclude (value = JsonInclude .Include .USE_DEFAULTS )
109+ public String getEnvironment () {
110+ return environment ;
111+ }
112+
113+ /**
114+ * The environment from which the webhook originated. Possible values: **test**, **live**.
115+ *
116+ * @param environment The environment from which the webhook originated. Possible values:
117+ * **test**, **live**.
118+ */
119+ @ JsonProperty (JSON_PROPERTY_ENVIRONMENT )
120+ @ JsonInclude (value = JsonInclude .Include .USE_DEFAULTS )
121+ public void setEnvironment (String environment ) {
122+ this .environment = environment ;
123+ }
124+
38125 /**
39126 * The unique identifier of the challenge.
40127 *
@@ -146,6 +233,111 @@ public void setPurchase(Purchase purchase) {
146233 this .purchase = purchase ;
147234 }
148235
236+ /**
237+ * URL for auto-switching to the threeDS Requestor App. If not present, the threeDS Requestor App
238+ * doesn't support auto-switching.
239+ *
240+ * @param threeDSRequestorAppURL URL for auto-switching to the threeDS Requestor App. If not
241+ * present, the threeDS Requestor App doesn't support auto-switching.
242+ * @return the current {@code RelayedAuthenticationRequest} instance, allowing for method chaining
243+ */
244+ public RelayedAuthenticationRequest threeDSRequestorAppURL (String threeDSRequestorAppURL ) {
245+ this .threeDSRequestorAppURL = threeDSRequestorAppURL ;
246+ return this ;
247+ }
248+
249+ /**
250+ * URL for auto-switching to the threeDS Requestor App. If not present, the threeDS Requestor App
251+ * doesn't support auto-switching.
252+ *
253+ * @return threeDSRequestorAppURL URL for auto-switching to the threeDS Requestor App. If not
254+ * present, the threeDS Requestor App doesn't support auto-switching.
255+ */
256+ @ JsonProperty (JSON_PROPERTY_THREE_D_S_REQUESTOR_APP_U_R_L )
257+ @ JsonInclude (value = JsonInclude .Include .USE_DEFAULTS )
258+ public String getThreeDSRequestorAppURL () {
259+ return threeDSRequestorAppURL ;
260+ }
261+
262+ /**
263+ * URL for auto-switching to the threeDS Requestor App. If not present, the threeDS Requestor App
264+ * doesn't support auto-switching.
265+ *
266+ * @param threeDSRequestorAppURL URL for auto-switching to the threeDS Requestor App. If not
267+ * present, the threeDS Requestor App doesn't support auto-switching.
268+ */
269+ @ JsonProperty (JSON_PROPERTY_THREE_D_S_REQUESTOR_APP_U_R_L )
270+ @ JsonInclude (value = JsonInclude .Include .USE_DEFAULTS )
271+ public void setThreeDSRequestorAppURL (String threeDSRequestorAppURL ) {
272+ this .threeDSRequestorAppURL = threeDSRequestorAppURL ;
273+ }
274+
275+ /**
276+ * When the event was queued.
277+ *
278+ * @param timestamp When the event was queued.
279+ * @return the current {@code RelayedAuthenticationRequest} instance, allowing for method chaining
280+ */
281+ public RelayedAuthenticationRequest timestamp (OffsetDateTime timestamp ) {
282+ this .timestamp = timestamp ;
283+ return this ;
284+ }
285+
286+ /**
287+ * When the event was queued.
288+ *
289+ * @return timestamp When the event was queued.
290+ */
291+ @ JsonProperty (JSON_PROPERTY_TIMESTAMP )
292+ @ JsonInclude (value = JsonInclude .Include .USE_DEFAULTS )
293+ public OffsetDateTime getTimestamp () {
294+ return timestamp ;
295+ }
296+
297+ /**
298+ * When the event was queued.
299+ *
300+ * @param timestamp When the event was queued.
301+ */
302+ @ JsonProperty (JSON_PROPERTY_TIMESTAMP )
303+ @ JsonInclude (value = JsonInclude .Include .USE_DEFAULTS )
304+ public void setTimestamp (OffsetDateTime timestamp ) {
305+ this .timestamp = timestamp ;
306+ }
307+
308+ /**
309+ * Type of notification.
310+ *
311+ * @param type Type of notification.
312+ * @return the current {@code RelayedAuthenticationRequest} instance, allowing for method chaining
313+ */
314+ public RelayedAuthenticationRequest type (TypeEnum type ) {
315+ this .type = type ;
316+ return this ;
317+ }
318+
319+ /**
320+ * Type of notification.
321+ *
322+ * @return type Type of notification.
323+ */
324+ @ JsonProperty (JSON_PROPERTY_TYPE )
325+ @ JsonInclude (value = JsonInclude .Include .USE_DEFAULTS )
326+ public TypeEnum getType () {
327+ return type ;
328+ }
329+
330+ /**
331+ * Type of notification.
332+ *
333+ * @param type Type of notification.
334+ */
335+ @ JsonProperty (JSON_PROPERTY_TYPE )
336+ @ JsonInclude (value = JsonInclude .Include .USE_DEFAULTS )
337+ public void setType (TypeEnum type ) {
338+ this .type = type ;
339+ }
340+
149341 /** Return true if this RelayedAuthenticationRequest object is equal to o. */
150342 @ Override
151343 public boolean equals (Object o ) {
@@ -156,26 +348,38 @@ public boolean equals(Object o) {
156348 return false ;
157349 }
158350 RelayedAuthenticationRequest relayedAuthenticationRequest = (RelayedAuthenticationRequest ) o ;
159- return Objects .equals (this .id , relayedAuthenticationRequest .id )
351+ return Objects .equals (this .environment , relayedAuthenticationRequest .environment )
352+ && Objects .equals (this .id , relayedAuthenticationRequest .id )
160353 && Objects .equals (
161354 this .paymentInstrumentId , relayedAuthenticationRequest .paymentInstrumentId )
162- && Objects .equals (this .purchase , relayedAuthenticationRequest .purchase );
355+ && Objects .equals (this .purchase , relayedAuthenticationRequest .purchase )
356+ && Objects .equals (
357+ this .threeDSRequestorAppURL , relayedAuthenticationRequest .threeDSRequestorAppURL )
358+ && Objects .equals (this .timestamp , relayedAuthenticationRequest .timestamp )
359+ && Objects .equals (this .type , relayedAuthenticationRequest .type );
163360 }
164361
165362 @ Override
166363 public int hashCode () {
167- return Objects .hash (id , paymentInstrumentId , purchase );
364+ return Objects .hash (
365+ environment , id , paymentInstrumentId , purchase , threeDSRequestorAppURL , timestamp , type );
168366 }
169367
170368 @ Override
171369 public String toString () {
172370 StringBuilder sb = new StringBuilder ();
173371 sb .append ("class RelayedAuthenticationRequest {\n " );
372+ sb .append (" environment: " ).append (toIndentedString (environment )).append ("\n " );
174373 sb .append (" id: " ).append (toIndentedString (id )).append ("\n " );
175374 sb .append (" paymentInstrumentId: " )
176375 .append (toIndentedString (paymentInstrumentId ))
177376 .append ("\n " );
178377 sb .append (" purchase: " ).append (toIndentedString (purchase )).append ("\n " );
378+ sb .append (" threeDSRequestorAppURL: " )
379+ .append (toIndentedString (threeDSRequestorAppURL ))
380+ .append ("\n " );
381+ sb .append (" timestamp: " ).append (toIndentedString (timestamp )).append ("\n " );
382+ sb .append (" type: " ).append (toIndentedString (type )).append ("\n " );
179383 sb .append ("}" );
180384 return sb .toString ();
181385 }
0 commit comments