blob: 4e6788701ba9c3597efc40461f9fce5e8b06152c [file] [log] [blame]
Craig Citro065b5302014-08-14 00:47:23 -07001<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13}
14
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54 margin-top: 0.5em;
55}
56
57.firstline {
58 margin-left: 2 em;
59}
60
61.method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66}
67
68.details {
69 font-weight: bold;
70 font-size: 14px;
71}
72
73</style>
74
75<h1><a href="compute_v1.html">Compute Engine API</a> . <a href="compute_v1.urlMaps.html">urlMaps</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
78 <code><a href="#delete">delete(project, urlMap)</a></code></p>
79<p class="firstline">Deletes the specified UrlMap resource.</p>
80<p class="toc_element">
81 <code><a href="#get">get(project, urlMap)</a></code></p>
82<p class="firstline">Returns the specified UrlMap resource.</p>
83<p class="toc_element">
84 <code><a href="#insert">insert(project, body)</a></code></p>
85<p class="firstline">Creates a UrlMap resource in the specified project using the data included in the request.</p>
86<p class="toc_element">
87 <code><a href="#list">list(project, maxResults=None, pageToken=None, filter=None)</a></code></p>
88<p class="firstline">Retrieves the list of UrlMap resources available to the specified project.</p>
89<p class="toc_element">
90 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
91<p class="firstline">Retrieves the next page of results.</p>
92<p class="toc_element">
93 <code><a href="#patch">patch(project, urlMap, body)</a></code></p>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -080094<p class="firstline">Updates the entire content of the UrlMap resource. This method supports patch semantics.</p>
Craig Citro065b5302014-08-14 00:47:23 -070095<p class="toc_element">
96 <code><a href="#update">update(project, urlMap, body)</a></code></p>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -080097<p class="firstline">Updates the entire content of the UrlMap resource.</p>
Craig Citro065b5302014-08-14 00:47:23 -070098<p class="toc_element">
99 <code><a href="#validate">validate(project, urlMap, body)</a></code></p>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800100<p class="firstline">Runs static validation for the UrlMap. In particular, the tests of the provided UrlMap will be run. Calling this method does NOT create the UrlMap.</p>
Craig Citro065b5302014-08-14 00:47:23 -0700101<h3>Method Details</h3>
102<div class="method">
103 <code class="details" id="delete">delete(project, urlMap)</code>
104 <pre>Deletes the specified UrlMap resource.
105
106Args:
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800107 project: string, Project ID for this request. (required)
Craig Citro065b5302014-08-14 00:47:23 -0700108 urlMap: string, Name of the UrlMap resource to delete. (required)
109
110Returns:
111 An object of the form:
112
Takashi Matsuo06694102015-09-11 13:55:40 -0700113 { # An Operation resource, used to manage asynchronous API requests.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800114 "targetId": "A String", # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource.
115 "clientOperationId": "A String", # [Output Only] Reserved for future use.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000116 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800117 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
118 "zone": "A String", # [Output Only] The URL of the zone where the operation resides. Only available when performing per-zone operations.
119 "insertTime": "A String", # [Output Only] The time that this operation was requested. This value is in RFC3339 text format.
120 "operationType": "A String", # [Output Only] The type of operation, such as insert, update, or delete, and so on.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000121 "httpErrorMessage": "A String", # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800122 "progress": 42, # [Output Only] An optional progress indicator that ranges from 0 to 100. There is no requirement that this be linear or support any granularity of operations. This should not be used to guess when the operation will be complete. This number should monotonically increase as the operation progresses.
123 "httpErrorStatusCode": 42, # [Output Only] If the operation fails, this field contains the HTTP error status code that was returned. For example, a 404 means the resource was not found.
Craig Citroe633be12015-03-02 13:40:36 -0800124 "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800125 "status": "A String", # [Output Only] The status of the operation, which can be one of the following: PENDING, RUNNING, or DONE.
126 "description": "A String", # [Output Only] A textual description of the operation, which is set when the operation is created.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000127 "warnings": [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated.
Craig Citro065b5302014-08-14 00:47:23 -0700128 {
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800129 "message": "A String", # [Output Only] A human-readable description of the warning code.
130 "code": "A String", # [Output Only] A warning code, if applicable. For example, Compute Engine returns NO_RESULTS_ON_PAGE if there are no results in the response.
131 "data": [ # [Output Only] Metadata about this warning in key: value format. For example:
132 # "data": [ { "key": "scope", "value": "zones/us-east1-d" }
Craig Citro065b5302014-08-14 00:47:23 -0700133 {
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000134 "value": "A String", # [Output Only] A warning data value corresponding to the key.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800135 "key": "A String", # [Output Only] A key that provides more detail on the warning being returned. For example, for warnings where there are no results in a list request for a particular zone, this key might be scope and the key value might be the zone name. Other examples might be a key indicating a deprecated resource, and a suggested replacement, or a warning about invalid network settings (for example, if an instance attempts to perform IP forwarding but is not enabled for IP forwarding).
Craig Citro065b5302014-08-14 00:47:23 -0700136 },
137 ],
138 },
139 ],
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000140 "user": "A String", # [Output Only] User who requested the operation, for example: user@example.com.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800141 "startTime": "A String", # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format.
142 "kind": "compute#operation", # [Output Only] Type of the resource. Always compute#operation for Operation resources.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000143 "name": "A String", # [Output Only] Name of the resource.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800144 "region": "A String", # [Output Only] The URL of the region where the operation resides. Only available when performing regional operations.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000145 "error": { # [Output Only] If errors are generated during processing of the operation, this field will be populated.
Craig Citroe633be12015-03-02 13:40:36 -0800146 "errors": [ # [Output Only] The array of errors encountered while processing this operation.
Craig Citro065b5302014-08-14 00:47:23 -0700147 {
Craig Citroe633be12015-03-02 13:40:36 -0800148 "message": "A String", # [Output Only] An optional, human-readable error message.
149 "code": "A String", # [Output Only] The error type identifier for this error.
150 "location": "A String", # [Output Only] Indicates the field in the request which caused the error. This property is optional.
Craig Citro065b5302014-08-14 00:47:23 -0700151 },
152 ],
153 },
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800154 "endTime": "A String", # [Output Only] The time that this operation was completed. This value is in RFC3339 text format.
Takashi Matsuo06694102015-09-11 13:55:40 -0700155 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800156 "targetLink": "A String", # [Output Only] The URL of the resource that the operation modifies.
Craig Citro065b5302014-08-14 00:47:23 -0700157 }</pre>
158</div>
159
160<div class="method">
161 <code class="details" id="get">get(project, urlMap)</code>
162 <pre>Returns the specified UrlMap resource.
163
164Args:
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800165 project: string, Project ID for this request. (required)
Craig Citro065b5302014-08-14 00:47:23 -0700166 urlMap: string, Name of the UrlMap resource to return. (required)
167
168Returns:
169 An object of the form:
170
171 { # A UrlMap resource. This resource defines the mapping from URL to the BackendService resource, based on the "longest-match" of the URL's host and path.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800172 "kind": "compute#urlMap", # [Output Only] Type of the resource. Always compute#urlMaps for url maps.
173 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700174 "defaultService": "A String", # The URL of the BackendService resource if none of the hostRules match.
175 "tests": [ # The list of expected URL mappings. Request to update this UrlMap will succeed only all of the test cases pass.
176 { # Message for the expected URL mappings.
177 "path": "A String", # Path portion of the URL.
178 "host": "A String", # Host portion of the URL.
179 "description": "A String", # Description of this test case.
180 "service": "A String", # Expected BackendService resource the given URL should be mapped to.
181 },
182 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700183 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700184 "fingerprint": "A String", # Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a UrlMap. An up-to-date fingerprint must be provided in order to update the UrlMap.
185 "pathMatchers": [ # The list of named PathMatchers to use against the URL.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800186 { # A matcher for the path portion of the URL. The BackendService from the longest-matched rule will serve the URL. If no rule was matched, the default service will be used.
187 "defaultService": "A String", # The full or partial URL to the BackendService resource. This will be used if none of the pathRules defined by this PathMatcher is matched by the URL's path portion. For example, the following are all valid URLs to a BackendService resource:
188 # - https://www.googleapis.com/compute/v1/projects/project/global/backendServices/backendService
189 # - compute/v1/projects/project/global/backendServices/backendService
190 # - global/backendServices/backendService
Craig Citro065b5302014-08-14 00:47:23 -0700191 "pathRules": [ # The list of path rules.
192 { # A path-matching rule for a URL. If matched, will use the specified BackendService to handle the traffic arriving at this URL.
193 "paths": [ # The list of path patterns to match. Each must start with / and the only place a * is allowed is at the end following a /. The string fed to the path matcher does not include any text after the first ? or #, and those chars are not allowed here.
194 "A String",
195 ],
196 "service": "A String", # The URL of the BackendService resource if this rule is matched.
197 },
198 ],
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800199 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700200 "name": "A String", # The name to which this PathMatcher is referred by the HostRule.
201 },
202 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700203 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800204 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
Craig Citro065b5302014-08-14 00:47:23 -0700205 "hostRules": [ # The list of HostRules to use against the URL.
Takashi Matsuo06694102015-09-11 13:55:40 -0700206 { # UrlMaps A host-matching rule for a URL. If matched, will use the named PathMatcher to select the BackendService.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800207 "hosts": [ # The list of host patterns to match. They must be valid hostnames, except * will match any string of ([a-z0-9-.]*). In that case, * must be the first character and must be followed in the pattern by either - or ..
Craig Citro065b5302014-08-14 00:47:23 -0700208 "A String",
209 ],
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800210 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
211 "pathMatcher": "A String", # The name of the PathMatcher to use to match the path portion of the URL if the hostRule matches the URL's host portion.
Craig Citro065b5302014-08-14 00:47:23 -0700212 },
213 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700214 "name": "A String", # Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression [a-z]([-a-z0-9]*[a-z0-9])? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
Craig Citro065b5302014-08-14 00:47:23 -0700215 }</pre>
216</div>
217
218<div class="method">
219 <code class="details" id="insert">insert(project, body)</code>
220 <pre>Creates a UrlMap resource in the specified project using the data included in the request.
221
222Args:
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800223 project: string, Project ID for this request. (required)
Craig Citro065b5302014-08-14 00:47:23 -0700224 body: object, The request body. (required)
225 The object takes the form of:
226
227{ # A UrlMap resource. This resource defines the mapping from URL to the BackendService resource, based on the "longest-match" of the URL's host and path.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800228 "kind": "compute#urlMap", # [Output Only] Type of the resource. Always compute#urlMaps for url maps.
229 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700230 "defaultService": "A String", # The URL of the BackendService resource if none of the hostRules match.
231 "tests": [ # The list of expected URL mappings. Request to update this UrlMap will succeed only all of the test cases pass.
232 { # Message for the expected URL mappings.
233 "path": "A String", # Path portion of the URL.
234 "host": "A String", # Host portion of the URL.
235 "description": "A String", # Description of this test case.
236 "service": "A String", # Expected BackendService resource the given URL should be mapped to.
237 },
238 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700239 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700240 "fingerprint": "A String", # Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a UrlMap. An up-to-date fingerprint must be provided in order to update the UrlMap.
241 "pathMatchers": [ # The list of named PathMatchers to use against the URL.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800242 { # A matcher for the path portion of the URL. The BackendService from the longest-matched rule will serve the URL. If no rule was matched, the default service will be used.
243 "defaultService": "A String", # The full or partial URL to the BackendService resource. This will be used if none of the pathRules defined by this PathMatcher is matched by the URL's path portion. For example, the following are all valid URLs to a BackendService resource:
244 # - https://www.googleapis.com/compute/v1/projects/project/global/backendServices/backendService
245 # - compute/v1/projects/project/global/backendServices/backendService
246 # - global/backendServices/backendService
Craig Citro065b5302014-08-14 00:47:23 -0700247 "pathRules": [ # The list of path rules.
248 { # A path-matching rule for a URL. If matched, will use the specified BackendService to handle the traffic arriving at this URL.
249 "paths": [ # The list of path patterns to match. Each must start with / and the only place a * is allowed is at the end following a /. The string fed to the path matcher does not include any text after the first ? or #, and those chars are not allowed here.
250 "A String",
251 ],
252 "service": "A String", # The URL of the BackendService resource if this rule is matched.
253 },
254 ],
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800255 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700256 "name": "A String", # The name to which this PathMatcher is referred by the HostRule.
257 },
258 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700259 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800260 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
Craig Citro065b5302014-08-14 00:47:23 -0700261 "hostRules": [ # The list of HostRules to use against the URL.
Takashi Matsuo06694102015-09-11 13:55:40 -0700262 { # UrlMaps A host-matching rule for a URL. If matched, will use the named PathMatcher to select the BackendService.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800263 "hosts": [ # The list of host patterns to match. They must be valid hostnames, except * will match any string of ([a-z0-9-.]*). In that case, * must be the first character and must be followed in the pattern by either - or ..
Craig Citro065b5302014-08-14 00:47:23 -0700264 "A String",
265 ],
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800266 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
267 "pathMatcher": "A String", # The name of the PathMatcher to use to match the path portion of the URL if the hostRule matches the URL's host portion.
Craig Citro065b5302014-08-14 00:47:23 -0700268 },
269 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700270 "name": "A String", # Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression [a-z]([-a-z0-9]*[a-z0-9])? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
Craig Citro065b5302014-08-14 00:47:23 -0700271 }
272
273
274Returns:
275 An object of the form:
276
Takashi Matsuo06694102015-09-11 13:55:40 -0700277 { # An Operation resource, used to manage asynchronous API requests.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800278 "targetId": "A String", # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource.
279 "clientOperationId": "A String", # [Output Only] Reserved for future use.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000280 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800281 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
282 "zone": "A String", # [Output Only] The URL of the zone where the operation resides. Only available when performing per-zone operations.
283 "insertTime": "A String", # [Output Only] The time that this operation was requested. This value is in RFC3339 text format.
284 "operationType": "A String", # [Output Only] The type of operation, such as insert, update, or delete, and so on.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000285 "httpErrorMessage": "A String", # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800286 "progress": 42, # [Output Only] An optional progress indicator that ranges from 0 to 100. There is no requirement that this be linear or support any granularity of operations. This should not be used to guess when the operation will be complete. This number should monotonically increase as the operation progresses.
287 "httpErrorStatusCode": 42, # [Output Only] If the operation fails, this field contains the HTTP error status code that was returned. For example, a 404 means the resource was not found.
Craig Citroe633be12015-03-02 13:40:36 -0800288 "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800289 "status": "A String", # [Output Only] The status of the operation, which can be one of the following: PENDING, RUNNING, or DONE.
290 "description": "A String", # [Output Only] A textual description of the operation, which is set when the operation is created.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000291 "warnings": [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated.
Craig Citro065b5302014-08-14 00:47:23 -0700292 {
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800293 "message": "A String", # [Output Only] A human-readable description of the warning code.
294 "code": "A String", # [Output Only] A warning code, if applicable. For example, Compute Engine returns NO_RESULTS_ON_PAGE if there are no results in the response.
295 "data": [ # [Output Only] Metadata about this warning in key: value format. For example:
296 # "data": [ { "key": "scope", "value": "zones/us-east1-d" }
Craig Citro065b5302014-08-14 00:47:23 -0700297 {
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000298 "value": "A String", # [Output Only] A warning data value corresponding to the key.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800299 "key": "A String", # [Output Only] A key that provides more detail on the warning being returned. For example, for warnings where there are no results in a list request for a particular zone, this key might be scope and the key value might be the zone name. Other examples might be a key indicating a deprecated resource, and a suggested replacement, or a warning about invalid network settings (for example, if an instance attempts to perform IP forwarding but is not enabled for IP forwarding).
Craig Citro065b5302014-08-14 00:47:23 -0700300 },
301 ],
302 },
303 ],
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000304 "user": "A String", # [Output Only] User who requested the operation, for example: user@example.com.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800305 "startTime": "A String", # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format.
306 "kind": "compute#operation", # [Output Only] Type of the resource. Always compute#operation for Operation resources.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000307 "name": "A String", # [Output Only] Name of the resource.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800308 "region": "A String", # [Output Only] The URL of the region where the operation resides. Only available when performing regional operations.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000309 "error": { # [Output Only] If errors are generated during processing of the operation, this field will be populated.
Craig Citroe633be12015-03-02 13:40:36 -0800310 "errors": [ # [Output Only] The array of errors encountered while processing this operation.
Craig Citro065b5302014-08-14 00:47:23 -0700311 {
Craig Citroe633be12015-03-02 13:40:36 -0800312 "message": "A String", # [Output Only] An optional, human-readable error message.
313 "code": "A String", # [Output Only] The error type identifier for this error.
314 "location": "A String", # [Output Only] Indicates the field in the request which caused the error. This property is optional.
Craig Citro065b5302014-08-14 00:47:23 -0700315 },
316 ],
317 },
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800318 "endTime": "A String", # [Output Only] The time that this operation was completed. This value is in RFC3339 text format.
Takashi Matsuo06694102015-09-11 13:55:40 -0700319 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800320 "targetLink": "A String", # [Output Only] The URL of the resource that the operation modifies.
Craig Citro065b5302014-08-14 00:47:23 -0700321 }</pre>
322</div>
323
324<div class="method">
325 <code class="details" id="list">list(project, maxResults=None, pageToken=None, filter=None)</code>
326 <pre>Retrieves the list of UrlMap resources available to the specified project.
327
328Args:
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800329 project: string, Project ID for this request. (required)
330 maxResults: integer, The maximum number of results per page that should be returned. If the number of available results is larger than maxResults, Compute Engine returns a nextPageToken that can be used to get the next page of results in subsequent list requests.
331 pageToken: string, Specifies a page token to use. Set pageToken to the nextPageToken returned by a previous list request to get the next page of results.
332 filter: string, Sets a filter expression for filtering listed resources, in the form filter={expression}. Your {expression} must be in the format: field_name comparison_string literal_string.
Takashi Matsuo06694102015-09-11 13:55:40 -0700333
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800334The field_name is the name of the field you want to compare. Only atomic field types are supported (string, number, boolean). The comparison_string must be either eq (equals) or ne (not equals). The literal_string is the string value to filter to. The literal value must be valid for the type of field you are filtering by (string, number, boolean). For string fields, the literal value is interpreted as a regular expression using RE2 syntax. The literal value must match the entire field.
Takashi Matsuo06694102015-09-11 13:55:40 -0700335
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800336For example, to filter for instances whose name is not equal to example-instance, you would use filter=name ne example-instance.
337
338Compute Engine Beta API Only: If you use filtering in the Beta API, you can also filter on nested fields. For example, you could filter on instances that have set the scheduling.automaticRestart field to true. In particular, use filtering on nested fields to take advantage of instance labels to organize and filter results based on label values.
339
340The Beta API also supports filtering on multiple expressions by providing each separate expression within parentheses. For example, (scheduling.automaticRestart eq true) (zone eq us-central1-f). Multiple expressions are treated as AND expressions meaning that resources must match all expressions to pass the filters.
Craig Citro065b5302014-08-14 00:47:23 -0700341
342Returns:
343 An object of the form:
344
345 { # Contains a list of UrlMap resources.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800346 "nextPageToken": "A String", # [Output Only] This token allows you to get the next page of results for list requests. If the number of results is larger than maxResults, use the nextPageToken as a value for the query parameter pageToken in the next list request. Subsequent list requests will have their own nextPageToken to continue paging through the results.
Craig Citroe633be12015-03-02 13:40:36 -0800347 "items": [ # A list of UrlMap resources.
Craig Citro065b5302014-08-14 00:47:23 -0700348 { # A UrlMap resource. This resource defines the mapping from URL to the BackendService resource, based on the "longest-match" of the URL's host and path.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800349 "kind": "compute#urlMap", # [Output Only] Type of the resource. Always compute#urlMaps for url maps.
350 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700351 "defaultService": "A String", # The URL of the BackendService resource if none of the hostRules match.
352 "tests": [ # The list of expected URL mappings. Request to update this UrlMap will succeed only all of the test cases pass.
353 { # Message for the expected URL mappings.
354 "path": "A String", # Path portion of the URL.
355 "host": "A String", # Host portion of the URL.
356 "description": "A String", # Description of this test case.
357 "service": "A String", # Expected BackendService resource the given URL should be mapped to.
358 },
359 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700360 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700361 "fingerprint": "A String", # Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a UrlMap. An up-to-date fingerprint must be provided in order to update the UrlMap.
362 "pathMatchers": [ # The list of named PathMatchers to use against the URL.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800363 { # A matcher for the path portion of the URL. The BackendService from the longest-matched rule will serve the URL. If no rule was matched, the default service will be used.
364 "defaultService": "A String", # The full or partial URL to the BackendService resource. This will be used if none of the pathRules defined by this PathMatcher is matched by the URL's path portion. For example, the following are all valid URLs to a BackendService resource:
365 # - https://www.googleapis.com/compute/v1/projects/project/global/backendServices/backendService
366 # - compute/v1/projects/project/global/backendServices/backendService
367 # - global/backendServices/backendService
Craig Citro065b5302014-08-14 00:47:23 -0700368 "pathRules": [ # The list of path rules.
369 { # A path-matching rule for a URL. If matched, will use the specified BackendService to handle the traffic arriving at this URL.
370 "paths": [ # The list of path patterns to match. Each must start with / and the only place a * is allowed is at the end following a /. The string fed to the path matcher does not include any text after the first ? or #, and those chars are not allowed here.
371 "A String",
372 ],
373 "service": "A String", # The URL of the BackendService resource if this rule is matched.
374 },
375 ],
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800376 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700377 "name": "A String", # The name to which this PathMatcher is referred by the HostRule.
378 },
379 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700380 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800381 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
Craig Citro065b5302014-08-14 00:47:23 -0700382 "hostRules": [ # The list of HostRules to use against the URL.
Takashi Matsuo06694102015-09-11 13:55:40 -0700383 { # UrlMaps A host-matching rule for a URL. If matched, will use the named PathMatcher to select the BackendService.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800384 "hosts": [ # The list of host patterns to match. They must be valid hostnames, except * will match any string of ([a-z0-9-.]*). In that case, * must be the first character and must be followed in the pattern by either - or ..
Craig Citro065b5302014-08-14 00:47:23 -0700385 "A String",
386 ],
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800387 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
388 "pathMatcher": "A String", # The name of the PathMatcher to use to match the path portion of the URL if the hostRule matches the URL's host portion.
Craig Citro065b5302014-08-14 00:47:23 -0700389 },
390 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700391 "name": "A String", # Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression [a-z]([-a-z0-9]*[a-z0-9])? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
Craig Citro065b5302014-08-14 00:47:23 -0700392 },
393 ],
394 "kind": "compute#urlMapList", # Type of resource.
Takashi Matsuo06694102015-09-11 13:55:40 -0700395 "id": "A String", # [Output Only] Unique identifier for the resource. Set by the server.
396 "selfLink": "A String", # [Output Only] Server-defined URL for this resource.
Craig Citro065b5302014-08-14 00:47:23 -0700397 }</pre>
398</div>
399
400<div class="method">
401 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
402 <pre>Retrieves the next page of results.
403
404Args:
405 previous_request: The request for the previous page. (required)
406 previous_response: The response from the request for the previous page. (required)
407
408Returns:
409 A request object that you can call 'execute()' on to request the next
410 page. Returns None if there are no more items in the collection.
411 </pre>
412</div>
413
414<div class="method">
415 <code class="details" id="patch">patch(project, urlMap, body)</code>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800416 <pre>Updates the entire content of the UrlMap resource. This method supports patch semantics.
Craig Citro065b5302014-08-14 00:47:23 -0700417
418Args:
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800419 project: string, Project ID for this request. (required)
Craig Citro065b5302014-08-14 00:47:23 -0700420 urlMap: string, Name of the UrlMap resource to update. (required)
421 body: object, The request body. (required)
422 The object takes the form of:
423
424{ # A UrlMap resource. This resource defines the mapping from URL to the BackendService resource, based on the "longest-match" of the URL's host and path.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800425 "kind": "compute#urlMap", # [Output Only] Type of the resource. Always compute#urlMaps for url maps.
426 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700427 "defaultService": "A String", # The URL of the BackendService resource if none of the hostRules match.
428 "tests": [ # The list of expected URL mappings. Request to update this UrlMap will succeed only all of the test cases pass.
429 { # Message for the expected URL mappings.
430 "path": "A String", # Path portion of the URL.
431 "host": "A String", # Host portion of the URL.
432 "description": "A String", # Description of this test case.
433 "service": "A String", # Expected BackendService resource the given URL should be mapped to.
434 },
435 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700436 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700437 "fingerprint": "A String", # Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a UrlMap. An up-to-date fingerprint must be provided in order to update the UrlMap.
438 "pathMatchers": [ # The list of named PathMatchers to use against the URL.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800439 { # A matcher for the path portion of the URL. The BackendService from the longest-matched rule will serve the URL. If no rule was matched, the default service will be used.
440 "defaultService": "A String", # The full or partial URL to the BackendService resource. This will be used if none of the pathRules defined by this PathMatcher is matched by the URL's path portion. For example, the following are all valid URLs to a BackendService resource:
441 # - https://www.googleapis.com/compute/v1/projects/project/global/backendServices/backendService
442 # - compute/v1/projects/project/global/backendServices/backendService
443 # - global/backendServices/backendService
Craig Citro065b5302014-08-14 00:47:23 -0700444 "pathRules": [ # The list of path rules.
445 { # A path-matching rule for a URL. If matched, will use the specified BackendService to handle the traffic arriving at this URL.
446 "paths": [ # The list of path patterns to match. Each must start with / and the only place a * is allowed is at the end following a /. The string fed to the path matcher does not include any text after the first ? or #, and those chars are not allowed here.
447 "A String",
448 ],
449 "service": "A String", # The URL of the BackendService resource if this rule is matched.
450 },
451 ],
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800452 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700453 "name": "A String", # The name to which this PathMatcher is referred by the HostRule.
454 },
455 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700456 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800457 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
Craig Citro065b5302014-08-14 00:47:23 -0700458 "hostRules": [ # The list of HostRules to use against the URL.
Takashi Matsuo06694102015-09-11 13:55:40 -0700459 { # UrlMaps A host-matching rule for a URL. If matched, will use the named PathMatcher to select the BackendService.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800460 "hosts": [ # The list of host patterns to match. They must be valid hostnames, except * will match any string of ([a-z0-9-.]*). In that case, * must be the first character and must be followed in the pattern by either - or ..
Craig Citro065b5302014-08-14 00:47:23 -0700461 "A String",
462 ],
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800463 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
464 "pathMatcher": "A String", # The name of the PathMatcher to use to match the path portion of the URL if the hostRule matches the URL's host portion.
Craig Citro065b5302014-08-14 00:47:23 -0700465 },
466 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700467 "name": "A String", # Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression [a-z]([-a-z0-9]*[a-z0-9])? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
Craig Citro065b5302014-08-14 00:47:23 -0700468 }
469
470
471Returns:
472 An object of the form:
473
Takashi Matsuo06694102015-09-11 13:55:40 -0700474 { # An Operation resource, used to manage asynchronous API requests.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800475 "targetId": "A String", # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource.
476 "clientOperationId": "A String", # [Output Only] Reserved for future use.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000477 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800478 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
479 "zone": "A String", # [Output Only] The URL of the zone where the operation resides. Only available when performing per-zone operations.
480 "insertTime": "A String", # [Output Only] The time that this operation was requested. This value is in RFC3339 text format.
481 "operationType": "A String", # [Output Only] The type of operation, such as insert, update, or delete, and so on.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000482 "httpErrorMessage": "A String", # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800483 "progress": 42, # [Output Only] An optional progress indicator that ranges from 0 to 100. There is no requirement that this be linear or support any granularity of operations. This should not be used to guess when the operation will be complete. This number should monotonically increase as the operation progresses.
484 "httpErrorStatusCode": 42, # [Output Only] If the operation fails, this field contains the HTTP error status code that was returned. For example, a 404 means the resource was not found.
Craig Citroe633be12015-03-02 13:40:36 -0800485 "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800486 "status": "A String", # [Output Only] The status of the operation, which can be one of the following: PENDING, RUNNING, or DONE.
487 "description": "A String", # [Output Only] A textual description of the operation, which is set when the operation is created.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000488 "warnings": [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated.
Craig Citro065b5302014-08-14 00:47:23 -0700489 {
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800490 "message": "A String", # [Output Only] A human-readable description of the warning code.
491 "code": "A String", # [Output Only] A warning code, if applicable. For example, Compute Engine returns NO_RESULTS_ON_PAGE if there are no results in the response.
492 "data": [ # [Output Only] Metadata about this warning in key: value format. For example:
493 # "data": [ { "key": "scope", "value": "zones/us-east1-d" }
Craig Citro065b5302014-08-14 00:47:23 -0700494 {
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000495 "value": "A String", # [Output Only] A warning data value corresponding to the key.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800496 "key": "A String", # [Output Only] A key that provides more detail on the warning being returned. For example, for warnings where there are no results in a list request for a particular zone, this key might be scope and the key value might be the zone name. Other examples might be a key indicating a deprecated resource, and a suggested replacement, or a warning about invalid network settings (for example, if an instance attempts to perform IP forwarding but is not enabled for IP forwarding).
Craig Citro065b5302014-08-14 00:47:23 -0700497 },
498 ],
499 },
500 ],
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000501 "user": "A String", # [Output Only] User who requested the operation, for example: user@example.com.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800502 "startTime": "A String", # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format.
503 "kind": "compute#operation", # [Output Only] Type of the resource. Always compute#operation for Operation resources.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000504 "name": "A String", # [Output Only] Name of the resource.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800505 "region": "A String", # [Output Only] The URL of the region where the operation resides. Only available when performing regional operations.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000506 "error": { # [Output Only] If errors are generated during processing of the operation, this field will be populated.
Craig Citroe633be12015-03-02 13:40:36 -0800507 "errors": [ # [Output Only] The array of errors encountered while processing this operation.
Craig Citro065b5302014-08-14 00:47:23 -0700508 {
Craig Citroe633be12015-03-02 13:40:36 -0800509 "message": "A String", # [Output Only] An optional, human-readable error message.
510 "code": "A String", # [Output Only] The error type identifier for this error.
511 "location": "A String", # [Output Only] Indicates the field in the request which caused the error. This property is optional.
Craig Citro065b5302014-08-14 00:47:23 -0700512 },
513 ],
514 },
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800515 "endTime": "A String", # [Output Only] The time that this operation was completed. This value is in RFC3339 text format.
Takashi Matsuo06694102015-09-11 13:55:40 -0700516 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800517 "targetLink": "A String", # [Output Only] The URL of the resource that the operation modifies.
Craig Citro065b5302014-08-14 00:47:23 -0700518 }</pre>
519</div>
520
521<div class="method">
522 <code class="details" id="update">update(project, urlMap, body)</code>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800523 <pre>Updates the entire content of the UrlMap resource.
Craig Citro065b5302014-08-14 00:47:23 -0700524
525Args:
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800526 project: string, Project ID for this request. (required)
Craig Citro065b5302014-08-14 00:47:23 -0700527 urlMap: string, Name of the UrlMap resource to update. (required)
528 body: object, The request body. (required)
529 The object takes the form of:
530
531{ # A UrlMap resource. This resource defines the mapping from URL to the BackendService resource, based on the "longest-match" of the URL's host and path.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800532 "kind": "compute#urlMap", # [Output Only] Type of the resource. Always compute#urlMaps for url maps.
533 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700534 "defaultService": "A String", # The URL of the BackendService resource if none of the hostRules match.
535 "tests": [ # The list of expected URL mappings. Request to update this UrlMap will succeed only all of the test cases pass.
536 { # Message for the expected URL mappings.
537 "path": "A String", # Path portion of the URL.
538 "host": "A String", # Host portion of the URL.
539 "description": "A String", # Description of this test case.
540 "service": "A String", # Expected BackendService resource the given URL should be mapped to.
541 },
542 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700543 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700544 "fingerprint": "A String", # Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a UrlMap. An up-to-date fingerprint must be provided in order to update the UrlMap.
545 "pathMatchers": [ # The list of named PathMatchers to use against the URL.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800546 { # A matcher for the path portion of the URL. The BackendService from the longest-matched rule will serve the URL. If no rule was matched, the default service will be used.
547 "defaultService": "A String", # The full or partial URL to the BackendService resource. This will be used if none of the pathRules defined by this PathMatcher is matched by the URL's path portion. For example, the following are all valid URLs to a BackendService resource:
548 # - https://www.googleapis.com/compute/v1/projects/project/global/backendServices/backendService
549 # - compute/v1/projects/project/global/backendServices/backendService
550 # - global/backendServices/backendService
Craig Citro065b5302014-08-14 00:47:23 -0700551 "pathRules": [ # The list of path rules.
552 { # A path-matching rule for a URL. If matched, will use the specified BackendService to handle the traffic arriving at this URL.
553 "paths": [ # The list of path patterns to match. Each must start with / and the only place a * is allowed is at the end following a /. The string fed to the path matcher does not include any text after the first ? or #, and those chars are not allowed here.
554 "A String",
555 ],
556 "service": "A String", # The URL of the BackendService resource if this rule is matched.
557 },
558 ],
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800559 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700560 "name": "A String", # The name to which this PathMatcher is referred by the HostRule.
561 },
562 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700563 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800564 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
Craig Citro065b5302014-08-14 00:47:23 -0700565 "hostRules": [ # The list of HostRules to use against the URL.
Takashi Matsuo06694102015-09-11 13:55:40 -0700566 { # UrlMaps A host-matching rule for a URL. If matched, will use the named PathMatcher to select the BackendService.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800567 "hosts": [ # The list of host patterns to match. They must be valid hostnames, except * will match any string of ([a-z0-9-.]*). In that case, * must be the first character and must be followed in the pattern by either - or ..
Craig Citro065b5302014-08-14 00:47:23 -0700568 "A String",
569 ],
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800570 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
571 "pathMatcher": "A String", # The name of the PathMatcher to use to match the path portion of the URL if the hostRule matches the URL's host portion.
Craig Citro065b5302014-08-14 00:47:23 -0700572 },
573 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700574 "name": "A String", # Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression [a-z]([-a-z0-9]*[a-z0-9])? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
Craig Citro065b5302014-08-14 00:47:23 -0700575 }
576
577
578Returns:
579 An object of the form:
580
Takashi Matsuo06694102015-09-11 13:55:40 -0700581 { # An Operation resource, used to manage asynchronous API requests.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800582 "targetId": "A String", # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource.
583 "clientOperationId": "A String", # [Output Only] Reserved for future use.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000584 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800585 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
586 "zone": "A String", # [Output Only] The URL of the zone where the operation resides. Only available when performing per-zone operations.
587 "insertTime": "A String", # [Output Only] The time that this operation was requested. This value is in RFC3339 text format.
588 "operationType": "A String", # [Output Only] The type of operation, such as insert, update, or delete, and so on.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000589 "httpErrorMessage": "A String", # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800590 "progress": 42, # [Output Only] An optional progress indicator that ranges from 0 to 100. There is no requirement that this be linear or support any granularity of operations. This should not be used to guess when the operation will be complete. This number should monotonically increase as the operation progresses.
591 "httpErrorStatusCode": 42, # [Output Only] If the operation fails, this field contains the HTTP error status code that was returned. For example, a 404 means the resource was not found.
Craig Citroe633be12015-03-02 13:40:36 -0800592 "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800593 "status": "A String", # [Output Only] The status of the operation, which can be one of the following: PENDING, RUNNING, or DONE.
594 "description": "A String", # [Output Only] A textual description of the operation, which is set when the operation is created.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000595 "warnings": [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated.
Craig Citro065b5302014-08-14 00:47:23 -0700596 {
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800597 "message": "A String", # [Output Only] A human-readable description of the warning code.
598 "code": "A String", # [Output Only] A warning code, if applicable. For example, Compute Engine returns NO_RESULTS_ON_PAGE if there are no results in the response.
599 "data": [ # [Output Only] Metadata about this warning in key: value format. For example:
600 # "data": [ { "key": "scope", "value": "zones/us-east1-d" }
Craig Citro065b5302014-08-14 00:47:23 -0700601 {
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000602 "value": "A String", # [Output Only] A warning data value corresponding to the key.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800603 "key": "A String", # [Output Only] A key that provides more detail on the warning being returned. For example, for warnings where there are no results in a list request for a particular zone, this key might be scope and the key value might be the zone name. Other examples might be a key indicating a deprecated resource, and a suggested replacement, or a warning about invalid network settings (for example, if an instance attempts to perform IP forwarding but is not enabled for IP forwarding).
Craig Citro065b5302014-08-14 00:47:23 -0700604 },
605 ],
606 },
607 ],
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000608 "user": "A String", # [Output Only] User who requested the operation, for example: user@example.com.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800609 "startTime": "A String", # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format.
610 "kind": "compute#operation", # [Output Only] Type of the resource. Always compute#operation for Operation resources.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000611 "name": "A String", # [Output Only] Name of the resource.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800612 "region": "A String", # [Output Only] The URL of the region where the operation resides. Only available when performing regional operations.
Nathaniel Manista5cbe5ba2015-03-10 23:29:22 +0000613 "error": { # [Output Only] If errors are generated during processing of the operation, this field will be populated.
Craig Citroe633be12015-03-02 13:40:36 -0800614 "errors": [ # [Output Only] The array of errors encountered while processing this operation.
Craig Citro065b5302014-08-14 00:47:23 -0700615 {
Craig Citroe633be12015-03-02 13:40:36 -0800616 "message": "A String", # [Output Only] An optional, human-readable error message.
617 "code": "A String", # [Output Only] The error type identifier for this error.
618 "location": "A String", # [Output Only] Indicates the field in the request which caused the error. This property is optional.
Craig Citro065b5302014-08-14 00:47:23 -0700619 },
620 ],
621 },
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800622 "endTime": "A String", # [Output Only] The time that this operation was completed. This value is in RFC3339 text format.
Takashi Matsuo06694102015-09-11 13:55:40 -0700623 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800624 "targetLink": "A String", # [Output Only] The URL of the resource that the operation modifies.
Craig Citro065b5302014-08-14 00:47:23 -0700625 }</pre>
626</div>
627
628<div class="method">
629 <code class="details" id="validate">validate(project, urlMap, body)</code>
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800630 <pre>Runs static validation for the UrlMap. In particular, the tests of the provided UrlMap will be run. Calling this method does NOT create the UrlMap.
Craig Citro065b5302014-08-14 00:47:23 -0700631
632Args:
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800633 project: string, Project ID for this request. (required)
Craig Citro065b5302014-08-14 00:47:23 -0700634 urlMap: string, Name of the UrlMap resource to be validated as. (required)
635 body: object, The request body. (required)
636 The object takes the form of:
637
638{
639 "resource": { # A UrlMap resource. This resource defines the mapping from URL to the BackendService resource, based on the "longest-match" of the URL's host and path. # Content of the UrlMap to be validated.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800640 "kind": "compute#urlMap", # [Output Only] Type of the resource. Always compute#urlMaps for url maps.
641 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700642 "defaultService": "A String", # The URL of the BackendService resource if none of the hostRules match.
643 "tests": [ # The list of expected URL mappings. Request to update this UrlMap will succeed only all of the test cases pass.
644 { # Message for the expected URL mappings.
645 "path": "A String", # Path portion of the URL.
646 "host": "A String", # Host portion of the URL.
647 "description": "A String", # Description of this test case.
648 "service": "A String", # Expected BackendService resource the given URL should be mapped to.
649 },
650 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700651 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700652 "fingerprint": "A String", # Fingerprint of this resource. A hash of the contents stored in this object. This field is used in optimistic locking. This field will be ignored when inserting a UrlMap. An up-to-date fingerprint must be provided in order to update the UrlMap.
653 "pathMatchers": [ # The list of named PathMatchers to use against the URL.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800654 { # A matcher for the path portion of the URL. The BackendService from the longest-matched rule will serve the URL. If no rule was matched, the default service will be used.
655 "defaultService": "A String", # The full or partial URL to the BackendService resource. This will be used if none of the pathRules defined by this PathMatcher is matched by the URL's path portion. For example, the following are all valid URLs to a BackendService resource:
656 # - https://www.googleapis.com/compute/v1/projects/project/global/backendServices/backendService
657 # - compute/v1/projects/project/global/backendServices/backendService
658 # - global/backendServices/backendService
Craig Citro065b5302014-08-14 00:47:23 -0700659 "pathRules": [ # The list of path rules.
660 { # A path-matching rule for a URL. If matched, will use the specified BackendService to handle the traffic arriving at this URL.
661 "paths": [ # The list of path patterns to match. Each must start with / and the only place a * is allowed is at the end following a /. The string fed to the path matcher does not include any text after the first ? or #, and those chars are not allowed here.
662 "A String",
663 ],
664 "service": "A String", # The URL of the BackendService resource if this rule is matched.
665 },
666 ],
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800667 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
Craig Citro065b5302014-08-14 00:47:23 -0700668 "name": "A String", # The name to which this PathMatcher is referred by the HostRule.
669 },
670 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700671 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800672 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
Craig Citro065b5302014-08-14 00:47:23 -0700673 "hostRules": [ # The list of HostRules to use against the URL.
Takashi Matsuo06694102015-09-11 13:55:40 -0700674 { # UrlMaps A host-matching rule for a URL. If matched, will use the named PathMatcher to select the BackendService.
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800675 "hosts": [ # The list of host patterns to match. They must be valid hostnames, except * will match any string of ([a-z0-9-.]*). In that case, * must be the first character and must be followed in the pattern by either - or ..
Craig Citro065b5302014-08-14 00:47:23 -0700676 "A String",
677 ],
Jon Wayne Parrott36e41bc2016-02-19 16:02:29 -0800678 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
679 "pathMatcher": "A String", # The name of the PathMatcher to use to match the path portion of the URL if the hostRule matches the URL's host portion.
Craig Citro065b5302014-08-14 00:47:23 -0700680 },
681 ],
Takashi Matsuo06694102015-09-11 13:55:40 -0700682 "name": "A String", # Name of the resource. Provided by the client when the resource is created. The name must be 1-63 characters long, and comply with RFC1035. Specifically, the name must be 1-63 characters long and match the regular expression [a-z]([-a-z0-9]*[a-z0-9])? which means the first character must be a lowercase letter, and all following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash.
Craig Citro065b5302014-08-14 00:47:23 -0700683 },
684 }
685
686
687Returns:
688 An object of the form:
689
690 {
691 "result": { # Message representing the validation result for a UrlMap.
692 "testFailures": [
693 {
694 "path": "A String",
695 "actualService": "A String",
696 "host": "A String",
697 "expectedService": "A String",
698 },
699 ],
700 "loadErrors": [
701 "A String",
702 ],
703 "testPassed": True or False, # If successfully loaded, this field indicates whether the test passed. If false, 'testFailures's indicate the reason of failure.
704 "loadSucceeded": True or False, # Whether the given UrlMap can be successfully loaded. If false, 'loadErrors' indicates the reasons.
705 },
706 }</pre>
707</div>
708
709</body></html>