1 <html><body> 2 <style> 3 4 body, 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 15 body { 16 font-size: 13px; 17 padding: 1em; 18 } 19 20 h1 { 21 font-size: 26px; 22 margin-bottom: 1em; 23 } 24 25 h2 { 26 font-size: 24px; 27 margin-bottom: 1em; 28 } 29 30 h3 { 31 font-size: 20px; 32 margin-bottom: 1em; 33 margin-top: 1em; 34 } 35 36 pre, code { 37 line-height: 1.5; 38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace; 39 } 40 41 pre { 42 margin-top: 0.5em; 43 } 44 45 h1, h2, h3, p { 46 font-family: Arial, sans serif; 47 } 48 49 h1, 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_alpha.html">Compute Engine API</a> . <a href="compute_alpha.networks.html">networks</a></h1> 76 <h2>Instance Methods</h2> 77 <p class="toc_element"> 78 <code><a href="#addPeering">addPeering(project, network, body, requestId=None)</a></code></p> 79 <p class="firstline">Adds a peering to the specified network.</p> 80 <p class="toc_element"> 81 <code><a href="#delete">delete(project, network, requestId=None)</a></code></p> 82 <p class="firstline">Deletes the specified network.</p> 83 <p class="toc_element"> 84 <code><a href="#get">get(project, network)</a></code></p> 85 <p class="firstline">Returns the specified network. Get a list of available networks by making a list() request.</p> 86 <p class="toc_element"> 87 <code><a href="#insert">insert(project, body, requestId=None)</a></code></p> 88 <p class="firstline">Creates a network in the specified project using the data included in the request.</p> 89 <p class="toc_element"> 90 <code><a href="#list">list(project, orderBy=None, maxResults=None, pageToken=None, filter=None)</a></code></p> 91 <p class="firstline">Retrieves the list of networks available to the specified project.</p> 92 <p class="toc_element"> 93 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p> 94 <p class="firstline">Retrieves the next page of results.</p> 95 <p class="toc_element"> 96 <code><a href="#removePeering">removePeering(project, network, body, requestId=None)</a></code></p> 97 <p class="firstline">Removes a peering from the specified network.</p> 98 <p class="toc_element"> 99 <code><a href="#switchToCustomMode">switchToCustomMode(project, network, requestId=None)</a></code></p> 100 <p class="firstline">Switches the network mode from auto subnet mode to custom subnet mode.</p> 101 <p class="toc_element"> 102 <code><a href="#testIamPermissions">testIamPermissions(project, resource, body)</a></code></p> 103 <p class="firstline">Returns permissions that a caller has on the specified resource.</p> 104 <h3>Method Details</h3> 105 <div class="method"> 106 <code class="details" id="addPeering">addPeering(project, network, body, requestId=None)</code> 107 <pre>Adds a peering to the specified network. 108 109 Args: 110 project: string, Project ID for this request. (required) 111 network: string, Name of the network resource to add peering to. (required) 112 body: object, The request body. (required) 113 The object takes the form of: 114 115 { 116 "peerNetwork": "A String", # URL of the peer network. It can be either full URL or partial URL. The peer network may belong to a different project. If the partial URL does not contain project, it is assumed that the peer network is in the same project as the current network. 117 "name": "A String", # Name of the peering, which should conform to RFC1035. 118 "autoCreateRoutes": True or False, # Whether Google Compute Engine manages the routes automatically. 119 } 120 121 requestId: string, begin_interface: MixerMutationRequestBuilder Request ID to support idempotency. 122 123 Returns: 124 An object of the form: 125 126 { # An Operation resource, used to manage asynchronous API requests. 127 "targetId": "A String", # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource. 128 "clientOperationId": "A String", # [Output Only] Reserved for future use. 129 "creationTimestamp": "A String", # [Deprecated] This field is deprecated. 130 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server. 131 "zone": "A String", # [Output Only] The URL of the zone where the operation resides. Only available when performing per-zone operations. 132 "insertTime": "A String", # [Output Only] The time that this operation was requested. This value is in RFC3339 text format. 133 "operationType": "A String", # [Output Only] The type of operation, such as insert, update, or delete, and so on. 134 "httpErrorMessage": "A String", # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND. 135 "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. 136 "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. 137 "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation. 138 "status": "A String", # [Output Only] The status of the operation, which can be one of the following: PENDING, RUNNING, or DONE. 139 "description": "A String", # [Output Only] A textual description of the operation, which is set when the operation is created. 140 "warnings": [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated. 141 { 142 "message": "A String", # [Output Only] A human-readable description of the warning code. 143 "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. 144 "data": [ # [Output Only] Metadata about this warning in key: value format. For example: 145 # "data": [ { "key": "scope", "value": "zones/us-east1-d" } 146 { 147 "value": "A String", # [Output Only] A warning data value corresponding to the key. 148 "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). 149 }, 150 ], 151 }, 152 ], 153 "user": "A String", # [Output Only] User who requested the operation, for example: user (a] example.com. 154 "startTime": "A String", # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format. 155 "kind": "compute#operation", # [Output Only] Type of the resource. Always compute#operation for Operation resources. 156 "name": "A String", # [Output Only] Name of the resource. 157 "region": "A String", # [Output Only] The URL of the region where the operation resides. Only available when performing regional operations. 158 "error": { # [Output Only] If errors are generated during processing of the operation, this field will be populated. 159 "errors": [ # [Output Only] The array of errors encountered while processing this operation. 160 { 161 "message": "A String", # [Output Only] An optional, human-readable error message. 162 "code": "A String", # [Output Only] The error type identifier for this error. 163 "location": "A String", # [Output Only] Indicates the field in the request that caused the error. This property is optional. 164 }, 165 ], 166 }, 167 "endTime": "A String", # [Output Only] The time that this operation was completed. This value is in RFC3339 text format. 168 "selfLink": "A String", # [Output Only] Server-defined URL for the resource. 169 "targetLink": "A String", # [Output Only] The URL of the resource that the operation modifies. For operations related to creating a snapshot, this points to the persistent disk that the snapshot was created from. 170 }</pre> 171 </div> 172 173 <div class="method"> 174 <code class="details" id="delete">delete(project, network, requestId=None)</code> 175 <pre>Deletes the specified network. 176 177 Args: 178 project: string, Project ID for this request. (required) 179 network: string, Name of the network to delete. (required) 180 requestId: string, begin_interface: MixerMutationRequestBuilder Request ID to support idempotency. 181 182 Returns: 183 An object of the form: 184 185 { # An Operation resource, used to manage asynchronous API requests. 186 "targetId": "A String", # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource. 187 "clientOperationId": "A String", # [Output Only] Reserved for future use. 188 "creationTimestamp": "A String", # [Deprecated] This field is deprecated. 189 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server. 190 "zone": "A String", # [Output Only] The URL of the zone where the operation resides. Only available when performing per-zone operations. 191 "insertTime": "A String", # [Output Only] The time that this operation was requested. This value is in RFC3339 text format. 192 "operationType": "A String", # [Output Only] The type of operation, such as insert, update, or delete, and so on. 193 "httpErrorMessage": "A String", # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND. 194 "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. 195 "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. 196 "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation. 197 "status": "A String", # [Output Only] The status of the operation, which can be one of the following: PENDING, RUNNING, or DONE. 198 "description": "A String", # [Output Only] A textual description of the operation, which is set when the operation is created. 199 "warnings": [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated. 200 { 201 "message": "A String", # [Output Only] A human-readable description of the warning code. 202 "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. 203 "data": [ # [Output Only] Metadata about this warning in key: value format. For example: 204 # "data": [ { "key": "scope", "value": "zones/us-east1-d" } 205 { 206 "value": "A String", # [Output Only] A warning data value corresponding to the key. 207 "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). 208 }, 209 ], 210 }, 211 ], 212 "user": "A String", # [Output Only] User who requested the operation, for example: user (a] example.com. 213 "startTime": "A String", # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format. 214 "kind": "compute#operation", # [Output Only] Type of the resource. Always compute#operation for Operation resources. 215 "name": "A String", # [Output Only] Name of the resource. 216 "region": "A String", # [Output Only] The URL of the region where the operation resides. Only available when performing regional operations. 217 "error": { # [Output Only] If errors are generated during processing of the operation, this field will be populated. 218 "errors": [ # [Output Only] The array of errors encountered while processing this operation. 219 { 220 "message": "A String", # [Output Only] An optional, human-readable error message. 221 "code": "A String", # [Output Only] The error type identifier for this error. 222 "location": "A String", # [Output Only] Indicates the field in the request that caused the error. This property is optional. 223 }, 224 ], 225 }, 226 "endTime": "A String", # [Output Only] The time that this operation was completed. This value is in RFC3339 text format. 227 "selfLink": "A String", # [Output Only] Server-defined URL for the resource. 228 "targetLink": "A String", # [Output Only] The URL of the resource that the operation modifies. For operations related to creating a snapshot, this points to the persistent disk that the snapshot was created from. 229 }</pre> 230 </div> 231 232 <div class="method"> 233 <code class="details" id="get">get(project, network)</code> 234 <pre>Returns the specified network. Get a list of available networks by making a list() request. 235 236 Args: 237 project: string, Project ID for this request. (required) 238 network: string, Name of the network to return. (required) 239 240 Returns: 241 An object of the form: 242 243 { # Represents a Network resource. Read Networks and Firewalls for more information. 244 "kind": "compute#network", # [Output Only] Type of the resource. Always compute#network for networks. 245 "description": "A String", # An optional description of this resource. Provide this property when you create the resource. 246 "loadBalancerVmEncryption": "A String", # [Output Only] Type of LB-to-VM traffic encryption for this network. 247 "subnetworks": [ # [Output Only] Server-defined fully-qualified URLs for all subnetworks in this network. 248 "A String", 249 ], 250 "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. 251 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server. 252 "IPv4Range": "A String", # The range of internal addresses that are legal on this network. This range is a CIDR specification, for example: 192.168.0.0/16. Provided by the client when the network is created. 253 "gatewayIPv4": "A String", # A gateway address for default routing to other networks. This value is read only and is selected by the Google Compute Engine, typically as the first usable address in the IPv4Range. 254 "routingConfig": { # A routing configuration attached to a network resource. The message includes the list of routers associated with the network, and a flag indicating the type of routing behavior to enforce network-wide. # The network-level routing configuration for this network. Used by Cloud Router to determine what type of network-wide routing behavior to enforce. 255 "routingMode": "A String", # The network-wide routing mode to use. If set to REGIONAL, this network's cloud routers will only advertise routes with subnetworks of this network in the same region as the router. If set to GLOBAL, this network's cloud routers will advertise routes with all subnetworks of this network, across regions. 256 }, 257 "peerings": [ # [Output Only] List of network peerings for the resource. 258 { # A network peering attached to a network resource. The message includes the peering name, peer network, peering state, and a flag indicating whether Google Compute Engine should automatically create routes for the peering. 259 "network": "A String", # The URL of the peer network. It can be either full URL or partial URL. The peer network may belong to a different project. If the partial URL does not contain project, it is assumed that the peer network is in the same project as the current network. 260 "state": "A String", # [Output Only] State for the peering. 261 "stateDetails": "A String", # [Output Only] Details about the current state of the peering. 262 "name": "A String", # Name of this peering. Provided by the client when the peering is created. The name must comply with RFC1035. Specifically, the name must be 1-63 characters long and match regular expression [a-z]([-a-z0-9]*[a-z0-9])? which means the first character must be a lowercase letter, and all the following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. 263 "autoCreateRoutes": True or False, # Whether full mesh connectivity is created and managed automatically. When it is set to true, Google Compute Engine will automatically create and manage the routes between two networks when the state is ACTIVE. Otherwise, user needs to create routes manually to route packets to peer network. 264 }, 265 ], 266 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format. 267 "autoCreateSubnetworks": True or False, # When set to true, the network is created in "auto subnet mode". When set to false, the network is in "custom subnet mode". 268 # 269 # In "auto subnet mode", a newly created network is assigned the default CIDR of 10.128.0.0/9 and it automatically creates one subnetwork per region. 270 "selfLink": "A String", # [Output Only] Server-defined URL for the resource. 271 "crossVmEncryption": "A String", # [Output Only] Type of VM-to-VM traffic encryption for this network. 272 }</pre> 273 </div> 274 275 <div class="method"> 276 <code class="details" id="insert">insert(project, body, requestId=None)</code> 277 <pre>Creates a network in the specified project using the data included in the request. 278 279 Args: 280 project: string, Project ID for this request. (required) 281 body: object, The request body. (required) 282 The object takes the form of: 283 284 { # Represents a Network resource. Read Networks and Firewalls for more information. 285 "kind": "compute#network", # [Output Only] Type of the resource. Always compute#network for networks. 286 "description": "A String", # An optional description of this resource. Provide this property when you create the resource. 287 "loadBalancerVmEncryption": "A String", # [Output Only] Type of LB-to-VM traffic encryption for this network. 288 "subnetworks": [ # [Output Only] Server-defined fully-qualified URLs for all subnetworks in this network. 289 "A String", 290 ], 291 "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. 292 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server. 293 "IPv4Range": "A String", # The range of internal addresses that are legal on this network. This range is a CIDR specification, for example: 192.168.0.0/16. Provided by the client when the network is created. 294 "gatewayIPv4": "A String", # A gateway address for default routing to other networks. This value is read only and is selected by the Google Compute Engine, typically as the first usable address in the IPv4Range. 295 "routingConfig": { # A routing configuration attached to a network resource. The message includes the list of routers associated with the network, and a flag indicating the type of routing behavior to enforce network-wide. # The network-level routing configuration for this network. Used by Cloud Router to determine what type of network-wide routing behavior to enforce. 296 "routingMode": "A String", # The network-wide routing mode to use. If set to REGIONAL, this network's cloud routers will only advertise routes with subnetworks of this network in the same region as the router. If set to GLOBAL, this network's cloud routers will advertise routes with all subnetworks of this network, across regions. 297 }, 298 "peerings": [ # [Output Only] List of network peerings for the resource. 299 { # A network peering attached to a network resource. The message includes the peering name, peer network, peering state, and a flag indicating whether Google Compute Engine should automatically create routes for the peering. 300 "network": "A String", # The URL of the peer network. It can be either full URL or partial URL. The peer network may belong to a different project. If the partial URL does not contain project, it is assumed that the peer network is in the same project as the current network. 301 "state": "A String", # [Output Only] State for the peering. 302 "stateDetails": "A String", # [Output Only] Details about the current state of the peering. 303 "name": "A String", # Name of this peering. Provided by the client when the peering is created. The name must comply with RFC1035. Specifically, the name must be 1-63 characters long and match regular expression [a-z]([-a-z0-9]*[a-z0-9])? which means the first character must be a lowercase letter, and all the following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. 304 "autoCreateRoutes": True or False, # Whether full mesh connectivity is created and managed automatically. When it is set to true, Google Compute Engine will automatically create and manage the routes between two networks when the state is ACTIVE. Otherwise, user needs to create routes manually to route packets to peer network. 305 }, 306 ], 307 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format. 308 "autoCreateSubnetworks": True or False, # When set to true, the network is created in "auto subnet mode". When set to false, the network is in "custom subnet mode". 309 # 310 # In "auto subnet mode", a newly created network is assigned the default CIDR of 10.128.0.0/9 and it automatically creates one subnetwork per region. 311 "selfLink": "A String", # [Output Only] Server-defined URL for the resource. 312 "crossVmEncryption": "A String", # [Output Only] Type of VM-to-VM traffic encryption for this network. 313 } 314 315 requestId: string, begin_interface: MixerMutationRequestBuilder Request ID to support idempotency. 316 317 Returns: 318 An object of the form: 319 320 { # An Operation resource, used to manage asynchronous API requests. 321 "targetId": "A String", # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource. 322 "clientOperationId": "A String", # [Output Only] Reserved for future use. 323 "creationTimestamp": "A String", # [Deprecated] This field is deprecated. 324 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server. 325 "zone": "A String", # [Output Only] The URL of the zone where the operation resides. Only available when performing per-zone operations. 326 "insertTime": "A String", # [Output Only] The time that this operation was requested. This value is in RFC3339 text format. 327 "operationType": "A String", # [Output Only] The type of operation, such as insert, update, or delete, and so on. 328 "httpErrorMessage": "A String", # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND. 329 "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. 330 "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. 331 "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation. 332 "status": "A String", # [Output Only] The status of the operation, which can be one of the following: PENDING, RUNNING, or DONE. 333 "description": "A String", # [Output Only] A textual description of the operation, which is set when the operation is created. 334 "warnings": [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated. 335 { 336 "message": "A String", # [Output Only] A human-readable description of the warning code. 337 "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. 338 "data": [ # [Output Only] Metadata about this warning in key: value format. For example: 339 # "data": [ { "key": "scope", "value": "zones/us-east1-d" } 340 { 341 "value": "A String", # [Output Only] A warning data value corresponding to the key. 342 "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). 343 }, 344 ], 345 }, 346 ], 347 "user": "A String", # [Output Only] User who requested the operation, for example: user (a] example.com. 348 "startTime": "A String", # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format. 349 "kind": "compute#operation", # [Output Only] Type of the resource. Always compute#operation for Operation resources. 350 "name": "A String", # [Output Only] Name of the resource. 351 "region": "A String", # [Output Only] The URL of the region where the operation resides. Only available when performing regional operations. 352 "error": { # [Output Only] If errors are generated during processing of the operation, this field will be populated. 353 "errors": [ # [Output Only] The array of errors encountered while processing this operation. 354 { 355 "message": "A String", # [Output Only] An optional, human-readable error message. 356 "code": "A String", # [Output Only] The error type identifier for this error. 357 "location": "A String", # [Output Only] Indicates the field in the request that caused the error. This property is optional. 358 }, 359 ], 360 }, 361 "endTime": "A String", # [Output Only] The time that this operation was completed. This value is in RFC3339 text format. 362 "selfLink": "A String", # [Output Only] Server-defined URL for the resource. 363 "targetLink": "A String", # [Output Only] The URL of the resource that the operation modifies. For operations related to creating a snapshot, this points to the persistent disk that the snapshot was created from. 364 }</pre> 365 </div> 366 367 <div class="method"> 368 <code class="details" id="list">list(project, orderBy=None, maxResults=None, pageToken=None, filter=None)</code> 369 <pre>Retrieves the list of networks available to the specified project. 370 371 Args: 372 project: string, Project ID for this request. (required) 373 orderBy: string, Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. 374 375 You can also sort results in descending order based on the creation timestamp using orderBy="creationTimestamp desc". This sorts results based on the creationTimestamp field in reverse chronological order (newest result first). Use this to sort resources like operations so that the newest operation is returned first. 376 377 Currently, only sorting by name or creationTimestamp desc is supported. 378 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. Acceptable values are 0 to 500, inclusive. (Default: 500) 379 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. 380 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. 381 382 The 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. 383 384 For example, to filter for instances that do not have a name of example-instance, you would use filter=name ne example-instance. 385 386 You 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. 387 388 To 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. 389 390 Returns: 391 An object of the form: 392 393 { # Contains a list of networks. 394 "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. 395 "items": [ # [Output Only] A list of Network resources. 396 { # Represents a Network resource. Read Networks and Firewalls for more information. 397 "kind": "compute#network", # [Output Only] Type of the resource. Always compute#network for networks. 398 "description": "A String", # An optional description of this resource. Provide this property when you create the resource. 399 "loadBalancerVmEncryption": "A String", # [Output Only] Type of LB-to-VM traffic encryption for this network. 400 "subnetworks": [ # [Output Only] Server-defined fully-qualified URLs for all subnetworks in this network. 401 "A String", 402 ], 403 "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. 404 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server. 405 "IPv4Range": "A String", # The range of internal addresses that are legal on this network. This range is a CIDR specification, for example: 192.168.0.0/16. Provided by the client when the network is created. 406 "gatewayIPv4": "A String", # A gateway address for default routing to other networks. This value is read only and is selected by the Google Compute Engine, typically as the first usable address in the IPv4Range. 407 "routingConfig": { # A routing configuration attached to a network resource. The message includes the list of routers associated with the network, and a flag indicating the type of routing behavior to enforce network-wide. # The network-level routing configuration for this network. Used by Cloud Router to determine what type of network-wide routing behavior to enforce. 408 "routingMode": "A String", # The network-wide routing mode to use. If set to REGIONAL, this network's cloud routers will only advertise routes with subnetworks of this network in the same region as the router. If set to GLOBAL, this network's cloud routers will advertise routes with all subnetworks of this network, across regions. 409 }, 410 "peerings": [ # [Output Only] List of network peerings for the resource. 411 { # A network peering attached to a network resource. The message includes the peering name, peer network, peering state, and a flag indicating whether Google Compute Engine should automatically create routes for the peering. 412 "network": "A String", # The URL of the peer network. It can be either full URL or partial URL. The peer network may belong to a different project. If the partial URL does not contain project, it is assumed that the peer network is in the same project as the current network. 413 "state": "A String", # [Output Only] State for the peering. 414 "stateDetails": "A String", # [Output Only] Details about the current state of the peering. 415 "name": "A String", # Name of this peering. Provided by the client when the peering is created. The name must comply with RFC1035. Specifically, the name must be 1-63 characters long and match regular expression [a-z]([-a-z0-9]*[a-z0-9])? which means the first character must be a lowercase letter, and all the following characters must be a dash, lowercase letter, or digit, except the last character, which cannot be a dash. 416 "autoCreateRoutes": True or False, # Whether full mesh connectivity is created and managed automatically. When it is set to true, Google Compute Engine will automatically create and manage the routes between two networks when the state is ACTIVE. Otherwise, user needs to create routes manually to route packets to peer network. 417 }, 418 ], 419 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format. 420 "autoCreateSubnetworks": True or False, # When set to true, the network is created in "auto subnet mode". When set to false, the network is in "custom subnet mode". 421 # 422 # In "auto subnet mode", a newly created network is assigned the default CIDR of 10.128.0.0/9 and it automatically creates one subnetwork per region. 423 "selfLink": "A String", # [Output Only] Server-defined URL for the resource. 424 "crossVmEncryption": "A String", # [Output Only] Type of VM-to-VM traffic encryption for this network. 425 }, 426 ], 427 "kind": "compute#networkList", # [Output Only] Type of resource. Always compute#networkList for lists of networks. 428 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server. 429 "selfLink": "A String", # [Output Only] Server-defined URL for this resource. 430 }</pre> 431 </div> 432 433 <div class="method"> 434 <code class="details" id="list_next">list_next(previous_request, previous_response)</code> 435 <pre>Retrieves the next page of results. 436 437 Args: 438 previous_request: The request for the previous page. (required) 439 previous_response: The response from the request for the previous page. (required) 440 441 Returns: 442 A request object that you can call 'execute()' on to request the next 443 page. Returns None if there are no more items in the collection. 444 </pre> 445 </div> 446 447 <div class="method"> 448 <code class="details" id="removePeering">removePeering(project, network, body, requestId=None)</code> 449 <pre>Removes a peering from the specified network. 450 451 Args: 452 project: string, Project ID for this request. (required) 453 network: string, Name of the network resource to remove peering from. (required) 454 body: object, The request body. (required) 455 The object takes the form of: 456 457 { 458 "name": "A String", # Name of the peering, which should conform to RFC1035. 459 } 460 461 requestId: string, begin_interface: MixerMutationRequestBuilder Request ID to support idempotency. 462 463 Returns: 464 An object of the form: 465 466 { # An Operation resource, used to manage asynchronous API requests. 467 "targetId": "A String", # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource. 468 "clientOperationId": "A String", # [Output Only] Reserved for future use. 469 "creationTimestamp": "A String", # [Deprecated] This field is deprecated. 470 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server. 471 "zone": "A String", # [Output Only] The URL of the zone where the operation resides. Only available when performing per-zone operations. 472 "insertTime": "A String", # [Output Only] The time that this operation was requested. This value is in RFC3339 text format. 473 "operationType": "A String", # [Output Only] The type of operation, such as insert, update, or delete, and so on. 474 "httpErrorMessage": "A String", # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND. 475 "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. 476 "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. 477 "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation. 478 "status": "A String", # [Output Only] The status of the operation, which can be one of the following: PENDING, RUNNING, or DONE. 479 "description": "A String", # [Output Only] A textual description of the operation, which is set when the operation is created. 480 "warnings": [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated. 481 { 482 "message": "A String", # [Output Only] A human-readable description of the warning code. 483 "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. 484 "data": [ # [Output Only] Metadata about this warning in key: value format. For example: 485 # "data": [ { "key": "scope", "value": "zones/us-east1-d" } 486 { 487 "value": "A String", # [Output Only] A warning data value corresponding to the key. 488 "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). 489 }, 490 ], 491 }, 492 ], 493 "user": "A String", # [Output Only] User who requested the operation, for example: user (a] example.com. 494 "startTime": "A String", # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format. 495 "kind": "compute#operation", # [Output Only] Type of the resource. Always compute#operation for Operation resources. 496 "name": "A String", # [Output Only] Name of the resource. 497 "region": "A String", # [Output Only] The URL of the region where the operation resides. Only available when performing regional operations. 498 "error": { # [Output Only] If errors are generated during processing of the operation, this field will be populated. 499 "errors": [ # [Output Only] The array of errors encountered while processing this operation. 500 { 501 "message": "A String", # [Output Only] An optional, human-readable error message. 502 "code": "A String", # [Output Only] The error type identifier for this error. 503 "location": "A String", # [Output Only] Indicates the field in the request that caused the error. This property is optional. 504 }, 505 ], 506 }, 507 "endTime": "A String", # [Output Only] The time that this operation was completed. This value is in RFC3339 text format. 508 "selfLink": "A String", # [Output Only] Server-defined URL for the resource. 509 "targetLink": "A String", # [Output Only] The URL of the resource that the operation modifies. For operations related to creating a snapshot, this points to the persistent disk that the snapshot was created from. 510 }</pre> 511 </div> 512 513 <div class="method"> 514 <code class="details" id="switchToCustomMode">switchToCustomMode(project, network, requestId=None)</code> 515 <pre>Switches the network mode from auto subnet mode to custom subnet mode. 516 517 Args: 518 project: string, Project ID for this request. (required) 519 network: string, Name of the network to be updated. (required) 520 requestId: string, begin_interface: MixerMutationRequestBuilder Request ID to support idempotency. 521 522 Returns: 523 An object of the form: 524 525 { # An Operation resource, used to manage asynchronous API requests. 526 "targetId": "A String", # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource. 527 "clientOperationId": "A String", # [Output Only] Reserved for future use. 528 "creationTimestamp": "A String", # [Deprecated] This field is deprecated. 529 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server. 530 "zone": "A String", # [Output Only] The URL of the zone where the operation resides. Only available when performing per-zone operations. 531 "insertTime": "A String", # [Output Only] The time that this operation was requested. This value is in RFC3339 text format. 532 "operationType": "A String", # [Output Only] The type of operation, such as insert, update, or delete, and so on. 533 "httpErrorMessage": "A String", # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND. 534 "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. 535 "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. 536 "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation. 537 "status": "A String", # [Output Only] The status of the operation, which can be one of the following: PENDING, RUNNING, or DONE. 538 "description": "A String", # [Output Only] A textual description of the operation, which is set when the operation is created. 539 "warnings": [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated. 540 { 541 "message": "A String", # [Output Only] A human-readable description of the warning code. 542 "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. 543 "data": [ # [Output Only] Metadata about this warning in key: value format. For example: 544 # "data": [ { "key": "scope", "value": "zones/us-east1-d" } 545 { 546 "value": "A String", # [Output Only] A warning data value corresponding to the key. 547 "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). 548 }, 549 ], 550 }, 551 ], 552 "user": "A String", # [Output Only] User who requested the operation, for example: user (a] example.com. 553 "startTime": "A String", # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format. 554 "kind": "compute#operation", # [Output Only] Type of the resource. Always compute#operation for Operation resources. 555 "name": "A String", # [Output Only] Name of the resource. 556 "region": "A String", # [Output Only] The URL of the region where the operation resides. Only available when performing regional operations. 557 "error": { # [Output Only] If errors are generated during processing of the operation, this field will be populated. 558 "errors": [ # [Output Only] The array of errors encountered while processing this operation. 559 { 560 "message": "A String", # [Output Only] An optional, human-readable error message. 561 "code": "A String", # [Output Only] The error type identifier for this error. 562 "location": "A String", # [Output Only] Indicates the field in the request that caused the error. This property is optional. 563 }, 564 ], 565 }, 566 "endTime": "A String", # [Output Only] The time that this operation was completed. This value is in RFC3339 text format. 567 "selfLink": "A String", # [Output Only] Server-defined URL for the resource. 568 "targetLink": "A String", # [Output Only] The URL of the resource that the operation modifies. For operations related to creating a snapshot, this points to the persistent disk that the snapshot was created from. 569 }</pre> 570 </div> 571 572 <div class="method"> 573 <code class="details" id="testIamPermissions">testIamPermissions(project, resource, body)</code> 574 <pre>Returns permissions that a caller has on the specified resource. 575 576 Args: 577 project: string, Project ID for this request. (required) 578 resource: string, Name of the resource for this request. (required) 579 body: object, The request body. (required) 580 The object takes the form of: 581 582 { 583 "permissions": [ # The set of permissions to check for the 'resource'. Permissions with wildcards (such as '*' or 'storage.*') are not allowed. 584 "A String", 585 ], 586 } 587 588 589 Returns: 590 An object of the form: 591 592 { 593 "permissions": [ # A subset of `TestPermissionsRequest.permissions` that the caller is allowed. 594 "A String", 595 ], 596 }</pre> 597 </div> 598 599 </body></html>