-
Notifications
You must be signed in to change notification settings - Fork 152
Expand file tree
/
Copy pathCreateSweepConfigurationV2.java
More file actions
1342 lines (1192 loc) · 53.8 KB
/
CreateSweepConfigurationV2.java
File metadata and controls
1342 lines (1192 loc) · 53.8 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
/*
* 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.
*/
package com.adyen.model.balanceplatform;
import com.fasterxml.jackson.annotation.JsonAnyGetter;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import com.fasterxml.jackson.annotation.JsonValue;
import com.fasterxml.jackson.core.JsonProcessingException;
import java.util.*;
import java.util.ArrayList;
import java.util.Arrays;
import java.util.List;
import java.util.logging.Logger;
/** CreateSweepConfigurationV2 */
@JsonPropertyOrder({
CreateSweepConfigurationV2.JSON_PROPERTY_CATEGORY,
CreateSweepConfigurationV2.JSON_PROPERTY_COUNTERPARTY,
CreateSweepConfigurationV2.JSON_PROPERTY_CURRENCY,
CreateSweepConfigurationV2.JSON_PROPERTY_DESCRIPTION,
CreateSweepConfigurationV2.JSON_PROPERTY_PRIORITIES,
CreateSweepConfigurationV2.JSON_PROPERTY_REASON,
CreateSweepConfigurationV2.JSON_PROPERTY_REASON_DETAIL,
CreateSweepConfigurationV2.JSON_PROPERTY_REFERENCE,
CreateSweepConfigurationV2.JSON_PROPERTY_REFERENCE_FOR_BENEFICIARY,
CreateSweepConfigurationV2.JSON_PROPERTY_SCHEDULE,
CreateSweepConfigurationV2.JSON_PROPERTY_STATUS,
CreateSweepConfigurationV2.JSON_PROPERTY_SWEEP_AMOUNT,
CreateSweepConfigurationV2.JSON_PROPERTY_TARGET_AMOUNT,
CreateSweepConfigurationV2.JSON_PROPERTY_TRIGGER_AMOUNT,
CreateSweepConfigurationV2.JSON_PROPERTY_TYPE
})
public class CreateSweepConfigurationV2 {
/**
* The type of transfer that results from the sweep. Possible values: - **bank**: Sweep to a
* [transfer
* instrument](https://docs.adyen.com/api-explorer/#/legalentity/latest/post/transferInstruments__resParam_id).
* - **internal**: Transfer to another [balance
* account](https://docs.adyen.com/api-explorer/#/balanceplatform/latest/post/balanceAccounts__resParam_id)
* within your platform. Required when setting `priorities`.
*/
public enum CategoryEnum {
BANK(String.valueOf("bank")),
INTERNAL(String.valueOf("internal")),
PLATFORMPAYMENT(String.valueOf("platformPayment"));
private static final Logger LOG = Logger.getLogger(CategoryEnum.class.getName());
private String value;
CategoryEnum(String value) {
this.value = value;
}
@JsonValue
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
@JsonCreator
public static CategoryEnum fromValue(String value) {
for (CategoryEnum b : CategoryEnum.values()) {
if (b.value.equals(value)) {
return b;
}
}
// handling unexpected value
LOG.warning(
"CategoryEnum: unexpected enum value '"
+ value
+ "' - Supported values are "
+ Arrays.toString(CategoryEnum.values()));
return null;
}
}
public static final String JSON_PROPERTY_CATEGORY = "category";
private CategoryEnum category;
/** Mark when the attribute has been explicitly set. */
private boolean isSetCategory = false;
public static final String JSON_PROPERTY_COUNTERPARTY = "counterparty";
private SweepCounterparty counterparty;
/** Mark when the attribute has been explicitly set. */
private boolean isSetCounterparty = false;
public static final String JSON_PROPERTY_CURRENCY = "currency";
private String currency;
/** Mark when the attribute has been explicitly set. */
private boolean isSetCurrency = false;
public static final String JSON_PROPERTY_DESCRIPTION = "description";
private String description;
/** Mark when the attribute has been explicitly set. */
private boolean isSetDescription = false;
/** Gets or Sets priorities */
public enum PrioritiesEnum {
CROSSBORDER(String.valueOf("crossBorder")),
FAST(String.valueOf("fast")),
INSTANT(String.valueOf("instant")),
INTERNAL(String.valueOf("internal")),
REGULAR(String.valueOf("regular")),
WIRE(String.valueOf("wire"));
private static final Logger LOG = Logger.getLogger(PrioritiesEnum.class.getName());
private String value;
PrioritiesEnum(String value) {
this.value = value;
}
@JsonValue
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
@JsonCreator
public static PrioritiesEnum fromValue(String value) {
for (PrioritiesEnum b : PrioritiesEnum.values()) {
if (b.value.equals(value)) {
return b;
}
}
// handling unexpected value
LOG.warning(
"PrioritiesEnum: unexpected enum value '"
+ value
+ "' - Supported values are "
+ Arrays.toString(PrioritiesEnum.values()));
return null;
}
}
public static final String JSON_PROPERTY_PRIORITIES = "priorities";
private List<PrioritiesEnum> priorities;
/** Mark when the attribute has been explicitly set. */
private boolean isSetPriorities = false;
/** The reason for disabling the sweep. */
public enum ReasonEnum {
ACCOUNTHIERARCHYNOTACTIVE(String.valueOf("accountHierarchyNotActive")),
AMOUNTLIMITEXCEEDED(String.valueOf("amountLimitExceeded")),
APPROVED(String.valueOf("approved")),
COUNTERPARTYACCOUNTBLOCKED(String.valueOf("counterpartyAccountBlocked")),
COUNTERPARTYACCOUNTCLOSED(String.valueOf("counterpartyAccountClosed")),
COUNTERPARTYACCOUNTNOTFOUND(String.valueOf("counterpartyAccountNotFound")),
COUNTERPARTYADDRESSREQUIRED(String.valueOf("counterpartyAddressRequired")),
COUNTERPARTYBANKTIMEDOUT(String.valueOf("counterpartyBankTimedOut")),
COUNTERPARTYBANKUNAVAILABLE(String.valueOf("counterpartyBankUnavailable")),
DIRECTDEBITNOTSUPPORTED(String.valueOf("directDebitNotSupported")),
ERROR(String.valueOf("error")),
NOTENOUGHBALANCE(String.valueOf("notEnoughBalance")),
REFUSEDBYCOUNTERPARTYBANK(String.valueOf("refusedByCounterpartyBank")),
ROUTENOTFOUND(String.valueOf("routeNotFound")),
TRANSFERINSTRUMENTDOESNOTEXIST(String.valueOf("transferInstrumentDoesNotExist")),
UNKNOWN(String.valueOf("unknown"));
private static final Logger LOG = Logger.getLogger(ReasonEnum.class.getName());
private String value;
ReasonEnum(String value) {
this.value = value;
}
@JsonValue
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
@JsonCreator
public static ReasonEnum fromValue(String value) {
for (ReasonEnum b : ReasonEnum.values()) {
if (b.value.equals(value)) {
return b;
}
}
// handling unexpected value
LOG.warning(
"ReasonEnum: unexpected enum value '"
+ value
+ "' - Supported values are "
+ Arrays.toString(ReasonEnum.values()));
return null;
}
}
public static final String JSON_PROPERTY_REASON = "reason";
private ReasonEnum reason;
/** Mark when the attribute has been explicitly set. */
private boolean isSetReason = false;
public static final String JSON_PROPERTY_REASON_DETAIL = "reasonDetail";
private String reasonDetail;
/** Mark when the attribute has been explicitly set. */
private boolean isSetReasonDetail = false;
public static final String JSON_PROPERTY_REFERENCE = "reference";
private String reference;
/** Mark when the attribute has been explicitly set. */
private boolean isSetReference = false;
public static final String JSON_PROPERTY_REFERENCE_FOR_BENEFICIARY = "referenceForBeneficiary";
private String referenceForBeneficiary;
/** Mark when the attribute has been explicitly set. */
private boolean isSetReferenceForBeneficiary = false;
public static final String JSON_PROPERTY_SCHEDULE = "schedule";
private SweepSchedule schedule;
/** Mark when the attribute has been explicitly set. */
private boolean isSetSchedule = false;
/**
* The status of the sweep. If not provided, by default, this is set to **active**. Possible
* values: * **active**: the sweep is enabled and funds will be pulled in or pushed out based on
* the defined configuration. * **inactive**: the sweep is disabled and cannot be triggered.
*/
public enum StatusEnum {
ACTIVE(String.valueOf("active")),
INACTIVE(String.valueOf("inactive"));
private static final Logger LOG = Logger.getLogger(StatusEnum.class.getName());
private String value;
StatusEnum(String value) {
this.value = value;
}
@JsonValue
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
@JsonCreator
public static StatusEnum fromValue(String value) {
for (StatusEnum b : StatusEnum.values()) {
if (b.value.equals(value)) {
return b;
}
}
// handling unexpected value
LOG.warning(
"StatusEnum: unexpected enum value '"
+ value
+ "' - Supported values are "
+ Arrays.toString(StatusEnum.values()));
return null;
}
}
public static final String JSON_PROPERTY_STATUS = "status";
private StatusEnum status;
/** Mark when the attribute has been explicitly set. */
private boolean isSetStatus = false;
public static final String JSON_PROPERTY_SWEEP_AMOUNT = "sweepAmount";
private Amount sweepAmount;
/** Mark when the attribute has been explicitly set. */
private boolean isSetSweepAmount = false;
public static final String JSON_PROPERTY_TARGET_AMOUNT = "targetAmount";
private Amount targetAmount;
/** Mark when the attribute has been explicitly set. */
private boolean isSetTargetAmount = false;
public static final String JSON_PROPERTY_TRIGGER_AMOUNT = "triggerAmount";
private Amount triggerAmount;
/** Mark when the attribute has been explicitly set. */
private boolean isSetTriggerAmount = false;
/**
* The direction of sweep, whether pushing out or pulling in funds to the balance account. If not
* provided, by default, this is set to **push**. Possible values: * **push**: _push out funds_ to
* a destination balance account or transfer instrument. * **pull**: _pull in funds_ from a source
* merchant account, transfer instrument, or balance account.
*/
public enum TypeEnum {
PULL(String.valueOf("pull")),
PUSH(String.valueOf("push"));
private static final Logger LOG = Logger.getLogger(TypeEnum.class.getName());
private String value;
TypeEnum(String value) {
this.value = value;
}
@JsonValue
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
@JsonCreator
public static TypeEnum fromValue(String value) {
for (TypeEnum b : TypeEnum.values()) {
if (b.value.equals(value)) {
return b;
}
}
// handling unexpected value
LOG.warning(
"TypeEnum: unexpected enum value '"
+ value
+ "' - Supported values are "
+ Arrays.toString(TypeEnum.values()));
return null;
}
}
public static final String JSON_PROPERTY_TYPE = "type";
private TypeEnum type;
/** Mark when the attribute has been explicitly set. */
private boolean isSetType = false;
/**
* Sets whether attributes with null values should be explicitly included in the JSON payload.
* Default is false.
*/
@JsonIgnore private boolean includeNullValues = false;
public CreateSweepConfigurationV2() {}
@JsonCreator
public CreateSweepConfigurationV2(
@JsonProperty(JSON_PROPERTY_REASON) ReasonEnum reason,
@JsonProperty(JSON_PROPERTY_REASON_DETAIL) String reasonDetail) {
this();
this.reason = reason;
this.reasonDetail = reasonDetail;
}
/**
* The type of transfer that results from the sweep. Possible values: - **bank**: Sweep to a
* [transfer
* instrument](https://docs.adyen.com/api-explorer/#/legalentity/latest/post/transferInstruments__resParam_id).
* - **internal**: Transfer to another [balance
* account](https://docs.adyen.com/api-explorer/#/balanceplatform/latest/post/balanceAccounts__resParam_id)
* within your platform. Required when setting `priorities`.
*
* @param category The type of transfer that results from the sweep. Possible values: - **bank**:
* Sweep to a [transfer
* instrument](https://docs.adyen.com/api-explorer/#/legalentity/latest/post/transferInstruments__resParam_id).
* - **internal**: Transfer to another [balance
* account](https://docs.adyen.com/api-explorer/#/balanceplatform/latest/post/balanceAccounts__resParam_id)
* within your platform. Required when setting `priorities`.
* @return the current {@code CreateSweepConfigurationV2} instance, allowing for method chaining
*/
public CreateSweepConfigurationV2 category(CategoryEnum category) {
this.category = category;
isSetCategory = true; // mark as set
return this;
}
/**
* The type of transfer that results from the sweep. Possible values: - **bank**: Sweep to a
* [transfer
* instrument](https://docs.adyen.com/api-explorer/#/legalentity/latest/post/transferInstruments__resParam_id).
* - **internal**: Transfer to another [balance
* account](https://docs.adyen.com/api-explorer/#/balanceplatform/latest/post/balanceAccounts__resParam_id)
* within your platform. Required when setting `priorities`.
*
* @return category The type of transfer that results from the sweep. Possible values: - **bank**:
* Sweep to a [transfer
* instrument](https://docs.adyen.com/api-explorer/#/legalentity/latest/post/transferInstruments__resParam_id).
* - **internal**: Transfer to another [balance
* account](https://docs.adyen.com/api-explorer/#/balanceplatform/latest/post/balanceAccounts__resParam_id)
* within your platform. Required when setting `priorities`.
*/
@JsonProperty(JSON_PROPERTY_CATEGORY)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public CategoryEnum getCategory() {
return category;
}
/**
* The type of transfer that results from the sweep. Possible values: - **bank**: Sweep to a
* [transfer
* instrument](https://docs.adyen.com/api-explorer/#/legalentity/latest/post/transferInstruments__resParam_id).
* - **internal**: Transfer to another [balance
* account](https://docs.adyen.com/api-explorer/#/balanceplatform/latest/post/balanceAccounts__resParam_id)
* within your platform. Required when setting `priorities`.
*
* @param category The type of transfer that results from the sweep. Possible values: - **bank**:
* Sweep to a [transfer
* instrument](https://docs.adyen.com/api-explorer/#/legalentity/latest/post/transferInstruments__resParam_id).
* - **internal**: Transfer to another [balance
* account](https://docs.adyen.com/api-explorer/#/balanceplatform/latest/post/balanceAccounts__resParam_id)
* within your platform. Required when setting `priorities`.
*/
@JsonProperty(JSON_PROPERTY_CATEGORY)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setCategory(CategoryEnum category) {
this.category = category;
isSetCategory = true; // mark as set
}
/**
* counterparty
*
* @param counterparty
* @return the current {@code CreateSweepConfigurationV2} instance, allowing for method chaining
*/
public CreateSweepConfigurationV2 counterparty(SweepCounterparty counterparty) {
this.counterparty = counterparty;
isSetCounterparty = true; // mark as set
return this;
}
/**
* Get counterparty
*
* @return counterparty
*/
@JsonProperty(JSON_PROPERTY_COUNTERPARTY)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public SweepCounterparty getCounterparty() {
return counterparty;
}
/**
* counterparty
*
* @param counterparty
*/
@JsonProperty(JSON_PROPERTY_COUNTERPARTY)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setCounterparty(SweepCounterparty counterparty) {
this.counterparty = counterparty;
isSetCounterparty = true; // mark as set
}
/**
* The three-character [ISO currency
* code](https://docs.adyen.com/development-resources/currency-codes) in uppercase. For example,
* **EUR**. The sweep currency must match any of the [balances
* currencies](https://docs.adyen.com/api-explorer/#/balanceplatform/latest/get/balanceAccounts/{id}__resParam_balances).
*
* @param currency The three-character [ISO currency
* code](https://docs.adyen.com/development-resources/currency-codes) in uppercase. For
* example, **EUR**. The sweep currency must match any of the [balances
* currencies](https://docs.adyen.com/api-explorer/#/balanceplatform/latest/get/balanceAccounts/{id}__resParam_balances).
* @return the current {@code CreateSweepConfigurationV2} instance, allowing for method chaining
*/
public CreateSweepConfigurationV2 currency(String currency) {
this.currency = currency;
isSetCurrency = true; // mark as set
return this;
}
/**
* The three-character [ISO currency
* code](https://docs.adyen.com/development-resources/currency-codes) in uppercase. For example,
* **EUR**. The sweep currency must match any of the [balances
* currencies](https://docs.adyen.com/api-explorer/#/balanceplatform/latest/get/balanceAccounts/{id}__resParam_balances).
*
* @return currency The three-character [ISO currency
* code](https://docs.adyen.com/development-resources/currency-codes) in uppercase. For
* example, **EUR**. The sweep currency must match any of the [balances
* currencies](https://docs.adyen.com/api-explorer/#/balanceplatform/latest/get/balanceAccounts/{id}__resParam_balances).
*/
@JsonProperty(JSON_PROPERTY_CURRENCY)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getCurrency() {
return currency;
}
/**
* The three-character [ISO currency
* code](https://docs.adyen.com/development-resources/currency-codes) in uppercase. For example,
* **EUR**. The sweep currency must match any of the [balances
* currencies](https://docs.adyen.com/api-explorer/#/balanceplatform/latest/get/balanceAccounts/{id}__resParam_balances).
*
* @param currency The three-character [ISO currency
* code](https://docs.adyen.com/development-resources/currency-codes) in uppercase. For
* example, **EUR**. The sweep currency must match any of the [balances
* currencies](https://docs.adyen.com/api-explorer/#/balanceplatform/latest/get/balanceAccounts/{id}__resParam_balances).
*/
@JsonProperty(JSON_PROPERTY_CURRENCY)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setCurrency(String currency) {
this.currency = currency;
isSetCurrency = true; // mark as set
}
/**
* The message that will be used in the sweep transfer's description body with a maximum
* length of 140 characters. If the message is longer after replacing placeholders, the message
* will be cut off at 140 characters.
*
* @param description The message that will be used in the sweep transfer's description body
* with a maximum length of 140 characters. If the message is longer after replacing
* placeholders, the message will be cut off at 140 characters.
* @return the current {@code CreateSweepConfigurationV2} instance, allowing for method chaining
*/
public CreateSweepConfigurationV2 description(String description) {
this.description = description;
isSetDescription = true; // mark as set
return this;
}
/**
* The message that will be used in the sweep transfer's description body with a maximum
* length of 140 characters. If the message is longer after replacing placeholders, the message
* will be cut off at 140 characters.
*
* @return description The message that will be used in the sweep transfer's description body
* with a maximum length of 140 characters. If the message is longer after replacing
* placeholders, the message will be cut off at 140 characters.
*/
@JsonProperty(JSON_PROPERTY_DESCRIPTION)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getDescription() {
return description;
}
/**
* The message that will be used in the sweep transfer's description body with a maximum
* length of 140 characters. If the message is longer after replacing placeholders, the message
* will be cut off at 140 characters.
*
* @param description The message that will be used in the sweep transfer's description body
* with a maximum length of 140 characters. If the message is longer after replacing
* placeholders, the message will be cut off at 140 characters.
*/
@JsonProperty(JSON_PROPERTY_DESCRIPTION)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setDescription(String description) {
this.description = description;
isSetDescription = true; // mark as set
}
/**
* The list of priorities for the bank transfer. This sets the speed at which the transfer is sent
* and the fees that you have to pay. You can provide multiple priorities, ordered by your
* preference. Adyen will try to pay out using the priorities in the given order. If the first
* priority is not currently supported or enabled for your platform, the system will try the next
* one, and so on. The request will be accepted as long as **at least one** of the provided
* priorities is valid (i.e., supported by Adyen and activated for your platform). For example, if
* you provide `[\"wire\",\"regular\"]`, and `wire` is not
* supported but `regular` is, the request will still be accepted and processed.
* Possible values: * **regular**: For normal, low-value transactions. * **fast**: A faster way to
* transfer funds, but the fees are higher. Recommended for high-priority, low-value transactions.
* * **wire**: The fastest way to transfer funds, but this has the highest fees. Recommended for
* high-priority, high-value transactions. * **instant**: For instant funds transfers within the
* United States and in [SEPA
* locations](https://www.ecb.europa.eu/paym/integration/retail/sepa/html/index.en.html). *
* **crossBorder**: For high-value transfers to a recipient in a different country. *
* **internal**: For transfers to an Adyen-issued business bank account (by bank account
* number/IBAN). Set `category` to **bank**. For more details, see optional priorities
* setup for
* [marketplaces](https://docs.adyen.com/marketplaces/payout-to-users/scheduled-payouts#optional-priorities-setup)
* or
* [platforms](https://docs.adyen.com/platforms/payout-to-users/scheduled-payouts#optional-priorities-setup).
*
* @param priorities The list of priorities for the bank transfer. This sets the speed at which
* the transfer is sent and the fees that you have to pay. You can provide multiple
* priorities, ordered by your preference. Adyen will try to pay out using the priorities in
* the given order. If the first priority is not currently supported or enabled for your
* platform, the system will try the next one, and so on. The request will be accepted as long
* as **at least one** of the provided priorities is valid (i.e., supported by Adyen and
* activated for your platform). For example, if you provide
* `[\"wire\",\"regular\"]`, and `wire` is not
* supported but `regular` is, the request will still be accepted and processed.
* Possible values: * **regular**: For normal, low-value transactions. * **fast**: A faster
* way to transfer funds, but the fees are higher. Recommended for high-priority, low-value
* transactions. * **wire**: The fastest way to transfer funds, but this has the highest fees.
* Recommended for high-priority, high-value transactions. * **instant**: For instant funds
* transfers within the United States and in [SEPA
* locations](https://www.ecb.europa.eu/paym/integration/retail/sepa/html/index.en.html). *
* **crossBorder**: For high-value transfers to a recipient in a different country. *
* **internal**: For transfers to an Adyen-issued business bank account (by bank account
* number/IBAN). Set `category` to **bank**. For more details, see optional
* priorities setup for
* [marketplaces](https://docs.adyen.com/marketplaces/payout-to-users/scheduled-payouts#optional-priorities-setup)
* or
* [platforms](https://docs.adyen.com/platforms/payout-to-users/scheduled-payouts#optional-priorities-setup).
* @return the current {@code CreateSweepConfigurationV2} instance, allowing for method chaining
*/
public CreateSweepConfigurationV2 priorities(List<PrioritiesEnum> priorities) {
this.priorities = priorities;
isSetPriorities = true; // mark as set
return this;
}
public CreateSweepConfigurationV2 addPrioritiesItem(PrioritiesEnum prioritiesItem) {
if (this.priorities == null) {
this.priorities = new ArrayList<>();
}
this.priorities.add(prioritiesItem);
return this;
}
/**
* The list of priorities for the bank transfer. This sets the speed at which the transfer is sent
* and the fees that you have to pay. You can provide multiple priorities, ordered by your
* preference. Adyen will try to pay out using the priorities in the given order. If the first
* priority is not currently supported or enabled for your platform, the system will try the next
* one, and so on. The request will be accepted as long as **at least one** of the provided
* priorities is valid (i.e., supported by Adyen and activated for your platform). For example, if
* you provide `[\"wire\",\"regular\"]`, and `wire` is not
* supported but `regular` is, the request will still be accepted and processed.
* Possible values: * **regular**: For normal, low-value transactions. * **fast**: A faster way to
* transfer funds, but the fees are higher. Recommended for high-priority, low-value transactions.
* * **wire**: The fastest way to transfer funds, but this has the highest fees. Recommended for
* high-priority, high-value transactions. * **instant**: For instant funds transfers within the
* United States and in [SEPA
* locations](https://www.ecb.europa.eu/paym/integration/retail/sepa/html/index.en.html). *
* **crossBorder**: For high-value transfers to a recipient in a different country. *
* **internal**: For transfers to an Adyen-issued business bank account (by bank account
* number/IBAN). Set `category` to **bank**. For more details, see optional priorities
* setup for
* [marketplaces](https://docs.adyen.com/marketplaces/payout-to-users/scheduled-payouts#optional-priorities-setup)
* or
* [platforms](https://docs.adyen.com/platforms/payout-to-users/scheduled-payouts#optional-priorities-setup).
*
* @return priorities The list of priorities for the bank transfer. This sets the speed at which
* the transfer is sent and the fees that you have to pay. You can provide multiple
* priorities, ordered by your preference. Adyen will try to pay out using the priorities in
* the given order. If the first priority is not currently supported or enabled for your
* platform, the system will try the next one, and so on. The request will be accepted as long
* as **at least one** of the provided priorities is valid (i.e., supported by Adyen and
* activated for your platform). For example, if you provide
* `[\"wire\",\"regular\"]`, and `wire` is not
* supported but `regular` is, the request will still be accepted and processed.
* Possible values: * **regular**: For normal, low-value transactions. * **fast**: A faster
* way to transfer funds, but the fees are higher. Recommended for high-priority, low-value
* transactions. * **wire**: The fastest way to transfer funds, but this has the highest fees.
* Recommended for high-priority, high-value transactions. * **instant**: For instant funds
* transfers within the United States and in [SEPA
* locations](https://www.ecb.europa.eu/paym/integration/retail/sepa/html/index.en.html). *
* **crossBorder**: For high-value transfers to a recipient in a different country. *
* **internal**: For transfers to an Adyen-issued business bank account (by bank account
* number/IBAN). Set `category` to **bank**. For more details, see optional
* priorities setup for
* [marketplaces](https://docs.adyen.com/marketplaces/payout-to-users/scheduled-payouts#optional-priorities-setup)
* or
* [platforms](https://docs.adyen.com/platforms/payout-to-users/scheduled-payouts#optional-priorities-setup).
*/
@JsonProperty(JSON_PROPERTY_PRIORITIES)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public List<PrioritiesEnum> getPriorities() {
return priorities;
}
/**
* The list of priorities for the bank transfer. This sets the speed at which the transfer is sent
* and the fees that you have to pay. You can provide multiple priorities, ordered by your
* preference. Adyen will try to pay out using the priorities in the given order. If the first
* priority is not currently supported or enabled for your platform, the system will try the next
* one, and so on. The request will be accepted as long as **at least one** of the provided
* priorities is valid (i.e., supported by Adyen and activated for your platform). For example, if
* you provide `[\"wire\",\"regular\"]`, and `wire` is not
* supported but `regular` is, the request will still be accepted and processed.
* Possible values: * **regular**: For normal, low-value transactions. * **fast**: A faster way to
* transfer funds, but the fees are higher. Recommended for high-priority, low-value transactions.
* * **wire**: The fastest way to transfer funds, but this has the highest fees. Recommended for
* high-priority, high-value transactions. * **instant**: For instant funds transfers within the
* United States and in [SEPA
* locations](https://www.ecb.europa.eu/paym/integration/retail/sepa/html/index.en.html). *
* **crossBorder**: For high-value transfers to a recipient in a different country. *
* **internal**: For transfers to an Adyen-issued business bank account (by bank account
* number/IBAN). Set `category` to **bank**. For more details, see optional priorities
* setup for
* [marketplaces](https://docs.adyen.com/marketplaces/payout-to-users/scheduled-payouts#optional-priorities-setup)
* or
* [platforms](https://docs.adyen.com/platforms/payout-to-users/scheduled-payouts#optional-priorities-setup).
*
* @param priorities The list of priorities for the bank transfer. This sets the speed at which
* the transfer is sent and the fees that you have to pay. You can provide multiple
* priorities, ordered by your preference. Adyen will try to pay out using the priorities in
* the given order. If the first priority is not currently supported or enabled for your
* platform, the system will try the next one, and so on. The request will be accepted as long
* as **at least one** of the provided priorities is valid (i.e., supported by Adyen and
* activated for your platform). For example, if you provide
* `[\"wire\",\"regular\"]`, and `wire` is not
* supported but `regular` is, the request will still be accepted and processed.
* Possible values: * **regular**: For normal, low-value transactions. * **fast**: A faster
* way to transfer funds, but the fees are higher. Recommended for high-priority, low-value
* transactions. * **wire**: The fastest way to transfer funds, but this has the highest fees.
* Recommended for high-priority, high-value transactions. * **instant**: For instant funds
* transfers within the United States and in [SEPA
* locations](https://www.ecb.europa.eu/paym/integration/retail/sepa/html/index.en.html). *
* **crossBorder**: For high-value transfers to a recipient in a different country. *
* **internal**: For transfers to an Adyen-issued business bank account (by bank account
* number/IBAN). Set `category` to **bank**. For more details, see optional
* priorities setup for
* [marketplaces](https://docs.adyen.com/marketplaces/payout-to-users/scheduled-payouts#optional-priorities-setup)
* or
* [platforms](https://docs.adyen.com/platforms/payout-to-users/scheduled-payouts#optional-priorities-setup).
*/
@JsonProperty(JSON_PROPERTY_PRIORITIES)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setPriorities(List<PrioritiesEnum> priorities) {
this.priorities = priorities;
isSetPriorities = true; // mark as set
}
/**
* The reason for disabling the sweep.
*
* @return reason The reason for disabling the sweep.
*/
@JsonProperty(JSON_PROPERTY_REASON)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public ReasonEnum getReason() {
return reason;
}
/**
* The human readable reason for disabling the sweep.
*
* @return reasonDetail The human readable reason for disabling the sweep.
*/
@JsonProperty(JSON_PROPERTY_REASON_DETAIL)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getReasonDetail() {
return reasonDetail;
}
/**
* Your reference for the sweep configuration.
*
* @param reference Your reference for the sweep configuration.
* @return the current {@code CreateSweepConfigurationV2} instance, allowing for method chaining
*/
public CreateSweepConfigurationV2 reference(String reference) {
this.reference = reference;
isSetReference = true; // mark as set
return this;
}
/**
* Your reference for the sweep configuration.
*
* @return reference Your reference for the sweep configuration.
*/
@JsonProperty(JSON_PROPERTY_REFERENCE)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getReference() {
return reference;
}
/**
* Your reference for the sweep configuration.
*
* @param reference Your reference for the sweep configuration.
*/
@JsonProperty(JSON_PROPERTY_REFERENCE)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setReference(String reference) {
this.reference = reference;
isSetReference = true; // mark as set
}
/**
* The reference sent to or received from the counterparty. Only alphanumeric characters are
* allowed.
*
* @param referenceForBeneficiary The reference sent to or received from the counterparty. Only
* alphanumeric characters are allowed.
* @return the current {@code CreateSweepConfigurationV2} instance, allowing for method chaining
*/
public CreateSweepConfigurationV2 referenceForBeneficiary(String referenceForBeneficiary) {
this.referenceForBeneficiary = referenceForBeneficiary;
isSetReferenceForBeneficiary = true; // mark as set
return this;
}
/**
* The reference sent to or received from the counterparty. Only alphanumeric characters are
* allowed.
*
* @return referenceForBeneficiary The reference sent to or received from the counterparty. Only
* alphanumeric characters are allowed.
*/
@JsonProperty(JSON_PROPERTY_REFERENCE_FOR_BENEFICIARY)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getReferenceForBeneficiary() {
return referenceForBeneficiary;
}
/**
* The reference sent to or received from the counterparty. Only alphanumeric characters are
* allowed.
*
* @param referenceForBeneficiary The reference sent to or received from the counterparty. Only
* alphanumeric characters are allowed.
*/
@JsonProperty(JSON_PROPERTY_REFERENCE_FOR_BENEFICIARY)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setReferenceForBeneficiary(String referenceForBeneficiary) {
this.referenceForBeneficiary = referenceForBeneficiary;
isSetReferenceForBeneficiary = true; // mark as set
}
/**
* schedule
*
* @param schedule
* @return the current {@code CreateSweepConfigurationV2} instance, allowing for method chaining
*/
public CreateSweepConfigurationV2 schedule(SweepSchedule schedule) {
this.schedule = schedule;
isSetSchedule = true; // mark as set
return this;
}
/**
* Get schedule
*
* @return schedule
*/
@JsonProperty(JSON_PROPERTY_SCHEDULE)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public SweepSchedule getSchedule() {
return schedule;
}
/**
* schedule
*
* @param schedule
*/
@JsonProperty(JSON_PROPERTY_SCHEDULE)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setSchedule(SweepSchedule schedule) {
this.schedule = schedule;
isSetSchedule = true; // mark as set
}
/**
* The status of the sweep. If not provided, by default, this is set to **active**. Possible
* values: * **active**: the sweep is enabled and funds will be pulled in or pushed out based on
* the defined configuration. * **inactive**: the sweep is disabled and cannot be triggered.
*
* @param status The status of the sweep. If not provided, by default, this is set to **active**.
* Possible values: * **active**: the sweep is enabled and funds will be pulled in or pushed
* out based on the defined configuration. * **inactive**: the sweep is disabled and cannot be
* triggered.
* @return the current {@code CreateSweepConfigurationV2} instance, allowing for method chaining
*/
public CreateSweepConfigurationV2 status(StatusEnum status) {
this.status = status;
isSetStatus = true; // mark as set
return this;
}
/**
* The status of the sweep. If not provided, by default, this is set to **active**. Possible
* values: * **active**: the sweep is enabled and funds will be pulled in or pushed out based on
* the defined configuration. * **inactive**: the sweep is disabled and cannot be triggered.
*
* @return status The status of the sweep. If not provided, by default, this is set to **active**.
* Possible values: * **active**: the sweep is enabled and funds will be pulled in or pushed
* out based on the defined configuration. * **inactive**: the sweep is disabled and cannot be
* triggered.
*/
@JsonProperty(JSON_PROPERTY_STATUS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public StatusEnum getStatus() {
return status;
}
/**
* The status of the sweep. If not provided, by default, this is set to **active**. Possible
* values: * **active**: the sweep is enabled and funds will be pulled in or pushed out based on
* the defined configuration. * **inactive**: the sweep is disabled and cannot be triggered.
*
* @param status The status of the sweep. If not provided, by default, this is set to **active**.
* Possible values: * **active**: the sweep is enabled and funds will be pulled in or pushed
* out based on the defined configuration. * **inactive**: the sweep is disabled and cannot be
* triggered.
*/
@JsonProperty(JSON_PROPERTY_STATUS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setStatus(StatusEnum status) {
this.status = status;
isSetStatus = true; // mark as set
}
/**
* sweepAmount
*
* @param sweepAmount
* @return the current {@code CreateSweepConfigurationV2} instance, allowing for method chaining
*/
public CreateSweepConfigurationV2 sweepAmount(Amount sweepAmount) {
this.sweepAmount = sweepAmount;
isSetSweepAmount = true; // mark as set
return this;
}
/**
* Get sweepAmount
*
* @return sweepAmount
*/
@JsonProperty(JSON_PROPERTY_SWEEP_AMOUNT)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public Amount getSweepAmount() {
return sweepAmount;
}
/**
* sweepAmount
*
* @param sweepAmount
*/
@JsonProperty(JSON_PROPERTY_SWEEP_AMOUNT)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setSweepAmount(Amount sweepAmount) {
this.sweepAmount = sweepAmount;
isSetSweepAmount = true; // mark as set
}
/**
* targetAmount
*
* @param targetAmount