File Coverage

blib/lib/WWW/TypePad/ExternalFeedSubscriptions.pm
Criterion Covered Total %
statement 15 59 25.4
branch n/a
condition n/a
subroutine 5 15 33.3
pod 8 10 80.0
total 28 84 33.3


line stmt bran cond sub pod time code
1             package WWW::TypePad::ExternalFeedSubscriptions;
2              
3 1     1   8 use strict;
  1         3  
  1         46  
4 1     1   7 use warnings;
  1         2  
  1         71  
5              
6             # Install an accessor into WWW::TypePad to access an instance of this class
7             # bound to the WWW::TypePad instance.
8 0     0 0   sub WWW::TypePad::external_feed_subscriptions { __PACKAGE__->new( base => $_[0] ) }
9              
10             ### BEGIN auto-generated
11             ### This is an automatically generated code, do not edit!
12             ### Scroll down to look for END to add additional methods
13              
14             =pod
15              
16             =head1 NAME
17              
18             WWW::TypePad::ExternalFeedSubscriptions - ExternalFeedSubscriptions API methods
19              
20             =head1 METHODS
21              
22             =cut
23              
24 1     1   6 use strict;
  1         2  
  1         286  
25 1     1   8 use Any::Moose;
  1         2  
  1         20  
26             extends 'WWW::TypePad::Noun';
27              
28 1     1   703 use Carp ();
  1         4  
  1         1642  
29              
30              
31             =pod
32              
33             =over 4
34              
35              
36             =item delete
37              
38             my $res = $tp->external_feed_subscriptions->delete($id);
39              
40             Remove the selected subscription.
41              
42             Returns ExternalFeedSubscription which contains following properties.
43              
44             =over 8
45              
46             =item urlId
47              
48             (string) The canonical identifier that can be used to identify this object in URLs. This can be used to recognise where the same user is returned in response to different requests, and as a mapping key for an application's local data store.
49              
50             =item callbackUrl
51              
52             (string) The URL to which to send notifications of new items in this subscription's feeds.
53              
54             =item callbackStatus
55              
56             (string) The HTTP status code that was returned by the last call to the subscription's callback URL.
57              
58             =item filterRules
59              
60             (arrayEstringE) A list of rules for filtering notifications to this subscription. Each rule is a full-text search query string, like those used with the NE/assetsE endpoint. An item will be delivered to the MEcallbackUrlE if it matches any one of these query strings.
61              
62             =item postAsUserId
63              
64             (arrayEstringE) For a Group-owned subscription, the urlId of the User who will own the items posted into the group by the subscription.
65              
66              
67             =back
68              
69             =cut
70              
71             sub delete {
72 0     0 1   my $api = shift;
73 0           my @args;
74 0           push @args, shift; # id
75 0           my $uri = sprintf '/external-feed-subscriptions/%s.json', @args;
76 0           $api->base->call("DELETE", $uri, @_);
77             }
78              
79              
80             =pod
81              
82              
83              
84             =item get
85              
86             my $res = $tp->external_feed_subscriptions->get($id);
87              
88             Get basic information about the selected subscription.
89              
90             Returns ExternalFeedSubscription which contains following properties.
91              
92             =over 8
93              
94             =item urlId
95              
96             (string) The canonical identifier that can be used to identify this object in URLs. This can be used to recognise where the same user is returned in response to different requests, and as a mapping key for an application's local data store.
97              
98             =item callbackUrl
99              
100             (string) The URL to which to send notifications of new items in this subscription's feeds.
101              
102             =item callbackStatus
103              
104             (string) The HTTP status code that was returned by the last call to the subscription's callback URL.
105              
106             =item filterRules
107              
108             (arrayEstringE) A list of rules for filtering notifications to this subscription. Each rule is a full-text search query string, like those used with the NE/assetsE endpoint. An item will be delivered to the MEcallbackUrlE if it matches any one of these query strings.
109              
110             =item postAsUserId
111              
112             (arrayEstringE) For a Group-owned subscription, the urlId of the User who will own the items posted into the group by the subscription.
113              
114              
115             =back
116              
117             =cut
118              
119             sub get {
120 0     0 1   my $api = shift;
121 0           my @args;
122 0           push @args, shift; # id
123 0           my $uri = sprintf '/external-feed-subscriptions/%s.json', @args;
124 0           $api->base->call("GET", $uri, @_);
125             }
126              
127              
128             =pod
129              
130              
131              
132             =item add_feeds
133              
134             my $res = $tp->external_feed_subscriptions->add_feeds($id);
135              
136             Add one or more feed identifiers to the subscription.
137              
138             Returns hash reference which contains following properties.
139              
140             =over 8
141              
142              
143             =back
144              
145             =cut
146              
147             sub add_feeds {
148 0     0 1   my $api = shift;
149 0           my @args;
150 0           push @args, shift; # id
151 0           my $uri = sprintf '/external-feed-subscriptions/%s/add-feeds.json', @args;
152 0           $api->base->call("POST", $uri, @_);
153             }
154              
155              
156             =pod
157              
158              
159              
160             =item get_feeds
161              
162             my $res = $tp->external_feed_subscriptions->get_feeds($id);
163              
164             Get a list of strings containing the identifiers of the feeds to which this subscription is subscribed.
165              
166             Returns ListEstringE which contains following properties.
167              
168             =over 8
169              
170             =item totalResults
171              
172             (integer) The total number of items in the whole list of which this list object is a paginated view.
173              
174             =item entries
175              
176             (arrayEstringE) The items within the selected slice of the list.
177              
178              
179             =back
180              
181             =cut
182              
183             sub get_feeds {
184 0     0 1   my $api = shift;
185 0           my @args;
186 0           push @args, shift; # id
187 0           my $uri = sprintf '/external-feed-subscriptions/%s/feeds.json', @args;
188 0           $api->base->call("GET", $uri, @_);
189             }
190              
191              
192             sub feeds {
193 0     0 0   my $self = shift;
194 0           Carp::carp("'feeds' is deprecated. Use 'get_feeds' instead.");
195 0           $self->get_feeds(@_);
196             }
197              
198             =pod
199              
200              
201              
202             =item remove_feeds
203              
204             my $res = $tp->external_feed_subscriptions->remove_feeds($id);
205              
206             Remove one or more feed identifiers from the subscription.
207              
208             Returns hash reference which contains following properties.
209              
210             =over 8
211              
212              
213             =back
214              
215             =cut
216              
217             sub remove_feeds {
218 0     0 1   my $api = shift;
219 0           my @args;
220 0           push @args, shift; # id
221 0           my $uri = sprintf '/external-feed-subscriptions/%s/remove-feeds.json', @args;
222 0           $api->base->call("POST", $uri, @_);
223             }
224              
225              
226             =pod
227              
228              
229              
230             =item update_filters
231              
232             my $res = $tp->external_feed_subscriptions->update_filters($id);
233              
234             Change the filtering rules for the subscription.
235              
236             Returns hash reference which contains following properties.
237              
238             =over 8
239              
240              
241             =back
242              
243             =cut
244              
245             sub update_filters {
246 0     0 1   my $api = shift;
247 0           my @args;
248 0           push @args, shift; # id
249 0           my $uri = sprintf '/external-feed-subscriptions/%s/update-filters.json', @args;
250 0           $api->base->call("POST", $uri, @_);
251             }
252              
253              
254             =pod
255              
256              
257              
258             =item update_notification_settings
259              
260             my $res = $tp->external_feed_subscriptions->update_notification_settings($id);
261              
262             Change the callback URL and/or secret for the subscription.
263              
264             Returns hash reference which contains following properties.
265              
266             =over 8
267              
268              
269             =back
270              
271             =cut
272              
273             sub update_notification_settings {
274 0     0 1   my $api = shift;
275 0           my @args;
276 0           push @args, shift; # id
277 0           my $uri = sprintf '/external-feed-subscriptions/%s/update-notification-settings.json', @args;
278 0           $api->base->call("POST", $uri, @_);
279             }
280              
281              
282             =pod
283              
284              
285              
286             =item update_user
287              
288             my $res = $tp->external_feed_subscriptions->update_user($id);
289              
290             Change the "post as" user for a subscription owned by a group.
291              
292             Returns hash reference which contains following properties.
293              
294             =over 8
295              
296              
297             =back
298              
299             =cut
300              
301             sub update_user {
302 0     0 1   my $api = shift;
303 0           my @args;
304 0           push @args, shift; # id
305 0           my $uri = sprintf '/external-feed-subscriptions/%s/update-user.json', @args;
306 0           $api->base->call("POST", $uri, @_);
307             }
308              
309              
310             =pod
311              
312             =back
313              
314             =cut
315              
316             ### END auto-generated
317              
318             1;