File Coverage

lib/Net/API/Stripe/Payment/Installment.pm
Criterion Covered Total %
statement 19 22 86.3
branch n/a
condition n/a
subroutine 7 10 70.0
pod 3 3 100.0
total 29 35 82.8


line stmt bran cond sub pod time code
1             ##----------------------------------------------------------------------------
2             ## Stripe API - ~/lib/Net/API/Stripe/Payment/Installment.pm
3             ## Version v0.101.0
4             ## Copyright(c) 2020 DEGUEST Pte. Ltd.
5             ## Author: Jacques Deguest <jack@deguest.jp>
6             ## Created 2019/11/02
7             ## Modified 2020/11/30
8             ## All rights reserved
9             ##
10             ## This program is free software; you can redistribute it and/or modify it
11             ## under the same terms as Perl itself.
12             ##----------------------------------------------------------------------------
13             BEGIN
14             {
15             use strict;
16 1     1   1059 use warnings;
  1         2  
  1         33  
17 1     1   6 use parent qw( Net::API::Stripe::Generic );
  1         2  
  1         30  
18 1     1   5 use vars qw( $VERSION );
  1         1  
  1         6  
19 1     1   69 our( $VERSION ) = 'v0.101.0';
  1         2  
  1         47  
20 1     1   34 };
21              
22             use strict;
23 1     1   6 use warnings;
  1         3  
  1         22  
24 1     1   5  
  1         2  
  1         142  
25              
26 0     0 1    
27              
28 0     0 1   1;
29              
30 0     0 1    
31             =encoding utf8
32              
33             =head1 NAME
34              
35             Net::API::Stripe::Payment::Installment - A Stripe Instalment Payment Object
36              
37             =head1 SYNOPSIS
38              
39             my $inst = $stripe->card->installments({
40             plan => $plan_object,
41             });
42              
43             =head1 VERSION
44              
45             v0.101.0
46              
47             =head1 DESCRIPTION
48              
49             Installment details for this payment (Mexico only).
50              
51             For more information, see the installments integration guide (L<https://stripe.com/docs/payments/installments>).
52              
53             This is instantiated by method B<installments> in module L<Net::API::Stripe::Connect::ExternalAccount::Card>
54              
55             =head1 CONSTRUCTOR
56              
57             =head2 new
58              
59             Creates a new L<Net::API::Stripe::Payment::Installment> object.
60             It may also take an hash like arguments, that also are method of the same name.
61              
62             =head1 METHODS
63              
64             =head2 available_plans array of objects
65              
66             Installment plans that may be selected for this PaymentIntent.
67              
68             This is a L<Net::API::Stripe::Billing::Plan> object.
69              
70             =head2 enabled boolean
71              
72             Whether Installments are enabled for this PaymentIntent.
73              
74             =head2 plan hash
75              
76             This is a C<Net::API::Stripe::Billing::Plan;> object who only 3 following properties are used:
77              
78             =over 4
79              
80             =item I<count> integer
81              
82             For fixed_count installment plans, this is the number of installment payments your customer will make to their credit card.
83              
84             =item I<interval> string
85              
86             For fixed_count installment plans, this is the interval between installment payments your customer will make to their credit card.
87              
88             =item I<type> string
89              
90             Type of installment plan, one of fixed_count.
91              
92             =back
93              
94             =head1 HISTORY
95              
96             =head2 v0.1
97              
98             Initial version
99              
100             =head1 AUTHOR
101              
102             Jacques Deguest E<lt>F<jack@deguest.jp>E<gt>
103              
104             =head1 SEE ALSO
105              
106             Stripe API documentation:
107              
108             L<https://stripe.com/docs/payments/installments>
109              
110             L<Payment intent, instalment property|https://stripe.com/docs/api/payment_intents/object#payment_intent_object-payment_method_options-card-installments>
111              
112             =head1 COPYRIGHT & LICENSE
113              
114             Copyright (c) 2019-2020 DEGUEST Pte. Ltd.
115              
116             You can use, copy, modify and redistribute this package and associated
117             files under the same terms as Perl itself.
118              
119             =cut