Skip to content

Commit d58a279

Browse files
authored
Merge pull request #1062 from stripe/remi/codegen-0b9fd61
Add support for `political_exposure` on `Person`
2 parents 0aa0064 + 40212d7 commit d58a279

6 files changed

+203
-0
lines changed

src/main/java/com/stripe/model/Person.java

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,16 @@ public class Person extends ApiResource implements HasId, MetadataStore<Person>
112112
@SerializedName("phone")
113113
String phone;
114114

115+
/**
116+
* Indicates if the person or any of their representatives, family members, or other closely
117+
* related persons, declares that they hold or have held an important public job or function, in
118+
* any jurisdiction.
119+
*
120+
* <p>One of {@code existing}, or {@code none}.
121+
*/
122+
@SerializedName("political_exposure")
123+
String politicalExposure;
124+
115125
@SerializedName("relationship")
116126
Relationship relationship;
117127

src/main/java/com/stripe/param/AccountCreateParams.java

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1969,6 +1969,14 @@ public static class Individual {
19691969
@SerializedName("phone")
19701970
String phone;
19711971

1972+
/**
1973+
* Indicates if the person or any of their representatives, family members, or other closely
1974+
* related persons, declares that they hold or have held an important public job or function, in
1975+
* any jurisdiction.
1976+
*/
1977+
@SerializedName("political_exposure")
1978+
PoliticalExposure politicalExposure;
1979+
19721980
/** The last four digits of the individual's Social Security Number (U.S. only). */
19731981
@SerializedName("ssn_last_4")
19741982
String ssnLast4;
@@ -1995,6 +2003,7 @@ private Individual(
19952003
String maidenName,
19962004
Object metadata,
19972005
String phone,
2006+
PoliticalExposure politicalExposure,
19982007
String ssnLast4,
19992008
Verification verification) {
20002009
this.address = address;
@@ -2014,6 +2023,7 @@ private Individual(
20142023
this.maidenName = maidenName;
20152024
this.metadata = metadata;
20162025
this.phone = phone;
2026+
this.politicalExposure = politicalExposure;
20172027
this.ssnLast4 = ssnLast4;
20182028
this.verification = verification;
20192029
}
@@ -2057,6 +2067,8 @@ public static class Builder {
20572067

20582068
private String phone;
20592069

2070+
private PoliticalExposure politicalExposure;
2071+
20602072
private String ssnLast4;
20612073

20622074
private Verification verification;
@@ -2081,6 +2093,7 @@ public Individual build() {
20812093
this.maidenName,
20822094
this.metadata,
20832095
this.phone,
2096+
this.politicalExposure,
20842097
this.ssnLast4,
20852098
this.verification);
20862099
}
@@ -2266,6 +2279,16 @@ public Builder setPhone(String phone) {
22662279
return this;
22672280
}
22682281

2282+
/**
2283+
* Indicates if the person or any of their representatives, family members, or other closely
2284+
* related persons, declares that they hold or have held an important public job or function,
2285+
* in any jurisdiction.
2286+
*/
2287+
public Builder setPoliticalExposure(PoliticalExposure politicalExposure) {
2288+
this.politicalExposure = politicalExposure;
2289+
return this;
2290+
}
2291+
22692292
/** The last four digits of the individual's Social Security Number (U.S. only). */
22702293
public Builder setSsnLast4(String ssnLast4) {
22712294
this.ssnLast4 = ssnLast4;
@@ -3171,6 +3194,21 @@ public Builder setFront(String front) {
31713194
}
31723195
}
31733196
}
3197+
3198+
public enum PoliticalExposure implements ApiRequestParams.EnumParam {
3199+
@SerializedName("existing")
3200+
EXISTING("existing"),
3201+
3202+
@SerializedName("none")
3203+
NONE("none");
3204+
3205+
@Getter(onMethod_ = {@Override})
3206+
private final String value;
3207+
3208+
PoliticalExposure(String value) {
3209+
this.value = value;
3210+
}
3211+
}
31743212
}
31753213

31763214
@Getter

src/main/java/com/stripe/param/AccountUpdateParams.java

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2262,6 +2262,14 @@ public static class Individual {
22622262
@SerializedName("phone")
22632263
Object phone;
22642264

2265+
/**
2266+
* Indicates if the person or any of their representatives, family members, or other closely
2267+
* related persons, declares that they hold or have held an important public job or function, in
2268+
* any jurisdiction.
2269+
*/
2270+
@SerializedName("political_exposure")
2271+
PoliticalExposure politicalExposure;
2272+
22652273
/** The last four digits of the individual's Social Security Number (U.S. only). */
22662274
@SerializedName("ssn_last_4")
22672275
Object ssnLast4;
@@ -2288,6 +2296,7 @@ private Individual(
22882296
Object maidenName,
22892297
Object metadata,
22902298
Object phone,
2299+
PoliticalExposure politicalExposure,
22912300
Object ssnLast4,
22922301
Verification verification) {
22932302
this.address = address;
@@ -2307,6 +2316,7 @@ private Individual(
23072316
this.maidenName = maidenName;
23082317
this.metadata = metadata;
23092318
this.phone = phone;
2319+
this.politicalExposure = politicalExposure;
23102320
this.ssnLast4 = ssnLast4;
23112321
this.verification = verification;
23122322
}
@@ -2350,6 +2360,8 @@ public static class Builder {
23502360

23512361
private Object phone;
23522362

2363+
private PoliticalExposure politicalExposure;
2364+
23532365
private Object ssnLast4;
23542366

23552367
private Verification verification;
@@ -2374,6 +2386,7 @@ public Individual build() {
23742386
this.maidenName,
23752387
this.metadata,
23762388
this.phone,
2389+
this.politicalExposure,
23772390
this.ssnLast4,
23782391
this.verification);
23792392
}
@@ -2634,6 +2647,16 @@ public Builder setPhone(EmptyParam phone) {
26342647
return this;
26352648
}
26362649

2650+
/**
2651+
* Indicates if the person or any of their representatives, family members, or other closely
2652+
* related persons, declares that they hold or have held an important public job or function,
2653+
* in any jurisdiction.
2654+
*/
2655+
public Builder setPoliticalExposure(PoliticalExposure politicalExposure) {
2656+
this.politicalExposure = politicalExposure;
2657+
return this;
2658+
}
2659+
26372660
/** The last four digits of the individual's Social Security Number (U.S. only). */
26382661
public Builder setSsnLast4(String ssnLast4) {
26392662
this.ssnLast4 = ssnLast4;
@@ -3718,6 +3741,21 @@ public Builder setFront(EmptyParam front) {
37183741
}
37193742
}
37203743
}
3744+
3745+
public enum PoliticalExposure implements ApiRequestParams.EnumParam {
3746+
@SerializedName("existing")
3747+
EXISTING("existing"),
3748+
3749+
@SerializedName("none")
3750+
NONE("none");
3751+
3752+
@Getter(onMethod_ = {@Override})
3753+
private final String value;
3754+
3755+
PoliticalExposure(String value) {
3756+
this.value = value;
3757+
}
3758+
}
37213759
}
37223760

37233761
@Getter

src/main/java/com/stripe/param/PersonCollectionCreateParams.java

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,14 @@ public class PersonCollectionCreateParams extends ApiRequestParams {
109109
@SerializedName("phone")
110110
String phone;
111111

112+
/**
113+
* Indicates if the person or any of their representatives, family members, or other closely
114+
* related persons, declares that they hold or have held an important public job or function, in
115+
* any jurisdiction.
116+
*/
117+
@SerializedName("political_exposure")
118+
String politicalExposure;
119+
112120
/** The relationship that this person has with the account's legal entity. */
113121
@SerializedName("relationship")
114122
Relationship relationship;
@@ -141,6 +149,7 @@ private PersonCollectionCreateParams(
141149
Object metadata,
142150
String personToken,
143151
String phone,
152+
String politicalExposure,
144153
Relationship relationship,
145154
String ssnLast4,
146155
Verification verification) {
@@ -163,6 +172,7 @@ private PersonCollectionCreateParams(
163172
this.metadata = metadata;
164173
this.personToken = personToken;
165174
this.phone = phone;
175+
this.politicalExposure = politicalExposure;
166176
this.relationship = relationship;
167177
this.ssnLast4 = ssnLast4;
168178
this.verification = verification;
@@ -211,6 +221,8 @@ public static class Builder {
211221

212222
private String phone;
213223

224+
private String politicalExposure;
225+
214226
private Relationship relationship;
215227

216228
private String ssnLast4;
@@ -239,6 +251,7 @@ public PersonCollectionCreateParams build() {
239251
this.metadata,
240252
this.personToken,
241253
this.phone,
254+
this.politicalExposure,
242255
this.relationship,
243256
this.ssnLast4,
244257
this.verification);
@@ -459,6 +472,16 @@ public Builder setPhone(String phone) {
459472
return this;
460473
}
461474

475+
/**
476+
* Indicates if the person or any of their representatives, family members, or other closely
477+
* related persons, declares that they hold or have held an important public job or function, in
478+
* any jurisdiction.
479+
*/
480+
public Builder setPoliticalExposure(String politicalExposure) {
481+
this.politicalExposure = politicalExposure;
482+
return this;
483+
}
484+
462485
/** The relationship that this person has with the account's legal entity. */
463486
public Builder setRelationship(Relationship relationship) {
464487
this.relationship = relationship;

src/main/java/com/stripe/param/PersonUpdateParams.java

Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,14 @@ public class PersonUpdateParams extends ApiRequestParams {
109109
@SerializedName("phone")
110110
Object phone;
111111

112+
/**
113+
* Indicates if the person or any of their representatives, family members, or other closely
114+
* related persons, declares that they hold or have held an important public job or function, in
115+
* any jurisdiction.
116+
*/
117+
@SerializedName("political_exposure")
118+
Object politicalExposure;
119+
112120
/** The relationship that this person has with the account's legal entity. */
113121
@SerializedName("relationship")
114122
Relationship relationship;
@@ -141,6 +149,7 @@ private PersonUpdateParams(
141149
Object metadata,
142150
Object personToken,
143151
Object phone,
152+
Object politicalExposure,
144153
Relationship relationship,
145154
Object ssnLast4,
146155
Verification verification) {
@@ -163,6 +172,7 @@ private PersonUpdateParams(
163172
this.metadata = metadata;
164173
this.personToken = personToken;
165174
this.phone = phone;
175+
this.politicalExposure = politicalExposure;
166176
this.relationship = relationship;
167177
this.ssnLast4 = ssnLast4;
168178
this.verification = verification;
@@ -211,6 +221,8 @@ public static class Builder {
211221

212222
private Object phone;
213223

224+
private Object politicalExposure;
225+
214226
private Relationship relationship;
215227

216228
private Object ssnLast4;
@@ -239,6 +251,7 @@ public PersonUpdateParams build() {
239251
this.metadata,
240252
this.personToken,
241253
this.phone,
254+
this.politicalExposure,
242255
this.relationship,
243256
this.ssnLast4,
244257
this.verification);
@@ -542,6 +555,26 @@ public Builder setPhone(EmptyParam phone) {
542555
return this;
543556
}
544557

558+
/**
559+
* Indicates if the person or any of their representatives, family members, or other closely
560+
* related persons, declares that they hold or have held an important public job or function, in
561+
* any jurisdiction.
562+
*/
563+
public Builder setPoliticalExposure(String politicalExposure) {
564+
this.politicalExposure = politicalExposure;
565+
return this;
566+
}
567+
568+
/**
569+
* Indicates if the person or any of their representatives, family members, or other closely
570+
* related persons, declares that they hold or have held an important public job or function, in
571+
* any jurisdiction.
572+
*/
573+
public Builder setPoliticalExposure(EmptyParam politicalExposure) {
574+
this.politicalExposure = politicalExposure;
575+
return this;
576+
}
577+
545578
/** The relationship that this person has with the account's legal entity. */
546579
public Builder setRelationship(Relationship relationship) {
547580
this.relationship = relationship;

0 commit comments

Comments
 (0)