source: vendor/google/apiclient-services/src/ApiKeysService.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: 6.5 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 ApiKeysService (v2).
24 *
25 * <p>
26 * Manages the API keys associated with developer projects.</p>
27 *
28 * <p>
29 * For more information about this service, see the API
30 * <a href="https://cloud.google.com/api-keys/docs" target="_blank">Documentation</a>
31 * </p>
32 *
33 * @author Google, Inc.
34 */
35class ApiKeysService extends \Google\Service
36{
37 /** See, edit, configure, and delete your Google Cloud data and see the email address for your Google Account.. */
38 const CLOUD_PLATFORM =
39 "https://www.googleapis.com/auth/cloud-platform";
40 /** View your data across Google Cloud services and see the email address of your Google Account. */
41 const CLOUD_PLATFORM_READ_ONLY =
42 "https://www.googleapis.com/auth/cloud-platform.read-only";
43
44 public $keys;
45 public $operations;
46 public $projects_locations_keys;
47 public $rootUrlTemplate;
48
49 /**
50 * Constructs the internal representation of the ApiKeysService 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://apikeys.googleapis.com/';
60 $this->rootUrlTemplate = $rootUrl ?: 'https://apikeys.UNIVERSE_DOMAIN/';
61 $this->servicePath = '';
62 $this->batchPath = 'batch';
63 $this->version = 'v2';
64 $this->serviceName = 'apikeys';
65
66 $this->keys = new ApiKeysService\Resource\Keys(
67 $this,
68 $this->serviceName,
69 'keys',
70 [
71 'methods' => [
72 'lookupKey' => [
73 'path' => 'v2/keys:lookupKey',
74 'httpMethod' => 'GET',
75 'parameters' => [
76 'keyString' => [
77 'location' => 'query',
78 'type' => 'string',
79 ],
80 ],
81 ],
82 ]
83 ]
84 );
85 $this->operations = new ApiKeysService\Resource\Operations(
86 $this,
87 $this->serviceName,
88 'operations',
89 [
90 'methods' => [
91 'get' => [
92 'path' => 'v2/{+name}',
93 'httpMethod' => 'GET',
94 'parameters' => [
95 'name' => [
96 'location' => 'path',
97 'type' => 'string',
98 'required' => true,
99 ],
100 ],
101 ],
102 ]
103 ]
104 );
105 $this->projects_locations_keys = new ApiKeysService\Resource\ProjectsLocationsKeys(
106 $this,
107 $this->serviceName,
108 'keys',
109 [
110 'methods' => [
111 'create' => [
112 'path' => 'v2/{+parent}/keys',
113 'httpMethod' => 'POST',
114 'parameters' => [
115 'parent' => [
116 'location' => 'path',
117 'type' => 'string',
118 'required' => true,
119 ],
120 'keyId' => [
121 'location' => 'query',
122 'type' => 'string',
123 ],
124 ],
125 ],'delete' => [
126 'path' => 'v2/{+name}',
127 'httpMethod' => 'DELETE',
128 'parameters' => [
129 'name' => [
130 'location' => 'path',
131 'type' => 'string',
132 'required' => true,
133 ],
134 'etag' => [
135 'location' => 'query',
136 'type' => 'string',
137 ],
138 ],
139 ],'get' => [
140 'path' => 'v2/{+name}',
141 'httpMethod' => 'GET',
142 'parameters' => [
143 'name' => [
144 'location' => 'path',
145 'type' => 'string',
146 'required' => true,
147 ],
148 ],
149 ],'getKeyString' => [
150 'path' => 'v2/{+name}/keyString',
151 'httpMethod' => 'GET',
152 'parameters' => [
153 'name' => [
154 'location' => 'path',
155 'type' => 'string',
156 'required' => true,
157 ],
158 ],
159 ],'list' => [
160 'path' => 'v2/{+parent}/keys',
161 'httpMethod' => 'GET',
162 'parameters' => [
163 'parent' => [
164 'location' => 'path',
165 'type' => 'string',
166 'required' => true,
167 ],
168 'pageSize' => [
169 'location' => 'query',
170 'type' => 'integer',
171 ],
172 'pageToken' => [
173 'location' => 'query',
174 'type' => 'string',
175 ],
176 'showDeleted' => [
177 'location' => 'query',
178 'type' => 'boolean',
179 ],
180 ],
181 ],'patch' => [
182 'path' => 'v2/{+name}',
183 'httpMethod' => 'PATCH',
184 'parameters' => [
185 'name' => [
186 'location' => 'path',
187 'type' => 'string',
188 'required' => true,
189 ],
190 'updateMask' => [
191 'location' => 'query',
192 'type' => 'string',
193 ],
194 ],
195 ],'undelete' => [
196 'path' => 'v2/{+name}:undelete',
197 'httpMethod' => 'POST',
198 'parameters' => [
199 'name' => [
200 'location' => 'path',
201 'type' => 'string',
202 'required' => true,
203 ],
204 ],
205 ],
206 ]
207 ]
208 );
209 }
210}
211
212// Adding a class alias for backwards compatibility with the previous class name.
213class_alias(ApiKeysService::class, 'Google_Service_ApiKeysService');
Note: See TracBrowser for help on using the repository browser.