Stripe/Connect/Account.pm

filter: Statementstmt 17.0% 8 / 47 Branchbran n/a Conditioncond n/a MC/DCmcdc n/a Subroutinesub 7.1% 3 / 42 Podpod 100% 39 / 39 totaltotal 39.0% 50 / 128 CC 1 SCAR 6.6
CC
1
Cov
17%
id
2.0
object
2.0
business_logo
2.0
CRAP 1.9
« Stripe/Charge.pm ↑ Summary Stripe/Connect/ExternalAccount/Card.pm »
1 ##----------------------------------------------------------------------------
2 ## Stripe API - ~/lib/Net/API/Stripe/Connect/Account.pm
3 ## Version v0.100.0
4 ## Copyright(c) 2019 DEGUEST Pte. Ltd.
5 ## Author: Jacques Deguest <@sitael.tokyo.deguest.jp>
6 ## Created 2019/11/02
7 ## Modified 2020/05/15
8 ##
9 ##----------------------------------------------------------------------------
10 ## https://stripe.com/docs/api/account/object
11 package Net::API::Stripe::Connect::Account;
12 BEGIN
13 {
14 1 ▶ use strict;
Subroutine BEGIN: called CC=1 SCAR=0.0
15 1 ▶ use parent qw( Net::API::Stripe::Generic );
Subroutine BEGIN: called CC=1 SCAR=0.0
16 1 ▶ our( $VERSION ) = 'v0.100.0';
Subroutine BEGIN: called CC=1 SCAR=0.0
17 };
18  
19 0 ▶sub id { shift->_set_get_scalar( 'id', @_ ); }
Subroutine id: not called CC=1 SCAR=6.9
Pod documented
20  
21 0 ▶sub object { shift->_set_get_scalar( 'object', @_ ); }
Subroutine object: not called CC=1 SCAR=6.9
Pod documented
22  
23 ## Moved as of 2019-02-19
24 # sub business_logo { shift->_set_get_scalar_or_object( 'business_logo', 'Net::API::Stripe::File', @_ ); }
25 # Thanks to Module::Generic _set_get_object feature, even if settings is not set this will not crash
26 0 ▶sub business_logo { return( shift->settings->branding->icon( @_ ) ); }
Subroutine business_logo: not called CC=1 SCAR=6.9
Pod documented
27  
28 ## Moved as of 2019-02-19
29 ## sub business_logo_large { shift->_set_get_scalar( 'business_logo_large', @_ ); }
30 0 ▶sub business_logo_large { return( shift->settings->branding->logo( @_ ) ); }
Subroutine business_logo_large: not called CC=1 SCAR=6.9
Pod documented
31  
32 ## Moved as of 2019-02-19
33 ## sub business_name { shift->_set_get_scalar( 'business_name', @_ ); }
34 0 ▶sub business_name { return( shift->business_profile->name( @_ ) ); }
Subroutine business_name: not called CC=1 SCAR=6.9
Pod documented
35  
36 ## Moved as of 2019-02-19
37 ## sub business_primary_color { shift->_set_get_scalar( 'business_primary_color', @_ ); }
38 0 ▶sub business_primary_color { return( shift->settings->branding->primary_color( @_ ) ); }
Subroutine business_primary_color: not called CC=1 SCAR=6.9
Pod documented
39  
40 0 ▶sub business_profile { return( shift->_set_get_object( 'business_profile', 'Net::API::Stripe::Connect::Business::Profile', @_ ) ); }
Subroutine business_profile: not called CC=1 SCAR=6.9
Pod documented
41  
42 0 ▶sub business_type { return( shift->_set_get_scalar( 'business_type', @_ ) ); }
Subroutine business_type: not called CC=1 SCAR=6.9
Pod documented
43  
44 ## Moved as of 2019-02-19
45 ## sub business_url { shift->_set_get_uri( 'business_url', @_ ); }
46 0 ▶sub business_url { return( shift->business_profile->url( @_ ) ); }
Subroutine business_url: not called CC=1 SCAR=6.9
Pod documented
47  
48 ## This is a fake module (Net::API::Stripe::Connect::Account::Capabilities), but will allow the user to call the property as method of that module
49 0 ▶sub capabilities { return( shift->_set_get_hash_as_object( 'capabilities', 'Net::API::Stripe::Connect::Account::Capabilities', @_ ) ); }
Subroutine capabilities: not called CC=1 SCAR=6.9
Pod documented
50  
51 0 ▶sub charges_enabled { shift->_set_get_boolean( 'charges_enabled', @_ ); }
Subroutine charges_enabled: not called CC=1 SCAR=6.9
Pod documented
52  
53 0 ▶sub company { return( shift->_set_get_object( 'company', 'Net::API::Stripe::Connect::Account::Company', @_ ) ); }
Subroutine company: not called CC=1 SCAR=6.9
Pod documented
54  
55 0 ▶sub country { shift->_set_get_scalar( 'country', @_ ); }
Subroutine country: not called CC=1 SCAR=6.9
Pod documented
56  
57 0 ▶sub created { shift->_set_get_datetime( 'created', @_ ); }
Subroutine created: not called CC=1 SCAR=6.9
Pod documented
58  
59 ## Moved as of 2019-02-19
60 # sub debit_negative_balances { shift->_set_get_scalar( 'debit_negative_balances', @_ ); }
61 0 ▶sub debit_negative_balances { return( shift->settings->payouts->debit_negative_balances( @_ ) ); }
Subroutine debit_negative_balances: not called CC=1 SCAR=6.9
Pod documented
62  
63 ## Moved as of 2019-02-19
64 # sub decline_charge_on { shift->_set_get_object( 'decline_charge_on', 'Net::API::Stripe::Connect::Account::DeclineChargeOn', @_ ); }
65 0 ▶sub decline_charge_on { return( shift->settings->card_payments->decline_on( @_ ) ); }
Subroutine decline_charge_on: not called CC=1 SCAR=6.9
Pod documented
66  
67 0 ▶sub default_currency { shift->_set_get_scalar( 'default_currency', @_ ); }
Subroutine default_currency: not called CC=1 SCAR=6.9
Pod documented
68  
69 0 ▶sub details_submitted { shift->_set_get_boolean( 'details_submitted', @_ ); }
Subroutine details_submitted: not called CC=1 SCAR=6.9
Pod documented
70  
71 ## Moved as of 2019-02-19
72 ## sub display_name { shift->_set_get_scalar( 'display_name', @_ ); }
73 0 ▶sub display_name { return( shift->settings->dashboard->display_name( @_ ) ); }
Subroutine display_name: not called CC=1 SCAR=6.9
Pod documented
74  
75 0 ▶sub email { shift->_set_get_scalar( 'email', @_ ); }
Subroutine email: not called CC=1 SCAR=6.9
Pod documented
76  
77 0 ▶sub external_accounts { shift->_set_get_object( 'external_accounts', 'Net::API::Stripe::Connect::Account::ExternalAccounts', @_ ); }
Subroutine external_accounts: not called CC=1 SCAR=6.9
Pod documented
78  
79 0 ▶sub individual { return( shift->_set_get_object( 'individual', 'Net::API::Stripe::Connect::Person', @_ ) ); }
Subroutine individual: not called CC=1 SCAR=6.9
Pod documented
80  
81 0 ▶sub legal_entity { shift->_set_get_object( 'legal_entity', 'Net::API::Stripe::Connect::Account::LegalEntity', @_ ); }
Subroutine legal_entity: not called CC=1 SCAR=6.9
Pod documented
82  
83 0 ▶sub metadata { return( shift->_set_get_hash( 'metadata', @_ ) ); }
Subroutine metadata: not called CC=1 SCAR=6.9
Pod documented
84  
85 0 ▶sub payouts_enabled { shift->_set_get_boolean( 'payouts_enabled', @_ ); }
Subroutine payouts_enabled: not called CC=1 SCAR=6.9
Pod documented
86  
87 ## Moved as of 2019-02-19
88 ## sub payout_schedule { shift->_set_get_object( 'payout_schedule', 'Net::API::Stripe::Connect::Account::PaymentSchedule', @_ ); }
89 0 ▶sub payout_schedule { return( shift->settings->payouts->schedule( @_ ) ); }
Subroutine payout_schedule: not called CC=1 SCAR=6.9
Pod documented
90  
91 ## Moved as of 2019-02-19
92 ## sub payout_statement_descriptor { shift->_set_get_scalar( 'payout_statement_descriptor', @_ ); }
93 0 ▶sub payout_statement_descriptor { return( shift->settings->payouts->statement_descriptor( @_ ) ); }
Subroutine payout_statement_descriptor: not called CC=1 SCAR=6.9
Pod documented
94  
95 ## Moved as of 2019-02-19
96 ## sub product_description { shift->_set_get_scalar( 'product_description', @_ ); }
97 0 ▶sub product_description { return( shift->business_profile->product_description( @_ ) ); }
Subroutine product_description: not called CC=1 SCAR=6.9
Pod documented
98  
99 0 ▶sub requirements { return( shift->_set_get_object( 'requirements', 'Net::API::Stripe::Connect::Account::Requirements', @_ ) ); }
Subroutine requirements: not called CC=1 SCAR=6.9
Pod documented
100  
101 0 ▶sub settings { return( shift->_set_get_object( 'settings', 'Net::API::Stripe::Connect::Account::Settings', @_ ) ); }
Subroutine settings: not called CC=1 SCAR=6.9
Pod documented
102  
103 ## Moved as of 2019-02-19
104 ## sub statement_descriptor { shift->_set_get_scalar( 'statement_descriptor', @_ ); }
105 0 ▶sub statement_descriptor { return( shift->settings->payments->statement_descriptor( @_ ) ); }
Subroutine statement_descriptor: not called CC=1 SCAR=6.9
Pod documented
106  
107 ## Moved as of 2019-02-19
108 ## sub support_address { shift->_set_get_object( 'support_address', 'Net::API::Stripe::Address', @_ ); }
109 0 ▶sub support_address { return( shift->business_profile->support_address( @_ ) ); }
Subroutine support_address: not called CC=1 SCAR=6.9
Pod documented
110  
111 ## Moved as of 2019-02-19
112 ## sub support_email { shift->_set_get_scalar( 'support_email', @_ ); }
113 0 ▶sub support_email { return( shift->business_profile->support_email( @_ ) ); }
Subroutine support_email: not called CC=1 SCAR=6.9
Pod documented
114  
115 ## Moved as of 2019-02-19
116 ## sub support_phone { shift->_set_get_scalar( 'support_phone', @_ ); }
117 0 ▶sub support_phone { return( shift->business_profile->support_phone( @_ ) ); }
Subroutine support_phone: not called CC=1 SCAR=6.9
Pod documented
118  
119 ## Moved as of 2019-02-19
120 ## sub support_url { shift->_set_get_uri( 'support_url', @_ ); }
121 0 ▶sub support_url { return( shift->business_profile->support_url( @_ ) ); }
Subroutine support_url: not called CC=1 SCAR=6.9
Pod documented
122  
123 ## Moved as of 2019-02-19
124 ## sub timezone { shift->_set_get_scalar( 'timezone', @_ ); }
125 0 ▶sub timezone { return( shift->settings->dashboard->timezone( @_ ) ); }
Subroutine timezone: not called CC=1 SCAR=6.9
Pod documented
126  
127 0 ▶sub tos_acceptance { shift->_set_get_object( 'tos_acceptance', 'Net::API::Stripe::Connect::Account::TosAcceptance', @_ ); }
Subroutine tos_acceptance: not called CC=1 SCAR=6.9
Pod documented
128  
129 ## standard, express, or custom
130 0 ▶sub type { shift->_set_get_scalar( 'type', @_ ); }
Subroutine type: not called CC=1 SCAR=6.9
Pod documented
131  
132 ## Not used anymore as of 2019-02-19
133 0 ▶sub verification { shift->_set_get_object( 'verification', 'Net::API::Stripe::Connect::Account::Verification', @_ ); }
Subroutine verification: not called CC=1 SCAR=6.9
Pod documented
134  
135 1 1;
136  
137 __END__
138  
139 =encoding utf8
140  
141 =head1 NAME
142  
143 Net::API::Stripe::Connect::Account - A Stripe Account Object
144  
145 =head1 SYNOPSIS
146  
147 my $acct = $stripe->account({
148 business_profile =>
149 {
150 logo => '/some/file/path/logo.jpg',
151 name => 'Big Corp, Inc',
152 },
153 settings =>
154 {
155 primary_color => 'blue',
156 dashboard => { display_name => 'Big Corp, Inc' },
157 },
158 business_type => 'company',
159 business_url => 'https://example.com',
160 charges_enabled => $stripe->true,
161 company => $company_object,
162 country => 'jp',
163 default_currency => 'jpy',
164 email => 'hello@example.com',
165 metadata => { transaction_id => 1212, customer_id => 123 },
166 });
167  
168 =head1 VERSION
169  
170 v0.100.0
171  
172 =head1 DESCRIPTION
173  
174 This is an object representing a Stripe account. You can retrieve it to see properties on the account like its current e-mail address or if the account is enabled yet to make live charges.
175  
176 Some properties, marked below, are available only to platforms that want to create and manage Express or Custom accounts (L<https://stripe.com/docs/connect/accounts>).
177  
178 =head1 CONSTRUCTOR
179  
180 =over 4
181  
182 =item B<new>( %ARG )
183  
184 Creates a new L<Net::API::Stripe::Connect::Account> object.
185 It may also take an hash like arguments, that also are method of the same name.
186  
187 =back
188  
189 =head1 METHODS
190  
191 =over 4
192  
193 =item B<id> string
194  
195 Unique identifier for the object.
196  
197 =item B<object> string, value is "account"
198  
199 String representing the object’s type. Objects of the same type share the same value.
200  
201 =item B<business_logo>
202  
203 This is outdated. It now points to B<business_profile>->B<icon>
204  
205 =item B<business_logo_large>
206  
207 This is outdated. It now points to B<business_profile>->B<logo>
208  
209 =item B<business_name>
210  
211 This is outdated. It now points to B<business_name>->B<name>
212  
213 =item B<business_primary_color>
214  
215 This is outdated. It now points to B<settings>->B<primary_color>
216  
217 =item B<business_profile> hash
218  
219 Optional information related to the business.
220  
221 This is a L<Net::API::Stripe::Business::Profile> object.
222  
223 =item B<business_type> string
224  
225 The business type. Can be individual or company.
226  
227 =item B<business_url>
228  
229 This is outdated. It now points to B<business_profile>->B<url>
230  
231 =item B<capabilities> hash
232  
233 A hash containing the set of capabilities that was requested for this account and their associated states. Keys are names of capabilities. You can see the full list here (L<https://stripe.com/docs/api/capabilities/list>). Values may be active, inactive, or pending.
234  
235 This is a L<Net::API::Stripe::Connect::Account::Capabilities> object, although there is no real L<Net::API::Stripe::Connect::Account::Capability> module. This is created on the fly by the B<_set_get_hash_as_object> method of L<Module::Generic>
236  
237 =over 8
238  
239 =item B<card_issuing> string
240  
241 The status of the card issuing capability of the account, or whether you can use Issuing to distribute funds on cards
242  
243 =item B<card_payments> string
244  
245 The status of the card payments capability of the account, or whether the account can directly process credit and debit card charges.
246  
247 =item B<legacy_payments> string
248  
249 The status of the legacy payments capability of the account.
250  
251 =item B<transfers> string
252  
253 The status of the transfers capability of the account, or whether your platform can transfer funds to the account.
254  
255 =back
256  
257 =item B<charges_enabled> boolean
258  
259 Whether the account can create live charges.
260  
261 =item B<company> custom only hash
262  
263 Information about the company or business. This field is null unless business_type is set to company.
264  
265 This is a L<Net::API::Stripe::Connect::Account::Company> object.
266  
267 =item B<country> string
268  
269 The account’s country.
270  
271 =item B<created> custom and express timestamp
272  
273 Time at which the object was created. Measured in seconds since the Unix epoch. This is a C<DateTime> object.
274  
275 =item B<debit_negative_balances>
276  
277 This is outdated. It now points to B<settings>->B<payouts>->B<debit_negative_balances>
278  
279 =item B<decline_charge_on>
280  
281 This is outdated. It now points to B<settings>->B<card_payments>->B<decline_on>
282  
283 =item B<default_currency> string
284  
285 Three-letter ISO currency code representing the default currency for the account. This must be a currency that Stripe supports in the account’s country.
286  
287 =item B<details_submitted> boolean
288  
289 Whether account details have been submitted. Standard accounts cannot receive payouts before this is true.
290  
291 =item B<display_name>
292  
293 This is outdated. It now points to B<settings>->B<dashboard>->B<display_name>
294  
295 =item B<email> string
296  
297 The primary user’s email address.
298  
299 =item B<external_accounts> custom and express list
300  
301 External accounts (bank accounts and debit cards) currently attached to this account
302  
303 This is a L<Net::API::Stripe::Connect::Account::ExternalAccounts> object.
304  
305 =item B<individual> custom only hash
306  
307 Information about the person represented by the account. This field is null unless business_type is set to individual.
308  
309 This is a L<Net::API::Stripe::Connect::Person> object.
310  
311 =item B<legal_entity>
312  
313 This is outdated. Stripe now uses a L<Net::API::Stripe::Connect::Account::Company> object and a L<Net::API::Stripe::Connect::Person> object.
314  
315 =item B<metadata> hash
316  
317 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.
318  
319 =item B<payouts_enabled> boolean
320  
321 Whether Stripe can send payouts to this account.
322  
323 =item B<payout_schedule>
324  
325 This is outdated. It now points to B<settings>->B<payouts>->B<schedule>
326  
327 =item B<payout_statement_descriptor>
328  
329 This is outdated. It now points to B<settings>->B<payouts>->B<statement_descriptor>
330  
331 =item B<product_description>
332  
333 This is outdated. It now points to B<business_profile>->B<product_description>
334  
335 =item B<requirements> custom and express hash
336  
337 Information about the requirements for the account, including what information needs to be collected, and by when.
338  
339 This is a L<Net::API::Stripe::Connect::Account::Requirements> object.
340  
341 =item B<settings> hash
342  
343 Options for customizing how the account functions within Stripe.
344  
345 This is a L<Net::API::Stripe::Connect::Account::Settings> object.
346  
347 =item B<statement_descriptor>
348  
349 This is outdated. It now points to B<settings>->B<payments>->B<statement_descriptor>
350  
351 =item B<support_address>
352  
353 This is outdated. It now points to B<business_profile>->B<support_address>
354  
355 =item B<support_email>
356  
357 This is outdated. It now points to B<business_profile>->B<support_email>
358  
359 =item B<support_phone>
360  
361 This is outdated. It now points to B<business_profile>->B<support_phone>
362  
363 =item B<support_url>
364  
365 This is outdated. It now points to B<business_profile>->B<support_url>
366  
367 =item B<timezone>
368  
369 This is outdated. It is a C<DateTime> object.
370  
371 =item B<tos_acceptance> custom only hash
372  
373 Details on the acceptance of the Stripe Services Agreement
374  
375 This is a L<Net::API::Stripe::Connect::Account::TosAcceptance> object.
376  
377 =item B<type> string
378  
379 The Stripe account type. Can be standard, express, or custom.
380  
381 =item B<verification>
382  
383 This is outdated. It is a L<Net::API::Stripe::Connect::Account::Verification> object.
384  
385 =back
386  
387 =head1 API SAMPLE
388  
389 =head2 Response Standard
390  
391 {
392 "id": "acct_fake123456789",
393 "object": "account",
394 "business_profile": {
395 "mcc": null,
396 "name": "My Shop, Inc",
397 "product_description": "Great products shipping all over the world",
398 "support_address": {
399 "city": "Tokyo",
400 "country": "JP",
401 "line1": "1-2-3 Kudan-minami, Chiyoda-ku",
402 "line2": "",
403 "postal_code": "100-0012",
404 "state": ""
405 },
406 "support_email": "billing@example.com",
407 "support_phone": "+81312345678",
408 "support_url": "",
409 "url": "https://www.example.com"
410 },
411 "business_type": "company",
412 "capabilities": {
413 "card_payments": "active"
414 },
415 "charges_enabled": true,
416 "country": "JP",
417 "default_currency": "jpy",
418 "details_submitted": true,
419 "email": "tech@example.com",
420 "metadata": {},
421 "payouts_enabled": true,
422 "settings": {
423 "branding": {
424 "icon": "file_fake123456789",
425 "logo": null,
426 "primary_color": "#0e77ca"
427 },
428 "card_payments": {
429 "decline_on": {
430 "avs_failure": false,
431 "cvc_failure": false
432 },
433 "statement_descriptor_prefix": null
434 },
435 "dashboard": {
436 "display_name": "myshop-inc",
437 "timezone": "Asia/Tokyo"
438 },
439 "payments": {
440 "statement_descriptor": "MYSHOP, INC",
441 "statement_descriptor_kana": "マイショップインク",
442 "statement_descriptor_kanji": "マイショップインク"
443 },
444 "payouts": {
445 "debit_negative_balances": true,
446 "schedule": {
447 "delay_days": 4,
448 "interval": "weekly",
449 "weekly_anchor": "thursday"
450 },
451 "statement_descriptor": null
452 }
453 },
454 "type": "standard"
455 }
456  
457 =head2 Response Express
458  
459 {
460 "id": "acct_19eGgRCeyNCl6xYZ",
461 "object": "account",
462 "business_profile": {
463 "mcc": null,
464 "name": "MyShop, Inc",
465 "product_description": "Great products shipping all over the world",
466 "support_address": {
467 "city": "Tokyo",
468 "country": "JP",
469 "line1": "1-2-3 Kudan-minami, Chiyoda-ku",
470 "line2": "",
471 "postal_code": "100-0012",
472 "state": ""
473 },
474 "support_email": "billing@example.com",
475 "support_phone": "+81312345678",
476 "support_url": "",
477 "url": "https://www.example.com"
478 },
479 "business_type": "company",
480 "capabilities": {
481 "card_payments": "active"
482 },
483 "charges_enabled": true,
484 "country": "JP",
485 "created": 1484973659,
486 "default_currency": "jpy",
487 "details_submitted": true,
488 "email": "tech@example.com",
489 "external_accounts": {
490 "object": "list",
491 "data": [
492 {
493 "id": "ba_19eGy1CeyNCl6fY2R3ACmqG4",
494 "object": "bank_account",
495 "account": "acct_19eGgRCeyNCl6xYZ",
496 "account_holder_name": "カ)マイショップインク",
497 "account_holder_type": null,
498 "bank_name": "三井住友銀行",
499 "country": "JP",
500 "currency": "jpy",
501 "default_for_currency": true,
502 "fingerprint": "VWINqgzE0zu5x1ab",
503 "last4": "1234",
504 "metadata": {},
505 "routing_number": "0009218",
506 "status": "new"
507 }
508 ],
509 "has_more": false,
510 "url": "/v1/accounts/acct_19eGgRCeyNCl6xYZ/external_accounts"
511 },
512 "metadata": {},
513 "payouts_enabled": true,
514 "requirements": {
515 "current_deadline": null,
516 "currently_due": [],
517 "disabled_reason": null,
518 "eventually_due": [],
519 "past_due": [],
520 "pending_verification": []
521 },
522 "settings": {
523 "branding": {
524 "icon": "file_1DLf5rCeyNCl6fY2kS4e1xyz",
525 "logo": null,
526 "primary_color": "#0e77ca"
527 },
528 "card_payments": {
529 "decline_on": {
530 "avs_failure": false,
531 "cvc_failure": false
532 },
533 "statement_descriptor_prefix": null
534 },
535 "dashboard": {
536 "display_name": "myshop-inc",
537 "timezone": "Asia/Tokyo"
538 },
539 "payments": {
540 "statement_descriptor": "MYSHOP, INC",
541 "statement_descriptor_kana": "マイショップインク",
542 "statement_descriptor_kanji": "マイショップインク"
543 },
544 "payouts": {
545 "debit_negative_balances": true,
546 "schedule": {
547 "delay_days": 4,
548 "interval": "weekly",
549 "weekly_anchor": "thursday"
550 },
551 "statement_descriptor": null
552 }
553 },
554 "type": "express"
555 }
556  
557 =head2 Response Custom
558  
559 {
560 "id": "acct_19eGgRCeyNCl6xYZ",
561 "object": "account",
562 "business_profile": {
563 "mcc": null,
564 "name": "MyShop, Inc",
565 "product_description": "Great products shipping all over the world",
566 "support_address": {
567 "city": "Tokyo",
568 "country": "JP",
569 "line1": "1-2-3 Kudan-minami, Chiyoda-ku",
570 "line2": "",
571 "postal_code": "100-0012",
572 "state": ""
573 },
574 "support_email": "billing@example.com",
575 "support_phone": "+81312345678",
576 "support_url": "",
577 "url": "https://www.example.com"
578 },
579 "business_type": "company",
580 "capabilities": {
581 "card_payments": "active"
582 },
583 "charges_enabled": true,
584 "company": {
585 "address_kana": {
586 "city": "チヨダク",
587 "country": "JP",
588 "line1": "2-3",
589 "line2": "ナシ",
590 "postal_code": null,
591 "state": null,
592 "town": "クダンミナミ1"
593 },
594 "address_kanji": {
595 "city": "千代田区",
596 "country": "JP",
597 "line1": "",
598 "line2": "",
599 "postal_code": null,
600 "state": null,
601 "town": "九段南1-2-3"
602 },
603 "directors_provided": false,
604 "name": "MyShop, Inc",
605 "name_kana": "カブシキカイシャマイショップインク",
606 "name_kanji": "株式会社マイショップインク",
607 "owners_provided": true,
608 "phone": null,
609 "tax_id_provided": true,
610 "verification": {
611 "document": {
612 "back": null,
613 "details": null,
614 "details_code": null,
615 "front": null
616 }
617 }
618 },
619 "country": "JP",
620 "created": 1484973659,
621 "default_currency": "jpy",
622 "details_submitted": true,
623 "email": "tech@example.com",
624 "external_accounts": {
625 "object": "list",
626 "data": [
627 {
628 "id": "ba_19eGy1CeyNCl6fY2R3ACmqG4",
629 "object": "bank_account",
630 "account": "acct_19eGgRCeyNCl6xYZ",
631 "account_holder_name": "カ)マイショップインク",
632 "account_holder_type": null,
633 "bank_name": "三井住友銀行",
634 "country": "JP",
635 "currency": "jpy",
636 "default_for_currency": true,
637 "fingerprint": "VkINqgzE0zu5x1xw",
638 "last4": "2235",
639 "metadata": {},
640 "routing_number": "0009218",
641 "status": "new"
642 }
643 ],
644 "has_more": false,
645 "url": "/v1/accounts/acct_19eGgRCeyNCl6xYZ/external_accounts"
646 },
647 "metadata": {},
648 "payouts_enabled": true,
649 "requirements": {
650 "current_deadline": null,
651 "currently_due": [],
652 "disabled_reason": null,
653 "eventually_due": [],
654 "past_due": [],
655 "pending_verification": []
656 },
657 "settings": {
658 "branding": {
659 "icon": "file_1DLf5rCeyabl6fY2kS4e5xyz",
660 "logo": null,
661 "primary_color": "#0e77ca"
662 },
663 "card_payments": {
664 "decline_on": {
665 "avs_failure": false,
666 "cvc_failure": false
667 },
668 "statement_descriptor_prefix": null
669 },
670 "dashboard": {
671 "display_name": "myshop-inc",
672 "timezone": "Asia/Tokyo"
673 },
674 "payments": {
675 "statement_descriptor": "MYSHOP, IN",
676 "statement_descriptor_kana": "マイショップインク",
677 "statement_descriptor_kanji": "マイショップインク"
678 },
679 "payouts": {
680 "debit_negative_balances": true,
681 "schedule": {
682 "delay_days": 4,
683 "interval": "weekly",
684 "weekly_anchor": "thursday"
685 },
686 "statement_descriptor": null
687 }
688 },
689 "tos_acceptance": {
690 "date": 1484979187,
691 "ip": "114.17.230.189",
692 "user_agent": "Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/55.0.2883.87 Safari/537.36"
693 },
694 "type": "custom"
695 }
696  
697 =head1 HISTORY
698  
699 =head2 v0.1
700  
701 Initial version
702  
703 =head1 STRIPE HISTORY
704  
705 =head2 2019-02-19
706  
707 Statement descriptor behaviors for card payments created via /v1/charges have changed. See L<Stripe statement descriptor guide|https://stripe.com/docs/statement-descriptors> for details.
708  
709 =over 4
710  
711 =item * Instead of using the platform's statement descriptor, charges created with on_behalf_of or destination will now use the descriptor of the connected account.
712  
713 ~item * The full statement descriptor for a card payment may no longer be provided at charge creation. Dynamic descriptors provided at charge time will now be prefixed by the descriptor prefix set in the dashboard or via the new settings[card_payments][statement_descriptor_prefix] parameter in the Accounts API.
714  
715 =item * If an account has no statement_descriptor set, the account's business or legal name will be used as statement descriptor.
716  
717 =item * Statement descriptors may no longer contain *, ', and ".
718  
719 =back
720  
721 =head2 2019-02-19
722  
723 Many properties on the Account API object have been reworked. To see a mapping of the old argument names to the new ones, see Accounts API Argument Changes.
724  
725 =over 4
726  
727 =item * The legal_entity property on the Account API resource has been replaced with individual, company, and business_type.
728  
729 =item * The verification hash has been replaced with a requirements hash.
730  
731 =over 8
732  
733 =item * The verification[fields_needed] array has been replaced with three arrays to better represent when info is required: requirements[eventually_due], requirements[currently_due], and requirements[past_due].
734  
735 =item * verification[due_by] has been renamed to requirements[current_deadline].
736  
737 =item * The disabled_reason enum value of fields_needed has been renamed to requirements.past_due.
738  
739 =back
740  
741 =item * Properties on the Account API object that configure behavior within Stripe have been moved into the new settings hash.
742  
743 =over 8
744  
745 =item * The payout_schedule, payout_statement_descriptor and debit_negative_balances fields have been moved to settings[payouts] and renamed to schedule, statement_descriptor and debit_negative_balances.
746  
747 =item * The statement_descriptor field has been moved to settings[payments][statement_descriptor].
748  
749 =item * The decline_charge_on fields have been moved to settings[card_payments] and renamed to decline_on.
750  
751 =item * The business_logo, business_logo_large and business_primary_color fields have been moved to settings[branding] and renamed to icon, logo and primary_color. The icon field additionally requires the uploaded image file to be square.
752  
753 =item * The display_name and timezone fields have been moved to settings[dashboard].
754  
755 =back
756  
757 =item * business_name, business_url, product_description, support_address, support_email, support_phone and support_url have been moved to the business_profile subhash.
758  
759 =item * The legal_entity[verification][document] property (now located at individual[verification] and at verification in the Person API object) has been changed to a hash.
760  
761 =over 8
762  
763 =item * The front and back fields support uploading both sides of documents.
764  
765 =item * The details_code field has new error types: document_corrupt, document_failed_copy, document_failed_greyscale, document_failed_other, document_failed_test_mode, document_fraudulent, document_id_country_not_supported, document_id_type_not_supported, document_invalid, document_manipulated, document_missing_back, document_missing_front, document_not_readable, document_not_uploaded, document_photo_mismatch, and document_too_large.
766  
767 =item * The keys property on Account creation has been removed. Platforms should now authenticate as their connected accounts with their own key via the Stripe-Account header.
768  
769 =item * Starting with the 2019-02-19 API, the requested_capabilities property is now required at creation time for accounts in the U.S. See the Capabilities Overview for more information.
770  
771 =back
772  
773 =back
774  
775 =head2 2017-05-25
776  
777 Replaces the managed Boolean property on Account objects with type, whose possible values are: standard, express, and custom. A managed value is required when creating accounts.
778  
779 =head1 AUTHOR
780  
781 Jacques Deguest E<lt>F<jack@deguest.jp>E<gt>
782  
783 =head1 SEE ALSO
784  
785 Stripe API documentation:
786  
787 L<https://stripe.com/docs/api>
788  
789 =head1 COPYRIGHT & LICENSE
790  
791 Copyright (c) 2019-2020 DEGUEST Pte. Ltd.
792  
793 You can use, copy, modify and redistribute this package and associated
794 files under the same terms as Perl itself.
795  
796 =cut
« Stripe/Charge.pm ↑ Summary Stripe/Connect/ExternalAccount/Card.pm »