1<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.forwardingRules.html">forwardingRules</a></h1> 76<h2>Instance Methods</h2> 77<p class="toc_element"> 78 <code><a href="#aggregatedList">aggregatedList(project, orderBy=None, maxResults=None, pageToken=None, filter=None)</a></code></p> 79<p class="firstline">Retrieves an aggregated list of forwarding rules.</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, forwardingRule, requestId=None)</a></code></p> 85<p class="firstline">Deletes the specified ForwardingRule resource.</p> 86<p class="toc_element"> 87 <code><a href="#get">get(project, region, forwardingRule)</a></code></p> 88<p class="firstline">Returns the specified ForwardingRule resource.</p> 89<p class="toc_element"> 90 <code><a href="#insert">insert(project, region, body, requestId=None)</a></code></p> 91<p class="firstline">Creates a ForwardingRule resource in the specified project and region using the data included in the request.</p> 92<p class="toc_element"> 93 <code><a href="#list">list(project, region, orderBy=None, maxResults=None, pageToken=None, filter=None)</a></code></p> 94<p class="firstline">Retrieves a list of ForwardingRule resources available to the specified project and region.</p> 95<p class="toc_element"> 96 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p> 97<p class="firstline">Retrieves the next page of results.</p> 98<p class="toc_element"> 99 <code><a href="#setTarget">setTarget(project, region, forwardingRule, body, requestId=None)</a></code></p> 100<p class="firstline">Changes target URL for forwarding rule. The new target should be of the same type as the old target.</p> 101<h3>Method Details</h3> 102<div class="method"> 103 <code class="details" id="aggregatedList">aggregatedList(project, orderBy=None, maxResults=None, pageToken=None, filter=None)</code> 104 <pre>Retrieves an aggregated list of forwarding rules. 105 106Args: 107 project: string, Project ID for this request. (required) 108 orderBy: string, Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. 109 110You 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. 111 112Currently, only sorting by name or creationTimestamp desc is supported. 113 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) 114 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. 115 filter: string, A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. 116 117For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. 118 119You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. 120 121To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). 122 123Returns: 124 An object of the form: 125 126 { 127 "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. 128 "kind": "compute#forwardingRuleAggregatedList", # [Output Only] Type of resource. Always compute#forwardingRuleAggregatedList for lists of forwarding rules. 129 "items": { # A list of ForwardingRulesScopedList resources. 130 "a_key": { # Name of the scope containing this set of addresses. 131 "forwardingRules": [ # A list of forwarding rules contained in this scope. 132 { # A ForwardingRule resource. A ForwardingRule resource specifies which pool of target virtual machines to forward a packet to if it matches the given [IPAddress, IPProtocol, ports] tuple. (== resource_for beta.forwardingRules ==) (== resource_for v1.forwardingRules ==) (== resource_for beta.globalForwardingRules ==) (== resource_for v1.globalForwardingRules ==) (== resource_for beta.regionForwardingRules ==) (== resource_for v1.regionForwardingRules ==) 133 "kind": "compute#forwardingRule", # [Output Only] Type of the resource. Always compute#forwardingRule for Forwarding Rule resources. 134 "target": "A String", # The URL of the target resource to receive the matched traffic. For regional forwarding rules, this target must live in the same region as the forwarding rule. For global forwarding rules, this target must be a global load balancing resource. The forwarded traffic must be of a type appropriate to the target object. For INTERNAL_SELF_MANAGED load balancing, only HTTP and HTTPS targets are valid. 135 "description": "A String", # An optional description of this resource. Provide this property when you create the resource. 136 "serviceName": "A String", # [Output Only] The internal fully qualified service name for this Forwarding Rule. 137 # 138 # This field is only used for internal load balancing. 139 "networkTier": "A String", # This signifies the networking tier used for configuring this load balancer and can only take the following values: PREMIUM , STANDARD. 140 # 141 # For regional ForwardingRule, the valid values are PREMIUM and STANDARD. For GlobalForwardingRule, the valid value is PREMIUM. 142 # 143 # If this field is not specified, it is assumed to be PREMIUM. If IPAddress is specified, this value must be equal to the networkTier of the Address. 144 "IPAddress": "A String", # The IP address that this forwarding rule is serving on behalf of. 145 # 146 # Addresses are restricted based on the forwarding rule's load balancing scheme (EXTERNAL or INTERNAL) and scope (global or regional). 147 # 148 # When the load balancing scheme is EXTERNAL, for global forwarding rules, the address must be a global IP, and for regional forwarding rules, the address must live in the same region as the forwarding rule. If this field is empty, an ephemeral IPv4 address from the same scope (global or regional) will be assigned. A regional forwarding rule supports IPv4 only. A global forwarding rule supports either IPv4 or IPv6. 149 # 150 # When the load balancing scheme is INTERNAL_SELF_MANAGED, this must be a URL reference to an existing Address resource ( internal regional static IP address), with a purpose of GCE_END_POINT and address_type of INTERNAL. 151 # 152 # When the load balancing scheme is INTERNAL, this can only be an RFC 1918 IP address belonging to the network/subnet configured for the forwarding rule. By default, if this field is empty, an ephemeral internal IP address will be automatically allocated from the IP range of the subnet or network configured for this forwarding rule. 153 # 154 # An address can be specified either by a literal IP address or a URL reference to an existing Address resource. The following examples are all valid: 155 # - 100.1.2.3 156 # - https://www.googleapis.com/compute/v1/projects/project/regions/region/addresses/address 157 # - projects/project/regions/region/addresses/address 158 # - regions/region/addresses/address 159 # - global/addresses/address 160 # - address 161 "region": "A String", # [Output Only] URL of the region where the regional forwarding rule resides. This field is not applicable to global forwarding rules. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. 162 "allPorts": True or False, # This field is used along with the backend_service field for internal load balancing or with the target field for internal TargetInstance. This field cannot be used with port or portRange fields. 163 # 164 # When the load balancing scheme is INTERNAL and protocol is TCP/UDP, specify this field to allow packets addressed to any ports will be forwarded to the backends configured with this forwarding rule. 165 "ports": [ # This field is used along with the backend_service field for internal load balancing. 166 # 167 # When the load balancing scheme is INTERNAL, a list of ports can be configured, for example, ['80'], ['8000','9000'] etc. Only packets addressed to these ports will be forwarded to the backends configured with this forwarding rule. 168 # 169 # You may specify a maximum of up to 5 ports. 170 "A String", 171 ], 172 "ipVersion": "A String", # The IP Version that will be used by this forwarding rule. Valid options are IPV4 or IPV6. This can only be specified for an external global forwarding rule. 173 "network": "A String", # This field is not used for external load balancing. 174 # 175 # For INTERNAL and INTERNAL_SELF_MANAGED load balancing, this field identifies the network that the load balanced IP should belong to for this Forwarding Rule. If this field is not specified, the default network will be used. 176 "loadBalancingScheme": "A String", # This signifies what the ForwardingRule will be used for and can only take the following values: INTERNAL, INTERNAL_SELF_MANAGED, EXTERNAL. The value of INTERNAL means that this will be used for Internal Network Load Balancing (TCP, UDP). The value of INTERNAL_SELF_MANAGED means that this will be used for Internal Global HTTP(S) LB. The value of EXTERNAL means that this will be used for External Load Balancing (HTTP(S) LB, External TCP/UDP LB, SSL Proxy) 177 "serviceLabel": "A String", # An optional prefix to the service name for this Forwarding Rule. If specified, will be the first label of the fully qualified service name. 178 # 179 # The label must be 1-63 characters long, and comply with RFC1035. Specifically, the label 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. 180 # 181 # This field is only used for internal load balancing. 182 "portRange": "A String", # This field is used along with the target field for TargetHttpProxy, TargetHttpsProxy, TargetSslProxy, TargetTcpProxy, TargetVpnGateway, TargetPool, TargetInstance. 183 # 184 # Applicable only when IPProtocol is TCP, UDP, or SCTP, only packets addressed to ports in the specified range will be forwarded to target. Forwarding rules with the same [IPAddress, IPProtocol] pair must have disjoint port ranges. 185 # 186 # Some types of forwarding target have constraints on the acceptable ports: 187 # - TargetHttpProxy: 80, 8080 188 # - TargetHttpsProxy: 443 189 # - TargetTcpProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 190 # - TargetSslProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 191 # - TargetVpnGateway: 500, 4500 192 "backendService": "A String", # This field is only used for INTERNAL load balancing. 193 # 194 # For internal load balancing, this field identifies the BackendService resource to receive the matched traffic. 195 "IPProtocol": "A String", # The IP protocol to which this rule applies. Valid options are TCP, UDP, ESP, AH, SCTP or ICMP. 196 # 197 # When the load balancing scheme is INTERNAL, only TCP and UDP are valid. When the load balancing scheme is INTERNAL_SELF_MANAGED, only TCPis valid. 198 "subnetwork": "A String", # This field is only used for INTERNAL load balancing. 199 # 200 # For internal load balancing, this field identifies the subnetwork that the load balanced IP should belong to for this Forwarding Rule. 201 # 202 # If the network specified is in auto subnet mode, this field is optional. However, if the network is in custom subnet mode, a subnetwork must be specified. 203 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format. 204 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server. 205 "selfLink": "A String", # [Output Only] Server-defined URL for the resource. 206 "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. 207 }, 208 ], 209 "warning": { # Informational warning which replaces the list of forwarding rules when the list is empty. 210 "message": "A String", # [Output Only] A human-readable description of the warning code. 211 "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. 212 "data": [ # [Output Only] Metadata about this warning in key: value format. For example: 213 # "data": [ { "key": "scope", "value": "zones/us-east1-d" } 214 { 215 "value": "A String", # [Output Only] A warning data value corresponding to the key. 216 "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). 217 }, 218 ], 219 }, 220 }, 221 }, 222 "warning": { # [Output Only] Informational warning message. 223 "message": "A String", # [Output Only] A human-readable description of the warning code. 224 "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. 225 "data": [ # [Output Only] Metadata about this warning in key: value format. For example: 226 # "data": [ { "key": "scope", "value": "zones/us-east1-d" } 227 { 228 "value": "A String", # [Output Only] A warning data value corresponding to the key. 229 "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). 230 }, 231 ], 232 }, 233 "id": "A String", # [Output Only] Unique identifier for the resource; defined by the server. 234 "selfLink": "A String", # [Output Only] Server-defined URL for this resource. 235 }</pre> 236</div> 237 238<div class="method"> 239 <code class="details" id="aggregatedList_next">aggregatedList_next(previous_request, previous_response)</code> 240 <pre>Retrieves the next page of results. 241 242Args: 243 previous_request: The request for the previous page. (required) 244 previous_response: The response from the request for the previous page. (required) 245 246Returns: 247 A request object that you can call 'execute()' on to request the next 248 page. Returns None if there are no more items in the collection. 249 </pre> 250</div> 251 252<div class="method"> 253 <code class="details" id="delete">delete(project, region, forwardingRule, requestId=None)</code> 254 <pre>Deletes the specified ForwardingRule resource. 255 256Args: 257 project: string, Project ID for this request. (required) 258 region: string, Name of the region scoping this request. (required) 259 forwardingRule: string, Name of the ForwardingRule resource to delete. (required) 260 requestId: string, An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. 261 262For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. 263 264The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). 265 266Returns: 267 An object of the form: 268 269 { # Represents an Operation resource. 270 # 271 # You can use an operation resource to manage asynchronous API requests. For more information, read Handling API responses. 272 # 273 # Operations can be global, regional or zonal. 274 # - For global operations, use the globalOperations resource. 275 # - For regional operations, use the regionOperations resource. 276 # - For zonal operations, use the zonalOperations resource. 277 # 278 # For more information, read Global, Regional, and Zonal Resources. (== resource_for v1.globalOperations ==) (== resource_for beta.globalOperations ==) (== resource_for v1.regionOperations ==) (== resource_for beta.regionOperations ==) (== resource_for v1.zoneOperations ==) (== resource_for beta.zoneOperations ==) 279 "targetId": "A String", # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource. 280 "clientOperationId": "A String", # [Output Only] The value of `requestId` if you provided it in the request. Not present otherwise. 281 "creationTimestamp": "A String", # [Deprecated] This field is deprecated. 282 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server. 283 "zone": "A String", # [Output Only] The URL of the zone where the operation resides. Only applicable when performing per-zone operations. 284 "insertTime": "A String", # [Output Only] The time that this operation was requested. This value is in RFC3339 text format. 285 "operationType": "A String", # [Output Only] The type of operation, such as insert, update, or delete, and so on. 286 "httpErrorMessage": "A String", # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND. 287 "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. 288 "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. 289 "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation. 290 "status": "A String", # [Output Only] The status of the operation, which can be one of the following: PENDING, RUNNING, or DONE. 291 "description": "A String", # [Output Only] A textual description of the operation, which is set when the operation is created. 292 "warnings": [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated. 293 { 294 "message": "A String", # [Output Only] A human-readable description of the warning code. 295 "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. 296 "data": [ # [Output Only] Metadata about this warning in key: value format. For example: 297 # "data": [ { "key": "scope", "value": "zones/us-east1-d" } 298 { 299 "value": "A String", # [Output Only] A warning data value corresponding to the key. 300 "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). 301 }, 302 ], 303 }, 304 ], 305 "user": "A String", # [Output Only] User who requested the operation, for example: user@example.com. 306 "startTime": "A String", # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format. 307 "kind": "compute#operation", # [Output Only] Type of the resource. Always compute#operation for Operation resources. 308 "name": "A String", # [Output Only] Name of the resource. 309 "region": "A String", # [Output Only] The URL of the region where the operation resides. Only applicable when performing regional operations. 310 "error": { # [Output Only] If errors are generated during processing of the operation, this field will be populated. 311 "errors": [ # [Output Only] The array of errors encountered while processing this operation. 312 { 313 "message": "A String", # [Output Only] An optional, human-readable error message. 314 "code": "A String", # [Output Only] The error type identifier for this error. 315 "location": "A String", # [Output Only] Indicates the field in the request that caused the error. This property is optional. 316 }, 317 ], 318 }, 319 "endTime": "A String", # [Output Only] The time that this operation was completed. This value is in RFC3339 text format. 320 "selfLink": "A String", # [Output Only] Server-defined URL for the resource. 321 "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. 322 }</pre> 323</div> 324 325<div class="method"> 326 <code class="details" id="get">get(project, region, forwardingRule)</code> 327 <pre>Returns the specified ForwardingRule resource. 328 329Args: 330 project: string, Project ID for this request. (required) 331 region: string, Name of the region scoping this request. (required) 332 forwardingRule: string, Name of the ForwardingRule resource to return. (required) 333 334Returns: 335 An object of the form: 336 337 { # A ForwardingRule resource. A ForwardingRule resource specifies which pool of target virtual machines to forward a packet to if it matches the given [IPAddress, IPProtocol, ports] tuple. (== resource_for beta.forwardingRules ==) (== resource_for v1.forwardingRules ==) (== resource_for beta.globalForwardingRules ==) (== resource_for v1.globalForwardingRules ==) (== resource_for beta.regionForwardingRules ==) (== resource_for v1.regionForwardingRules ==) 338 "kind": "compute#forwardingRule", # [Output Only] Type of the resource. Always compute#forwardingRule for Forwarding Rule resources. 339 "target": "A String", # The URL of the target resource to receive the matched traffic. For regional forwarding rules, this target must live in the same region as the forwarding rule. For global forwarding rules, this target must be a global load balancing resource. The forwarded traffic must be of a type appropriate to the target object. For INTERNAL_SELF_MANAGED load balancing, only HTTP and HTTPS targets are valid. 340 "description": "A String", # An optional description of this resource. Provide this property when you create the resource. 341 "serviceName": "A String", # [Output Only] The internal fully qualified service name for this Forwarding Rule. 342 # 343 # This field is only used for internal load balancing. 344 "networkTier": "A String", # This signifies the networking tier used for configuring this load balancer and can only take the following values: PREMIUM , STANDARD. 345 # 346 # For regional ForwardingRule, the valid values are PREMIUM and STANDARD. For GlobalForwardingRule, the valid value is PREMIUM. 347 # 348 # If this field is not specified, it is assumed to be PREMIUM. If IPAddress is specified, this value must be equal to the networkTier of the Address. 349 "IPAddress": "A String", # The IP address that this forwarding rule is serving on behalf of. 350 # 351 # Addresses are restricted based on the forwarding rule's load balancing scheme (EXTERNAL or INTERNAL) and scope (global or regional). 352 # 353 # When the load balancing scheme is EXTERNAL, for global forwarding rules, the address must be a global IP, and for regional forwarding rules, the address must live in the same region as the forwarding rule. If this field is empty, an ephemeral IPv4 address from the same scope (global or regional) will be assigned. A regional forwarding rule supports IPv4 only. A global forwarding rule supports either IPv4 or IPv6. 354 # 355 # When the load balancing scheme is INTERNAL_SELF_MANAGED, this must be a URL reference to an existing Address resource ( internal regional static IP address), with a purpose of GCE_END_POINT and address_type of INTERNAL. 356 # 357 # When the load balancing scheme is INTERNAL, this can only be an RFC 1918 IP address belonging to the network/subnet configured for the forwarding rule. By default, if this field is empty, an ephemeral internal IP address will be automatically allocated from the IP range of the subnet or network configured for this forwarding rule. 358 # 359 # An address can be specified either by a literal IP address or a URL reference to an existing Address resource. The following examples are all valid: 360 # - 100.1.2.3 361 # - https://www.googleapis.com/compute/v1/projects/project/regions/region/addresses/address 362 # - projects/project/regions/region/addresses/address 363 # - regions/region/addresses/address 364 # - global/addresses/address 365 # - address 366 "region": "A String", # [Output Only] URL of the region where the regional forwarding rule resides. This field is not applicable to global forwarding rules. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. 367 "allPorts": True or False, # This field is used along with the backend_service field for internal load balancing or with the target field for internal TargetInstance. This field cannot be used with port or portRange fields. 368 # 369 # When the load balancing scheme is INTERNAL and protocol is TCP/UDP, specify this field to allow packets addressed to any ports will be forwarded to the backends configured with this forwarding rule. 370 "ports": [ # This field is used along with the backend_service field for internal load balancing. 371 # 372 # When the load balancing scheme is INTERNAL, a list of ports can be configured, for example, ['80'], ['8000','9000'] etc. Only packets addressed to these ports will be forwarded to the backends configured with this forwarding rule. 373 # 374 # You may specify a maximum of up to 5 ports. 375 "A String", 376 ], 377 "ipVersion": "A String", # The IP Version that will be used by this forwarding rule. Valid options are IPV4 or IPV6. This can only be specified for an external global forwarding rule. 378 "network": "A String", # This field is not used for external load balancing. 379 # 380 # For INTERNAL and INTERNAL_SELF_MANAGED load balancing, this field identifies the network that the load balanced IP should belong to for this Forwarding Rule. If this field is not specified, the default network will be used. 381 "loadBalancingScheme": "A String", # This signifies what the ForwardingRule will be used for and can only take the following values: INTERNAL, INTERNAL_SELF_MANAGED, EXTERNAL. The value of INTERNAL means that this will be used for Internal Network Load Balancing (TCP, UDP). The value of INTERNAL_SELF_MANAGED means that this will be used for Internal Global HTTP(S) LB. The value of EXTERNAL means that this will be used for External Load Balancing (HTTP(S) LB, External TCP/UDP LB, SSL Proxy) 382 "serviceLabel": "A String", # An optional prefix to the service name for this Forwarding Rule. If specified, will be the first label of the fully qualified service name. 383 # 384 # The label must be 1-63 characters long, and comply with RFC1035. Specifically, the label 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. 385 # 386 # This field is only used for internal load balancing. 387 "portRange": "A String", # This field is used along with the target field for TargetHttpProxy, TargetHttpsProxy, TargetSslProxy, TargetTcpProxy, TargetVpnGateway, TargetPool, TargetInstance. 388 # 389 # Applicable only when IPProtocol is TCP, UDP, or SCTP, only packets addressed to ports in the specified range will be forwarded to target. Forwarding rules with the same [IPAddress, IPProtocol] pair must have disjoint port ranges. 390 # 391 # Some types of forwarding target have constraints on the acceptable ports: 392 # - TargetHttpProxy: 80, 8080 393 # - TargetHttpsProxy: 443 394 # - TargetTcpProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 395 # - TargetSslProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 396 # - TargetVpnGateway: 500, 4500 397 "backendService": "A String", # This field is only used for INTERNAL load balancing. 398 # 399 # For internal load balancing, this field identifies the BackendService resource to receive the matched traffic. 400 "IPProtocol": "A String", # The IP protocol to which this rule applies. Valid options are TCP, UDP, ESP, AH, SCTP or ICMP. 401 # 402 # When the load balancing scheme is INTERNAL, only TCP and UDP are valid. When the load balancing scheme is INTERNAL_SELF_MANAGED, only TCPis valid. 403 "subnetwork": "A String", # This field is only used for INTERNAL load balancing. 404 # 405 # For internal load balancing, this field identifies the subnetwork that the load balanced IP should belong to for this Forwarding Rule. 406 # 407 # If the network specified is in auto subnet mode, this field is optional. However, if the network is in custom subnet mode, a subnetwork must be specified. 408 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format. 409 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server. 410 "selfLink": "A String", # [Output Only] Server-defined URL for the resource. 411 "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. 412 }</pre> 413</div> 414 415<div class="method"> 416 <code class="details" id="insert">insert(project, region, body, requestId=None)</code> 417 <pre>Creates a ForwardingRule 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 scoping this request. (required) 422 body: object, The request body. (required) 423 The object takes the form of: 424 425{ # A ForwardingRule resource. A ForwardingRule resource specifies which pool of target virtual machines to forward a packet to if it matches the given [IPAddress, IPProtocol, ports] tuple. (== resource_for beta.forwardingRules ==) (== resource_for v1.forwardingRules ==) (== resource_for beta.globalForwardingRules ==) (== resource_for v1.globalForwardingRules ==) (== resource_for beta.regionForwardingRules ==) (== resource_for v1.regionForwardingRules ==) 426 "kind": "compute#forwardingRule", # [Output Only] Type of the resource. Always compute#forwardingRule for Forwarding Rule resources. 427 "target": "A String", # The URL of the target resource to receive the matched traffic. For regional forwarding rules, this target must live in the same region as the forwarding rule. For global forwarding rules, this target must be a global load balancing resource. The forwarded traffic must be of a type appropriate to the target object. For INTERNAL_SELF_MANAGED load balancing, only HTTP and HTTPS targets are valid. 428 "description": "A String", # An optional description of this resource. Provide this property when you create the resource. 429 "serviceName": "A String", # [Output Only] The internal fully qualified service name for this Forwarding Rule. 430 # 431 # This field is only used for internal load balancing. 432 "networkTier": "A String", # This signifies the networking tier used for configuring this load balancer and can only take the following values: PREMIUM , STANDARD. 433 # 434 # For regional ForwardingRule, the valid values are PREMIUM and STANDARD. For GlobalForwardingRule, the valid value is PREMIUM. 435 # 436 # If this field is not specified, it is assumed to be PREMIUM. If IPAddress is specified, this value must be equal to the networkTier of the Address. 437 "IPAddress": "A String", # The IP address that this forwarding rule is serving on behalf of. 438 # 439 # Addresses are restricted based on the forwarding rule's load balancing scheme (EXTERNAL or INTERNAL) and scope (global or regional). 440 # 441 # When the load balancing scheme is EXTERNAL, for global forwarding rules, the address must be a global IP, and for regional forwarding rules, the address must live in the same region as the forwarding rule. If this field is empty, an ephemeral IPv4 address from the same scope (global or regional) will be assigned. A regional forwarding rule supports IPv4 only. A global forwarding rule supports either IPv4 or IPv6. 442 # 443 # When the load balancing scheme is INTERNAL_SELF_MANAGED, this must be a URL reference to an existing Address resource ( internal regional static IP address), with a purpose of GCE_END_POINT and address_type of INTERNAL. 444 # 445 # When the load balancing scheme is INTERNAL, this can only be an RFC 1918 IP address belonging to the network/subnet configured for the forwarding rule. By default, if this field is empty, an ephemeral internal IP address will be automatically allocated from the IP range of the subnet or network configured for this forwarding rule. 446 # 447 # An address can be specified either by a literal IP address or a URL reference to an existing Address resource. The following examples are all valid: 448 # - 100.1.2.3 449 # - https://www.googleapis.com/compute/v1/projects/project/regions/region/addresses/address 450 # - projects/project/regions/region/addresses/address 451 # - regions/region/addresses/address 452 # - global/addresses/address 453 # - address 454 "region": "A String", # [Output Only] URL of the region where the regional forwarding rule resides. This field is not applicable to global forwarding rules. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. 455 "allPorts": True or False, # This field is used along with the backend_service field for internal load balancing or with the target field for internal TargetInstance. This field cannot be used with port or portRange fields. 456 # 457 # When the load balancing scheme is INTERNAL and protocol is TCP/UDP, specify this field to allow packets addressed to any ports will be forwarded to the backends configured with this forwarding rule. 458 "ports": [ # This field is used along with the backend_service field for internal load balancing. 459 # 460 # When the load balancing scheme is INTERNAL, a list of ports can be configured, for example, ['80'], ['8000','9000'] etc. Only packets addressed to these ports will be forwarded to the backends configured with this forwarding rule. 461 # 462 # You may specify a maximum of up to 5 ports. 463 "A String", 464 ], 465 "ipVersion": "A String", # The IP Version that will be used by this forwarding rule. Valid options are IPV4 or IPV6. This can only be specified for an external global forwarding rule. 466 "network": "A String", # This field is not used for external load balancing. 467 # 468 # For INTERNAL and INTERNAL_SELF_MANAGED load balancing, this field identifies the network that the load balanced IP should belong to for this Forwarding Rule. If this field is not specified, the default network will be used. 469 "loadBalancingScheme": "A String", # This signifies what the ForwardingRule will be used for and can only take the following values: INTERNAL, INTERNAL_SELF_MANAGED, EXTERNAL. The value of INTERNAL means that this will be used for Internal Network Load Balancing (TCP, UDP). The value of INTERNAL_SELF_MANAGED means that this will be used for Internal Global HTTP(S) LB. The value of EXTERNAL means that this will be used for External Load Balancing (HTTP(S) LB, External TCP/UDP LB, SSL Proxy) 470 "serviceLabel": "A String", # An optional prefix to the service name for this Forwarding Rule. If specified, will be the first label of the fully qualified service name. 471 # 472 # The label must be 1-63 characters long, and comply with RFC1035. Specifically, the label 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. 473 # 474 # This field is only used for internal load balancing. 475 "portRange": "A String", # This field is used along with the target field for TargetHttpProxy, TargetHttpsProxy, TargetSslProxy, TargetTcpProxy, TargetVpnGateway, TargetPool, TargetInstance. 476 # 477 # Applicable only when IPProtocol is TCP, UDP, or SCTP, only packets addressed to ports in the specified range will be forwarded to target. Forwarding rules with the same [IPAddress, IPProtocol] pair must have disjoint port ranges. 478 # 479 # Some types of forwarding target have constraints on the acceptable ports: 480 # - TargetHttpProxy: 80, 8080 481 # - TargetHttpsProxy: 443 482 # - TargetTcpProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 483 # - TargetSslProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 484 # - TargetVpnGateway: 500, 4500 485 "backendService": "A String", # This field is only used for INTERNAL load balancing. 486 # 487 # For internal load balancing, this field identifies the BackendService resource to receive the matched traffic. 488 "IPProtocol": "A String", # The IP protocol to which this rule applies. Valid options are TCP, UDP, ESP, AH, SCTP or ICMP. 489 # 490 # When the load balancing scheme is INTERNAL, only TCP and UDP are valid. When the load balancing scheme is INTERNAL_SELF_MANAGED, only TCPis valid. 491 "subnetwork": "A String", # This field is only used for INTERNAL load balancing. 492 # 493 # For internal load balancing, this field identifies the subnetwork that the load balanced IP should belong to for this Forwarding Rule. 494 # 495 # If the network specified is in auto subnet mode, this field is optional. However, if the network is in custom subnet mode, a subnetwork must be specified. 496 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format. 497 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server. 498 "selfLink": "A String", # [Output Only] Server-defined URL for the resource. 499 "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. 500 } 501 502 requestId: string, An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. 503 504For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. 505 506The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). 507 508Returns: 509 An object of the form: 510 511 { # Represents an Operation resource. 512 # 513 # You can use an operation resource to manage asynchronous API requests. For more information, read Handling API responses. 514 # 515 # Operations can be global, regional or zonal. 516 # - For global operations, use the globalOperations resource. 517 # - For regional operations, use the regionOperations resource. 518 # - For zonal operations, use the zonalOperations resource. 519 # 520 # For more information, read Global, Regional, and Zonal Resources. (== resource_for v1.globalOperations ==) (== resource_for beta.globalOperations ==) (== resource_for v1.regionOperations ==) (== resource_for beta.regionOperations ==) (== resource_for v1.zoneOperations ==) (== resource_for beta.zoneOperations ==) 521 "targetId": "A String", # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource. 522 "clientOperationId": "A String", # [Output Only] The value of `requestId` if you provided it in the request. Not present otherwise. 523 "creationTimestamp": "A String", # [Deprecated] This field is deprecated. 524 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server. 525 "zone": "A String", # [Output Only] The URL of the zone where the operation resides. Only applicable when performing per-zone operations. 526 "insertTime": "A String", # [Output Only] The time that this operation was requested. This value is in RFC3339 text format. 527 "operationType": "A String", # [Output Only] The type of operation, such as insert, update, or delete, and so on. 528 "httpErrorMessage": "A String", # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND. 529 "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. 530 "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. 531 "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation. 532 "status": "A String", # [Output Only] The status of the operation, which can be one of the following: PENDING, RUNNING, or DONE. 533 "description": "A String", # [Output Only] A textual description of the operation, which is set when the operation is created. 534 "warnings": [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated. 535 { 536 "message": "A String", # [Output Only] A human-readable description of the warning code. 537 "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. 538 "data": [ # [Output Only] Metadata about this warning in key: value format. For example: 539 # "data": [ { "key": "scope", "value": "zones/us-east1-d" } 540 { 541 "value": "A String", # [Output Only] A warning data value corresponding to the key. 542 "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). 543 }, 544 ], 545 }, 546 ], 547 "user": "A String", # [Output Only] User who requested the operation, for example: user@example.com. 548 "startTime": "A String", # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format. 549 "kind": "compute#operation", # [Output Only] Type of the resource. Always compute#operation for Operation resources. 550 "name": "A String", # [Output Only] Name of the resource. 551 "region": "A String", # [Output Only] The URL of the region where the operation resides. Only applicable when performing regional operations. 552 "error": { # [Output Only] If errors are generated during processing of the operation, this field will be populated. 553 "errors": [ # [Output Only] The array of errors encountered while processing this operation. 554 { 555 "message": "A String", # [Output Only] An optional, human-readable error message. 556 "code": "A String", # [Output Only] The error type identifier for this error. 557 "location": "A String", # [Output Only] Indicates the field in the request that caused the error. This property is optional. 558 }, 559 ], 560 }, 561 "endTime": "A String", # [Output Only] The time that this operation was completed. This value is in RFC3339 text format. 562 "selfLink": "A String", # [Output Only] Server-defined URL for the resource. 563 "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. 564 }</pre> 565</div> 566 567<div class="method"> 568 <code class="details" id="list">list(project, region, orderBy=None, maxResults=None, pageToken=None, filter=None)</code> 569 <pre>Retrieves a list of ForwardingRule resources available to the specified project and region. 570 571Args: 572 project: string, Project ID for this request. (required) 573 region: string, Name of the region scoping this request. (required) 574 orderBy: string, Sorts list results by a certain order. By default, results are returned in alphanumerical order based on the resource name. 575 576You 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. 577 578Currently, only sorting by name or creationTimestamp desc is supported. 579 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) 580 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. 581 filter: string, A filter expression that filters resources listed in the response. The expression must specify the field name, a comparison operator, and the value that you want to use for filtering. The value must be a string, a number, or a boolean. The comparison operator must be either =, !=, >, or <. 582 583For example, if you are filtering Compute Engine instances, you can exclude instances named example-instance by specifying name != example-instance. 584 585You can also filter nested fields. For example, you could specify scheduling.automaticRestart = false to include instances only if they are not scheduled for automatic restarts. You can use filtering on nested fields to filter based on resource labels. 586 587To filter on multiple expressions, provide each separate expression within parentheses. For example, (scheduling.automaticRestart = true) (cpuPlatform = "Intel Skylake"). By default, each expression is an AND expression. However, you can include AND and OR expressions explicitly. For example, (cpuPlatform = "Intel Skylake") OR (cpuPlatform = "Intel Broadwell") AND (scheduling.automaticRestart = true). 588 589Returns: 590 An object of the form: 591 592 { # Contains a list of ForwardingRule resources. 593 "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. 594 "kind": "compute#forwardingRuleList", # Type of resource. 595 "items": [ # A list of ForwardingRule resources. 596 { # A ForwardingRule resource. A ForwardingRule resource specifies which pool of target virtual machines to forward a packet to if it matches the given [IPAddress, IPProtocol, ports] tuple. (== resource_for beta.forwardingRules ==) (== resource_for v1.forwardingRules ==) (== resource_for beta.globalForwardingRules ==) (== resource_for v1.globalForwardingRules ==) (== resource_for beta.regionForwardingRules ==) (== resource_for v1.regionForwardingRules ==) 597 "kind": "compute#forwardingRule", # [Output Only] Type of the resource. Always compute#forwardingRule for Forwarding Rule resources. 598 "target": "A String", # The URL of the target resource to receive the matched traffic. For regional forwarding rules, this target must live in the same region as the forwarding rule. For global forwarding rules, this target must be a global load balancing resource. The forwarded traffic must be of a type appropriate to the target object. For INTERNAL_SELF_MANAGED load balancing, only HTTP and HTTPS targets are valid. 599 "description": "A String", # An optional description of this resource. Provide this property when you create the resource. 600 "serviceName": "A String", # [Output Only] The internal fully qualified service name for this Forwarding Rule. 601 # 602 # This field is only used for internal load balancing. 603 "networkTier": "A String", # This signifies the networking tier used for configuring this load balancer and can only take the following values: PREMIUM , STANDARD. 604 # 605 # For regional ForwardingRule, the valid values are PREMIUM and STANDARD. For GlobalForwardingRule, the valid value is PREMIUM. 606 # 607 # If this field is not specified, it is assumed to be PREMIUM. If IPAddress is specified, this value must be equal to the networkTier of the Address. 608 "IPAddress": "A String", # The IP address that this forwarding rule is serving on behalf of. 609 # 610 # Addresses are restricted based on the forwarding rule's load balancing scheme (EXTERNAL or INTERNAL) and scope (global or regional). 611 # 612 # When the load balancing scheme is EXTERNAL, for global forwarding rules, the address must be a global IP, and for regional forwarding rules, the address must live in the same region as the forwarding rule. If this field is empty, an ephemeral IPv4 address from the same scope (global or regional) will be assigned. A regional forwarding rule supports IPv4 only. A global forwarding rule supports either IPv4 or IPv6. 613 # 614 # When the load balancing scheme is INTERNAL_SELF_MANAGED, this must be a URL reference to an existing Address resource ( internal regional static IP address), with a purpose of GCE_END_POINT and address_type of INTERNAL. 615 # 616 # When the load balancing scheme is INTERNAL, this can only be an RFC 1918 IP address belonging to the network/subnet configured for the forwarding rule. By default, if this field is empty, an ephemeral internal IP address will be automatically allocated from the IP range of the subnet or network configured for this forwarding rule. 617 # 618 # An address can be specified either by a literal IP address or a URL reference to an existing Address resource. The following examples are all valid: 619 # - 100.1.2.3 620 # - https://www.googleapis.com/compute/v1/projects/project/regions/region/addresses/address 621 # - projects/project/regions/region/addresses/address 622 # - regions/region/addresses/address 623 # - global/addresses/address 624 # - address 625 "region": "A String", # [Output Only] URL of the region where the regional forwarding rule resides. This field is not applicable to global forwarding rules. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. 626 "allPorts": True or False, # This field is used along with the backend_service field for internal load balancing or with the target field for internal TargetInstance. This field cannot be used with port or portRange fields. 627 # 628 # When the load balancing scheme is INTERNAL and protocol is TCP/UDP, specify this field to allow packets addressed to any ports will be forwarded to the backends configured with this forwarding rule. 629 "ports": [ # This field is used along with the backend_service field for internal load balancing. 630 # 631 # When the load balancing scheme is INTERNAL, a list of ports can be configured, for example, ['80'], ['8000','9000'] etc. Only packets addressed to these ports will be forwarded to the backends configured with this forwarding rule. 632 # 633 # You may specify a maximum of up to 5 ports. 634 "A String", 635 ], 636 "ipVersion": "A String", # The IP Version that will be used by this forwarding rule. Valid options are IPV4 or IPV6. This can only be specified for an external global forwarding rule. 637 "network": "A String", # This field is not used for external load balancing. 638 # 639 # For INTERNAL and INTERNAL_SELF_MANAGED load balancing, this field identifies the network that the load balanced IP should belong to for this Forwarding Rule. If this field is not specified, the default network will be used. 640 "loadBalancingScheme": "A String", # This signifies what the ForwardingRule will be used for and can only take the following values: INTERNAL, INTERNAL_SELF_MANAGED, EXTERNAL. The value of INTERNAL means that this will be used for Internal Network Load Balancing (TCP, UDP). The value of INTERNAL_SELF_MANAGED means that this will be used for Internal Global HTTP(S) LB. The value of EXTERNAL means that this will be used for External Load Balancing (HTTP(S) LB, External TCP/UDP LB, SSL Proxy) 641 "serviceLabel": "A String", # An optional prefix to the service name for this Forwarding Rule. If specified, will be the first label of the fully qualified service name. 642 # 643 # The label must be 1-63 characters long, and comply with RFC1035. Specifically, the label 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. 644 # 645 # This field is only used for internal load balancing. 646 "portRange": "A String", # This field is used along with the target field for TargetHttpProxy, TargetHttpsProxy, TargetSslProxy, TargetTcpProxy, TargetVpnGateway, TargetPool, TargetInstance. 647 # 648 # Applicable only when IPProtocol is TCP, UDP, or SCTP, only packets addressed to ports in the specified range will be forwarded to target. Forwarding rules with the same [IPAddress, IPProtocol] pair must have disjoint port ranges. 649 # 650 # Some types of forwarding target have constraints on the acceptable ports: 651 # - TargetHttpProxy: 80, 8080 652 # - TargetHttpsProxy: 443 653 # - TargetTcpProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 654 # - TargetSslProxy: 25, 43, 110, 143, 195, 443, 465, 587, 700, 993, 995, 1688, 1883, 5222 655 # - TargetVpnGateway: 500, 4500 656 "backendService": "A String", # This field is only used for INTERNAL load balancing. 657 # 658 # For internal load balancing, this field identifies the BackendService resource to receive the matched traffic. 659 "IPProtocol": "A String", # The IP protocol to which this rule applies. Valid options are TCP, UDP, ESP, AH, SCTP or ICMP. 660 # 661 # When the load balancing scheme is INTERNAL, only TCP and UDP are valid. When the load balancing scheme is INTERNAL_SELF_MANAGED, only TCPis valid. 662 "subnetwork": "A String", # This field is only used for INTERNAL load balancing. 663 # 664 # For internal load balancing, this field identifies the subnetwork that the load balanced IP should belong to for this Forwarding Rule. 665 # 666 # If the network specified is in auto subnet mode, this field is optional. However, if the network is in custom subnet mode, a subnetwork must be specified. 667 "creationTimestamp": "A String", # [Output Only] Creation timestamp in RFC3339 text format. 668 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server. 669 "selfLink": "A String", # [Output Only] Server-defined URL for the resource. 670 "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. 671 }, 672 ], 673 "warning": { # [Output Only] Informational warning message. 674 "message": "A String", # [Output Only] A human-readable description of the warning code. 675 "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. 676 "data": [ # [Output Only] Metadata about this warning in key: value format. For example: 677 # "data": [ { "key": "scope", "value": "zones/us-east1-d" } 678 { 679 "value": "A String", # [Output Only] A warning data value corresponding to the key. 680 "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). 681 }, 682 ], 683 }, 684 "id": "A String", # [Output Only] Unique identifier for the resource; defined by the server. 685 "selfLink": "A String", # [Output Only] Server-defined URL for this resource. 686 }</pre> 687</div> 688 689<div class="method"> 690 <code class="details" id="list_next">list_next(previous_request, previous_response)</code> 691 <pre>Retrieves the next page of results. 692 693Args: 694 previous_request: The request for the previous page. (required) 695 previous_response: The response from the request for the previous page. (required) 696 697Returns: 698 A request object that you can call 'execute()' on to request the next 699 page. Returns None if there are no more items in the collection. 700 </pre> 701</div> 702 703<div class="method"> 704 <code class="details" id="setTarget">setTarget(project, region, forwardingRule, body, requestId=None)</code> 705 <pre>Changes target URL for forwarding rule. The new target should be of the same type as the old target. 706 707Args: 708 project: string, Project ID for this request. (required) 709 region: string, Name of the region scoping this request. (required) 710 forwardingRule: string, Name of the ForwardingRule resource in which target is to be set. (required) 711 body: object, The request body. (required) 712 The object takes the form of: 713 714{ 715 "target": "A String", 716 } 717 718 requestId: string, An optional request ID to identify requests. Specify a unique request ID so that if you must retry your request, the server will know to ignore the request if it has already been completed. 719 720For example, consider a situation where you make an initial request and the request times out. If you make the request again with the same request ID, the server can check if original operation with the same request ID was received, and if so, will ignore the second request. This prevents clients from accidentally creating duplicate commitments. 721 722The request ID must be a valid UUID with the exception that zero UUID is not supported (00000000-0000-0000-0000-000000000000). 723 724Returns: 725 An object of the form: 726 727 { # Represents an Operation resource. 728 # 729 # You can use an operation resource to manage asynchronous API requests. For more information, read Handling API responses. 730 # 731 # Operations can be global, regional or zonal. 732 # - For global operations, use the globalOperations resource. 733 # - For regional operations, use the regionOperations resource. 734 # - For zonal operations, use the zonalOperations resource. 735 # 736 # For more information, read Global, Regional, and Zonal Resources. (== resource_for v1.globalOperations ==) (== resource_for beta.globalOperations ==) (== resource_for v1.regionOperations ==) (== resource_for beta.regionOperations ==) (== resource_for v1.zoneOperations ==) (== resource_for beta.zoneOperations ==) 737 "targetId": "A String", # [Output Only] The unique target ID, which identifies a specific incarnation of the target resource. 738 "clientOperationId": "A String", # [Output Only] The value of `requestId` if you provided it in the request. Not present otherwise. 739 "creationTimestamp": "A String", # [Deprecated] This field is deprecated. 740 "id": "A String", # [Output Only] The unique identifier for the resource. This identifier is defined by the server. 741 "zone": "A String", # [Output Only] The URL of the zone where the operation resides. Only applicable when performing per-zone operations. 742 "insertTime": "A String", # [Output Only] The time that this operation was requested. This value is in RFC3339 text format. 743 "operationType": "A String", # [Output Only] The type of operation, such as insert, update, or delete, and so on. 744 "httpErrorMessage": "A String", # [Output Only] If the operation fails, this field contains the HTTP error message that was returned, such as NOT FOUND. 745 "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. 746 "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. 747 "statusMessage": "A String", # [Output Only] An optional textual description of the current status of the operation. 748 "status": "A String", # [Output Only] The status of the operation, which can be one of the following: PENDING, RUNNING, or DONE. 749 "description": "A String", # [Output Only] A textual description of the operation, which is set when the operation is created. 750 "warnings": [ # [Output Only] If warning messages are generated during processing of the operation, this field will be populated. 751 { 752 "message": "A String", # [Output Only] A human-readable description of the warning code. 753 "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. 754 "data": [ # [Output Only] Metadata about this warning in key: value format. For example: 755 # "data": [ { "key": "scope", "value": "zones/us-east1-d" } 756 { 757 "value": "A String", # [Output Only] A warning data value corresponding to the key. 758 "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). 759 }, 760 ], 761 }, 762 ], 763 "user": "A String", # [Output Only] User who requested the operation, for example: user@example.com. 764 "startTime": "A String", # [Output Only] The time that this operation was started by the server. This value is in RFC3339 text format. 765 "kind": "compute#operation", # [Output Only] Type of the resource. Always compute#operation for Operation resources. 766 "name": "A String", # [Output Only] Name of the resource. 767 "region": "A String", # [Output Only] The URL of the region where the operation resides. Only applicable when performing regional operations. 768 "error": { # [Output Only] If errors are generated during processing of the operation, this field will be populated. 769 "errors": [ # [Output Only] The array of errors encountered while processing this operation. 770 { 771 "message": "A String", # [Output Only] An optional, human-readable error message. 772 "code": "A String", # [Output Only] The error type identifier for this error. 773 "location": "A String", # [Output Only] Indicates the field in the request that caused the error. This property is optional. 774 }, 775 ], 776 }, 777 "endTime": "A String", # [Output Only] The time that this operation was completed. This value is in RFC3339 text format. 778 "selfLink": "A String", # [Output Only] Server-defined URL for the resource. 779 "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. 780 }</pre> 781</div> 782 783</body></html>