line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Regru::API::Hosting; |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
# ABSTRACT: REG.API v2 hosting management functions |
4
|
|
|
|
|
|
|
|
5
|
1
|
|
|
1
|
|
617
|
use strict; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
31
|
|
6
|
1
|
|
|
1
|
|
5
|
use warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
24
|
|
7
|
1
|
|
|
1
|
|
7
|
use Moo; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
7
|
|
8
|
1
|
|
|
1
|
|
2894
|
use namespace::autoclean; |
|
1
|
|
|
|
|
4
|
|
|
1
|
|
|
|
|
11
|
|
9
|
|
|
|
|
|
|
|
10
|
|
|
|
|
|
|
our $VERSION = '0.051'; # VERSION |
11
|
|
|
|
|
|
|
our $AUTHORITY = 'cpan:CHIM'; # AUTHORITY |
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
with 'Regru::API::Role::Client'; |
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
has '+namespace' => ( |
16
|
|
|
|
|
|
|
default => sub { 'hosting' }, |
17
|
|
|
|
|
|
|
); |
18
|
|
|
|
|
|
|
|
19
|
1
|
|
|
1
|
|
5
|
sub available_methods {[qw( |
20
|
|
|
|
|
|
|
nop |
21
|
|
|
|
|
|
|
get_jelastic_refill_url |
22
|
|
|
|
|
|
|
set_jelastic_refill_url |
23
|
|
|
|
|
|
|
get_parallelswpb_constructor_url |
24
|
|
|
|
|
|
|
)]} |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
__PACKAGE__->namespace_methods; |
27
|
|
|
|
|
|
|
__PACKAGE__->meta->make_immutable; |
28
|
|
|
|
|
|
|
|
29
|
|
|
|
|
|
|
1; # End of Regru::API::Hosting |
30
|
|
|
|
|
|
|
|
31
|
|
|
|
|
|
|
__END__ |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
=pod |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
=encoding UTF-8 |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
=head1 NAME |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
Regru::API::Hosting - REG.API v2 hosting management functions |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
=head1 VERSION |
42
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
version 0.051 |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
=head1 DESCRIPTION |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
REG.API hosting management functions. Most of their available only for C<partners>. |
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
=head1 ATTRIBUTES |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
=head2 namespace |
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
Always returns the name of category: C<hosting>. For internal uses only. |
54
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
=head1 REG.API METHODS |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
=head2 nop |
58
|
|
|
|
|
|
|
|
59
|
|
|
|
|
|
|
For testing purposes. Scope: B<everyone>. Typical usage: |
60
|
|
|
|
|
|
|
|
61
|
|
|
|
|
|
|
$resp = $client->hosting->nop; |
62
|
|
|
|
|
|
|
|
63
|
|
|
|
|
|
|
Returns success response. |
64
|
|
|
|
|
|
|
|
65
|
|
|
|
|
|
|
More info at L<Hosting management: nop|https://www.reg.com/support/help/api2#hosting_nop>. |
66
|
|
|
|
|
|
|
|
67
|
|
|
|
|
|
|
=head2 set_jelastic_refill_url |
68
|
|
|
|
|
|
|
|
69
|
|
|
|
|
|
|
Update Jelastic refill URL for current reseller. That url is used when client hits "Refill" button at his Jelastic account page. Keywords C<< <service_id> >> and C<< <email> >> in url will be replaced |
70
|
|
|
|
|
|
|
with service identifier and user email, which was used for Jelastic account registration. |
71
|
|
|
|
|
|
|
Scope B<partners>. |
72
|
|
|
|
|
|
|
|
73
|
|
|
|
|
|
|
Typical usage: |
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
$resp = $client->hosting->set_jelastic_refill_url( |
76
|
|
|
|
|
|
|
url => 'http://mysite.com?service_id=<service_id>&email=<email>' |
77
|
|
|
|
|
|
|
); |
78
|
|
|
|
|
|
|
|
79
|
|
|
|
|
|
|
Returns success response if URL was set. |
80
|
|
|
|
|
|
|
More info at L<Hosting management: set_jelastic_refill_url|https://www.reg.com/support/help/api2#hosting_set_jelastic_refill_url>. |
81
|
|
|
|
|
|
|
|
82
|
|
|
|
|
|
|
=head2 get_jelastic_refill_url |
83
|
|
|
|
|
|
|
|
84
|
|
|
|
|
|
|
Fetch Jelastic refill URL for current reseller. Scope: B<partners>. Typical usage: |
85
|
|
|
|
|
|
|
|
86
|
|
|
|
|
|
|
$resp = $client->hosting->get_jelastic_refill_url; |
87
|
|
|
|
|
|
|
|
88
|
|
|
|
|
|
|
Answer will contain the C<url> field, with reseller refill url. |
89
|
|
|
|
|
|
|
|
90
|
|
|
|
|
|
|
More info at L<Hosting management: get_jelastic_refill_url|https://www.reg.com/support/help/api2#hosting_get_jelastic_refill_url>. |
91
|
|
|
|
|
|
|
|
92
|
|
|
|
|
|
|
=head2 get_parallelswpb_constructor_url |
93
|
|
|
|
|
|
|
|
94
|
|
|
|
|
|
|
Retrieves an URL for ParallelsWPB constructor. Scope: B<clients>. Typical usage: |
95
|
|
|
|
|
|
|
|
96
|
|
|
|
|
|
|
$resp = $client->hosting->get_parallelswpb_constructor_url( |
97
|
|
|
|
|
|
|
service_id => 2312677, |
98
|
|
|
|
|
|
|
); |
99
|
|
|
|
|
|
|
|
100
|
|
|
|
|
|
|
Answer will contain the C<url> field, with URL for ParallelsWPB constructor. |
101
|
|
|
|
|
|
|
|
102
|
|
|
|
|
|
|
More info at L<Hosting management: get_parallelswpb_constructor_url|https://www.reg.com/support/help/api2#hosting_get_parallelswpb_constructor_url>. |
103
|
|
|
|
|
|
|
|
104
|
|
|
|
|
|
|
=head1 SEE ALSO |
105
|
|
|
|
|
|
|
|
106
|
|
|
|
|
|
|
L<Regru::API> |
107
|
|
|
|
|
|
|
|
108
|
|
|
|
|
|
|
L<Regru::API::Role::Client> |
109
|
|
|
|
|
|
|
|
110
|
|
|
|
|
|
|
L<REG.API Hosting management|https://www.reg.com/support/help/api2#hosting_functions> |
111
|
|
|
|
|
|
|
|
112
|
|
|
|
|
|
|
L<REG.API Common error codes|https://www.reg.com/support/help/api2#common_errors> |
113
|
|
|
|
|
|
|
|
114
|
|
|
|
|
|
|
=head1 BUGS |
115
|
|
|
|
|
|
|
|
116
|
|
|
|
|
|
|
Please report any bugs or feature requests on the bugtracker website |
117
|
|
|
|
|
|
|
L<https://github.com/regru/regru-api-perl/issues> |
118
|
|
|
|
|
|
|
|
119
|
|
|
|
|
|
|
When submitting a bug or request, please include a test-file or a |
120
|
|
|
|
|
|
|
patch to an existing test-file that illustrates the bug or desired |
121
|
|
|
|
|
|
|
feature. |
122
|
|
|
|
|
|
|
|
123
|
|
|
|
|
|
|
=head1 AUTHORS |
124
|
|
|
|
|
|
|
|
125
|
|
|
|
|
|
|
=over 4 |
126
|
|
|
|
|
|
|
|
127
|
|
|
|
|
|
|
=item * |
128
|
|
|
|
|
|
|
|
129
|
|
|
|
|
|
|
Polina Shubina <shubina@reg.ru> |
130
|
|
|
|
|
|
|
|
131
|
|
|
|
|
|
|
=item * |
132
|
|
|
|
|
|
|
|
133
|
|
|
|
|
|
|
Anton Gerasimov <a.gerasimov@reg.ru> |
134
|
|
|
|
|
|
|
|
135
|
|
|
|
|
|
|
=back |
136
|
|
|
|
|
|
|
|
137
|
|
|
|
|
|
|
=head1 COPYRIGHT AND LICENSE |
138
|
|
|
|
|
|
|
|
139
|
|
|
|
|
|
|
This software is copyright (c) 2013 by REG.RU LLC. |
140
|
|
|
|
|
|
|
|
141
|
|
|
|
|
|
|
This is free software; you can redistribute it and/or modify it under |
142
|
|
|
|
|
|
|
the same terms as the Perl 5 programming language system itself. |
143
|
|
|
|
|
|
|
|
144
|
|
|
|
|
|
|
=cut |