blob: d1a99d5841f14ff5077e8a74537b155f63a655bc [file] [log] [blame]
Jon Wayne Parrott7d5badb2016-08-16 12:44:29 -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.routers.html">routers</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
78 <code><a href="#aggregatedList">aggregatedList(project, maxResults=None, pageToken=None, filter=None)</a></code></p>
79<p class="firstline">Retrieves an aggregated list of routers.</p>
80<p class="toc_element">
81 <code><a href="#aggregatedList_next">aggregatedList_next(previous_request, previous_response)</a></code></p>
82<p class="firstline">Retrieves the next page of results.</p>
83<p class="toc_element">
84 <code><a href="#delete">delete(project, region, router)</a></code></p>
85<p class="firstline">Deletes the specified Router resource.</p>
86<p class="toc_element">
87 <code><a href="#get">get(project, region, router)</a></code></p>
88<p class="firstline">Returns the specified Router resource. Get a list of available routers by making a list() request.</p>
89<p class="toc_element">
90 <code><a href="#getRouterStatus">getRouterStatus(project, region, router)</a></code></p>
91<p class="firstline">Retrieves runtime information of the specified router.</p>
92<p class="toc_element">
93 <code><a href="#insert">insert(project, region, body)</a></code></p>
94<p class="firstline">Creates a Router resource in the specified project and region using the data included in the request.</p>
95<p class="toc_element">
96 <code><a href="#list">list(project, region, maxResults=None, pageToken=None, filter=None)</a></code></p>
97<p class="firstline">Retrieves a list of Router resources available to the specified project.</p>
98<p class="toc_element">
99 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
100<p class="firstline">Retrieves the next page of results.</p>
101<p class="toc_element">
102 <code><a href="#patch">patch(project, region, router, body)</a></code></p>
103<p class="firstline">Updates the entire content of the Router resource. This method supports patch semantics.</p>
104<p class="toc_element">
105 <code><a href="#preview">preview(project, region, router, body)</a></code></p>
106<p class="firstline">Preview fields auto-generated during router create and update operations. Calling this method does NOT create or update the router.</p>
107<p class="toc_element">
108 <code><a href="#update">update(project, region, router, body)</a></code></p>
109<p class="firstline">Updates the entire content of the Router resource.</p>
110<h3>Method Details</h3>
111<div class="method">
112 <code class="details" id="aggregatedList">aggregatedList(project, maxResults=None, pageToken=None, filter=None)</code>
113 <pre>Retrieves an aggregated list of routers.
114
115Args:
116 project: string, Project ID for this request. (required)
117 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.
118 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.
119 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.
120
121The 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.
122
123For example, to filter for instances that do not have a name of example-instance, you would use filter=name ne example-instance.
124
125You can filter on nested fields. For example, you could filter on instances that have set the scheduling.automaticRestart field to true. Use filtering on nested fields to take advantage of labels to organize and search for results based on label values.
126
127To filter on multiple expressions, provide 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.
128
129Returns:
130 An object of the form:
131
132 { # Contains a list of routers.
133 "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.
134 "items": { # A map of scoped router lists.
135 "a_key": { # Name of the scope containing this set of routers.
136 "routers": [ # List of routers contained in this scope.
137 { # Router resource.
138 "kind": "compute#router", # [Output Only] Type of resource. Always compute#router for routers.
139 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
140 "interfaces": [ # Router interfaces. Each interface requires either one linked resource (e.g. linkedVpnTunnel) or IP address and IP address range (e.g. ipRange).
141 {
142 "linkedVpnTunnel": "A String", # URI of linked VPN tunnel. It must be in the same region as the router. Each interface can have at most one linked resource.
143 "ipRange": "A String", # IP address and range of the interface. The IP range must be in the RFC3927 link-local IP space. The value must be a CIDR-formatted string, for example: 169.254.0.1/30. NOTE: Do not truncate the address as it represents the IP address of the interface.
144 "name": "A String", # Name of this interface entry. The name must be 1-63 characters long and comply with RFC1035.
145 },
146 ],
147 "bgp": { # BGP information specific to this router.
148 "asn": 42, # Local BGP Autonomous System Number (ASN). Must be an RFC6996 private ASN, either 16-bit or 32-bit. The value will be fixed for this router resource. All VPN tunnels that link to this router will have the same local ASN.
149 },
150 "network": "A String", # URI of the network to which this router belongs.
151 "bgpPeers": [ # BGP information that needs to be configured into the routing stack to establish the BGP peering. It must specify peer ASN and either interface name, IP, or peer IP. Please refer to RFC4273.
152 {
153 "interfaceName": "A String", # Name of the interface the BGP peer is associated with.
154 "peerIpAddress": "A String", # IP address of the BGP interface outside Google cloud.
155 "peerAsn": 42, # Peer BGP Autonomous System Number (ASN). For VPN use case, this value can be different for every tunnel.
156 "advertisedRoutePriority": 42, # The priority of routes advertised to this BGP peer. In the case where there is more than one matching route of maximum length, the routes with lowest priority value win.
157 "ipAddress": "A String", # IP address of the interface inside Google Cloud Platform.
158 "name": "A String", # Name of this BGP peer. The name must be 1-63 characters long and comply with RFC1035.
159 },
160 ],
161 "region": "A String", # [Output Only] URI of the region where the router resides.
162 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
163 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
164 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
165 "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.
166 },
167 ],
168 "warning": { # Informational warning which replaces the list of routers when the list is empty.
169 "message": "A String", # [Output Only] A human-readable description of the warning code.
170 "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.
171 "data": [ # [Output Only] Metadata about this warning in key: value format. For example:
172 # "data": [ { "key": "scope", "value": "zones/us-east1-d" }
173 {
174 "value": "A String", # [Output Only] A warning data value corresponding to the key.
175 "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).
176 },
177 ],
178 },
179 },
180 },
181 "kind": "compute#routerAggregatedList", # Type of resource.
182 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
183 "selfLink": "A String", # [Output Only] Server-defined URL for this resource.
184 }</pre>
185</div>
186
187<div class="method">
188 <code class="details" id="aggregatedList_next">aggregatedList_next(previous_request, previous_response)</code>
189 <pre>Retrieves the next page of results.
190
191Args:
192 previous_request: The request for the previous page. (required)
193 previous_response: The response from the request for the previous page. (required)
194
195Returns:
196 A request object that you can call 'execute()' on to request the next
197 page. Returns None if there are no more items in the collection.
198 </pre>
199</div>
200
201<div class="method">
202 <code class="details" id="delete">delete(project, region, router)</code>
203 <pre>Deletes the specified Router resource.
204
205Args:
206 project: string, Project ID for this request. (required)
207 region: string, Name of the region for this request. (required)
208 router: string, Name of the Router resource to delete. (required)
209
210Returns:
211 An object of the form:
212
213 { # An Operation resource, used to manage asynchronous API requests.
214 "targetId": "A String", # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource.
215 "clientOperationId": "A String", # [Output Only] Reserved for future use.
216 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
217 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
218 "zone": "A String", # [Output Only] The URL of the zone where the operation resides. Only available when performing per-zone operations.
219 "insertTime": "A String", # [Output Only] The time that this operation was requested. This value is in RFC3339 text format.
220 "operationType": "A String", # [Output Only] The type of operation, such as insert, update, or delete, and so on.
221 "httpErrorMessage": "A String", # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND.
222 "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.
223 "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.
224 "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation.
225 "status": "A String", # [Output Only] The status of the operation, which can be one of the following: PENDING, RUNNING, or DONE.
226 "description": "A String", # [Output Only] A textual description of the operation, which is set when the operation is created.
227 "warnings": [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated.
228 {
229 "message": "A String", # [Output Only] A human-readable description of the warning code.
230 "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.
231 "data": [ # [Output Only] Metadata about this warning in key: value format. For example:
232 # "data": [ { "key": "scope", "value": "zones/us-east1-d" }
233 {
234 "value": "A String", # [Output Only] A warning data value corresponding to the key.
235 "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).
236 },
237 ],
238 },
239 ],
240 "user": "A String", # [Output Only] User who requested the operation, for example: user@example.com.
241 "startTime": "A String", # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format.
242 "kind": "compute#operation", # [Output Only] Type of the resource. Always compute#operation for Operation resources.
243 "name": "A String", # [Output Only] Name of the resource.
244 "region": "A String", # [Output Only] The URL of the region where the operation resides. Only available when performing regional operations.
245 "error": { # [Output Only] If errors are generated during processing of the operation, this field will be populated.
246 "errors": [ # [Output Only] The array of errors encountered while processing this operation.
247 {
248 "message": "A String", # [Output Only] An optional, human-readable error message.
249 "code": "A String", # [Output Only] The error type identifier for this error.
250 "location": "A String", # [Output Only] Indicates the field in the request that caused the error. This property is optional.
251 },
252 ],
253 },
254 "endTime": "A String", # [Output Only] The time that this operation was completed. This value is in RFC3339 text format.
255 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
256 "targetLink": "A String", # [Output Only] The URL of the resource that the operation modifies.
257 }</pre>
258</div>
259
260<div class="method">
261 <code class="details" id="get">get(project, region, router)</code>
262 <pre>Returns the specified Router resource. Get a list of available routers by making a list() request.
263
264Args:
265 project: string, Project ID for this request. (required)
266 region: string, Name of the region for this request. (required)
267 router: string, Name of the Router resource to return. (required)
268
269Returns:
270 An object of the form:
271
272 { # Router resource.
273 "kind": "compute#router", # [Output Only] Type of resource. Always compute#router for routers.
274 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
275 "interfaces": [ # Router interfaces. Each interface requires either one linked resource (e.g. linkedVpnTunnel) or IP address and IP address range (e.g. ipRange).
276 {
277 "linkedVpnTunnel": "A String", # URI of linked VPN tunnel. It must be in the same region as the router. Each interface can have at most one linked resource.
278 "ipRange": "A String", # IP address and range of the interface. The IP range must be in the RFC3927 link-local IP space. The value must be a CIDR-formatted string, for example: 169.254.0.1/30. NOTE: Do not truncate the address as it represents the IP address of the interface.
279 "name": "A String", # Name of this interface entry. The name must be 1-63 characters long and comply with RFC1035.
280 },
281 ],
282 "bgp": { # BGP information specific to this router.
283 "asn": 42, # Local BGP Autonomous System Number (ASN). Must be an RFC6996 private ASN, either 16-bit or 32-bit. The value will be fixed for this router resource. All VPN tunnels that link to this router will have the same local ASN.
284 },
285 "network": "A String", # URI of the network to which this router belongs.
286 "bgpPeers": [ # BGP information that needs to be configured into the routing stack to establish the BGP peering. It must specify peer ASN and either interface name, IP, or peer IP. Please refer to RFC4273.
287 {
288 "interfaceName": "A String", # Name of the interface the BGP peer is associated with.
289 "peerIpAddress": "A String", # IP address of the BGP interface outside Google cloud.
290 "peerAsn": 42, # Peer BGP Autonomous System Number (ASN). For VPN use case, this value can be different for every tunnel.
291 "advertisedRoutePriority": 42, # The priority of routes advertised to this BGP peer. In the case where there is more than one matching route of maximum length, the routes with lowest priority value win.
292 "ipAddress": "A String", # IP address of the interface inside Google Cloud Platform.
293 "name": "A String", # Name of this BGP peer. The name must be 1-63 characters long and comply with RFC1035.
294 },
295 ],
296 "region": "A String", # [Output Only] URI of the region where the router resides.
297 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
298 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
299 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
300 "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.
301 }</pre>
302</div>
303
304<div class="method">
305 <code class="details" id="getRouterStatus">getRouterStatus(project, region, router)</code>
306 <pre>Retrieves runtime information of the specified router.
307
308Args:
309 project: string, Project ID for this request. (required)
310 region: string, Name of the region for this request. (required)
311 router: string, Name of the Router resource to query. (required)
312
313Returns:
314 An object of the form:
315
316 {
317 "kind": "compute#routerStatusResponse", # Type of resource.
318 "result": {
319 "bgpPeerStatus": [
320 {
321 "status": "A String", # Status of the BGP peer: {UP, DOWN}
322 "uptime": "A String", # Time this session has been up. Format: 14 years, 51 weeks, 6 days, 23 hours, 59 minutes, 59 seconds
323 "name": "A String", # Name of this BGP peer. Unique within the Routers resource.
324 "uptimeSeconds": "A String", # Time this session has been up, in seconds. Format: 145
325 "linkedVpnTunnel": "A String", # URL of the VPN tunnel that this BGP peer controls.
326 "peerIpAddress": "A String", # IP address of the remote BGP interface.
327 "advertisedRoutes": [ # Routes that were advertised to the remote BGP peer
328 { # Represents a Route resource. A route specifies how certain packets should be handled by the network. Routes are associated with instances by tags and the set of routes for a particular instance is called its routing table.
329 #
330 # For each packet leaving a instance, the system searches that instance's routing table for a single best matching route. Routes match packets by destination IP address, preferring smaller or more specific ranges over larger ones. If there is a tie, the system selects the route with the smallest priority value. If there is still a tie, it uses the layer three and four packet headers to select just one of the remaining matching routes. The packet is then forwarded as specified by the nextHop field of the winning route - either to another instance destination, a instance gateway or a Google Compute Engine-operated gateway.
331 #
332 # Packets that do not match any route in the sending instance's routing table are dropped.
333 "nextHopGateway": "A String", # The URL to a gateway that should handle matching packets. You can only specify the internet gateway using a full or partial valid URL: projects/<project-id>/global/gateways/default-internet-gateway
334 "nextHopVpnTunnel": "A String", # The URL to a VpnTunnel that should handle matching packets.
335 "kind": "compute#route", # [Output Only] Type of this resource. Always compute#routes for Route resources.
336 "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.
337 "tags": [ # A list of instance tags to which this route applies.
338 "A String",
339 ],
340 "nextHopInstance": "A String", # The URL to an instance that should handle matching packets. You can specify this as a full or partial URL. For example:
341 # https://www.googleapis.com/compute/v1/projects/project/zones/zone/instances/
342 "priority": 42, # The priority of this route. Priority is used to break ties in cases where there is more than one matching route of equal prefix length. In the case of two routes with equal prefix length, the one with the lowest-numbered priority value wins. Default value is 1000. Valid range is 0 through 65535.
343 "nextHopNetwork": "A String", # The URL of the local network if it should handle matching packets.
344 "network": "A String", # Fully-qualified URL of the network that this route applies to.
345 "selfLink": "A String", # [Output Only] Server-defined fully-qualified URL for this resource.
346 "warnings": [ # [Output Only] If potential misconfigurations are detected for this route, this field will be populated with warning messages.
347 {
348 "message": "A String", # [Output Only] A human-readable description of the warning code.
349 "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.
350 "data": [ # [Output Only] Metadata about this warning in key: value format. For example:
351 # "data": [ { "key": "scope", "value": "zones/us-east1-d" }
352 {
353 "value": "A String", # [Output Only] A warning data value corresponding to the key.
354 "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).
355 },
356 ],
357 },
358 ],
359 "destRange": "A String", # The destination range of outgoing packets that this route applies to.
360 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
361 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
362 "nextHopIp": "A String", # The network IP address of an instance that should handle matching packets.
363 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
364 },
365 ],
366 "state": "A String", # BGP state as specified in RFC1771.
367 "ipAddress": "A String", # IP address of the local BGP interface.
368 "numLearnedRoutes": 42, # Number of routes learned from the remote BGP Peer.
369 },
370 ],
371 "network": "A String", # URI of the network to which this router belongs.
372 "bestRoutes": [ # Best routes for this router's network.
373 { # Represents a Route resource. A route specifies how certain packets should be handled by the network. Routes are associated with instances by tags and the set of routes for a particular instance is called its routing table.
374 #
375 # For each packet leaving a instance, the system searches that instance's routing table for a single best matching route. Routes match packets by destination IP address, preferring smaller or more specific ranges over larger ones. If there is a tie, the system selects the route with the smallest priority value. If there is still a tie, it uses the layer three and four packet headers to select just one of the remaining matching routes. The packet is then forwarded as specified by the nextHop field of the winning route - either to another instance destination, a instance gateway or a Google Compute Engine-operated gateway.
376 #
377 # Packets that do not match any route in the sending instance's routing table are dropped.
378 "nextHopGateway": "A String", # The URL to a gateway that should handle matching packets. You can only specify the internet gateway using a full or partial valid URL: projects/<project-id>/global/gateways/default-internet-gateway
379 "nextHopVpnTunnel": "A String", # The URL to a VpnTunnel that should handle matching packets.
380 "kind": "compute#route", # [Output Only] Type of this resource. Always compute#routes for Route resources.
381 "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.
382 "tags": [ # A list of instance tags to which this route applies.
383 "A String",
384 ],
385 "nextHopInstance": "A String", # The URL to an instance that should handle matching packets. You can specify this as a full or partial URL. For example:
386 # https://www.googleapis.com/compute/v1/projects/project/zones/zone/instances/
387 "priority": 42, # The priority of this route. Priority is used to break ties in cases where there is more than one matching route of equal prefix length. In the case of two routes with equal prefix length, the one with the lowest-numbered priority value wins. Default value is 1000. Valid range is 0 through 65535.
388 "nextHopNetwork": "A String", # The URL of the local network if it should handle matching packets.
389 "network": "A String", # Fully-qualified URL of the network that this route applies to.
390 "selfLink": "A String", # [Output Only] Server-defined fully-qualified URL for this resource.
391 "warnings": [ # [Output Only] If potential misconfigurations are detected for this route, this field will be populated with warning messages.
392 {
393 "message": "A String", # [Output Only] A human-readable description of the warning code.
394 "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.
395 "data": [ # [Output Only] Metadata about this warning in key: value format. For example:
396 # "data": [ { "key": "scope", "value": "zones/us-east1-d" }
397 {
398 "value": "A String", # [Output Only] A warning data value corresponding to the key.
399 "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).
400 },
401 ],
402 },
403 ],
404 "destRange": "A String", # The destination range of outgoing packets that this route applies to.
405 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
406 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
407 "nextHopIp": "A String", # The network IP address of an instance that should handle matching packets.
408 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
409 },
410 ],
411 },
412 }</pre>
413</div>
414
415<div class="method">
416 <code class="details" id="insert">insert(project, region, body)</code>
417 <pre>Creates a Router resource in the specified project and region using the data included in the request.
418
419Args:
420 project: string, Project ID for this request. (required)
421 region: string, Name of the region for this request. (required)
422 body: object, The request body. (required)
423 The object takes the form of:
424
425{ # Router resource.
426 "kind": "compute#router", # [Output Only] Type of resource. Always compute#router for routers.
427 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
428 "interfaces": [ # Router interfaces. Each interface requires either one linked resource (e.g. linkedVpnTunnel) or IP address and IP address range (e.g. ipRange).
429 {
430 "linkedVpnTunnel": "A String", # URI of linked VPN tunnel. It must be in the same region as the router. Each interface can have at most one linked resource.
431 "ipRange": "A String", # IP address and range of the interface. The IP range must be in the RFC3927 link-local IP space. The value must be a CIDR-formatted string, for example: 169.254.0.1/30. NOTE: Do not truncate the address as it represents the IP address of the interface.
432 "name": "A String", # Name of this interface entry. The name must be 1-63 characters long and comply with RFC1035.
433 },
434 ],
435 "bgp": { # BGP information specific to this router.
436 "asn": 42, # Local BGP Autonomous System Number (ASN). Must be an RFC6996 private ASN, either 16-bit or 32-bit. The value will be fixed for this router resource. All VPN tunnels that link to this router will have the same local ASN.
437 },
438 "network": "A String", # URI of the network to which this router belongs.
439 "bgpPeers": [ # BGP information that needs to be configured into the routing stack to establish the BGP peering. It must specify peer ASN and either interface name, IP, or peer IP. Please refer to RFC4273.
440 {
441 "interfaceName": "A String", # Name of the interface the BGP peer is associated with.
442 "peerIpAddress": "A String", # IP address of the BGP interface outside Google cloud.
443 "peerAsn": 42, # Peer BGP Autonomous System Number (ASN). For VPN use case, this value can be different for every tunnel.
444 "advertisedRoutePriority": 42, # The priority of routes advertised to this BGP peer. In the case where there is more than one matching route of maximum length, the routes with lowest priority value win.
445 "ipAddress": "A String", # IP address of the interface inside Google Cloud Platform.
446 "name": "A String", # Name of this BGP peer. The name must be 1-63 characters long and comply with RFC1035.
447 },
448 ],
449 "region": "A String", # [Output Only] URI of the region where the router resides.
450 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
451 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
452 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
453 "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.
454 }
455
456
457Returns:
458 An object of the form:
459
460 { # An Operation resource, used to manage asynchronous API requests.
461 "targetId": "A String", # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource.
462 "clientOperationId": "A String", # [Output Only] Reserved for future use.
463 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
464 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
465 "zone": "A String", # [Output Only] The URL of the zone where the operation resides. Only available when performing per-zone operations.
466 "insertTime": "A String", # [Output Only] The time that this operation was requested. This value is in RFC3339 text format.
467 "operationType": "A String", # [Output Only] The type of operation, such as insert, update, or delete, and so on.
468 "httpErrorMessage": "A String", # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND.
469 "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.
470 "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.
471 "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation.
472 "status": "A String", # [Output Only] The status of the operation, which can be one of the following: PENDING, RUNNING, or DONE.
473 "description": "A String", # [Output Only] A textual description of the operation, which is set when the operation is created.
474 "warnings": [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated.
475 {
476 "message": "A String", # [Output Only] A human-readable description of the warning code.
477 "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.
478 "data": [ # [Output Only] Metadata about this warning in key: value format. For example:
479 # "data": [ { "key": "scope", "value": "zones/us-east1-d" }
480 {
481 "value": "A String", # [Output Only] A warning data value corresponding to the key.
482 "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).
483 },
484 ],
485 },
486 ],
487 "user": "A String", # [Output Only] User who requested the operation, for example: user@example.com.
488 "startTime": "A String", # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format.
489 "kind": "compute#operation", # [Output Only] Type of the resource. Always compute#operation for Operation resources.
490 "name": "A String", # [Output Only] Name of the resource.
491 "region": "A String", # [Output Only] The URL of the region where the operation resides. Only available when performing regional operations.
492 "error": { # [Output Only] If errors are generated during processing of the operation, this field will be populated.
493 "errors": [ # [Output Only] The array of errors encountered while processing this operation.
494 {
495 "message": "A String", # [Output Only] An optional, human-readable error message.
496 "code": "A String", # [Output Only] The error type identifier for this error.
497 "location": "A String", # [Output Only] Indicates the field in the request that caused the error. This property is optional.
498 },
499 ],
500 },
501 "endTime": "A String", # [Output Only] The time that this operation was completed. This value is in RFC3339 text format.
502 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
503 "targetLink": "A String", # [Output Only] The URL of the resource that the operation modifies.
504 }</pre>
505</div>
506
507<div class="method">
508 <code class="details" id="list">list(project, region, maxResults=None, pageToken=None, filter=None)</code>
509 <pre>Retrieves a list of Router resources available to the specified project.
510
511Args:
512 project: string, Project ID for this request. (required)
513 region: string, Name of the region for this request. (required)
514 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.
515 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.
516 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.
517
518The 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.
519
520For example, to filter for instances that do not have a name of example-instance, you would use filter=name ne example-instance.
521
522You can filter on nested fields. For example, you could filter on instances that have set the scheduling.automaticRestart field to true. Use filtering on nested fields to take advantage of labels to organize and search for results based on label values.
523
524To filter on multiple expressions, provide 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.
525
526Returns:
527 An object of the form:
528
529 { # Contains a list of Router resources.
530 "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.
531 "items": [ # A list of Router resources.
532 { # Router resource.
533 "kind": "compute#router", # [Output Only] Type of resource. Always compute#router for routers.
534 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
535 "interfaces": [ # Router interfaces. Each interface requires either one linked resource (e.g. linkedVpnTunnel) or IP address and IP address range (e.g. ipRange).
536 {
537 "linkedVpnTunnel": "A String", # URI of linked VPN tunnel. It must be in the same region as the router. Each interface can have at most one linked resource.
538 "ipRange": "A String", # IP address and range of the interface. The IP range must be in the RFC3927 link-local IP space. The value must be a CIDR-formatted string, for example: 169.254.0.1/30. NOTE: Do not truncate the address as it represents the IP address of the interface.
539 "name": "A String", # Name of this interface entry. The name must be 1-63 characters long and comply with RFC1035.
540 },
541 ],
542 "bgp": { # BGP information specific to this router.
543 "asn": 42, # Local BGP Autonomous System Number (ASN). Must be an RFC6996 private ASN, either 16-bit or 32-bit. The value will be fixed for this router resource. All VPN tunnels that link to this router will have the same local ASN.
544 },
545 "network": "A String", # URI of the network to which this router belongs.
546 "bgpPeers": [ # BGP information that needs to be configured into the routing stack to establish the BGP peering. It must specify peer ASN and either interface name, IP, or peer IP. Please refer to RFC4273.
547 {
548 "interfaceName": "A String", # Name of the interface the BGP peer is associated with.
549 "peerIpAddress": "A String", # IP address of the BGP interface outside Google cloud.
550 "peerAsn": 42, # Peer BGP Autonomous System Number (ASN). For VPN use case, this value can be different for every tunnel.
551 "advertisedRoutePriority": 42, # The priority of routes advertised to this BGP peer. In the case where there is more than one matching route of maximum length, the routes with lowest priority value win.
552 "ipAddress": "A String", # IP address of the interface inside Google Cloud Platform.
553 "name": "A String", # Name of this BGP peer. The name must be 1-63 characters long and comply with RFC1035.
554 },
555 ],
556 "region": "A String", # [Output Only] URI of the region where the router resides.
557 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
558 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
559 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
560 "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.
561 },
562 ],
563 "kind": "compute#routerList", # [Output Only] Type of resource. Always compute#router for routers.
564 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
565 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
566 }</pre>
567</div>
568
569<div class="method">
570 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
571 <pre>Retrieves the next page of results.
572
573Args:
574 previous_request: The request for the previous page. (required)
575 previous_response: The response from the request for the previous page. (required)
576
577Returns:
578 A request object that you can call 'execute()' on to request the next
579 page. Returns None if there are no more items in the collection.
580 </pre>
581</div>
582
583<div class="method">
584 <code class="details" id="patch">patch(project, region, router, body)</code>
585 <pre>Updates the entire content of the Router resource. This method supports patch semantics.
586
587Args:
588 project: string, Project ID for this request. (required)
589 region: string, Name of the region for this request. (required)
590 router: string, Name of the Router resource to update. (required)
591 body: object, The request body. (required)
592 The object takes the form of:
593
594{ # Router resource.
595 "kind": "compute#router", # [Output Only] Type of resource. Always compute#router for routers.
596 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
597 "interfaces": [ # Router interfaces. Each interface requires either one linked resource (e.g. linkedVpnTunnel) or IP address and IP address range (e.g. ipRange).
598 {
599 "linkedVpnTunnel": "A String", # URI of linked VPN tunnel. It must be in the same region as the router. Each interface can have at most one linked resource.
600 "ipRange": "A String", # IP address and range of the interface. The IP range must be in the RFC3927 link-local IP space. The value must be a CIDR-formatted string, for example: 169.254.0.1/30. NOTE: Do not truncate the address as it represents the IP address of the interface.
601 "name": "A String", # Name of this interface entry. The name must be 1-63 characters long and comply with RFC1035.
602 },
603 ],
604 "bgp": { # BGP information specific to this router.
605 "asn": 42, # Local BGP Autonomous System Number (ASN). Must be an RFC6996 private ASN, either 16-bit or 32-bit. The value will be fixed for this router resource. All VPN tunnels that link to this router will have the same local ASN.
606 },
607 "network": "A String", # URI of the network to which this router belongs.
608 "bgpPeers": [ # BGP information that needs to be configured into the routing stack to establish the BGP peering. It must specify peer ASN and either interface name, IP, or peer IP. Please refer to RFC4273.
609 {
610 "interfaceName": "A String", # Name of the interface the BGP peer is associated with.
611 "peerIpAddress": "A String", # IP address of the BGP interface outside Google cloud.
612 "peerAsn": 42, # Peer BGP Autonomous System Number (ASN). For VPN use case, this value can be different for every tunnel.
613 "advertisedRoutePriority": 42, # The priority of routes advertised to this BGP peer. In the case where there is more than one matching route of maximum length, the routes with lowest priority value win.
614 "ipAddress": "A String", # IP address of the interface inside Google Cloud Platform.
615 "name": "A String", # Name of this BGP peer. The name must be 1-63 characters long and comply with RFC1035.
616 },
617 ],
618 "region": "A String", # [Output Only] URI of the region where the router resides.
619 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
620 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
621 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
622 "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.
623 }
624
625
626Returns:
627 An object of the form:
628
629 { # An Operation resource, used to manage asynchronous API requests.
630 "targetId": "A String", # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource.
631 "clientOperationId": "A String", # [Output Only] Reserved for future use.
632 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
633 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
634 "zone": "A String", # [Output Only] The URL of the zone where the operation resides. Only available when performing per-zone operations.
635 "insertTime": "A String", # [Output Only] The time that this operation was requested. This value is in RFC3339 text format.
636 "operationType": "A String", # [Output Only] The type of operation, such as insert, update, or delete, and so on.
637 "httpErrorMessage": "A String", # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND.
638 "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.
639 "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.
640 "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation.
641 "status": "A String", # [Output Only] The status of the operation, which can be one of the following: PENDING, RUNNING, or DONE.
642 "description": "A String", # [Output Only] A textual description of the operation, which is set when the operation is created.
643 "warnings": [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated.
644 {
645 "message": "A String", # [Output Only] A human-readable description of the warning code.
646 "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.
647 "data": [ # [Output Only] Metadata about this warning in key: value format. For example:
648 # "data": [ { "key": "scope", "value": "zones/us-east1-d" }
649 {
650 "value": "A String", # [Output Only] A warning data value corresponding to the key.
651 "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).
652 },
653 ],
654 },
655 ],
656 "user": "A String", # [Output Only] User who requested the operation, for example: user@example.com.
657 "startTime": "A String", # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format.
658 "kind": "compute#operation", # [Output Only] Type of the resource. Always compute#operation for Operation resources.
659 "name": "A String", # [Output Only] Name of the resource.
660 "region": "A String", # [Output Only] The URL of the region where the operation resides. Only available when performing regional operations.
661 "error": { # [Output Only] If errors are generated during processing of the operation, this field will be populated.
662 "errors": [ # [Output Only] The array of errors encountered while processing this operation.
663 {
664 "message": "A String", # [Output Only] An optional, human-readable error message.
665 "code": "A String", # [Output Only] The error type identifier for this error.
666 "location": "A String", # [Output Only] Indicates the field in the request that caused the error. This property is optional.
667 },
668 ],
669 },
670 "endTime": "A String", # [Output Only] The time that this operation was completed. This value is in RFC3339 text format.
671 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
672 "targetLink": "A String", # [Output Only] The URL of the resource that the operation modifies.
673 }</pre>
674</div>
675
676<div class="method">
677 <code class="details" id="preview">preview(project, region, router, body)</code>
678 <pre>Preview fields auto-generated during router create and update operations. Calling this method does NOT create or update the router.
679
680Args:
681 project: string, Project ID for this request. (required)
682 region: string, Name of the region for this request. (required)
683 router: string, Name of the Router resource to query. (required)
684 body: object, The request body. (required)
685 The object takes the form of:
686
687{ # Router resource.
688 "kind": "compute#router", # [Output Only] Type of resource. Always compute#router for routers.
689 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
690 "interfaces": [ # Router interfaces. Each interface requires either one linked resource (e.g. linkedVpnTunnel) or IP address and IP address range (e.g. ipRange).
691 {
692 "linkedVpnTunnel": "A String", # URI of linked VPN tunnel. It must be in the same region as the router. Each interface can have at most one linked resource.
693 "ipRange": "A String", # IP address and range of the interface. The IP range must be in the RFC3927 link-local IP space. The value must be a CIDR-formatted string, for example: 169.254.0.1/30. NOTE: Do not truncate the address as it represents the IP address of the interface.
694 "name": "A String", # Name of this interface entry. The name must be 1-63 characters long and comply with RFC1035.
695 },
696 ],
697 "bgp": { # BGP information specific to this router.
698 "asn": 42, # Local BGP Autonomous System Number (ASN). Must be an RFC6996 private ASN, either 16-bit or 32-bit. The value will be fixed for this router resource. All VPN tunnels that link to this router will have the same local ASN.
699 },
700 "network": "A String", # URI of the network to which this router belongs.
701 "bgpPeers": [ # BGP information that needs to be configured into the routing stack to establish the BGP peering. It must specify peer ASN and either interface name, IP, or peer IP. Please refer to RFC4273.
702 {
703 "interfaceName": "A String", # Name of the interface the BGP peer is associated with.
704 "peerIpAddress": "A String", # IP address of the BGP interface outside Google cloud.
705 "peerAsn": 42, # Peer BGP Autonomous System Number (ASN). For VPN use case, this value can be different for every tunnel.
706 "advertisedRoutePriority": 42, # The priority of routes advertised to this BGP peer. In the case where there is more than one matching route of maximum length, the routes with lowest priority value win.
707 "ipAddress": "A String", # IP address of the interface inside Google Cloud Platform.
708 "name": "A String", # Name of this BGP peer. The name must be 1-63 characters long and comply with RFC1035.
709 },
710 ],
711 "region": "A String", # [Output Only] URI of the region where the router resides.
712 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
713 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
714 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
715 "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.
716 }
717
718
719Returns:
720 An object of the form:
721
722 {
723 "resource": { # Router resource. # Preview of given router.
724 "kind": "compute#router", # [Output Only] Type of resource. Always compute#router for routers.
725 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
726 "interfaces": [ # Router interfaces. Each interface requires either one linked resource (e.g. linkedVpnTunnel) or IP address and IP address range (e.g. ipRange).
727 {
728 "linkedVpnTunnel": "A String", # URI of linked VPN tunnel. It must be in the same region as the router. Each interface can have at most one linked resource.
729 "ipRange": "A String", # IP address and range of the interface. The IP range must be in the RFC3927 link-local IP space. The value must be a CIDR-formatted string, for example: 169.254.0.1/30. NOTE: Do not truncate the address as it represents the IP address of the interface.
730 "name": "A String", # Name of this interface entry. The name must be 1-63 characters long and comply with RFC1035.
731 },
732 ],
733 "bgp": { # BGP information specific to this router.
734 "asn": 42, # Local BGP Autonomous System Number (ASN). Must be an RFC6996 private ASN, either 16-bit or 32-bit. The value will be fixed for this router resource. All VPN tunnels that link to this router will have the same local ASN.
735 },
736 "network": "A String", # URI of the network to which this router belongs.
737 "bgpPeers": [ # BGP information that needs to be configured into the routing stack to establish the BGP peering. It must specify peer ASN and either interface name, IP, or peer IP. Please refer to RFC4273.
738 {
739 "interfaceName": "A String", # Name of the interface the BGP peer is associated with.
740 "peerIpAddress": "A String", # IP address of the BGP interface outside Google cloud.
741 "peerAsn": 42, # Peer BGP Autonomous System Number (ASN). For VPN use case, this value can be different for every tunnel.
742 "advertisedRoutePriority": 42, # The priority of routes advertised to this BGP peer. In the case where there is more than one matching route of maximum length, the routes with lowest priority value win.
743 "ipAddress": "A String", # IP address of the interface inside Google Cloud Platform.
744 "name": "A String", # Name of this BGP peer. The name must be 1-63 characters long and comply with RFC1035.
745 },
746 ],
747 "region": "A String", # [Output Only] URI of the region where the router resides.
748 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
749 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
750 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
751 "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.
752 },
753 }</pre>
754</div>
755
756<div class="method">
757 <code class="details" id="update">update(project, region, router, body)</code>
758 <pre>Updates the entire content of the Router resource.
759
760Args:
761 project: string, Project ID for this request. (required)
762 region: string, Name of the region for this request. (required)
763 router: string, Name of the Router resource to update. (required)
764 body: object, The request body. (required)
765 The object takes the form of:
766
767{ # Router resource.
768 "kind": "compute#router", # [Output Only] Type of resource. Always compute#router for routers.
769 "description": "A String", # An optional description of this resource. Provide this property when you create the resource.
770 "interfaces": [ # Router interfaces. Each interface requires either one linked resource (e.g. linkedVpnTunnel) or IP address and IP address range (e.g. ipRange).
771 {
772 "linkedVpnTunnel": "A String", # URI of linked VPN tunnel. It must be in the same region as the router. Each interface can have at most one linked resource.
773 "ipRange": "A String", # IP address and range of the interface. The IP range must be in the RFC3927 link-local IP space. The value must be a CIDR-formatted string, for example: 169.254.0.1/30. NOTE: Do not truncate the address as it represents the IP address of the interface.
774 "name": "A String", # Name of this interface entry. The name must be 1-63 characters long and comply with RFC1035.
775 },
776 ],
777 "bgp": { # BGP information specific to this router.
778 "asn": 42, # Local BGP Autonomous System Number (ASN). Must be an RFC6996 private ASN, either 16-bit or 32-bit. The value will be fixed for this router resource. All VPN tunnels that link to this router will have the same local ASN.
779 },
780 "network": "A String", # URI of the network to which this router belongs.
781 "bgpPeers": [ # BGP information that needs to be configured into the routing stack to establish the BGP peering. It must specify peer ASN and either interface name, IP, or peer IP. Please refer to RFC4273.
782 {
783 "interfaceName": "A String", # Name of the interface the BGP peer is associated with.
784 "peerIpAddress": "A String", # IP address of the BGP interface outside Google cloud.
785 "peerAsn": 42, # Peer BGP Autonomous System Number (ASN). For VPN use case, this value can be different for every tunnel.
786 "advertisedRoutePriority": 42, # The priority of routes advertised to this BGP peer. In the case where there is more than one matching route of maximum length, the routes with lowest priority value win.
787 "ipAddress": "A String", # IP address of the interface inside Google Cloud Platform.
788 "name": "A String", # Name of this BGP peer. The name must be 1-63 characters long and comply with RFC1035.
789 },
790 ],
791 "region": "A String", # [Output Only] URI of the region where the router resides.
792 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
793 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
794 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
795 "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.
796 }
797
798
799Returns:
800 An object of the form:
801
802 { # An Operation resource, used to manage asynchronous API requests.
803 "targetId": "A String", # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource.
804 "clientOperationId": "A String", # [Output Only] Reserved for future use.
805 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format.
806 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server.
807 "zone": "A String", # [Output Only] The URL of the zone where the operation resides. Only available when performing per-zone operations.
808 "insertTime": "A String", # [Output Only] The time that this operation was requested. This value is in RFC3339 text format.
809 "operationType": "A String", # [Output Only] The type of operation, such as insert, update, or delete, and so on.
810 "httpErrorMessage": "A String", # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND.
811 "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.
812 "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.
813 "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation.
814 "status": "A String", # [Output Only] The status of the operation, which can be one of the following: PENDING, RUNNING, or DONE.
815 "description": "A String", # [Output Only] A textual description of the operation, which is set when the operation is created.
816 "warnings": [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated.
817 {
818 "message": "A String", # [Output Only] A human-readable description of the warning code.
819 "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.
820 "data": [ # [Output Only] Metadata about this warning in key: value format. For example:
821 # "data": [ { "key": "scope", "value": "zones/us-east1-d" }
822 {
823 "value": "A String", # [Output Only] A warning data value corresponding to the key.
824 "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).
825 },
826 ],
827 },
828 ],
829 "user": "A String", # [Output Only] User who requested the operation, for example: user@example.com.
830 "startTime": "A String", # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format.
831 "kind": "compute#operation", # [Output Only] Type of the resource. Always compute#operation for Operation resources.
832 "name": "A String", # [Output Only] Name of the resource.
833 "region": "A String", # [Output Only] The URL of the region where the operation resides. Only available when performing regional operations.
834 "error": { # [Output Only] If errors are generated during processing of the operation, this field will be populated.
835 "errors": [ # [Output Only] The array of errors encountered while processing this operation.
836 {
837 "message": "A String", # [Output Only] An optional, human-readable error message.
838 "code": "A String", # [Output Only] The error type identifier for this error.
839 "location": "A String", # [Output Only] Indicates the field in the request that caused the error. This property is optional.
840 },
841 ],
842 },
843 "endTime": "A String", # [Output Only] The time that this operation was completed. This value is in RFC3339 text format.
844 "selfLink": "A String", # [Output Only] Server-defined URL for the resource.
845 "targetLink": "A String", # [Output Only] The URL of the resource that the operation modifies.
846 }</pre>
847</div>
848
849</body></html>