line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package WebService::Mattermost::V4::API::Resource::Webhook; |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
|
4
|
|
|
|
|
|
|
|
5
|
7
|
|
|
7
|
|
51
|
use Moo; |
|
7
|
|
|
|
|
16
|
|
|
7
|
|
|
|
|
43
|
|
6
|
7
|
|
|
7
|
|
2604
|
use Types::Standard 'InstanceOf'; |
|
7
|
|
|
|
|
25
|
|
|
7
|
|
|
|
|
50
|
|
7
|
|
|
|
|
|
|
|
8
|
7
|
|
|
7
|
|
3455
|
use WebService::Mattermost::Helper::Alias 'v4'; |
|
7
|
|
|
|
|
17
|
|
|
7
|
|
|
|
|
413
|
|
9
|
7
|
|
|
7
|
|
3173
|
use WebService::Mattermost::V4::API::Resource::Webhook::Incoming; |
|
7
|
|
|
|
|
19
|
|
|
7
|
|
|
|
|
193
|
|
10
|
7
|
|
|
7
|
|
3142
|
use WebService::Mattermost::V4::API::Resource::Webhook::Outgoing; |
|
7
|
|
|
|
|
22
|
|
|
7
|
|
|
|
|
851
|
|
11
|
|
|
|
|
|
|
|
12
|
|
|
|
|
|
|
extends 'WebService::Mattermost::V4::API::Resource'; |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
|
15
|
|
|
|
|
|
|
|
16
|
|
|
|
|
|
|
has incoming => (is => 'ro', isa => InstanceOf[v4 'Webhook::Incoming'], lazy => 1, builder => 1); |
17
|
|
|
|
|
|
|
has outgoing => (is => 'ro', isa => InstanceOf[v4 'Webhook::Incoming'], lazy => 1, builder => 1); |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
|
21
|
|
|
|
|
|
|
sub _build_incoming { |
22
|
0
|
|
|
0
|
|
|
my $self = shift; |
23
|
|
|
|
|
|
|
|
24
|
0
|
|
|
|
|
|
return $self->_new_related_resource('webhooks', 'Webhook::Incoming'); |
25
|
|
|
|
|
|
|
} |
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
sub _build_outgoing { |
28
|
0
|
|
|
0
|
|
|
my $self = shift; |
29
|
|
|
|
|
|
|
|
30
|
0
|
|
|
|
|
|
return $self->_new_related_resource('webhooks', 'Webhook::Outgoing'); |
31
|
|
|
|
|
|
|
} |
32
|
|
|
|
|
|
|
|
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
1; |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
__END__ |
38
|
|
|
|
|
|
|
|
39
|
|
|
|
|
|
|
=pod |
40
|
|
|
|
|
|
|
|
41
|
|
|
|
|
|
|
=encoding UTF-8 |
42
|
|
|
|
|
|
|
|
43
|
|
|
|
|
|
|
=head1 NAME |
44
|
|
|
|
|
|
|
|
45
|
|
|
|
|
|
|
WebService::Mattermost::V4::API::Resource::Webhook - Wrapped API methods for the webhook API endpoints. |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
=head1 VERSION |
48
|
|
|
|
|
|
|
|
49
|
|
|
|
|
|
|
version 0.26 |
50
|
|
|
|
|
|
|
|
51
|
|
|
|
|
|
|
=head1 DESCRIPTION |
52
|
|
|
|
|
|
|
|
53
|
|
|
|
|
|
|
=head2 USAGE |
54
|
|
|
|
|
|
|
|
55
|
|
|
|
|
|
|
use WebService::Mattermost; |
56
|
|
|
|
|
|
|
|
57
|
|
|
|
|
|
|
my $mm = WebService::Mattermost->new({ |
58
|
|
|
|
|
|
|
authenticate => 1, |
59
|
|
|
|
|
|
|
username => 'me@somewhere.com', |
60
|
|
|
|
|
|
|
password => 'hunter2', |
61
|
|
|
|
|
|
|
base_url => 'https://my.mattermost.server.com/api/v4/', |
62
|
|
|
|
|
|
|
}); |
63
|
|
|
|
|
|
|
|
64
|
|
|
|
|
|
|
my $resource = $mm->api->webhooks; |
65
|
|
|
|
|
|
|
|
66
|
|
|
|
|
|
|
=head2 ATTRIBUTES |
67
|
|
|
|
|
|
|
|
68
|
|
|
|
|
|
|
=over 4 |
69
|
|
|
|
|
|
|
|
70
|
|
|
|
|
|
|
=item C<incoming> |
71
|
|
|
|
|
|
|
|
72
|
|
|
|
|
|
|
Contains methods for incoming webhooks. See |
73
|
|
|
|
|
|
|
L<WebService::Mattermost::V4::API::Resource::Webhook::Incoming>. |
74
|
|
|
|
|
|
|
|
75
|
|
|
|
|
|
|
my $incoming = $resource->incoming; |
76
|
|
|
|
|
|
|
|
77
|
|
|
|
|
|
|
=item C<outgoing> |
78
|
|
|
|
|
|
|
|
79
|
|
|
|
|
|
|
Contains methods for outgoing webhooks. See |
80
|
|
|
|
|
|
|
L<WebService::Mattermost::V4::API::Resource::Webhook::Outgoing>. |
81
|
|
|
|
|
|
|
|
82
|
|
|
|
|
|
|
my $outgoing = $resource->outgoing; |
83
|
|
|
|
|
|
|
|
84
|
|
|
|
|
|
|
=back |
85
|
|
|
|
|
|
|
|
86
|
|
|
|
|
|
|
=head1 AUTHOR |
87
|
|
|
|
|
|
|
|
88
|
|
|
|
|
|
|
Mike Jones <mike@netsplit.org.uk> |
89
|
|
|
|
|
|
|
|
90
|
|
|
|
|
|
|
=head1 COPYRIGHT AND LICENSE |
91
|
|
|
|
|
|
|
|
92
|
|
|
|
|
|
|
This software is Copyright (c) 2020 by Mike Jones. |
93
|
|
|
|
|
|
|
|
94
|
|
|
|
|
|
|
This is free software, licensed under: |
95
|
|
|
|
|
|
|
|
96
|
|
|
|
|
|
|
The MIT (X11) License |
97
|
|
|
|
|
|
|
|
98
|
|
|
|
|
|
|
=cut |
99
|
|
|
|
|
|
|
|