line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
##---------------------------------------------------------------------------- |
2
|
|
|
|
|
|
|
## Stripe API - ~/lib/Net/API/Stripe/Connect/Person.pm |
3
|
|
|
|
|
|
|
## Version v0.201.0 |
4
|
|
|
|
|
|
|
## Copyright(c) 2020 DEGUEST Pte. Ltd. |
5
|
|
|
|
|
|
|
## Author: Jacques Deguest <jack@deguest.jp> |
6
|
|
|
|
|
|
|
## Created 2019/11/02 |
7
|
|
|
|
|
|
|
## Modified 2022/10/29 |
8
|
|
|
|
|
|
|
## |
9
|
|
|
|
|
|
|
##---------------------------------------------------------------------------- |
10
|
|
|
|
|
|
|
package Net::API::Stripe::Connect::Person; |
11
|
|
|
|
|
|
|
BEGIN |
12
|
|
|
|
|
|
|
{ |
13
|
2
|
|
|
2
|
|
21288543
|
use strict; |
|
2
|
|
|
|
|
16
|
|
|
2
|
|
|
|
|
65
|
|
14
|
2
|
|
|
2
|
|
14
|
use warnings; |
|
2
|
|
|
|
|
8
|
|
|
2
|
|
|
|
|
68
|
|
15
|
2
|
|
|
2
|
|
11
|
use parent qw( Net::API::Stripe::Generic ); |
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
11
|
|
16
|
2
|
|
|
2
|
|
146
|
use vars qw( $VERSION ); |
|
2
|
|
|
|
|
6
|
|
|
2
|
|
|
|
|
118
|
|
17
|
2
|
|
|
2
|
|
989
|
use DateTime; |
|
2
|
|
|
|
|
541822
|
|
|
2
|
|
|
|
|
98
|
|
18
|
2
|
|
|
2
|
|
814
|
use DateTime::Format::Strptime; |
|
2
|
|
|
|
|
221454
|
|
|
2
|
|
|
|
|
21
|
|
19
|
2
|
|
|
2
|
|
157
|
use Nice::Try; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
23
|
|
20
|
2
|
|
|
2
|
|
560400
|
our( $VERSION ) = 'v0.201.0'; |
21
|
|
|
|
|
|
|
}; |
22
|
|
|
|
|
|
|
|
23
|
2
|
|
|
2
|
|
51
|
use strict; |
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
67
|
|
24
|
2
|
|
|
2
|
|
13
|
use warnings; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
2655
|
|
25
|
|
|
|
|
|
|
|
26
|
0
|
|
|
0
|
1
|
|
sub id { return( shift->_set_get_scalar( 'id', @_ ) ); } |
27
|
|
|
|
|
|
|
|
28
|
0
|
|
|
0
|
1
|
|
sub object { return( shift->_set_get_scalar( 'object', @_ ) ); } |
29
|
|
|
|
|
|
|
|
30
|
0
|
|
|
0
|
1
|
|
sub account { return( shift->_set_get_scalar_or_object( 'account', 'Net::API::Stripe::Connect::Account', @_ ) ); } |
31
|
|
|
|
|
|
|
|
32
|
0
|
|
|
0
|
1
|
|
sub additional { return( shift->_set_get_array( 'additional', @_ ) ); } |
33
|
|
|
|
|
|
|
|
34
|
0
|
|
|
0
|
1
|
|
sub address { return( shift->_set_get_object( 'address', 'Net::API::Stripe::Address', @_ ) ); } |
35
|
|
|
|
|
|
|
|
36
|
0
|
|
|
0
|
1
|
|
sub address_kana { return( shift->_set_get_object( 'address_kana', 'Net::API::Stripe::Address', @_ ) ); } |
37
|
|
|
|
|
|
|
|
38
|
0
|
|
|
0
|
1
|
|
sub address_kanji { return( shift->_set_get_object( 'address_kanji', 'Net::API::Stripe::Address', @_ ) ); } |
39
|
|
|
|
|
|
|
|
40
|
0
|
|
|
0
|
1
|
|
sub created { return( shift->_set_get_datetime( 'created', @_ ) ); } |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
sub dob |
43
|
|
|
|
|
|
|
{ |
44
|
0
|
|
|
0
|
1
|
|
my $self = shift( @_ ); |
45
|
0
|
0
|
|
|
|
|
if( @_ ) |
46
|
|
|
|
|
|
|
{ |
47
|
|
|
|
|
|
|
## There may be a hash provided with undefined values for each of the properties, so we need to check that |
48
|
0
|
|
|
|
|
|
my $ref = shift( @_ ); |
49
|
0
|
|
|
|
|
|
my $dt; |
50
|
0
|
0
|
0
|
|
|
|
if( $self->_is_object( $ref ) && $ref->isa( 'DateTime' ) ) |
|
|
0
|
|
|
|
|
|
51
|
|
|
|
|
|
|
{ |
52
|
0
|
|
|
|
|
|
$dt = $ref; |
53
|
|
|
|
|
|
|
} |
54
|
|
|
|
|
|
|
elsif( $self->_is_hash( $ref ) ) |
55
|
|
|
|
|
|
|
{ |
56
|
0
|
0
|
0
|
|
|
|
return if( !length( $ref->{year} ) && !length( $ref->{month} ) && !length( $ref->{day} ) ); |
|
|
|
0
|
|
|
|
|
57
|
|
|
|
|
|
|
|
58
|
0
|
|
|
|
|
|
foreach my $k ( qw( year month day ) ) |
59
|
|
|
|
|
|
|
{ |
60
|
0
|
0
|
|
|
|
|
return( $self->error( "Hash provided for person date of birth is missing the $k property" ) ) if( !$ref->{ $k } ); |
61
|
|
|
|
|
|
|
} |
62
|
0
|
|
|
|
|
|
@$ref{ qw( hour minute second ) } = ( 0, 0, 0 ); |
63
|
0
|
0
|
0
|
|
|
|
try |
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
64
|
0
|
|
|
0
|
|
|
{ |
65
|
0
|
|
|
|
|
|
$dt = DateTime->new( %$ref ); |
66
|
|
|
|
|
|
|
} |
67
|
0
|
0
|
0
|
|
|
|
catch( $e ) |
|
0
|
0
|
0
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
68
|
0
|
|
|
0
|
|
|
{ |
69
|
0
|
|
|
|
|
|
return( $self->error( "An error occurred while trying to create a datetime object from this person's date of birth (year = '$ref->{year}', month = '$ref->{month}', day = '$ref->{day}'." ) ); |
70
|
2
|
0
|
0
|
2
|
|
16
|
} |
|
2
|
0
|
0
|
|
|
5
|
|
|
2
|
0
|
0
|
|
|
1862
|
|
|
0
|
0
|
0
|
|
|
|
|
|
0
|
0
|
0
|
|
|
|
|
|
0
|
0
|
0
|
|
|
|
|
|
0
|
0
|
0
|
|
|
|
|
|
0
|
0
|
0
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
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
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
0
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
|
0
|
|
|
|
|
|
|
82
|
|
|
|
|
|
|
|
83
|
0
|
|
|
|
|
|
my $fmt = DateTime::Format::Strptime->new( |
84
|
|
|
|
|
|
|
pattern => '%Y-%m-%d', |
85
|
|
|
|
|
|
|
locale => 'en_GB', |
86
|
|
|
|
|
|
|
time_zone => $tz->name, |
87
|
|
|
|
|
|
|
); |
88
|
0
|
|
|
|
|
|
$dt->set_formatter( $fmt ); |
89
|
0
|
|
|
|
|
|
$self->{dob} = $dt; |
90
|
|
|
|
|
|
|
} |
91
|
0
|
|
|
|
|
|
return( $self->{dob} ); |
92
|
|
|
|
|
|
|
} |
93
|
|
|
|
|
|
|
|
94
|
0
|
|
|
0
|
1
|
|
sub email { return( shift->_set_get_scalar( 'email', @_ ) ); } |
95
|
|
|
|
|
|
|
|
96
|
0
|
|
|
0
|
1
|
|
sub first_name { return( shift->_set_get_scalar( 'first_name', @_ ) ); } |
97
|
|
|
|
|
|
|
|
98
|
0
|
|
|
0
|
1
|
|
sub first_name_kana { return( shift->_set_get_scalar( 'first_name_kana', @_ ) ); } |
99
|
|
|
|
|
|
|
|
100
|
0
|
|
|
0
|
1
|
|
sub first_name_kanji { return( shift->_set_get_scalar( 'first_name_kanji', @_ ) ); } |
101
|
|
|
|
|
|
|
|
102
|
0
|
|
|
0
|
1
|
|
sub full_name_aliases { return( shift->_set_get_array( 'full_name_aliases', @_ ) ); } |
103
|
|
|
|
|
|
|
|
104
|
0
|
|
|
0
|
1
|
|
sub future_requirements { return( shift->_set_get_object( 'future_requirements', 'Net::API::Stripe::Connect::Account::Requirements', @_ ) ); } |
105
|
|
|
|
|
|
|
|
106
|
0
|
|
|
0
|
1
|
|
sub gender { return( shift->_set_get_scalar( 'gender', @_ ) ); } |
107
|
|
|
|
|
|
|
|
108
|
0
|
|
|
0
|
1
|
|
sub id_number_provided { return( shift->_set_get_boolean( 'id_number_provided', @_ ) ); } |
109
|
|
|
|
|
|
|
|
110
|
0
|
|
|
0
|
1
|
|
sub id_number_secondary_provided { return( shift->_set_get_boolean( 'id_number_secondary_provided', @_ ) ); } |
111
|
|
|
|
|
|
|
|
112
|
0
|
|
|
0
|
1
|
|
sub last_name { return( shift->_set_get_scalar( 'last_name', @_ ) ); } |
113
|
|
|
|
|
|
|
|
114
|
0
|
|
|
0
|
1
|
|
sub last_name_kana { return( shift->_set_get_scalar( 'last_name_kana', @_ ) ); } |
115
|
|
|
|
|
|
|
|
116
|
0
|
|
|
0
|
1
|
|
sub last_name_kanji { return( shift->_set_get_scalar( 'last_name_kanji', @_ ) ); } |
117
|
|
|
|
|
|
|
|
118
|
0
|
|
|
0
|
1
|
|
sub maiden_name { return( shift->_set_get_scalar( 'maiden_name', @_ ) ); } |
119
|
|
|
|
|
|
|
|
120
|
0
|
|
|
0
|
1
|
|
sub metadata { return( shift->_set_get_hash( 'metadata', @_ ) ); } |
121
|
|
|
|
|
|
|
|
122
|
0
|
|
|
0
|
1
|
|
sub minimum { return( shift->_set_get_array( 'minimum', @_ ) ); } |
123
|
|
|
|
|
|
|
|
124
|
0
|
|
|
0
|
1
|
|
sub nationality { return( shift->_set_get_scalar( 'nationality', @_ ) ); } |
125
|
|
|
|
|
|
|
|
126
|
0
|
|
|
0
|
1
|
|
sub phone { return( shift->_set_get_scalar( 'phone', @_ ) ); } |
127
|
|
|
|
|
|
|
|
128
|
0
|
|
|
0
|
1
|
|
sub political_exposure { return( shift->_set_get_scalar( 'political_exposure', @_ ) ); } |
129
|
|
|
|
|
|
|
|
130
|
0
|
|
|
0
|
1
|
|
sub registered_address { return( shift->_set_get_object( 'registered_address', 'Net::API::Stripe::Address', @_ ) ); } |
131
|
|
|
|
|
|
|
|
132
|
0
|
|
|
0
|
1
|
|
sub relationship { return( shift->_set_get_object( 'relationship', 'Net::API::Stripe::Connect::Account::Relationship', @_ ) ); } |
133
|
|
|
|
|
|
|
|
134
|
0
|
|
|
0
|
1
|
|
sub requirements { return( shift->_set_get_object( 'requirements', 'Net::API::Stripe::Connect::Account::Requirements', @_ ) ); } |
135
|
|
|
|
|
|
|
|
136
|
0
|
|
|
0
|
1
|
|
sub ssn_last_4_provided { return( shift->_set_get_boolean( 'ssn_last_4_provided', @_ ) ); } |
137
|
|
|
|
|
|
|
|
138
|
0
|
|
|
0
|
1
|
|
sub verification { return( shift->_set_get_object( 'verification', 'Net::API::Stripe::Connect::Account::Verification', @_ ) ); } |
139
|
|
|
|
|
|
|
|
140
|
|
|
|
|
|
|
1; |
141
|
|
|
|
|
|
|
|
142
|
|
|
|
|
|
|
__END__ |
143
|
|
|
|
|
|
|
|
144
|
|
|
|
|
|
|
=encoding utf8 |
145
|
|
|
|
|
|
|
|
146
|
|
|
|
|
|
|
=head1 NAME |
147
|
|
|
|
|
|
|
|
148
|
|
|
|
|
|
|
Net::API::Stripe::Connect::Person - A Stripe Person Object |
149
|
|
|
|
|
|
|
|
150
|
|
|
|
|
|
|
=head1 SYNOPSIS |
151
|
|
|
|
|
|
|
|
152
|
|
|
|
|
|
|
my $pers = $stripe->person({ |
153
|
|
|
|
|
|
|
account => $account_object, |
154
|
|
|
|
|
|
|
address => $address_object, |
155
|
|
|
|
|
|
|
address_kana => $address_kana_object, |
156
|
|
|
|
|
|
|
address_kanji => $address_kanji_object, |
157
|
|
|
|
|
|
|
# or: |
158
|
|
|
|
|
|
|
# dob => DateTime->new( year => 1985, month => 8, day => 15 ) |
159
|
|
|
|
|
|
|
dob => |
160
|
|
|
|
|
|
|
{ |
161
|
|
|
|
|
|
|
day => 15 |
162
|
|
|
|
|
|
|
month => 8, |
163
|
|
|
|
|
|
|
year => 1985, |
164
|
|
|
|
|
|
|
}, |
165
|
|
|
|
|
|
|
email => 'nadeshiko.yamato@example.com', |
166
|
|
|
|
|
|
|
first_name => 'Nadeshiko', |
167
|
|
|
|
|
|
|
last_name => 'Yamato', |
168
|
|
|
|
|
|
|
first_name_kana => 'なでしこ', |
169
|
|
|
|
|
|
|
last_name_kana => 'やまと', |
170
|
|
|
|
|
|
|
first_name_kanji => '撫子', |
171
|
|
|
|
|
|
|
last_name_kanji => '大和', |
172
|
|
|
|
|
|
|
gender => 'female', |
173
|
|
|
|
|
|
|
metadata => { transaction_id => 123, customer_id => 456 }, |
174
|
|
|
|
|
|
|
phone => '+81-(0)90-1234-5678', |
175
|
|
|
|
|
|
|
}); |
176
|
|
|
|
|
|
|
|
177
|
|
|
|
|
|
|
See documentation in L<Net::API::Stripe> for example to make api calls to Stripe to create those objects. |
178
|
|
|
|
|
|
|
|
179
|
|
|
|
|
|
|
=head1 VERSION |
180
|
|
|
|
|
|
|
|
181
|
|
|
|
|
|
|
v0.201.0 |
182
|
|
|
|
|
|
|
|
183
|
|
|
|
|
|
|
=head1 DESCRIPTION |
184
|
|
|
|
|
|
|
|
185
|
|
|
|
|
|
|
This is an object representing a person associated with a Stripe account. |
186
|
|
|
|
|
|
|
|
187
|
|
|
|
|
|
|
=head1 CONSTRUCTOR |
188
|
|
|
|
|
|
|
|
189
|
|
|
|
|
|
|
=head2 new( %ARG ) |
190
|
|
|
|
|
|
|
|
191
|
|
|
|
|
|
|
Creates a new L<Net::API::Stripe::Connect::Person> object. |
192
|
|
|
|
|
|
|
It may also take an hash like arguments, that also are method of the same name. |
193
|
|
|
|
|
|
|
|
194
|
|
|
|
|
|
|
=head1 METHODS |
195
|
|
|
|
|
|
|
|
196
|
|
|
|
|
|
|
=head2 id string |
197
|
|
|
|
|
|
|
|
198
|
|
|
|
|
|
|
Unique identifier for the object. |
199
|
|
|
|
|
|
|
|
200
|
|
|
|
|
|
|
=head2 object string, value is "person" |
201
|
|
|
|
|
|
|
|
202
|
|
|
|
|
|
|
String representing the object’s type. Objects of the same type share the same value. |
203
|
|
|
|
|
|
|
|
204
|
|
|
|
|
|
|
=head2 account string |
205
|
|
|
|
|
|
|
|
206
|
|
|
|
|
|
|
The account the person is associated with. If expanded (currently not implemented in Stripe API), this will be a L<Net::API::Stripe::Connect::Account> object. |
207
|
|
|
|
|
|
|
|
208
|
|
|
|
|
|
|
=head2 additional string_array |
209
|
|
|
|
|
|
|
|
210
|
|
|
|
|
|
|
Additional fields which are only required for some users. |
211
|
|
|
|
|
|
|
|
212
|
|
|
|
|
|
|
=head2 address hash |
213
|
|
|
|
|
|
|
|
214
|
|
|
|
|
|
|
The person’s address. |
215
|
|
|
|
|
|
|
|
216
|
|
|
|
|
|
|
This is L<Net::API::Stripe::Address> object. |
217
|
|
|
|
|
|
|
|
218
|
|
|
|
|
|
|
=head2 address_kana hash |
219
|
|
|
|
|
|
|
|
220
|
|
|
|
|
|
|
The Kana variation of the person’s address (Japan only). |
221
|
|
|
|
|
|
|
|
222
|
|
|
|
|
|
|
This is L<Net::API::Stripe::Address> object. |
223
|
|
|
|
|
|
|
|
224
|
|
|
|
|
|
|
=head2 address_kanji hash |
225
|
|
|
|
|
|
|
|
226
|
|
|
|
|
|
|
The Kanji variation of the person’s address (Japan only). |
227
|
|
|
|
|
|
|
|
228
|
|
|
|
|
|
|
This is L<Net::API::Stripe::Address> object. |
229
|
|
|
|
|
|
|
|
230
|
|
|
|
|
|
|
=head2 created timestamp |
231
|
|
|
|
|
|
|
|
232
|
|
|
|
|
|
|
Time at which the object was created. Measured in seconds since the Unix epoch. |
233
|
|
|
|
|
|
|
|
234
|
|
|
|
|
|
|
=head2 dob L<DateTime> object or hash |
235
|
|
|
|
|
|
|
|
236
|
|
|
|
|
|
|
The person’s date of birth. |
237
|
|
|
|
|
|
|
|
238
|
|
|
|
|
|
|
This returns a C<DateTime> object. It can take either a L<DateTime> object or an hash with the following properties: |
239
|
|
|
|
|
|
|
|
240
|
|
|
|
|
|
|
=over 4 |
241
|
|
|
|
|
|
|
|
242
|
|
|
|
|
|
|
=item I<day> positive integer |
243
|
|
|
|
|
|
|
|
244
|
|
|
|
|
|
|
The day of birth, between 1 and 31. |
245
|
|
|
|
|
|
|
|
246
|
|
|
|
|
|
|
=item I<month> positive integer |
247
|
|
|
|
|
|
|
|
248
|
|
|
|
|
|
|
The month of birth, between 1 and 12. |
249
|
|
|
|
|
|
|
|
250
|
|
|
|
|
|
|
=item I<year> positive integer |
251
|
|
|
|
|
|
|
|
252
|
|
|
|
|
|
|
The four-digit year of birth. |
253
|
|
|
|
|
|
|
|
254
|
|
|
|
|
|
|
=back |
255
|
|
|
|
|
|
|
|
256
|
|
|
|
|
|
|
=head2 email string |
257
|
|
|
|
|
|
|
|
258
|
|
|
|
|
|
|
The person’s email address. |
259
|
|
|
|
|
|
|
|
260
|
|
|
|
|
|
|
=head2 first_name string |
261
|
|
|
|
|
|
|
|
262
|
|
|
|
|
|
|
The person’s first name. |
263
|
|
|
|
|
|
|
|
264
|
|
|
|
|
|
|
=head2 first_name_kana string |
265
|
|
|
|
|
|
|
|
266
|
|
|
|
|
|
|
The Kana variation of the person’s first name (Japan only). |
267
|
|
|
|
|
|
|
|
268
|
|
|
|
|
|
|
=head2 first_name_kanji string |
269
|
|
|
|
|
|
|
|
270
|
|
|
|
|
|
|
The Kanji variation of the person’s first name (Japan only). |
271
|
|
|
|
|
|
|
|
272
|
|
|
|
|
|
|
=head2 full_name_aliases string_array |
273
|
|
|
|
|
|
|
|
274
|
|
|
|
|
|
|
A list of alternate names or aliases that the individual is known by. |
275
|
|
|
|
|
|
|
|
276
|
|
|
|
|
|
|
=head2 future_requirements object |
277
|
|
|
|
|
|
|
|
278
|
|
|
|
|
|
|
Information about future requirements for the individual, including what information needs to be collected, and by when. |
279
|
|
|
|
|
|
|
|
280
|
|
|
|
|
|
|
This is a L<Net::API::Stripe::Connect::Account::Requirements> object. |
281
|
|
|
|
|
|
|
|
282
|
|
|
|
|
|
|
=head2 gender string |
283
|
|
|
|
|
|
|
|
284
|
|
|
|
|
|
|
The person’s gender (International regulations require either “male” or “female”). |
285
|
|
|
|
|
|
|
|
286
|
|
|
|
|
|
|
=head2 id_number_provided boolean |
287
|
|
|
|
|
|
|
|
288
|
|
|
|
|
|
|
Whether the person’s id_number was provided. |
289
|
|
|
|
|
|
|
|
290
|
|
|
|
|
|
|
=head2 id_number_secondary_provided boolean |
291
|
|
|
|
|
|
|
|
292
|
|
|
|
|
|
|
Whether the individual's personal secondary ID number was provided. |
293
|
|
|
|
|
|
|
|
294
|
|
|
|
|
|
|
=head2 last_name string |
295
|
|
|
|
|
|
|
|
296
|
|
|
|
|
|
|
The person’s last name. |
297
|
|
|
|
|
|
|
|
298
|
|
|
|
|
|
|
=head2 last_name_kana string |
299
|
|
|
|
|
|
|
|
300
|
|
|
|
|
|
|
The Kana variation of the person’s last name (Japan only). |
301
|
|
|
|
|
|
|
|
302
|
|
|
|
|
|
|
=head2 last_name_kanji string |
303
|
|
|
|
|
|
|
|
304
|
|
|
|
|
|
|
The Kanji variation of the person’s last name (Japan only). |
305
|
|
|
|
|
|
|
|
306
|
|
|
|
|
|
|
=head2 maiden_name string |
307
|
|
|
|
|
|
|
|
308
|
|
|
|
|
|
|
The person’s maiden name. |
309
|
|
|
|
|
|
|
|
310
|
|
|
|
|
|
|
=head2 metadata hash |
311
|
|
|
|
|
|
|
|
312
|
|
|
|
|
|
|
Set of key-value pairs that you can attach to an object. This can be useful for storing additional information about the object in a structured format. |
313
|
|
|
|
|
|
|
|
314
|
|
|
|
|
|
|
=head2 minimum string_array |
315
|
|
|
|
|
|
|
|
316
|
|
|
|
|
|
|
Fields which every account must eventually provide. |
317
|
|
|
|
|
|
|
|
318
|
|
|
|
|
|
|
=head2 nationality string |
319
|
|
|
|
|
|
|
|
320
|
|
|
|
|
|
|
The country where the person is a national. |
321
|
|
|
|
|
|
|
|
322
|
|
|
|
|
|
|
=head2 phone string |
323
|
|
|
|
|
|
|
|
324
|
|
|
|
|
|
|
The person’s phone number. |
325
|
|
|
|
|
|
|
|
326
|
|
|
|
|
|
|
=head2 political_exposure string |
327
|
|
|
|
|
|
|
|
328
|
|
|
|
|
|
|
Indicates if the person or any of their representatives, family members, or other closely related persons, declares that they hold or have held an important public job or function, in any jurisdiction. |
329
|
|
|
|
|
|
|
|
330
|
|
|
|
|
|
|
=head2 registered_address object |
331
|
|
|
|
|
|
|
|
332
|
|
|
|
|
|
|
The individual's registered address. |
333
|
|
|
|
|
|
|
|
334
|
|
|
|
|
|
|
This is a L<Net::API::Stripe::Address> object. |
335
|
|
|
|
|
|
|
|
336
|
|
|
|
|
|
|
=head2 relationship hash |
337
|
|
|
|
|
|
|
|
338
|
|
|
|
|
|
|
Describes the person’s relationship to the account. |
339
|
|
|
|
|
|
|
|
340
|
|
|
|
|
|
|
This is a L<Net::API::Stripe::Connect::Account::Relationship> object. |
341
|
|
|
|
|
|
|
|
342
|
|
|
|
|
|
|
=head2 requirements hash |
343
|
|
|
|
|
|
|
|
344
|
|
|
|
|
|
|
Information about the requirements for this person, including what information needs to be collected, and by when. |
345
|
|
|
|
|
|
|
|
346
|
|
|
|
|
|
|
This is a L<Net::API::Stripe::Connect::Account::Requirements> object. |
347
|
|
|
|
|
|
|
|
348
|
|
|
|
|
|
|
=head2 ssn_last_4_provided boolean |
349
|
|
|
|
|
|
|
|
350
|
|
|
|
|
|
|
Whether the last 4 digits of this person’s SSN have been provided. |
351
|
|
|
|
|
|
|
|
352
|
|
|
|
|
|
|
=head2 verification hash |
353
|
|
|
|
|
|
|
|
354
|
|
|
|
|
|
|
The persons’s verification status. |
355
|
|
|
|
|
|
|
|
356
|
|
|
|
|
|
|
This is a L<Net::API::Stripe::Connect::Account::Verification> object. |
357
|
|
|
|
|
|
|
|
358
|
|
|
|
|
|
|
=head1 API SAMPLE |
359
|
|
|
|
|
|
|
|
360
|
|
|
|
|
|
|
{ |
361
|
|
|
|
|
|
|
"id": "person_fake123456789", |
362
|
|
|
|
|
|
|
"object": "person", |
363
|
|
|
|
|
|
|
"account": "acct_fake123456789", |
364
|
|
|
|
|
|
|
"created": 1571602397, |
365
|
|
|
|
|
|
|
"dob": { |
366
|
|
|
|
|
|
|
"day": null, |
367
|
|
|
|
|
|
|
"month": null, |
368
|
|
|
|
|
|
|
"year": null |
369
|
|
|
|
|
|
|
}, |
370
|
|
|
|
|
|
|
"first_name_kana": null, |
371
|
|
|
|
|
|
|
"first_name_kanji": null, |
372
|
|
|
|
|
|
|
"gender": null, |
373
|
|
|
|
|
|
|
"last_name_kana": null, |
374
|
|
|
|
|
|
|
"last_name_kanji": null, |
375
|
|
|
|
|
|
|
"metadata": {}, |
376
|
|
|
|
|
|
|
"relationship": { |
377
|
|
|
|
|
|
|
"director": false, |
378
|
|
|
|
|
|
|
"executive": false, |
379
|
|
|
|
|
|
|
"owner": false, |
380
|
|
|
|
|
|
|
"percent_ownership": null, |
381
|
|
|
|
|
|
|
"representative": false, |
382
|
|
|
|
|
|
|
"title": null |
383
|
|
|
|
|
|
|
}, |
384
|
|
|
|
|
|
|
"requirements": { |
385
|
|
|
|
|
|
|
"currently_due": [], |
386
|
|
|
|
|
|
|
"eventually_due": [], |
387
|
|
|
|
|
|
|
"past_due": [], |
388
|
|
|
|
|
|
|
"pending_verification": [] |
389
|
|
|
|
|
|
|
}, |
390
|
|
|
|
|
|
|
"verification": { |
391
|
|
|
|
|
|
|
"additional_document": { |
392
|
|
|
|
|
|
|
"back": null, |
393
|
|
|
|
|
|
|
"details": null, |
394
|
|
|
|
|
|
|
"details_code": null, |
395
|
|
|
|
|
|
|
"front": null |
396
|
|
|
|
|
|
|
}, |
397
|
|
|
|
|
|
|
"details": null, |
398
|
|
|
|
|
|
|
"details_code": null, |
399
|
|
|
|
|
|
|
"document": { |
400
|
|
|
|
|
|
|
"back": null, |
401
|
|
|
|
|
|
|
"details": null, |
402
|
|
|
|
|
|
|
"details_code": null, |
403
|
|
|
|
|
|
|
"front": null |
404
|
|
|
|
|
|
|
}, |
405
|
|
|
|
|
|
|
"status": "unverified" |
406
|
|
|
|
|
|
|
} |
407
|
|
|
|
|
|
|
} |
408
|
|
|
|
|
|
|
|
409
|
|
|
|
|
|
|
=head1 HISTORY |
410
|
|
|
|
|
|
|
|
411
|
|
|
|
|
|
|
=head2 v0.1 |
412
|
|
|
|
|
|
|
|
413
|
|
|
|
|
|
|
Initial version |
414
|
|
|
|
|
|
|
|
415
|
|
|
|
|
|
|
=head2 v0.2 |
416
|
|
|
|
|
|
|
|
417
|
|
|
|
|
|
|
Update the method B<dob> to accept L<DateTime> objects |
418
|
|
|
|
|
|
|
|
419
|
|
|
|
|
|
|
=head1 AUTHOR |
420
|
|
|
|
|
|
|
|
421
|
|
|
|
|
|
|
Jacques Deguest E<lt>F<jack@deguest.jp>E<gt> |
422
|
|
|
|
|
|
|
|
423
|
|
|
|
|
|
|
=head1 SEE ALSO |
424
|
|
|
|
|
|
|
|
425
|
|
|
|
|
|
|
Stripe API documentation: |
426
|
|
|
|
|
|
|
|
427
|
|
|
|
|
|
|
L<https://stripe.com/docs/api/persons/object>, L<https://stripe.com/docs/connect/identity-verification-api#person-information> |
428
|
|
|
|
|
|
|
|
429
|
|
|
|
|
|
|
=head1 COPYRIGHT & LICENSE |
430
|
|
|
|
|
|
|
|
431
|
|
|
|
|
|
|
Copyright (c) 2020-2020 DEGUEST Pte. Ltd. |
432
|
|
|
|
|
|
|
|
433
|
|
|
|
|
|
|
You can use, copy, modify and redistribute this package and associated |
434
|
|
|
|
|
|
|
files under the same terms as Perl itself. |
435
|
|
|
|
|
|
|
|
436
|
|
|
|
|
|
|
=cut |