|
| 1 | +package com.checkout.handlepaymentsandpayouts.setups.entities.paymentMethods.cashapp; |
| 2 | + |
| 3 | +import com.checkout.common.CountryCode; |
| 4 | +import com.google.gson.annotations.SerializedName; |
| 5 | +import lombok.AllArgsConstructor; |
| 6 | +import lombok.Builder; |
| 7 | +import lombok.Data; |
| 8 | +import lombok.NoArgsConstructor; |
| 9 | + |
| 10 | +/** |
| 11 | + * The customer's address from their Cash App profile. The keys follow Cash App's naming |
| 12 | + * (address_line_1, locality, administrative_district_level_1), not the Checkout.com address, so |
| 13 | + * the line and district fields carry an explicit serialized name: the naming policy alone would |
| 14 | + * produce address_line1. |
| 15 | + */ |
| 16 | +@Data |
| 17 | +@Builder |
| 18 | +@NoArgsConstructor |
| 19 | +@AllArgsConstructor |
| 20 | +public final class CashAppAddress { |
| 21 | + |
| 22 | + /** |
| 23 | + * The first line of the address. |
| 24 | + * [Optional] readOnly |
| 25 | + */ |
| 26 | + @SerializedName("address_line_1") |
| 27 | + private String addressLine1; |
| 28 | + |
| 29 | + /** |
| 30 | + * The second line of the address. |
| 31 | + * [Optional] readOnly |
| 32 | + */ |
| 33 | + @SerializedName("address_line_2") |
| 34 | + private String addressLine2; |
| 35 | + |
| 36 | + /** |
| 37 | + * The third line of the address. |
| 38 | + * [Optional] readOnly |
| 39 | + */ |
| 40 | + @SerializedName("address_line_3") |
| 41 | + private String addressLine3; |
| 42 | + |
| 43 | + /** |
| 44 | + * The address locality, such as the city or town. |
| 45 | + * [Optional] readOnly |
| 46 | + */ |
| 47 | + private String locality; |
| 48 | + |
| 49 | + /** |
| 50 | + * The address sublocality, such as the district or neighborhood. |
| 51 | + * [Optional] readOnly |
| 52 | + */ |
| 53 | + private String sublocality; |
| 54 | + |
| 55 | + /** |
| 56 | + * The address's top-level administrative district, such as the state or province. |
| 57 | + * [Optional] readOnly |
| 58 | + */ |
| 59 | + @SerializedName("administrative_district_level_1") |
| 60 | + private String administrativeDistrictLevel1; |
| 61 | + |
| 62 | + /** |
| 63 | + * The postal or zip code. |
| 64 | + * [Optional] readOnly |
| 65 | + */ |
| 66 | + private String postalCode; |
| 67 | + |
| 68 | + /** |
| 69 | + * The address country, in ISO 3166-1 alpha-2 format. |
| 70 | + * [Optional] readOnly |
| 71 | + * max 2 characters |
| 72 | + */ |
| 73 | + private CountryCode country; |
| 74 | +} |
0 commit comments