source: vendor/google/apiclient-services/src/Blogger.php

Last change on this file was e3d4e0a, checked in by Vlado 222039 <vlado.popovski@…>, 7 days ago

Upload project files

  • Property mode set to 100644
File size: 29.8 KB
Line 
1<?php
2/*
3 * Copyright 2014 Google Inc.
4 *
5 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
6 * use this file except in compliance with the License. You may obtain a copy of
7 * the License at
8 *
9 * http://www.apache.org/licenses/LICENSE-2.0
10 *
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
13 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
14 * License for the specific language governing permissions and limitations under
15 * the License.
16 */
17
18namespace Google\Service;
19
20use Google\Client;
21
22/**
23 * Service definition for Blogger (v3).
24 *
25 * <p>
26 * The Blogger API provides access to posts, comments and pages of a Blogger
27 * blog.</p>
28 *
29 * <p>
30 * For more information about this service, see the API
31 * <a href="https://developers.google.com/blogger/docs/3.0/getting_started" target="_blank">Documentation</a>
32 * </p>
33 *
34 * @author Google, Inc.
35 */
36class Blogger extends \Google\Service
37{
38 /** Manage your Blogger account. */
39 const BLOGGER =
40 "https://www.googleapis.com/auth/blogger";
41 /** View your Blogger account. */
42 const BLOGGER_READONLY =
43 "https://www.googleapis.com/auth/blogger.readonly";
44
45 public $blogUserInfos;
46 public $blogs;
47 public $comments;
48 public $pageViews;
49 public $pages;
50 public $postUserInfos;
51 public $posts;
52 public $users;
53 public $rootUrlTemplate;
54
55 /**
56 * Constructs the internal representation of the Blogger service.
57 *
58 * @param Client|array $clientOrConfig The client used to deliver requests, or a
59 * config array to pass to a new Client instance.
60 * @param string $rootUrl The root URL used for requests to the service.
61 */
62 public function __construct($clientOrConfig = [], $rootUrl = null)
63 {
64 parent::__construct($clientOrConfig);
65 $this->rootUrl = $rootUrl ?: 'https://blogger.googleapis.com/';
66 $this->rootUrlTemplate = $rootUrl ?: 'https://blogger.UNIVERSE_DOMAIN/';
67 $this->servicePath = '';
68 $this->batchPath = 'batch';
69 $this->version = 'v3';
70 $this->serviceName = 'blogger';
71
72 $this->blogUserInfos = new Blogger\Resource\BlogUserInfos(
73 $this,
74 $this->serviceName,
75 'blogUserInfos',
76 [
77 'methods' => [
78 'get' => [
79 'path' => 'v3/users/{userId}/blogs/{blogId}',
80 'httpMethod' => 'GET',
81 'parameters' => [
82 'userId' => [
83 'location' => 'path',
84 'type' => 'string',
85 'required' => true,
86 ],
87 'blogId' => [
88 'location' => 'path',
89 'type' => 'string',
90 'required' => true,
91 ],
92 'maxPosts' => [
93 'location' => 'query',
94 'type' => 'integer',
95 ],
96 ],
97 ],
98 ]
99 ]
100 );
101 $this->blogs = new Blogger\Resource\Blogs(
102 $this,
103 $this->serviceName,
104 'blogs',
105 [
106 'methods' => [
107 'get' => [
108 'path' => 'v3/blogs/{blogId}',
109 'httpMethod' => 'GET',
110 'parameters' => [
111 'blogId' => [
112 'location' => 'path',
113 'type' => 'string',
114 'required' => true,
115 ],
116 'maxPosts' => [
117 'location' => 'query',
118 'type' => 'integer',
119 ],
120 'view' => [
121 'location' => 'query',
122 'type' => 'string',
123 ],
124 ],
125 ],'getByUrl' => [
126 'path' => 'v3/blogs/byurl',
127 'httpMethod' => 'GET',
128 'parameters' => [
129 'url' => [
130 'location' => 'query',
131 'type' => 'string',
132 'required' => true,
133 ],
134 'view' => [
135 'location' => 'query',
136 'type' => 'string',
137 ],
138 ],
139 ],'listByUser' => [
140 'path' => 'v3/users/{userId}/blogs',
141 'httpMethod' => 'GET',
142 'parameters' => [
143 'userId' => [
144 'location' => 'path',
145 'type' => 'string',
146 'required' => true,
147 ],
148 'fetchUserInfo' => [
149 'location' => 'query',
150 'type' => 'boolean',
151 ],
152 'role' => [
153 'location' => 'query',
154 'type' => 'string',
155 'repeated' => true,
156 ],
157 'status' => [
158 'location' => 'query',
159 'type' => 'string',
160 'repeated' => true,
161 ],
162 'view' => [
163 'location' => 'query',
164 'type' => 'string',
165 ],
166 ],
167 ],
168 ]
169 ]
170 );
171 $this->comments = new Blogger\Resource\Comments(
172 $this,
173 $this->serviceName,
174 'comments',
175 [
176 'methods' => [
177 'approve' => [
178 'path' => 'v3/blogs/{blogId}/posts/{postId}/comments/{commentId}/approve',
179 'httpMethod' => 'POST',
180 'parameters' => [
181 'blogId' => [
182 'location' => 'path',
183 'type' => 'string',
184 'required' => true,
185 ],
186 'postId' => [
187 'location' => 'path',
188 'type' => 'string',
189 'required' => true,
190 ],
191 'commentId' => [
192 'location' => 'path',
193 'type' => 'string',
194 'required' => true,
195 ],
196 ],
197 ],'delete' => [
198 'path' => 'v3/blogs/{blogId}/posts/{postId}/comments/{commentId}',
199 'httpMethod' => 'DELETE',
200 'parameters' => [
201 'blogId' => [
202 'location' => 'path',
203 'type' => 'string',
204 'required' => true,
205 ],
206 'postId' => [
207 'location' => 'path',
208 'type' => 'string',
209 'required' => true,
210 ],
211 'commentId' => [
212 'location' => 'path',
213 'type' => 'string',
214 'required' => true,
215 ],
216 ],
217 ],'get' => [
218 'path' => 'v3/blogs/{blogId}/posts/{postId}/comments/{commentId}',
219 'httpMethod' => 'GET',
220 'parameters' => [
221 'blogId' => [
222 'location' => 'path',
223 'type' => 'string',
224 'required' => true,
225 ],
226 'postId' => [
227 'location' => 'path',
228 'type' => 'string',
229 'required' => true,
230 ],
231 'commentId' => [
232 'location' => 'path',
233 'type' => 'string',
234 'required' => true,
235 ],
236 'view' => [
237 'location' => 'query',
238 'type' => 'string',
239 ],
240 ],
241 ],'list' => [
242 'path' => 'v3/blogs/{blogId}/posts/{postId}/comments',
243 'httpMethod' => 'GET',
244 'parameters' => [
245 'blogId' => [
246 'location' => 'path',
247 'type' => 'string',
248 'required' => true,
249 ],
250 'postId' => [
251 'location' => 'path',
252 'type' => 'string',
253 'required' => true,
254 ],
255 'endDate' => [
256 'location' => 'query',
257 'type' => 'string',
258 ],
259 'fetchBodies' => [
260 'location' => 'query',
261 'type' => 'boolean',
262 ],
263 'maxResults' => [
264 'location' => 'query',
265 'type' => 'integer',
266 ],
267 'pageToken' => [
268 'location' => 'query',
269 'type' => 'string',
270 ],
271 'startDate' => [
272 'location' => 'query',
273 'type' => 'string',
274 ],
275 'status' => [
276 'location' => 'query',
277 'type' => 'string',
278 ],
279 'view' => [
280 'location' => 'query',
281 'type' => 'string',
282 ],
283 ],
284 ],'listByBlog' => [
285 'path' => 'v3/blogs/{blogId}/comments',
286 'httpMethod' => 'GET',
287 'parameters' => [
288 'blogId' => [
289 'location' => 'path',
290 'type' => 'string',
291 'required' => true,
292 ],
293 'endDate' => [
294 'location' => 'query',
295 'type' => 'string',
296 ],
297 'fetchBodies' => [
298 'location' => 'query',
299 'type' => 'boolean',
300 ],
301 'maxResults' => [
302 'location' => 'query',
303 'type' => 'integer',
304 ],
305 'pageToken' => [
306 'location' => 'query',
307 'type' => 'string',
308 ],
309 'startDate' => [
310 'location' => 'query',
311 'type' => 'string',
312 ],
313 'status' => [
314 'location' => 'query',
315 'type' => 'string',
316 'repeated' => true,
317 ],
318 ],
319 ],'markAsSpam' => [
320 'path' => 'v3/blogs/{blogId}/posts/{postId}/comments/{commentId}/spam',
321 'httpMethod' => 'POST',
322 'parameters' => [
323 'blogId' => [
324 'location' => 'path',
325 'type' => 'string',
326 'required' => true,
327 ],
328 'postId' => [
329 'location' => 'path',
330 'type' => 'string',
331 'required' => true,
332 ],
333 'commentId' => [
334 'location' => 'path',
335 'type' => 'string',
336 'required' => true,
337 ],
338 ],
339 ],'removeContent' => [
340 'path' => 'v3/blogs/{blogId}/posts/{postId}/comments/{commentId}/removecontent',
341 'httpMethod' => 'POST',
342 'parameters' => [
343 'blogId' => [
344 'location' => 'path',
345 'type' => 'string',
346 'required' => true,
347 ],
348 'postId' => [
349 'location' => 'path',
350 'type' => 'string',
351 'required' => true,
352 ],
353 'commentId' => [
354 'location' => 'path',
355 'type' => 'string',
356 'required' => true,
357 ],
358 ],
359 ],
360 ]
361 ]
362 );
363 $this->pageViews = new Blogger\Resource\PageViews(
364 $this,
365 $this->serviceName,
366 'pageViews',
367 [
368 'methods' => [
369 'get' => [
370 'path' => 'v3/blogs/{blogId}/pageviews',
371 'httpMethod' => 'GET',
372 'parameters' => [
373 'blogId' => [
374 'location' => 'path',
375 'type' => 'string',
376 'required' => true,
377 ],
378 'range' => [
379 'location' => 'query',
380 'type' => 'string',
381 'repeated' => true,
382 ],
383 ],
384 ],
385 ]
386 ]
387 );
388 $this->pages = new Blogger\Resource\Pages(
389 $this,
390 $this->serviceName,
391 'pages',
392 [
393 'methods' => [
394 'delete' => [
395 'path' => 'v3/blogs/{blogId}/pages/{pageId}',
396 'httpMethod' => 'DELETE',
397 'parameters' => [
398 'blogId' => [
399 'location' => 'path',
400 'type' => 'string',
401 'required' => true,
402 ],
403 'pageId' => [
404 'location' => 'path',
405 'type' => 'string',
406 'required' => true,
407 ],
408 'useTrash' => [
409 'location' => 'query',
410 'type' => 'boolean',
411 ],
412 ],
413 ],'get' => [
414 'path' => 'v3/blogs/{blogId}/pages/{pageId}',
415 'httpMethod' => 'GET',
416 'parameters' => [
417 'blogId' => [
418 'location' => 'path',
419 'type' => 'string',
420 'required' => true,
421 ],
422 'pageId' => [
423 'location' => 'path',
424 'type' => 'string',
425 'required' => true,
426 ],
427 'view' => [
428 'location' => 'query',
429 'type' => 'string',
430 ],
431 ],
432 ],'insert' => [
433 'path' => 'v3/blogs/{blogId}/pages',
434 'httpMethod' => 'POST',
435 'parameters' => [
436 'blogId' => [
437 'location' => 'path',
438 'type' => 'string',
439 'required' => true,
440 ],
441 'isDraft' => [
442 'location' => 'query',
443 'type' => 'boolean',
444 ],
445 ],
446 ],'list' => [
447 'path' => 'v3/blogs/{blogId}/pages',
448 'httpMethod' => 'GET',
449 'parameters' => [
450 'blogId' => [
451 'location' => 'path',
452 'type' => 'string',
453 'required' => true,
454 ],
455 'fetchBodies' => [
456 'location' => 'query',
457 'type' => 'boolean',
458 ],
459 'maxResults' => [
460 'location' => 'query',
461 'type' => 'integer',
462 ],
463 'pageToken' => [
464 'location' => 'query',
465 'type' => 'string',
466 ],
467 'status' => [
468 'location' => 'query',
469 'type' => 'string',
470 'repeated' => true,
471 ],
472 'view' => [
473 'location' => 'query',
474 'type' => 'string',
475 ],
476 ],
477 ],'patch' => [
478 'path' => 'v3/blogs/{blogId}/pages/{pageId}',
479 'httpMethod' => 'PATCH',
480 'parameters' => [
481 'blogId' => [
482 'location' => 'path',
483 'type' => 'string',
484 'required' => true,
485 ],
486 'pageId' => [
487 'location' => 'path',
488 'type' => 'string',
489 'required' => true,
490 ],
491 'publish' => [
492 'location' => 'query',
493 'type' => 'boolean',
494 ],
495 'revert' => [
496 'location' => 'query',
497 'type' => 'boolean',
498 ],
499 ],
500 ],'publish' => [
501 'path' => 'v3/blogs/{blogId}/pages/{pageId}/publish',
502 'httpMethod' => 'POST',
503 'parameters' => [
504 'blogId' => [
505 'location' => 'path',
506 'type' => 'string',
507 'required' => true,
508 ],
509 'pageId' => [
510 'location' => 'path',
511 'type' => 'string',
512 'required' => true,
513 ],
514 ],
515 ],'revert' => [
516 'path' => 'v3/blogs/{blogId}/pages/{pageId}/revert',
517 'httpMethod' => 'POST',
518 'parameters' => [
519 'blogId' => [
520 'location' => 'path',
521 'type' => 'string',
522 'required' => true,
523 ],
524 'pageId' => [
525 'location' => 'path',
526 'type' => 'string',
527 'required' => true,
528 ],
529 ],
530 ],'update' => [
531 'path' => 'v3/blogs/{blogId}/pages/{pageId}',
532 'httpMethod' => 'PUT',
533 'parameters' => [
534 'blogId' => [
535 'location' => 'path',
536 'type' => 'string',
537 'required' => true,
538 ],
539 'pageId' => [
540 'location' => 'path',
541 'type' => 'string',
542 'required' => true,
543 ],
544 'publish' => [
545 'location' => 'query',
546 'type' => 'boolean',
547 ],
548 'revert' => [
549 'location' => 'query',
550 'type' => 'boolean',
551 ],
552 ],
553 ],
554 ]
555 ]
556 );
557 $this->postUserInfos = new Blogger\Resource\PostUserInfos(
558 $this,
559 $this->serviceName,
560 'postUserInfos',
561 [
562 'methods' => [
563 'get' => [
564 'path' => 'v3/users/{userId}/blogs/{blogId}/posts/{postId}',
565 'httpMethod' => 'GET',
566 'parameters' => [
567 'userId' => [
568 'location' => 'path',
569 'type' => 'string',
570 'required' => true,
571 ],
572 'blogId' => [
573 'location' => 'path',
574 'type' => 'string',
575 'required' => true,
576 ],
577 'postId' => [
578 'location' => 'path',
579 'type' => 'string',
580 'required' => true,
581 ],
582 'maxComments' => [
583 'location' => 'query',
584 'type' => 'integer',
585 ],
586 ],
587 ],'list' => [
588 'path' => 'v3/users/{userId}/blogs/{blogId}/posts',
589 'httpMethod' => 'GET',
590 'parameters' => [
591 'userId' => [
592 'location' => 'path',
593 'type' => 'string',
594 'required' => true,
595 ],
596 'blogId' => [
597 'location' => 'path',
598 'type' => 'string',
599 'required' => true,
600 ],
601 'endDate' => [
602 'location' => 'query',
603 'type' => 'string',
604 ],
605 'fetchBodies' => [
606 'location' => 'query',
607 'type' => 'boolean',
608 ],
609 'labels' => [
610 'location' => 'query',
611 'type' => 'string',
612 ],
613 'maxResults' => [
614 'location' => 'query',
615 'type' => 'integer',
616 ],
617 'orderBy' => [
618 'location' => 'query',
619 'type' => 'string',
620 ],
621 'pageToken' => [
622 'location' => 'query',
623 'type' => 'string',
624 ],
625 'startDate' => [
626 'location' => 'query',
627 'type' => 'string',
628 ],
629 'status' => [
630 'location' => 'query',
631 'type' => 'string',
632 'repeated' => true,
633 ],
634 'view' => [
635 'location' => 'query',
636 'type' => 'string',
637 ],
638 ],
639 ],
640 ]
641 ]
642 );
643 $this->posts = new Blogger\Resource\Posts(
644 $this,
645 $this->serviceName,
646 'posts',
647 [
648 'methods' => [
649 'delete' => [
650 'path' => 'v3/blogs/{blogId}/posts/{postId}',
651 'httpMethod' => 'DELETE',
652 'parameters' => [
653 'blogId' => [
654 'location' => 'path',
655 'type' => 'string',
656 'required' => true,
657 ],
658 'postId' => [
659 'location' => 'path',
660 'type' => 'string',
661 'required' => true,
662 ],
663 'useTrash' => [
664 'location' => 'query',
665 'type' => 'boolean',
666 ],
667 ],
668 ],'get' => [
669 'path' => 'v3/blogs/{blogId}/posts/{postId}',
670 'httpMethod' => 'GET',
671 'parameters' => [
672 'blogId' => [
673 'location' => 'path',
674 'type' => 'string',
675 'required' => true,
676 ],
677 'postId' => [
678 'location' => 'path',
679 'type' => 'string',
680 'required' => true,
681 ],
682 'fetchBody' => [
683 'location' => 'query',
684 'type' => 'boolean',
685 ],
686 'fetchImages' => [
687 'location' => 'query',
688 'type' => 'boolean',
689 ],
690 'maxComments' => [
691 'location' => 'query',
692 'type' => 'integer',
693 ],
694 'view' => [
695 'location' => 'query',
696 'type' => 'string',
697 ],
698 ],
699 ],'getByPath' => [
700 'path' => 'v3/blogs/{blogId}/posts/bypath',
701 'httpMethod' => 'GET',
702 'parameters' => [
703 'blogId' => [
704 'location' => 'path',
705 'type' => 'string',
706 'required' => true,
707 ],
708 'path' => [
709 'location' => 'query',
710 'type' => 'string',
711 'required' => true,
712 ],
713 'maxComments' => [
714 'location' => 'query',
715 'type' => 'integer',
716 ],
717 'view' => [
718 'location' => 'query',
719 'type' => 'string',
720 ],
721 ],
722 ],'insert' => [
723 'path' => 'v3/blogs/{blogId}/posts',
724 'httpMethod' => 'POST',
725 'parameters' => [
726 'blogId' => [
727 'location' => 'path',
728 'type' => 'string',
729 'required' => true,
730 ],
731 'fetchBody' => [
732 'location' => 'query',
733 'type' => 'boolean',
734 ],
735 'fetchImages' => [
736 'location' => 'query',
737 'type' => 'boolean',
738 ],
739 'isDraft' => [
740 'location' => 'query',
741 'type' => 'boolean',
742 ],
743 ],
744 ],'list' => [
745 'path' => 'v3/blogs/{blogId}/posts',
746 'httpMethod' => 'GET',
747 'parameters' => [
748 'blogId' => [
749 'location' => 'path',
750 'type' => 'string',
751 'required' => true,
752 ],
753 'endDate' => [
754 'location' => 'query',
755 'type' => 'string',
756 ],
757 'fetchBodies' => [
758 'location' => 'query',
759 'type' => 'boolean',
760 ],
761 'fetchImages' => [
762 'location' => 'query',
763 'type' => 'boolean',
764 ],
765 'labels' => [
766 'location' => 'query',
767 'type' => 'string',
768 ],
769 'maxResults' => [
770 'location' => 'query',
771 'type' => 'integer',
772 ],
773 'orderBy' => [
774 'location' => 'query',
775 'type' => 'string',
776 ],
777 'pageToken' => [
778 'location' => 'query',
779 'type' => 'string',
780 ],
781 'sortOption' => [
782 'location' => 'query',
783 'type' => 'string',
784 ],
785 'startDate' => [
786 'location' => 'query',
787 'type' => 'string',
788 ],
789 'status' => [
790 'location' => 'query',
791 'type' => 'string',
792 'repeated' => true,
793 ],
794 'view' => [
795 'location' => 'query',
796 'type' => 'string',
797 ],
798 ],
799 ],'patch' => [
800 'path' => 'v3/blogs/{blogId}/posts/{postId}',
801 'httpMethod' => 'PATCH',
802 'parameters' => [
803 'blogId' => [
804 'location' => 'path',
805 'type' => 'string',
806 'required' => true,
807 ],
808 'postId' => [
809 'location' => 'path',
810 'type' => 'string',
811 'required' => true,
812 ],
813 'fetchBody' => [
814 'location' => 'query',
815 'type' => 'boolean',
816 ],
817 'fetchImages' => [
818 'location' => 'query',
819 'type' => 'boolean',
820 ],
821 'maxComments' => [
822 'location' => 'query',
823 'type' => 'integer',
824 ],
825 'publish' => [
826 'location' => 'query',
827 'type' => 'boolean',
828 ],
829 'revert' => [
830 'location' => 'query',
831 'type' => 'boolean',
832 ],
833 ],
834 ],'publish' => [
835 'path' => 'v3/blogs/{blogId}/posts/{postId}/publish',
836 'httpMethod' => 'POST',
837 'parameters' => [
838 'blogId' => [
839 'location' => 'path',
840 'type' => 'string',
841 'required' => true,
842 ],
843 'postId' => [
844 'location' => 'path',
845 'type' => 'string',
846 'required' => true,
847 ],
848 'publishDate' => [
849 'location' => 'query',
850 'type' => 'string',
851 ],
852 ],
853 ],'revert' => [
854 'path' => 'v3/blogs/{blogId}/posts/{postId}/revert',
855 'httpMethod' => 'POST',
856 'parameters' => [
857 'blogId' => [
858 'location' => 'path',
859 'type' => 'string',
860 'required' => true,
861 ],
862 'postId' => [
863 'location' => 'path',
864 'type' => 'string',
865 'required' => true,
866 ],
867 ],
868 ],'search' => [
869 'path' => 'v3/blogs/{blogId}/posts/search',
870 'httpMethod' => 'GET',
871 'parameters' => [
872 'blogId' => [
873 'location' => 'path',
874 'type' => 'string',
875 'required' => true,
876 ],
877 'q' => [
878 'location' => 'query',
879 'type' => 'string',
880 'required' => true,
881 ],
882 'fetchBodies' => [
883 'location' => 'query',
884 'type' => 'boolean',
885 ],
886 'orderBy' => [
887 'location' => 'query',
888 'type' => 'string',
889 ],
890 ],
891 ],'update' => [
892 'path' => 'v3/blogs/{blogId}/posts/{postId}',
893 'httpMethod' => 'PUT',
894 'parameters' => [
895 'blogId' => [
896 'location' => 'path',
897 'type' => 'string',
898 'required' => true,
899 ],
900 'postId' => [
901 'location' => 'path',
902 'type' => 'string',
903 'required' => true,
904 ],
905 'fetchBody' => [
906 'location' => 'query',
907 'type' => 'boolean',
908 ],
909 'fetchImages' => [
910 'location' => 'query',
911 'type' => 'boolean',
912 ],
913 'maxComments' => [
914 'location' => 'query',
915 'type' => 'integer',
916 ],
917 'publish' => [
918 'location' => 'query',
919 'type' => 'boolean',
920 ],
921 'revert' => [
922 'location' => 'query',
923 'type' => 'boolean',
924 ],
925 ],
926 ],
927 ]
928 ]
929 );
930 $this->users = new Blogger\Resource\Users(
931 $this,
932 $this->serviceName,
933 'users',
934 [
935 'methods' => [
936 'get' => [
937 'path' => 'v3/users/{userId}',
938 'httpMethod' => 'GET',
939 'parameters' => [
940 'userId' => [
941 'location' => 'path',
942 'type' => 'string',
943 'required' => true,
944 ],
945 ],
946 ],
947 ]
948 ]
949 );
950 }
951}
952
953// Adding a class alias for backwards compatibility with the previous class name.
954class_alias(Blogger::class, 'Google_Service_Blogger');
Note: See TracBrowser for help on using the repository browser.