...

Source file src/google.golang.org/api/appengine/v1beta4/appengine-gen.go

Documentation: google.golang.org/api/appengine/v1beta4

     1  // Copyright 2021 Google LLC.
     2  // Use of this source code is governed by a BSD-style
     3  // license that can be found in the LICENSE file.
     4  
     5  // Code generated file. DO NOT EDIT.
     6  
     7  // Package appengine provides access to the App Engine Admin API.
     8  //
     9  // For product documentation, see: https://cloud.google.com/appengine/docs/admin-api/
    10  //
    11  // # Creating a client
    12  //
    13  // Usage example:
    14  //
    15  //	import "google.golang.org/api/appengine/v1beta4"
    16  //	...
    17  //	ctx := context.Background()
    18  //	appengineService, err := appengine.NewService(ctx)
    19  //
    20  // In this example, Google Application Default Credentials are used for authentication.
    21  //
    22  // For information on how to create and obtain Application Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials.
    23  //
    24  // # Other authentication options
    25  //
    26  // By default, all available scopes (see "Constants") are used to authenticate. To restrict scopes, use option.WithScopes:
    27  //
    28  //	appengineService, err := appengine.NewService(ctx, option.WithScopes(appengine.CloudPlatformReadOnlyScope))
    29  //
    30  // To use an API key for authentication (note: some APIs do not support API keys), use option.WithAPIKey:
    31  //
    32  //	appengineService, err := appengine.NewService(ctx, option.WithAPIKey("AIza..."))
    33  //
    34  // To use an OAuth token (e.g., a user token obtained via a three-legged OAuth flow), use option.WithTokenSource:
    35  //
    36  //	config := &oauth2.Config{...}
    37  //	// ...
    38  //	token, err := config.Exchange(ctx, ...)
    39  //	appengineService, err := appengine.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
    40  //
    41  // See https://godoc.org/google.golang.org/api/option/ for details on options.
    42  package appengine // import "google.golang.org/api/appengine/v1beta4"
    43  
    44  import (
    45  	"bytes"
    46  	"context"
    47  	"encoding/json"
    48  	"errors"
    49  	"fmt"
    50  	"io"
    51  	"net/http"
    52  	"net/url"
    53  	"strconv"
    54  	"strings"
    55  
    56  	googleapi "google.golang.org/api/googleapi"
    57  	gensupport "google.golang.org/api/internal/gensupport"
    58  	option "google.golang.org/api/option"
    59  	internaloption "google.golang.org/api/option/internaloption"
    60  	htransport "google.golang.org/api/transport/http"
    61  )
    62  
    63  // Always reference these packages, just in case the auto-generated code
    64  // below doesn't.
    65  var _ = bytes.NewBuffer
    66  var _ = strconv.Itoa
    67  var _ = fmt.Sprintf
    68  var _ = json.NewDecoder
    69  var _ = io.Copy
    70  var _ = url.Parse
    71  var _ = gensupport.MarshalJSON
    72  var _ = googleapi.Version
    73  var _ = errors.New
    74  var _ = strings.Replace
    75  var _ = context.Canceled
    76  var _ = internaloption.WithDefaultEndpoint
    77  
    78  const apiId = "appengine:v1beta4"
    79  const apiName = "appengine"
    80  const apiVersion = "v1beta4"
    81  const basePath = "https://appengine.googleapis.com/"
    82  
    83  // OAuth2 scopes used by this API.
    84  const (
    85  	// View and manage your applications deployed on Google App Engine
    86  	AppengineAdminScope = "https://www.googleapis.com/auth/appengine.admin"
    87  
    88  	// View and manage your data across Google Cloud Platform services
    89  	CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform"
    90  
    91  	// View your data across Google Cloud Platform services
    92  	CloudPlatformReadOnlyScope = "https://www.googleapis.com/auth/cloud-platform.read-only"
    93  )
    94  
    95  // NewService creates a new APIService.
    96  func NewService(ctx context.Context, opts ...option.ClientOption) (*APIService, error) {
    97  	scopesOption := option.WithScopes(
    98  		"https://www.googleapis.com/auth/appengine.admin",
    99  		"https://www.googleapis.com/auth/cloud-platform",
   100  		"https://www.googleapis.com/auth/cloud-platform.read-only",
   101  	)
   102  	// NOTE: prepend, so we don't override user-specified scopes.
   103  	opts = append([]option.ClientOption{scopesOption}, opts...)
   104  	opts = append(opts, internaloption.WithDefaultEndpoint(basePath))
   105  	client, endpoint, err := htransport.NewClient(ctx, opts...)
   106  	if err != nil {
   107  		return nil, err
   108  	}
   109  	s, err := New(client)
   110  	if err != nil {
   111  		return nil, err
   112  	}
   113  	if endpoint != "" {
   114  		s.BasePath = endpoint
   115  	}
   116  	return s, nil
   117  }
   118  
   119  // New creates a new APIService. It uses the provided http.Client for requests.
   120  //
   121  // Deprecated: please use NewService instead.
   122  // To provide a custom HTTP client, use option.WithHTTPClient.
   123  // If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
   124  func New(client *http.Client) (*APIService, error) {
   125  	if client == nil {
   126  		return nil, errors.New("client is nil")
   127  	}
   128  	s := &APIService{client: client, BasePath: basePath}
   129  	s.Apps = NewAppsService(s)
   130  	return s, nil
   131  }
   132  
   133  type APIService struct {
   134  	client    *http.Client
   135  	BasePath  string // API endpoint base URL
   136  	UserAgent string // optional additional User-Agent fragment
   137  
   138  	Apps *AppsService
   139  }
   140  
   141  func (s *APIService) userAgent() string {
   142  	if s.UserAgent == "" {
   143  		return googleapi.UserAgent
   144  	}
   145  	return googleapi.UserAgent + " " + s.UserAgent
   146  }
   147  
   148  func NewAppsService(s *APIService) *AppsService {
   149  	rs := &AppsService{s: s}
   150  	rs.Locations = NewAppsLocationsService(s)
   151  	rs.Modules = NewAppsModulesService(s)
   152  	rs.Operations = NewAppsOperationsService(s)
   153  	return rs
   154  }
   155  
   156  type AppsService struct {
   157  	s *APIService
   158  
   159  	Locations *AppsLocationsService
   160  
   161  	Modules *AppsModulesService
   162  
   163  	Operations *AppsOperationsService
   164  }
   165  
   166  func NewAppsLocationsService(s *APIService) *AppsLocationsService {
   167  	rs := &AppsLocationsService{s: s}
   168  	return rs
   169  }
   170  
   171  type AppsLocationsService struct {
   172  	s *APIService
   173  }
   174  
   175  func NewAppsModulesService(s *APIService) *AppsModulesService {
   176  	rs := &AppsModulesService{s: s}
   177  	rs.Versions = NewAppsModulesVersionsService(s)
   178  	return rs
   179  }
   180  
   181  type AppsModulesService struct {
   182  	s *APIService
   183  
   184  	Versions *AppsModulesVersionsService
   185  }
   186  
   187  func NewAppsModulesVersionsService(s *APIService) *AppsModulesVersionsService {
   188  	rs := &AppsModulesVersionsService{s: s}
   189  	rs.Instances = NewAppsModulesVersionsInstancesService(s)
   190  	return rs
   191  }
   192  
   193  type AppsModulesVersionsService struct {
   194  	s *APIService
   195  
   196  	Instances *AppsModulesVersionsInstancesService
   197  }
   198  
   199  func NewAppsModulesVersionsInstancesService(s *APIService) *AppsModulesVersionsInstancesService {
   200  	rs := &AppsModulesVersionsInstancesService{s: s}
   201  	return rs
   202  }
   203  
   204  type AppsModulesVersionsInstancesService struct {
   205  	s *APIService
   206  }
   207  
   208  func NewAppsOperationsService(s *APIService) *AppsOperationsService {
   209  	rs := &AppsOperationsService{s: s}
   210  	return rs
   211  }
   212  
   213  type AppsOperationsService struct {
   214  	s *APIService
   215  }
   216  
   217  // ApiConfigHandler: Google Cloud Endpoints
   218  // (https://cloud.google.com/appengine/docs/python/endpoints/)
   219  // configuration for API handlers.
   220  type ApiConfigHandler struct {
   221  	// AuthFailAction: Action to take when users access resources that
   222  	// require authentication. Defaults to redirect.
   223  	//
   224  	// Possible values:
   225  	//   "AUTH_FAIL_ACTION_UNSPECIFIED" - Not specified.
   226  	// AUTH_FAIL_ACTION_REDIRECT is assumed.
   227  	//   "AUTH_FAIL_ACTION_REDIRECT" - Redirects user to
   228  	// "accounts.google.com". The user is redirected back to the application
   229  	// URL after signing in or creating an account.
   230  	//   "AUTH_FAIL_ACTION_UNAUTHORIZED" - Rejects request with a 401 HTTP
   231  	// status code and an error message.
   232  	AuthFailAction string `json:"authFailAction,omitempty"`
   233  
   234  	// Login: Level of login required to access this resource. Defaults to
   235  	// optional.
   236  	//
   237  	// Possible values:
   238  	//   "LOGIN_UNSPECIFIED" - Not specified. LOGIN_OPTIONAL is assumed.
   239  	//   "LOGIN_OPTIONAL" - Does not require that the user is signed in.
   240  	//   "LOGIN_ADMIN" - If the user is not signed in, the auth_fail_action
   241  	// is taken. In addition, if the user is not an administrator for the
   242  	// application, they are given an error message regardless of
   243  	// auth_fail_action. If the user is an administrator, the handler
   244  	// proceeds.
   245  	//   "LOGIN_REQUIRED" - If the user has signed in, the handler proceeds
   246  	// normally. Otherwise, the auth_fail_action is taken.
   247  	Login string `json:"login,omitempty"`
   248  
   249  	// Script: Path to the script from the application root directory.
   250  	Script string `json:"script,omitempty"`
   251  
   252  	// SecurityLevel: Security (HTTPS) enforcement for this URL.
   253  	//
   254  	// Possible values:
   255  	//   "SECURE_UNSPECIFIED" - Not specified.
   256  	//   "SECURE_DEFAULT" - Both HTTP and HTTPS requests with URLs that
   257  	// match the handler succeed without redirects. The application can
   258  	// examine the request to determine which protocol was used, and respond
   259  	// accordingly.
   260  	//   "SECURE_NEVER" - Requests for a URL that match this handler that
   261  	// use HTTPS are automatically redirected to the HTTP equivalent URL.
   262  	//   "SECURE_OPTIONAL" - Both HTTP and HTTPS requests with URLs that
   263  	// match the handler succeed without redirects. The application can
   264  	// examine the request to determine which protocol was used and respond
   265  	// accordingly.
   266  	//   "SECURE_ALWAYS" - Requests for a URL that match this handler that
   267  	// do not use HTTPS are automatically redirected to the HTTPS URL with
   268  	// the same path. Query parameters are reserved for the redirect.
   269  	SecurityLevel string `json:"securityLevel,omitempty"`
   270  
   271  	// Url: URL to serve the endpoint at.
   272  	Url string `json:"url,omitempty"`
   273  
   274  	// ForceSendFields is a list of field names (e.g. "AuthFailAction") to
   275  	// unconditionally include in API requests. By default, fields with
   276  	// empty values are omitted from API requests. However, any non-pointer,
   277  	// non-interface field appearing in ForceSendFields will be sent to the
   278  	// server regardless of whether the field is empty or not. This may be
   279  	// used to include empty fields in Patch requests.
   280  	ForceSendFields []string `json:"-"`
   281  
   282  	// NullFields is a list of field names (e.g. "AuthFailAction") to
   283  	// include in API requests with the JSON null value. By default, fields
   284  	// with empty values are omitted from API requests. However, any field
   285  	// with an empty value appearing in NullFields will be sent to the
   286  	// server as null. It is an error if a field in this list has a
   287  	// non-empty value. This may be used to include null fields in Patch
   288  	// requests.
   289  	NullFields []string `json:"-"`
   290  }
   291  
   292  func (s *ApiConfigHandler) MarshalJSON() ([]byte, error) {
   293  	type NoMethod ApiConfigHandler
   294  	raw := NoMethod(*s)
   295  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
   296  }
   297  
   298  // ApiEndpointHandler: Uses Google Cloud Endpoints to handle requests.
   299  type ApiEndpointHandler struct {
   300  	// ScriptPath: Path to the script from the application root directory.
   301  	ScriptPath string `json:"scriptPath,omitempty"`
   302  
   303  	// ForceSendFields is a list of field names (e.g. "ScriptPath") to
   304  	// unconditionally include in API requests. By default, fields with
   305  	// empty values are omitted from API requests. However, any non-pointer,
   306  	// non-interface field appearing in ForceSendFields will be sent to the
   307  	// server regardless of whether the field is empty or not. This may be
   308  	// used to include empty fields in Patch requests.
   309  	ForceSendFields []string `json:"-"`
   310  
   311  	// NullFields is a list of field names (e.g. "ScriptPath") to include in
   312  	// API requests with the JSON null value. By default, fields with empty
   313  	// values are omitted from API requests. However, any field with an
   314  	// empty value appearing in NullFields will be sent to the server as
   315  	// null. It is an error if a field in this list has a non-empty value.
   316  	// This may be used to include null fields in Patch requests.
   317  	NullFields []string `json:"-"`
   318  }
   319  
   320  func (s *ApiEndpointHandler) MarshalJSON() ([]byte, error) {
   321  	type NoMethod ApiEndpointHandler
   322  	raw := NoMethod(*s)
   323  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
   324  }
   325  
   326  // Application: An Application resource contains the top-level
   327  // configuration of an App Engine application.
   328  type Application struct {
   329  	// AuthDomain: Google Apps authentication domain that controls which
   330  	// users can access this application.Defaults to open access for any
   331  	// Google Account.
   332  	AuthDomain string `json:"authDomain,omitempty"`
   333  
   334  	// CodeBucket: Google Cloud Storage bucket that can be used for storing
   335  	// files associated with this application. This bucket is associated
   336  	// with the application and can be used by the gcloud deployment
   337  	// commands.@OutputOnly
   338  	CodeBucket string `json:"codeBucket,omitempty"`
   339  
   340  	// DefaultBucket: Google Cloud Storage bucket that can be used by this
   341  	// application to store content.@OutputOnly
   342  	DefaultBucket string `json:"defaultBucket,omitempty"`
   343  
   344  	// DefaultCookieExpiration: Cookie expiration policy for this
   345  	// application.
   346  	DefaultCookieExpiration string `json:"defaultCookieExpiration,omitempty"`
   347  
   348  	// DefaultHostname: Hostname used to reach the application, as resolved
   349  	// by App Engine.@OutputOnly
   350  	DefaultHostname string `json:"defaultHostname,omitempty"`
   351  
   352  	// DispatchRules: HTTP path dispatch rules for requests to the
   353  	// application that do not explicitly target a module or version. Rules
   354  	// are order-dependent.@OutputOnly
   355  	DispatchRules []*UrlDispatchRule `json:"dispatchRules,omitempty"`
   356  
   357  	Iap *IdentityAwareProxy `json:"iap,omitempty"`
   358  
   359  	// Id: Identifier of the Application resource. This identifier is
   360  	// equivalent to the project ID of the Google Cloud Platform project
   361  	// where you want to deploy your application. Example: myapp.
   362  	Id string `json:"id,omitempty"`
   363  
   364  	// Location: Location from which this application will be run.
   365  	// Application instances will run out of data centers in the chosen
   366  	// location, which is also where all of the application's end user
   367  	// content is stored.Defaults to us-central.Options are:us-central -
   368  	// Central USeurope-west - Western Europeus-east1 - Eastern US
   369  	Location string `json:"location,omitempty"`
   370  
   371  	// Name: Full path to the Application resource in the API. Example:
   372  	// apps/myapp.@OutputOnly
   373  	Name string `json:"name,omitempty"`
   374  
   375  	// ServerResponse contains the HTTP response code and headers from the
   376  	// server.
   377  	googleapi.ServerResponse `json:"-"`
   378  
   379  	// ForceSendFields is a list of field names (e.g. "AuthDomain") to
   380  	// unconditionally include in API requests. By default, fields with
   381  	// empty values are omitted from API requests. However, any non-pointer,
   382  	// non-interface field appearing in ForceSendFields will be sent to the
   383  	// server regardless of whether the field is empty or not. This may be
   384  	// used to include empty fields in Patch requests.
   385  	ForceSendFields []string `json:"-"`
   386  
   387  	// NullFields is a list of field names (e.g. "AuthDomain") to include in
   388  	// API requests with the JSON null value. By default, fields with empty
   389  	// values are omitted from API requests. However, any field with an
   390  	// empty value appearing in NullFields will be sent to the server as
   391  	// null. It is an error if a field in this list has a non-empty value.
   392  	// This may be used to include null fields in Patch requests.
   393  	NullFields []string `json:"-"`
   394  }
   395  
   396  func (s *Application) MarshalJSON() ([]byte, error) {
   397  	type NoMethod Application
   398  	raw := NoMethod(*s)
   399  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
   400  }
   401  
   402  // AutomaticScaling: Automatic scaling is based on request rate,
   403  // response latencies, and other application metrics.
   404  type AutomaticScaling struct {
   405  	// CoolDownPeriod: The time period that the Autoscaler
   406  	// (https://cloud.google.com/compute/docs/autoscaler/) should wait
   407  	// before it starts collecting information from a new instance. This
   408  	// prevents the autoscaler from collecting information when the instance
   409  	// is initializing, during which the collected usage would not be
   410  	// reliable. Only applicable in the App Engine flexible environment.
   411  	CoolDownPeriod string `json:"coolDownPeriod,omitempty"`
   412  
   413  	// CpuUtilization: Target scaling by CPU usage.
   414  	CpuUtilization *CpuUtilization `json:"cpuUtilization,omitempty"`
   415  
   416  	// DiskUtilization: Target scaling by disk usage.
   417  	DiskUtilization *DiskUtilization `json:"diskUtilization,omitempty"`
   418  
   419  	// MaxConcurrentRequests: Number of concurrent requests an automatic
   420  	// scaling instance can accept before the scheduler spawns a new
   421  	// instance.Defaults to a runtime-specific value.
   422  	MaxConcurrentRequests int64 `json:"maxConcurrentRequests,omitempty"`
   423  
   424  	// MaxIdleInstances: Maximum number of idle instances that should be
   425  	// maintained for this version.
   426  	MaxIdleInstances int64 `json:"maxIdleInstances,omitempty"`
   427  
   428  	// MaxPendingLatency: Maximum amount of time that a request should wait
   429  	// in the pending queue before starting a new instance to handle it.
   430  	MaxPendingLatency string `json:"maxPendingLatency,omitempty"`
   431  
   432  	// MaxTotalInstances: Maximum number of instances that should be started
   433  	// to handle requests.
   434  	MaxTotalInstances int64 `json:"maxTotalInstances,omitempty"`
   435  
   436  	// MinIdleInstances: Minimum number of idle instances that should be
   437  	// maintained for this version. Only applicable for the default version
   438  	// of a module.
   439  	MinIdleInstances int64 `json:"minIdleInstances,omitempty"`
   440  
   441  	// MinPendingLatency: Minimum amount of time a request should wait in
   442  	// the pending queue before starting a new instance to handle it.
   443  	MinPendingLatency string `json:"minPendingLatency,omitempty"`
   444  
   445  	// MinTotalInstances: Minimum number of instances that should be
   446  	// maintained for this version.
   447  	MinTotalInstances int64 `json:"minTotalInstances,omitempty"`
   448  
   449  	// NetworkUtilization: Target scaling by network usage.
   450  	NetworkUtilization *NetworkUtilization `json:"networkUtilization,omitempty"`
   451  
   452  	// RequestUtilization: Target scaling by request utilization.
   453  	RequestUtilization *RequestUtilization `json:"requestUtilization,omitempty"`
   454  
   455  	// ForceSendFields is a list of field names (e.g. "CoolDownPeriod") to
   456  	// unconditionally include in API requests. By default, fields with
   457  	// empty values are omitted from API requests. However, any non-pointer,
   458  	// non-interface field appearing in ForceSendFields will be sent to the
   459  	// server regardless of whether the field is empty or not. This may be
   460  	// used to include empty fields in Patch requests.
   461  	ForceSendFields []string `json:"-"`
   462  
   463  	// NullFields is a list of field names (e.g. "CoolDownPeriod") to
   464  	// include in API requests with the JSON null value. By default, fields
   465  	// with empty values are omitted from API requests. However, any field
   466  	// with an empty value appearing in NullFields will be sent to the
   467  	// server as null. It is an error if a field in this list has a
   468  	// non-empty value. This may be used to include null fields in Patch
   469  	// requests.
   470  	NullFields []string `json:"-"`
   471  }
   472  
   473  func (s *AutomaticScaling) MarshalJSON() ([]byte, error) {
   474  	type NoMethod AutomaticScaling
   475  	raw := NoMethod(*s)
   476  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
   477  }
   478  
   479  // BasicScaling: A module with basic scaling will create an instance
   480  // when the application receives a request. The instance will be turned
   481  // down when the app becomes idle. Basic scaling is ideal for work that
   482  // is intermittent or driven by user activity.
   483  type BasicScaling struct {
   484  	// IdleTimeout: Duration of time after the last request that an instance
   485  	// must wait before the instance is shut down.
   486  	IdleTimeout string `json:"idleTimeout,omitempty"`
   487  
   488  	// MaxInstances: Maximum number of instances to create for this version.
   489  	MaxInstances int64 `json:"maxInstances,omitempty"`
   490  
   491  	// ForceSendFields is a list of field names (e.g. "IdleTimeout") to
   492  	// unconditionally include in API requests. By default, fields with
   493  	// empty values are omitted from API requests. However, any non-pointer,
   494  	// non-interface field appearing in ForceSendFields will be sent to the
   495  	// server regardless of whether the field is empty or not. This may be
   496  	// used to include empty fields in Patch requests.
   497  	ForceSendFields []string `json:"-"`
   498  
   499  	// NullFields is a list of field names (e.g. "IdleTimeout") to include
   500  	// in API requests with the JSON null value. By default, fields with
   501  	// empty values are omitted from API requests. However, any field with
   502  	// an empty value appearing in NullFields will be sent to the server as
   503  	// null. It is an error if a field in this list has a non-empty value.
   504  	// This may be used to include null fields in Patch requests.
   505  	NullFields []string `json:"-"`
   506  }
   507  
   508  func (s *BasicScaling) MarshalJSON() ([]byte, error) {
   509  	type NoMethod BasicScaling
   510  	raw := NoMethod(*s)
   511  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
   512  }
   513  
   514  // ContainerInfo: Docker image that is used to create a container and
   515  // start a VM instance for the version that you deploy. Only applicable
   516  // for instances running in the App Engine flexible environment.
   517  type ContainerInfo struct {
   518  	// Image: URI to the hosted container image in Google Container
   519  	// Registry. The URI must be fully qualified and include a tag or
   520  	// digest. Examples: "gcr.io/my-project/image:tag" or
   521  	// "gcr.io/my-project/image@digest"
   522  	Image string `json:"image,omitempty"`
   523  
   524  	// ForceSendFields is a list of field names (e.g. "Image") to
   525  	// unconditionally include in API requests. By default, fields with
   526  	// empty values are omitted from API requests. However, any non-pointer,
   527  	// non-interface field appearing in ForceSendFields will be sent to the
   528  	// server regardless of whether the field is empty or not. This may be
   529  	// used to include empty fields in Patch requests.
   530  	ForceSendFields []string `json:"-"`
   531  
   532  	// NullFields is a list of field names (e.g. "Image") to include in API
   533  	// requests with the JSON null value. By default, fields with empty
   534  	// values are omitted from API requests. However, any field with an
   535  	// empty value appearing in NullFields will be sent to the server as
   536  	// null. It is an error if a field in this list has a non-empty value.
   537  	// This may be used to include null fields in Patch requests.
   538  	NullFields []string `json:"-"`
   539  }
   540  
   541  func (s *ContainerInfo) MarshalJSON() ([]byte, error) {
   542  	type NoMethod ContainerInfo
   543  	raw := NoMethod(*s)
   544  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
   545  }
   546  
   547  // CpuUtilization: Target scaling by CPU usage.
   548  type CpuUtilization struct {
   549  	// AggregationWindowLength: Period of time over which CPU utilization is
   550  	// calculated.
   551  	AggregationWindowLength string `json:"aggregationWindowLength,omitempty"`
   552  
   553  	// TargetUtilization: Target CPU utilization ratio to maintain when
   554  	// scaling. Must be between 0 and 1.
   555  	TargetUtilization float64 `json:"targetUtilization,omitempty"`
   556  
   557  	// ForceSendFields is a list of field names (e.g.
   558  	// "AggregationWindowLength") to unconditionally include in API
   559  	// requests. By default, fields with empty values are omitted from API
   560  	// requests. However, any non-pointer, non-interface field appearing in
   561  	// ForceSendFields will be sent to the server regardless of whether the
   562  	// field is empty or not. This may be used to include empty fields in
   563  	// Patch requests.
   564  	ForceSendFields []string `json:"-"`
   565  
   566  	// NullFields is a list of field names (e.g. "AggregationWindowLength")
   567  	// to include in API requests with the JSON null value. By default,
   568  	// fields with empty values are omitted from API requests. However, any
   569  	// field with an empty value appearing in NullFields will be sent to the
   570  	// server as null. It is an error if a field in this list has a
   571  	// non-empty value. This may be used to include null fields in Patch
   572  	// requests.
   573  	NullFields []string `json:"-"`
   574  }
   575  
   576  func (s *CpuUtilization) MarshalJSON() ([]byte, error) {
   577  	type NoMethod CpuUtilization
   578  	raw := NoMethod(*s)
   579  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
   580  }
   581  
   582  func (s *CpuUtilization) UnmarshalJSON(data []byte) error {
   583  	type NoMethod CpuUtilization
   584  	var s1 struct {
   585  		TargetUtilization gensupport.JSONFloat64 `json:"targetUtilization"`
   586  		*NoMethod
   587  	}
   588  	s1.NoMethod = (*NoMethod)(s)
   589  	if err := json.Unmarshal(data, &s1); err != nil {
   590  		return err
   591  	}
   592  	s.TargetUtilization = float64(s1.TargetUtilization)
   593  	return nil
   594  }
   595  
   596  // CreateVersionMetadataV1: Metadata for the given
   597  // google.longrunning.Operation during a
   598  // google.appengine.v1.CreateVersionRequest.
   599  type CreateVersionMetadataV1 struct {
   600  	// CloudBuildId: The Cloud Build ID if one was created as part of the
   601  	// version create. @OutputOnly
   602  	CloudBuildId string `json:"cloudBuildId,omitempty"`
   603  
   604  	// ForceSendFields is a list of field names (e.g. "CloudBuildId") to
   605  	// unconditionally include in API requests. By default, fields with
   606  	// empty values are omitted from API requests. However, any non-pointer,
   607  	// non-interface field appearing in ForceSendFields will be sent to the
   608  	// server regardless of whether the field is empty or not. This may be
   609  	// used to include empty fields in Patch requests.
   610  	ForceSendFields []string `json:"-"`
   611  
   612  	// NullFields is a list of field names (e.g. "CloudBuildId") to include
   613  	// in API requests with the JSON null value. By default, fields with
   614  	// empty values are omitted from API requests. However, any field with
   615  	// an empty value appearing in NullFields will be sent to the server as
   616  	// null. It is an error if a field in this list has a non-empty value.
   617  	// This may be used to include null fields in Patch requests.
   618  	NullFields []string `json:"-"`
   619  }
   620  
   621  func (s *CreateVersionMetadataV1) MarshalJSON() ([]byte, error) {
   622  	type NoMethod CreateVersionMetadataV1
   623  	raw := NoMethod(*s)
   624  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
   625  }
   626  
   627  // CreateVersionMetadataV1Alpha: Metadata for the given
   628  // google.longrunning.Operation during a
   629  // google.appengine.v1alpha.CreateVersionRequest.
   630  type CreateVersionMetadataV1Alpha struct {
   631  	// CloudBuildId: The Cloud Build ID if one was created as part of the
   632  	// version create. @OutputOnly
   633  	CloudBuildId string `json:"cloudBuildId,omitempty"`
   634  
   635  	// ForceSendFields is a list of field names (e.g. "CloudBuildId") to
   636  	// unconditionally include in API requests. By default, fields with
   637  	// empty values are omitted from API requests. However, any non-pointer,
   638  	// non-interface field appearing in ForceSendFields will be sent to the
   639  	// server regardless of whether the field is empty or not. This may be
   640  	// used to include empty fields in Patch requests.
   641  	ForceSendFields []string `json:"-"`
   642  
   643  	// NullFields is a list of field names (e.g. "CloudBuildId") to include
   644  	// in API requests with the JSON null value. By default, fields with
   645  	// empty values are omitted from API requests. However, any field with
   646  	// an empty value appearing in NullFields will be sent to the server as
   647  	// null. It is an error if a field in this list has a non-empty value.
   648  	// This may be used to include null fields in Patch requests.
   649  	NullFields []string `json:"-"`
   650  }
   651  
   652  func (s *CreateVersionMetadataV1Alpha) MarshalJSON() ([]byte, error) {
   653  	type NoMethod CreateVersionMetadataV1Alpha
   654  	raw := NoMethod(*s)
   655  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
   656  }
   657  
   658  // CreateVersionMetadataV1Beta: Metadata for the given
   659  // google.longrunning.Operation during a
   660  // google.appengine.v1beta.CreateVersionRequest.
   661  type CreateVersionMetadataV1Beta struct {
   662  	// CloudBuildId: The Cloud Build ID if one was created as part of the
   663  	// version create. @OutputOnly
   664  	CloudBuildId string `json:"cloudBuildId,omitempty"`
   665  
   666  	// ForceSendFields is a list of field names (e.g. "CloudBuildId") to
   667  	// unconditionally include in API requests. By default, fields with
   668  	// empty values are omitted from API requests. However, any non-pointer,
   669  	// non-interface field appearing in ForceSendFields will be sent to the
   670  	// server regardless of whether the field is empty or not. This may be
   671  	// used to include empty fields in Patch requests.
   672  	ForceSendFields []string `json:"-"`
   673  
   674  	// NullFields is a list of field names (e.g. "CloudBuildId") to include
   675  	// in API requests with the JSON null value. By default, fields with
   676  	// empty values are omitted from API requests. However, any field with
   677  	// an empty value appearing in NullFields will be sent to the server as
   678  	// null. It is an error if a field in this list has a non-empty value.
   679  	// This may be used to include null fields in Patch requests.
   680  	NullFields []string `json:"-"`
   681  }
   682  
   683  func (s *CreateVersionMetadataV1Beta) MarshalJSON() ([]byte, error) {
   684  	type NoMethod CreateVersionMetadataV1Beta
   685  	raw := NoMethod(*s)
   686  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
   687  }
   688  
   689  // DebugInstanceRequest: Request message for Instances.DebugInstance.
   690  type DebugInstanceRequest struct {
   691  	// SshKey: Public SSH key to add to the instance.
   692  	// Examples:
   693  	// [USERNAME]:ssh-rsa [KEY_VALUE] [USERNAME]
   694  	// [USERNAME]:ssh-rsa [KEY_VALUE] google-ssh
   695  	// {"userName":"[USERNAME]","expireOn":"[EXPIRE_TIME]"}For more
   696  	// information, see Adding and Removing SSH Keys
   697  	// (https://cloud.google.com/compute/docs/instances/adding-removing-ssh-keys).
   698  	SshKey string `json:"sshKey,omitempty"`
   699  
   700  	// ForceSendFields is a list of field names (e.g. "SshKey") to
   701  	// unconditionally include in API requests. By default, fields with
   702  	// empty values are omitted from API requests. However, any non-pointer,
   703  	// non-interface field appearing in ForceSendFields will be sent to the
   704  	// server regardless of whether the field is empty or not. This may be
   705  	// used to include empty fields in Patch requests.
   706  	ForceSendFields []string `json:"-"`
   707  
   708  	// NullFields is a list of field names (e.g. "SshKey") to include in API
   709  	// requests with the JSON null value. By default, fields with empty
   710  	// values are omitted from API requests. However, any field with an
   711  	// empty value appearing in NullFields will be sent to the server as
   712  	// null. It is an error if a field in this list has a non-empty value.
   713  	// This may be used to include null fields in Patch requests.
   714  	NullFields []string `json:"-"`
   715  }
   716  
   717  func (s *DebugInstanceRequest) MarshalJSON() ([]byte, error) {
   718  	type NoMethod DebugInstanceRequest
   719  	raw := NoMethod(*s)
   720  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
   721  }
   722  
   723  // Deployment: Code and application artifacts used to deploy a version
   724  // to App Engine.
   725  type Deployment struct {
   726  	// Container: The Docker image for the container that runs the version.
   727  	// Only applicable for instances running in the App Engine flexible
   728  	// environment.
   729  	Container *ContainerInfo `json:"container,omitempty"`
   730  
   731  	// Files: Manifest of the files stored in Google Cloud Storage that are
   732  	// included as part of this version. All files must be readable using
   733  	// the credentials supplied with this call.
   734  	Files map[string]FileInfo `json:"files,omitempty"`
   735  
   736  	// SourceReferences: Origin of the source code for this deployment.
   737  	// There can be more than one source reference per version if source
   738  	// code is distributed among multiple repositories.
   739  	SourceReferences []*SourceReference `json:"sourceReferences,omitempty"`
   740  
   741  	// ForceSendFields is a list of field names (e.g. "Container") to
   742  	// unconditionally include in API requests. By default, fields with
   743  	// empty values are omitted from API requests. However, any non-pointer,
   744  	// non-interface field appearing in ForceSendFields will be sent to the
   745  	// server regardless of whether the field is empty or not. This may be
   746  	// used to include empty fields in Patch requests.
   747  	ForceSendFields []string `json:"-"`
   748  
   749  	// NullFields is a list of field names (e.g. "Container") to include in
   750  	// API requests with the JSON null value. By default, fields with empty
   751  	// values are omitted from API requests. However, any field with an
   752  	// empty value appearing in NullFields will be sent to the server as
   753  	// null. It is an error if a field in this list has a non-empty value.
   754  	// This may be used to include null fields in Patch requests.
   755  	NullFields []string `json:"-"`
   756  }
   757  
   758  func (s *Deployment) MarshalJSON() ([]byte, error) {
   759  	type NoMethod Deployment
   760  	raw := NoMethod(*s)
   761  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
   762  }
   763  
   764  // DiskUtilization: Target scaling by disk usage. Only applicable for VM
   765  // runtimes.
   766  type DiskUtilization struct {
   767  	// TargetReadBytesPerSec: Target bytes read per second.
   768  	TargetReadBytesPerSec int64 `json:"targetReadBytesPerSec,omitempty"`
   769  
   770  	// TargetReadOpsPerSec: Target ops read per second.
   771  	TargetReadOpsPerSec int64 `json:"targetReadOpsPerSec,omitempty"`
   772  
   773  	// TargetWriteBytesPerSec: Target bytes written per second.
   774  	TargetWriteBytesPerSec int64 `json:"targetWriteBytesPerSec,omitempty"`
   775  
   776  	// TargetWriteOpsPerSec: Target ops written per second.
   777  	TargetWriteOpsPerSec int64 `json:"targetWriteOpsPerSec,omitempty"`
   778  
   779  	// ForceSendFields is a list of field names (e.g.
   780  	// "TargetReadBytesPerSec") to unconditionally include in API requests.
   781  	// By default, fields with empty values are omitted from API requests.
   782  	// However, any non-pointer, non-interface field appearing in
   783  	// ForceSendFields will be sent to the server regardless of whether the
   784  	// field is empty or not. This may be used to include empty fields in
   785  	// Patch requests.
   786  	ForceSendFields []string `json:"-"`
   787  
   788  	// NullFields is a list of field names (e.g. "TargetReadBytesPerSec") to
   789  	// include in API requests with the JSON null value. By default, fields
   790  	// with empty values are omitted from API requests. However, any field
   791  	// with an empty value appearing in NullFields will be sent to the
   792  	// server as null. It is an error if a field in this list has a
   793  	// non-empty value. This may be used to include null fields in Patch
   794  	// requests.
   795  	NullFields []string `json:"-"`
   796  }
   797  
   798  func (s *DiskUtilization) MarshalJSON() ([]byte, error) {
   799  	type NoMethod DiskUtilization
   800  	raw := NoMethod(*s)
   801  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
   802  }
   803  
   804  // EndpointsApiService: Cloud Endpoints
   805  // (https://cloud.google.com/endpoints) configuration. The Endpoints API
   806  // Service provides tooling for serving Open API and gRPC endpoints via
   807  // an NGINX proxy. Only valid for App Engine Flexible environment
   808  // deployments..The fields here refer to the name and configuration id
   809  // of a "service" resource in the Service Management API
   810  // (https://cloud.google.com/service-management/overview).
   811  type EndpointsApiService struct {
   812  	// ConfigId: Endpoints service configuration id as specified by the
   813  	// Service Management API. For example "2016-09-19r1"By default, the
   814  	// Endpoints service configuration id is fixed and config_id must be
   815  	// specified. To keep the Endpoints service configuration id updated
   816  	// with each rollout, specify RolloutStrategy.MANAGED and omit
   817  	// config_id.
   818  	ConfigId string `json:"configId,omitempty"`
   819  
   820  	// DisableTraceSampling: Enable or disable trace sampling. By default,
   821  	// this is set to false for enabled.
   822  	DisableTraceSampling bool `json:"disableTraceSampling,omitempty"`
   823  
   824  	// Name: Endpoints service name which is the name of the "service"
   825  	// resource in the Service Management API. For example
   826  	// "myapi.endpoints.myproject.cloud.goog"
   827  	Name string `json:"name,omitempty"`
   828  
   829  	// RolloutStrategy: Endpoints rollout strategy. If FIXED, config_id must
   830  	// be specified. If MANAGED, config_id must be omitted.
   831  	//
   832  	// Possible values:
   833  	//   "UNSPECIFIED_ROLLOUT_STRATEGY" - Not specified. Defaults to FIXED.
   834  	//   "FIXED" - Endpoints service configuration id will be fixed to the
   835  	// configuration id specified by config_id.
   836  	//   "MANAGED" - Endpoints service configuration id will be updated with
   837  	// each rollout.
   838  	RolloutStrategy string `json:"rolloutStrategy,omitempty"`
   839  
   840  	// ForceSendFields is a list of field names (e.g. "ConfigId") to
   841  	// unconditionally include in API requests. By default, fields with
   842  	// empty values are omitted from API requests. However, any non-pointer,
   843  	// non-interface field appearing in ForceSendFields will be sent to the
   844  	// server regardless of whether the field is empty or not. This may be
   845  	// used to include empty fields in Patch requests.
   846  	ForceSendFields []string `json:"-"`
   847  
   848  	// NullFields is a list of field names (e.g. "ConfigId") to include in
   849  	// API requests with the JSON null value. By default, fields with empty
   850  	// values are omitted from API requests. However, any field with an
   851  	// empty value appearing in NullFields will be sent to the server as
   852  	// null. It is an error if a field in this list has a non-empty value.
   853  	// This may be used to include null fields in Patch requests.
   854  	NullFields []string `json:"-"`
   855  }
   856  
   857  func (s *EndpointsApiService) MarshalJSON() ([]byte, error) {
   858  	type NoMethod EndpointsApiService
   859  	raw := NoMethod(*s)
   860  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
   861  }
   862  
   863  // ErrorHandler: Custom static error page to be served when an error
   864  // occurs.
   865  type ErrorHandler struct {
   866  	// ErrorCode: Error condition this handler applies to.
   867  	//
   868  	// Possible values:
   869  	//   "ERROR_CODE_UNSPECIFIED" - Not specified. ERROR_CODE_DEFAULT is
   870  	// assumed.
   871  	//   "ERROR_CODE_DEFAULT" - All other error types.
   872  	//   "ERROR_CODE_OVER_QUOTA" - Application has exceeded a resource
   873  	// quota.
   874  	//   "ERROR_CODE_DOS_API_DENIAL" - Client blocked by the application's
   875  	// Denial of Service protection configuration.
   876  	//   "ERROR_CODE_TIMEOUT" - Deadline reached before the application
   877  	// responds.
   878  	ErrorCode string `json:"errorCode,omitempty"`
   879  
   880  	// MimeType: MIME type of file. Defaults to text/html.
   881  	MimeType string `json:"mimeType,omitempty"`
   882  
   883  	// StaticFile: Static file content to be served for this error.
   884  	StaticFile string `json:"staticFile,omitempty"`
   885  
   886  	// ForceSendFields is a list of field names (e.g. "ErrorCode") to
   887  	// unconditionally include in API requests. By default, fields with
   888  	// empty values are omitted from API requests. However, any non-pointer,
   889  	// non-interface field appearing in ForceSendFields will be sent to the
   890  	// server regardless of whether the field is empty or not. This may be
   891  	// used to include empty fields in Patch requests.
   892  	ForceSendFields []string `json:"-"`
   893  
   894  	// NullFields is a list of field names (e.g. "ErrorCode") to include in
   895  	// API requests with the JSON null value. By default, fields with empty
   896  	// values are omitted from API requests. However, any field with an
   897  	// empty value appearing in NullFields will be sent to the server as
   898  	// null. It is an error if a field in this list has a non-empty value.
   899  	// This may be used to include null fields in Patch requests.
   900  	NullFields []string `json:"-"`
   901  }
   902  
   903  func (s *ErrorHandler) MarshalJSON() ([]byte, error) {
   904  	type NoMethod ErrorHandler
   905  	raw := NoMethod(*s)
   906  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
   907  }
   908  
   909  // FileInfo: Single source file that is part of the version to be
   910  // deployed. Each source file that is deployed must be specified
   911  // separately.
   912  type FileInfo struct {
   913  	// MimeType: The MIME type of the file.Defaults to the value from Google
   914  	// Cloud Storage.
   915  	MimeType string `json:"mimeType,omitempty"`
   916  
   917  	// Sha1Sum: The SHA1 hash of the file, in hex.
   918  	Sha1Sum string `json:"sha1Sum,omitempty"`
   919  
   920  	// SourceUrl: URL source to use to fetch this file. Must be a URL to a
   921  	// resource in Google Cloud Storage in the form
   922  	// 'http(s)://storage.googleapis.com/<bucket>/<object>'.
   923  	SourceUrl string `json:"sourceUrl,omitempty"`
   924  
   925  	// ForceSendFields is a list of field names (e.g. "MimeType") to
   926  	// unconditionally include in API requests. By default, fields with
   927  	// empty values are omitted from API requests. However, any non-pointer,
   928  	// non-interface field appearing in ForceSendFields will be sent to the
   929  	// server regardless of whether the field is empty or not. This may be
   930  	// used to include empty fields in Patch requests.
   931  	ForceSendFields []string `json:"-"`
   932  
   933  	// NullFields is a list of field names (e.g. "MimeType") to include in
   934  	// API requests with the JSON null value. By default, fields with empty
   935  	// values are omitted from API requests. However, any field with an
   936  	// empty value appearing in NullFields will be sent to the server as
   937  	// null. It is an error if a field in this list has a non-empty value.
   938  	// This may be used to include null fields in Patch requests.
   939  	NullFields []string `json:"-"`
   940  }
   941  
   942  func (s *FileInfo) MarshalJSON() ([]byte, error) {
   943  	type NoMethod FileInfo
   944  	raw := NoMethod(*s)
   945  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
   946  }
   947  
   948  // HealthCheck: Health checking configuration for VM instances.
   949  // Unhealthy instances are killed and replaced with new instances. Only
   950  // applicable for instances in App Engine flexible environment.
   951  type HealthCheck struct {
   952  	// CheckInterval: Interval between health checks.
   953  	CheckInterval string `json:"checkInterval,omitempty"`
   954  
   955  	// DisableHealthCheck: Whether to explicitly disable health checks for
   956  	// this instance.
   957  	DisableHealthCheck bool `json:"disableHealthCheck,omitempty"`
   958  
   959  	// HealthyThreshold: Number of consecutive successful health checks
   960  	// required before receiving traffic.
   961  	HealthyThreshold int64 `json:"healthyThreshold,omitempty"`
   962  
   963  	// Host: Host header to send when performing an HTTP health check.
   964  	// Example: "myapp.appspot.com"
   965  	Host string `json:"host,omitempty"`
   966  
   967  	// RestartThreshold: Number of consecutive failed health checks required
   968  	// before an instance is restarted.
   969  	RestartThreshold int64 `json:"restartThreshold,omitempty"`
   970  
   971  	// Timeout: Time before the health check is considered failed.
   972  	Timeout string `json:"timeout,omitempty"`
   973  
   974  	// UnhealthyThreshold: Number of consecutive failed health checks
   975  	// required before removing traffic.
   976  	UnhealthyThreshold int64 `json:"unhealthyThreshold,omitempty"`
   977  
   978  	// ForceSendFields is a list of field names (e.g. "CheckInterval") to
   979  	// unconditionally include in API requests. By default, fields with
   980  	// empty values are omitted from API requests. However, any non-pointer,
   981  	// non-interface field appearing in ForceSendFields will be sent to the
   982  	// server regardless of whether the field is empty or not. This may be
   983  	// used to include empty fields in Patch requests.
   984  	ForceSendFields []string `json:"-"`
   985  
   986  	// NullFields is a list of field names (e.g. "CheckInterval") to include
   987  	// in API requests with the JSON null value. By default, fields with
   988  	// empty values are omitted from API requests. However, any field with
   989  	// an empty value appearing in NullFields will be sent to the server as
   990  	// null. It is an error if a field in this list has a non-empty value.
   991  	// This may be used to include null fields in Patch requests.
   992  	NullFields []string `json:"-"`
   993  }
   994  
   995  func (s *HealthCheck) MarshalJSON() ([]byte, error) {
   996  	type NoMethod HealthCheck
   997  	raw := NoMethod(*s)
   998  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
   999  }
  1000  
  1001  // IdentityAwareProxy: Identity-Aware Proxy
  1002  type IdentityAwareProxy struct {
  1003  	// Enabled: Whether the serving infrastructure will authenticate and
  1004  	// authorize all incoming requests.If true, the oauth2_client_id and
  1005  	// oauth2_client_secret fields must be non-empty.
  1006  	Enabled bool `json:"enabled,omitempty"`
  1007  
  1008  	// Oauth2ClientId: OAuth2 client ID to use for the authentication flow.
  1009  	Oauth2ClientId string `json:"oauth2ClientId,omitempty"`
  1010  
  1011  	// Oauth2ClientSecret: For security reasons, this value cannot be
  1012  	// retrieved via the API. Instead, the SHA-256 hash of the value is
  1013  	// returned in the oauth2_client_secret_sha256 field.@InputOnly
  1014  	Oauth2ClientSecret string `json:"oauth2ClientSecret,omitempty"`
  1015  
  1016  	// Oauth2ClientSecretSha256: Hex-encoded SHA-256 hash of the client
  1017  	// secret.@OutputOnly
  1018  	Oauth2ClientSecretSha256 string `json:"oauth2ClientSecretSha256,omitempty"`
  1019  
  1020  	// ForceSendFields is a list of field names (e.g. "Enabled") to
  1021  	// unconditionally include in API requests. By default, fields with
  1022  	// empty values are omitted from API requests. However, any non-pointer,
  1023  	// non-interface field appearing in ForceSendFields will be sent to the
  1024  	// server regardless of whether the field is empty or not. This may be
  1025  	// used to include empty fields in Patch requests.
  1026  	ForceSendFields []string `json:"-"`
  1027  
  1028  	// NullFields is a list of field names (e.g. "Enabled") to include in
  1029  	// API requests with the JSON null value. By default, fields with empty
  1030  	// values are omitted from API requests. However, any field with an
  1031  	// empty value appearing in NullFields will be sent to the server as
  1032  	// null. It is an error if a field in this list has a non-empty value.
  1033  	// This may be used to include null fields in Patch requests.
  1034  	NullFields []string `json:"-"`
  1035  }
  1036  
  1037  func (s *IdentityAwareProxy) MarshalJSON() ([]byte, error) {
  1038  	type NoMethod IdentityAwareProxy
  1039  	raw := NoMethod(*s)
  1040  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1041  }
  1042  
  1043  // Instance: An Instance resource is the computing unit that App Engine
  1044  // uses to automatically scale an application.
  1045  type Instance struct {
  1046  	// AppEngineRelease: App Engine release this instance is running
  1047  	// on.@OutputOnly
  1048  	AppEngineRelease string `json:"appEngineRelease,omitempty"`
  1049  
  1050  	// Availability: Availability of the instance.@OutputOnly
  1051  	//
  1052  	// Possible values:
  1053  	//   "UNSPECIFIED"
  1054  	//   "RESIDENT"
  1055  	//   "DYNAMIC"
  1056  	Availability string `json:"availability,omitempty"`
  1057  
  1058  	// AverageLatency: Average latency (ms) over the last minute.@OutputOnly
  1059  	AverageLatency int64 `json:"averageLatency,omitempty"`
  1060  
  1061  	// Errors: Number of errors since this instance was started.@OutputOnly
  1062  	Errors int64 `json:"errors,omitempty"`
  1063  
  1064  	// Id: Relative name of the instance within the version. Example:
  1065  	// instance-1.@OutputOnly
  1066  	Id string `json:"id,omitempty"`
  1067  
  1068  	// MemoryUsage: Total memory in use (bytes).@OutputOnly
  1069  	MemoryUsage int64 `json:"memoryUsage,omitempty,string"`
  1070  
  1071  	// Name: Full path to the Instance resource in the API. Example:
  1072  	// apps/myapp/modules/default/versions/v1/instances/instance-1.@OutputOnl
  1073  	// y
  1074  	Name string `json:"name,omitempty"`
  1075  
  1076  	// Qps: Average queries per second (QPS) over the last
  1077  	// minute.@OutputOnly
  1078  	Qps float64 `json:"qps,omitempty"`
  1079  
  1080  	// Requests: Number of requests since this instance was
  1081  	// started.@OutputOnly
  1082  	Requests int64 `json:"requests,omitempty"`
  1083  
  1084  	// StartTimestamp: Time that this instance was started.@OutputOnly
  1085  	StartTimestamp string `json:"startTimestamp,omitempty"`
  1086  
  1087  	// VmId: Virtual machine ID of this instance. Only applicable for
  1088  	// instances in App Engine flexible environment.@OutputOnly
  1089  	VmId string `json:"vmId,omitempty"`
  1090  
  1091  	// VmIp: The IP address of this instance. Only applicable for instances
  1092  	// in App Engine flexible environment.@OutputOnly
  1093  	VmIp string `json:"vmIp,omitempty"`
  1094  
  1095  	// VmName: Name of the virtual machine where this instance lives. Only
  1096  	// applicable for instances in App Engine flexible
  1097  	// environment.@OutputOnly
  1098  	VmName string `json:"vmName,omitempty"`
  1099  
  1100  	// VmStatus: Status of the virtual machine where this instance lives.
  1101  	// Only applicable for instances in App Engine flexible
  1102  	// environment.@OutputOnly
  1103  	VmStatus string `json:"vmStatus,omitempty"`
  1104  
  1105  	// VmUnlocked: Whether this instance is in debug mode. Only applicable
  1106  	// for instances in App Engine flexible environment.@OutputOnly
  1107  	VmUnlocked bool `json:"vmUnlocked,omitempty"`
  1108  
  1109  	// VmZoneName: Zone where the virtual machine is located. Only
  1110  	// applicable for instances in App Engine flexible
  1111  	// environment.@OutputOnly
  1112  	VmZoneName string `json:"vmZoneName,omitempty"`
  1113  
  1114  	// ServerResponse contains the HTTP response code and headers from the
  1115  	// server.
  1116  	googleapi.ServerResponse `json:"-"`
  1117  
  1118  	// ForceSendFields is a list of field names (e.g. "AppEngineRelease") to
  1119  	// unconditionally include in API requests. By default, fields with
  1120  	// empty values are omitted from API requests. However, any non-pointer,
  1121  	// non-interface field appearing in ForceSendFields will be sent to the
  1122  	// server regardless of whether the field is empty or not. This may be
  1123  	// used to include empty fields in Patch requests.
  1124  	ForceSendFields []string `json:"-"`
  1125  
  1126  	// NullFields is a list of field names (e.g. "AppEngineRelease") to
  1127  	// include in API requests with the JSON null value. By default, fields
  1128  	// with empty values are omitted from API requests. However, any field
  1129  	// with an empty value appearing in NullFields will be sent to the
  1130  	// server as null. It is an error if a field in this list has a
  1131  	// non-empty value. This may be used to include null fields in Patch
  1132  	// requests.
  1133  	NullFields []string `json:"-"`
  1134  }
  1135  
  1136  func (s *Instance) MarshalJSON() ([]byte, error) {
  1137  	type NoMethod Instance
  1138  	raw := NoMethod(*s)
  1139  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1140  }
  1141  
  1142  func (s *Instance) UnmarshalJSON(data []byte) error {
  1143  	type NoMethod Instance
  1144  	var s1 struct {
  1145  		Qps gensupport.JSONFloat64 `json:"qps"`
  1146  		*NoMethod
  1147  	}
  1148  	s1.NoMethod = (*NoMethod)(s)
  1149  	if err := json.Unmarshal(data, &s1); err != nil {
  1150  		return err
  1151  	}
  1152  	s.Qps = float64(s1.Qps)
  1153  	return nil
  1154  }
  1155  
  1156  // Library: Third-party Python runtime library that is required by the
  1157  // application.
  1158  type Library struct {
  1159  	// Name: Name of the library. Example: "django".
  1160  	Name string `json:"name,omitempty"`
  1161  
  1162  	// Version: Version of the library to select, or "latest".
  1163  	Version string `json:"version,omitempty"`
  1164  
  1165  	// ForceSendFields is a list of field names (e.g. "Name") to
  1166  	// unconditionally include in API requests. By default, fields with
  1167  	// empty values are omitted from API requests. However, any non-pointer,
  1168  	// non-interface field appearing in ForceSendFields will be sent to the
  1169  	// server regardless of whether the field is empty or not. This may be
  1170  	// used to include empty fields in Patch requests.
  1171  	ForceSendFields []string `json:"-"`
  1172  
  1173  	// NullFields is a list of field names (e.g. "Name") to include in API
  1174  	// requests with the JSON null value. By default, fields with empty
  1175  	// values are omitted from API requests. However, any field with an
  1176  	// empty value appearing in NullFields will be sent to the server as
  1177  	// null. It is an error if a field in this list has a non-empty value.
  1178  	// This may be used to include null fields in Patch requests.
  1179  	NullFields []string `json:"-"`
  1180  }
  1181  
  1182  func (s *Library) MarshalJSON() ([]byte, error) {
  1183  	type NoMethod Library
  1184  	raw := NoMethod(*s)
  1185  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1186  }
  1187  
  1188  // ListInstancesResponse: Response message for Instances.ListInstances.
  1189  type ListInstancesResponse struct {
  1190  	// Instances: The instances belonging to the requested version.
  1191  	Instances []*Instance `json:"instances,omitempty"`
  1192  
  1193  	// NextPageToken: Continuation token for fetching the next page of
  1194  	// results.
  1195  	NextPageToken string `json:"nextPageToken,omitempty"`
  1196  
  1197  	// ServerResponse contains the HTTP response code and headers from the
  1198  	// server.
  1199  	googleapi.ServerResponse `json:"-"`
  1200  
  1201  	// ForceSendFields is a list of field names (e.g. "Instances") to
  1202  	// unconditionally include in API requests. By default, fields with
  1203  	// empty values are omitted from API requests. However, any non-pointer,
  1204  	// non-interface field appearing in ForceSendFields will be sent to the
  1205  	// server regardless of whether the field is empty or not. This may be
  1206  	// used to include empty fields in Patch requests.
  1207  	ForceSendFields []string `json:"-"`
  1208  
  1209  	// NullFields is a list of field names (e.g. "Instances") to include in
  1210  	// API requests with the JSON null value. By default, fields with empty
  1211  	// values are omitted from API requests. However, any field with an
  1212  	// empty value appearing in NullFields will be sent to the server as
  1213  	// null. It is an error if a field in this list has a non-empty value.
  1214  	// This may be used to include null fields in Patch requests.
  1215  	NullFields []string `json:"-"`
  1216  }
  1217  
  1218  func (s *ListInstancesResponse) MarshalJSON() ([]byte, error) {
  1219  	type NoMethod ListInstancesResponse
  1220  	raw := NoMethod(*s)
  1221  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1222  }
  1223  
  1224  // ListLocationsResponse: The response message for
  1225  // Locations.ListLocations.
  1226  type ListLocationsResponse struct {
  1227  	// Locations: A list of locations that matches the specified filter in
  1228  	// the request.
  1229  	Locations []*Location `json:"locations,omitempty"`
  1230  
  1231  	// NextPageToken: The standard List next-page token.
  1232  	NextPageToken string `json:"nextPageToken,omitempty"`
  1233  
  1234  	// ServerResponse contains the HTTP response code and headers from the
  1235  	// server.
  1236  	googleapi.ServerResponse `json:"-"`
  1237  
  1238  	// ForceSendFields is a list of field names (e.g. "Locations") to
  1239  	// unconditionally include in API requests. By default, fields with
  1240  	// empty values are omitted from API requests. However, any non-pointer,
  1241  	// non-interface field appearing in ForceSendFields will be sent to the
  1242  	// server regardless of whether the field is empty or not. This may be
  1243  	// used to include empty fields in Patch requests.
  1244  	ForceSendFields []string `json:"-"`
  1245  
  1246  	// NullFields is a list of field names (e.g. "Locations") to include in
  1247  	// API requests with the JSON null value. By default, fields with empty
  1248  	// values are omitted from API requests. However, any field with an
  1249  	// empty value appearing in NullFields will be sent to the server as
  1250  	// null. It is an error if a field in this list has a non-empty value.
  1251  	// This may be used to include null fields in Patch requests.
  1252  	NullFields []string `json:"-"`
  1253  }
  1254  
  1255  func (s *ListLocationsResponse) MarshalJSON() ([]byte, error) {
  1256  	type NoMethod ListLocationsResponse
  1257  	raw := NoMethod(*s)
  1258  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1259  }
  1260  
  1261  // ListModulesResponse: Response message for Modules.ListModules.
  1262  type ListModulesResponse struct {
  1263  	// Modules: The modules belonging to the requested application.
  1264  	Modules []*Module `json:"modules,omitempty"`
  1265  
  1266  	// NextPageToken: Continuation token for fetching the next page of
  1267  	// results.
  1268  	NextPageToken string `json:"nextPageToken,omitempty"`
  1269  
  1270  	// ServerResponse contains the HTTP response code and headers from the
  1271  	// server.
  1272  	googleapi.ServerResponse `json:"-"`
  1273  
  1274  	// ForceSendFields is a list of field names (e.g. "Modules") to
  1275  	// unconditionally include in API requests. By default, fields with
  1276  	// empty values are omitted from API requests. However, any non-pointer,
  1277  	// non-interface field appearing in ForceSendFields will be sent to the
  1278  	// server regardless of whether the field is empty or not. This may be
  1279  	// used to include empty fields in Patch requests.
  1280  	ForceSendFields []string `json:"-"`
  1281  
  1282  	// NullFields is a list of field names (e.g. "Modules") to include in
  1283  	// API requests with the JSON null value. By default, fields with empty
  1284  	// values are omitted from API requests. However, any field with an
  1285  	// empty value appearing in NullFields will be sent to the server as
  1286  	// null. It is an error if a field in this list has a non-empty value.
  1287  	// This may be used to include null fields in Patch requests.
  1288  	NullFields []string `json:"-"`
  1289  }
  1290  
  1291  func (s *ListModulesResponse) MarshalJSON() ([]byte, error) {
  1292  	type NoMethod ListModulesResponse
  1293  	raw := NoMethod(*s)
  1294  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1295  }
  1296  
  1297  // ListOperationsResponse: The response message for
  1298  // Operations.ListOperations.
  1299  type ListOperationsResponse struct {
  1300  	// NextPageToken: The standard List next-page token.
  1301  	NextPageToken string `json:"nextPageToken,omitempty"`
  1302  
  1303  	// Operations: A list of operations that matches the specified filter in
  1304  	// the request.
  1305  	Operations []*Operation `json:"operations,omitempty"`
  1306  
  1307  	// ServerResponse contains the HTTP response code and headers from the
  1308  	// server.
  1309  	googleapi.ServerResponse `json:"-"`
  1310  
  1311  	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
  1312  	// unconditionally include in API requests. By default, fields with
  1313  	// empty values are omitted from API requests. However, any non-pointer,
  1314  	// non-interface field appearing in ForceSendFields will be sent to the
  1315  	// server regardless of whether the field is empty or not. This may be
  1316  	// used to include empty fields in Patch requests.
  1317  	ForceSendFields []string `json:"-"`
  1318  
  1319  	// NullFields is a list of field names (e.g. "NextPageToken") to include
  1320  	// in API requests with the JSON null value. By default, fields with
  1321  	// empty values are omitted from API requests. However, any field with
  1322  	// an empty value appearing in NullFields will be sent to the server as
  1323  	// null. It is an error if a field in this list has a non-empty value.
  1324  	// This may be used to include null fields in Patch requests.
  1325  	NullFields []string `json:"-"`
  1326  }
  1327  
  1328  func (s *ListOperationsResponse) MarshalJSON() ([]byte, error) {
  1329  	type NoMethod ListOperationsResponse
  1330  	raw := NoMethod(*s)
  1331  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1332  }
  1333  
  1334  // ListVersionsResponse: Response message for Versions.ListVersions.
  1335  type ListVersionsResponse struct {
  1336  	// NextPageToken: Continuation token for fetching the next page of
  1337  	// results.
  1338  	NextPageToken string `json:"nextPageToken,omitempty"`
  1339  
  1340  	// Versions: The versions belonging to the requested module.
  1341  	Versions []*Version `json:"versions,omitempty"`
  1342  
  1343  	// ServerResponse contains the HTTP response code and headers from the
  1344  	// server.
  1345  	googleapi.ServerResponse `json:"-"`
  1346  
  1347  	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
  1348  	// unconditionally include in API requests. By default, fields with
  1349  	// empty values are omitted from API requests. However, any non-pointer,
  1350  	// non-interface field appearing in ForceSendFields will be sent to the
  1351  	// server regardless of whether the field is empty or not. This may be
  1352  	// used to include empty fields in Patch requests.
  1353  	ForceSendFields []string `json:"-"`
  1354  
  1355  	// NullFields is a list of field names (e.g. "NextPageToken") to include
  1356  	// in API requests with the JSON null value. By default, fields with
  1357  	// empty values are omitted from API requests. However, any field with
  1358  	// an empty value appearing in NullFields will be sent to the server as
  1359  	// null. It is an error if a field in this list has a non-empty value.
  1360  	// This may be used to include null fields in Patch requests.
  1361  	NullFields []string `json:"-"`
  1362  }
  1363  
  1364  func (s *ListVersionsResponse) MarshalJSON() ([]byte, error) {
  1365  	type NoMethod ListVersionsResponse
  1366  	raw := NoMethod(*s)
  1367  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1368  }
  1369  
  1370  // Location: A resource that represents Google Cloud Platform location.
  1371  type Location struct {
  1372  	// DisplayName: The friendly name for this location, typically a nearby
  1373  	// city name. For example, "Tokyo".
  1374  	DisplayName string `json:"displayName,omitempty"`
  1375  
  1376  	// Labels: Cross-service attributes for the location. For
  1377  	// example
  1378  	// {"cloud.googleapis.com/region": "us-east1"}
  1379  	//
  1380  	Labels map[string]string `json:"labels,omitempty"`
  1381  
  1382  	// LocationId: The canonical id for this location. For example:
  1383  	// "us-east1".
  1384  	LocationId string `json:"locationId,omitempty"`
  1385  
  1386  	// Metadata: Service-specific metadata. For example the available
  1387  	// capacity at the given location.
  1388  	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
  1389  
  1390  	// Name: Resource name for the location, which may vary between
  1391  	// implementations. For example:
  1392  	// "projects/example-project/locations/us-east1"
  1393  	Name string `json:"name,omitempty"`
  1394  
  1395  	// ServerResponse contains the HTTP response code and headers from the
  1396  	// server.
  1397  	googleapi.ServerResponse `json:"-"`
  1398  
  1399  	// ForceSendFields is a list of field names (e.g. "DisplayName") to
  1400  	// unconditionally include in API requests. By default, fields with
  1401  	// empty values are omitted from API requests. However, any non-pointer,
  1402  	// non-interface field appearing in ForceSendFields will be sent to the
  1403  	// server regardless of whether the field is empty or not. This may be
  1404  	// used to include empty fields in Patch requests.
  1405  	ForceSendFields []string `json:"-"`
  1406  
  1407  	// NullFields is a list of field names (e.g. "DisplayName") to include
  1408  	// in API requests with the JSON null value. By default, fields with
  1409  	// empty values are omitted from API requests. However, any field with
  1410  	// an empty value appearing in NullFields will be sent to the server as
  1411  	// null. It is an error if a field in this list has a non-empty value.
  1412  	// This may be used to include null fields in Patch requests.
  1413  	NullFields []string `json:"-"`
  1414  }
  1415  
  1416  func (s *Location) MarshalJSON() ([]byte, error) {
  1417  	type NoMethod Location
  1418  	raw := NoMethod(*s)
  1419  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1420  }
  1421  
  1422  // LocationMetadata: Metadata for the given
  1423  // google.cloud.location.Location.
  1424  type LocationMetadata struct {
  1425  	// FlexibleEnvironmentAvailable: App Engine flexible environment is
  1426  	// available in the given location.@OutputOnly
  1427  	FlexibleEnvironmentAvailable bool `json:"flexibleEnvironmentAvailable,omitempty"`
  1428  
  1429  	// StandardEnvironmentAvailable: App Engine standard environment is
  1430  	// available in the given location.@OutputOnly
  1431  	StandardEnvironmentAvailable bool `json:"standardEnvironmentAvailable,omitempty"`
  1432  
  1433  	// ForceSendFields is a list of field names (e.g.
  1434  	// "FlexibleEnvironmentAvailable") to unconditionally include in API
  1435  	// requests. By default, fields with empty values are omitted from API
  1436  	// requests. However, any non-pointer, non-interface field appearing in
  1437  	// ForceSendFields will be sent to the server regardless of whether the
  1438  	// field is empty or not. This may be used to include empty fields in
  1439  	// Patch requests.
  1440  	ForceSendFields []string `json:"-"`
  1441  
  1442  	// NullFields is a list of field names (e.g.
  1443  	// "FlexibleEnvironmentAvailable") to include in API requests with the
  1444  	// JSON null value. By default, fields with empty values are omitted
  1445  	// from API requests. However, any field with an empty value appearing
  1446  	// in NullFields will be sent to the server as null. It is an error if a
  1447  	// field in this list has a non-empty value. This may be used to include
  1448  	// null fields in Patch requests.
  1449  	NullFields []string `json:"-"`
  1450  }
  1451  
  1452  func (s *LocationMetadata) MarshalJSON() ([]byte, error) {
  1453  	type NoMethod LocationMetadata
  1454  	raw := NoMethod(*s)
  1455  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1456  }
  1457  
  1458  // ManualScaling: A module with manual scaling runs continuously,
  1459  // allowing you to perform complex initialization and rely on the state
  1460  // of its memory over time.
  1461  type ManualScaling struct {
  1462  	// Instances: Number of instances to assign to the module at the start.
  1463  	// This number can later be altered by using the Modules API
  1464  	// (https://cloud.google.com/appengine/docs/python/modules/functions)
  1465  	// set_num_instances() function.
  1466  	Instances int64 `json:"instances,omitempty"`
  1467  
  1468  	// ForceSendFields is a list of field names (e.g. "Instances") to
  1469  	// unconditionally include in API requests. By default, fields with
  1470  	// empty values are omitted from API requests. However, any non-pointer,
  1471  	// non-interface field appearing in ForceSendFields will be sent to the
  1472  	// server regardless of whether the field is empty or not. This may be
  1473  	// used to include empty fields in Patch requests.
  1474  	ForceSendFields []string `json:"-"`
  1475  
  1476  	// NullFields is a list of field names (e.g. "Instances") to include in
  1477  	// API requests with the JSON null value. By default, fields with empty
  1478  	// values are omitted from API requests. However, any field with an
  1479  	// empty value appearing in NullFields will be sent to the server as
  1480  	// null. It is an error if a field in this list has a non-empty value.
  1481  	// This may be used to include null fields in Patch requests.
  1482  	NullFields []string `json:"-"`
  1483  }
  1484  
  1485  func (s *ManualScaling) MarshalJSON() ([]byte, error) {
  1486  	type NoMethod ManualScaling
  1487  	raw := NoMethod(*s)
  1488  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1489  }
  1490  
  1491  // Module: A Module resource is a logical component of an application
  1492  // that can share state and communicate in a secure fashion with other
  1493  // modules. For example, an application that handles customer requests
  1494  // might include separate modules to handle tasks such as backend data
  1495  // analysis or API requests from mobile devices. Each module has a
  1496  // collection of versions that define a specific set of code used to
  1497  // implement the functionality of that module.
  1498  type Module struct {
  1499  	// Id: Relative name of the module within the application. Example:
  1500  	// default.@OutputOnly
  1501  	Id string `json:"id,omitempty"`
  1502  
  1503  	// Name: Full path to the Module resource in the API. Example:
  1504  	// apps/myapp/modules/default.@OutputOnly
  1505  	Name string `json:"name,omitempty"`
  1506  
  1507  	// Split: Mapping that defines fractional HTTP traffic diversion to
  1508  	// different versions within the module.
  1509  	Split *TrafficSplit `json:"split,omitempty"`
  1510  
  1511  	// ServerResponse contains the HTTP response code and headers from the
  1512  	// server.
  1513  	googleapi.ServerResponse `json:"-"`
  1514  
  1515  	// ForceSendFields is a list of field names (e.g. "Id") to
  1516  	// unconditionally include in API requests. By default, fields with
  1517  	// empty values are omitted from API requests. However, any non-pointer,
  1518  	// non-interface field appearing in ForceSendFields will be sent to the
  1519  	// server regardless of whether the field is empty or not. This may be
  1520  	// used to include empty fields in Patch requests.
  1521  	ForceSendFields []string `json:"-"`
  1522  
  1523  	// NullFields is a list of field names (e.g. "Id") to include in API
  1524  	// requests with the JSON null value. By default, fields with empty
  1525  	// values are omitted from API requests. However, any field with an
  1526  	// empty value appearing in NullFields will be sent to the server as
  1527  	// null. It is an error if a field in this list has a non-empty value.
  1528  	// This may be used to include null fields in Patch requests.
  1529  	NullFields []string `json:"-"`
  1530  }
  1531  
  1532  func (s *Module) MarshalJSON() ([]byte, error) {
  1533  	type NoMethod Module
  1534  	raw := NoMethod(*s)
  1535  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1536  }
  1537  
  1538  // Network: Extra network settings. Only applicable for VM runtimes.
  1539  type Network struct {
  1540  	// ForwardedPorts: List of ports, or port pairs, to forward from the
  1541  	// virtual machine to the application container.
  1542  	ForwardedPorts []string `json:"forwardedPorts,omitempty"`
  1543  
  1544  	// InstanceTag: Tag to apply to the VM instance during creation.
  1545  	InstanceTag string `json:"instanceTag,omitempty"`
  1546  
  1547  	// Name: Google Cloud Platform network where the virtual machines are
  1548  	// created. Specify the short name, not the resource path.Defaults to
  1549  	// default.
  1550  	Name string `json:"name,omitempty"`
  1551  
  1552  	// ForceSendFields is a list of field names (e.g. "ForwardedPorts") to
  1553  	// unconditionally include in API requests. By default, fields with
  1554  	// empty values are omitted from API requests. However, any non-pointer,
  1555  	// non-interface field appearing in ForceSendFields will be sent to the
  1556  	// server regardless of whether the field is empty or not. This may be
  1557  	// used to include empty fields in Patch requests.
  1558  	ForceSendFields []string `json:"-"`
  1559  
  1560  	// NullFields is a list of field names (e.g. "ForwardedPorts") to
  1561  	// include in API requests with the JSON null value. By default, fields
  1562  	// with empty values are omitted from API requests. However, any field
  1563  	// with an empty value appearing in NullFields will be sent to the
  1564  	// server as null. It is an error if a field in this list has a
  1565  	// non-empty value. This may be used to include null fields in Patch
  1566  	// requests.
  1567  	NullFields []string `json:"-"`
  1568  }
  1569  
  1570  func (s *Network) MarshalJSON() ([]byte, error) {
  1571  	type NoMethod Network
  1572  	raw := NoMethod(*s)
  1573  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1574  }
  1575  
  1576  // NetworkUtilization: Target scaling by network usage. Only applicable
  1577  // for VM runtimes.
  1578  type NetworkUtilization struct {
  1579  	// TargetReceivedBytesPerSec: Target bytes received per second.
  1580  	TargetReceivedBytesPerSec int64 `json:"targetReceivedBytesPerSec,omitempty"`
  1581  
  1582  	// TargetReceivedPacketsPerSec: Target packets received per second.
  1583  	TargetReceivedPacketsPerSec int64 `json:"targetReceivedPacketsPerSec,omitempty"`
  1584  
  1585  	// TargetSentBytesPerSec: Target bytes sent per second.
  1586  	TargetSentBytesPerSec int64 `json:"targetSentBytesPerSec,omitempty"`
  1587  
  1588  	// TargetSentPacketsPerSec: Target packets sent per second.
  1589  	TargetSentPacketsPerSec int64 `json:"targetSentPacketsPerSec,omitempty"`
  1590  
  1591  	// ForceSendFields is a list of field names (e.g.
  1592  	// "TargetReceivedBytesPerSec") to unconditionally include in API
  1593  	// requests. By default, fields with empty values are omitted from API
  1594  	// requests. However, any non-pointer, non-interface field appearing in
  1595  	// ForceSendFields will be sent to the server regardless of whether the
  1596  	// field is empty or not. This may be used to include empty fields in
  1597  	// Patch requests.
  1598  	ForceSendFields []string `json:"-"`
  1599  
  1600  	// NullFields is a list of field names (e.g.
  1601  	// "TargetReceivedBytesPerSec") to include in API requests with the JSON
  1602  	// null value. By default, fields with empty values are omitted from API
  1603  	// requests. However, any field with an empty value appearing in
  1604  	// NullFields will be sent to the server as null. It is an error if a
  1605  	// field in this list has a non-empty value. This may be used to include
  1606  	// null fields in Patch requests.
  1607  	NullFields []string `json:"-"`
  1608  }
  1609  
  1610  func (s *NetworkUtilization) MarshalJSON() ([]byte, error) {
  1611  	type NoMethod NetworkUtilization
  1612  	raw := NoMethod(*s)
  1613  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1614  }
  1615  
  1616  // Operation: This resource represents a long-running operation that is
  1617  // the result of a network API call.
  1618  type Operation struct {
  1619  	// Done: If the value is false, it means the operation is still in
  1620  	// progress. If true, the operation is completed, and either error or
  1621  	// response is available.
  1622  	Done bool `json:"done,omitempty"`
  1623  
  1624  	// Error: The error result of the operation in case of failure or
  1625  	// cancellation.
  1626  	Error *Status `json:"error,omitempty"`
  1627  
  1628  	// Metadata: Service-specific metadata associated with the operation. It
  1629  	// typically contains progress information and common metadata such as
  1630  	// create time. Some services might not provide such metadata. Any
  1631  	// method that returns a long-running operation should document the
  1632  	// metadata type, if any.
  1633  	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
  1634  
  1635  	// Name: The server-assigned name, which is only unique within the same
  1636  	// service that originally returns it. If you use the default HTTP
  1637  	// mapping, the name should have the format of
  1638  	// operations/some/unique/name.
  1639  	Name string `json:"name,omitempty"`
  1640  
  1641  	// Response: The normal response of the operation in case of success. If
  1642  	// the original method returns no data on success, such as Delete, the
  1643  	// response is google.protobuf.Empty. If the original method is standard
  1644  	// Get/Create/Update, the response should be the resource. For other
  1645  	// methods, the response should have the type XxxResponse, where Xxx is
  1646  	// the original method name. For example, if the original method name is
  1647  	// TakeSnapshot(), the inferred response type is TakeSnapshotResponse.
  1648  	Response googleapi.RawMessage `json:"response,omitempty"`
  1649  
  1650  	// ServerResponse contains the HTTP response code and headers from the
  1651  	// server.
  1652  	googleapi.ServerResponse `json:"-"`
  1653  
  1654  	// ForceSendFields is a list of field names (e.g. "Done") to
  1655  	// unconditionally include in API requests. By default, fields with
  1656  	// empty values are omitted from API requests. However, any non-pointer,
  1657  	// non-interface field appearing in ForceSendFields will be sent to the
  1658  	// server regardless of whether the field is empty or not. This may be
  1659  	// used to include empty fields in Patch requests.
  1660  	ForceSendFields []string `json:"-"`
  1661  
  1662  	// NullFields is a list of field names (e.g. "Done") to include in API
  1663  	// requests with the JSON null value. By default, fields with empty
  1664  	// values are omitted from API requests. However, any field with an
  1665  	// empty value appearing in NullFields will be sent to the server as
  1666  	// null. It is an error if a field in this list has a non-empty value.
  1667  	// This may be used to include null fields in Patch requests.
  1668  	NullFields []string `json:"-"`
  1669  }
  1670  
  1671  func (s *Operation) MarshalJSON() ([]byte, error) {
  1672  	type NoMethod Operation
  1673  	raw := NoMethod(*s)
  1674  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1675  }
  1676  
  1677  // OperationMetadata: Metadata for the given
  1678  // google.longrunning.Operation.
  1679  type OperationMetadata struct {
  1680  	// EndTime: Timestamp that this operation completed.@OutputOnly
  1681  	EndTime string `json:"endTime,omitempty"`
  1682  
  1683  	// InsertTime: Timestamp that this operation was created.@OutputOnly
  1684  	InsertTime string `json:"insertTime,omitempty"`
  1685  
  1686  	// Method: API method that initiated this operation. Example:
  1687  	// google.appengine.v1beta4.Version.CreateVersion.@OutputOnly
  1688  	Method string `json:"method,omitempty"`
  1689  
  1690  	// OperationType: Type of this operation. Deprecated, use method field
  1691  	// instead. Example: "create_version".@OutputOnly
  1692  	OperationType string `json:"operationType,omitempty"`
  1693  
  1694  	// Target: Name of the resource that this operation is acting on.
  1695  	// Example: apps/myapp/modules/default.@OutputOnly
  1696  	Target string `json:"target,omitempty"`
  1697  
  1698  	// User: User who requested this operation.@OutputOnly
  1699  	User string `json:"user,omitempty"`
  1700  
  1701  	// ForceSendFields is a list of field names (e.g. "EndTime") to
  1702  	// unconditionally include in API requests. By default, fields with
  1703  	// empty values are omitted from API requests. However, any non-pointer,
  1704  	// non-interface field appearing in ForceSendFields will be sent to the
  1705  	// server regardless of whether the field is empty or not. This may be
  1706  	// used to include empty fields in Patch requests.
  1707  	ForceSendFields []string `json:"-"`
  1708  
  1709  	// NullFields is a list of field names (e.g. "EndTime") to include in
  1710  	// API requests with the JSON null value. By default, fields with empty
  1711  	// values are omitted from API requests. However, any field with an
  1712  	// empty value appearing in NullFields will be sent to the server as
  1713  	// null. It is an error if a field in this list has a non-empty value.
  1714  	// This may be used to include null fields in Patch requests.
  1715  	NullFields []string `json:"-"`
  1716  }
  1717  
  1718  func (s *OperationMetadata) MarshalJSON() ([]byte, error) {
  1719  	type NoMethod OperationMetadata
  1720  	raw := NoMethod(*s)
  1721  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1722  }
  1723  
  1724  // OperationMetadataV1: Metadata for the given
  1725  // google.longrunning.Operation.
  1726  type OperationMetadataV1 struct {
  1727  	CreateVersionMetadata *CreateVersionMetadataV1 `json:"createVersionMetadata,omitempty"`
  1728  
  1729  	// EndTime: Time that this operation completed.@OutputOnly
  1730  	EndTime string `json:"endTime,omitempty"`
  1731  
  1732  	// EphemeralMessage: Ephemeral message that may change every time the
  1733  	// operation is polled. @OutputOnly
  1734  	EphemeralMessage string `json:"ephemeralMessage,omitempty"`
  1735  
  1736  	// InsertTime: Time that this operation was created.@OutputOnly
  1737  	InsertTime string `json:"insertTime,omitempty"`
  1738  
  1739  	// Method: API method that initiated this operation. Example:
  1740  	// google.appengine.v1.Versions.CreateVersion.@OutputOnly
  1741  	Method string `json:"method,omitempty"`
  1742  
  1743  	// Target: Name of the resource that this operation is acting on.
  1744  	// Example: apps/myapp/services/default.@OutputOnly
  1745  	Target string `json:"target,omitempty"`
  1746  
  1747  	// User: User who requested this operation.@OutputOnly
  1748  	User string `json:"user,omitempty"`
  1749  
  1750  	// Warning: Durable messages that persist on every operation poll.
  1751  	// @OutputOnly
  1752  	Warning []string `json:"warning,omitempty"`
  1753  
  1754  	// ForceSendFields is a list of field names (e.g.
  1755  	// "CreateVersionMetadata") to unconditionally include in API requests.
  1756  	// By default, fields with empty values are omitted from API requests.
  1757  	// However, any non-pointer, non-interface field appearing in
  1758  	// ForceSendFields will be sent to the server regardless of whether the
  1759  	// field is empty or not. This may be used to include empty fields in
  1760  	// Patch requests.
  1761  	ForceSendFields []string `json:"-"`
  1762  
  1763  	// NullFields is a list of field names (e.g. "CreateVersionMetadata") to
  1764  	// include in API requests with the JSON null value. By default, fields
  1765  	// with empty values are omitted from API requests. However, any field
  1766  	// with an empty value appearing in NullFields will be sent to the
  1767  	// server as null. It is an error if a field in this list has a
  1768  	// non-empty value. This may be used to include null fields in Patch
  1769  	// requests.
  1770  	NullFields []string `json:"-"`
  1771  }
  1772  
  1773  func (s *OperationMetadataV1) MarshalJSON() ([]byte, error) {
  1774  	type NoMethod OperationMetadataV1
  1775  	raw := NoMethod(*s)
  1776  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1777  }
  1778  
  1779  // OperationMetadataV1Alpha: Metadata for the given
  1780  // google.longrunning.Operation.
  1781  type OperationMetadataV1Alpha struct {
  1782  	CreateVersionMetadata *CreateVersionMetadataV1Alpha `json:"createVersionMetadata,omitempty"`
  1783  
  1784  	// EndTime: Time that this operation completed.@OutputOnly
  1785  	EndTime string `json:"endTime,omitempty"`
  1786  
  1787  	// EphemeralMessage: Ephemeral message that may change every time the
  1788  	// operation is polled. @OutputOnly
  1789  	EphemeralMessage string `json:"ephemeralMessage,omitempty"`
  1790  
  1791  	// InsertTime: Time that this operation was created.@OutputOnly
  1792  	InsertTime string `json:"insertTime,omitempty"`
  1793  
  1794  	// Method: API method that initiated this operation. Example:
  1795  	// google.appengine.v1alpha.Versions.CreateVersion.@OutputOnly
  1796  	Method string `json:"method,omitempty"`
  1797  
  1798  	// Target: Name of the resource that this operation is acting on.
  1799  	// Example: apps/myapp/services/default.@OutputOnly
  1800  	Target string `json:"target,omitempty"`
  1801  
  1802  	// User: User who requested this operation.@OutputOnly
  1803  	User string `json:"user,omitempty"`
  1804  
  1805  	// Warning: Durable messages that persist on every operation poll.
  1806  	// @OutputOnly
  1807  	Warning []string `json:"warning,omitempty"`
  1808  
  1809  	// ForceSendFields is a list of field names (e.g.
  1810  	// "CreateVersionMetadata") to unconditionally include in API requests.
  1811  	// By default, fields with empty values are omitted from API requests.
  1812  	// However, any non-pointer, non-interface field appearing in
  1813  	// ForceSendFields will be sent to the server regardless of whether the
  1814  	// field is empty or not. This may be used to include empty fields in
  1815  	// Patch requests.
  1816  	ForceSendFields []string `json:"-"`
  1817  
  1818  	// NullFields is a list of field names (e.g. "CreateVersionMetadata") to
  1819  	// include in API requests with the JSON null value. By default, fields
  1820  	// with empty values are omitted from API requests. However, any field
  1821  	// with an empty value appearing in NullFields will be sent to the
  1822  	// server as null. It is an error if a field in this list has a
  1823  	// non-empty value. This may be used to include null fields in Patch
  1824  	// requests.
  1825  	NullFields []string `json:"-"`
  1826  }
  1827  
  1828  func (s *OperationMetadataV1Alpha) MarshalJSON() ([]byte, error) {
  1829  	type NoMethod OperationMetadataV1Alpha
  1830  	raw := NoMethod(*s)
  1831  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1832  }
  1833  
  1834  // OperationMetadataV1Beta: Metadata for the given
  1835  // google.longrunning.Operation.
  1836  type OperationMetadataV1Beta struct {
  1837  	CreateVersionMetadata *CreateVersionMetadataV1Beta `json:"createVersionMetadata,omitempty"`
  1838  
  1839  	// EndTime: Time that this operation completed.@OutputOnly
  1840  	EndTime string `json:"endTime,omitempty"`
  1841  
  1842  	// EphemeralMessage: Ephemeral message that may change every time the
  1843  	// operation is polled. @OutputOnly
  1844  	EphemeralMessage string `json:"ephemeralMessage,omitempty"`
  1845  
  1846  	// InsertTime: Time that this operation was created.@OutputOnly
  1847  	InsertTime string `json:"insertTime,omitempty"`
  1848  
  1849  	// Method: API method that initiated this operation. Example:
  1850  	// google.appengine.v1beta.Versions.CreateVersion.@OutputOnly
  1851  	Method string `json:"method,omitempty"`
  1852  
  1853  	// Target: Name of the resource that this operation is acting on.
  1854  	// Example: apps/myapp/services/default.@OutputOnly
  1855  	Target string `json:"target,omitempty"`
  1856  
  1857  	// User: User who requested this operation.@OutputOnly
  1858  	User string `json:"user,omitempty"`
  1859  
  1860  	// Warning: Durable messages that persist on every operation poll.
  1861  	// @OutputOnly
  1862  	Warning []string `json:"warning,omitempty"`
  1863  
  1864  	// ForceSendFields is a list of field names (e.g.
  1865  	// "CreateVersionMetadata") to unconditionally include in API requests.
  1866  	// By default, fields with empty values are omitted from API requests.
  1867  	// However, any non-pointer, non-interface field appearing in
  1868  	// ForceSendFields will be sent to the server regardless of whether the
  1869  	// field is empty or not. This may be used to include empty fields in
  1870  	// Patch requests.
  1871  	ForceSendFields []string `json:"-"`
  1872  
  1873  	// NullFields is a list of field names (e.g. "CreateVersionMetadata") to
  1874  	// include in API requests with the JSON null value. By default, fields
  1875  	// with empty values are omitted from API requests. However, any field
  1876  	// with an empty value appearing in NullFields will be sent to the
  1877  	// server as null. It is an error if a field in this list has a
  1878  	// non-empty value. This may be used to include null fields in Patch
  1879  	// requests.
  1880  	NullFields []string `json:"-"`
  1881  }
  1882  
  1883  func (s *OperationMetadataV1Beta) MarshalJSON() ([]byte, error) {
  1884  	type NoMethod OperationMetadataV1Beta
  1885  	raw := NoMethod(*s)
  1886  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1887  }
  1888  
  1889  // OperationMetadataV1Beta5: Metadata for the given
  1890  // google.longrunning.Operation.
  1891  type OperationMetadataV1Beta5 struct {
  1892  	// EndTime: Timestamp that this operation completed.@OutputOnly
  1893  	EndTime string `json:"endTime,omitempty"`
  1894  
  1895  	// InsertTime: Timestamp that this operation was created.@OutputOnly
  1896  	InsertTime string `json:"insertTime,omitempty"`
  1897  
  1898  	// Method: API method name that initiated this operation. Example:
  1899  	// google.appengine.v1beta5.Version.CreateVersion.@OutputOnly
  1900  	Method string `json:"method,omitempty"`
  1901  
  1902  	// Target: Name of the resource that this operation is acting on.
  1903  	// Example: apps/myapp/services/default.@OutputOnly
  1904  	Target string `json:"target,omitempty"`
  1905  
  1906  	// User: User who requested this operation.@OutputOnly
  1907  	User string `json:"user,omitempty"`
  1908  
  1909  	// ForceSendFields is a list of field names (e.g. "EndTime") to
  1910  	// unconditionally include in API requests. By default, fields with
  1911  	// empty values are omitted from API requests. However, any non-pointer,
  1912  	// non-interface field appearing in ForceSendFields will be sent to the
  1913  	// server regardless of whether the field is empty or not. This may be
  1914  	// used to include empty fields in Patch requests.
  1915  	ForceSendFields []string `json:"-"`
  1916  
  1917  	// NullFields is a list of field names (e.g. "EndTime") to include in
  1918  	// API requests with the JSON null value. By default, fields with empty
  1919  	// values are omitted from API requests. However, any field with an
  1920  	// empty value appearing in NullFields will be sent to the server as
  1921  	// null. It is an error if a field in this list has a non-empty value.
  1922  	// This may be used to include null fields in Patch requests.
  1923  	NullFields []string `json:"-"`
  1924  }
  1925  
  1926  func (s *OperationMetadataV1Beta5) MarshalJSON() ([]byte, error) {
  1927  	type NoMethod OperationMetadataV1Beta5
  1928  	raw := NoMethod(*s)
  1929  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1930  }
  1931  
  1932  // RequestUtilization: Target scaling by request utilization. Only
  1933  // applicable for VM runtimes.
  1934  type RequestUtilization struct {
  1935  	// TargetConcurrentRequests: Target number of concurrent requests.
  1936  	TargetConcurrentRequests int64 `json:"targetConcurrentRequests,omitempty"`
  1937  
  1938  	// TargetRequestCountPerSec: Target requests per second.
  1939  	TargetRequestCountPerSec int64 `json:"targetRequestCountPerSec,omitempty"`
  1940  
  1941  	// ForceSendFields is a list of field names (e.g.
  1942  	// "TargetConcurrentRequests") to unconditionally include in API
  1943  	// requests. By default, fields with empty values are omitted from API
  1944  	// requests. However, any non-pointer, non-interface field appearing in
  1945  	// ForceSendFields will be sent to the server regardless of whether the
  1946  	// field is empty or not. This may be used to include empty fields in
  1947  	// Patch requests.
  1948  	ForceSendFields []string `json:"-"`
  1949  
  1950  	// NullFields is a list of field names (e.g. "TargetConcurrentRequests")
  1951  	// to include in API requests with the JSON null value. By default,
  1952  	// fields with empty values are omitted from API requests. However, any
  1953  	// field with an empty value appearing in NullFields will be sent to the
  1954  	// server as null. It is an error if a field in this list has a
  1955  	// non-empty value. This may be used to include null fields in Patch
  1956  	// requests.
  1957  	NullFields []string `json:"-"`
  1958  }
  1959  
  1960  func (s *RequestUtilization) MarshalJSON() ([]byte, error) {
  1961  	type NoMethod RequestUtilization
  1962  	raw := NoMethod(*s)
  1963  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  1964  }
  1965  
  1966  // Resources: Machine resources for a version.
  1967  type Resources struct {
  1968  	// Cpu: Number of CPU cores needed.
  1969  	Cpu float64 `json:"cpu,omitempty"`
  1970  
  1971  	// DiskGb: Disk size (GB) needed.
  1972  	DiskGb float64 `json:"diskGb,omitempty"`
  1973  
  1974  	// MemoryGb: Memory (GB) needed.
  1975  	MemoryGb float64 `json:"memoryGb,omitempty"`
  1976  
  1977  	// Volumes: User specified volumes.
  1978  	Volumes []*Volume `json:"volumes,omitempty"`
  1979  
  1980  	// ForceSendFields is a list of field names (e.g. "Cpu") to
  1981  	// unconditionally include in API requests. By default, fields with
  1982  	// empty values are omitted from API requests. However, any non-pointer,
  1983  	// non-interface field appearing in ForceSendFields will be sent to the
  1984  	// server regardless of whether the field is empty or not. This may be
  1985  	// used to include empty fields in Patch requests.
  1986  	ForceSendFields []string `json:"-"`
  1987  
  1988  	// NullFields is a list of field names (e.g. "Cpu") to include in API
  1989  	// requests with the JSON null value. By default, fields with empty
  1990  	// values are omitted from API requests. However, any field with an
  1991  	// empty value appearing in NullFields will be sent to the server as
  1992  	// null. It is an error if a field in this list has a non-empty value.
  1993  	// This may be used to include null fields in Patch requests.
  1994  	NullFields []string `json:"-"`
  1995  }
  1996  
  1997  func (s *Resources) MarshalJSON() ([]byte, error) {
  1998  	type NoMethod Resources
  1999  	raw := NoMethod(*s)
  2000  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  2001  }
  2002  
  2003  func (s *Resources) UnmarshalJSON(data []byte) error {
  2004  	type NoMethod Resources
  2005  	var s1 struct {
  2006  		Cpu      gensupport.JSONFloat64 `json:"cpu"`
  2007  		DiskGb   gensupport.JSONFloat64 `json:"diskGb"`
  2008  		MemoryGb gensupport.JSONFloat64 `json:"memoryGb"`
  2009  		*NoMethod
  2010  	}
  2011  	s1.NoMethod = (*NoMethod)(s)
  2012  	if err := json.Unmarshal(data, &s1); err != nil {
  2013  		return err
  2014  	}
  2015  	s.Cpu = float64(s1.Cpu)
  2016  	s.DiskGb = float64(s1.DiskGb)
  2017  	s.MemoryGb = float64(s1.MemoryGb)
  2018  	return nil
  2019  }
  2020  
  2021  // ScriptHandler: Executes a script to handle the request that matches
  2022  // the URL pattern.
  2023  type ScriptHandler struct {
  2024  	// ScriptPath: Path to the script from the application root directory.
  2025  	ScriptPath string `json:"scriptPath,omitempty"`
  2026  
  2027  	// ForceSendFields is a list of field names (e.g. "ScriptPath") to
  2028  	// unconditionally include in API requests. By default, fields with
  2029  	// empty values are omitted from API requests. However, any non-pointer,
  2030  	// non-interface field appearing in ForceSendFields will be sent to the
  2031  	// server regardless of whether the field is empty or not. This may be
  2032  	// used to include empty fields in Patch requests.
  2033  	ForceSendFields []string `json:"-"`
  2034  
  2035  	// NullFields is a list of field names (e.g. "ScriptPath") to include in
  2036  	// API requests with the JSON null value. By default, fields with empty
  2037  	// values are omitted from API requests. However, any field with an
  2038  	// empty value appearing in NullFields will be sent to the server as
  2039  	// null. It is an error if a field in this list has a non-empty value.
  2040  	// This may be used to include null fields in Patch requests.
  2041  	NullFields []string `json:"-"`
  2042  }
  2043  
  2044  func (s *ScriptHandler) MarshalJSON() ([]byte, error) {
  2045  	type NoMethod ScriptHandler
  2046  	raw := NoMethod(*s)
  2047  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  2048  }
  2049  
  2050  // SourceReference: Reference to a particular snapshot of the source
  2051  // tree used to build and deploy the application.
  2052  type SourceReference struct {
  2053  	// Repository: URI string identifying the repository. Example:
  2054  	// "https://source.developers.google.com/p/app-123/r/default"
  2055  	Repository string `json:"repository,omitempty"`
  2056  
  2057  	// RevisionId: The canonical, persistent identifier of the deployed
  2058  	// revision. Aliases that include tags or branch names are not allowed.
  2059  	// Example (git): "2198322f89e0bb2e25021667c2ed489d1fd34e6b"
  2060  	RevisionId string `json:"revisionId,omitempty"`
  2061  
  2062  	// ForceSendFields is a list of field names (e.g. "Repository") to
  2063  	// unconditionally include in API requests. By default, fields with
  2064  	// empty values are omitted from API requests. However, any non-pointer,
  2065  	// non-interface field appearing in ForceSendFields will be sent to the
  2066  	// server regardless of whether the field is empty or not. This may be
  2067  	// used to include empty fields in Patch requests.
  2068  	ForceSendFields []string `json:"-"`
  2069  
  2070  	// NullFields is a list of field names (e.g. "Repository") to include in
  2071  	// API requests with the JSON null value. By default, fields with empty
  2072  	// values are omitted from API requests. However, any field with an
  2073  	// empty value appearing in NullFields will be sent to the server as
  2074  	// null. It is an error if a field in this list has a non-empty value.
  2075  	// This may be used to include null fields in Patch requests.
  2076  	NullFields []string `json:"-"`
  2077  }
  2078  
  2079  func (s *SourceReference) MarshalJSON() ([]byte, error) {
  2080  	type NoMethod SourceReference
  2081  	raw := NoMethod(*s)
  2082  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  2083  }
  2084  
  2085  // StaticDirectoryHandler: Files served directly to the user for a given
  2086  // URL, such as images, CSS stylesheets, or JavaScript source files.
  2087  // Static directory handlers make it easy to serve the entire contents
  2088  // of a directory as static files.
  2089  type StaticDirectoryHandler struct {
  2090  	// ApplicationReadable: Whether files should also be uploaded as code
  2091  	// data. By default, files declared in static directory handlers are
  2092  	// uploaded as static data and are only served to end users; they cannot
  2093  	// be read by the application. If enabled, uploads are charged against
  2094  	// both your code and static data storage resource quotas.
  2095  	ApplicationReadable bool `json:"applicationReadable,omitempty"`
  2096  
  2097  	// Directory: Path to the directory containing the static files from the
  2098  	// application root directory. Everything after the end of the matched
  2099  	// URL pattern is appended to static_dir to form the full path to the
  2100  	// requested file.
  2101  	Directory string `json:"directory,omitempty"`
  2102  
  2103  	// Expiration: Time a static file served by this handler should be
  2104  	// cached.
  2105  	Expiration string `json:"expiration,omitempty"`
  2106  
  2107  	// HttpHeaders: HTTP headers to use for all responses from these URLs.
  2108  	HttpHeaders map[string]string `json:"httpHeaders,omitempty"`
  2109  
  2110  	// MimeType: MIME type used to serve all files served by this handler.
  2111  	// Defaults to file-specific MIME types, which are direved from each
  2112  	// file's filename extension.
  2113  	MimeType string `json:"mimeType,omitempty"`
  2114  
  2115  	// RequireMatchingFile: Whether this handler should match the request if
  2116  	// the file referenced by the handler does not exist.
  2117  	RequireMatchingFile bool `json:"requireMatchingFile,omitempty"`
  2118  
  2119  	// ForceSendFields is a list of field names (e.g. "ApplicationReadable")
  2120  	// to unconditionally include in API requests. By default, fields with
  2121  	// empty values are omitted from API requests. However, any non-pointer,
  2122  	// non-interface field appearing in ForceSendFields will be sent to the
  2123  	// server regardless of whether the field is empty or not. This may be
  2124  	// used to include empty fields in Patch requests.
  2125  	ForceSendFields []string `json:"-"`
  2126  
  2127  	// NullFields is a list of field names (e.g. "ApplicationReadable") to
  2128  	// include in API requests with the JSON null value. By default, fields
  2129  	// with empty values are omitted from API requests. However, any field
  2130  	// with an empty value appearing in NullFields will be sent to the
  2131  	// server as null. It is an error if a field in this list has a
  2132  	// non-empty value. This may be used to include null fields in Patch
  2133  	// requests.
  2134  	NullFields []string `json:"-"`
  2135  }
  2136  
  2137  func (s *StaticDirectoryHandler) MarshalJSON() ([]byte, error) {
  2138  	type NoMethod StaticDirectoryHandler
  2139  	raw := NoMethod(*s)
  2140  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  2141  }
  2142  
  2143  // StaticFilesHandler: Files served directly to the user for a given
  2144  // URL, such as images, CSS stylesheets, or JavaScript source files.
  2145  // Static file handlers describe which files in the application
  2146  // directory are static files, and which URLs serve them.
  2147  type StaticFilesHandler struct {
  2148  	// ApplicationReadable: Whether files should also be uploaded as code
  2149  	// data. By default, files declared in static file handlers are uploaded
  2150  	// as static data and are only served to end users; they cannot be read
  2151  	// by the application. If enabled, uploads are charged against both your
  2152  	// code and static data storage resource quotas.
  2153  	ApplicationReadable bool `json:"applicationReadable,omitempty"`
  2154  
  2155  	// Expiration: Time a static file served by this handler should be
  2156  	// cached.
  2157  	Expiration string `json:"expiration,omitempty"`
  2158  
  2159  	// HttpHeaders: HTTP headers to use for all responses from these URLs.
  2160  	HttpHeaders map[string]string `json:"httpHeaders,omitempty"`
  2161  
  2162  	// MimeType: MIME type used to serve all files served by this handler.
  2163  	// Defaults to file-specific MIME types, which are derived from each
  2164  	// file's filename extension.
  2165  	MimeType string `json:"mimeType,omitempty"`
  2166  
  2167  	// Path: Path to the static files matched by the URL pattern, from the
  2168  	// application root directory. The path can refer to text matched in
  2169  	// groupings in the URL pattern.
  2170  	Path string `json:"path,omitempty"`
  2171  
  2172  	// RequireMatchingFile: Whether this handler should match the request if
  2173  	// the file referenced by the handler does not exist.
  2174  	RequireMatchingFile bool `json:"requireMatchingFile,omitempty"`
  2175  
  2176  	// UploadPathRegex: Regular expression that matches the file paths for
  2177  	// all files that should be referenced by this handler.
  2178  	UploadPathRegex string `json:"uploadPathRegex,omitempty"`
  2179  
  2180  	// ForceSendFields is a list of field names (e.g. "ApplicationReadable")
  2181  	// to unconditionally include in API requests. By default, fields with
  2182  	// empty values are omitted from API requests. However, any non-pointer,
  2183  	// non-interface field appearing in ForceSendFields will be sent to the
  2184  	// server regardless of whether the field is empty or not. This may be
  2185  	// used to include empty fields in Patch requests.
  2186  	ForceSendFields []string `json:"-"`
  2187  
  2188  	// NullFields is a list of field names (e.g. "ApplicationReadable") to
  2189  	// include in API requests with the JSON null value. By default, fields
  2190  	// with empty values are omitted from API requests. However, any field
  2191  	// with an empty value appearing in NullFields will be sent to the
  2192  	// server as null. It is an error if a field in this list has a
  2193  	// non-empty value. This may be used to include null fields in Patch
  2194  	// requests.
  2195  	NullFields []string `json:"-"`
  2196  }
  2197  
  2198  func (s *StaticFilesHandler) MarshalJSON() ([]byte, error) {
  2199  	type NoMethod StaticFilesHandler
  2200  	raw := NoMethod(*s)
  2201  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  2202  }
  2203  
  2204  // Status: The Status type defines a logical error model that is
  2205  // suitable for different programming environments, including REST APIs
  2206  // and RPC APIs. It is used by gRPC (https://github.com/grpc). The error
  2207  // model is designed to be:
  2208  // Simple to use and understand for most users
  2209  // Flexible enough to meet unexpected needsOverviewThe Status message
  2210  // contains three pieces of data: error code, error message, and error
  2211  // details. The error code should be an enum value of google.rpc.Code,
  2212  // but it may accept additional error codes if needed. The error message
  2213  // should be a developer-facing English message that helps developers
  2214  // understand and resolve the error. If a localized user-facing error
  2215  // message is needed, put the localized message in the error details or
  2216  // localize it in the client. The optional error details may contain
  2217  // arbitrary information about the error. There is a predefined set of
  2218  // error detail types in the package google.rpc that can be used for
  2219  // common error conditions.Language mappingThe Status message is the
  2220  // logical representation of the error model, but it is not necessarily
  2221  // the actual wire format. When the Status message is exposed in
  2222  // different client libraries and different wire protocols, it can be
  2223  // mapped differently. For example, it will likely be mapped to some
  2224  // exceptions in Java, but more likely mapped to some error codes in
  2225  // C.Other usesThe error model and the Status message can be used in a
  2226  // variety of environments, either with or without APIs, to provide a
  2227  // consistent developer experience across different environments.Example
  2228  // uses of this error model include:
  2229  // Partial errors. If a service needs to return partial errors to the
  2230  // client, it may embed the Status in the normal response to indicate
  2231  // the partial errors.
  2232  // Workflow errors. A typical workflow has multiple steps. Each step may
  2233  // have a Status message for error reporting.
  2234  // Batch operations. If a client uses batch request and batch response,
  2235  // the Status message should be used directly inside batch response, one
  2236  // for each error sub-response.
  2237  // Asynchronous operations. If an API call embeds asynchronous operation
  2238  // results in its response, the status of those operations should be
  2239  // represented directly using the Status message.
  2240  // Logging. If some API errors are stored in logs, the message Status
  2241  // could be used directly after any stripping needed for
  2242  // security/privacy reasons.
  2243  type Status struct {
  2244  	// Code: The status code, which should be an enum value of
  2245  	// google.rpc.Code.
  2246  	Code int64 `json:"code,omitempty"`
  2247  
  2248  	// Details: A list of messages that carry the error details. There is a
  2249  	// common set of message types for APIs to use.
  2250  	Details []googleapi.RawMessage `json:"details,omitempty"`
  2251  
  2252  	// Message: A developer-facing error message, which should be in
  2253  	// English. Any user-facing error message should be localized and sent
  2254  	// in the google.rpc.Status.details field, or localized by the client.
  2255  	Message string `json:"message,omitempty"`
  2256  
  2257  	// ForceSendFields is a list of field names (e.g. "Code") to
  2258  	// unconditionally include in API requests. By default, fields with
  2259  	// empty values are omitted from API requests. However, any non-pointer,
  2260  	// non-interface field appearing in ForceSendFields will be sent to the
  2261  	// server regardless of whether the field is empty or not. This may be
  2262  	// used to include empty fields in Patch requests.
  2263  	ForceSendFields []string `json:"-"`
  2264  
  2265  	// NullFields is a list of field names (e.g. "Code") to include in API
  2266  	// requests with the JSON null value. By default, fields with empty
  2267  	// values are omitted from API requests. However, any field with an
  2268  	// empty value appearing in NullFields will be sent to the server as
  2269  	// null. It is an error if a field in this list has a non-empty value.
  2270  	// This may be used to include null fields in Patch requests.
  2271  	NullFields []string `json:"-"`
  2272  }
  2273  
  2274  func (s *Status) MarshalJSON() ([]byte, error) {
  2275  	type NoMethod Status
  2276  	raw := NoMethod(*s)
  2277  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  2278  }
  2279  
  2280  // TrafficSplit: Traffic routing configuration for versions within a
  2281  // single module. Traffic splits define how traffic directed to the
  2282  // module is assigned to versions.
  2283  type TrafficSplit struct {
  2284  	// Allocations: Mapping from version IDs within the module to fractional
  2285  	// (0.000, 1] allocations of traffic for that version. Each version can
  2286  	// be specified only once, but some versions in the module may not have
  2287  	// any traffic allocation. Modules that have traffic allocated cannot be
  2288  	// deleted until either the module is deleted or their traffic
  2289  	// allocation is removed. Allocations must sum to 1. Up to two decimal
  2290  	// place precision is supported for IP-based splits and up to three
  2291  	// decimal places is supported for cookie-based splits.
  2292  	Allocations map[string]float64 `json:"allocations,omitempty"`
  2293  
  2294  	// ShardBy: Mechanism used to determine which version a request is sent
  2295  	// to. The traffic selection algorithm will be stable for either type
  2296  	// until allocations are changed.
  2297  	//
  2298  	// Possible values:
  2299  	//   "UNSPECIFIED" - Diversion method unspecified.
  2300  	//   "COOKIE" - Diversion based on a specially named cookie,
  2301  	// "GOOGAPPUID." The cookie must be set by the application itself or
  2302  	// else no diversion will occur.
  2303  	//   "IP" - Diversion based on applying the modulus operation to a
  2304  	// fingerprint of the IP address.
  2305  	ShardBy string `json:"shardBy,omitempty"`
  2306  
  2307  	// ForceSendFields is a list of field names (e.g. "Allocations") to
  2308  	// unconditionally include in API requests. By default, fields with
  2309  	// empty values are omitted from API requests. However, any non-pointer,
  2310  	// non-interface field appearing in ForceSendFields will be sent to the
  2311  	// server regardless of whether the field is empty or not. This may be
  2312  	// used to include empty fields in Patch requests.
  2313  	ForceSendFields []string `json:"-"`
  2314  
  2315  	// NullFields is a list of field names (e.g. "Allocations") to include
  2316  	// in API requests with the JSON null value. By default, fields with
  2317  	// empty values are omitted from API requests. However, any field with
  2318  	// an empty value appearing in NullFields will be sent to the server as
  2319  	// null. It is an error if a field in this list has a non-empty value.
  2320  	// This may be used to include null fields in Patch requests.
  2321  	NullFields []string `json:"-"`
  2322  }
  2323  
  2324  func (s *TrafficSplit) MarshalJSON() ([]byte, error) {
  2325  	type NoMethod TrafficSplit
  2326  	raw := NoMethod(*s)
  2327  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  2328  }
  2329  
  2330  // UrlDispatchRule: Rules to match an HTTP request and dispatch that
  2331  // request to a module.
  2332  type UrlDispatchRule struct {
  2333  	// Domain: Domain name to match against. The wildcard "*" is supported
  2334  	// if specified before a period: "*.".Defaults to matching all domains:
  2335  	// "*".
  2336  	Domain string `json:"domain,omitempty"`
  2337  
  2338  	// Module: Resource ID of a module in this application that should serve
  2339  	// the matched request. The module must already exist. Example: default.
  2340  	Module string `json:"module,omitempty"`
  2341  
  2342  	// Path: Pathname within the host. Must start with a "/". A single "*"
  2343  	// can be included at the end of the path. The sum of the lengths of the
  2344  	// domain and path may not exceed 100 characters.
  2345  	Path string `json:"path,omitempty"`
  2346  
  2347  	// ForceSendFields is a list of field names (e.g. "Domain") to
  2348  	// unconditionally include in API requests. By default, fields with
  2349  	// empty values are omitted from API requests. However, any non-pointer,
  2350  	// non-interface field appearing in ForceSendFields will be sent to the
  2351  	// server regardless of whether the field is empty or not. This may be
  2352  	// used to include empty fields in Patch requests.
  2353  	ForceSendFields []string `json:"-"`
  2354  
  2355  	// NullFields is a list of field names (e.g. "Domain") to include in API
  2356  	// requests with the JSON null value. By default, fields with empty
  2357  	// values are omitted from API requests. However, any field with an
  2358  	// empty value appearing in NullFields will be sent to the server as
  2359  	// null. It is an error if a field in this list has a non-empty value.
  2360  	// This may be used to include null fields in Patch requests.
  2361  	NullFields []string `json:"-"`
  2362  }
  2363  
  2364  func (s *UrlDispatchRule) MarshalJSON() ([]byte, error) {
  2365  	type NoMethod UrlDispatchRule
  2366  	raw := NoMethod(*s)
  2367  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  2368  }
  2369  
  2370  // UrlMap: URL pattern and description of how the URL should be handled.
  2371  // App Engine can handle URLs by executing application code, or by
  2372  // serving static files uploaded with the version, such as images, CSS,
  2373  // or JavaScript.
  2374  type UrlMap struct {
  2375  	// ApiEndpoint: Uses API Endpoints to handle requests.
  2376  	ApiEndpoint *ApiEndpointHandler `json:"apiEndpoint,omitempty"`
  2377  
  2378  	// AuthFailAction: Action to take when users access resources that
  2379  	// require authentication. Defaults to redirect.
  2380  	//
  2381  	// Possible values:
  2382  	//   "AUTH_FAIL_ACTION_UNSPECIFIED" - Not specified.
  2383  	// AUTH_FAIL_ACTION_REDIRECT is assumed.
  2384  	//   "AUTH_FAIL_ACTION_REDIRECT" - Redirects user to
  2385  	// "accounts.google.com". The user is redirected back to the application
  2386  	// URL after signing in or creating an account.
  2387  	//   "AUTH_FAIL_ACTION_UNAUTHORIZED" - Rejects request with a 401 HTTP
  2388  	// status code and an error message.
  2389  	AuthFailAction string `json:"authFailAction,omitempty"`
  2390  
  2391  	// Login: Level of login required to access this resource.
  2392  	//
  2393  	// Possible values:
  2394  	//   "LOGIN_UNSPECIFIED" - Not specified. LOGIN_OPTIONAL is assumed.
  2395  	//   "LOGIN_OPTIONAL" - Does not require that the user is signed in.
  2396  	//   "LOGIN_ADMIN" - If the user is not signed in, the auth_fail_action
  2397  	// is taken. In addition, if the user is not an administrator for the
  2398  	// application, they are given an error message regardless of
  2399  	// auth_fail_action. If the user is an administrator, the handler
  2400  	// proceeds.
  2401  	//   "LOGIN_REQUIRED" - If the user has signed in, the handler proceeds
  2402  	// normally. Otherwise, the auth_fail_action is taken.
  2403  	Login string `json:"login,omitempty"`
  2404  
  2405  	// RedirectHttpResponseCode: 30x code to use when performing redirects
  2406  	// for the secure field. Defaults to 302.
  2407  	//
  2408  	// Possible values:
  2409  	//   "REDIRECT_HTTP_RESPONSE_CODE_UNSPECIFIED" - Not specified. 302 is
  2410  	// assumed.
  2411  	//   "REDIRECT_HTTP_RESPONSE_CODE_301" - 301 Moved Permanently code.
  2412  	//   "REDIRECT_HTTP_RESPONSE_CODE_302" - 302 Moved Temporarily code.
  2413  	//   "REDIRECT_HTTP_RESPONSE_CODE_303" - 303 See Other code.
  2414  	//   "REDIRECT_HTTP_RESPONSE_CODE_307" - 307 Temporary Redirect code.
  2415  	RedirectHttpResponseCode string `json:"redirectHttpResponseCode,omitempty"`
  2416  
  2417  	// Script: Executes a script to handle the request that matches this URL
  2418  	// pattern.
  2419  	Script *ScriptHandler `json:"script,omitempty"`
  2420  
  2421  	// SecurityLevel: Security (HTTPS) enforcement for this URL.
  2422  	//
  2423  	// Possible values:
  2424  	//   "SECURE_UNSPECIFIED" - Not specified.
  2425  	//   "SECURE_DEFAULT" - Both HTTP and HTTPS requests with URLs that
  2426  	// match the handler succeed without redirects. The application can
  2427  	// examine the request to determine which protocol was used, and respond
  2428  	// accordingly.
  2429  	//   "SECURE_NEVER" - Requests for a URL that match this handler that
  2430  	// use HTTPS are automatically redirected to the HTTP equivalent URL.
  2431  	//   "SECURE_OPTIONAL" - Both HTTP and HTTPS requests with URLs that
  2432  	// match the handler succeed without redirects. The application can
  2433  	// examine the request to determine which protocol was used and respond
  2434  	// accordingly.
  2435  	//   "SECURE_ALWAYS" - Requests for a URL that match this handler that
  2436  	// do not use HTTPS are automatically redirected to the HTTPS URL with
  2437  	// the same path. Query parameters are reserved for the redirect.
  2438  	SecurityLevel string `json:"securityLevel,omitempty"`
  2439  
  2440  	// StaticDirectory: Serves the entire contents of a directory as static
  2441  	// files.This attribute is deprecated. You can mimic the behavior of
  2442  	// static directories using static files.
  2443  	StaticDirectory *StaticDirectoryHandler `json:"staticDirectory,omitempty"`
  2444  
  2445  	// StaticFiles: Returns the contents of a file, such as an image, as the
  2446  	// response.
  2447  	StaticFiles *StaticFilesHandler `json:"staticFiles,omitempty"`
  2448  
  2449  	// UrlRegex: A URL prefix. Uses regular expression syntax, which means
  2450  	// regexp special characters must be escaped, but should not contain
  2451  	// groupings. All URLs that begin with this prefix are handled by this
  2452  	// handler, using the portion of the URL after the prefix as part of the
  2453  	// file path.
  2454  	UrlRegex string `json:"urlRegex,omitempty"`
  2455  
  2456  	// ForceSendFields is a list of field names (e.g. "ApiEndpoint") to
  2457  	// unconditionally include in API requests. By default, fields with
  2458  	// empty values are omitted from API requests. However, any non-pointer,
  2459  	// non-interface field appearing in ForceSendFields will be sent to the
  2460  	// server regardless of whether the field is empty or not. This may be
  2461  	// used to include empty fields in Patch requests.
  2462  	ForceSendFields []string `json:"-"`
  2463  
  2464  	// NullFields is a list of field names (e.g. "ApiEndpoint") to include
  2465  	// in API requests with the JSON null value. By default, fields with
  2466  	// empty values are omitted from API requests. However, any field with
  2467  	// an empty value appearing in NullFields will be sent to the server as
  2468  	// null. It is an error if a field in this list has a non-empty value.
  2469  	// This may be used to include null fields in Patch requests.
  2470  	NullFields []string `json:"-"`
  2471  }
  2472  
  2473  func (s *UrlMap) MarshalJSON() ([]byte, error) {
  2474  	type NoMethod UrlMap
  2475  	raw := NoMethod(*s)
  2476  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  2477  }
  2478  
  2479  // Version: A Version resource is a specific set of source code and
  2480  // configuration files that are deployed into a module.
  2481  type Version struct {
  2482  	// ApiConfig: Serving configuration for Google Cloud Endpoints
  2483  	// (https://cloud.google.com/appengine/docs/python/endpoints/).Only
  2484  	// returned in GET requests if view=FULL is set.
  2485  	ApiConfig *ApiConfigHandler `json:"apiConfig,omitempty"`
  2486  
  2487  	// AutomaticScaling: Automatic scaling is based on request rate,
  2488  	// response latencies, and other application metrics.
  2489  	AutomaticScaling *AutomaticScaling `json:"automaticScaling,omitempty"`
  2490  
  2491  	// BasicScaling: A module with basic scaling will create an instance
  2492  	// when the application receives a request. The instance will be turned
  2493  	// down when the app becomes idle. Basic scaling is ideal for work that
  2494  	// is intermittent or driven by user activity.
  2495  	BasicScaling *BasicScaling `json:"basicScaling,omitempty"`
  2496  
  2497  	// BetaSettings: Metadata settings that are supplied to this version to
  2498  	// enable beta runtime features.
  2499  	BetaSettings map[string]string `json:"betaSettings,omitempty"`
  2500  
  2501  	// CreationTime: Time that this version was created.@OutputOnly
  2502  	CreationTime string `json:"creationTime,omitempty"`
  2503  
  2504  	// DefaultExpiration: Duration that static files should be cached by web
  2505  	// proxies and browsers. Only applicable if the corresponding
  2506  	// StaticFilesHandler
  2507  	// (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1/apps.services.versions#staticfileshandler)
  2508  	// does not specify its own expiration time.Only returned in GET
  2509  	// requests if view=FULL is set.
  2510  	DefaultExpiration string `json:"defaultExpiration,omitempty"`
  2511  
  2512  	// Deployer: Email address of the user who created this
  2513  	// version.@OutputOnly
  2514  	Deployer string `json:"deployer,omitempty"`
  2515  
  2516  	// Deployment: Code and application artifacts that make up this
  2517  	// version.Only returned in GET requests if view=FULL is set.
  2518  	Deployment *Deployment `json:"deployment,omitempty"`
  2519  
  2520  	// EndpointsApiService: Cloud Endpoints configuration.If
  2521  	// endpoints_api_service is set, the Cloud Endpoints Extensible Service
  2522  	// Proxy will be provided to serve the API implemented by the app.
  2523  	EndpointsApiService *EndpointsApiService `json:"endpointsApiService,omitempty"`
  2524  
  2525  	// Env: App Engine execution environment to use for this
  2526  	// version.Defaults to 1.
  2527  	Env string `json:"env,omitempty"`
  2528  
  2529  	// EnvVariables: Environment variables made available to the
  2530  	// application.Only returned in GET requests if view=FULL is set.
  2531  	EnvVariables map[string]string `json:"envVariables,omitempty"`
  2532  
  2533  	// ErrorHandlers: Custom static error pages. Limited to 10KB per
  2534  	// page.Only returned in GET requests if view=FULL is set.
  2535  	ErrorHandlers []*ErrorHandler `json:"errorHandlers,omitempty"`
  2536  
  2537  	// Handlers: An ordered list of URL-matching patterns that should be
  2538  	// applied to incoming requests. The first matching URL handles the
  2539  	// request and other request handlers are not attempted.Only returned in
  2540  	// GET requests if view=FULL is set.
  2541  	Handlers []*UrlMap `json:"handlers,omitempty"`
  2542  
  2543  	// HealthCheck: Configures health checking for VM instances. Unhealthy
  2544  	// instances are stopped and replaced with new instances. Only
  2545  	// applicable for VM runtimes.Only returned in GET requests if view=FULL
  2546  	// is set.
  2547  	HealthCheck *HealthCheck `json:"healthCheck,omitempty"`
  2548  
  2549  	// Id: Relative name of the version within the module. Example: v1.
  2550  	// Version names can contain only lowercase letters, numbers, or
  2551  	// hyphens. Reserved names: "default", "latest", and any name with the
  2552  	// prefix "ah-".
  2553  	Id string `json:"id,omitempty"`
  2554  
  2555  	// InboundServices: Before an application can receive email or XMPP
  2556  	// messages, the application must be configured to enable the service.
  2557  	//
  2558  	// Possible values:
  2559  	//   "INBOUND_SERVICE_UNSPECIFIED" - Not specified.
  2560  	//   "INBOUND_SERVICE_MAIL" - Allows an application to receive mail.
  2561  	//   "INBOUND_SERVICE_MAIL_BOUNCE" - Allows an application to receive
  2562  	// email-bound notifications.
  2563  	//   "INBOUND_SERVICE_XMPP_ERROR" - Allows an application to receive
  2564  	// error stanzas.
  2565  	//   "INBOUND_SERVICE_XMPP_MESSAGE" - Allows an application to receive
  2566  	// instant messages.
  2567  	//   "INBOUND_SERVICE_XMPP_SUBSCRIBE" - Allows an application to receive
  2568  	// user subscription POSTs.
  2569  	//   "INBOUND_SERVICE_XMPP_PRESENCE" - Allows an application to receive
  2570  	// a user's chat presence.
  2571  	//   "INBOUND_SERVICE_CHANNEL_PRESENCE" - Registers an application for
  2572  	// notifications when a client connects or disconnects from a channel.
  2573  	//   "INBOUND_SERVICE_WARMUP" - Enables warmup requests.
  2574  	InboundServices []string `json:"inboundServices,omitempty"`
  2575  
  2576  	// InstanceClass: Instance class that is used to run this version. Valid
  2577  	// values are:
  2578  	// AutomaticScaling: F1, F2, F4, F4_1G
  2579  	// ManualScaling or BasicScaling: B1, B2, B4, B8, B4_1GDefaults to F1
  2580  	// for AutomaticScaling and B1 for ManualScaling or BasicScaling.
  2581  	InstanceClass string `json:"instanceClass,omitempty"`
  2582  
  2583  	// Libraries: Configuration for third-party Python runtime libraries
  2584  	// required by the application.Only returned in GET requests if
  2585  	// view=FULL is set.
  2586  	Libraries []*Library `json:"libraries,omitempty"`
  2587  
  2588  	// ManualScaling: A module with manual scaling runs continuously,
  2589  	// allowing you to perform complex initialization and rely on the state
  2590  	// of its memory over time.
  2591  	ManualScaling *ManualScaling `json:"manualScaling,omitempty"`
  2592  
  2593  	// Name: Full path to the Version resource in the API. Example:
  2594  	// apps/myapp/modules/default/versions/v1.@OutputOnly
  2595  	Name string `json:"name,omitempty"`
  2596  
  2597  	// Network: Extra network settings. Only applicable for VM runtimes.
  2598  	Network *Network `json:"network,omitempty"`
  2599  
  2600  	// NobuildFilesRegex: Files that match this pattern will not be built
  2601  	// into this version. Only applicable for Go runtimes.Only returned in
  2602  	// GET requests if view=FULL is set.
  2603  	NobuildFilesRegex string `json:"nobuildFilesRegex,omitempty"`
  2604  
  2605  	// Resources: Machine resources for this version. Only applicable for VM
  2606  	// runtimes.
  2607  	Resources *Resources `json:"resources,omitempty"`
  2608  
  2609  	// Runtime: Desired runtime. Example: python27.
  2610  	Runtime string `json:"runtime,omitempty"`
  2611  
  2612  	// RuntimeApiVersion: The version of the API in the given runtime
  2613  	// environment. Please see the app.yaml reference for valid values at
  2614  	// https://cloud.google.com/appengine/docs/standard/<language>/config/appref
  2615  	RuntimeApiVersion string `json:"runtimeApiVersion,omitempty"`
  2616  
  2617  	// RuntimeMainExecutablePath: The path or name of the app's main
  2618  	// executable.
  2619  	RuntimeMainExecutablePath string `json:"runtimeMainExecutablePath,omitempty"`
  2620  
  2621  	// ServingStatus: Current serving status of this version. Only the
  2622  	// versions with a SERVING status create instances and can be
  2623  	// billed.SERVING_STATUS_UNSPECIFIED is an invalid value. Defaults to
  2624  	// SERVING.
  2625  	//
  2626  	// Possible values:
  2627  	//   "SERVING_STATUS_UNSPECIFIED" - Not specified.
  2628  	//   "SERVING" - Currently serving. Instances are created according to
  2629  	// the scaling settings of the version.
  2630  	//   "STOPPED" - Disabled. No instances will be created and the scaling
  2631  	// settings are ignored until the state of the version changes to
  2632  	// SERVING.
  2633  	ServingStatus string `json:"servingStatus,omitempty"`
  2634  
  2635  	// Threadsafe: Whether multiple requests can be dispatched to this
  2636  	// version at once.
  2637  	Threadsafe bool `json:"threadsafe,omitempty"`
  2638  
  2639  	// Vm: Whether to deploy this version in a container on a virtual
  2640  	// machine.
  2641  	Vm bool `json:"vm,omitempty"`
  2642  
  2643  	// ServerResponse contains the HTTP response code and headers from the
  2644  	// server.
  2645  	googleapi.ServerResponse `json:"-"`
  2646  
  2647  	// ForceSendFields is a list of field names (e.g. "ApiConfig") to
  2648  	// unconditionally include in API requests. By default, fields with
  2649  	// empty values are omitted from API requests. However, any non-pointer,
  2650  	// non-interface field appearing in ForceSendFields will be sent to the
  2651  	// server regardless of whether the field is empty or not. This may be
  2652  	// used to include empty fields in Patch requests.
  2653  	ForceSendFields []string `json:"-"`
  2654  
  2655  	// NullFields is a list of field names (e.g. "ApiConfig") to include in
  2656  	// API requests with the JSON null value. By default, fields with empty
  2657  	// values are omitted from API requests. However, any field with an
  2658  	// empty value appearing in NullFields will be sent to the server as
  2659  	// null. It is an error if a field in this list has a non-empty value.
  2660  	// This may be used to include null fields in Patch requests.
  2661  	NullFields []string `json:"-"`
  2662  }
  2663  
  2664  func (s *Version) MarshalJSON() ([]byte, error) {
  2665  	type NoMethod Version
  2666  	raw := NoMethod(*s)
  2667  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  2668  }
  2669  
  2670  // Volume: Volumes mounted within the app container. Only applicable for
  2671  // VM runtimes.
  2672  type Volume struct {
  2673  	// Name: Unique name for the volume.
  2674  	Name string `json:"name,omitempty"`
  2675  
  2676  	// SizeGb: Volume size in gigabytes.
  2677  	SizeGb float64 `json:"sizeGb,omitempty"`
  2678  
  2679  	// VolumeType: Underlying volume type, e.g. 'tmpfs'.
  2680  	VolumeType string `json:"volumeType,omitempty"`
  2681  
  2682  	// ForceSendFields is a list of field names (e.g. "Name") to
  2683  	// unconditionally include in API requests. By default, fields with
  2684  	// empty values are omitted from API requests. However, any non-pointer,
  2685  	// non-interface field appearing in ForceSendFields will be sent to the
  2686  	// server regardless of whether the field is empty or not. This may be
  2687  	// used to include empty fields in Patch requests.
  2688  	ForceSendFields []string `json:"-"`
  2689  
  2690  	// NullFields is a list of field names (e.g. "Name") to include in API
  2691  	// requests with the JSON null value. By default, fields with empty
  2692  	// values are omitted from API requests. However, any field with an
  2693  	// empty value appearing in NullFields will be sent to the server as
  2694  	// null. It is an error if a field in this list has a non-empty value.
  2695  	// This may be used to include null fields in Patch requests.
  2696  	NullFields []string `json:"-"`
  2697  }
  2698  
  2699  func (s *Volume) MarshalJSON() ([]byte, error) {
  2700  	type NoMethod Volume
  2701  	raw := NoMethod(*s)
  2702  	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
  2703  }
  2704  
  2705  func (s *Volume) UnmarshalJSON(data []byte) error {
  2706  	type NoMethod Volume
  2707  	var s1 struct {
  2708  		SizeGb gensupport.JSONFloat64 `json:"sizeGb"`
  2709  		*NoMethod
  2710  	}
  2711  	s1.NoMethod = (*NoMethod)(s)
  2712  	if err := json.Unmarshal(data, &s1); err != nil {
  2713  		return err
  2714  	}
  2715  	s.SizeGb = float64(s1.SizeGb)
  2716  	return nil
  2717  }
  2718  
  2719  // method id "appengine.apps.create":
  2720  
  2721  type AppsCreateCall struct {
  2722  	s           *APIService
  2723  	application *Application
  2724  	urlParams_  gensupport.URLParams
  2725  	ctx_        context.Context
  2726  	header_     http.Header
  2727  }
  2728  
  2729  // Create: Creates an App Engine application for a Google Cloud Platform
  2730  // project. Required fields:
  2731  // id - The ID of the target Cloud Platform project.
  2732  // location - The region
  2733  // (https://cloud.google.com/appengine/docs/locations) where you want
  2734  // the App Engine application located.For more information about App
  2735  // Engine applications, see Managing Projects, Applications, and Billing
  2736  // (https://cloud.google.com/appengine/docs/python/console/).
  2737  func (r *AppsService) Create(application *Application) *AppsCreateCall {
  2738  	c := &AppsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2739  	c.application = application
  2740  	return c
  2741  }
  2742  
  2743  // Fields allows partial responses to be retrieved. See
  2744  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  2745  // for more information.
  2746  func (c *AppsCreateCall) Fields(s ...googleapi.Field) *AppsCreateCall {
  2747  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2748  	return c
  2749  }
  2750  
  2751  // Context sets the context to be used in this call's Do method. Any
  2752  // pending HTTP request will be aborted if the provided context is
  2753  // canceled.
  2754  func (c *AppsCreateCall) Context(ctx context.Context) *AppsCreateCall {
  2755  	c.ctx_ = ctx
  2756  	return c
  2757  }
  2758  
  2759  // Header returns an http.Header that can be modified by the caller to
  2760  // add HTTP headers to the request.
  2761  func (c *AppsCreateCall) Header() http.Header {
  2762  	if c.header_ == nil {
  2763  		c.header_ = make(http.Header)
  2764  	}
  2765  	return c.header_
  2766  }
  2767  
  2768  func (c *AppsCreateCall) doRequest(alt string) (*http.Response, error) {
  2769  	reqHeaders := make(http.Header)
  2770  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  2771  	for k, v := range c.header_ {
  2772  		reqHeaders[k] = v
  2773  	}
  2774  	reqHeaders.Set("User-Agent", c.s.userAgent())
  2775  	var body io.Reader = nil
  2776  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.application)
  2777  	if err != nil {
  2778  		return nil, err
  2779  	}
  2780  	reqHeaders.Set("Content-Type", "application/json")
  2781  	c.urlParams_.Set("alt", alt)
  2782  	c.urlParams_.Set("prettyPrint", "false")
  2783  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps")
  2784  	urls += "?" + c.urlParams_.Encode()
  2785  	req, err := http.NewRequest("POST", urls, body)
  2786  	if err != nil {
  2787  		return nil, err
  2788  	}
  2789  	req.Header = reqHeaders
  2790  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2791  }
  2792  
  2793  // Do executes the "appengine.apps.create" call.
  2794  // Exactly one of *Operation or error will be non-nil. Any non-2xx
  2795  // status code is an error. Response headers are in either
  2796  // *Operation.ServerResponse.Header or (if a response was returned at
  2797  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
  2798  // to check whether the returned error was because
  2799  // http.StatusNotModified was returned.
  2800  func (c *AppsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  2801  	gensupport.SetOptions(c.urlParams_, opts...)
  2802  	res, err := c.doRequest("json")
  2803  	if res != nil && res.StatusCode == http.StatusNotModified {
  2804  		if res.Body != nil {
  2805  			res.Body.Close()
  2806  		}
  2807  		return nil, &googleapi.Error{
  2808  			Code:   res.StatusCode,
  2809  			Header: res.Header,
  2810  		}
  2811  	}
  2812  	if err != nil {
  2813  		return nil, err
  2814  	}
  2815  	defer googleapi.CloseBody(res)
  2816  	if err := googleapi.CheckResponse(res); err != nil {
  2817  		return nil, err
  2818  	}
  2819  	ret := &Operation{
  2820  		ServerResponse: googleapi.ServerResponse{
  2821  			Header:         res.Header,
  2822  			HTTPStatusCode: res.StatusCode,
  2823  		},
  2824  	}
  2825  	target := &ret
  2826  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2827  		return nil, err
  2828  	}
  2829  	return ret, nil
  2830  	// {
  2831  	//   "description": "Creates an App Engine application for a Google Cloud Platform project. Required fields:\nid - The ID of the target Cloud Platform project.\nlocation - The region (https://cloud.google.com/appengine/docs/locations) where you want the App Engine application located.For more information about App Engine applications, see Managing Projects, Applications, and Billing (https://cloud.google.com/appengine/docs/python/console/).",
  2832  	//   "flatPath": "v1beta4/apps",
  2833  	//   "httpMethod": "POST",
  2834  	//   "id": "appengine.apps.create",
  2835  	//   "parameterOrder": [],
  2836  	//   "parameters": {},
  2837  	//   "path": "v1beta4/apps",
  2838  	//   "request": {
  2839  	//     "$ref": "Application"
  2840  	//   },
  2841  	//   "response": {
  2842  	//     "$ref": "Operation"
  2843  	//   },
  2844  	//   "scopes": [
  2845  	//     "https://www.googleapis.com/auth/cloud-platform"
  2846  	//   ]
  2847  	// }
  2848  
  2849  }
  2850  
  2851  // method id "appengine.apps.get":
  2852  
  2853  type AppsGetCall struct {
  2854  	s            *APIService
  2855  	appsId       string
  2856  	urlParams_   gensupport.URLParams
  2857  	ifNoneMatch_ string
  2858  	ctx_         context.Context
  2859  	header_      http.Header
  2860  }
  2861  
  2862  // Get: Gets information about an application.
  2863  func (r *AppsService) Get(appsId string) *AppsGetCall {
  2864  	c := &AppsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2865  	c.appsId = appsId
  2866  	return c
  2867  }
  2868  
  2869  // EnsureResourcesExist sets the optional parameter
  2870  // "ensureResourcesExist": Certain resources associated with an
  2871  // application are created on-demand. Controls whether these resources
  2872  // should be created when performing the GET operation. If specified and
  2873  // any resources could not be created, the request will fail with an
  2874  // error code. Additionally, this parameter can cause the request to
  2875  // take longer to complete.
  2876  func (c *AppsGetCall) EnsureResourcesExist(ensureResourcesExist bool) *AppsGetCall {
  2877  	c.urlParams_.Set("ensureResourcesExist", fmt.Sprint(ensureResourcesExist))
  2878  	return c
  2879  }
  2880  
  2881  // Fields allows partial responses to be retrieved. See
  2882  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  2883  // for more information.
  2884  func (c *AppsGetCall) Fields(s ...googleapi.Field) *AppsGetCall {
  2885  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2886  	return c
  2887  }
  2888  
  2889  // IfNoneMatch sets the optional parameter which makes the operation
  2890  // fail if the object's ETag matches the given value. This is useful for
  2891  // getting updates only after the object has changed since the last
  2892  // request. Use googleapi.IsNotModified to check whether the response
  2893  // error from Do is the result of In-None-Match.
  2894  func (c *AppsGetCall) IfNoneMatch(entityTag string) *AppsGetCall {
  2895  	c.ifNoneMatch_ = entityTag
  2896  	return c
  2897  }
  2898  
  2899  // Context sets the context to be used in this call's Do method. Any
  2900  // pending HTTP request will be aborted if the provided context is
  2901  // canceled.
  2902  func (c *AppsGetCall) Context(ctx context.Context) *AppsGetCall {
  2903  	c.ctx_ = ctx
  2904  	return c
  2905  }
  2906  
  2907  // Header returns an http.Header that can be modified by the caller to
  2908  // add HTTP headers to the request.
  2909  func (c *AppsGetCall) Header() http.Header {
  2910  	if c.header_ == nil {
  2911  		c.header_ = make(http.Header)
  2912  	}
  2913  	return c.header_
  2914  }
  2915  
  2916  func (c *AppsGetCall) doRequest(alt string) (*http.Response, error) {
  2917  	reqHeaders := make(http.Header)
  2918  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  2919  	for k, v := range c.header_ {
  2920  		reqHeaders[k] = v
  2921  	}
  2922  	reqHeaders.Set("User-Agent", c.s.userAgent())
  2923  	if c.ifNoneMatch_ != "" {
  2924  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  2925  	}
  2926  	var body io.Reader = nil
  2927  	c.urlParams_.Set("alt", alt)
  2928  	c.urlParams_.Set("prettyPrint", "false")
  2929  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}")
  2930  	urls += "?" + c.urlParams_.Encode()
  2931  	req, err := http.NewRequest("GET", urls, body)
  2932  	if err != nil {
  2933  		return nil, err
  2934  	}
  2935  	req.Header = reqHeaders
  2936  	googleapi.Expand(req.URL, map[string]string{
  2937  		"appsId": c.appsId,
  2938  	})
  2939  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2940  }
  2941  
  2942  // Do executes the "appengine.apps.get" call.
  2943  // Exactly one of *Application or error will be non-nil. Any non-2xx
  2944  // status code is an error. Response headers are in either
  2945  // *Application.ServerResponse.Header or (if a response was returned at
  2946  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
  2947  // to check whether the returned error was because
  2948  // http.StatusNotModified was returned.
  2949  func (c *AppsGetCall) Do(opts ...googleapi.CallOption) (*Application, error) {
  2950  	gensupport.SetOptions(c.urlParams_, opts...)
  2951  	res, err := c.doRequest("json")
  2952  	if res != nil && res.StatusCode == http.StatusNotModified {
  2953  		if res.Body != nil {
  2954  			res.Body.Close()
  2955  		}
  2956  		return nil, &googleapi.Error{
  2957  			Code:   res.StatusCode,
  2958  			Header: res.Header,
  2959  		}
  2960  	}
  2961  	if err != nil {
  2962  		return nil, err
  2963  	}
  2964  	defer googleapi.CloseBody(res)
  2965  	if err := googleapi.CheckResponse(res); err != nil {
  2966  		return nil, err
  2967  	}
  2968  	ret := &Application{
  2969  		ServerResponse: googleapi.ServerResponse{
  2970  			Header:         res.Header,
  2971  			HTTPStatusCode: res.StatusCode,
  2972  		},
  2973  	}
  2974  	target := &ret
  2975  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2976  		return nil, err
  2977  	}
  2978  	return ret, nil
  2979  	// {
  2980  	//   "description": "Gets information about an application.",
  2981  	//   "flatPath": "v1beta4/apps/{appsId}",
  2982  	//   "httpMethod": "GET",
  2983  	//   "id": "appengine.apps.get",
  2984  	//   "parameterOrder": [
  2985  	//     "appsId"
  2986  	//   ],
  2987  	//   "parameters": {
  2988  	//     "appsId": {
  2989  	//       "description": "Part of `name`. Name of the application to get. Example: apps/myapp.",
  2990  	//       "location": "path",
  2991  	//       "required": true,
  2992  	//       "type": "string"
  2993  	//     },
  2994  	//     "ensureResourcesExist": {
  2995  	//       "description": "Certain resources associated with an application are created on-demand. Controls whether these resources should be created when performing the GET operation. If specified and any resources could not be created, the request will fail with an error code. Additionally, this parameter can cause the request to take longer to complete.",
  2996  	//       "location": "query",
  2997  	//       "type": "boolean"
  2998  	//     }
  2999  	//   },
  3000  	//   "path": "v1beta4/apps/{appsId}",
  3001  	//   "response": {
  3002  	//     "$ref": "Application"
  3003  	//   },
  3004  	//   "scopes": [
  3005  	//     "https://www.googleapis.com/auth/cloud-platform"
  3006  	//   ]
  3007  	// }
  3008  
  3009  }
  3010  
  3011  // method id "appengine.apps.patch":
  3012  
  3013  type AppsPatchCall struct {
  3014  	s           *APIService
  3015  	appsId      string
  3016  	application *Application
  3017  	urlParams_  gensupport.URLParams
  3018  	ctx_        context.Context
  3019  	header_     http.Header
  3020  }
  3021  
  3022  // Patch: Updates the specified Application resource. You can update the
  3023  // following fields:
  3024  // auth_domain
  3025  // (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps#Application.FIELDS.auth_domain)
  3026  // default_cookie_expiration
  3027  // (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps#Application.FIELDS.default_cookie_expiration)
  3028  func (r *AppsService) Patch(appsId string, application *Application) *AppsPatchCall {
  3029  	c := &AppsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3030  	c.appsId = appsId
  3031  	c.application = application
  3032  	return c
  3033  }
  3034  
  3035  // Mask sets the optional parameter "mask": Standard field mask for the
  3036  // set of fields to be updated.
  3037  func (c *AppsPatchCall) Mask(mask string) *AppsPatchCall {
  3038  	c.urlParams_.Set("mask", mask)
  3039  	return c
  3040  }
  3041  
  3042  // Fields allows partial responses to be retrieved. See
  3043  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  3044  // for more information.
  3045  func (c *AppsPatchCall) Fields(s ...googleapi.Field) *AppsPatchCall {
  3046  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3047  	return c
  3048  }
  3049  
  3050  // Context sets the context to be used in this call's Do method. Any
  3051  // pending HTTP request will be aborted if the provided context is
  3052  // canceled.
  3053  func (c *AppsPatchCall) Context(ctx context.Context) *AppsPatchCall {
  3054  	c.ctx_ = ctx
  3055  	return c
  3056  }
  3057  
  3058  // Header returns an http.Header that can be modified by the caller to
  3059  // add HTTP headers to the request.
  3060  func (c *AppsPatchCall) Header() http.Header {
  3061  	if c.header_ == nil {
  3062  		c.header_ = make(http.Header)
  3063  	}
  3064  	return c.header_
  3065  }
  3066  
  3067  func (c *AppsPatchCall) doRequest(alt string) (*http.Response, error) {
  3068  	reqHeaders := make(http.Header)
  3069  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  3070  	for k, v := range c.header_ {
  3071  		reqHeaders[k] = v
  3072  	}
  3073  	reqHeaders.Set("User-Agent", c.s.userAgent())
  3074  	var body io.Reader = nil
  3075  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.application)
  3076  	if err != nil {
  3077  		return nil, err
  3078  	}
  3079  	reqHeaders.Set("Content-Type", "application/json")
  3080  	c.urlParams_.Set("alt", alt)
  3081  	c.urlParams_.Set("prettyPrint", "false")
  3082  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}")
  3083  	urls += "?" + c.urlParams_.Encode()
  3084  	req, err := http.NewRequest("PATCH", urls, body)
  3085  	if err != nil {
  3086  		return nil, err
  3087  	}
  3088  	req.Header = reqHeaders
  3089  	googleapi.Expand(req.URL, map[string]string{
  3090  		"appsId": c.appsId,
  3091  	})
  3092  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3093  }
  3094  
  3095  // Do executes the "appengine.apps.patch" call.
  3096  // Exactly one of *Operation or error will be non-nil. Any non-2xx
  3097  // status code is an error. Response headers are in either
  3098  // *Operation.ServerResponse.Header or (if a response was returned at
  3099  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
  3100  // to check whether the returned error was because
  3101  // http.StatusNotModified was returned.
  3102  func (c *AppsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  3103  	gensupport.SetOptions(c.urlParams_, opts...)
  3104  	res, err := c.doRequest("json")
  3105  	if res != nil && res.StatusCode == http.StatusNotModified {
  3106  		if res.Body != nil {
  3107  			res.Body.Close()
  3108  		}
  3109  		return nil, &googleapi.Error{
  3110  			Code:   res.StatusCode,
  3111  			Header: res.Header,
  3112  		}
  3113  	}
  3114  	if err != nil {
  3115  		return nil, err
  3116  	}
  3117  	defer googleapi.CloseBody(res)
  3118  	if err := googleapi.CheckResponse(res); err != nil {
  3119  		return nil, err
  3120  	}
  3121  	ret := &Operation{
  3122  		ServerResponse: googleapi.ServerResponse{
  3123  			Header:         res.Header,
  3124  			HTTPStatusCode: res.StatusCode,
  3125  		},
  3126  	}
  3127  	target := &ret
  3128  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3129  		return nil, err
  3130  	}
  3131  	return ret, nil
  3132  	// {
  3133  	//   "description": "Updates the specified Application resource. You can update the following fields:\nauth_domain (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps#Application.FIELDS.auth_domain)\ndefault_cookie_expiration (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps#Application.FIELDS.default_cookie_expiration)",
  3134  	//   "flatPath": "v1beta4/apps/{appsId}",
  3135  	//   "httpMethod": "PATCH",
  3136  	//   "id": "appengine.apps.patch",
  3137  	//   "parameterOrder": [
  3138  	//     "appsId"
  3139  	//   ],
  3140  	//   "parameters": {
  3141  	//     "appsId": {
  3142  	//       "description": "Part of `name`. Name of the Application resource to update. Example: apps/myapp.",
  3143  	//       "location": "path",
  3144  	//       "required": true,
  3145  	//       "type": "string"
  3146  	//     },
  3147  	//     "mask": {
  3148  	//       "description": "Standard field mask for the set of fields to be updated.",
  3149  	//       "format": "google-fieldmask",
  3150  	//       "location": "query",
  3151  	//       "type": "string"
  3152  	//     }
  3153  	//   },
  3154  	//   "path": "v1beta4/apps/{appsId}",
  3155  	//   "request": {
  3156  	//     "$ref": "Application"
  3157  	//   },
  3158  	//   "response": {
  3159  	//     "$ref": "Operation"
  3160  	//   },
  3161  	//   "scopes": [
  3162  	//     "https://www.googleapis.com/auth/cloud-platform"
  3163  	//   ]
  3164  	// }
  3165  
  3166  }
  3167  
  3168  // method id "appengine.apps.locations.get":
  3169  
  3170  type AppsLocationsGetCall struct {
  3171  	s            *APIService
  3172  	appsId       string
  3173  	locationsId  string
  3174  	urlParams_   gensupport.URLParams
  3175  	ifNoneMatch_ string
  3176  	ctx_         context.Context
  3177  	header_      http.Header
  3178  }
  3179  
  3180  // Get: Gets information about a location.
  3181  func (r *AppsLocationsService) Get(appsId string, locationsId string) *AppsLocationsGetCall {
  3182  	c := &AppsLocationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3183  	c.appsId = appsId
  3184  	c.locationsId = locationsId
  3185  	return c
  3186  }
  3187  
  3188  // Fields allows partial responses to be retrieved. See
  3189  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  3190  // for more information.
  3191  func (c *AppsLocationsGetCall) Fields(s ...googleapi.Field) *AppsLocationsGetCall {
  3192  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3193  	return c
  3194  }
  3195  
  3196  // IfNoneMatch sets the optional parameter which makes the operation
  3197  // fail if the object's ETag matches the given value. This is useful for
  3198  // getting updates only after the object has changed since the last
  3199  // request. Use googleapi.IsNotModified to check whether the response
  3200  // error from Do is the result of In-None-Match.
  3201  func (c *AppsLocationsGetCall) IfNoneMatch(entityTag string) *AppsLocationsGetCall {
  3202  	c.ifNoneMatch_ = entityTag
  3203  	return c
  3204  }
  3205  
  3206  // Context sets the context to be used in this call's Do method. Any
  3207  // pending HTTP request will be aborted if the provided context is
  3208  // canceled.
  3209  func (c *AppsLocationsGetCall) Context(ctx context.Context) *AppsLocationsGetCall {
  3210  	c.ctx_ = ctx
  3211  	return c
  3212  }
  3213  
  3214  // Header returns an http.Header that can be modified by the caller to
  3215  // add HTTP headers to the request.
  3216  func (c *AppsLocationsGetCall) Header() http.Header {
  3217  	if c.header_ == nil {
  3218  		c.header_ = make(http.Header)
  3219  	}
  3220  	return c.header_
  3221  }
  3222  
  3223  func (c *AppsLocationsGetCall) doRequest(alt string) (*http.Response, error) {
  3224  	reqHeaders := make(http.Header)
  3225  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  3226  	for k, v := range c.header_ {
  3227  		reqHeaders[k] = v
  3228  	}
  3229  	reqHeaders.Set("User-Agent", c.s.userAgent())
  3230  	if c.ifNoneMatch_ != "" {
  3231  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3232  	}
  3233  	var body io.Reader = nil
  3234  	c.urlParams_.Set("alt", alt)
  3235  	c.urlParams_.Set("prettyPrint", "false")
  3236  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}/locations/{locationsId}")
  3237  	urls += "?" + c.urlParams_.Encode()
  3238  	req, err := http.NewRequest("GET", urls, body)
  3239  	if err != nil {
  3240  		return nil, err
  3241  	}
  3242  	req.Header = reqHeaders
  3243  	googleapi.Expand(req.URL, map[string]string{
  3244  		"appsId":      c.appsId,
  3245  		"locationsId": c.locationsId,
  3246  	})
  3247  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3248  }
  3249  
  3250  // Do executes the "appengine.apps.locations.get" call.
  3251  // Exactly one of *Location or error will be non-nil. Any non-2xx status
  3252  // code is an error. Response headers are in either
  3253  // *Location.ServerResponse.Header or (if a response was returned at
  3254  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
  3255  // to check whether the returned error was because
  3256  // http.StatusNotModified was returned.
  3257  func (c *AppsLocationsGetCall) Do(opts ...googleapi.CallOption) (*Location, error) {
  3258  	gensupport.SetOptions(c.urlParams_, opts...)
  3259  	res, err := c.doRequest("json")
  3260  	if res != nil && res.StatusCode == http.StatusNotModified {
  3261  		if res.Body != nil {
  3262  			res.Body.Close()
  3263  		}
  3264  		return nil, &googleapi.Error{
  3265  			Code:   res.StatusCode,
  3266  			Header: res.Header,
  3267  		}
  3268  	}
  3269  	if err != nil {
  3270  		return nil, err
  3271  	}
  3272  	defer googleapi.CloseBody(res)
  3273  	if err := googleapi.CheckResponse(res); err != nil {
  3274  		return nil, err
  3275  	}
  3276  	ret := &Location{
  3277  		ServerResponse: googleapi.ServerResponse{
  3278  			Header:         res.Header,
  3279  			HTTPStatusCode: res.StatusCode,
  3280  		},
  3281  	}
  3282  	target := &ret
  3283  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3284  		return nil, err
  3285  	}
  3286  	return ret, nil
  3287  	// {
  3288  	//   "description": "Gets information about a location.",
  3289  	//   "flatPath": "v1beta4/apps/{appsId}/locations/{locationsId}",
  3290  	//   "httpMethod": "GET",
  3291  	//   "id": "appengine.apps.locations.get",
  3292  	//   "parameterOrder": [
  3293  	//     "appsId",
  3294  	//     "locationsId"
  3295  	//   ],
  3296  	//   "parameters": {
  3297  	//     "appsId": {
  3298  	//       "description": "Part of `name`. Resource name for the location.",
  3299  	//       "location": "path",
  3300  	//       "required": true,
  3301  	//       "type": "string"
  3302  	//     },
  3303  	//     "locationsId": {
  3304  	//       "description": "Part of `name`. See documentation of `appsId`.",
  3305  	//       "location": "path",
  3306  	//       "required": true,
  3307  	//       "type": "string"
  3308  	//     }
  3309  	//   },
  3310  	//   "path": "v1beta4/apps/{appsId}/locations/{locationsId}",
  3311  	//   "response": {
  3312  	//     "$ref": "Location"
  3313  	//   },
  3314  	//   "scopes": [
  3315  	//     "https://www.googleapis.com/auth/appengine.admin",
  3316  	//     "https://www.googleapis.com/auth/cloud-platform",
  3317  	//     "https://www.googleapis.com/auth/cloud-platform.read-only"
  3318  	//   ]
  3319  	// }
  3320  
  3321  }
  3322  
  3323  // method id "appengine.apps.locations.list":
  3324  
  3325  type AppsLocationsListCall struct {
  3326  	s            *APIService
  3327  	appsId       string
  3328  	urlParams_   gensupport.URLParams
  3329  	ifNoneMatch_ string
  3330  	ctx_         context.Context
  3331  	header_      http.Header
  3332  }
  3333  
  3334  // List: Lists information about the supported locations for this
  3335  // service.
  3336  func (r *AppsLocationsService) List(appsId string) *AppsLocationsListCall {
  3337  	c := &AppsLocationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3338  	c.appsId = appsId
  3339  	return c
  3340  }
  3341  
  3342  // Filter sets the optional parameter "filter": The standard list
  3343  // filter.
  3344  func (c *AppsLocationsListCall) Filter(filter string) *AppsLocationsListCall {
  3345  	c.urlParams_.Set("filter", filter)
  3346  	return c
  3347  }
  3348  
  3349  // PageSize sets the optional parameter "pageSize": The standard list
  3350  // page size.
  3351  func (c *AppsLocationsListCall) PageSize(pageSize int64) *AppsLocationsListCall {
  3352  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  3353  	return c
  3354  }
  3355  
  3356  // PageToken sets the optional parameter "pageToken": The standard list
  3357  // page token.
  3358  func (c *AppsLocationsListCall) PageToken(pageToken string) *AppsLocationsListCall {
  3359  	c.urlParams_.Set("pageToken", pageToken)
  3360  	return c
  3361  }
  3362  
  3363  // Fields allows partial responses to be retrieved. See
  3364  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  3365  // for more information.
  3366  func (c *AppsLocationsListCall) Fields(s ...googleapi.Field) *AppsLocationsListCall {
  3367  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3368  	return c
  3369  }
  3370  
  3371  // IfNoneMatch sets the optional parameter which makes the operation
  3372  // fail if the object's ETag matches the given value. This is useful for
  3373  // getting updates only after the object has changed since the last
  3374  // request. Use googleapi.IsNotModified to check whether the response
  3375  // error from Do is the result of In-None-Match.
  3376  func (c *AppsLocationsListCall) IfNoneMatch(entityTag string) *AppsLocationsListCall {
  3377  	c.ifNoneMatch_ = entityTag
  3378  	return c
  3379  }
  3380  
  3381  // Context sets the context to be used in this call's Do method. Any
  3382  // pending HTTP request will be aborted if the provided context is
  3383  // canceled.
  3384  func (c *AppsLocationsListCall) Context(ctx context.Context) *AppsLocationsListCall {
  3385  	c.ctx_ = ctx
  3386  	return c
  3387  }
  3388  
  3389  // Header returns an http.Header that can be modified by the caller to
  3390  // add HTTP headers to the request.
  3391  func (c *AppsLocationsListCall) Header() http.Header {
  3392  	if c.header_ == nil {
  3393  		c.header_ = make(http.Header)
  3394  	}
  3395  	return c.header_
  3396  }
  3397  
  3398  func (c *AppsLocationsListCall) doRequest(alt string) (*http.Response, error) {
  3399  	reqHeaders := make(http.Header)
  3400  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  3401  	for k, v := range c.header_ {
  3402  		reqHeaders[k] = v
  3403  	}
  3404  	reqHeaders.Set("User-Agent", c.s.userAgent())
  3405  	if c.ifNoneMatch_ != "" {
  3406  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3407  	}
  3408  	var body io.Reader = nil
  3409  	c.urlParams_.Set("alt", alt)
  3410  	c.urlParams_.Set("prettyPrint", "false")
  3411  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}/locations")
  3412  	urls += "?" + c.urlParams_.Encode()
  3413  	req, err := http.NewRequest("GET", urls, body)
  3414  	if err != nil {
  3415  		return nil, err
  3416  	}
  3417  	req.Header = reqHeaders
  3418  	googleapi.Expand(req.URL, map[string]string{
  3419  		"appsId": c.appsId,
  3420  	})
  3421  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3422  }
  3423  
  3424  // Do executes the "appengine.apps.locations.list" call.
  3425  // Exactly one of *ListLocationsResponse or error will be non-nil. Any
  3426  // non-2xx status code is an error. Response headers are in either
  3427  // *ListLocationsResponse.ServerResponse.Header or (if a response was
  3428  // returned at all) in error.(*googleapi.Error).Header. Use
  3429  // googleapi.IsNotModified to check whether the returned error was
  3430  // because http.StatusNotModified was returned.
  3431  func (c *AppsLocationsListCall) Do(opts ...googleapi.CallOption) (*ListLocationsResponse, error) {
  3432  	gensupport.SetOptions(c.urlParams_, opts...)
  3433  	res, err := c.doRequest("json")
  3434  	if res != nil && res.StatusCode == http.StatusNotModified {
  3435  		if res.Body != nil {
  3436  			res.Body.Close()
  3437  		}
  3438  		return nil, &googleapi.Error{
  3439  			Code:   res.StatusCode,
  3440  			Header: res.Header,
  3441  		}
  3442  	}
  3443  	if err != nil {
  3444  		return nil, err
  3445  	}
  3446  	defer googleapi.CloseBody(res)
  3447  	if err := googleapi.CheckResponse(res); err != nil {
  3448  		return nil, err
  3449  	}
  3450  	ret := &ListLocationsResponse{
  3451  		ServerResponse: googleapi.ServerResponse{
  3452  			Header:         res.Header,
  3453  			HTTPStatusCode: res.StatusCode,
  3454  		},
  3455  	}
  3456  	target := &ret
  3457  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3458  		return nil, err
  3459  	}
  3460  	return ret, nil
  3461  	// {
  3462  	//   "description": "Lists information about the supported locations for this service.",
  3463  	//   "flatPath": "v1beta4/apps/{appsId}/locations",
  3464  	//   "httpMethod": "GET",
  3465  	//   "id": "appengine.apps.locations.list",
  3466  	//   "parameterOrder": [
  3467  	//     "appsId"
  3468  	//   ],
  3469  	//   "parameters": {
  3470  	//     "appsId": {
  3471  	//       "description": "Part of `name`. The resource that owns the locations collection, if applicable.",
  3472  	//       "location": "path",
  3473  	//       "required": true,
  3474  	//       "type": "string"
  3475  	//     },
  3476  	//     "filter": {
  3477  	//       "description": "The standard list filter.",
  3478  	//       "location": "query",
  3479  	//       "type": "string"
  3480  	//     },
  3481  	//     "pageSize": {
  3482  	//       "description": "The standard list page size.",
  3483  	//       "format": "int32",
  3484  	//       "location": "query",
  3485  	//       "type": "integer"
  3486  	//     },
  3487  	//     "pageToken": {
  3488  	//       "description": "The standard list page token.",
  3489  	//       "location": "query",
  3490  	//       "type": "string"
  3491  	//     }
  3492  	//   },
  3493  	//   "path": "v1beta4/apps/{appsId}/locations",
  3494  	//   "response": {
  3495  	//     "$ref": "ListLocationsResponse"
  3496  	//   },
  3497  	//   "scopes": [
  3498  	//     "https://www.googleapis.com/auth/appengine.admin",
  3499  	//     "https://www.googleapis.com/auth/cloud-platform",
  3500  	//     "https://www.googleapis.com/auth/cloud-platform.read-only"
  3501  	//   ]
  3502  	// }
  3503  
  3504  }
  3505  
  3506  // Pages invokes f for each page of results.
  3507  // A non-nil error returned from f will halt the iteration.
  3508  // The provided context supersedes any context provided to the Context method.
  3509  func (c *AppsLocationsListCall) Pages(ctx context.Context, f func(*ListLocationsResponse) error) error {
  3510  	c.ctx_ = ctx
  3511  	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
  3512  	for {
  3513  		x, err := c.Do()
  3514  		if err != nil {
  3515  			return err
  3516  		}
  3517  		if err := f(x); err != nil {
  3518  			return err
  3519  		}
  3520  		if x.NextPageToken == "" {
  3521  			return nil
  3522  		}
  3523  		c.PageToken(x.NextPageToken)
  3524  	}
  3525  }
  3526  
  3527  // method id "appengine.apps.modules.delete":
  3528  
  3529  type AppsModulesDeleteCall struct {
  3530  	s          *APIService
  3531  	appsId     string
  3532  	modulesId  string
  3533  	urlParams_ gensupport.URLParams
  3534  	ctx_       context.Context
  3535  	header_    http.Header
  3536  }
  3537  
  3538  // Delete: Deletes the specified module and all enclosed versions.
  3539  func (r *AppsModulesService) Delete(appsId string, modulesId string) *AppsModulesDeleteCall {
  3540  	c := &AppsModulesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3541  	c.appsId = appsId
  3542  	c.modulesId = modulesId
  3543  	return c
  3544  }
  3545  
  3546  // Fields allows partial responses to be retrieved. See
  3547  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  3548  // for more information.
  3549  func (c *AppsModulesDeleteCall) Fields(s ...googleapi.Field) *AppsModulesDeleteCall {
  3550  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3551  	return c
  3552  }
  3553  
  3554  // Context sets the context to be used in this call's Do method. Any
  3555  // pending HTTP request will be aborted if the provided context is
  3556  // canceled.
  3557  func (c *AppsModulesDeleteCall) Context(ctx context.Context) *AppsModulesDeleteCall {
  3558  	c.ctx_ = ctx
  3559  	return c
  3560  }
  3561  
  3562  // Header returns an http.Header that can be modified by the caller to
  3563  // add HTTP headers to the request.
  3564  func (c *AppsModulesDeleteCall) Header() http.Header {
  3565  	if c.header_ == nil {
  3566  		c.header_ = make(http.Header)
  3567  	}
  3568  	return c.header_
  3569  }
  3570  
  3571  func (c *AppsModulesDeleteCall) doRequest(alt string) (*http.Response, error) {
  3572  	reqHeaders := make(http.Header)
  3573  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  3574  	for k, v := range c.header_ {
  3575  		reqHeaders[k] = v
  3576  	}
  3577  	reqHeaders.Set("User-Agent", c.s.userAgent())
  3578  	var body io.Reader = nil
  3579  	c.urlParams_.Set("alt", alt)
  3580  	c.urlParams_.Set("prettyPrint", "false")
  3581  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}/modules/{modulesId}")
  3582  	urls += "?" + c.urlParams_.Encode()
  3583  	req, err := http.NewRequest("DELETE", urls, body)
  3584  	if err != nil {
  3585  		return nil, err
  3586  	}
  3587  	req.Header = reqHeaders
  3588  	googleapi.Expand(req.URL, map[string]string{
  3589  		"appsId":    c.appsId,
  3590  		"modulesId": c.modulesId,
  3591  	})
  3592  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3593  }
  3594  
  3595  // Do executes the "appengine.apps.modules.delete" call.
  3596  // Exactly one of *Operation or error will be non-nil. Any non-2xx
  3597  // status code is an error. Response headers are in either
  3598  // *Operation.ServerResponse.Header or (if a response was returned at
  3599  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
  3600  // to check whether the returned error was because
  3601  // http.StatusNotModified was returned.
  3602  func (c *AppsModulesDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  3603  	gensupport.SetOptions(c.urlParams_, opts...)
  3604  	res, err := c.doRequest("json")
  3605  	if res != nil && res.StatusCode == http.StatusNotModified {
  3606  		if res.Body != nil {
  3607  			res.Body.Close()
  3608  		}
  3609  		return nil, &googleapi.Error{
  3610  			Code:   res.StatusCode,
  3611  			Header: res.Header,
  3612  		}
  3613  	}
  3614  	if err != nil {
  3615  		return nil, err
  3616  	}
  3617  	defer googleapi.CloseBody(res)
  3618  	if err := googleapi.CheckResponse(res); err != nil {
  3619  		return nil, err
  3620  	}
  3621  	ret := &Operation{
  3622  		ServerResponse: googleapi.ServerResponse{
  3623  			Header:         res.Header,
  3624  			HTTPStatusCode: res.StatusCode,
  3625  		},
  3626  	}
  3627  	target := &ret
  3628  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3629  		return nil, err
  3630  	}
  3631  	return ret, nil
  3632  	// {
  3633  	//   "description": "Deletes the specified module and all enclosed versions.",
  3634  	//   "flatPath": "v1beta4/apps/{appsId}/modules/{modulesId}",
  3635  	//   "httpMethod": "DELETE",
  3636  	//   "id": "appengine.apps.modules.delete",
  3637  	//   "parameterOrder": [
  3638  	//     "appsId",
  3639  	//     "modulesId"
  3640  	//   ],
  3641  	//   "parameters": {
  3642  	//     "appsId": {
  3643  	//       "description": "Part of `name`. Name of the resource requested. Example: apps/myapp/modules/default.",
  3644  	//       "location": "path",
  3645  	//       "required": true,
  3646  	//       "type": "string"
  3647  	//     },
  3648  	//     "modulesId": {
  3649  	//       "description": "Part of `name`. See documentation of `appsId`.",
  3650  	//       "location": "path",
  3651  	//       "required": true,
  3652  	//       "type": "string"
  3653  	//     }
  3654  	//   },
  3655  	//   "path": "v1beta4/apps/{appsId}/modules/{modulesId}",
  3656  	//   "response": {
  3657  	//     "$ref": "Operation"
  3658  	//   },
  3659  	//   "scopes": [
  3660  	//     "https://www.googleapis.com/auth/cloud-platform"
  3661  	//   ]
  3662  	// }
  3663  
  3664  }
  3665  
  3666  // method id "appengine.apps.modules.get":
  3667  
  3668  type AppsModulesGetCall struct {
  3669  	s            *APIService
  3670  	appsId       string
  3671  	modulesId    string
  3672  	urlParams_   gensupport.URLParams
  3673  	ifNoneMatch_ string
  3674  	ctx_         context.Context
  3675  	header_      http.Header
  3676  }
  3677  
  3678  // Get: Gets the current configuration of the specified module.
  3679  func (r *AppsModulesService) Get(appsId string, modulesId string) *AppsModulesGetCall {
  3680  	c := &AppsModulesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3681  	c.appsId = appsId
  3682  	c.modulesId = modulesId
  3683  	return c
  3684  }
  3685  
  3686  // Fields allows partial responses to be retrieved. See
  3687  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  3688  // for more information.
  3689  func (c *AppsModulesGetCall) Fields(s ...googleapi.Field) *AppsModulesGetCall {
  3690  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3691  	return c
  3692  }
  3693  
  3694  // IfNoneMatch sets the optional parameter which makes the operation
  3695  // fail if the object's ETag matches the given value. This is useful for
  3696  // getting updates only after the object has changed since the last
  3697  // request. Use googleapi.IsNotModified to check whether the response
  3698  // error from Do is the result of In-None-Match.
  3699  func (c *AppsModulesGetCall) IfNoneMatch(entityTag string) *AppsModulesGetCall {
  3700  	c.ifNoneMatch_ = entityTag
  3701  	return c
  3702  }
  3703  
  3704  // Context sets the context to be used in this call's Do method. Any
  3705  // pending HTTP request will be aborted if the provided context is
  3706  // canceled.
  3707  func (c *AppsModulesGetCall) Context(ctx context.Context) *AppsModulesGetCall {
  3708  	c.ctx_ = ctx
  3709  	return c
  3710  }
  3711  
  3712  // Header returns an http.Header that can be modified by the caller to
  3713  // add HTTP headers to the request.
  3714  func (c *AppsModulesGetCall) Header() http.Header {
  3715  	if c.header_ == nil {
  3716  		c.header_ = make(http.Header)
  3717  	}
  3718  	return c.header_
  3719  }
  3720  
  3721  func (c *AppsModulesGetCall) doRequest(alt string) (*http.Response, error) {
  3722  	reqHeaders := make(http.Header)
  3723  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  3724  	for k, v := range c.header_ {
  3725  		reqHeaders[k] = v
  3726  	}
  3727  	reqHeaders.Set("User-Agent", c.s.userAgent())
  3728  	if c.ifNoneMatch_ != "" {
  3729  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3730  	}
  3731  	var body io.Reader = nil
  3732  	c.urlParams_.Set("alt", alt)
  3733  	c.urlParams_.Set("prettyPrint", "false")
  3734  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}/modules/{modulesId}")
  3735  	urls += "?" + c.urlParams_.Encode()
  3736  	req, err := http.NewRequest("GET", urls, body)
  3737  	if err != nil {
  3738  		return nil, err
  3739  	}
  3740  	req.Header = reqHeaders
  3741  	googleapi.Expand(req.URL, map[string]string{
  3742  		"appsId":    c.appsId,
  3743  		"modulesId": c.modulesId,
  3744  	})
  3745  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3746  }
  3747  
  3748  // Do executes the "appengine.apps.modules.get" call.
  3749  // Exactly one of *Module or error will be non-nil. Any non-2xx status
  3750  // code is an error. Response headers are in either
  3751  // *Module.ServerResponse.Header or (if a response was returned at all)
  3752  // in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  3753  // check whether the returned error was because http.StatusNotModified
  3754  // was returned.
  3755  func (c *AppsModulesGetCall) Do(opts ...googleapi.CallOption) (*Module, error) {
  3756  	gensupport.SetOptions(c.urlParams_, opts...)
  3757  	res, err := c.doRequest("json")
  3758  	if res != nil && res.StatusCode == http.StatusNotModified {
  3759  		if res.Body != nil {
  3760  			res.Body.Close()
  3761  		}
  3762  		return nil, &googleapi.Error{
  3763  			Code:   res.StatusCode,
  3764  			Header: res.Header,
  3765  		}
  3766  	}
  3767  	if err != nil {
  3768  		return nil, err
  3769  	}
  3770  	defer googleapi.CloseBody(res)
  3771  	if err := googleapi.CheckResponse(res); err != nil {
  3772  		return nil, err
  3773  	}
  3774  	ret := &Module{
  3775  		ServerResponse: googleapi.ServerResponse{
  3776  			Header:         res.Header,
  3777  			HTTPStatusCode: res.StatusCode,
  3778  		},
  3779  	}
  3780  	target := &ret
  3781  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3782  		return nil, err
  3783  	}
  3784  	return ret, nil
  3785  	// {
  3786  	//   "description": "Gets the current configuration of the specified module.",
  3787  	//   "flatPath": "v1beta4/apps/{appsId}/modules/{modulesId}",
  3788  	//   "httpMethod": "GET",
  3789  	//   "id": "appengine.apps.modules.get",
  3790  	//   "parameterOrder": [
  3791  	//     "appsId",
  3792  	//     "modulesId"
  3793  	//   ],
  3794  	//   "parameters": {
  3795  	//     "appsId": {
  3796  	//       "description": "Part of `name`. Name of the resource requested. Example: apps/myapp/modules/default.",
  3797  	//       "location": "path",
  3798  	//       "required": true,
  3799  	//       "type": "string"
  3800  	//     },
  3801  	//     "modulesId": {
  3802  	//       "description": "Part of `name`. See documentation of `appsId`.",
  3803  	//       "location": "path",
  3804  	//       "required": true,
  3805  	//       "type": "string"
  3806  	//     }
  3807  	//   },
  3808  	//   "path": "v1beta4/apps/{appsId}/modules/{modulesId}",
  3809  	//   "response": {
  3810  	//     "$ref": "Module"
  3811  	//   },
  3812  	//   "scopes": [
  3813  	//     "https://www.googleapis.com/auth/appengine.admin",
  3814  	//     "https://www.googleapis.com/auth/cloud-platform",
  3815  	//     "https://www.googleapis.com/auth/cloud-platform.read-only"
  3816  	//   ]
  3817  	// }
  3818  
  3819  }
  3820  
  3821  // method id "appengine.apps.modules.list":
  3822  
  3823  type AppsModulesListCall struct {
  3824  	s            *APIService
  3825  	appsId       string
  3826  	urlParams_   gensupport.URLParams
  3827  	ifNoneMatch_ string
  3828  	ctx_         context.Context
  3829  	header_      http.Header
  3830  }
  3831  
  3832  // List: Lists all the modules in the application.
  3833  func (r *AppsModulesService) List(appsId string) *AppsModulesListCall {
  3834  	c := &AppsModulesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3835  	c.appsId = appsId
  3836  	return c
  3837  }
  3838  
  3839  // PageSize sets the optional parameter "pageSize": Maximum results to
  3840  // return per page.
  3841  func (c *AppsModulesListCall) PageSize(pageSize int64) *AppsModulesListCall {
  3842  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  3843  	return c
  3844  }
  3845  
  3846  // PageToken sets the optional parameter "pageToken": Continuation token
  3847  // for fetching the next page of results.
  3848  func (c *AppsModulesListCall) PageToken(pageToken string) *AppsModulesListCall {
  3849  	c.urlParams_.Set("pageToken", pageToken)
  3850  	return c
  3851  }
  3852  
  3853  // Fields allows partial responses to be retrieved. See
  3854  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  3855  // for more information.
  3856  func (c *AppsModulesListCall) Fields(s ...googleapi.Field) *AppsModulesListCall {
  3857  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3858  	return c
  3859  }
  3860  
  3861  // IfNoneMatch sets the optional parameter which makes the operation
  3862  // fail if the object's ETag matches the given value. This is useful for
  3863  // getting updates only after the object has changed since the last
  3864  // request. Use googleapi.IsNotModified to check whether the response
  3865  // error from Do is the result of In-None-Match.
  3866  func (c *AppsModulesListCall) IfNoneMatch(entityTag string) *AppsModulesListCall {
  3867  	c.ifNoneMatch_ = entityTag
  3868  	return c
  3869  }
  3870  
  3871  // Context sets the context to be used in this call's Do method. Any
  3872  // pending HTTP request will be aborted if the provided context is
  3873  // canceled.
  3874  func (c *AppsModulesListCall) Context(ctx context.Context) *AppsModulesListCall {
  3875  	c.ctx_ = ctx
  3876  	return c
  3877  }
  3878  
  3879  // Header returns an http.Header that can be modified by the caller to
  3880  // add HTTP headers to the request.
  3881  func (c *AppsModulesListCall) Header() http.Header {
  3882  	if c.header_ == nil {
  3883  		c.header_ = make(http.Header)
  3884  	}
  3885  	return c.header_
  3886  }
  3887  
  3888  func (c *AppsModulesListCall) doRequest(alt string) (*http.Response, error) {
  3889  	reqHeaders := make(http.Header)
  3890  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  3891  	for k, v := range c.header_ {
  3892  		reqHeaders[k] = v
  3893  	}
  3894  	reqHeaders.Set("User-Agent", c.s.userAgent())
  3895  	if c.ifNoneMatch_ != "" {
  3896  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3897  	}
  3898  	var body io.Reader = nil
  3899  	c.urlParams_.Set("alt", alt)
  3900  	c.urlParams_.Set("prettyPrint", "false")
  3901  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}/modules")
  3902  	urls += "?" + c.urlParams_.Encode()
  3903  	req, err := http.NewRequest("GET", urls, body)
  3904  	if err != nil {
  3905  		return nil, err
  3906  	}
  3907  	req.Header = reqHeaders
  3908  	googleapi.Expand(req.URL, map[string]string{
  3909  		"appsId": c.appsId,
  3910  	})
  3911  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3912  }
  3913  
  3914  // Do executes the "appengine.apps.modules.list" call.
  3915  // Exactly one of *ListModulesResponse or error will be non-nil. Any
  3916  // non-2xx status code is an error. Response headers are in either
  3917  // *ListModulesResponse.ServerResponse.Header or (if a response was
  3918  // returned at all) in error.(*googleapi.Error).Header. Use
  3919  // googleapi.IsNotModified to check whether the returned error was
  3920  // because http.StatusNotModified was returned.
  3921  func (c *AppsModulesListCall) Do(opts ...googleapi.CallOption) (*ListModulesResponse, error) {
  3922  	gensupport.SetOptions(c.urlParams_, opts...)
  3923  	res, err := c.doRequest("json")
  3924  	if res != nil && res.StatusCode == http.StatusNotModified {
  3925  		if res.Body != nil {
  3926  			res.Body.Close()
  3927  		}
  3928  		return nil, &googleapi.Error{
  3929  			Code:   res.StatusCode,
  3930  			Header: res.Header,
  3931  		}
  3932  	}
  3933  	if err != nil {
  3934  		return nil, err
  3935  	}
  3936  	defer googleapi.CloseBody(res)
  3937  	if err := googleapi.CheckResponse(res); err != nil {
  3938  		return nil, err
  3939  	}
  3940  	ret := &ListModulesResponse{
  3941  		ServerResponse: googleapi.ServerResponse{
  3942  			Header:         res.Header,
  3943  			HTTPStatusCode: res.StatusCode,
  3944  		},
  3945  	}
  3946  	target := &ret
  3947  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3948  		return nil, err
  3949  	}
  3950  	return ret, nil
  3951  	// {
  3952  	//   "description": "Lists all the modules in the application.",
  3953  	//   "flatPath": "v1beta4/apps/{appsId}/modules",
  3954  	//   "httpMethod": "GET",
  3955  	//   "id": "appengine.apps.modules.list",
  3956  	//   "parameterOrder": [
  3957  	//     "appsId"
  3958  	//   ],
  3959  	//   "parameters": {
  3960  	//     "appsId": {
  3961  	//       "description": "Part of `name`. Name of the resource requested. Example: apps/myapp.",
  3962  	//       "location": "path",
  3963  	//       "required": true,
  3964  	//       "type": "string"
  3965  	//     },
  3966  	//     "pageSize": {
  3967  	//       "description": "Maximum results to return per page.",
  3968  	//       "format": "int32",
  3969  	//       "location": "query",
  3970  	//       "type": "integer"
  3971  	//     },
  3972  	//     "pageToken": {
  3973  	//       "description": "Continuation token for fetching the next page of results.",
  3974  	//       "location": "query",
  3975  	//       "type": "string"
  3976  	//     }
  3977  	//   },
  3978  	//   "path": "v1beta4/apps/{appsId}/modules",
  3979  	//   "response": {
  3980  	//     "$ref": "ListModulesResponse"
  3981  	//   },
  3982  	//   "scopes": [
  3983  	//     "https://www.googleapis.com/auth/appengine.admin",
  3984  	//     "https://www.googleapis.com/auth/cloud-platform",
  3985  	//     "https://www.googleapis.com/auth/cloud-platform.read-only"
  3986  	//   ]
  3987  	// }
  3988  
  3989  }
  3990  
  3991  // Pages invokes f for each page of results.
  3992  // A non-nil error returned from f will halt the iteration.
  3993  // The provided context supersedes any context provided to the Context method.
  3994  func (c *AppsModulesListCall) Pages(ctx context.Context, f func(*ListModulesResponse) error) error {
  3995  	c.ctx_ = ctx
  3996  	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
  3997  	for {
  3998  		x, err := c.Do()
  3999  		if err != nil {
  4000  			return err
  4001  		}
  4002  		if err := f(x); err != nil {
  4003  			return err
  4004  		}
  4005  		if x.NextPageToken == "" {
  4006  			return nil
  4007  		}
  4008  		c.PageToken(x.NextPageToken)
  4009  	}
  4010  }
  4011  
  4012  // method id "appengine.apps.modules.patch":
  4013  
  4014  type AppsModulesPatchCall struct {
  4015  	s          *APIService
  4016  	appsId     string
  4017  	modulesId  string
  4018  	module     *Module
  4019  	urlParams_ gensupport.URLParams
  4020  	ctx_       context.Context
  4021  	header_    http.Header
  4022  }
  4023  
  4024  // Patch: Updates the configuration of the specified module.
  4025  func (r *AppsModulesService) Patch(appsId string, modulesId string, module *Module) *AppsModulesPatchCall {
  4026  	c := &AppsModulesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4027  	c.appsId = appsId
  4028  	c.modulesId = modulesId
  4029  	c.module = module
  4030  	return c
  4031  }
  4032  
  4033  // Mask sets the optional parameter "mask": Standard field mask for the
  4034  // set of fields to be updated.
  4035  func (c *AppsModulesPatchCall) Mask(mask string) *AppsModulesPatchCall {
  4036  	c.urlParams_.Set("mask", mask)
  4037  	return c
  4038  }
  4039  
  4040  // MigrateTraffic sets the optional parameter "migrateTraffic": Set to
  4041  // true to gradually shift traffic to one or more versions that you
  4042  // specify. By default, traffic is shifted immediately. For gradual
  4043  // traffic migration, the target versions must be located within
  4044  // instances that are configured for both warmup requests
  4045  // (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps.modules.versions#inboundservicetype)
  4046  // and automatic scaling
  4047  // (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps.modules.versions#automaticscaling).
  4048  // You must specify the shardBy
  4049  // (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps.modules#shardby)
  4050  // field in the Module resource. Gradual traffic migration is not
  4051  // supported in the App Engine flexible environment. For examples, see
  4052  // Migrating and Splitting Traffic
  4053  // (https://cloud.google.com/appengine/docs/admin-api/migrating-splitting-traffic).
  4054  func (c *AppsModulesPatchCall) MigrateTraffic(migrateTraffic bool) *AppsModulesPatchCall {
  4055  	c.urlParams_.Set("migrateTraffic", fmt.Sprint(migrateTraffic))
  4056  	return c
  4057  }
  4058  
  4059  // Fields allows partial responses to be retrieved. See
  4060  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  4061  // for more information.
  4062  func (c *AppsModulesPatchCall) Fields(s ...googleapi.Field) *AppsModulesPatchCall {
  4063  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4064  	return c
  4065  }
  4066  
  4067  // Context sets the context to be used in this call's Do method. Any
  4068  // pending HTTP request will be aborted if the provided context is
  4069  // canceled.
  4070  func (c *AppsModulesPatchCall) Context(ctx context.Context) *AppsModulesPatchCall {
  4071  	c.ctx_ = ctx
  4072  	return c
  4073  }
  4074  
  4075  // Header returns an http.Header that can be modified by the caller to
  4076  // add HTTP headers to the request.
  4077  func (c *AppsModulesPatchCall) Header() http.Header {
  4078  	if c.header_ == nil {
  4079  		c.header_ = make(http.Header)
  4080  	}
  4081  	return c.header_
  4082  }
  4083  
  4084  func (c *AppsModulesPatchCall) doRequest(alt string) (*http.Response, error) {
  4085  	reqHeaders := make(http.Header)
  4086  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  4087  	for k, v := range c.header_ {
  4088  		reqHeaders[k] = v
  4089  	}
  4090  	reqHeaders.Set("User-Agent", c.s.userAgent())
  4091  	var body io.Reader = nil
  4092  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.module)
  4093  	if err != nil {
  4094  		return nil, err
  4095  	}
  4096  	reqHeaders.Set("Content-Type", "application/json")
  4097  	c.urlParams_.Set("alt", alt)
  4098  	c.urlParams_.Set("prettyPrint", "false")
  4099  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}/modules/{modulesId}")
  4100  	urls += "?" + c.urlParams_.Encode()
  4101  	req, err := http.NewRequest("PATCH", urls, body)
  4102  	if err != nil {
  4103  		return nil, err
  4104  	}
  4105  	req.Header = reqHeaders
  4106  	googleapi.Expand(req.URL, map[string]string{
  4107  		"appsId":    c.appsId,
  4108  		"modulesId": c.modulesId,
  4109  	})
  4110  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4111  }
  4112  
  4113  // Do executes the "appengine.apps.modules.patch" call.
  4114  // Exactly one of *Operation or error will be non-nil. Any non-2xx
  4115  // status code is an error. Response headers are in either
  4116  // *Operation.ServerResponse.Header or (if a response was returned at
  4117  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
  4118  // to check whether the returned error was because
  4119  // http.StatusNotModified was returned.
  4120  func (c *AppsModulesPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  4121  	gensupport.SetOptions(c.urlParams_, opts...)
  4122  	res, err := c.doRequest("json")
  4123  	if res != nil && res.StatusCode == http.StatusNotModified {
  4124  		if res.Body != nil {
  4125  			res.Body.Close()
  4126  		}
  4127  		return nil, &googleapi.Error{
  4128  			Code:   res.StatusCode,
  4129  			Header: res.Header,
  4130  		}
  4131  	}
  4132  	if err != nil {
  4133  		return nil, err
  4134  	}
  4135  	defer googleapi.CloseBody(res)
  4136  	if err := googleapi.CheckResponse(res); err != nil {
  4137  		return nil, err
  4138  	}
  4139  	ret := &Operation{
  4140  		ServerResponse: googleapi.ServerResponse{
  4141  			Header:         res.Header,
  4142  			HTTPStatusCode: res.StatusCode,
  4143  		},
  4144  	}
  4145  	target := &ret
  4146  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4147  		return nil, err
  4148  	}
  4149  	return ret, nil
  4150  	// {
  4151  	//   "description": "Updates the configuration of the specified module.",
  4152  	//   "flatPath": "v1beta4/apps/{appsId}/modules/{modulesId}",
  4153  	//   "httpMethod": "PATCH",
  4154  	//   "id": "appengine.apps.modules.patch",
  4155  	//   "parameterOrder": [
  4156  	//     "appsId",
  4157  	//     "modulesId"
  4158  	//   ],
  4159  	//   "parameters": {
  4160  	//     "appsId": {
  4161  	//       "description": "Part of `name`. Name of the resource to update. Example: apps/myapp/modules/default.",
  4162  	//       "location": "path",
  4163  	//       "required": true,
  4164  	//       "type": "string"
  4165  	//     },
  4166  	//     "mask": {
  4167  	//       "description": "Standard field mask for the set of fields to be updated.",
  4168  	//       "format": "google-fieldmask",
  4169  	//       "location": "query",
  4170  	//       "type": "string"
  4171  	//     },
  4172  	//     "migrateTraffic": {
  4173  	//       "description": "Set to true to gradually shift traffic to one or more versions that you specify. By default, traffic is shifted immediately. For gradual traffic migration, the target versions must be located within instances that are configured for both warmup requests (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps.modules.versions#inboundservicetype) and automatic scaling (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps.modules.versions#automaticscaling). You must specify the shardBy (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps.modules#shardby) field in the Module resource. Gradual traffic migration is not supported in the App Engine flexible environment. For examples, see Migrating and Splitting Traffic (https://cloud.google.com/appengine/docs/admin-api/migrating-splitting-traffic).",
  4174  	//       "location": "query",
  4175  	//       "type": "boolean"
  4176  	//     },
  4177  	//     "modulesId": {
  4178  	//       "description": "Part of `name`. See documentation of `appsId`.",
  4179  	//       "location": "path",
  4180  	//       "required": true,
  4181  	//       "type": "string"
  4182  	//     }
  4183  	//   },
  4184  	//   "path": "v1beta4/apps/{appsId}/modules/{modulesId}",
  4185  	//   "request": {
  4186  	//     "$ref": "Module"
  4187  	//   },
  4188  	//   "response": {
  4189  	//     "$ref": "Operation"
  4190  	//   },
  4191  	//   "scopes": [
  4192  	//     "https://www.googleapis.com/auth/cloud-platform"
  4193  	//   ]
  4194  	// }
  4195  
  4196  }
  4197  
  4198  // method id "appengine.apps.modules.versions.create":
  4199  
  4200  type AppsModulesVersionsCreateCall struct {
  4201  	s          *APIService
  4202  	appsId     string
  4203  	modulesId  string
  4204  	version    *Version
  4205  	urlParams_ gensupport.URLParams
  4206  	ctx_       context.Context
  4207  	header_    http.Header
  4208  }
  4209  
  4210  // Create: Deploys code and resource files to a new version.
  4211  func (r *AppsModulesVersionsService) Create(appsId string, modulesId string, version *Version) *AppsModulesVersionsCreateCall {
  4212  	c := &AppsModulesVersionsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4213  	c.appsId = appsId
  4214  	c.modulesId = modulesId
  4215  	c.version = version
  4216  	return c
  4217  }
  4218  
  4219  // Fields allows partial responses to be retrieved. See
  4220  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  4221  // for more information.
  4222  func (c *AppsModulesVersionsCreateCall) Fields(s ...googleapi.Field) *AppsModulesVersionsCreateCall {
  4223  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4224  	return c
  4225  }
  4226  
  4227  // Context sets the context to be used in this call's Do method. Any
  4228  // pending HTTP request will be aborted if the provided context is
  4229  // canceled.
  4230  func (c *AppsModulesVersionsCreateCall) Context(ctx context.Context) *AppsModulesVersionsCreateCall {
  4231  	c.ctx_ = ctx
  4232  	return c
  4233  }
  4234  
  4235  // Header returns an http.Header that can be modified by the caller to
  4236  // add HTTP headers to the request.
  4237  func (c *AppsModulesVersionsCreateCall) Header() http.Header {
  4238  	if c.header_ == nil {
  4239  		c.header_ = make(http.Header)
  4240  	}
  4241  	return c.header_
  4242  }
  4243  
  4244  func (c *AppsModulesVersionsCreateCall) doRequest(alt string) (*http.Response, error) {
  4245  	reqHeaders := make(http.Header)
  4246  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  4247  	for k, v := range c.header_ {
  4248  		reqHeaders[k] = v
  4249  	}
  4250  	reqHeaders.Set("User-Agent", c.s.userAgent())
  4251  	var body io.Reader = nil
  4252  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.version)
  4253  	if err != nil {
  4254  		return nil, err
  4255  	}
  4256  	reqHeaders.Set("Content-Type", "application/json")
  4257  	c.urlParams_.Set("alt", alt)
  4258  	c.urlParams_.Set("prettyPrint", "false")
  4259  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}/modules/{modulesId}/versions")
  4260  	urls += "?" + c.urlParams_.Encode()
  4261  	req, err := http.NewRequest("POST", urls, body)
  4262  	if err != nil {
  4263  		return nil, err
  4264  	}
  4265  	req.Header = reqHeaders
  4266  	googleapi.Expand(req.URL, map[string]string{
  4267  		"appsId":    c.appsId,
  4268  		"modulesId": c.modulesId,
  4269  	})
  4270  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4271  }
  4272  
  4273  // Do executes the "appengine.apps.modules.versions.create" call.
  4274  // Exactly one of *Operation or error will be non-nil. Any non-2xx
  4275  // status code is an error. Response headers are in either
  4276  // *Operation.ServerResponse.Header or (if a response was returned at
  4277  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
  4278  // to check whether the returned error was because
  4279  // http.StatusNotModified was returned.
  4280  func (c *AppsModulesVersionsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  4281  	gensupport.SetOptions(c.urlParams_, opts...)
  4282  	res, err := c.doRequest("json")
  4283  	if res != nil && res.StatusCode == http.StatusNotModified {
  4284  		if res.Body != nil {
  4285  			res.Body.Close()
  4286  		}
  4287  		return nil, &googleapi.Error{
  4288  			Code:   res.StatusCode,
  4289  			Header: res.Header,
  4290  		}
  4291  	}
  4292  	if err != nil {
  4293  		return nil, err
  4294  	}
  4295  	defer googleapi.CloseBody(res)
  4296  	if err := googleapi.CheckResponse(res); err != nil {
  4297  		return nil, err
  4298  	}
  4299  	ret := &Operation{
  4300  		ServerResponse: googleapi.ServerResponse{
  4301  			Header:         res.Header,
  4302  			HTTPStatusCode: res.StatusCode,
  4303  		},
  4304  	}
  4305  	target := &ret
  4306  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4307  		return nil, err
  4308  	}
  4309  	return ret, nil
  4310  	// {
  4311  	//   "description": "Deploys code and resource files to a new version.",
  4312  	//   "flatPath": "v1beta4/apps/{appsId}/modules/{modulesId}/versions",
  4313  	//   "httpMethod": "POST",
  4314  	//   "id": "appengine.apps.modules.versions.create",
  4315  	//   "parameterOrder": [
  4316  	//     "appsId",
  4317  	//     "modulesId"
  4318  	//   ],
  4319  	//   "parameters": {
  4320  	//     "appsId": {
  4321  	//       "description": "Part of `name`. Name of the resource to update. Example: apps/myapp/modules/default.",
  4322  	//       "location": "path",
  4323  	//       "required": true,
  4324  	//       "type": "string"
  4325  	//     },
  4326  	//     "modulesId": {
  4327  	//       "description": "Part of `name`. See documentation of `appsId`.",
  4328  	//       "location": "path",
  4329  	//       "required": true,
  4330  	//       "type": "string"
  4331  	//     }
  4332  	//   },
  4333  	//   "path": "v1beta4/apps/{appsId}/modules/{modulesId}/versions",
  4334  	//   "request": {
  4335  	//     "$ref": "Version"
  4336  	//   },
  4337  	//   "response": {
  4338  	//     "$ref": "Operation"
  4339  	//   },
  4340  	//   "scopes": [
  4341  	//     "https://www.googleapis.com/auth/cloud-platform"
  4342  	//   ]
  4343  	// }
  4344  
  4345  }
  4346  
  4347  // method id "appengine.apps.modules.versions.delete":
  4348  
  4349  type AppsModulesVersionsDeleteCall struct {
  4350  	s          *APIService
  4351  	appsId     string
  4352  	modulesId  string
  4353  	versionsId string
  4354  	urlParams_ gensupport.URLParams
  4355  	ctx_       context.Context
  4356  	header_    http.Header
  4357  }
  4358  
  4359  // Delete: Deletes an existing version.
  4360  func (r *AppsModulesVersionsService) Delete(appsId string, modulesId string, versionsId string) *AppsModulesVersionsDeleteCall {
  4361  	c := &AppsModulesVersionsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4362  	c.appsId = appsId
  4363  	c.modulesId = modulesId
  4364  	c.versionsId = versionsId
  4365  	return c
  4366  }
  4367  
  4368  // Fields allows partial responses to be retrieved. See
  4369  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  4370  // for more information.
  4371  func (c *AppsModulesVersionsDeleteCall) Fields(s ...googleapi.Field) *AppsModulesVersionsDeleteCall {
  4372  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4373  	return c
  4374  }
  4375  
  4376  // Context sets the context to be used in this call's Do method. Any
  4377  // pending HTTP request will be aborted if the provided context is
  4378  // canceled.
  4379  func (c *AppsModulesVersionsDeleteCall) Context(ctx context.Context) *AppsModulesVersionsDeleteCall {
  4380  	c.ctx_ = ctx
  4381  	return c
  4382  }
  4383  
  4384  // Header returns an http.Header that can be modified by the caller to
  4385  // add HTTP headers to the request.
  4386  func (c *AppsModulesVersionsDeleteCall) Header() http.Header {
  4387  	if c.header_ == nil {
  4388  		c.header_ = make(http.Header)
  4389  	}
  4390  	return c.header_
  4391  }
  4392  
  4393  func (c *AppsModulesVersionsDeleteCall) doRequest(alt string) (*http.Response, error) {
  4394  	reqHeaders := make(http.Header)
  4395  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  4396  	for k, v := range c.header_ {
  4397  		reqHeaders[k] = v
  4398  	}
  4399  	reqHeaders.Set("User-Agent", c.s.userAgent())
  4400  	var body io.Reader = nil
  4401  	c.urlParams_.Set("alt", alt)
  4402  	c.urlParams_.Set("prettyPrint", "false")
  4403  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}")
  4404  	urls += "?" + c.urlParams_.Encode()
  4405  	req, err := http.NewRequest("DELETE", urls, body)
  4406  	if err != nil {
  4407  		return nil, err
  4408  	}
  4409  	req.Header = reqHeaders
  4410  	googleapi.Expand(req.URL, map[string]string{
  4411  		"appsId":     c.appsId,
  4412  		"modulesId":  c.modulesId,
  4413  		"versionsId": c.versionsId,
  4414  	})
  4415  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4416  }
  4417  
  4418  // Do executes the "appengine.apps.modules.versions.delete" call.
  4419  // Exactly one of *Operation or error will be non-nil. Any non-2xx
  4420  // status code is an error. Response headers are in either
  4421  // *Operation.ServerResponse.Header or (if a response was returned at
  4422  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
  4423  // to check whether the returned error was because
  4424  // http.StatusNotModified was returned.
  4425  func (c *AppsModulesVersionsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  4426  	gensupport.SetOptions(c.urlParams_, opts...)
  4427  	res, err := c.doRequest("json")
  4428  	if res != nil && res.StatusCode == http.StatusNotModified {
  4429  		if res.Body != nil {
  4430  			res.Body.Close()
  4431  		}
  4432  		return nil, &googleapi.Error{
  4433  			Code:   res.StatusCode,
  4434  			Header: res.Header,
  4435  		}
  4436  	}
  4437  	if err != nil {
  4438  		return nil, err
  4439  	}
  4440  	defer googleapi.CloseBody(res)
  4441  	if err := googleapi.CheckResponse(res); err != nil {
  4442  		return nil, err
  4443  	}
  4444  	ret := &Operation{
  4445  		ServerResponse: googleapi.ServerResponse{
  4446  			Header:         res.Header,
  4447  			HTTPStatusCode: res.StatusCode,
  4448  		},
  4449  	}
  4450  	target := &ret
  4451  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4452  		return nil, err
  4453  	}
  4454  	return ret, nil
  4455  	// {
  4456  	//   "description": "Deletes an existing version.",
  4457  	//   "flatPath": "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}",
  4458  	//   "httpMethod": "DELETE",
  4459  	//   "id": "appengine.apps.modules.versions.delete",
  4460  	//   "parameterOrder": [
  4461  	//     "appsId",
  4462  	//     "modulesId",
  4463  	//     "versionsId"
  4464  	//   ],
  4465  	//   "parameters": {
  4466  	//     "appsId": {
  4467  	//       "description": "Part of `name`. Name of the resource requested. Example: apps/myapp/modules/default/versions/v1.",
  4468  	//       "location": "path",
  4469  	//       "required": true,
  4470  	//       "type": "string"
  4471  	//     },
  4472  	//     "modulesId": {
  4473  	//       "description": "Part of `name`. See documentation of `appsId`.",
  4474  	//       "location": "path",
  4475  	//       "required": true,
  4476  	//       "type": "string"
  4477  	//     },
  4478  	//     "versionsId": {
  4479  	//       "description": "Part of `name`. See documentation of `appsId`.",
  4480  	//       "location": "path",
  4481  	//       "required": true,
  4482  	//       "type": "string"
  4483  	//     }
  4484  	//   },
  4485  	//   "path": "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}",
  4486  	//   "response": {
  4487  	//     "$ref": "Operation"
  4488  	//   },
  4489  	//   "scopes": [
  4490  	//     "https://www.googleapis.com/auth/cloud-platform"
  4491  	//   ]
  4492  	// }
  4493  
  4494  }
  4495  
  4496  // method id "appengine.apps.modules.versions.get":
  4497  
  4498  type AppsModulesVersionsGetCall struct {
  4499  	s            *APIService
  4500  	appsId       string
  4501  	modulesId    string
  4502  	versionsId   string
  4503  	urlParams_   gensupport.URLParams
  4504  	ifNoneMatch_ string
  4505  	ctx_         context.Context
  4506  	header_      http.Header
  4507  }
  4508  
  4509  // Get: Gets the specified Version resource. By default, only a
  4510  // BASIC_VIEW will be returned. Specify the FULL_VIEW parameter to get
  4511  // the full resource.
  4512  func (r *AppsModulesVersionsService) Get(appsId string, modulesId string, versionsId string) *AppsModulesVersionsGetCall {
  4513  	c := &AppsModulesVersionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4514  	c.appsId = appsId
  4515  	c.modulesId = modulesId
  4516  	c.versionsId = versionsId
  4517  	return c
  4518  }
  4519  
  4520  // View sets the optional parameter "view": Controls the set of fields
  4521  // returned in the Get response.
  4522  //
  4523  // Possible values:
  4524  //
  4525  //	"BASIC"
  4526  //	"FULL"
  4527  func (c *AppsModulesVersionsGetCall) View(view string) *AppsModulesVersionsGetCall {
  4528  	c.urlParams_.Set("view", view)
  4529  	return c
  4530  }
  4531  
  4532  // Fields allows partial responses to be retrieved. See
  4533  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  4534  // for more information.
  4535  func (c *AppsModulesVersionsGetCall) Fields(s ...googleapi.Field) *AppsModulesVersionsGetCall {
  4536  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4537  	return c
  4538  }
  4539  
  4540  // IfNoneMatch sets the optional parameter which makes the operation
  4541  // fail if the object's ETag matches the given value. This is useful for
  4542  // getting updates only after the object has changed since the last
  4543  // request. Use googleapi.IsNotModified to check whether the response
  4544  // error from Do is the result of In-None-Match.
  4545  func (c *AppsModulesVersionsGetCall) IfNoneMatch(entityTag string) *AppsModulesVersionsGetCall {
  4546  	c.ifNoneMatch_ = entityTag
  4547  	return c
  4548  }
  4549  
  4550  // Context sets the context to be used in this call's Do method. Any
  4551  // pending HTTP request will be aborted if the provided context is
  4552  // canceled.
  4553  func (c *AppsModulesVersionsGetCall) Context(ctx context.Context) *AppsModulesVersionsGetCall {
  4554  	c.ctx_ = ctx
  4555  	return c
  4556  }
  4557  
  4558  // Header returns an http.Header that can be modified by the caller to
  4559  // add HTTP headers to the request.
  4560  func (c *AppsModulesVersionsGetCall) Header() http.Header {
  4561  	if c.header_ == nil {
  4562  		c.header_ = make(http.Header)
  4563  	}
  4564  	return c.header_
  4565  }
  4566  
  4567  func (c *AppsModulesVersionsGetCall) doRequest(alt string) (*http.Response, error) {
  4568  	reqHeaders := make(http.Header)
  4569  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  4570  	for k, v := range c.header_ {
  4571  		reqHeaders[k] = v
  4572  	}
  4573  	reqHeaders.Set("User-Agent", c.s.userAgent())
  4574  	if c.ifNoneMatch_ != "" {
  4575  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  4576  	}
  4577  	var body io.Reader = nil
  4578  	c.urlParams_.Set("alt", alt)
  4579  	c.urlParams_.Set("prettyPrint", "false")
  4580  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}")
  4581  	urls += "?" + c.urlParams_.Encode()
  4582  	req, err := http.NewRequest("GET", urls, body)
  4583  	if err != nil {
  4584  		return nil, err
  4585  	}
  4586  	req.Header = reqHeaders
  4587  	googleapi.Expand(req.URL, map[string]string{
  4588  		"appsId":     c.appsId,
  4589  		"modulesId":  c.modulesId,
  4590  		"versionsId": c.versionsId,
  4591  	})
  4592  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4593  }
  4594  
  4595  // Do executes the "appengine.apps.modules.versions.get" call.
  4596  // Exactly one of *Version or error will be non-nil. Any non-2xx status
  4597  // code is an error. Response headers are in either
  4598  // *Version.ServerResponse.Header or (if a response was returned at all)
  4599  // in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  4600  // check whether the returned error was because http.StatusNotModified
  4601  // was returned.
  4602  func (c *AppsModulesVersionsGetCall) Do(opts ...googleapi.CallOption) (*Version, error) {
  4603  	gensupport.SetOptions(c.urlParams_, opts...)
  4604  	res, err := c.doRequest("json")
  4605  	if res != nil && res.StatusCode == http.StatusNotModified {
  4606  		if res.Body != nil {
  4607  			res.Body.Close()
  4608  		}
  4609  		return nil, &googleapi.Error{
  4610  			Code:   res.StatusCode,
  4611  			Header: res.Header,
  4612  		}
  4613  	}
  4614  	if err != nil {
  4615  		return nil, err
  4616  	}
  4617  	defer googleapi.CloseBody(res)
  4618  	if err := googleapi.CheckResponse(res); err != nil {
  4619  		return nil, err
  4620  	}
  4621  	ret := &Version{
  4622  		ServerResponse: googleapi.ServerResponse{
  4623  			Header:         res.Header,
  4624  			HTTPStatusCode: res.StatusCode,
  4625  		},
  4626  	}
  4627  	target := &ret
  4628  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4629  		return nil, err
  4630  	}
  4631  	return ret, nil
  4632  	// {
  4633  	//   "description": "Gets the specified Version resource. By default, only a BASIC_VIEW will be returned. Specify the FULL_VIEW parameter to get the full resource.",
  4634  	//   "flatPath": "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}",
  4635  	//   "httpMethod": "GET",
  4636  	//   "id": "appengine.apps.modules.versions.get",
  4637  	//   "parameterOrder": [
  4638  	//     "appsId",
  4639  	//     "modulesId",
  4640  	//     "versionsId"
  4641  	//   ],
  4642  	//   "parameters": {
  4643  	//     "appsId": {
  4644  	//       "description": "Part of `name`. Name of the resource requested. Example: apps/myapp/modules/default/versions/v1.",
  4645  	//       "location": "path",
  4646  	//       "required": true,
  4647  	//       "type": "string"
  4648  	//     },
  4649  	//     "modulesId": {
  4650  	//       "description": "Part of `name`. See documentation of `appsId`.",
  4651  	//       "location": "path",
  4652  	//       "required": true,
  4653  	//       "type": "string"
  4654  	//     },
  4655  	//     "versionsId": {
  4656  	//       "description": "Part of `name`. See documentation of `appsId`.",
  4657  	//       "location": "path",
  4658  	//       "required": true,
  4659  	//       "type": "string"
  4660  	//     },
  4661  	//     "view": {
  4662  	//       "description": "Controls the set of fields returned in the Get response.",
  4663  	//       "enum": [
  4664  	//         "BASIC",
  4665  	//         "FULL"
  4666  	//       ],
  4667  	//       "location": "query",
  4668  	//       "type": "string"
  4669  	//     }
  4670  	//   },
  4671  	//   "path": "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}",
  4672  	//   "response": {
  4673  	//     "$ref": "Version"
  4674  	//   },
  4675  	//   "scopes": [
  4676  	//     "https://www.googleapis.com/auth/appengine.admin",
  4677  	//     "https://www.googleapis.com/auth/cloud-platform",
  4678  	//     "https://www.googleapis.com/auth/cloud-platform.read-only"
  4679  	//   ]
  4680  	// }
  4681  
  4682  }
  4683  
  4684  // method id "appengine.apps.modules.versions.list":
  4685  
  4686  type AppsModulesVersionsListCall struct {
  4687  	s            *APIService
  4688  	appsId       string
  4689  	modulesId    string
  4690  	urlParams_   gensupport.URLParams
  4691  	ifNoneMatch_ string
  4692  	ctx_         context.Context
  4693  	header_      http.Header
  4694  }
  4695  
  4696  // List: Lists the versions of a module.
  4697  func (r *AppsModulesVersionsService) List(appsId string, modulesId string) *AppsModulesVersionsListCall {
  4698  	c := &AppsModulesVersionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4699  	c.appsId = appsId
  4700  	c.modulesId = modulesId
  4701  	return c
  4702  }
  4703  
  4704  // PageSize sets the optional parameter "pageSize": Maximum results to
  4705  // return per page.
  4706  func (c *AppsModulesVersionsListCall) PageSize(pageSize int64) *AppsModulesVersionsListCall {
  4707  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  4708  	return c
  4709  }
  4710  
  4711  // PageToken sets the optional parameter "pageToken": Continuation token
  4712  // for fetching the next page of results.
  4713  func (c *AppsModulesVersionsListCall) PageToken(pageToken string) *AppsModulesVersionsListCall {
  4714  	c.urlParams_.Set("pageToken", pageToken)
  4715  	return c
  4716  }
  4717  
  4718  // View sets the optional parameter "view": Controls the set of fields
  4719  // returned in the List response.
  4720  //
  4721  // Possible values:
  4722  //
  4723  //	"BASIC"
  4724  //	"FULL"
  4725  func (c *AppsModulesVersionsListCall) View(view string) *AppsModulesVersionsListCall {
  4726  	c.urlParams_.Set("view", view)
  4727  	return c
  4728  }
  4729  
  4730  // Fields allows partial responses to be retrieved. See
  4731  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  4732  // for more information.
  4733  func (c *AppsModulesVersionsListCall) Fields(s ...googleapi.Field) *AppsModulesVersionsListCall {
  4734  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4735  	return c
  4736  }
  4737  
  4738  // IfNoneMatch sets the optional parameter which makes the operation
  4739  // fail if the object's ETag matches the given value. This is useful for
  4740  // getting updates only after the object has changed since the last
  4741  // request. Use googleapi.IsNotModified to check whether the response
  4742  // error from Do is the result of In-None-Match.
  4743  func (c *AppsModulesVersionsListCall) IfNoneMatch(entityTag string) *AppsModulesVersionsListCall {
  4744  	c.ifNoneMatch_ = entityTag
  4745  	return c
  4746  }
  4747  
  4748  // Context sets the context to be used in this call's Do method. Any
  4749  // pending HTTP request will be aborted if the provided context is
  4750  // canceled.
  4751  func (c *AppsModulesVersionsListCall) Context(ctx context.Context) *AppsModulesVersionsListCall {
  4752  	c.ctx_ = ctx
  4753  	return c
  4754  }
  4755  
  4756  // Header returns an http.Header that can be modified by the caller to
  4757  // add HTTP headers to the request.
  4758  func (c *AppsModulesVersionsListCall) Header() http.Header {
  4759  	if c.header_ == nil {
  4760  		c.header_ = make(http.Header)
  4761  	}
  4762  	return c.header_
  4763  }
  4764  
  4765  func (c *AppsModulesVersionsListCall) doRequest(alt string) (*http.Response, error) {
  4766  	reqHeaders := make(http.Header)
  4767  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  4768  	for k, v := range c.header_ {
  4769  		reqHeaders[k] = v
  4770  	}
  4771  	reqHeaders.Set("User-Agent", c.s.userAgent())
  4772  	if c.ifNoneMatch_ != "" {
  4773  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  4774  	}
  4775  	var body io.Reader = nil
  4776  	c.urlParams_.Set("alt", alt)
  4777  	c.urlParams_.Set("prettyPrint", "false")
  4778  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}/modules/{modulesId}/versions")
  4779  	urls += "?" + c.urlParams_.Encode()
  4780  	req, err := http.NewRequest("GET", urls, body)
  4781  	if err != nil {
  4782  		return nil, err
  4783  	}
  4784  	req.Header = reqHeaders
  4785  	googleapi.Expand(req.URL, map[string]string{
  4786  		"appsId":    c.appsId,
  4787  		"modulesId": c.modulesId,
  4788  	})
  4789  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4790  }
  4791  
  4792  // Do executes the "appengine.apps.modules.versions.list" call.
  4793  // Exactly one of *ListVersionsResponse or error will be non-nil. Any
  4794  // non-2xx status code is an error. Response headers are in either
  4795  // *ListVersionsResponse.ServerResponse.Header or (if a response was
  4796  // returned at all) in error.(*googleapi.Error).Header. Use
  4797  // googleapi.IsNotModified to check whether the returned error was
  4798  // because http.StatusNotModified was returned.
  4799  func (c *AppsModulesVersionsListCall) Do(opts ...googleapi.CallOption) (*ListVersionsResponse, error) {
  4800  	gensupport.SetOptions(c.urlParams_, opts...)
  4801  	res, err := c.doRequest("json")
  4802  	if res != nil && res.StatusCode == http.StatusNotModified {
  4803  		if res.Body != nil {
  4804  			res.Body.Close()
  4805  		}
  4806  		return nil, &googleapi.Error{
  4807  			Code:   res.StatusCode,
  4808  			Header: res.Header,
  4809  		}
  4810  	}
  4811  	if err != nil {
  4812  		return nil, err
  4813  	}
  4814  	defer googleapi.CloseBody(res)
  4815  	if err := googleapi.CheckResponse(res); err != nil {
  4816  		return nil, err
  4817  	}
  4818  	ret := &ListVersionsResponse{
  4819  		ServerResponse: googleapi.ServerResponse{
  4820  			Header:         res.Header,
  4821  			HTTPStatusCode: res.StatusCode,
  4822  		},
  4823  	}
  4824  	target := &ret
  4825  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4826  		return nil, err
  4827  	}
  4828  	return ret, nil
  4829  	// {
  4830  	//   "description": "Lists the versions of a module.",
  4831  	//   "flatPath": "v1beta4/apps/{appsId}/modules/{modulesId}/versions",
  4832  	//   "httpMethod": "GET",
  4833  	//   "id": "appengine.apps.modules.versions.list",
  4834  	//   "parameterOrder": [
  4835  	//     "appsId",
  4836  	//     "modulesId"
  4837  	//   ],
  4838  	//   "parameters": {
  4839  	//     "appsId": {
  4840  	//       "description": "Part of `name`. Name of the resource requested. Example: apps/myapp/modules/default.",
  4841  	//       "location": "path",
  4842  	//       "required": true,
  4843  	//       "type": "string"
  4844  	//     },
  4845  	//     "modulesId": {
  4846  	//       "description": "Part of `name`. See documentation of `appsId`.",
  4847  	//       "location": "path",
  4848  	//       "required": true,
  4849  	//       "type": "string"
  4850  	//     },
  4851  	//     "pageSize": {
  4852  	//       "description": "Maximum results to return per page.",
  4853  	//       "format": "int32",
  4854  	//       "location": "query",
  4855  	//       "type": "integer"
  4856  	//     },
  4857  	//     "pageToken": {
  4858  	//       "description": "Continuation token for fetching the next page of results.",
  4859  	//       "location": "query",
  4860  	//       "type": "string"
  4861  	//     },
  4862  	//     "view": {
  4863  	//       "description": "Controls the set of fields returned in the List response.",
  4864  	//       "enum": [
  4865  	//         "BASIC",
  4866  	//         "FULL"
  4867  	//       ],
  4868  	//       "location": "query",
  4869  	//       "type": "string"
  4870  	//     }
  4871  	//   },
  4872  	//   "path": "v1beta4/apps/{appsId}/modules/{modulesId}/versions",
  4873  	//   "response": {
  4874  	//     "$ref": "ListVersionsResponse"
  4875  	//   },
  4876  	//   "scopes": [
  4877  	//     "https://www.googleapis.com/auth/appengine.admin",
  4878  	//     "https://www.googleapis.com/auth/cloud-platform",
  4879  	//     "https://www.googleapis.com/auth/cloud-platform.read-only"
  4880  	//   ]
  4881  	// }
  4882  
  4883  }
  4884  
  4885  // Pages invokes f for each page of results.
  4886  // A non-nil error returned from f will halt the iteration.
  4887  // The provided context supersedes any context provided to the Context method.
  4888  func (c *AppsModulesVersionsListCall) Pages(ctx context.Context, f func(*ListVersionsResponse) error) error {
  4889  	c.ctx_ = ctx
  4890  	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
  4891  	for {
  4892  		x, err := c.Do()
  4893  		if err != nil {
  4894  			return err
  4895  		}
  4896  		if err := f(x); err != nil {
  4897  			return err
  4898  		}
  4899  		if x.NextPageToken == "" {
  4900  			return nil
  4901  		}
  4902  		c.PageToken(x.NextPageToken)
  4903  	}
  4904  }
  4905  
  4906  // method id "appengine.apps.modules.versions.patch":
  4907  
  4908  type AppsModulesVersionsPatchCall struct {
  4909  	s          *APIService
  4910  	appsId     string
  4911  	modulesId  string
  4912  	versionsId string
  4913  	version    *Version
  4914  	urlParams_ gensupport.URLParams
  4915  	ctx_       context.Context
  4916  	header_    http.Header
  4917  }
  4918  
  4919  // Patch: Updates the specified Version resource. You can specify the
  4920  // following fields depending on the App Engine environment and type of
  4921  // scaling that the version resource uses:
  4922  // serving_status
  4923  // (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps.modules.versions#Version.FIELDS.serving_status):
  4924  //
  4925  //	For Version resources that use basic scaling, manual scaling, or run
  4926  //
  4927  // in  the App Engine flexible environment.
  4928  // instance_class
  4929  // (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps.modules.versions#Version.FIELDS.instance_class):
  4930  //
  4931  //	For Version resources that run in the App Engine standard
  4932  //
  4933  // environment.
  4934  // automatic_scaling.min_idle_instances
  4935  // (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps.modules.versions#Version.FIELDS.automatic_scaling):
  4936  //
  4937  //	For Version resources that use automatic scaling and run in the App
  4938  //
  4939  // Engine standard environment.
  4940  // automatic_scaling.max_idle_instances
  4941  // (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps.modules.versions#Version.FIELDS.automatic_scaling):
  4942  //
  4943  //	For Version resources that use automatic scaling and run in the App
  4944  //
  4945  // Engine standard environment.
  4946  func (r *AppsModulesVersionsService) Patch(appsId string, modulesId string, versionsId string, version *Version) *AppsModulesVersionsPatchCall {
  4947  	c := &AppsModulesVersionsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4948  	c.appsId = appsId
  4949  	c.modulesId = modulesId
  4950  	c.versionsId = versionsId
  4951  	c.version = version
  4952  	return c
  4953  }
  4954  
  4955  // Mask sets the optional parameter "mask": Standard field mask for the
  4956  // set of fields to be updated.
  4957  func (c *AppsModulesVersionsPatchCall) Mask(mask string) *AppsModulesVersionsPatchCall {
  4958  	c.urlParams_.Set("mask", mask)
  4959  	return c
  4960  }
  4961  
  4962  // Fields allows partial responses to be retrieved. See
  4963  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  4964  // for more information.
  4965  func (c *AppsModulesVersionsPatchCall) Fields(s ...googleapi.Field) *AppsModulesVersionsPatchCall {
  4966  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4967  	return c
  4968  }
  4969  
  4970  // Context sets the context to be used in this call's Do method. Any
  4971  // pending HTTP request will be aborted if the provided context is
  4972  // canceled.
  4973  func (c *AppsModulesVersionsPatchCall) Context(ctx context.Context) *AppsModulesVersionsPatchCall {
  4974  	c.ctx_ = ctx
  4975  	return c
  4976  }
  4977  
  4978  // Header returns an http.Header that can be modified by the caller to
  4979  // add HTTP headers to the request.
  4980  func (c *AppsModulesVersionsPatchCall) Header() http.Header {
  4981  	if c.header_ == nil {
  4982  		c.header_ = make(http.Header)
  4983  	}
  4984  	return c.header_
  4985  }
  4986  
  4987  func (c *AppsModulesVersionsPatchCall) doRequest(alt string) (*http.Response, error) {
  4988  	reqHeaders := make(http.Header)
  4989  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  4990  	for k, v := range c.header_ {
  4991  		reqHeaders[k] = v
  4992  	}
  4993  	reqHeaders.Set("User-Agent", c.s.userAgent())
  4994  	var body io.Reader = nil
  4995  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.version)
  4996  	if err != nil {
  4997  		return nil, err
  4998  	}
  4999  	reqHeaders.Set("Content-Type", "application/json")
  5000  	c.urlParams_.Set("alt", alt)
  5001  	c.urlParams_.Set("prettyPrint", "false")
  5002  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}")
  5003  	urls += "?" + c.urlParams_.Encode()
  5004  	req, err := http.NewRequest("PATCH", urls, body)
  5005  	if err != nil {
  5006  		return nil, err
  5007  	}
  5008  	req.Header = reqHeaders
  5009  	googleapi.Expand(req.URL, map[string]string{
  5010  		"appsId":     c.appsId,
  5011  		"modulesId":  c.modulesId,
  5012  		"versionsId": c.versionsId,
  5013  	})
  5014  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5015  }
  5016  
  5017  // Do executes the "appengine.apps.modules.versions.patch" call.
  5018  // Exactly one of *Operation or error will be non-nil. Any non-2xx
  5019  // status code is an error. Response headers are in either
  5020  // *Operation.ServerResponse.Header or (if a response was returned at
  5021  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
  5022  // to check whether the returned error was because
  5023  // http.StatusNotModified was returned.
  5024  func (c *AppsModulesVersionsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  5025  	gensupport.SetOptions(c.urlParams_, opts...)
  5026  	res, err := c.doRequest("json")
  5027  	if res != nil && res.StatusCode == http.StatusNotModified {
  5028  		if res.Body != nil {
  5029  			res.Body.Close()
  5030  		}
  5031  		return nil, &googleapi.Error{
  5032  			Code:   res.StatusCode,
  5033  			Header: res.Header,
  5034  		}
  5035  	}
  5036  	if err != nil {
  5037  		return nil, err
  5038  	}
  5039  	defer googleapi.CloseBody(res)
  5040  	if err := googleapi.CheckResponse(res); err != nil {
  5041  		return nil, err
  5042  	}
  5043  	ret := &Operation{
  5044  		ServerResponse: googleapi.ServerResponse{
  5045  			Header:         res.Header,
  5046  			HTTPStatusCode: res.StatusCode,
  5047  		},
  5048  	}
  5049  	target := &ret
  5050  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5051  		return nil, err
  5052  	}
  5053  	return ret, nil
  5054  	// {
  5055  	//   "description": "Updates the specified Version resource. You can specify the following fields depending on the App Engine environment and type of scaling that the version resource uses:\nserving_status (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps.modules.versions#Version.FIELDS.serving_status):  For Version resources that use basic scaling, manual scaling, or run in  the App Engine flexible environment.\ninstance_class (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps.modules.versions#Version.FIELDS.instance_class):  For Version resources that run in the App Engine standard environment.\nautomatic_scaling.min_idle_instances (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps.modules.versions#Version.FIELDS.automatic_scaling):  For Version resources that use automatic scaling and run in the App  Engine standard environment.\nautomatic_scaling.max_idle_instances (https://cloud.google.com/appengine/docs/admin-api/reference/rest/v1beta4/apps.modules.versions#Version.FIELDS.automatic_scaling):  For Version resources that use automatic scaling and run in the App  Engine standard environment.",
  5056  	//   "flatPath": "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}",
  5057  	//   "httpMethod": "PATCH",
  5058  	//   "id": "appengine.apps.modules.versions.patch",
  5059  	//   "parameterOrder": [
  5060  	//     "appsId",
  5061  	//     "modulesId",
  5062  	//     "versionsId"
  5063  	//   ],
  5064  	//   "parameters": {
  5065  	//     "appsId": {
  5066  	//       "description": "Part of `name`. Name of the resource to update. Example: apps/myapp/modules/default/versions/1.",
  5067  	//       "location": "path",
  5068  	//       "required": true,
  5069  	//       "type": "string"
  5070  	//     },
  5071  	//     "mask": {
  5072  	//       "description": "Standard field mask for the set of fields to be updated.",
  5073  	//       "format": "google-fieldmask",
  5074  	//       "location": "query",
  5075  	//       "type": "string"
  5076  	//     },
  5077  	//     "modulesId": {
  5078  	//       "description": "Part of `name`. See documentation of `appsId`.",
  5079  	//       "location": "path",
  5080  	//       "required": true,
  5081  	//       "type": "string"
  5082  	//     },
  5083  	//     "versionsId": {
  5084  	//       "description": "Part of `name`. See documentation of `appsId`.",
  5085  	//       "location": "path",
  5086  	//       "required": true,
  5087  	//       "type": "string"
  5088  	//     }
  5089  	//   },
  5090  	//   "path": "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}",
  5091  	//   "request": {
  5092  	//     "$ref": "Version"
  5093  	//   },
  5094  	//   "response": {
  5095  	//     "$ref": "Operation"
  5096  	//   },
  5097  	//   "scopes": [
  5098  	//     "https://www.googleapis.com/auth/cloud-platform"
  5099  	//   ]
  5100  	// }
  5101  
  5102  }
  5103  
  5104  // method id "appengine.apps.modules.versions.instances.debug":
  5105  
  5106  type AppsModulesVersionsInstancesDebugCall struct {
  5107  	s                    *APIService
  5108  	appsId               string
  5109  	modulesId            string
  5110  	versionsId           string
  5111  	instancesId          string
  5112  	debuginstancerequest *DebugInstanceRequest
  5113  	urlParams_           gensupport.URLParams
  5114  	ctx_                 context.Context
  5115  	header_              http.Header
  5116  }
  5117  
  5118  // Debug: Enables debugging on a VM instance. This allows you to use the
  5119  // SSH command to connect to the virtual machine where the instance
  5120  // lives. While in "debug mode", the instance continues to serve live
  5121  // traffic. You should delete the instance when you are done debugging
  5122  // and then allow the system to take over and determine if another
  5123  // instance should be started.Only applicable for instances in App
  5124  // Engine flexible environment.
  5125  func (r *AppsModulesVersionsInstancesService) Debug(appsId string, modulesId string, versionsId string, instancesId string, debuginstancerequest *DebugInstanceRequest) *AppsModulesVersionsInstancesDebugCall {
  5126  	c := &AppsModulesVersionsInstancesDebugCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  5127  	c.appsId = appsId
  5128  	c.modulesId = modulesId
  5129  	c.versionsId = versionsId
  5130  	c.instancesId = instancesId
  5131  	c.debuginstancerequest = debuginstancerequest
  5132  	return c
  5133  }
  5134  
  5135  // Fields allows partial responses to be retrieved. See
  5136  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  5137  // for more information.
  5138  func (c *AppsModulesVersionsInstancesDebugCall) Fields(s ...googleapi.Field) *AppsModulesVersionsInstancesDebugCall {
  5139  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  5140  	return c
  5141  }
  5142  
  5143  // Context sets the context to be used in this call's Do method. Any
  5144  // pending HTTP request will be aborted if the provided context is
  5145  // canceled.
  5146  func (c *AppsModulesVersionsInstancesDebugCall) Context(ctx context.Context) *AppsModulesVersionsInstancesDebugCall {
  5147  	c.ctx_ = ctx
  5148  	return c
  5149  }
  5150  
  5151  // Header returns an http.Header that can be modified by the caller to
  5152  // add HTTP headers to the request.
  5153  func (c *AppsModulesVersionsInstancesDebugCall) Header() http.Header {
  5154  	if c.header_ == nil {
  5155  		c.header_ = make(http.Header)
  5156  	}
  5157  	return c.header_
  5158  }
  5159  
  5160  func (c *AppsModulesVersionsInstancesDebugCall) doRequest(alt string) (*http.Response, error) {
  5161  	reqHeaders := make(http.Header)
  5162  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  5163  	for k, v := range c.header_ {
  5164  		reqHeaders[k] = v
  5165  	}
  5166  	reqHeaders.Set("User-Agent", c.s.userAgent())
  5167  	var body io.Reader = nil
  5168  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.debuginstancerequest)
  5169  	if err != nil {
  5170  		return nil, err
  5171  	}
  5172  	reqHeaders.Set("Content-Type", "application/json")
  5173  	c.urlParams_.Set("alt", alt)
  5174  	c.urlParams_.Set("prettyPrint", "false")
  5175  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}/instances/{instancesId}:debug")
  5176  	urls += "?" + c.urlParams_.Encode()
  5177  	req, err := http.NewRequest("POST", urls, body)
  5178  	if err != nil {
  5179  		return nil, err
  5180  	}
  5181  	req.Header = reqHeaders
  5182  	googleapi.Expand(req.URL, map[string]string{
  5183  		"appsId":      c.appsId,
  5184  		"modulesId":   c.modulesId,
  5185  		"versionsId":  c.versionsId,
  5186  		"instancesId": c.instancesId,
  5187  	})
  5188  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5189  }
  5190  
  5191  // Do executes the "appengine.apps.modules.versions.instances.debug" call.
  5192  // Exactly one of *Operation or error will be non-nil. Any non-2xx
  5193  // status code is an error. Response headers are in either
  5194  // *Operation.ServerResponse.Header or (if a response was returned at
  5195  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
  5196  // to check whether the returned error was because
  5197  // http.StatusNotModified was returned.
  5198  func (c *AppsModulesVersionsInstancesDebugCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  5199  	gensupport.SetOptions(c.urlParams_, opts...)
  5200  	res, err := c.doRequest("json")
  5201  	if res != nil && res.StatusCode == http.StatusNotModified {
  5202  		if res.Body != nil {
  5203  			res.Body.Close()
  5204  		}
  5205  		return nil, &googleapi.Error{
  5206  			Code:   res.StatusCode,
  5207  			Header: res.Header,
  5208  		}
  5209  	}
  5210  	if err != nil {
  5211  		return nil, err
  5212  	}
  5213  	defer googleapi.CloseBody(res)
  5214  	if err := googleapi.CheckResponse(res); err != nil {
  5215  		return nil, err
  5216  	}
  5217  	ret := &Operation{
  5218  		ServerResponse: googleapi.ServerResponse{
  5219  			Header:         res.Header,
  5220  			HTTPStatusCode: res.StatusCode,
  5221  		},
  5222  	}
  5223  	target := &ret
  5224  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5225  		return nil, err
  5226  	}
  5227  	return ret, nil
  5228  	// {
  5229  	//   "description": "Enables debugging on a VM instance. This allows you to use the SSH command to connect to the virtual machine where the instance lives. While in \"debug mode\", the instance continues to serve live traffic. You should delete the instance when you are done debugging and then allow the system to take over and determine if another instance should be started.Only applicable for instances in App Engine flexible environment.",
  5230  	//   "flatPath": "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}/instances/{instancesId}:debug",
  5231  	//   "httpMethod": "POST",
  5232  	//   "id": "appengine.apps.modules.versions.instances.debug",
  5233  	//   "parameterOrder": [
  5234  	//     "appsId",
  5235  	//     "modulesId",
  5236  	//     "versionsId",
  5237  	//     "instancesId"
  5238  	//   ],
  5239  	//   "parameters": {
  5240  	//     "appsId": {
  5241  	//       "description": "Part of `name`. Name of the resource requested. Example: apps/myapp/modules/default/versions/v1/instances/instance-1.",
  5242  	//       "location": "path",
  5243  	//       "required": true,
  5244  	//       "type": "string"
  5245  	//     },
  5246  	//     "instancesId": {
  5247  	//       "description": "Part of `name`. See documentation of `appsId`.",
  5248  	//       "location": "path",
  5249  	//       "required": true,
  5250  	//       "type": "string"
  5251  	//     },
  5252  	//     "modulesId": {
  5253  	//       "description": "Part of `name`. See documentation of `appsId`.",
  5254  	//       "location": "path",
  5255  	//       "required": true,
  5256  	//       "type": "string"
  5257  	//     },
  5258  	//     "versionsId": {
  5259  	//       "description": "Part of `name`. See documentation of `appsId`.",
  5260  	//       "location": "path",
  5261  	//       "required": true,
  5262  	//       "type": "string"
  5263  	//     }
  5264  	//   },
  5265  	//   "path": "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}/instances/{instancesId}:debug",
  5266  	//   "request": {
  5267  	//     "$ref": "DebugInstanceRequest"
  5268  	//   },
  5269  	//   "response": {
  5270  	//     "$ref": "Operation"
  5271  	//   },
  5272  	//   "scopes": [
  5273  	//     "https://www.googleapis.com/auth/cloud-platform"
  5274  	//   ]
  5275  	// }
  5276  
  5277  }
  5278  
  5279  // method id "appengine.apps.modules.versions.instances.delete":
  5280  
  5281  type AppsModulesVersionsInstancesDeleteCall struct {
  5282  	s           *APIService
  5283  	appsId      string
  5284  	modulesId   string
  5285  	versionsId  string
  5286  	instancesId string
  5287  	urlParams_  gensupport.URLParams
  5288  	ctx_        context.Context
  5289  	header_     http.Header
  5290  }
  5291  
  5292  // Delete: Stops a running instance.
  5293  func (r *AppsModulesVersionsInstancesService) Delete(appsId string, modulesId string, versionsId string, instancesId string) *AppsModulesVersionsInstancesDeleteCall {
  5294  	c := &AppsModulesVersionsInstancesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  5295  	c.appsId = appsId
  5296  	c.modulesId = modulesId
  5297  	c.versionsId = versionsId
  5298  	c.instancesId = instancesId
  5299  	return c
  5300  }
  5301  
  5302  // Fields allows partial responses to be retrieved. See
  5303  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  5304  // for more information.
  5305  func (c *AppsModulesVersionsInstancesDeleteCall) Fields(s ...googleapi.Field) *AppsModulesVersionsInstancesDeleteCall {
  5306  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  5307  	return c
  5308  }
  5309  
  5310  // Context sets the context to be used in this call's Do method. Any
  5311  // pending HTTP request will be aborted if the provided context is
  5312  // canceled.
  5313  func (c *AppsModulesVersionsInstancesDeleteCall) Context(ctx context.Context) *AppsModulesVersionsInstancesDeleteCall {
  5314  	c.ctx_ = ctx
  5315  	return c
  5316  }
  5317  
  5318  // Header returns an http.Header that can be modified by the caller to
  5319  // add HTTP headers to the request.
  5320  func (c *AppsModulesVersionsInstancesDeleteCall) Header() http.Header {
  5321  	if c.header_ == nil {
  5322  		c.header_ = make(http.Header)
  5323  	}
  5324  	return c.header_
  5325  }
  5326  
  5327  func (c *AppsModulesVersionsInstancesDeleteCall) doRequest(alt string) (*http.Response, error) {
  5328  	reqHeaders := make(http.Header)
  5329  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  5330  	for k, v := range c.header_ {
  5331  		reqHeaders[k] = v
  5332  	}
  5333  	reqHeaders.Set("User-Agent", c.s.userAgent())
  5334  	var body io.Reader = nil
  5335  	c.urlParams_.Set("alt", alt)
  5336  	c.urlParams_.Set("prettyPrint", "false")
  5337  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}/instances/{instancesId}")
  5338  	urls += "?" + c.urlParams_.Encode()
  5339  	req, err := http.NewRequest("DELETE", urls, body)
  5340  	if err != nil {
  5341  		return nil, err
  5342  	}
  5343  	req.Header = reqHeaders
  5344  	googleapi.Expand(req.URL, map[string]string{
  5345  		"appsId":      c.appsId,
  5346  		"modulesId":   c.modulesId,
  5347  		"versionsId":  c.versionsId,
  5348  		"instancesId": c.instancesId,
  5349  	})
  5350  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5351  }
  5352  
  5353  // Do executes the "appengine.apps.modules.versions.instances.delete" call.
  5354  // Exactly one of *Operation or error will be non-nil. Any non-2xx
  5355  // status code is an error. Response headers are in either
  5356  // *Operation.ServerResponse.Header or (if a response was returned at
  5357  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
  5358  // to check whether the returned error was because
  5359  // http.StatusNotModified was returned.
  5360  func (c *AppsModulesVersionsInstancesDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  5361  	gensupport.SetOptions(c.urlParams_, opts...)
  5362  	res, err := c.doRequest("json")
  5363  	if res != nil && res.StatusCode == http.StatusNotModified {
  5364  		if res.Body != nil {
  5365  			res.Body.Close()
  5366  		}
  5367  		return nil, &googleapi.Error{
  5368  			Code:   res.StatusCode,
  5369  			Header: res.Header,
  5370  		}
  5371  	}
  5372  	if err != nil {
  5373  		return nil, err
  5374  	}
  5375  	defer googleapi.CloseBody(res)
  5376  	if err := googleapi.CheckResponse(res); err != nil {
  5377  		return nil, err
  5378  	}
  5379  	ret := &Operation{
  5380  		ServerResponse: googleapi.ServerResponse{
  5381  			Header:         res.Header,
  5382  			HTTPStatusCode: res.StatusCode,
  5383  		},
  5384  	}
  5385  	target := &ret
  5386  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5387  		return nil, err
  5388  	}
  5389  	return ret, nil
  5390  	// {
  5391  	//   "description": "Stops a running instance.",
  5392  	//   "flatPath": "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}/instances/{instancesId}",
  5393  	//   "httpMethod": "DELETE",
  5394  	//   "id": "appengine.apps.modules.versions.instances.delete",
  5395  	//   "parameterOrder": [
  5396  	//     "appsId",
  5397  	//     "modulesId",
  5398  	//     "versionsId",
  5399  	//     "instancesId"
  5400  	//   ],
  5401  	//   "parameters": {
  5402  	//     "appsId": {
  5403  	//       "description": "Part of `name`. Name of the resource requested. Example: apps/myapp/modules/default/versions/v1/instances/instance-1.",
  5404  	//       "location": "path",
  5405  	//       "required": true,
  5406  	//       "type": "string"
  5407  	//     },
  5408  	//     "instancesId": {
  5409  	//       "description": "Part of `name`. See documentation of `appsId`.",
  5410  	//       "location": "path",
  5411  	//       "required": true,
  5412  	//       "type": "string"
  5413  	//     },
  5414  	//     "modulesId": {
  5415  	//       "description": "Part of `name`. See documentation of `appsId`.",
  5416  	//       "location": "path",
  5417  	//       "required": true,
  5418  	//       "type": "string"
  5419  	//     },
  5420  	//     "versionsId": {
  5421  	//       "description": "Part of `name`. See documentation of `appsId`.",
  5422  	//       "location": "path",
  5423  	//       "required": true,
  5424  	//       "type": "string"
  5425  	//     }
  5426  	//   },
  5427  	//   "path": "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}/instances/{instancesId}",
  5428  	//   "response": {
  5429  	//     "$ref": "Operation"
  5430  	//   },
  5431  	//   "scopes": [
  5432  	//     "https://www.googleapis.com/auth/cloud-platform"
  5433  	//   ]
  5434  	// }
  5435  
  5436  }
  5437  
  5438  // method id "appengine.apps.modules.versions.instances.get":
  5439  
  5440  type AppsModulesVersionsInstancesGetCall struct {
  5441  	s            *APIService
  5442  	appsId       string
  5443  	modulesId    string
  5444  	versionsId   string
  5445  	instancesId  string
  5446  	urlParams_   gensupport.URLParams
  5447  	ifNoneMatch_ string
  5448  	ctx_         context.Context
  5449  	header_      http.Header
  5450  }
  5451  
  5452  // Get: Gets instance information.
  5453  func (r *AppsModulesVersionsInstancesService) Get(appsId string, modulesId string, versionsId string, instancesId string) *AppsModulesVersionsInstancesGetCall {
  5454  	c := &AppsModulesVersionsInstancesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  5455  	c.appsId = appsId
  5456  	c.modulesId = modulesId
  5457  	c.versionsId = versionsId
  5458  	c.instancesId = instancesId
  5459  	return c
  5460  }
  5461  
  5462  // Fields allows partial responses to be retrieved. See
  5463  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  5464  // for more information.
  5465  func (c *AppsModulesVersionsInstancesGetCall) Fields(s ...googleapi.Field) *AppsModulesVersionsInstancesGetCall {
  5466  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  5467  	return c
  5468  }
  5469  
  5470  // IfNoneMatch sets the optional parameter which makes the operation
  5471  // fail if the object's ETag matches the given value. This is useful for
  5472  // getting updates only after the object has changed since the last
  5473  // request. Use googleapi.IsNotModified to check whether the response
  5474  // error from Do is the result of In-None-Match.
  5475  func (c *AppsModulesVersionsInstancesGetCall) IfNoneMatch(entityTag string) *AppsModulesVersionsInstancesGetCall {
  5476  	c.ifNoneMatch_ = entityTag
  5477  	return c
  5478  }
  5479  
  5480  // Context sets the context to be used in this call's Do method. Any
  5481  // pending HTTP request will be aborted if the provided context is
  5482  // canceled.
  5483  func (c *AppsModulesVersionsInstancesGetCall) Context(ctx context.Context) *AppsModulesVersionsInstancesGetCall {
  5484  	c.ctx_ = ctx
  5485  	return c
  5486  }
  5487  
  5488  // Header returns an http.Header that can be modified by the caller to
  5489  // add HTTP headers to the request.
  5490  func (c *AppsModulesVersionsInstancesGetCall) Header() http.Header {
  5491  	if c.header_ == nil {
  5492  		c.header_ = make(http.Header)
  5493  	}
  5494  	return c.header_
  5495  }
  5496  
  5497  func (c *AppsModulesVersionsInstancesGetCall) doRequest(alt string) (*http.Response, error) {
  5498  	reqHeaders := make(http.Header)
  5499  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  5500  	for k, v := range c.header_ {
  5501  		reqHeaders[k] = v
  5502  	}
  5503  	reqHeaders.Set("User-Agent", c.s.userAgent())
  5504  	if c.ifNoneMatch_ != "" {
  5505  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  5506  	}
  5507  	var body io.Reader = nil
  5508  	c.urlParams_.Set("alt", alt)
  5509  	c.urlParams_.Set("prettyPrint", "false")
  5510  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}/instances/{instancesId}")
  5511  	urls += "?" + c.urlParams_.Encode()
  5512  	req, err := http.NewRequest("GET", urls, body)
  5513  	if err != nil {
  5514  		return nil, err
  5515  	}
  5516  	req.Header = reqHeaders
  5517  	googleapi.Expand(req.URL, map[string]string{
  5518  		"appsId":      c.appsId,
  5519  		"modulesId":   c.modulesId,
  5520  		"versionsId":  c.versionsId,
  5521  		"instancesId": c.instancesId,
  5522  	})
  5523  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5524  }
  5525  
  5526  // Do executes the "appengine.apps.modules.versions.instances.get" call.
  5527  // Exactly one of *Instance or error will be non-nil. Any non-2xx status
  5528  // code is an error. Response headers are in either
  5529  // *Instance.ServerResponse.Header or (if a response was returned at
  5530  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
  5531  // to check whether the returned error was because
  5532  // http.StatusNotModified was returned.
  5533  func (c *AppsModulesVersionsInstancesGetCall) Do(opts ...googleapi.CallOption) (*Instance, error) {
  5534  	gensupport.SetOptions(c.urlParams_, opts...)
  5535  	res, err := c.doRequest("json")
  5536  	if res != nil && res.StatusCode == http.StatusNotModified {
  5537  		if res.Body != nil {
  5538  			res.Body.Close()
  5539  		}
  5540  		return nil, &googleapi.Error{
  5541  			Code:   res.StatusCode,
  5542  			Header: res.Header,
  5543  		}
  5544  	}
  5545  	if err != nil {
  5546  		return nil, err
  5547  	}
  5548  	defer googleapi.CloseBody(res)
  5549  	if err := googleapi.CheckResponse(res); err != nil {
  5550  		return nil, err
  5551  	}
  5552  	ret := &Instance{
  5553  		ServerResponse: googleapi.ServerResponse{
  5554  			Header:         res.Header,
  5555  			HTTPStatusCode: res.StatusCode,
  5556  		},
  5557  	}
  5558  	target := &ret
  5559  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5560  		return nil, err
  5561  	}
  5562  	return ret, nil
  5563  	// {
  5564  	//   "description": "Gets instance information.",
  5565  	//   "flatPath": "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}/instances/{instancesId}",
  5566  	//   "httpMethod": "GET",
  5567  	//   "id": "appengine.apps.modules.versions.instances.get",
  5568  	//   "parameterOrder": [
  5569  	//     "appsId",
  5570  	//     "modulesId",
  5571  	//     "versionsId",
  5572  	//     "instancesId"
  5573  	//   ],
  5574  	//   "parameters": {
  5575  	//     "appsId": {
  5576  	//       "description": "Part of `name`. Name of the resource requested. Example: apps/myapp/modules/default/versions/v1/instances/instance-1.",
  5577  	//       "location": "path",
  5578  	//       "required": true,
  5579  	//       "type": "string"
  5580  	//     },
  5581  	//     "instancesId": {
  5582  	//       "description": "Part of `name`. See documentation of `appsId`.",
  5583  	//       "location": "path",
  5584  	//       "required": true,
  5585  	//       "type": "string"
  5586  	//     },
  5587  	//     "modulesId": {
  5588  	//       "description": "Part of `name`. See documentation of `appsId`.",
  5589  	//       "location": "path",
  5590  	//       "required": true,
  5591  	//       "type": "string"
  5592  	//     },
  5593  	//     "versionsId": {
  5594  	//       "description": "Part of `name`. See documentation of `appsId`.",
  5595  	//       "location": "path",
  5596  	//       "required": true,
  5597  	//       "type": "string"
  5598  	//     }
  5599  	//   },
  5600  	//   "path": "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}/instances/{instancesId}",
  5601  	//   "response": {
  5602  	//     "$ref": "Instance"
  5603  	//   },
  5604  	//   "scopes": [
  5605  	//     "https://www.googleapis.com/auth/appengine.admin",
  5606  	//     "https://www.googleapis.com/auth/cloud-platform",
  5607  	//     "https://www.googleapis.com/auth/cloud-platform.read-only"
  5608  	//   ]
  5609  	// }
  5610  
  5611  }
  5612  
  5613  // method id "appengine.apps.modules.versions.instances.list":
  5614  
  5615  type AppsModulesVersionsInstancesListCall struct {
  5616  	s            *APIService
  5617  	appsId       string
  5618  	modulesId    string
  5619  	versionsId   string
  5620  	urlParams_   gensupport.URLParams
  5621  	ifNoneMatch_ string
  5622  	ctx_         context.Context
  5623  	header_      http.Header
  5624  }
  5625  
  5626  // List: Lists the instances of a version.Tip: To aggregate details
  5627  // about instances over time, see the Stackdriver Monitoring API
  5628  // (https://cloud.google.com/monitoring/api/ref_v3/rest/v3/projects.timeSeries/list).
  5629  func (r *AppsModulesVersionsInstancesService) List(appsId string, modulesId string, versionsId string) *AppsModulesVersionsInstancesListCall {
  5630  	c := &AppsModulesVersionsInstancesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  5631  	c.appsId = appsId
  5632  	c.modulesId = modulesId
  5633  	c.versionsId = versionsId
  5634  	return c
  5635  }
  5636  
  5637  // PageSize sets the optional parameter "pageSize": Maximum results to
  5638  // return per page.
  5639  func (c *AppsModulesVersionsInstancesListCall) PageSize(pageSize int64) *AppsModulesVersionsInstancesListCall {
  5640  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  5641  	return c
  5642  }
  5643  
  5644  // PageToken sets the optional parameter "pageToken": Continuation token
  5645  // for fetching the next page of results.
  5646  func (c *AppsModulesVersionsInstancesListCall) PageToken(pageToken string) *AppsModulesVersionsInstancesListCall {
  5647  	c.urlParams_.Set("pageToken", pageToken)
  5648  	return c
  5649  }
  5650  
  5651  // Fields allows partial responses to be retrieved. See
  5652  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  5653  // for more information.
  5654  func (c *AppsModulesVersionsInstancesListCall) Fields(s ...googleapi.Field) *AppsModulesVersionsInstancesListCall {
  5655  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  5656  	return c
  5657  }
  5658  
  5659  // IfNoneMatch sets the optional parameter which makes the operation
  5660  // fail if the object's ETag matches the given value. This is useful for
  5661  // getting updates only after the object has changed since the last
  5662  // request. Use googleapi.IsNotModified to check whether the response
  5663  // error from Do is the result of In-None-Match.
  5664  func (c *AppsModulesVersionsInstancesListCall) IfNoneMatch(entityTag string) *AppsModulesVersionsInstancesListCall {
  5665  	c.ifNoneMatch_ = entityTag
  5666  	return c
  5667  }
  5668  
  5669  // Context sets the context to be used in this call's Do method. Any
  5670  // pending HTTP request will be aborted if the provided context is
  5671  // canceled.
  5672  func (c *AppsModulesVersionsInstancesListCall) Context(ctx context.Context) *AppsModulesVersionsInstancesListCall {
  5673  	c.ctx_ = ctx
  5674  	return c
  5675  }
  5676  
  5677  // Header returns an http.Header that can be modified by the caller to
  5678  // add HTTP headers to the request.
  5679  func (c *AppsModulesVersionsInstancesListCall) Header() http.Header {
  5680  	if c.header_ == nil {
  5681  		c.header_ = make(http.Header)
  5682  	}
  5683  	return c.header_
  5684  }
  5685  
  5686  func (c *AppsModulesVersionsInstancesListCall) doRequest(alt string) (*http.Response, error) {
  5687  	reqHeaders := make(http.Header)
  5688  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  5689  	for k, v := range c.header_ {
  5690  		reqHeaders[k] = v
  5691  	}
  5692  	reqHeaders.Set("User-Agent", c.s.userAgent())
  5693  	if c.ifNoneMatch_ != "" {
  5694  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  5695  	}
  5696  	var body io.Reader = nil
  5697  	c.urlParams_.Set("alt", alt)
  5698  	c.urlParams_.Set("prettyPrint", "false")
  5699  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}/instances")
  5700  	urls += "?" + c.urlParams_.Encode()
  5701  	req, err := http.NewRequest("GET", urls, body)
  5702  	if err != nil {
  5703  		return nil, err
  5704  	}
  5705  	req.Header = reqHeaders
  5706  	googleapi.Expand(req.URL, map[string]string{
  5707  		"appsId":     c.appsId,
  5708  		"modulesId":  c.modulesId,
  5709  		"versionsId": c.versionsId,
  5710  	})
  5711  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5712  }
  5713  
  5714  // Do executes the "appengine.apps.modules.versions.instances.list" call.
  5715  // Exactly one of *ListInstancesResponse or error will be non-nil. Any
  5716  // non-2xx status code is an error. Response headers are in either
  5717  // *ListInstancesResponse.ServerResponse.Header or (if a response was
  5718  // returned at all) in error.(*googleapi.Error).Header. Use
  5719  // googleapi.IsNotModified to check whether the returned error was
  5720  // because http.StatusNotModified was returned.
  5721  func (c *AppsModulesVersionsInstancesListCall) Do(opts ...googleapi.CallOption) (*ListInstancesResponse, error) {
  5722  	gensupport.SetOptions(c.urlParams_, opts...)
  5723  	res, err := c.doRequest("json")
  5724  	if res != nil && res.StatusCode == http.StatusNotModified {
  5725  		if res.Body != nil {
  5726  			res.Body.Close()
  5727  		}
  5728  		return nil, &googleapi.Error{
  5729  			Code:   res.StatusCode,
  5730  			Header: res.Header,
  5731  		}
  5732  	}
  5733  	if err != nil {
  5734  		return nil, err
  5735  	}
  5736  	defer googleapi.CloseBody(res)
  5737  	if err := googleapi.CheckResponse(res); err != nil {
  5738  		return nil, err
  5739  	}
  5740  	ret := &ListInstancesResponse{
  5741  		ServerResponse: googleapi.ServerResponse{
  5742  			Header:         res.Header,
  5743  			HTTPStatusCode: res.StatusCode,
  5744  		},
  5745  	}
  5746  	target := &ret
  5747  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5748  		return nil, err
  5749  	}
  5750  	return ret, nil
  5751  	// {
  5752  	//   "description": "Lists the instances of a version.Tip: To aggregate details about instances over time, see the Stackdriver Monitoring API (https://cloud.google.com/monitoring/api/ref_v3/rest/v3/projects.timeSeries/list).",
  5753  	//   "flatPath": "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}/instances",
  5754  	//   "httpMethod": "GET",
  5755  	//   "id": "appengine.apps.modules.versions.instances.list",
  5756  	//   "parameterOrder": [
  5757  	//     "appsId",
  5758  	//     "modulesId",
  5759  	//     "versionsId"
  5760  	//   ],
  5761  	//   "parameters": {
  5762  	//     "appsId": {
  5763  	//       "description": "Part of `name`. Name of the resource requested. Example: apps/myapp/modules/default/versions/v1.",
  5764  	//       "location": "path",
  5765  	//       "required": true,
  5766  	//       "type": "string"
  5767  	//     },
  5768  	//     "modulesId": {
  5769  	//       "description": "Part of `name`. See documentation of `appsId`.",
  5770  	//       "location": "path",
  5771  	//       "required": true,
  5772  	//       "type": "string"
  5773  	//     },
  5774  	//     "pageSize": {
  5775  	//       "description": "Maximum results to return per page.",
  5776  	//       "format": "int32",
  5777  	//       "location": "query",
  5778  	//       "type": "integer"
  5779  	//     },
  5780  	//     "pageToken": {
  5781  	//       "description": "Continuation token for fetching the next page of results.",
  5782  	//       "location": "query",
  5783  	//       "type": "string"
  5784  	//     },
  5785  	//     "versionsId": {
  5786  	//       "description": "Part of `name`. See documentation of `appsId`.",
  5787  	//       "location": "path",
  5788  	//       "required": true,
  5789  	//       "type": "string"
  5790  	//     }
  5791  	//   },
  5792  	//   "path": "v1beta4/apps/{appsId}/modules/{modulesId}/versions/{versionsId}/instances",
  5793  	//   "response": {
  5794  	//     "$ref": "ListInstancesResponse"
  5795  	//   },
  5796  	//   "scopes": [
  5797  	//     "https://www.googleapis.com/auth/appengine.admin",
  5798  	//     "https://www.googleapis.com/auth/cloud-platform",
  5799  	//     "https://www.googleapis.com/auth/cloud-platform.read-only"
  5800  	//   ]
  5801  	// }
  5802  
  5803  }
  5804  
  5805  // Pages invokes f for each page of results.
  5806  // A non-nil error returned from f will halt the iteration.
  5807  // The provided context supersedes any context provided to the Context method.
  5808  func (c *AppsModulesVersionsInstancesListCall) Pages(ctx context.Context, f func(*ListInstancesResponse) error) error {
  5809  	c.ctx_ = ctx
  5810  	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
  5811  	for {
  5812  		x, err := c.Do()
  5813  		if err != nil {
  5814  			return err
  5815  		}
  5816  		if err := f(x); err != nil {
  5817  			return err
  5818  		}
  5819  		if x.NextPageToken == "" {
  5820  			return nil
  5821  		}
  5822  		c.PageToken(x.NextPageToken)
  5823  	}
  5824  }
  5825  
  5826  // method id "appengine.apps.operations.get":
  5827  
  5828  type AppsOperationsGetCall struct {
  5829  	s            *APIService
  5830  	appsId       string
  5831  	operationsId string
  5832  	urlParams_   gensupport.URLParams
  5833  	ifNoneMatch_ string
  5834  	ctx_         context.Context
  5835  	header_      http.Header
  5836  }
  5837  
  5838  // Get: Gets the latest state of a long-running operation. Clients can
  5839  // use this method to poll the operation result at intervals as
  5840  // recommended by the API service.
  5841  func (r *AppsOperationsService) Get(appsId string, operationsId string) *AppsOperationsGetCall {
  5842  	c := &AppsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  5843  	c.appsId = appsId
  5844  	c.operationsId = operationsId
  5845  	return c
  5846  }
  5847  
  5848  // Fields allows partial responses to be retrieved. See
  5849  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  5850  // for more information.
  5851  func (c *AppsOperationsGetCall) Fields(s ...googleapi.Field) *AppsOperationsGetCall {
  5852  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  5853  	return c
  5854  }
  5855  
  5856  // IfNoneMatch sets the optional parameter which makes the operation
  5857  // fail if the object's ETag matches the given value. This is useful for
  5858  // getting updates only after the object has changed since the last
  5859  // request. Use googleapi.IsNotModified to check whether the response
  5860  // error from Do is the result of In-None-Match.
  5861  func (c *AppsOperationsGetCall) IfNoneMatch(entityTag string) *AppsOperationsGetCall {
  5862  	c.ifNoneMatch_ = entityTag
  5863  	return c
  5864  }
  5865  
  5866  // Context sets the context to be used in this call's Do method. Any
  5867  // pending HTTP request will be aborted if the provided context is
  5868  // canceled.
  5869  func (c *AppsOperationsGetCall) Context(ctx context.Context) *AppsOperationsGetCall {
  5870  	c.ctx_ = ctx
  5871  	return c
  5872  }
  5873  
  5874  // Header returns an http.Header that can be modified by the caller to
  5875  // add HTTP headers to the request.
  5876  func (c *AppsOperationsGetCall) Header() http.Header {
  5877  	if c.header_ == nil {
  5878  		c.header_ = make(http.Header)
  5879  	}
  5880  	return c.header_
  5881  }
  5882  
  5883  func (c *AppsOperationsGetCall) doRequest(alt string) (*http.Response, error) {
  5884  	reqHeaders := make(http.Header)
  5885  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  5886  	for k, v := range c.header_ {
  5887  		reqHeaders[k] = v
  5888  	}
  5889  	reqHeaders.Set("User-Agent", c.s.userAgent())
  5890  	if c.ifNoneMatch_ != "" {
  5891  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  5892  	}
  5893  	var body io.Reader = nil
  5894  	c.urlParams_.Set("alt", alt)
  5895  	c.urlParams_.Set("prettyPrint", "false")
  5896  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}/operations/{operationsId}")
  5897  	urls += "?" + c.urlParams_.Encode()
  5898  	req, err := http.NewRequest("GET", urls, body)
  5899  	if err != nil {
  5900  		return nil, err
  5901  	}
  5902  	req.Header = reqHeaders
  5903  	googleapi.Expand(req.URL, map[string]string{
  5904  		"appsId":       c.appsId,
  5905  		"operationsId": c.operationsId,
  5906  	})
  5907  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5908  }
  5909  
  5910  // Do executes the "appengine.apps.operations.get" call.
  5911  // Exactly one of *Operation or error will be non-nil. Any non-2xx
  5912  // status code is an error. Response headers are in either
  5913  // *Operation.ServerResponse.Header or (if a response was returned at
  5914  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified
  5915  // to check whether the returned error was because
  5916  // http.StatusNotModified was returned.
  5917  func (c *AppsOperationsGetCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  5918  	gensupport.SetOptions(c.urlParams_, opts...)
  5919  	res, err := c.doRequest("json")
  5920  	if res != nil && res.StatusCode == http.StatusNotModified {
  5921  		if res.Body != nil {
  5922  			res.Body.Close()
  5923  		}
  5924  		return nil, &googleapi.Error{
  5925  			Code:   res.StatusCode,
  5926  			Header: res.Header,
  5927  		}
  5928  	}
  5929  	if err != nil {
  5930  		return nil, err
  5931  	}
  5932  	defer googleapi.CloseBody(res)
  5933  	if err := googleapi.CheckResponse(res); err != nil {
  5934  		return nil, err
  5935  	}
  5936  	ret := &Operation{
  5937  		ServerResponse: googleapi.ServerResponse{
  5938  			Header:         res.Header,
  5939  			HTTPStatusCode: res.StatusCode,
  5940  		},
  5941  	}
  5942  	target := &ret
  5943  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5944  		return nil, err
  5945  	}
  5946  	return ret, nil
  5947  	// {
  5948  	//   "description": "Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.",
  5949  	//   "flatPath": "v1beta4/apps/{appsId}/operations/{operationsId}",
  5950  	//   "httpMethod": "GET",
  5951  	//   "id": "appengine.apps.operations.get",
  5952  	//   "parameterOrder": [
  5953  	//     "appsId",
  5954  	//     "operationsId"
  5955  	//   ],
  5956  	//   "parameters": {
  5957  	//     "appsId": {
  5958  	//       "description": "Part of `name`. The name of the operation resource.",
  5959  	//       "location": "path",
  5960  	//       "required": true,
  5961  	//       "type": "string"
  5962  	//     },
  5963  	//     "operationsId": {
  5964  	//       "description": "Part of `name`. See documentation of `appsId`.",
  5965  	//       "location": "path",
  5966  	//       "required": true,
  5967  	//       "type": "string"
  5968  	//     }
  5969  	//   },
  5970  	//   "path": "v1beta4/apps/{appsId}/operations/{operationsId}",
  5971  	//   "response": {
  5972  	//     "$ref": "Operation"
  5973  	//   },
  5974  	//   "scopes": [
  5975  	//     "https://www.googleapis.com/auth/appengine.admin",
  5976  	//     "https://www.googleapis.com/auth/cloud-platform",
  5977  	//     "https://www.googleapis.com/auth/cloud-platform.read-only"
  5978  	//   ]
  5979  	// }
  5980  
  5981  }
  5982  
  5983  // method id "appengine.apps.operations.list":
  5984  
  5985  type AppsOperationsListCall struct {
  5986  	s            *APIService
  5987  	appsId       string
  5988  	urlParams_   gensupport.URLParams
  5989  	ifNoneMatch_ string
  5990  	ctx_         context.Context
  5991  	header_      http.Header
  5992  }
  5993  
  5994  // List: Lists operations that match the specified filter in the
  5995  // request. If the server doesn't support this method, it returns
  5996  // UNIMPLEMENTED.NOTE: the name binding allows API services to override
  5997  // the binding to use different resource name schemes, such as
  5998  // users/*/operations. To override the binding, API services can add a
  5999  // binding such as "/v1/{name=users/*}/operations" to their service
  6000  // configuration. For backwards compatibility, the default name includes
  6001  // the operations collection id, however overriding users must ensure
  6002  // the name binding is the parent resource, without the operations
  6003  // collection id.
  6004  func (r *AppsOperationsService) List(appsId string) *AppsOperationsListCall {
  6005  	c := &AppsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  6006  	c.appsId = appsId
  6007  	return c
  6008  }
  6009  
  6010  // Filter sets the optional parameter "filter": The standard list
  6011  // filter.
  6012  func (c *AppsOperationsListCall) Filter(filter string) *AppsOperationsListCall {
  6013  	c.urlParams_.Set("filter", filter)
  6014  	return c
  6015  }
  6016  
  6017  // PageSize sets the optional parameter "pageSize": The standard list
  6018  // page size.
  6019  func (c *AppsOperationsListCall) PageSize(pageSize int64) *AppsOperationsListCall {
  6020  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  6021  	return c
  6022  }
  6023  
  6024  // PageToken sets the optional parameter "pageToken": The standard list
  6025  // page token.
  6026  func (c *AppsOperationsListCall) PageToken(pageToken string) *AppsOperationsListCall {
  6027  	c.urlParams_.Set("pageToken", pageToken)
  6028  	return c
  6029  }
  6030  
  6031  // Fields allows partial responses to be retrieved. See
  6032  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
  6033  // for more information.
  6034  func (c *AppsOperationsListCall) Fields(s ...googleapi.Field) *AppsOperationsListCall {
  6035  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  6036  	return c
  6037  }
  6038  
  6039  // IfNoneMatch sets the optional parameter which makes the operation
  6040  // fail if the object's ETag matches the given value. This is useful for
  6041  // getting updates only after the object has changed since the last
  6042  // request. Use googleapi.IsNotModified to check whether the response
  6043  // error from Do is the result of In-None-Match.
  6044  func (c *AppsOperationsListCall) IfNoneMatch(entityTag string) *AppsOperationsListCall {
  6045  	c.ifNoneMatch_ = entityTag
  6046  	return c
  6047  }
  6048  
  6049  // Context sets the context to be used in this call's Do method. Any
  6050  // pending HTTP request will be aborted if the provided context is
  6051  // canceled.
  6052  func (c *AppsOperationsListCall) Context(ctx context.Context) *AppsOperationsListCall {
  6053  	c.ctx_ = ctx
  6054  	return c
  6055  }
  6056  
  6057  // Header returns an http.Header that can be modified by the caller to
  6058  // add HTTP headers to the request.
  6059  func (c *AppsOperationsListCall) Header() http.Header {
  6060  	if c.header_ == nil {
  6061  		c.header_ = make(http.Header)
  6062  	}
  6063  	return c.header_
  6064  }
  6065  
  6066  func (c *AppsOperationsListCall) doRequest(alt string) (*http.Response, error) {
  6067  	reqHeaders := make(http.Header)
  6068  	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/20210110")
  6069  	for k, v := range c.header_ {
  6070  		reqHeaders[k] = v
  6071  	}
  6072  	reqHeaders.Set("User-Agent", c.s.userAgent())
  6073  	if c.ifNoneMatch_ != "" {
  6074  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  6075  	}
  6076  	var body io.Reader = nil
  6077  	c.urlParams_.Set("alt", alt)
  6078  	c.urlParams_.Set("prettyPrint", "false")
  6079  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta4/apps/{appsId}/operations")
  6080  	urls += "?" + c.urlParams_.Encode()
  6081  	req, err := http.NewRequest("GET", urls, body)
  6082  	if err != nil {
  6083  		return nil, err
  6084  	}
  6085  	req.Header = reqHeaders
  6086  	googleapi.Expand(req.URL, map[string]string{
  6087  		"appsId": c.appsId,
  6088  	})
  6089  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  6090  }
  6091  
  6092  // Do executes the "appengine.apps.operations.list" call.
  6093  // Exactly one of *ListOperationsResponse or error will be non-nil. Any
  6094  // non-2xx status code is an error. Response headers are in either
  6095  // *ListOperationsResponse.ServerResponse.Header or (if a response was
  6096  // returned at all) in error.(*googleapi.Error).Header. Use
  6097  // googleapi.IsNotModified to check whether the returned error was
  6098  // because http.StatusNotModified was returned.
  6099  func (c *AppsOperationsListCall) Do(opts ...googleapi.CallOption) (*ListOperationsResponse, error) {
  6100  	gensupport.SetOptions(c.urlParams_, opts...)
  6101  	res, err := c.doRequest("json")
  6102  	if res != nil && res.StatusCode == http.StatusNotModified {
  6103  		if res.Body != nil {
  6104  			res.Body.Close()
  6105  		}
  6106  		return nil, &googleapi.Error{
  6107  			Code:   res.StatusCode,
  6108  			Header: res.Header,
  6109  		}
  6110  	}
  6111  	if err != nil {
  6112  		return nil, err
  6113  	}
  6114  	defer googleapi.CloseBody(res)
  6115  	if err := googleapi.CheckResponse(res); err != nil {
  6116  		return nil, err
  6117  	}
  6118  	ret := &ListOperationsResponse{
  6119  		ServerResponse: googleapi.ServerResponse{
  6120  			Header:         res.Header,
  6121  			HTTPStatusCode: res.StatusCode,
  6122  		},
  6123  	}
  6124  	target := &ret
  6125  	if err := gensupport.DecodeResponse(target, res); err != nil {
  6126  		return nil, err
  6127  	}
  6128  	return ret, nil
  6129  	// {
  6130  	//   "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns UNIMPLEMENTED.NOTE: the name binding allows API services to override the binding to use different resource name schemes, such as users/*/operations. To override the binding, API services can add a binding such as \"/v1/{name=users/*}/operations\" to their service configuration. For backwards compatibility, the default name includes the operations collection id, however overriding users must ensure the name binding is the parent resource, without the operations collection id.",
  6131  	//   "flatPath": "v1beta4/apps/{appsId}/operations",
  6132  	//   "httpMethod": "GET",
  6133  	//   "id": "appengine.apps.operations.list",
  6134  	//   "parameterOrder": [
  6135  	//     "appsId"
  6136  	//   ],
  6137  	//   "parameters": {
  6138  	//     "appsId": {
  6139  	//       "description": "Part of `name`. The name of the operation's parent resource.",
  6140  	//       "location": "path",
  6141  	//       "required": true,
  6142  	//       "type": "string"
  6143  	//     },
  6144  	//     "filter": {
  6145  	//       "description": "The standard list filter.",
  6146  	//       "location": "query",
  6147  	//       "type": "string"
  6148  	//     },
  6149  	//     "pageSize": {
  6150  	//       "description": "The standard list page size.",
  6151  	//       "format": "int32",
  6152  	//       "location": "query",
  6153  	//       "type": "integer"
  6154  	//     },
  6155  	//     "pageToken": {
  6156  	//       "description": "The standard list page token.",
  6157  	//       "location": "query",
  6158  	//       "type": "string"
  6159  	//     }
  6160  	//   },
  6161  	//   "path": "v1beta4/apps/{appsId}/operations",
  6162  	//   "response": {
  6163  	//     "$ref": "ListOperationsResponse"
  6164  	//   },
  6165  	//   "scopes": [
  6166  	//     "https://www.googleapis.com/auth/appengine.admin",
  6167  	//     "https://www.googleapis.com/auth/cloud-platform",
  6168  	//     "https://www.googleapis.com/auth/cloud-platform.read-only"
  6169  	//   ]
  6170  	// }
  6171  
  6172  }
  6173  
  6174  // Pages invokes f for each page of results.
  6175  // A non-nil error returned from f will halt the iteration.
  6176  // The provided context supersedes any context provided to the Context method.
  6177  func (c *AppsOperationsListCall) Pages(ctx context.Context, f func(*ListOperationsResponse) error) error {
  6178  	c.ctx_ = ctx
  6179  	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
  6180  	for {
  6181  		x, err := c.Do()
  6182  		if err != nil {
  6183  			return err
  6184  		}
  6185  		if err := f(x); err != nil {
  6186  			return err
  6187  		}
  6188  		if x.NextPageToken == "" {
  6189  			return nil
  6190  		}
  6191  		c.PageToken(x.NextPageToken)
  6192  	}
  6193  }
  6194  

View as plain text