line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
##---------------------------------------------------------------------------- |
2
|
|
|
|
|
|
|
## Stripe API - ~/lib/Net/API/Stripe/Customer/TaxIds.pm |
3
|
|
|
|
|
|
|
## Version v0.100.0 |
4
|
|
|
|
|
|
|
## Copyright(c) 2019 DEGUEST Pte. Ltd. |
5
|
|
|
|
|
|
|
## Author: Jacques Deguest <jack@deguest.jp> |
6
|
|
|
|
|
|
|
## Created 2019/11/02 |
7
|
|
|
|
|
|
|
## Modified 2020/05/15 |
8
|
|
|
|
|
|
|
## |
9
|
|
|
|
|
|
|
##---------------------------------------------------------------------------- |
10
|
|
|
|
|
|
|
BEGIN |
11
|
|
|
|
|
|
|
{ |
12
|
|
|
|
|
|
|
use strict; |
13
|
1
|
|
|
1
|
|
981
|
use warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
30
|
|
14
|
1
|
|
|
1
|
|
4
|
use parent qw( Net::API::Stripe::List ); |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
43
|
|
15
|
1
|
|
|
1
|
|
6
|
use vars qw( $VERSION ); |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
5
|
|
16
|
1
|
|
|
1
|
|
66
|
our( $VERSION ) = 'v0.100.0'; |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
46
|
|
17
|
1
|
|
|
1
|
|
18
|
}; |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
use strict; |
20
|
1
|
|
|
1
|
|
5
|
use warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
19
|
|
21
|
1
|
|
|
1
|
|
4
|
|
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
37
|
|
22
|
|
|
|
|
|
|
# Inherite |
23
|
|
|
|
|
|
|
# sub object { return( shift->_set_get_scalar( 'object', @_ ) ); } |
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
## An array of Net::API::Stripe::Billing::Subscription |
26
|
|
|
|
|
|
|
## sub data { return( shift->_set_get_object_array( 'data', 'Net::API::Stripe::Customer::TaxId', @_ ) ); } |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
# Inherite |
29
|
|
|
|
|
|
|
# sub has_more { return( shift->_set_get_scalar( 'has_more', @_ ) ); } |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
# Inherite |
32
|
|
|
|
|
|
|
# sub total_count { return( shift->_set_get_scalar( 'total_count', @_ ) ); } |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
# Inherite |
35
|
|
|
|
|
|
|
# sub url { return( shift->_set_get_uri( 'url', @_ ) ); } |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
1; |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
|
40
|
|
|
|
|
|
|
=encoding utf8 |
41
|
|
|
|
|
|
|
|
42
|
|
|
|
|
|
|
=head1 NAME |
43
|
|
|
|
|
|
|
|
44
|
|
|
|
|
|
|
Net::API::Stripe::Customer::TaxIds - A Customer Tax IDs List Object |
45
|
|
|
|
|
|
|
|
46
|
|
|
|
|
|
|
=head1 SYNOPSIS |
47
|
|
|
|
|
|
|
|
48
|
|
|
|
|
|
|
my $stripe = Net::API::Stripe->new( conf_file => 'settings.json' ) || die( Net::API::Stripe->error ); |
49
|
|
|
|
|
|
|
my $list = $stripe->tax_id( 'list' ) || die( $stripe->error ); |
50
|
|
|
|
|
|
|
printf( "%d total tax id(s) found\n", $list->count ); |
51
|
|
|
|
|
|
|
while( my $tax_id = $list->next ) |
52
|
|
|
|
|
|
|
{ |
53
|
|
|
|
|
|
|
printf( "Tax ID %s with customer id %s has a country %s\n", $tax_id->id, $tax_id->customer->id, $tax_id->country ); |
54
|
|
|
|
|
|
|
} |
55
|
|
|
|
|
|
|
|
56
|
|
|
|
|
|
|
=head1 VERSION |
57
|
|
|
|
|
|
|
|
58
|
|
|
|
|
|
|
v0.100.0 |
59
|
|
|
|
|
|
|
|
60
|
|
|
|
|
|
|
=head1 DESCRIPTION |
61
|
|
|
|
|
|
|
|
62
|
|
|
|
|
|
|
This module inherits completely from L<Net::API::Stripe::List> and may be removed in the future. |
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
You can add one or multiple tax IDs to a customer. A customer's tax IDs are displayed on invoices and credit notes issued for the customer. |
65
|
|
|
|
|
|
|
|
66
|
|
|
|
|
|
|
=head1 API SAMPLE |
67
|
|
|
|
|
|
|
|
68
|
|
|
|
|
|
|
{ |
69
|
|
|
|
|
|
|
"id": "cus_fake123456789", |
70
|
|
|
|
|
|
|
"object": "customer", |
71
|
|
|
|
|
|
|
"account_balance": 0, |
72
|
|
|
|
|
|
|
"address": null, |
73
|
|
|
|
|
|
|
"balance": 0, |
74
|
|
|
|
|
|
|
"created": 1571176460, |
75
|
|
|
|
|
|
|
"currency": "jpy", |
76
|
|
|
|
|
|
|
"default_source": null, |
77
|
|
|
|
|
|
|
"delinquent": false, |
78
|
|
|
|
|
|
|
"description": null, |
79
|
|
|
|
|
|
|
"discount": null, |
80
|
|
|
|
|
|
|
"email": null, |
81
|
|
|
|
|
|
|
"invoice_prefix": "0822CFA", |
82
|
|
|
|
|
|
|
"invoice_settings": { |
83
|
|
|
|
|
|
|
"custom_fields": null, |
84
|
|
|
|
|
|
|
"default_payment_method": null, |
85
|
|
|
|
|
|
|
"footer": null |
86
|
|
|
|
|
|
|
}, |
87
|
|
|
|
|
|
|
"livemode": false, |
88
|
|
|
|
|
|
|
"metadata": {}, |
89
|
|
|
|
|
|
|
"name": null, |
90
|
|
|
|
|
|
|
"phone": null, |
91
|
|
|
|
|
|
|
"preferred_locales": [], |
92
|
|
|
|
|
|
|
"shipping": null, |
93
|
|
|
|
|
|
|
"sources": { |
94
|
|
|
|
|
|
|
"object": "list", |
95
|
|
|
|
|
|
|
"data": [], |
96
|
|
|
|
|
|
|
"has_more": false, |
97
|
|
|
|
|
|
|
"url": "/v1/customers/cus_fake123456789/sources" |
98
|
|
|
|
|
|
|
}, |
99
|
|
|
|
|
|
|
"subscriptions": { |
100
|
|
|
|
|
|
|
"object": "list", |
101
|
|
|
|
|
|
|
"data": [], |
102
|
|
|
|
|
|
|
"has_more": false, |
103
|
|
|
|
|
|
|
"url": "/v1/customers/cus_fake123456789/subscriptions" |
104
|
|
|
|
|
|
|
}, |
105
|
|
|
|
|
|
|
"tax_exempt": "none", |
106
|
|
|
|
|
|
|
"tax_ids": { |
107
|
|
|
|
|
|
|
"object": "list", |
108
|
|
|
|
|
|
|
"data": [], |
109
|
|
|
|
|
|
|
"has_more": false, |
110
|
|
|
|
|
|
|
"url": "/v1/customers/cus_fake123456789/tax_ids" |
111
|
|
|
|
|
|
|
}, |
112
|
|
|
|
|
|
|
"tax_info": null, |
113
|
|
|
|
|
|
|
"tax_info_verification": null |
114
|
|
|
|
|
|
|
} |
115
|
|
|
|
|
|
|
|
116
|
|
|
|
|
|
|
=head1 HISTORY |
117
|
|
|
|
|
|
|
|
118
|
|
|
|
|
|
|
=head2 v0.1 |
119
|
|
|
|
|
|
|
|
120
|
|
|
|
|
|
|
Initial version |
121
|
|
|
|
|
|
|
|
122
|
|
|
|
|
|
|
=head1 AUTHOR |
123
|
|
|
|
|
|
|
|
124
|
|
|
|
|
|
|
Jacques Deguest E<lt>F<jack@deguest.jp>E<gt> |
125
|
|
|
|
|
|
|
|
126
|
|
|
|
|
|
|
=head1 SEE ALSO |
127
|
|
|
|
|
|
|
|
128
|
|
|
|
|
|
|
Stripe API documentation: |
129
|
|
|
|
|
|
|
|
130
|
|
|
|
|
|
|
L<https://stripe.com/docs/api/customers>, L<https://stripe.com/docs/billing/taxes/tax-ids> |
131
|
|
|
|
|
|
|
|
132
|
|
|
|
|
|
|
=head1 COPYRIGHT & LICENSE |
133
|
|
|
|
|
|
|
|
134
|
|
|
|
|
|
|
Copyright (c) 2019-2020 DEGUEST Pte. Ltd. |
135
|
|
|
|
|
|
|
|
136
|
|
|
|
|
|
|
You can use, copy, modify and redistribute this package and associated |
137
|
|
|
|
|
|
|
files under the same terms as Perl itself. |
138
|
|
|
|
|
|
|
|
139
|
|
|
|
|
|
|
=cut |