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 Storage (v1).
24 *
25 * <p>
26 * Stores and retrieves potentially large, immutable data objects.</p>
27 *
28 * <p>
29 * For more information about this service, see the API
30 * <a href="https://developers.google.com/storage/docs/json_api/" target="_blank">Documentation</a>
31 * </p>
32 *
33 * @author Google, Inc.
34 */
35class Storage extends \Google\Service
36{
37  /** View and manage your data across Google Cloud Platform services. */
38  const CLOUD_PLATFORM =
39      "https://www.googleapis.com/auth/cloud-platform";
40  /** View your data across Google Cloud Platform services. */
41  const CLOUD_PLATFORM_READ_ONLY =
42      "https://www.googleapis.com/auth/cloud-platform.read-only";
43  /** Manage your data and permissions in Google Cloud Storage. */
44  const DEVSTORAGE_FULL_CONTROL =
45      "https://www.googleapis.com/auth/devstorage.full_control";
46  /** View your data in Google Cloud Storage. */
47  const DEVSTORAGE_READ_ONLY =
48      "https://www.googleapis.com/auth/devstorage.read_only";
49  /** Manage your data in Google Cloud Storage. */
50  const DEVSTORAGE_READ_WRITE =
51      "https://www.googleapis.com/auth/devstorage.read_write";
52
53  public $bucketAccessControls;
54  public $buckets;
55  public $channels;
56  public $defaultObjectAccessControls;
57  public $notifications;
58  public $objectAccessControls;
59  public $objects;
60  public $projects_hmacKeys;
61  public $projects_serviceAccount;
62
63  /**
64   * Constructs the internal representation of the Storage service.
65   *
66   * @param Client|array $clientOrConfig The client used to deliver requests, or a
67   *                                     config array to pass to a new Client instance.
68   * @param string $rootUrl The root URL used for requests to the service.
69   */
70  public function __construct($clientOrConfig = [], $rootUrl = null)
71  {
72    parent::__construct($clientOrConfig);
73    $this->rootUrl = $rootUrl ?: 'https://storage.googleapis.com/';
74    $this->servicePath = 'storage/v1/';
75    $this->batchPath = 'batch/storage/v1';
76    $this->version = 'v1';
77    $this->serviceName = 'storage';
78
79    $this->bucketAccessControls = new Storage\Resource\BucketAccessControls(
80        $this,
81        $this->serviceName,
82        'bucketAccessControls',
83        [
84          'methods' => [
85            'delete' => [
86              'path' => 'b/{bucket}/acl/{entity}',
87              'httpMethod' => 'DELETE',
88              'parameters' => [
89                'bucket' => [
90                  'location' => 'path',
91                  'type' => 'string',
92                  'required' => true,
93                ],
94                'entity' => [
95                  'location' => 'path',
96                  'type' => 'string',
97                  'required' => true,
98                ],
99                'userProject' => [
100                  'location' => 'query',
101                  'type' => 'string',
102                ],
103              ],
104            ],'get' => [
105              'path' => 'b/{bucket}/acl/{entity}',
106              'httpMethod' => 'GET',
107              'parameters' => [
108                'bucket' => [
109                  'location' => 'path',
110                  'type' => 'string',
111                  'required' => true,
112                ],
113                'entity' => [
114                  'location' => 'path',
115                  'type' => 'string',
116                  'required' => true,
117                ],
118                'userProject' => [
119                  'location' => 'query',
120                  'type' => 'string',
121                ],
122              ],
123            ],'insert' => [
124              'path' => 'b/{bucket}/acl',
125              'httpMethod' => 'POST',
126              'parameters' => [
127                'bucket' => [
128                  'location' => 'path',
129                  'type' => 'string',
130                  'required' => true,
131                ],
132                'userProject' => [
133                  'location' => 'query',
134                  'type' => 'string',
135                ],
136              ],
137            ],'list' => [
138              'path' => 'b/{bucket}/acl',
139              'httpMethod' => 'GET',
140              'parameters' => [
141                'bucket' => [
142                  'location' => 'path',
143                  'type' => 'string',
144                  'required' => true,
145                ],
146                'userProject' => [
147                  'location' => 'query',
148                  'type' => 'string',
149                ],
150              ],
151            ],'patch' => [
152              'path' => 'b/{bucket}/acl/{entity}',
153              'httpMethod' => 'PATCH',
154              'parameters' => [
155                'bucket' => [
156                  'location' => 'path',
157                  'type' => 'string',
158                  'required' => true,
159                ],
160                'entity' => [
161                  'location' => 'path',
162                  'type' => 'string',
163                  'required' => true,
164                ],
165                'userProject' => [
166                  'location' => 'query',
167                  'type' => 'string',
168                ],
169              ],
170            ],'update' => [
171              'path' => 'b/{bucket}/acl/{entity}',
172              'httpMethod' => 'PUT',
173              'parameters' => [
174                'bucket' => [
175                  'location' => 'path',
176                  'type' => 'string',
177                  'required' => true,
178                ],
179                'entity' => [
180                  'location' => 'path',
181                  'type' => 'string',
182                  'required' => true,
183                ],
184                'userProject' => [
185                  'location' => 'query',
186                  'type' => 'string',
187                ],
188              ],
189            ],
190          ]
191        ]
192    );
193    $this->buckets = new Storage\Resource\Buckets(
194        $this,
195        $this->serviceName,
196        'buckets',
197        [
198          'methods' => [
199            'delete' => [
200              'path' => 'b/{bucket}',
201              'httpMethod' => 'DELETE',
202              'parameters' => [
203                'bucket' => [
204                  'location' => 'path',
205                  'type' => 'string',
206                  'required' => true,
207                ],
208                'ifMetagenerationMatch' => [
209                  'location' => 'query',
210                  'type' => 'string',
211                ],
212                'ifMetagenerationNotMatch' => [
213                  'location' => 'query',
214                  'type' => 'string',
215                ],
216                'userProject' => [
217                  'location' => 'query',
218                  'type' => 'string',
219                ],
220              ],
221            ],'get' => [
222              'path' => 'b/{bucket}',
223              'httpMethod' => 'GET',
224              'parameters' => [
225                'bucket' => [
226                  'location' => 'path',
227                  'type' => 'string',
228                  'required' => true,
229                ],
230                'ifMetagenerationMatch' => [
231                  'location' => 'query',
232                  'type' => 'string',
233                ],
234                'ifMetagenerationNotMatch' => [
235                  'location' => 'query',
236                  'type' => 'string',
237                ],
238                'projection' => [
239                  'location' => 'query',
240                  'type' => 'string',
241                ],
242                'userProject' => [
243                  'location' => 'query',
244                  'type' => 'string',
245                ],
246              ],
247            ],'getIamPolicy' => [
248              'path' => 'b/{bucket}/iam',
249              'httpMethod' => 'GET',
250              'parameters' => [
251                'bucket' => [
252                  'location' => 'path',
253                  'type' => 'string',
254                  'required' => true,
255                ],
256                'optionsRequestedPolicyVersion' => [
257                  'location' => 'query',
258                  'type' => 'integer',
259                ],
260                'userProject' => [
261                  'location' => 'query',
262                  'type' => 'string',
263                ],
264              ],
265            ],'insert' => [
266              'path' => 'b',
267              'httpMethod' => 'POST',
268              'parameters' => [
269                'project' => [
270                  'location' => 'query',
271                  'type' => 'string',
272                  'required' => true,
273                ],
274                'predefinedAcl' => [
275                  'location' => 'query',
276                  'type' => 'string',
277                ],
278                'predefinedDefaultObjectAcl' => [
279                  'location' => 'query',
280                  'type' => 'string',
281                ],
282                'projection' => [
283                  'location' => 'query',
284                  'type' => 'string',
285                ],
286                'userProject' => [
287                  'location' => 'query',
288                  'type' => 'string',
289                ],
290              ],
291            ],'list' => [
292              'path' => 'b',
293              'httpMethod' => 'GET',
294              'parameters' => [
295                'project' => [
296                  'location' => 'query',
297                  'type' => 'string',
298                  'required' => true,
299                ],
300                'maxResults' => [
301                  'location' => 'query',
302                  'type' => 'integer',
303                ],
304                'pageToken' => [
305                  'location' => 'query',
306                  'type' => 'string',
307                ],
308                'prefix' => [
309                  'location' => 'query',
310                  'type' => 'string',
311                ],
312                'projection' => [
313                  'location' => 'query',
314                  'type' => 'string',
315                ],
316                'userProject' => [
317                  'location' => 'query',
318                  'type' => 'string',
319                ],
320              ],
321            ],'lockRetentionPolicy' => [
322              'path' => 'b/{bucket}/lockRetentionPolicy',
323              'httpMethod' => 'POST',
324              'parameters' => [
325                'bucket' => [
326                  'location' => 'path',
327                  'type' => 'string',
328                  'required' => true,
329                ],
330                'ifMetagenerationMatch' => [
331                  'location' => 'query',
332                  'type' => 'string',
333                  'required' => true,
334                ],
335                'userProject' => [
336                  'location' => 'query',
337                  'type' => 'string',
338                ],
339              ],
340            ],'patch' => [
341              'path' => 'b/{bucket}',
342              'httpMethod' => 'PATCH',
343              'parameters' => [
344                'bucket' => [
345                  'location' => 'path',
346                  'type' => 'string',
347                  'required' => true,
348                ],
349                'ifMetagenerationMatch' => [
350                  'location' => 'query',
351                  'type' => 'string',
352                ],
353                'ifMetagenerationNotMatch' => [
354                  'location' => 'query',
355                  'type' => 'string',
356                ],
357                'predefinedAcl' => [
358                  'location' => 'query',
359                  'type' => 'string',
360                ],
361                'predefinedDefaultObjectAcl' => [
362                  'location' => 'query',
363                  'type' => 'string',
364                ],
365                'projection' => [
366                  'location' => 'query',
367                  'type' => 'string',
368                ],
369                'userProject' => [
370                  'location' => 'query',
371                  'type' => 'string',
372                ],
373              ],
374            ],'setIamPolicy' => [
375              'path' => 'b/{bucket}/iam',
376              'httpMethod' => 'PUT',
377              'parameters' => [
378                'bucket' => [
379                  'location' => 'path',
380                  'type' => 'string',
381                  'required' => true,
382                ],
383                'userProject' => [
384                  'location' => 'query',
385                  'type' => 'string',
386                ],
387              ],
388            ],'testIamPermissions' => [
389              'path' => 'b/{bucket}/iam/testPermissions',
390              'httpMethod' => 'GET',
391              'parameters' => [
392                'bucket' => [
393                  'location' => 'path',
394                  'type' => 'string',
395                  'required' => true,
396                ],
397                'permissions' => [
398                  'location' => 'query',
399                  'type' => 'string',
400                  'repeated' => true,
401                  'required' => true,
402                ],
403                'userProject' => [
404                  'location' => 'query',
405                  'type' => 'string',
406                ],
407              ],
408            ],'update' => [
409              'path' => 'b/{bucket}',
410              'httpMethod' => 'PUT',
411              'parameters' => [
412                'bucket' => [
413                  'location' => 'path',
414                  'type' => 'string',
415                  'required' => true,
416                ],
417                'ifMetagenerationMatch' => [
418                  'location' => 'query',
419                  'type' => 'string',
420                ],
421                'ifMetagenerationNotMatch' => [
422                  'location' => 'query',
423                  'type' => 'string',
424                ],
425                'predefinedAcl' => [
426                  'location' => 'query',
427                  'type' => 'string',
428                ],
429                'predefinedDefaultObjectAcl' => [
430                  'location' => 'query',
431                  'type' => 'string',
432                ],
433                'projection' => [
434                  'location' => 'query',
435                  'type' => 'string',
436                ],
437                'userProject' => [
438                  'location' => 'query',
439                  'type' => 'string',
440                ],
441              ],
442            ],
443          ]
444        ]
445    );
446    $this->channels = new Storage\Resource\Channels(
447        $this,
448        $this->serviceName,
449        'channels',
450        [
451          'methods' => [
452            'stop' => [
453              'path' => 'channels/stop',
454              'httpMethod' => 'POST',
455              'parameters' => [],
456            ],
457          ]
458        ]
459    );
460    $this->defaultObjectAccessControls = new Storage\Resource\DefaultObjectAccessControls(
461        $this,
462        $this->serviceName,
463        'defaultObjectAccessControls',
464        [
465          'methods' => [
466            'delete' => [
467              'path' => 'b/{bucket}/defaultObjectAcl/{entity}',
468              'httpMethod' => 'DELETE',
469              'parameters' => [
470                'bucket' => [
471                  'location' => 'path',
472                  'type' => 'string',
473                  'required' => true,
474                ],
475                'entity' => [
476                  'location' => 'path',
477                  'type' => 'string',
478                  'required' => true,
479                ],
480                'userProject' => [
481                  'location' => 'query',
482                  'type' => 'string',
483                ],
484              ],
485            ],'get' => [
486              'path' => 'b/{bucket}/defaultObjectAcl/{entity}',
487              'httpMethod' => 'GET',
488              'parameters' => [
489                'bucket' => [
490                  'location' => 'path',
491                  'type' => 'string',
492                  'required' => true,
493                ],
494                'entity' => [
495                  'location' => 'path',
496                  'type' => 'string',
497                  'required' => true,
498                ],
499                'userProject' => [
500                  'location' => 'query',
501                  'type' => 'string',
502                ],
503              ],
504            ],'insert' => [
505              'path' => 'b/{bucket}/defaultObjectAcl',
506              'httpMethod' => 'POST',
507              'parameters' => [
508                'bucket' => [
509                  'location' => 'path',
510                  'type' => 'string',
511                  'required' => true,
512                ],
513                'userProject' => [
514                  'location' => 'query',
515                  'type' => 'string',
516                ],
517              ],
518            ],'list' => [
519              'path' => 'b/{bucket}/defaultObjectAcl',
520              'httpMethod' => 'GET',
521              'parameters' => [
522                'bucket' => [
523                  'location' => 'path',
524                  'type' => 'string',
525                  'required' => true,
526                ],
527                'ifMetagenerationMatch' => [
528                  'location' => 'query',
529                  'type' => 'string',
530                ],
531                'ifMetagenerationNotMatch' => [
532                  'location' => 'query',
533                  'type' => 'string',
534                ],
535                'userProject' => [
536                  'location' => 'query',
537                  'type' => 'string',
538                ],
539              ],
540            ],'patch' => [
541              'path' => 'b/{bucket}/defaultObjectAcl/{entity}',
542              'httpMethod' => 'PATCH',
543              'parameters' => [
544                'bucket' => [
545                  'location' => 'path',
546                  'type' => 'string',
547                  'required' => true,
548                ],
549                'entity' => [
550                  'location' => 'path',
551                  'type' => 'string',
552                  'required' => true,
553                ],
554                'userProject' => [
555                  'location' => 'query',
556                  'type' => 'string',
557                ],
558              ],
559            ],'update' => [
560              'path' => 'b/{bucket}/defaultObjectAcl/{entity}',
561              'httpMethod' => 'PUT',
562              'parameters' => [
563                'bucket' => [
564                  'location' => 'path',
565                  'type' => 'string',
566                  'required' => true,
567                ],
568                'entity' => [
569                  'location' => 'path',
570                  'type' => 'string',
571                  'required' => true,
572                ],
573                'userProject' => [
574                  'location' => 'query',
575                  'type' => 'string',
576                ],
577              ],
578            ],
579          ]
580        ]
581    );
582    $this->notifications = new Storage\Resource\Notifications(
583        $this,
584        $this->serviceName,
585        'notifications',
586        [
587          'methods' => [
588            'delete' => [
589              'path' => 'b/{bucket}/notificationConfigs/{notification}',
590              'httpMethod' => 'DELETE',
591              'parameters' => [
592                'bucket' => [
593                  'location' => 'path',
594                  'type' => 'string',
595                  'required' => true,
596                ],
597                'notification' => [
598                  'location' => 'path',
599                  'type' => 'string',
600                  'required' => true,
601                ],
602                'userProject' => [
603                  'location' => 'query',
604                  'type' => 'string',
605                ],
606              ],
607            ],'get' => [
608              'path' => 'b/{bucket}/notificationConfigs/{notification}',
609              'httpMethod' => 'GET',
610              'parameters' => [
611                'bucket' => [
612                  'location' => 'path',
613                  'type' => 'string',
614                  'required' => true,
615                ],
616                'notification' => [
617                  'location' => 'path',
618                  'type' => 'string',
619                  'required' => true,
620                ],
621                'userProject' => [
622                  'location' => 'query',
623                  'type' => 'string',
624                ],
625              ],
626            ],'insert' => [
627              'path' => 'b/{bucket}/notificationConfigs',
628              'httpMethod' => 'POST',
629              'parameters' => [
630                'bucket' => [
631                  'location' => 'path',
632                  'type' => 'string',
633                  'required' => true,
634                ],
635                'userProject' => [
636                  'location' => 'query',
637                  'type' => 'string',
638                ],
639              ],
640            ],'list' => [
641              'path' => 'b/{bucket}/notificationConfigs',
642              'httpMethod' => 'GET',
643              'parameters' => [
644                'bucket' => [
645                  'location' => 'path',
646                  'type' => 'string',
647                  'required' => true,
648                ],
649                'userProject' => [
650                  'location' => 'query',
651                  'type' => 'string',
652                ],
653              ],
654            ],
655          ]
656        ]
657    );
658    $this->objectAccessControls = new Storage\Resource\ObjectAccessControls(
659        $this,
660        $this->serviceName,
661        'objectAccessControls',
662        [
663          'methods' => [
664            'delete' => [
665              'path' => 'b/{bucket}/o/{object}/acl/{entity}',
666              'httpMethod' => 'DELETE',
667              'parameters' => [
668                'bucket' => [
669                  'location' => 'path',
670                  'type' => 'string',
671                  'required' => true,
672                ],
673                'object' => [
674                  'location' => 'path',
675                  'type' => 'string',
676                  'required' => true,
677                ],
678                'entity' => [
679                  'location' => 'path',
680                  'type' => 'string',
681                  'required' => true,
682                ],
683                'generation' => [
684                  'location' => 'query',
685                  'type' => 'string',
686                ],
687                'userProject' => [
688                  'location' => 'query',
689                  'type' => 'string',
690                ],
691              ],
692            ],'get' => [
693              'path' => 'b/{bucket}/o/{object}/acl/{entity}',
694              'httpMethod' => 'GET',
695              'parameters' => [
696                'bucket' => [
697                  'location' => 'path',
698                  'type' => 'string',
699                  'required' => true,
700                ],
701                'object' => [
702                  'location' => 'path',
703                  'type' => 'string',
704                  'required' => true,
705                ],
706                'entity' => [
707                  'location' => 'path',
708                  'type' => 'string',
709                  'required' => true,
710                ],
711                'generation' => [
712                  'location' => 'query',
713                  'type' => 'string',
714                ],
715                'userProject' => [
716                  'location' => 'query',
717                  'type' => 'string',
718                ],
719              ],
720            ],'insert' => [
721              'path' => 'b/{bucket}/o/{object}/acl',
722              'httpMethod' => 'POST',
723              'parameters' => [
724                'bucket' => [
725                  'location' => 'path',
726                  'type' => 'string',
727                  'required' => true,
728                ],
729                'object' => [
730                  'location' => 'path',
731                  'type' => 'string',
732                  'required' => true,
733                ],
734                'generation' => [
735                  'location' => 'query',
736                  'type' => 'string',
737                ],
738                'userProject' => [
739                  'location' => 'query',
740                  'type' => 'string',
741                ],
742              ],
743            ],'list' => [
744              'path' => 'b/{bucket}/o/{object}/acl',
745              'httpMethod' => 'GET',
746              'parameters' => [
747                'bucket' => [
748                  'location' => 'path',
749                  'type' => 'string',
750                  'required' => true,
751                ],
752                'object' => [
753                  'location' => 'path',
754                  'type' => 'string',
755                  'required' => true,
756                ],
757                'generation' => [
758                  'location' => 'query',
759                  'type' => 'string',
760                ],
761                'userProject' => [
762                  'location' => 'query',
763                  'type' => 'string',
764                ],
765              ],
766            ],'patch' => [
767              'path' => 'b/{bucket}/o/{object}/acl/{entity}',
768              'httpMethod' => 'PATCH',
769              'parameters' => [
770                'bucket' => [
771                  'location' => 'path',
772                  'type' => 'string',
773                  'required' => true,
774                ],
775                'object' => [
776                  'location' => 'path',
777                  'type' => 'string',
778                  'required' => true,
779                ],
780                'entity' => [
781                  'location' => 'path',
782                  'type' => 'string',
783                  'required' => true,
784                ],
785                'generation' => [
786                  'location' => 'query',
787                  'type' => 'string',
788                ],
789                'userProject' => [
790                  'location' => 'query',
791                  'type' => 'string',
792                ],
793              ],
794            ],'update' => [
795              'path' => 'b/{bucket}/o/{object}/acl/{entity}',
796              'httpMethod' => 'PUT',
797              'parameters' => [
798                'bucket' => [
799                  'location' => 'path',
800                  'type' => 'string',
801                  'required' => true,
802                ],
803                'object' => [
804                  'location' => 'path',
805                  'type' => 'string',
806                  'required' => true,
807                ],
808                'entity' => [
809                  'location' => 'path',
810                  'type' => 'string',
811                  'required' => true,
812                ],
813                'generation' => [
814                  'location' => 'query',
815                  'type' => 'string',
816                ],
817                'userProject' => [
818                  'location' => 'query',
819                  'type' => 'string',
820                ],
821              ],
822            ],
823          ]
824        ]
825    );
826    $this->objects = new Storage\Resource\Objects(
827        $this,
828        $this->serviceName,
829        'objects',
830        [
831          'methods' => [
832            'compose' => [
833              'path' => 'b/{destinationBucket}/o/{destinationObject}/compose',
834              'httpMethod' => 'POST',
835              'parameters' => [
836                'destinationBucket' => [
837                  'location' => 'path',
838                  'type' => 'string',
839                  'required' => true,
840                ],
841                'destinationObject' => [
842                  'location' => 'path',
843                  'type' => 'string',
844                  'required' => true,
845                ],
846                'destinationPredefinedAcl' => [
847                  'location' => 'query',
848                  'type' => 'string',
849                ],
850                'ifGenerationMatch' => [
851                  'location' => 'query',
852                  'type' => 'string',
853                ],
854                'ifMetagenerationMatch' => [
855                  'location' => 'query',
856                  'type' => 'string',
857                ],
858                'kmsKeyName' => [
859                  'location' => 'query',
860                  'type' => 'string',
861                ],
862                'userProject' => [
863                  'location' => 'query',
864                  'type' => 'string',
865                ],
866              ],
867            ],'copy' => [
868              'path' => 'b/{sourceBucket}/o/{sourceObject}/copyTo/b/{destinationBucket}/o/{destinationObject}',
869              'httpMethod' => 'POST',
870              'parameters' => [
871                'sourceBucket' => [
872                  'location' => 'path',
873                  'type' => 'string',
874                  'required' => true,
875                ],
876                'sourceObject' => [
877                  'location' => 'path',
878                  'type' => 'string',
879                  'required' => true,
880                ],
881                'destinationBucket' => [
882                  'location' => 'path',
883                  'type' => 'string',
884                  'required' => true,
885                ],
886                'destinationObject' => [
887                  'location' => 'path',
888                  'type' => 'string',
889                  'required' => true,
890                ],
891                'destinationKmsKeyName' => [
892                  'location' => 'query',
893                  'type' => 'string',
894                ],
895                'destinationPredefinedAcl' => [
896                  'location' => 'query',
897                  'type' => 'string',
898                ],
899                'ifGenerationMatch' => [
900                  'location' => 'query',
901                  'type' => 'string',
902                ],
903                'ifGenerationNotMatch' => [
904                  'location' => 'query',
905                  'type' => 'string',
906                ],
907                'ifMetagenerationMatch' => [
908                  'location' => 'query',
909                  'type' => 'string',
910                ],
911                'ifMetagenerationNotMatch' => [
912                  'location' => 'query',
913                  'type' => 'string',
914                ],
915                'ifSourceGenerationMatch' => [
916                  'location' => 'query',
917                  'type' => 'string',
918                ],
919                'ifSourceGenerationNotMatch' => [
920                  'location' => 'query',
921                  'type' => 'string',
922                ],
923                'ifSourceMetagenerationMatch' => [
924                  'location' => 'query',
925                  'type' => 'string',
926                ],
927                'ifSourceMetagenerationNotMatch' => [
928                  'location' => 'query',
929                  'type' => 'string',
930                ],
931                'projection' => [
932                  'location' => 'query',
933                  'type' => 'string',
934                ],
935                'sourceGeneration' => [
936                  'location' => 'query',
937                  'type' => 'string',
938                ],
939                'userProject' => [
940                  'location' => 'query',
941                  'type' => 'string',
942                ],
943              ],
944            ],'delete' => [
945              'path' => 'b/{bucket}/o/{object}',
946              'httpMethod' => 'DELETE',
947              'parameters' => [
948                'bucket' => [
949                  'location' => 'path',
950                  'type' => 'string',
951                  'required' => true,
952                ],
953                'object' => [
954                  'location' => 'path',
955                  'type' => 'string',
956                  'required' => true,
957                ],
958                'generation' => [
959                  'location' => 'query',
960                  'type' => 'string',
961                ],
962                'ifGenerationMatch' => [
963                  'location' => 'query',
964                  'type' => 'string',
965                ],
966                'ifGenerationNotMatch' => [
967                  'location' => 'query',
968                  'type' => 'string',
969                ],
970                'ifMetagenerationMatch' => [
971                  'location' => 'query',
972                  'type' => 'string',
973                ],
974                'ifMetagenerationNotMatch' => [
975                  'location' => 'query',
976                  'type' => 'string',
977                ],
978                'userProject' => [
979                  'location' => 'query',
980                  'type' => 'string',
981                ],
982              ],
983            ],'get' => [
984              'path' => 'b/{bucket}/o/{object}',
985              'httpMethod' => 'GET',
986              'parameters' => [
987                'bucket' => [
988                  'location' => 'path',
989                  'type' => 'string',
990                  'required' => true,
991                ],
992                'object' => [
993                  'location' => 'path',
994                  'type' => 'string',
995                  'required' => true,
996                ],
997                'generation' => [
998                  'location' => 'query',
999                  'type' => 'string',
1000                ],
1001                'ifGenerationMatch' => [
1002                  'location' => 'query',
1003                  'type' => 'string',
1004                ],
1005                'ifGenerationNotMatch' => [
1006                  'location' => 'query',
1007                  'type' => 'string',
1008                ],
1009                'ifMetagenerationMatch' => [
1010                  'location' => 'query',
1011                  'type' => 'string',
1012                ],
1013                'ifMetagenerationNotMatch' => [
1014                  'location' => 'query',
1015                  'type' => 'string',
1016                ],
1017                'projection' => [
1018                  'location' => 'query',
1019                  'type' => 'string',
1020                ],
1021                'userProject' => [
1022                  'location' => 'query',
1023                  'type' => 'string',
1024                ],
1025              ],
1026            ],'getIamPolicy' => [
1027              'path' => 'b/{bucket}/o/{object}/iam',
1028              'httpMethod' => 'GET',
1029              'parameters' => [
1030                'bucket' => [
1031                  'location' => 'path',
1032                  'type' => 'string',
1033                  'required' => true,
1034                ],
1035                'object' => [
1036                  'location' => 'path',
1037                  'type' => 'string',
1038                  'required' => true,
1039                ],
1040                'generation' => [
1041                  'location' => 'query',
1042                  'type' => 'string',
1043                ],
1044                'userProject' => [
1045                  'location' => 'query',
1046                  'type' => 'string',
1047                ],
1048              ],
1049            ],'insert' => [
1050              'path' => 'b/{bucket}/o',
1051              'httpMethod' => 'POST',
1052              'parameters' => [
1053                'bucket' => [
1054                  'location' => 'path',
1055                  'type' => 'string',
1056                  'required' => true,
1057                ],
1058                'contentEncoding' => [
1059                  'location' => 'query',
1060                  'type' => 'string',
1061                ],
1062                'ifGenerationMatch' => [
1063                  'location' => 'query',
1064                  'type' => 'string',
1065                ],
1066                'ifGenerationNotMatch' => [
1067                  'location' => 'query',
1068                  'type' => 'string',
1069                ],
1070                'ifMetagenerationMatch' => [
1071                  'location' => 'query',
1072                  'type' => 'string',
1073                ],
1074                'ifMetagenerationNotMatch' => [
1075                  'location' => 'query',
1076                  'type' => 'string',
1077                ],
1078                'kmsKeyName' => [
1079                  'location' => 'query',
1080                  'type' => 'string',
1081                ],
1082                'name' => [
1083                  'location' => 'query',
1084                  'type' => 'string',
1085                ],
1086                'predefinedAcl' => [
1087                  'location' => 'query',
1088                  'type' => 'string',
1089                ],
1090                'projection' => [
1091                  'location' => 'query',
1092                  'type' => 'string',
1093                ],
1094                'userProject' => [
1095                  'location' => 'query',
1096                  'type' => 'string',
1097                ],
1098              ],
1099            ],'list' => [
1100              'path' => 'b/{bucket}/o',
1101              'httpMethod' => 'GET',
1102              'parameters' => [
1103                'bucket' => [
1104                  'location' => 'path',
1105                  'type' => 'string',
1106                  'required' => true,
1107                ],
1108                'delimiter' => [
1109                  'location' => 'query',
1110                  'type' => 'string',
1111                ],
1112                'endOffset' => [
1113                  'location' => 'query',
1114                  'type' => 'string',
1115                ],
1116                'includeTrailingDelimiter' => [
1117                  'location' => 'query',
1118                  'type' => 'boolean',
1119                ],
1120                'maxResults' => [
1121                  'location' => 'query',
1122                  'type' => 'integer',
1123                ],
1124                'pageToken' => [
1125                  'location' => 'query',
1126                  'type' => 'string',
1127                ],
1128                'prefix' => [
1129                  'location' => 'query',
1130                  'type' => 'string',
1131                ],
1132                'projection' => [
1133                  'location' => 'query',
1134                  'type' => 'string',
1135                ],
1136                'startOffset' => [
1137                  'location' => 'query',
1138                  'type' => 'string',
1139                ],
1140                'userProject' => [
1141                  'location' => 'query',
1142                  'type' => 'string',
1143                ],
1144                'versions' => [
1145                  'location' => 'query',
1146                  'type' => 'boolean',
1147                ],
1148              ],
1149            ],'patch' => [
1150              'path' => 'b/{bucket}/o/{object}',
1151              'httpMethod' => 'PATCH',
1152              'parameters' => [
1153                'bucket' => [
1154                  'location' => 'path',
1155                  'type' => 'string',
1156                  'required' => true,
1157                ],
1158                'object' => [
1159                  'location' => 'path',
1160                  'type' => 'string',
1161                  'required' => true,
1162                ],
1163                'generation' => [
1164                  'location' => 'query',
1165                  'type' => 'string',
1166                ],
1167                'ifGenerationMatch' => [
1168                  'location' => 'query',
1169                  'type' => 'string',
1170                ],
1171                'ifGenerationNotMatch' => [
1172                  'location' => 'query',
1173                  'type' => 'string',
1174                ],
1175                'ifMetagenerationMatch' => [
1176                  'location' => 'query',
1177                  'type' => 'string',
1178                ],
1179                'ifMetagenerationNotMatch' => [
1180                  'location' => 'query',
1181                  'type' => 'string',
1182                ],
1183                'predefinedAcl' => [
1184                  'location' => 'query',
1185                  'type' => 'string',
1186                ],
1187                'projection' => [
1188                  'location' => 'query',
1189                  'type' => 'string',
1190                ],
1191                'userProject' => [
1192                  'location' => 'query',
1193                  'type' => 'string',
1194                ],
1195              ],
1196            ],'rewrite' => [
1197              'path' => 'b/{sourceBucket}/o/{sourceObject}/rewriteTo/b/{destinationBucket}/o/{destinationObject}',
1198              'httpMethod' => 'POST',
1199              'parameters' => [
1200                'sourceBucket' => [
1201                  'location' => 'path',
1202                  'type' => 'string',
1203                  'required' => true,
1204                ],
1205                'sourceObject' => [
1206                  'location' => 'path',
1207                  'type' => 'string',
1208                  'required' => true,
1209                ],
1210                'destinationBucket' => [
1211                  'location' => 'path',
1212                  'type' => 'string',
1213                  'required' => true,
1214                ],
1215                'destinationObject' => [
1216                  'location' => 'path',
1217                  'type' => 'string',
1218                  'required' => true,
1219                ],
1220                'destinationKmsKeyName' => [
1221                  'location' => 'query',
1222                  'type' => 'string',
1223                ],
1224                'destinationPredefinedAcl' => [
1225                  'location' => 'query',
1226                  'type' => 'string',
1227                ],
1228                'ifGenerationMatch' => [
1229                  'location' => 'query',
1230                  'type' => 'string',
1231                ],
1232                'ifGenerationNotMatch' => [
1233                  'location' => 'query',
1234                  'type' => 'string',
1235                ],
1236                'ifMetagenerationMatch' => [
1237                  'location' => 'query',
1238                  'type' => 'string',
1239                ],
1240                'ifMetagenerationNotMatch' => [
1241                  'location' => 'query',
1242                  'type' => 'string',
1243                ],
1244                'ifSourceGenerationMatch' => [
1245                  'location' => 'query',
1246                  'type' => 'string',
1247                ],
1248                'ifSourceGenerationNotMatch' => [
1249                  'location' => 'query',
1250                  'type' => 'string',
1251                ],
1252                'ifSourceMetagenerationMatch' => [
1253                  'location' => 'query',
1254                  'type' => 'string',
1255                ],
1256                'ifSourceMetagenerationNotMatch' => [
1257                  'location' => 'query',
1258                  'type' => 'string',
1259                ],
1260                'maxBytesRewrittenPerCall' => [
1261                  'location' => 'query',
1262                  'type' => 'string',
1263                ],
1264                'projection' => [
1265                  'location' => 'query',
1266                  'type' => 'string',
1267                ],
1268                'rewriteToken' => [
1269                  'location' => 'query',
1270                  'type' => 'string',
1271                ],
1272                'sourceGeneration' => [
1273                  'location' => 'query',
1274                  'type' => 'string',
1275                ],
1276                'userProject' => [
1277                  'location' => 'query',
1278                  'type' => 'string',
1279                ],
1280              ],
1281            ],'setIamPolicy' => [
1282              'path' => 'b/{bucket}/o/{object}/iam',
1283              'httpMethod' => 'PUT',
1284              'parameters' => [
1285                'bucket' => [
1286                  'location' => 'path',
1287                  'type' => 'string',
1288                  'required' => true,
1289                ],
1290                'object' => [
1291                  'location' => 'path',
1292                  'type' => 'string',
1293                  'required' => true,
1294                ],
1295                'generation' => [
1296                  'location' => 'query',
1297                  'type' => 'string',
1298                ],
1299                'userProject' => [
1300                  'location' => 'query',
1301                  'type' => 'string',
1302                ],
1303              ],
1304            ],'testIamPermissions' => [
1305              'path' => 'b/{bucket}/o/{object}/iam/testPermissions',
1306              'httpMethod' => 'GET',
1307              'parameters' => [
1308                'bucket' => [
1309                  'location' => 'path',
1310                  'type' => 'string',
1311                  'required' => true,
1312                ],
1313                'object' => [
1314                  'location' => 'path',
1315                  'type' => 'string',
1316                  'required' => true,
1317                ],
1318                'permissions' => [
1319                  'location' => 'query',
1320                  'type' => 'string',
1321                  'repeated' => true,
1322                  'required' => true,
1323                ],
1324                'generation' => [
1325                  'location' => 'query',
1326                  'type' => 'string',
1327                ],
1328                'userProject' => [
1329                  'location' => 'query',
1330                  'type' => 'string',
1331                ],
1332              ],
1333            ],'update' => [
1334              'path' => 'b/{bucket}/o/{object}',
1335              'httpMethod' => 'PUT',
1336              'parameters' => [
1337                'bucket' => [
1338                  'location' => 'path',
1339                  'type' => 'string',
1340                  'required' => true,
1341                ],
1342                'object' => [
1343                  'location' => 'path',
1344                  'type' => 'string',
1345                  'required' => true,
1346                ],
1347                'generation' => [
1348                  'location' => 'query',
1349                  'type' => 'string',
1350                ],
1351                'ifGenerationMatch' => [
1352                  'location' => 'query',
1353                  'type' => 'string',
1354                ],
1355                'ifGenerationNotMatch' => [
1356                  'location' => 'query',
1357                  'type' => 'string',
1358                ],
1359                'ifMetagenerationMatch' => [
1360                  'location' => 'query',
1361                  'type' => 'string',
1362                ],
1363                'ifMetagenerationNotMatch' => [
1364                  'location' => 'query',
1365                  'type' => 'string',
1366                ],
1367                'predefinedAcl' => [
1368                  'location' => 'query',
1369                  'type' => 'string',
1370                ],
1371                'projection' => [
1372                  'location' => 'query',
1373                  'type' => 'string',
1374                ],
1375                'userProject' => [
1376                  'location' => 'query',
1377                  'type' => 'string',
1378                ],
1379              ],
1380            ],'watchAll' => [
1381              'path' => 'b/{bucket}/o/watch',
1382              'httpMethod' => 'POST',
1383              'parameters' => [
1384                'bucket' => [
1385                  'location' => 'path',
1386                  'type' => 'string',
1387                  'required' => true,
1388                ],
1389                'delimiter' => [
1390                  'location' => 'query',
1391                  'type' => 'string',
1392                ],
1393                'endOffset' => [
1394                  'location' => 'query',
1395                  'type' => 'string',
1396                ],
1397                'includeTrailingDelimiter' => [
1398                  'location' => 'query',
1399                  'type' => 'boolean',
1400                ],
1401                'maxResults' => [
1402                  'location' => 'query',
1403                  'type' => 'integer',
1404                ],
1405                'pageToken' => [
1406                  'location' => 'query',
1407                  'type' => 'string',
1408                ],
1409                'prefix' => [
1410                  'location' => 'query',
1411                  'type' => 'string',
1412                ],
1413                'projection' => [
1414                  'location' => 'query',
1415                  'type' => 'string',
1416                ],
1417                'startOffset' => [
1418                  'location' => 'query',
1419                  'type' => 'string',
1420                ],
1421                'userProject' => [
1422                  'location' => 'query',
1423                  'type' => 'string',
1424                ],
1425                'versions' => [
1426                  'location' => 'query',
1427                  'type' => 'boolean',
1428                ],
1429              ],
1430            ],
1431          ]
1432        ]
1433    );
1434    $this->projects_hmacKeys = new Storage\Resource\ProjectsHmacKeys(
1435        $this,
1436        $this->serviceName,
1437        'hmacKeys',
1438        [
1439          'methods' => [
1440            'create' => [
1441              'path' => 'projects/{projectId}/hmacKeys',
1442              'httpMethod' => 'POST',
1443              'parameters' => [
1444                'projectId' => [
1445                  'location' => 'path',
1446                  'type' => 'string',
1447                  'required' => true,
1448                ],
1449                'serviceAccountEmail' => [
1450                  'location' => 'query',
1451                  'type' => 'string',
1452                  'required' => true,
1453                ],
1454                'userProject' => [
1455                  'location' => 'query',
1456                  'type' => 'string',
1457                ],
1458              ],
1459            ],'delete' => [
1460              'path' => 'projects/{projectId}/hmacKeys/{accessId}',
1461              'httpMethod' => 'DELETE',
1462              'parameters' => [
1463                'projectId' => [
1464                  'location' => 'path',
1465                  'type' => 'string',
1466                  'required' => true,
1467                ],
1468                'accessId' => [
1469                  'location' => 'path',
1470                  'type' => 'string',
1471                  'required' => true,
1472                ],
1473                'userProject' => [
1474                  'location' => 'query',
1475                  'type' => 'string',
1476                ],
1477              ],
1478            ],'get' => [
1479              'path' => 'projects/{projectId}/hmacKeys/{accessId}',
1480              'httpMethod' => 'GET',
1481              'parameters' => [
1482                'projectId' => [
1483                  'location' => 'path',
1484                  'type' => 'string',
1485                  'required' => true,
1486                ],
1487                'accessId' => [
1488                  'location' => 'path',
1489                  'type' => 'string',
1490                  'required' => true,
1491                ],
1492                'userProject' => [
1493                  'location' => 'query',
1494                  'type' => 'string',
1495                ],
1496              ],
1497            ],'list' => [
1498              'path' => 'projects/{projectId}/hmacKeys',
1499              'httpMethod' => 'GET',
1500              'parameters' => [
1501                'projectId' => [
1502                  'location' => 'path',
1503                  'type' => 'string',
1504                  'required' => true,
1505                ],
1506                'maxResults' => [
1507                  'location' => 'query',
1508                  'type' => 'integer',
1509                ],
1510                'pageToken' => [
1511                  'location' => 'query',
1512                  'type' => 'string',
1513                ],
1514                'serviceAccountEmail' => [
1515                  'location' => 'query',
1516                  'type' => 'string',
1517                ],
1518                'showDeletedKeys' => [
1519                  'location' => 'query',
1520                  'type' => 'boolean',
1521                ],
1522                'userProject' => [
1523                  'location' => 'query',
1524                  'type' => 'string',
1525                ],
1526              ],
1527            ],'update' => [
1528              'path' => 'projects/{projectId}/hmacKeys/{accessId}',
1529              'httpMethod' => 'PUT',
1530              'parameters' => [
1531                'projectId' => [
1532                  'location' => 'path',
1533                  'type' => 'string',
1534                  'required' => true,
1535                ],
1536                'accessId' => [
1537                  'location' => 'path',
1538                  'type' => 'string',
1539                  'required' => true,
1540                ],
1541                'userProject' => [
1542                  'location' => 'query',
1543                  'type' => 'string',
1544                ],
1545              ],
1546            ],
1547          ]
1548        ]
1549    );
1550    $this->projects_serviceAccount = new Storage\Resource\ProjectsServiceAccount(
1551        $this,
1552        $this->serviceName,
1553        'serviceAccount',
1554        [
1555          'methods' => [
1556            'get' => [
1557              'path' => 'projects/{projectId}/serviceAccount',
1558              'httpMethod' => 'GET',
1559              'parameters' => [
1560                'projectId' => [
1561                  'location' => 'path',
1562                  'type' => 'string',
1563                  'required' => true,
1564                ],
1565                'userProject' => [
1566                  'location' => 'query',
1567                  'type' => 'string',
1568                ],
1569              ],
1570            ],
1571          ]
1572        ]
1573    );
1574  }
1575}
1576
1577// Adding a class alias for backwards compatibility with the previous class name.
1578class_alias(Storage::class, 'Google_Service_Storage');
1579