source: vendor/google/apiclient-services/src/SecretManager.php@ e3d4e0a

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

Upload project files

  • Property mode set to 100644
File size: 16.6 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 SecretManager (v1).
24 *
25 * <p>
26 * Stores sensitive data such as API keys, passwords, and certificates. Provides
27 * convenience while improving security.</p>
28 *
29 * <p>
30 * For more information about this service, see the API
31 * <a href="https://cloud.google.com/secret-manager/" target="_blank">Documentation</a>
32 * </p>
33 *
34 * @author Google, Inc.
35 */
36class SecretManager extends \Google\Service
37{
38 /** See, edit, configure, and delete your Google Cloud data and see the email address for your Google Account.. */
39 const CLOUD_PLATFORM =
40 "https://www.googleapis.com/auth/cloud-platform";
41
42 public $projects_locations;
43 public $projects_locations_secrets;
44 public $projects_locations_secrets_versions;
45 public $projects_secrets;
46 public $projects_secrets_versions;
47 public $rootUrlTemplate;
48
49 /**
50 * Constructs the internal representation of the SecretManager service.
51 *
52 * @param Client|array $clientOrConfig The client used to deliver requests, or a
53 * config array to pass to a new Client instance.
54 * @param string $rootUrl The root URL used for requests to the service.
55 */
56 public function __construct($clientOrConfig = [], $rootUrl = null)
57 {
58 parent::__construct($clientOrConfig);
59 $this->rootUrl = $rootUrl ?: 'https://secretmanager.googleapis.com/';
60 $this->rootUrlTemplate = $rootUrl ?: 'https://secretmanager.UNIVERSE_DOMAIN/';
61 $this->servicePath = '';
62 $this->batchPath = 'batch';
63 $this->version = 'v1';
64 $this->serviceName = 'secretmanager';
65
66 $this->projects_locations = new SecretManager\Resource\ProjectsLocations(
67 $this,
68 $this->serviceName,
69 'locations',
70 [
71 'methods' => [
72 'get' => [
73 'path' => 'v1/{+name}',
74 'httpMethod' => 'GET',
75 'parameters' => [
76 'name' => [
77 'location' => 'path',
78 'type' => 'string',
79 'required' => true,
80 ],
81 ],
82 ],'list' => [
83 'path' => 'v1/{+name}/locations',
84 'httpMethod' => 'GET',
85 'parameters' => [
86 'name' => [
87 'location' => 'path',
88 'type' => 'string',
89 'required' => true,
90 ],
91 'filter' => [
92 'location' => 'query',
93 'type' => 'string',
94 ],
95 'pageSize' => [
96 'location' => 'query',
97 'type' => 'integer',
98 ],
99 'pageToken' => [
100 'location' => 'query',
101 'type' => 'string',
102 ],
103 ],
104 ],
105 ]
106 ]
107 );
108 $this->projects_locations_secrets = new SecretManager\Resource\ProjectsLocationsSecrets(
109 $this,
110 $this->serviceName,
111 'secrets',
112 [
113 'methods' => [
114 'addVersion' => [
115 'path' => 'v1/{+parent}:addVersion',
116 'httpMethod' => 'POST',
117 'parameters' => [
118 'parent' => [
119 'location' => 'path',
120 'type' => 'string',
121 'required' => true,
122 ],
123 ],
124 ],'create' => [
125 'path' => 'v1/{+parent}/secrets',
126 'httpMethod' => 'POST',
127 'parameters' => [
128 'parent' => [
129 'location' => 'path',
130 'type' => 'string',
131 'required' => true,
132 ],
133 'secretId' => [
134 'location' => 'query',
135 'type' => 'string',
136 ],
137 ],
138 ],'delete' => [
139 'path' => 'v1/{+name}',
140 'httpMethod' => 'DELETE',
141 'parameters' => [
142 'name' => [
143 'location' => 'path',
144 'type' => 'string',
145 'required' => true,
146 ],
147 'etag' => [
148 'location' => 'query',
149 'type' => 'string',
150 ],
151 ],
152 ],'get' => [
153 'path' => 'v1/{+name}',
154 'httpMethod' => 'GET',
155 'parameters' => [
156 'name' => [
157 'location' => 'path',
158 'type' => 'string',
159 'required' => true,
160 ],
161 ],
162 ],'getIamPolicy' => [
163 'path' => 'v1/{+resource}:getIamPolicy',
164 'httpMethod' => 'GET',
165 'parameters' => [
166 'resource' => [
167 'location' => 'path',
168 'type' => 'string',
169 'required' => true,
170 ],
171 'options.requestedPolicyVersion' => [
172 'location' => 'query',
173 'type' => 'integer',
174 ],
175 ],
176 ],'list' => [
177 'path' => 'v1/{+parent}/secrets',
178 'httpMethod' => 'GET',
179 'parameters' => [
180 'parent' => [
181 'location' => 'path',
182 'type' => 'string',
183 'required' => true,
184 ],
185 'filter' => [
186 'location' => 'query',
187 'type' => 'string',
188 ],
189 'pageSize' => [
190 'location' => 'query',
191 'type' => 'integer',
192 ],
193 'pageToken' => [
194 'location' => 'query',
195 'type' => 'string',
196 ],
197 ],
198 ],'patch' => [
199 'path' => 'v1/{+name}',
200 'httpMethod' => 'PATCH',
201 'parameters' => [
202 'name' => [
203 'location' => 'path',
204 'type' => 'string',
205 'required' => true,
206 ],
207 'updateMask' => [
208 'location' => 'query',
209 'type' => 'string',
210 ],
211 ],
212 ],'setIamPolicy' => [
213 'path' => 'v1/{+resource}:setIamPolicy',
214 'httpMethod' => 'POST',
215 'parameters' => [
216 'resource' => [
217 'location' => 'path',
218 'type' => 'string',
219 'required' => true,
220 ],
221 ],
222 ],'testIamPermissions' => [
223 'path' => 'v1/{+resource}:testIamPermissions',
224 'httpMethod' => 'POST',
225 'parameters' => [
226 'resource' => [
227 'location' => 'path',
228 'type' => 'string',
229 'required' => true,
230 ],
231 ],
232 ],
233 ]
234 ]
235 );
236 $this->projects_locations_secrets_versions = new SecretManager\Resource\ProjectsLocationsSecretsVersions(
237 $this,
238 $this->serviceName,
239 'versions',
240 [
241 'methods' => [
242 'access' => [
243 'path' => 'v1/{+name}:access',
244 'httpMethod' => 'GET',
245 'parameters' => [
246 'name' => [
247 'location' => 'path',
248 'type' => 'string',
249 'required' => true,
250 ],
251 ],
252 ],'destroy' => [
253 'path' => 'v1/{+name}:destroy',
254 'httpMethod' => 'POST',
255 'parameters' => [
256 'name' => [
257 'location' => 'path',
258 'type' => 'string',
259 'required' => true,
260 ],
261 ],
262 ],'disable' => [
263 'path' => 'v1/{+name}:disable',
264 'httpMethod' => 'POST',
265 'parameters' => [
266 'name' => [
267 'location' => 'path',
268 'type' => 'string',
269 'required' => true,
270 ],
271 ],
272 ],'enable' => [
273 'path' => 'v1/{+name}:enable',
274 'httpMethod' => 'POST',
275 'parameters' => [
276 'name' => [
277 'location' => 'path',
278 'type' => 'string',
279 'required' => true,
280 ],
281 ],
282 ],'get' => [
283 'path' => 'v1/{+name}',
284 'httpMethod' => 'GET',
285 'parameters' => [
286 'name' => [
287 'location' => 'path',
288 'type' => 'string',
289 'required' => true,
290 ],
291 ],
292 ],'list' => [
293 'path' => 'v1/{+parent}/versions',
294 'httpMethod' => 'GET',
295 'parameters' => [
296 'parent' => [
297 'location' => 'path',
298 'type' => 'string',
299 'required' => true,
300 ],
301 'filter' => [
302 'location' => 'query',
303 'type' => 'string',
304 ],
305 'pageSize' => [
306 'location' => 'query',
307 'type' => 'integer',
308 ],
309 'pageToken' => [
310 'location' => 'query',
311 'type' => 'string',
312 ],
313 ],
314 ],
315 ]
316 ]
317 );
318 $this->projects_secrets = new SecretManager\Resource\ProjectsSecrets(
319 $this,
320 $this->serviceName,
321 'secrets',
322 [
323 'methods' => [
324 'addVersion' => [
325 'path' => 'v1/{+parent}:addVersion',
326 'httpMethod' => 'POST',
327 'parameters' => [
328 'parent' => [
329 'location' => 'path',
330 'type' => 'string',
331 'required' => true,
332 ],
333 ],
334 ],'create' => [
335 'path' => 'v1/{+parent}/secrets',
336 'httpMethod' => 'POST',
337 'parameters' => [
338 'parent' => [
339 'location' => 'path',
340 'type' => 'string',
341 'required' => true,
342 ],
343 'secretId' => [
344 'location' => 'query',
345 'type' => 'string',
346 ],
347 ],
348 ],'delete' => [
349 'path' => 'v1/{+name}',
350 'httpMethod' => 'DELETE',
351 'parameters' => [
352 'name' => [
353 'location' => 'path',
354 'type' => 'string',
355 'required' => true,
356 ],
357 'etag' => [
358 'location' => 'query',
359 'type' => 'string',
360 ],
361 ],
362 ],'get' => [
363 'path' => 'v1/{+name}',
364 'httpMethod' => 'GET',
365 'parameters' => [
366 'name' => [
367 'location' => 'path',
368 'type' => 'string',
369 'required' => true,
370 ],
371 ],
372 ],'getIamPolicy' => [
373 'path' => 'v1/{+resource}:getIamPolicy',
374 'httpMethod' => 'GET',
375 'parameters' => [
376 'resource' => [
377 'location' => 'path',
378 'type' => 'string',
379 'required' => true,
380 ],
381 'options.requestedPolicyVersion' => [
382 'location' => 'query',
383 'type' => 'integer',
384 ],
385 ],
386 ],'list' => [
387 'path' => 'v1/{+parent}/secrets',
388 'httpMethod' => 'GET',
389 'parameters' => [
390 'parent' => [
391 'location' => 'path',
392 'type' => 'string',
393 'required' => true,
394 ],
395 'filter' => [
396 'location' => 'query',
397 'type' => 'string',
398 ],
399 'pageSize' => [
400 'location' => 'query',
401 'type' => 'integer',
402 ],
403 'pageToken' => [
404 'location' => 'query',
405 'type' => 'string',
406 ],
407 ],
408 ],'patch' => [
409 'path' => 'v1/{+name}',
410 'httpMethod' => 'PATCH',
411 'parameters' => [
412 'name' => [
413 'location' => 'path',
414 'type' => 'string',
415 'required' => true,
416 ],
417 'updateMask' => [
418 'location' => 'query',
419 'type' => 'string',
420 ],
421 ],
422 ],'setIamPolicy' => [
423 'path' => 'v1/{+resource}:setIamPolicy',
424 'httpMethod' => 'POST',
425 'parameters' => [
426 'resource' => [
427 'location' => 'path',
428 'type' => 'string',
429 'required' => true,
430 ],
431 ],
432 ],'testIamPermissions' => [
433 'path' => 'v1/{+resource}:testIamPermissions',
434 'httpMethod' => 'POST',
435 'parameters' => [
436 'resource' => [
437 'location' => 'path',
438 'type' => 'string',
439 'required' => true,
440 ],
441 ],
442 ],
443 ]
444 ]
445 );
446 $this->projects_secrets_versions = new SecretManager\Resource\ProjectsSecretsVersions(
447 $this,
448 $this->serviceName,
449 'versions',
450 [
451 'methods' => [
452 'access' => [
453 'path' => 'v1/{+name}:access',
454 'httpMethod' => 'GET',
455 'parameters' => [
456 'name' => [
457 'location' => 'path',
458 'type' => 'string',
459 'required' => true,
460 ],
461 ],
462 ],'destroy' => [
463 'path' => 'v1/{+name}:destroy',
464 'httpMethod' => 'POST',
465 'parameters' => [
466 'name' => [
467 'location' => 'path',
468 'type' => 'string',
469 'required' => true,
470 ],
471 ],
472 ],'disable' => [
473 'path' => 'v1/{+name}:disable',
474 'httpMethod' => 'POST',
475 'parameters' => [
476 'name' => [
477 'location' => 'path',
478 'type' => 'string',
479 'required' => true,
480 ],
481 ],
482 ],'enable' => [
483 'path' => 'v1/{+name}:enable',
484 'httpMethod' => 'POST',
485 'parameters' => [
486 'name' => [
487 'location' => 'path',
488 'type' => 'string',
489 'required' => true,
490 ],
491 ],
492 ],'get' => [
493 'path' => 'v1/{+name}',
494 'httpMethod' => 'GET',
495 'parameters' => [
496 'name' => [
497 'location' => 'path',
498 'type' => 'string',
499 'required' => true,
500 ],
501 ],
502 ],'list' => [
503 'path' => 'v1/{+parent}/versions',
504 'httpMethod' => 'GET',
505 'parameters' => [
506 'parent' => [
507 'location' => 'path',
508 'type' => 'string',
509 'required' => true,
510 ],
511 'filter' => [
512 'location' => 'query',
513 'type' => 'string',
514 ],
515 'pageSize' => [
516 'location' => 'query',
517 'type' => 'integer',
518 ],
519 'pageToken' => [
520 'location' => 'query',
521 'type' => 'string',
522 ],
523 ],
524 ],
525 ]
526 ]
527 );
528 }
529}
530
531// Adding a class alias for backwards compatibility with the previous class name.
532class_alias(SecretManager::class, 'Google_Service_SecretManager');
Note: See TracBrowser for help on using the repository browser.