...

Source file src/google.golang.org/api/workstations/v1beta/workstations-gen.go

Documentation: google.golang.org/api/workstations/v1beta

     1  // Copyright 2024 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 workstations provides access to the Cloud Workstations API.
     8  //
     9  // For product documentation, see: https://cloud.google.com/workstations
    10  //
    11  // # Library status
    12  //
    13  // These client libraries are officially supported by Google. However, this
    14  // library is considered complete and is in maintenance mode. This means
    15  // that we will address critical bugs and security issues but will not add
    16  // any new features.
    17  //
    18  // When possible, we recommend using our newer
    19  // [Cloud Client Libraries for Go](https://pkg.go.dev/cloud.google.com/go)
    20  // that are still actively being worked and iterated on.
    21  //
    22  // # Creating a client
    23  //
    24  // Usage example:
    25  //
    26  //	import "google.golang.org/api/workstations/v1beta"
    27  //	...
    28  //	ctx := context.Background()
    29  //	workstationsService, err := workstations.NewService(ctx)
    30  //
    31  // In this example, Google Application Default Credentials are used for
    32  // authentication. For information on how to create and obtain Application
    33  // Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials.
    34  //
    35  // # Other authentication options
    36  //
    37  // To use an API key for authentication (note: some APIs do not support API
    38  // keys), use [google.golang.org/api/option.WithAPIKey]:
    39  //
    40  //	workstationsService, err := workstations.NewService(ctx, option.WithAPIKey("AIza..."))
    41  //
    42  // To use an OAuth token (e.g., a user token obtained via a three-legged OAuth
    43  // flow, use [google.golang.org/api/option.WithTokenSource]:
    44  //
    45  //	config := &oauth2.Config{...}
    46  //	// ...
    47  //	token, err := config.Exchange(ctx, ...)
    48  //	workstationsService, err := workstations.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
    49  //
    50  // See [google.golang.org/api/option.ClientOption] for details on options.
    51  package workstations // import "google.golang.org/api/workstations/v1beta"
    52  
    53  import (
    54  	"bytes"
    55  	"context"
    56  	"encoding/json"
    57  	"errors"
    58  	"fmt"
    59  	"io"
    60  	"net/http"
    61  	"net/url"
    62  	"strconv"
    63  	"strings"
    64  
    65  	googleapi "google.golang.org/api/googleapi"
    66  	internal "google.golang.org/api/internal"
    67  	gensupport "google.golang.org/api/internal/gensupport"
    68  	option "google.golang.org/api/option"
    69  	internaloption "google.golang.org/api/option/internaloption"
    70  	htransport "google.golang.org/api/transport/http"
    71  )
    72  
    73  // Always reference these packages, just in case the auto-generated code
    74  // below doesn't.
    75  var _ = bytes.NewBuffer
    76  var _ = strconv.Itoa
    77  var _ = fmt.Sprintf
    78  var _ = json.NewDecoder
    79  var _ = io.Copy
    80  var _ = url.Parse
    81  var _ = gensupport.MarshalJSON
    82  var _ = googleapi.Version
    83  var _ = errors.New
    84  var _ = strings.Replace
    85  var _ = context.Canceled
    86  var _ = internaloption.WithDefaultEndpoint
    87  var _ = internal.Version
    88  
    89  const apiId = "workstations:v1beta"
    90  const apiName = "workstations"
    91  const apiVersion = "v1beta"
    92  const basePath = "https://workstations.googleapis.com/"
    93  const basePathTemplate = "https://workstations.UNIVERSE_DOMAIN/"
    94  const mtlsBasePath = "https://workstations.mtls.googleapis.com/"
    95  
    96  // OAuth2 scopes used by this API.
    97  const (
    98  	// See, edit, configure, and delete your Google Cloud data and see the email
    99  	// address for your Google Account.
   100  	CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform"
   101  )
   102  
   103  // NewService creates a new Service.
   104  func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) {
   105  	scopesOption := internaloption.WithDefaultScopes(
   106  		"https://www.googleapis.com/auth/cloud-platform",
   107  	)
   108  	// NOTE: prepend, so we don't override user-specified scopes.
   109  	opts = append([]option.ClientOption{scopesOption}, opts...)
   110  	opts = append(opts, internaloption.WithDefaultEndpoint(basePath))
   111  	opts = append(opts, internaloption.WithDefaultEndpointTemplate(basePathTemplate))
   112  	opts = append(opts, internaloption.WithDefaultMTLSEndpoint(mtlsBasePath))
   113  	opts = append(opts, internaloption.EnableNewAuthLibrary())
   114  	client, endpoint, err := htransport.NewClient(ctx, opts...)
   115  	if err != nil {
   116  		return nil, err
   117  	}
   118  	s, err := New(client)
   119  	if err != nil {
   120  		return nil, err
   121  	}
   122  	if endpoint != "" {
   123  		s.BasePath = endpoint
   124  	}
   125  	return s, nil
   126  }
   127  
   128  // New creates a new Service. It uses the provided http.Client for requests.
   129  //
   130  // Deprecated: please use NewService instead.
   131  // To provide a custom HTTP client, use option.WithHTTPClient.
   132  // If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
   133  func New(client *http.Client) (*Service, error) {
   134  	if client == nil {
   135  		return nil, errors.New("client is nil")
   136  	}
   137  	s := &Service{client: client, BasePath: basePath}
   138  	s.Projects = NewProjectsService(s)
   139  	return s, nil
   140  }
   141  
   142  type Service struct {
   143  	client    *http.Client
   144  	BasePath  string // API endpoint base URL
   145  	UserAgent string // optional additional User-Agent fragment
   146  
   147  	Projects *ProjectsService
   148  }
   149  
   150  func (s *Service) userAgent() string {
   151  	if s.UserAgent == "" {
   152  		return googleapi.UserAgent
   153  	}
   154  	return googleapi.UserAgent + " " + s.UserAgent
   155  }
   156  
   157  func NewProjectsService(s *Service) *ProjectsService {
   158  	rs := &ProjectsService{s: s}
   159  	rs.Locations = NewProjectsLocationsService(s)
   160  	return rs
   161  }
   162  
   163  type ProjectsService struct {
   164  	s *Service
   165  
   166  	Locations *ProjectsLocationsService
   167  }
   168  
   169  func NewProjectsLocationsService(s *Service) *ProjectsLocationsService {
   170  	rs := &ProjectsLocationsService{s: s}
   171  	rs.Operations = NewProjectsLocationsOperationsService(s)
   172  	rs.WorkstationClusters = NewProjectsLocationsWorkstationClustersService(s)
   173  	return rs
   174  }
   175  
   176  type ProjectsLocationsService struct {
   177  	s *Service
   178  
   179  	Operations *ProjectsLocationsOperationsService
   180  
   181  	WorkstationClusters *ProjectsLocationsWorkstationClustersService
   182  }
   183  
   184  func NewProjectsLocationsOperationsService(s *Service) *ProjectsLocationsOperationsService {
   185  	rs := &ProjectsLocationsOperationsService{s: s}
   186  	return rs
   187  }
   188  
   189  type ProjectsLocationsOperationsService struct {
   190  	s *Service
   191  }
   192  
   193  func NewProjectsLocationsWorkstationClustersService(s *Service) *ProjectsLocationsWorkstationClustersService {
   194  	rs := &ProjectsLocationsWorkstationClustersService{s: s}
   195  	rs.WorkstationConfigs = NewProjectsLocationsWorkstationClustersWorkstationConfigsService(s)
   196  	return rs
   197  }
   198  
   199  type ProjectsLocationsWorkstationClustersService struct {
   200  	s *Service
   201  
   202  	WorkstationConfigs *ProjectsLocationsWorkstationClustersWorkstationConfigsService
   203  }
   204  
   205  func NewProjectsLocationsWorkstationClustersWorkstationConfigsService(s *Service) *ProjectsLocationsWorkstationClustersWorkstationConfigsService {
   206  	rs := &ProjectsLocationsWorkstationClustersWorkstationConfigsService{s: s}
   207  	rs.Workstations = NewProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService(s)
   208  	return rs
   209  }
   210  
   211  type ProjectsLocationsWorkstationClustersWorkstationConfigsService struct {
   212  	s *Service
   213  
   214  	Workstations *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService
   215  }
   216  
   217  func NewProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService(s *Service) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService {
   218  	rs := &ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService{s: s}
   219  	return rs
   220  }
   221  
   222  type ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService struct {
   223  	s *Service
   224  }
   225  
   226  // Accelerator: An accelerator card attached to the instance.
   227  type Accelerator struct {
   228  	// Count: Optional. Number of accelerator cards exposed to the instance.
   229  	Count int64 `json:"count,omitempty"`
   230  	// Type: Optional. Type of accelerator resource to attach to the instance, for
   231  	// example, "nvidia-tesla-p100".
   232  	Type string `json:"type,omitempty"`
   233  	// ForceSendFields is a list of field names (e.g. "Count") to unconditionally
   234  	// include in API requests. By default, fields with empty or default values are
   235  	// omitted from API requests. See
   236  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   237  	// details.
   238  	ForceSendFields []string `json:"-"`
   239  	// NullFields is a list of field names (e.g. "Count") to include in API
   240  	// requests with the JSON null value. By default, fields with empty values are
   241  	// omitted from API requests. See
   242  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   243  	NullFields []string `json:"-"`
   244  }
   245  
   246  func (s *Accelerator) MarshalJSON() ([]byte, error) {
   247  	type NoMethod Accelerator
   248  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   249  }
   250  
   251  // AuditConfig: Specifies the audit configuration for a service. The
   252  // configuration determines which permission types are logged, and what
   253  // identities, if any, are exempted from logging. An AuditConfig must have one
   254  // or more AuditLogConfigs. If there are AuditConfigs for both `allServices`
   255  // and a specific service, the union of the two AuditConfigs is used for that
   256  // service: the log_types specified in each AuditConfig are enabled, and the
   257  // exempted_members in each AuditLogConfig are exempted. Example Policy with
   258  // multiple AuditConfigs: { "audit_configs": [ { "service": "allServices",
   259  // "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members": [
   260  // "user:jose@example.com" ] }, { "log_type": "DATA_WRITE" }, { "log_type":
   261  // "ADMIN_READ" } ] }, { "service": "sampleservice.googleapis.com",
   262  // "audit_log_configs": [ { "log_type": "DATA_READ" }, { "log_type":
   263  // "DATA_WRITE", "exempted_members": [ "user:aliya@example.com" ] } ] } ] } For
   264  // sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ
   265  // logging. It also exempts `jose@example.com` from DATA_READ logging, and
   266  // `aliya@example.com` from DATA_WRITE logging.
   267  type AuditConfig struct {
   268  	// AuditLogConfigs: The configuration for logging of each type of permission.
   269  	AuditLogConfigs []*AuditLogConfig `json:"auditLogConfigs,omitempty"`
   270  	// Service: Specifies a service that will be enabled for audit logging. For
   271  	// example, `storage.googleapis.com`, `cloudsql.googleapis.com`. `allServices`
   272  	// is a special value that covers all services.
   273  	Service string `json:"service,omitempty"`
   274  	// ForceSendFields is a list of field names (e.g. "AuditLogConfigs") to
   275  	// unconditionally include in API requests. By default, fields with empty or
   276  	// default values are omitted from API requests. See
   277  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   278  	// details.
   279  	ForceSendFields []string `json:"-"`
   280  	// NullFields is a list of field names (e.g. "AuditLogConfigs") to include in
   281  	// API requests with the JSON null value. By default, fields with empty values
   282  	// are omitted from API requests. See
   283  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   284  	NullFields []string `json:"-"`
   285  }
   286  
   287  func (s *AuditConfig) MarshalJSON() ([]byte, error) {
   288  	type NoMethod AuditConfig
   289  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   290  }
   291  
   292  // AuditLogConfig: Provides the configuration for logging a type of
   293  // permissions. Example: { "audit_log_configs": [ { "log_type": "DATA_READ",
   294  // "exempted_members": [ "user:jose@example.com" ] }, { "log_type":
   295  // "DATA_WRITE" } ] } This enables 'DATA_READ' and 'DATA_WRITE' logging, while
   296  // exempting jose@example.com from DATA_READ logging.
   297  type AuditLogConfig struct {
   298  	// ExemptedMembers: Specifies the identities that do not cause logging for this
   299  	// type of permission. Follows the same format of Binding.members.
   300  	ExemptedMembers []string `json:"exemptedMembers,omitempty"`
   301  	// LogType: The log type that this config enables.
   302  	//
   303  	// Possible values:
   304  	//   "LOG_TYPE_UNSPECIFIED" - Default case. Should never be this.
   305  	//   "ADMIN_READ" - Admin reads. Example: CloudIAM getIamPolicy
   306  	//   "DATA_WRITE" - Data writes. Example: CloudSQL Users create
   307  	//   "DATA_READ" - Data reads. Example: CloudSQL Users list
   308  	LogType string `json:"logType,omitempty"`
   309  	// ForceSendFields is a list of field names (e.g. "ExemptedMembers") to
   310  	// unconditionally include in API requests. By default, fields with empty or
   311  	// default values are omitted from API requests. See
   312  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   313  	// details.
   314  	ForceSendFields []string `json:"-"`
   315  	// NullFields is a list of field names (e.g. "ExemptedMembers") to include in
   316  	// API requests with the JSON null value. By default, fields with empty values
   317  	// are omitted from API requests. See
   318  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   319  	NullFields []string `json:"-"`
   320  }
   321  
   322  func (s *AuditLogConfig) MarshalJSON() ([]byte, error) {
   323  	type NoMethod AuditLogConfig
   324  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   325  }
   326  
   327  // Binding: Associates `members`, or principals, with a `role`.
   328  type Binding struct {
   329  	// Condition: The condition that is associated with this binding. If the
   330  	// condition evaluates to `true`, then this binding applies to the current
   331  	// request. If the condition evaluates to `false`, then this binding does not
   332  	// apply to the current request. However, a different role binding might grant
   333  	// the same role to one or more of the principals in this binding. To learn
   334  	// which resources support conditions in their IAM policies, see the IAM
   335  	// documentation
   336  	// (https://cloud.google.com/iam/help/conditions/resource-policies).
   337  	Condition *Expr `json:"condition,omitempty"`
   338  	// Members: Specifies the principals requesting access for a Google Cloud
   339  	// resource. `members` can have the following values: * `allUsers`: A special
   340  	// identifier that represents anyone who is on the internet; with or without a
   341  	// Google account. * `allAuthenticatedUsers`: A special identifier that
   342  	// represents anyone who is authenticated with a Google account or a service
   343  	// account. Does not include identities that come from external identity
   344  	// providers (IdPs) through identity federation. * `user:{emailid}`: An email
   345  	// address that represents a specific Google account. For example,
   346  	// `alice@example.com` . * `serviceAccount:{emailid}`: An email address that
   347  	// represents a Google service account. For example,
   348  	// `my-other-app@appspot.gserviceaccount.com`. *
   349  	// `serviceAccount:{projectid}.svc.id.goog[{namespace}/{kubernetes-sa}]`: An
   350  	// identifier for a Kubernetes service account
   351  	// (https://cloud.google.com/kubernetes-engine/docs/how-to/kubernetes-service-accounts).
   352  	// For example, `my-project.svc.id.goog[my-namespace/my-kubernetes-sa]`. *
   353  	// `group:{emailid}`: An email address that represents a Google group. For
   354  	// example, `admins@example.com`. * `domain:{domain}`: The G Suite domain
   355  	// (primary) that represents all the users of that domain. For example,
   356  	// `google.com` or `example.com`. *
   357  	// `principal://iam.googleapis.com/locations/global/workforcePools/{pool_id}/sub
   358  	// ject/{subject_attribute_value}`: A single identity in a workforce identity
   359  	// pool. *
   360  	// `principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/
   361  	// group/{group_id}`: All workforce identities in a group. *
   362  	// `principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/
   363  	// attribute.{attribute_name}/{attribute_value}`: All workforce identities with
   364  	// a specific attribute value. *
   365  	// `principalSet://iam.googleapis.com/locations/global/workforcePools/{pool_id}/
   366  	// *`: All identities in a workforce identity pool. *
   367  	// `principal://iam.googleapis.com/projects/{project_number}/locations/global/wo
   368  	// rkloadIdentityPools/{pool_id}/subject/{subject_attribute_value}`: A single
   369  	// identity in a workload identity pool. *
   370  	// `principalSet://iam.googleapis.com/projects/{project_number}/locations/global
   371  	// /workloadIdentityPools/{pool_id}/group/{group_id}`: A workload identity pool
   372  	// group. *
   373  	// `principalSet://iam.googleapis.com/projects/{project_number}/locations/global
   374  	// /workloadIdentityPools/{pool_id}/attribute.{attribute_name}/{attribute_value}
   375  	// `: All identities in a workload identity pool with a certain attribute. *
   376  	// `principalSet://iam.googleapis.com/projects/{project_number}/locations/global
   377  	// /workloadIdentityPools/{pool_id}/*`: All identities in a workload identity
   378  	// pool. * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus
   379  	// unique identifier) representing a user that has been recently deleted. For
   380  	// example, `alice@example.com?uid=123456789012345678901`. If the user is
   381  	// recovered, this value reverts to `user:{emailid}` and the recovered user
   382  	// retains the role in the binding. *
   383  	// `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus
   384  	// unique identifier) representing a service account that has been recently
   385  	// deleted. For example,
   386  	// `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. If the
   387  	// service account is undeleted, this value reverts to
   388  	// `serviceAccount:{emailid}` and the undeleted service account retains the
   389  	// role in the binding. * `deleted:group:{emailid}?uid={uniqueid}`: An email
   390  	// address (plus unique identifier) representing a Google group that has been
   391  	// recently deleted. For example,
   392  	// `admins@example.com?uid=123456789012345678901`. If the group is recovered,
   393  	// this value reverts to `group:{emailid}` and the recovered group retains the
   394  	// role in the binding. *
   395  	// `deleted:principal://iam.googleapis.com/locations/global/workforcePools/{pool
   396  	// _id}/subject/{subject_attribute_value}`: Deleted single identity in a
   397  	// workforce identity pool. For example,
   398  	// `deleted:principal://iam.googleapis.com/locations/global/workforcePools/my-po
   399  	// ol-id/subject/my-subject-attribute-value`.
   400  	Members []string `json:"members,omitempty"`
   401  	// Role: Role that is assigned to the list of `members`, or principals. For
   402  	// example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an overview
   403  	// of the IAM roles and permissions, see the IAM documentation
   404  	// (https://cloud.google.com/iam/docs/roles-overview). For a list of the
   405  	// available pre-defined roles, see here
   406  	// (https://cloud.google.com/iam/docs/understanding-roles).
   407  	Role string `json:"role,omitempty"`
   408  	// ForceSendFields is a list of field names (e.g. "Condition") to
   409  	// unconditionally include in API requests. By default, fields with empty or
   410  	// default values are omitted from API requests. See
   411  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   412  	// details.
   413  	ForceSendFields []string `json:"-"`
   414  	// NullFields is a list of field names (e.g. "Condition") to include in API
   415  	// requests with the JSON null value. By default, fields with empty values are
   416  	// omitted from API requests. See
   417  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   418  	NullFields []string `json:"-"`
   419  }
   420  
   421  func (s *Binding) MarshalJSON() ([]byte, error) {
   422  	type NoMethod Binding
   423  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   424  }
   425  
   426  // BoostConfig: A configuration that workstations can boost to.
   427  type BoostConfig struct {
   428  	// Accelerators: Optional. A list of the type and count of accelerator cards
   429  	// attached to the boost instance. Defaults to `none`.
   430  	Accelerators []*Accelerator `json:"accelerators,omitempty"`
   431  	// Id: Optional. Required. The id to be used for the boost config.
   432  	Id string `json:"id,omitempty"`
   433  	// MachineType: Optional. The type of machine that boosted VM instances will
   434  	// useā€”for example, `e2-standard-4`. For more information about machine types
   435  	// that Cloud Workstations supports, see the list of available machine types
   436  	// (https://cloud.google.com/workstations/docs/available-machine-types).
   437  	// Defaults to `e2-standard-4`.
   438  	MachineType string `json:"machineType,omitempty"`
   439  	// PoolSize: Optional. The number of boost VMs that the system should keep idle
   440  	// so that workstations can be boosted quickly. Defaults to `0`.
   441  	PoolSize int64 `json:"poolSize,omitempty"`
   442  	// ForceSendFields is a list of field names (e.g. "Accelerators") to
   443  	// unconditionally include in API requests. By default, fields with empty or
   444  	// default values are omitted from API requests. See
   445  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   446  	// details.
   447  	ForceSendFields []string `json:"-"`
   448  	// NullFields is a list of field names (e.g. "Accelerators") to include in API
   449  	// requests with the JSON null value. By default, fields with empty values are
   450  	// omitted from API requests. See
   451  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   452  	NullFields []string `json:"-"`
   453  }
   454  
   455  func (s *BoostConfig) MarshalJSON() ([]byte, error) {
   456  	type NoMethod BoostConfig
   457  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   458  }
   459  
   460  // CancelOperationRequest: The request message for Operations.CancelOperation.
   461  type CancelOperationRequest struct {
   462  }
   463  
   464  // Container: A Docker container.
   465  type Container struct {
   466  	// Args: Optional. Arguments passed to the entrypoint.
   467  	Args []string `json:"args,omitempty"`
   468  	// Command: Optional. If set, overrides the default ENTRYPOINT specified by the
   469  	// image.
   470  	Command []string `json:"command,omitempty"`
   471  	// Env: Optional. Environment variables passed to the container's entrypoint.
   472  	Env map[string]string `json:"env,omitempty"`
   473  	// Image: Optional. A Docker container image that defines a custom environment.
   474  	// Cloud Workstations provides a number of preconfigured images
   475  	// (https://cloud.google.com/workstations/docs/preconfigured-base-images), but
   476  	// you can create your own custom container images
   477  	// (https://cloud.google.com/workstations/docs/custom-container-images). If
   478  	// using a private image, the `host.gceInstance.serviceAccount` field must be
   479  	// specified in the workstation configuration. If using a custom container
   480  	// image, the service account must have Artifact Registry Reader
   481  	// (https://cloud.google.com/artifact-registry/docs/access-control#roles)
   482  	// permission to pull the specified image. Otherwise, the image must be
   483  	// publicly accessible.
   484  	Image string `json:"image,omitempty"`
   485  	// RunAsUser: Optional. If set, overrides the USER specified in the image with
   486  	// the given uid.
   487  	RunAsUser int64 `json:"runAsUser,omitempty"`
   488  	// WorkingDir: Optional. If set, overrides the default DIR specified by the
   489  	// image.
   490  	WorkingDir string `json:"workingDir,omitempty"`
   491  	// ForceSendFields is a list of field names (e.g. "Args") to unconditionally
   492  	// include in API requests. By default, fields with empty or default values are
   493  	// omitted from API requests. See
   494  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   495  	// details.
   496  	ForceSendFields []string `json:"-"`
   497  	// NullFields is a list of field names (e.g. "Args") to include in API requests
   498  	// with the JSON null value. By default, fields with empty values are omitted
   499  	// from API requests. See
   500  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   501  	NullFields []string `json:"-"`
   502  }
   503  
   504  func (s *Container) MarshalJSON() ([]byte, error) {
   505  	type NoMethod Container
   506  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   507  }
   508  
   509  // CustomerEncryptionKey: A customer-managed encryption key (CMEK) for the
   510  // Compute Engine resources of the associated workstation configuration.
   511  // Specify the name of your Cloud KMS encryption key and the default service
   512  // account. We recommend that you use a separate service account and follow
   513  // Cloud KMS best practices
   514  // (https://cloud.google.com/kms/docs/separation-of-duties).
   515  type CustomerEncryptionKey struct {
   516  	// KmsKey: Immutable. The name of the Google Cloud KMS encryption key. For
   517  	// example,
   518  	// "projects/PROJECT_ID/locations/REGION/keyRings/KEY_RING/cryptoKeys/KEY_NAME"
   519  	// `. The key must be in the same region as the workstation configuration.
   520  	KmsKey string `json:"kmsKey,omitempty"`
   521  	// KmsKeyServiceAccount: Immutable. The service account to use with the
   522  	// specified KMS key. We recommend that you use a separate service account and
   523  	// follow KMS best practices. For more information, see Separation of duties
   524  	// (https://cloud.google.com/kms/docs/separation-of-duties) and `gcloud kms
   525  	// keys add-iam-policy-binding` `--member`
   526  	// (https://cloud.google.com/sdk/gcloud/reference/kms/keys/add-iam-policy-binding#--member).
   527  	KmsKeyServiceAccount string `json:"kmsKeyServiceAccount,omitempty"`
   528  	// ForceSendFields is a list of field names (e.g. "KmsKey") to unconditionally
   529  	// include in API requests. By default, fields with empty or default values are
   530  	// omitted from API requests. See
   531  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   532  	// details.
   533  	ForceSendFields []string `json:"-"`
   534  	// NullFields is a list of field names (e.g. "KmsKey") to include in API
   535  	// requests with the JSON null value. By default, fields with empty values are
   536  	// omitted from API requests. See
   537  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   538  	NullFields []string `json:"-"`
   539  }
   540  
   541  func (s *CustomerEncryptionKey) MarshalJSON() ([]byte, error) {
   542  	type NoMethod CustomerEncryptionKey
   543  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   544  }
   545  
   546  // DomainConfig: Configuration options for a custom domain.
   547  type DomainConfig struct {
   548  	// Domain: Immutable. Domain used by Workstations for HTTP ingress.
   549  	Domain string `json:"domain,omitempty"`
   550  	// ForceSendFields is a list of field names (e.g. "Domain") to unconditionally
   551  	// include in API requests. By default, fields with empty or default values are
   552  	// omitted from API requests. See
   553  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   554  	// details.
   555  	ForceSendFields []string `json:"-"`
   556  	// NullFields is a list of field names (e.g. "Domain") to include in API
   557  	// requests with the JSON null value. By default, fields with empty values are
   558  	// omitted from API requests. See
   559  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   560  	NullFields []string `json:"-"`
   561  }
   562  
   563  func (s *DomainConfig) MarshalJSON() ([]byte, error) {
   564  	type NoMethod DomainConfig
   565  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   566  }
   567  
   568  // EphemeralDirectory: An ephemeral directory which won't persist across
   569  // workstation sessions. It is freshly created on every workstation start
   570  // operation.
   571  type EphemeralDirectory struct {
   572  	// GcePd: An EphemeralDirectory backed by a Compute Engine persistent disk.
   573  	GcePd *GcePersistentDisk `json:"gcePd,omitempty"`
   574  	// MountPath: Required. Location of this directory in the running workstation.
   575  	MountPath string `json:"mountPath,omitempty"`
   576  	// ForceSendFields is a list of field names (e.g. "GcePd") to unconditionally
   577  	// include in API requests. By default, fields with empty or default values are
   578  	// omitted from API requests. See
   579  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   580  	// details.
   581  	ForceSendFields []string `json:"-"`
   582  	// NullFields is a list of field names (e.g. "GcePd") to include in API
   583  	// requests with the JSON null value. By default, fields with empty values are
   584  	// omitted from API requests. See
   585  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   586  	NullFields []string `json:"-"`
   587  }
   588  
   589  func (s *EphemeralDirectory) MarshalJSON() ([]byte, error) {
   590  	type NoMethod EphemeralDirectory
   591  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   592  }
   593  
   594  // Expr: Represents a textual expression in the Common Expression Language
   595  // (CEL) syntax. CEL is a C-like expression language. The syntax and semantics
   596  // of CEL are documented at https://github.com/google/cel-spec. Example
   597  // (Comparison): title: "Summary size limit" description: "Determines if a
   598  // summary is less than 100 chars" expression: "document.summary.size() < 100"
   599  // Example (Equality): title: "Requestor is owner" description: "Determines if
   600  // requestor is the document owner" expression: "document.owner ==
   601  // request.auth.claims.email" Example (Logic): title: "Public documents"
   602  // description: "Determine whether the document should be publicly visible"
   603  // expression: "document.type != 'private' && document.type != 'internal'"
   604  // Example (Data Manipulation): title: "Notification string" description:
   605  // "Create a notification string with a timestamp." expression: "'New message
   606  // received at ' + string(document.create_time)" The exact variables and
   607  // functions that may be referenced within an expression are determined by the
   608  // service that evaluates it. See the service documentation for additional
   609  // information.
   610  type Expr struct {
   611  	// Description: Optional. Description of the expression. This is a longer text
   612  	// which describes the expression, e.g. when hovered over it in a UI.
   613  	Description string `json:"description,omitempty"`
   614  	// Expression: Textual representation of an expression in Common Expression
   615  	// Language syntax.
   616  	Expression string `json:"expression,omitempty"`
   617  	// Location: Optional. String indicating the location of the expression for
   618  	// error reporting, e.g. a file name and a position in the file.
   619  	Location string `json:"location,omitempty"`
   620  	// Title: Optional. Title for the expression, i.e. a short string describing
   621  	// its purpose. This can be used e.g. in UIs which allow to enter the
   622  	// expression.
   623  	Title string `json:"title,omitempty"`
   624  	// ForceSendFields is a list of field names (e.g. "Description") to
   625  	// unconditionally include in API requests. By default, fields with empty or
   626  	// default values are omitted from API requests. See
   627  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   628  	// details.
   629  	ForceSendFields []string `json:"-"`
   630  	// NullFields is a list of field names (e.g. "Description") to include in API
   631  	// requests with the JSON null value. By default, fields with empty values are
   632  	// omitted from API requests. See
   633  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   634  	NullFields []string `json:"-"`
   635  }
   636  
   637  func (s *Expr) MarshalJSON() ([]byte, error) {
   638  	type NoMethod Expr
   639  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   640  }
   641  
   642  // GceConfidentialInstanceConfig: A set of Compute Engine Confidential VM
   643  // instance options.
   644  type GceConfidentialInstanceConfig struct {
   645  	// EnableConfidentialCompute: Optional. Whether the instance has confidential
   646  	// compute enabled.
   647  	EnableConfidentialCompute bool `json:"enableConfidentialCompute,omitempty"`
   648  	// ForceSendFields is a list of field names (e.g. "EnableConfidentialCompute")
   649  	// to unconditionally include in API requests. By default, fields with empty or
   650  	// default values are omitted from API requests. See
   651  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   652  	// details.
   653  	ForceSendFields []string `json:"-"`
   654  	// NullFields is a list of field names (e.g. "EnableConfidentialCompute") to
   655  	// include in API requests with the JSON null value. By default, fields with
   656  	// empty values are omitted from API requests. See
   657  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   658  	NullFields []string `json:"-"`
   659  }
   660  
   661  func (s *GceConfidentialInstanceConfig) MarshalJSON() ([]byte, error) {
   662  	type NoMethod GceConfidentialInstanceConfig
   663  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   664  }
   665  
   666  // GceInstance: A runtime using a Compute Engine instance.
   667  type GceInstance struct {
   668  	// Accelerators: Optional. A list of the type and count of accelerator cards
   669  	// attached to the instance.
   670  	Accelerators []*Accelerator `json:"accelerators,omitempty"`
   671  	// BoostConfigs: Optional. A list of the boost configurations that workstations
   672  	// created using this workstation configuration are allowed to use.
   673  	BoostConfigs []*BoostConfig `json:"boostConfigs,omitempty"`
   674  	// BootDiskSizeGb: Optional. The size of the boot disk for the VM in gigabytes
   675  	// (GB). The minimum boot disk size is `30` GB. Defaults to `50` GB.
   676  	BootDiskSizeGb int64 `json:"bootDiskSizeGb,omitempty"`
   677  	// ConfidentialInstanceConfig: Optional. A set of Compute Engine Confidential
   678  	// VM instance options.
   679  	ConfidentialInstanceConfig *GceConfidentialInstanceConfig `json:"confidentialInstanceConfig,omitempty"`
   680  	// DisablePublicIpAddresses: Optional. When set to true, disables public IP
   681  	// addresses for VMs. If you disable public IP addresses, you must set up
   682  	// Private Google Access or Cloud NAT on your network. If you use Private
   683  	// Google Access and you use `private.googleapis.com` or
   684  	// `restricted.googleapis.com` for Container Registry and Artifact Registry,
   685  	// make sure that you set up DNS records for domains `*.gcr.io` and
   686  	// `*.pkg.dev`. Defaults to false (VMs have public IP addresses).
   687  	DisablePublicIpAddresses bool `json:"disablePublicIpAddresses,omitempty"`
   688  	// DisableSsh: Optional. Whether to disable SSH access to the VM.
   689  	DisableSsh bool `json:"disableSsh,omitempty"`
   690  	// EnableNestedVirtualization: Optional. Whether to enable nested
   691  	// virtualization on Cloud Workstations VMs created using this workstation
   692  	// configuration. Nested virtualization lets you run virtual machine (VM)
   693  	// instances inside your workstation. Before enabling nested virtualization,
   694  	// consider the following important considerations. Cloud Workstations
   695  	// instances are subject to the same restrictions as Compute Engine instances
   696  	// (https://cloud.google.com/compute/docs/instances/nested-virtualization/overview#restrictions):
   697  	// * **Organization policy**: projects, folders, or organizations may be
   698  	// restricted from creating nested VMs if the **Disable VM nested
   699  	// virtualization** constraint is enforced in the organization policy. For more
   700  	// information, see the Compute Engine section, Checking whether nested
   701  	// virtualization is allowed
   702  	// (https://cloud.google.com/compute/docs/instances/nested-virtualization/managing-constraint#checking_whether_nested_virtualization_is_allowed).
   703  	// * **Performance**: nested VMs might experience a 10% or greater decrease in
   704  	// performance for workloads that are CPU-bound and possibly greater than a 10%
   705  	// decrease for workloads that are input/output bound. * **Machine Type**:
   706  	// nested virtualization can only be enabled on workstation configurations that
   707  	// specify a machine_type in the N1 or N2 machine series. * **GPUs**: nested
   708  	// virtualization may not be enabled on workstation configurations with
   709  	// accelerators. * **Operating System**: Because Container-Optimized OS
   710  	// (https://cloud.google.com/compute/docs/images/os-details#container-optimized_os_cos)
   711  	// does not support nested virtualization, when nested virtualization is
   712  	// enabled, the underlying Compute Engine VM instances boot from an Ubuntu LTS
   713  	// (https://cloud.google.com/compute/docs/images/os-details#ubuntu_lts) image.
   714  	EnableNestedVirtualization bool `json:"enableNestedVirtualization,omitempty"`
   715  	// MachineType: Optional. The type of machine to use for VM instancesā€”for
   716  	// example, "e2-standard-4". For more information about machine types that
   717  	// Cloud Workstations supports, see the list of available machine types
   718  	// (https://cloud.google.com/workstations/docs/available-machine-types).
   719  	MachineType string `json:"machineType,omitempty"`
   720  	// PoolSize: Optional. The number of VMs that the system should keep idle so
   721  	// that new workstations can be started quickly for new users. Defaults to `0`
   722  	// in the API.
   723  	PoolSize int64 `json:"poolSize,omitempty"`
   724  	// PooledInstances: Output only. Number of instances currently available in the
   725  	// pool for faster workstation startup.
   726  	PooledInstances int64 `json:"pooledInstances,omitempty"`
   727  	// ServiceAccount: Optional. The email address of the service account for Cloud
   728  	// Workstations VMs created with this configuration. When specified, be sure
   729  	// that the service account has `logging.logEntries.create` and
   730  	// `monitoring.timeSeries.create` permissions on the project so it can write
   731  	// logs out to Cloud Logging. If using a custom container image, the service
   732  	// account must have Artifact Registry Reader
   733  	// (https://cloud.google.com/artifact-registry/docs/access-control#roles)
   734  	// permission to pull the specified image. If you as the administrator want to
   735  	// be able to `ssh` into the underlying VM, you need to set this value to a
   736  	// service account for which you have the `iam.serviceAccounts.actAs`
   737  	// permission. Conversely, if you don't want anyone to be able to `ssh` into
   738  	// the underlying VM, use a service account where no one has that permission.
   739  	// If not set, VMs run with a service account provided by the Cloud
   740  	// Workstations service, and the image must be publicly accessible.
   741  	ServiceAccount string `json:"serviceAccount,omitempty"`
   742  	// ServiceAccountScopes: Optional. Scopes to grant to the service_account. When
   743  	// specified, users of workstations under this configuration must have
   744  	// `iam.serviceAccounts.actAs` on the service account.
   745  	ServiceAccountScopes []string `json:"serviceAccountScopes,omitempty"`
   746  	// ShieldedInstanceConfig: Optional. A set of Compute Engine Shielded instance
   747  	// options.
   748  	ShieldedInstanceConfig *GceShieldedInstanceConfig `json:"shieldedInstanceConfig,omitempty"`
   749  	// Tags: Optional. Network tags to add to the Compute Engine VMs backing the
   750  	// workstations. This option applies network tags
   751  	// (https://cloud.google.com/vpc/docs/add-remove-network-tags) to VMs created
   752  	// with this configuration. These network tags enable the creation of firewall
   753  	// rules (https://cloud.google.com/workstations/docs/configure-firewall-rules).
   754  	Tags []string `json:"tags,omitempty"`
   755  	// VmTags: Optional. Resource manager tags to be bound to this instance. Tag
   756  	// keys and values have the same definition as
   757  	// https://cloud.google.com/resource-manager/docs/tags/tags-overview Keys must
   758  	// be in the format `tagKeys/{tag_key_id}`, and values are in the format
   759  	// `tagValues/456`.
   760  	VmTags map[string]string `json:"vmTags,omitempty"`
   761  	// ForceSendFields is a list of field names (e.g. "Accelerators") to
   762  	// unconditionally include in API requests. By default, fields with empty or
   763  	// default values are omitted from API requests. See
   764  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   765  	// details.
   766  	ForceSendFields []string `json:"-"`
   767  	// NullFields is a list of field names (e.g. "Accelerators") to include in API
   768  	// requests with the JSON null value. By default, fields with empty values are
   769  	// omitted from API requests. See
   770  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   771  	NullFields []string `json:"-"`
   772  }
   773  
   774  func (s *GceInstance) MarshalJSON() ([]byte, error) {
   775  	type NoMethod GceInstance
   776  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   777  }
   778  
   779  // GcePersistentDisk: An EphemeralDirectory is backed by a Compute Engine
   780  // persistent disk.
   781  type GcePersistentDisk struct {
   782  	// DiskType: Optional. Type of the disk to use. Defaults to "pd-standard".
   783  	DiskType string `json:"diskType,omitempty"`
   784  	// ReadOnly: Optional. Whether the disk is read only. If true, the disk may be
   785  	// shared by multiple VMs and source_snapshot must be set.
   786  	ReadOnly bool `json:"readOnly,omitempty"`
   787  	// SourceImage: Optional. Name of the disk image to use as the source for the
   788  	// disk. Must be empty if source_snapshot is set. Updating source_image will
   789  	// update content in the ephemeral directory after the workstation is
   790  	// restarted. This field is mutable.
   791  	SourceImage string `json:"sourceImage,omitempty"`
   792  	// SourceSnapshot: Optional. Name of the snapshot to use as the source for the
   793  	// disk. Must be empty if source_image is set. Must be empty if read_only is
   794  	// false. Updating source_snapshot will update content in the ephemeral
   795  	// directory after the workstation is restarted. This field is mutable.
   796  	SourceSnapshot string `json:"sourceSnapshot,omitempty"`
   797  	// ForceSendFields is a list of field names (e.g. "DiskType") to
   798  	// unconditionally include in API requests. By default, fields with empty or
   799  	// default values are omitted from API requests. See
   800  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   801  	// details.
   802  	ForceSendFields []string `json:"-"`
   803  	// NullFields is a list of field names (e.g. "DiskType") to include in API
   804  	// requests with the JSON null value. By default, fields with empty values are
   805  	// omitted from API requests. See
   806  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   807  	NullFields []string `json:"-"`
   808  }
   809  
   810  func (s *GcePersistentDisk) MarshalJSON() ([]byte, error) {
   811  	type NoMethod GcePersistentDisk
   812  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   813  }
   814  
   815  // GceRegionalPersistentDisk: A Persistent Directory backed by a Compute Engine
   816  // regional persistent disk. The persistent_directories field is repeated, but
   817  // it may contain only one entry. It creates a persistent disk
   818  // (https://cloud.google.com/compute/docs/disks/persistent-disks) that mounts
   819  // to the workstation VM at `/home` when the session starts and detaches when
   820  // the session ends. If this field is empty, workstations created with this
   821  // configuration do not have a persistent home directory.
   822  type GceRegionalPersistentDisk struct {
   823  	// DiskType: Optional. The type of the persistent disk
   824  	// (https://cloud.google.com/compute/docs/disks#disk-types) for the home
   825  	// directory. Defaults to "pd-standard".
   826  	DiskType string `json:"diskType,omitempty"`
   827  	// FsType: Optional. Type of file system that the disk should be formatted
   828  	// with. The workstation image must support this file system type. Must be
   829  	// empty if source_snapshot is set. Defaults to "ext4".
   830  	FsType string `json:"fsType,omitempty"`
   831  	// ReclaimPolicy: Optional. Whether the persistent disk should be deleted when
   832  	// the workstation is deleted. Valid values are `DELETE` and `RETAIN`. Defaults
   833  	// to `DELETE`.
   834  	//
   835  	// Possible values:
   836  	//   "RECLAIM_POLICY_UNSPECIFIED" - Do not use.
   837  	//   "DELETE" - Delete the persistent disk when deleting the workstation.
   838  	//   "RETAIN" - Keep the persistent disk when deleting the workstation. An
   839  	// administrator must manually delete the disk.
   840  	ReclaimPolicy string `json:"reclaimPolicy,omitempty"`
   841  	// SizeGb: Optional. The GB capacity of a persistent home directory for each
   842  	// workstation created with this configuration. Must be empty if
   843  	// source_snapshot is set. Valid values are `10`, `50`, `100`, `200`, `500`, or
   844  	// `1000`. Defaults to `200`. If less than `200` GB, the disk_type must be
   845  	// "pd-balanced" or "pd-ssd".
   846  	SizeGb int64 `json:"sizeGb,omitempty"`
   847  	// SourceSnapshot: Optional. Name of the snapshot to use as the source for the
   848  	// disk. If set, size_gb and fs_type must be empty.
   849  	SourceSnapshot string `json:"sourceSnapshot,omitempty"`
   850  	// ForceSendFields is a list of field names (e.g. "DiskType") to
   851  	// unconditionally include in API requests. By default, fields with empty or
   852  	// default values are omitted from API requests. See
   853  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   854  	// details.
   855  	ForceSendFields []string `json:"-"`
   856  	// NullFields is a list of field names (e.g. "DiskType") to include in API
   857  	// requests with the JSON null value. By default, fields with empty values are
   858  	// omitted from API requests. See
   859  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   860  	NullFields []string `json:"-"`
   861  }
   862  
   863  func (s *GceRegionalPersistentDisk) MarshalJSON() ([]byte, error) {
   864  	type NoMethod GceRegionalPersistentDisk
   865  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   866  }
   867  
   868  // GceShieldedInstanceConfig: A set of Compute Engine Shielded instance
   869  // options.
   870  type GceShieldedInstanceConfig struct {
   871  	// EnableIntegrityMonitoring: Optional. Whether the instance has integrity
   872  	// monitoring enabled.
   873  	EnableIntegrityMonitoring bool `json:"enableIntegrityMonitoring,omitempty"`
   874  	// EnableSecureBoot: Optional. Whether the instance has Secure Boot enabled.
   875  	EnableSecureBoot bool `json:"enableSecureBoot,omitempty"`
   876  	// EnableVtpm: Optional. Whether the instance has the vTPM enabled.
   877  	EnableVtpm bool `json:"enableVtpm,omitempty"`
   878  	// ForceSendFields is a list of field names (e.g. "EnableIntegrityMonitoring")
   879  	// to unconditionally include in API requests. By default, fields with empty or
   880  	// default values are omitted from API requests. See
   881  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   882  	// details.
   883  	ForceSendFields []string `json:"-"`
   884  	// NullFields is a list of field names (e.g. "EnableIntegrityMonitoring") to
   885  	// include in API requests with the JSON null value. By default, fields with
   886  	// empty values are omitted from API requests. See
   887  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   888  	NullFields []string `json:"-"`
   889  }
   890  
   891  func (s *GceShieldedInstanceConfig) MarshalJSON() ([]byte, error) {
   892  	type NoMethod GceShieldedInstanceConfig
   893  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   894  }
   895  
   896  // GenerateAccessTokenRequest: Request message for GenerateAccessToken.
   897  type GenerateAccessTokenRequest struct {
   898  	// ExpireTime: Desired expiration time of the access token. This value must be
   899  	// at most 24 hours in the future. If a value is not specified, the token's
   900  	// expiration time will be set to a default value of 1 hour in the future.
   901  	ExpireTime string `json:"expireTime,omitempty"`
   902  	// Ttl: Desired lifetime duration of the access token. This value must be at
   903  	// most 24 hours. If a value is not specified, the token's lifetime will be set
   904  	// to a default value of 1 hour.
   905  	Ttl string `json:"ttl,omitempty"`
   906  	// ForceSendFields is a list of field names (e.g. "ExpireTime") to
   907  	// unconditionally include in API requests. By default, fields with empty or
   908  	// default values are omitted from API requests. See
   909  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   910  	// details.
   911  	ForceSendFields []string `json:"-"`
   912  	// NullFields is a list of field names (e.g. "ExpireTime") to include in API
   913  	// requests with the JSON null value. By default, fields with empty values are
   914  	// omitted from API requests. See
   915  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   916  	NullFields []string `json:"-"`
   917  }
   918  
   919  func (s *GenerateAccessTokenRequest) MarshalJSON() ([]byte, error) {
   920  	type NoMethod GenerateAccessTokenRequest
   921  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   922  }
   923  
   924  // GenerateAccessTokenResponse: Response message for GenerateAccessToken.
   925  type GenerateAccessTokenResponse struct {
   926  	// AccessToken: The generated bearer access token. To use this token, include
   927  	// it in an Authorization header of an HTTP request sent to the associated
   928  	// workstation's hostnameā€”for example, `Authorization: Bearer `.
   929  	AccessToken string `json:"accessToken,omitempty"`
   930  	// ExpireTime: Time at which the generated token will expire.
   931  	ExpireTime string `json:"expireTime,omitempty"`
   932  
   933  	// ServerResponse contains the HTTP response code and headers from the server.
   934  	googleapi.ServerResponse `json:"-"`
   935  	// ForceSendFields is a list of field names (e.g. "AccessToken") to
   936  	// unconditionally include in API requests. By default, fields with empty or
   937  	// default values are omitted from API requests. See
   938  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   939  	// details.
   940  	ForceSendFields []string `json:"-"`
   941  	// NullFields is a list of field names (e.g. "AccessToken") to include in API
   942  	// requests with the JSON null value. By default, fields with empty values are
   943  	// omitted from API requests. See
   944  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   945  	NullFields []string `json:"-"`
   946  }
   947  
   948  func (s *GenerateAccessTokenResponse) MarshalJSON() ([]byte, error) {
   949  	type NoMethod GenerateAccessTokenResponse
   950  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   951  }
   952  
   953  // GoogleProtobufEmpty: A generic empty message that you can re-use to avoid
   954  // defining duplicated empty messages in your APIs. A typical example is to use
   955  // it as the request or the response type of an API method. For instance:
   956  // service Foo { rpc Bar(google.protobuf.Empty) returns
   957  // (google.protobuf.Empty); }
   958  type GoogleProtobufEmpty struct {
   959  	// ServerResponse contains the HTTP response code and headers from the server.
   960  	googleapi.ServerResponse `json:"-"`
   961  }
   962  
   963  // Host: Runtime host for a workstation.
   964  type Host struct {
   965  	// GceInstance: Specifies a Compute Engine instance as the host.
   966  	GceInstance *GceInstance `json:"gceInstance,omitempty"`
   967  	// ForceSendFields is a list of field names (e.g. "GceInstance") to
   968  	// unconditionally include in API requests. By default, fields with empty or
   969  	// default values are omitted from API requests. See
   970  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   971  	// details.
   972  	ForceSendFields []string `json:"-"`
   973  	// NullFields is a list of field names (e.g. "GceInstance") to include in API
   974  	// requests with the JSON null value. By default, fields with empty values are
   975  	// omitted from API requests. See
   976  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
   977  	NullFields []string `json:"-"`
   978  }
   979  
   980  func (s *Host) MarshalJSON() ([]byte, error) {
   981  	type NoMethod Host
   982  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
   983  }
   984  
   985  // ListOperationsResponse: The response message for Operations.ListOperations.
   986  type ListOperationsResponse struct {
   987  	// NextPageToken: The standard List next-page token.
   988  	NextPageToken string `json:"nextPageToken,omitempty"`
   989  	// Operations: A list of operations that matches the specified filter in the
   990  	// request.
   991  	Operations []*Operation `json:"operations,omitempty"`
   992  
   993  	// ServerResponse contains the HTTP response code and headers from the server.
   994  	googleapi.ServerResponse `json:"-"`
   995  	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
   996  	// unconditionally include in API requests. By default, fields with empty or
   997  	// default values are omitted from API requests. See
   998  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
   999  	// details.
  1000  	ForceSendFields []string `json:"-"`
  1001  	// NullFields is a list of field names (e.g. "NextPageToken") to include in API
  1002  	// requests with the JSON null value. By default, fields with empty values are
  1003  	// omitted from API requests. See
  1004  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1005  	NullFields []string `json:"-"`
  1006  }
  1007  
  1008  func (s *ListOperationsResponse) MarshalJSON() ([]byte, error) {
  1009  	type NoMethod ListOperationsResponse
  1010  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1011  }
  1012  
  1013  // ListUsableWorkstationConfigsResponse: Response message for
  1014  // ListUsableWorkstationConfigs.
  1015  type ListUsableWorkstationConfigsResponse struct {
  1016  	// NextPageToken: Token to retrieve the next page of results, or empty if there
  1017  	// are no more results in the list.
  1018  	NextPageToken string `json:"nextPageToken,omitempty"`
  1019  	// Unreachable: Unreachable resources.
  1020  	Unreachable []string `json:"unreachable,omitempty"`
  1021  	// WorkstationConfigs: The requested configs.
  1022  	WorkstationConfigs []*WorkstationConfig `json:"workstationConfigs,omitempty"`
  1023  
  1024  	// ServerResponse contains the HTTP response code and headers from the server.
  1025  	googleapi.ServerResponse `json:"-"`
  1026  	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
  1027  	// unconditionally include in API requests. By default, fields with empty or
  1028  	// default values are omitted from API requests. See
  1029  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1030  	// details.
  1031  	ForceSendFields []string `json:"-"`
  1032  	// NullFields is a list of field names (e.g. "NextPageToken") to include in API
  1033  	// requests with the JSON null value. By default, fields with empty values are
  1034  	// omitted from API requests. See
  1035  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1036  	NullFields []string `json:"-"`
  1037  }
  1038  
  1039  func (s *ListUsableWorkstationConfigsResponse) MarshalJSON() ([]byte, error) {
  1040  	type NoMethod ListUsableWorkstationConfigsResponse
  1041  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1042  }
  1043  
  1044  // ListUsableWorkstationsResponse: Response message for ListUsableWorkstations.
  1045  type ListUsableWorkstationsResponse struct {
  1046  	// NextPageToken: Token to retrieve the next page of results, or empty if there
  1047  	// are no more results in the list.
  1048  	NextPageToken string `json:"nextPageToken,omitempty"`
  1049  	// Unreachable: Unreachable resources.
  1050  	Unreachable []string `json:"unreachable,omitempty"`
  1051  	// Workstations: The requested workstations.
  1052  	Workstations []*Workstation `json:"workstations,omitempty"`
  1053  
  1054  	// ServerResponse contains the HTTP response code and headers from the server.
  1055  	googleapi.ServerResponse `json:"-"`
  1056  	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
  1057  	// unconditionally include in API requests. By default, fields with empty or
  1058  	// default values are omitted from API requests. See
  1059  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1060  	// details.
  1061  	ForceSendFields []string `json:"-"`
  1062  	// NullFields is a list of field names (e.g. "NextPageToken") to include in API
  1063  	// requests with the JSON null value. By default, fields with empty values are
  1064  	// omitted from API requests. See
  1065  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1066  	NullFields []string `json:"-"`
  1067  }
  1068  
  1069  func (s *ListUsableWorkstationsResponse) MarshalJSON() ([]byte, error) {
  1070  	type NoMethod ListUsableWorkstationsResponse
  1071  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1072  }
  1073  
  1074  // ListWorkstationClustersResponse: Response message for
  1075  // ListWorkstationClusters.
  1076  type ListWorkstationClustersResponse struct {
  1077  	// NextPageToken: Token to retrieve the next page of results, or empty if there
  1078  	// are no more results in the list.
  1079  	NextPageToken string `json:"nextPageToken,omitempty"`
  1080  	// Unreachable: Unreachable resources.
  1081  	Unreachable []string `json:"unreachable,omitempty"`
  1082  	// WorkstationClusters: The requested workstation clusters.
  1083  	WorkstationClusters []*WorkstationCluster `json:"workstationClusters,omitempty"`
  1084  
  1085  	// ServerResponse contains the HTTP response code and headers from the server.
  1086  	googleapi.ServerResponse `json:"-"`
  1087  	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
  1088  	// unconditionally include in API requests. By default, fields with empty or
  1089  	// default values are omitted from API requests. See
  1090  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1091  	// details.
  1092  	ForceSendFields []string `json:"-"`
  1093  	// NullFields is a list of field names (e.g. "NextPageToken") to include in API
  1094  	// requests with the JSON null value. By default, fields with empty values are
  1095  	// omitted from API requests. See
  1096  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1097  	NullFields []string `json:"-"`
  1098  }
  1099  
  1100  func (s *ListWorkstationClustersResponse) MarshalJSON() ([]byte, error) {
  1101  	type NoMethod ListWorkstationClustersResponse
  1102  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1103  }
  1104  
  1105  // ListWorkstationConfigsResponse: Response message for ListWorkstationConfigs.
  1106  type ListWorkstationConfigsResponse struct {
  1107  	// NextPageToken: Token to retrieve the next page of results, or empty if there
  1108  	// are no more results in the list.
  1109  	NextPageToken string `json:"nextPageToken,omitempty"`
  1110  	// Unreachable: Unreachable resources.
  1111  	Unreachable []string `json:"unreachable,omitempty"`
  1112  	// WorkstationConfigs: The requested configs.
  1113  	WorkstationConfigs []*WorkstationConfig `json:"workstationConfigs,omitempty"`
  1114  
  1115  	// ServerResponse contains the HTTP response code and headers from the server.
  1116  	googleapi.ServerResponse `json:"-"`
  1117  	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
  1118  	// unconditionally include in API requests. By default, fields with empty or
  1119  	// default values are omitted from API requests. See
  1120  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1121  	// details.
  1122  	ForceSendFields []string `json:"-"`
  1123  	// NullFields is a list of field names (e.g. "NextPageToken") to include in API
  1124  	// requests with the JSON null value. By default, fields with empty values are
  1125  	// omitted from API requests. See
  1126  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1127  	NullFields []string `json:"-"`
  1128  }
  1129  
  1130  func (s *ListWorkstationConfigsResponse) MarshalJSON() ([]byte, error) {
  1131  	type NoMethod ListWorkstationConfigsResponse
  1132  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1133  }
  1134  
  1135  // ListWorkstationsResponse: Response message for ListWorkstations.
  1136  type ListWorkstationsResponse struct {
  1137  	// NextPageToken: Optional. Token to retrieve the next page of results, or
  1138  	// empty if there are no more results in the list.
  1139  	NextPageToken string `json:"nextPageToken,omitempty"`
  1140  	// Unreachable: Optional. Unreachable resources.
  1141  	Unreachable []string `json:"unreachable,omitempty"`
  1142  	// Workstations: The requested workstations.
  1143  	Workstations []*Workstation `json:"workstations,omitempty"`
  1144  
  1145  	// ServerResponse contains the HTTP response code and headers from the server.
  1146  	googleapi.ServerResponse `json:"-"`
  1147  	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
  1148  	// unconditionally include in API requests. By default, fields with empty or
  1149  	// default values are omitted from API requests. See
  1150  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1151  	// details.
  1152  	ForceSendFields []string `json:"-"`
  1153  	// NullFields is a list of field names (e.g. "NextPageToken") to include in API
  1154  	// requests with the JSON null value. By default, fields with empty values are
  1155  	// omitted from API requests. See
  1156  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1157  	NullFields []string `json:"-"`
  1158  }
  1159  
  1160  func (s *ListWorkstationsResponse) MarshalJSON() ([]byte, error) {
  1161  	type NoMethod ListWorkstationsResponse
  1162  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1163  }
  1164  
  1165  // Operation: This resource represents a long-running operation that is the
  1166  // result of a network API call.
  1167  type Operation struct {
  1168  	// Done: If the value is `false`, it means the operation is still in progress.
  1169  	// If `true`, the operation is completed, and either `error` or `response` is
  1170  	// available.
  1171  	Done bool `json:"done,omitempty"`
  1172  	// Error: The error result of the operation in case of failure or cancellation.
  1173  	Error *Status `json:"error,omitempty"`
  1174  	// Metadata: Service-specific metadata associated with the operation. It
  1175  	// typically contains progress information and common metadata such as create
  1176  	// time. Some services might not provide such metadata. Any method that returns
  1177  	// a long-running operation should document the metadata type, if any.
  1178  	Metadata googleapi.RawMessage `json:"metadata,omitempty"`
  1179  	// Name: The server-assigned name, which is only unique within the same service
  1180  	// that originally returns it. If you use the default HTTP mapping, the `name`
  1181  	// should be a resource name ending with `operations/{unique_id}`.
  1182  	Name string `json:"name,omitempty"`
  1183  	// Response: The normal, successful response of the operation. If the original
  1184  	// method returns no data on success, such as `Delete`, the response is
  1185  	// `google.protobuf.Empty`. If the original method is standard
  1186  	// `Get`/`Create`/`Update`, the response should be the resource. For other
  1187  	// methods, the response should have the type `XxxResponse`, where `Xxx` is the
  1188  	// original method name. For example, if the original method name is
  1189  	// `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.
  1190  	Response googleapi.RawMessage `json:"response,omitempty"`
  1191  
  1192  	// ServerResponse contains the HTTP response code and headers from the server.
  1193  	googleapi.ServerResponse `json:"-"`
  1194  	// ForceSendFields is a list of field names (e.g. "Done") to unconditionally
  1195  	// include in API requests. By default, fields with empty or default values are
  1196  	// omitted from API requests. See
  1197  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1198  	// details.
  1199  	ForceSendFields []string `json:"-"`
  1200  	// NullFields is a list of field names (e.g. "Done") to include in API requests
  1201  	// with the JSON null value. By default, fields with empty values are omitted
  1202  	// from API requests. See
  1203  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1204  	NullFields []string `json:"-"`
  1205  }
  1206  
  1207  func (s *Operation) MarshalJSON() ([]byte, error) {
  1208  	type NoMethod Operation
  1209  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1210  }
  1211  
  1212  // OperationMetadata: Metadata for long-running operations.
  1213  type OperationMetadata struct {
  1214  	// ApiVersion: Output only. API version used to start the operation.
  1215  	ApiVersion string `json:"apiVersion,omitempty"`
  1216  	// CreateTime: Output only. Time that the operation was created.
  1217  	CreateTime string `json:"createTime,omitempty"`
  1218  	// EndTime: Output only. Time that the operation finished running.
  1219  	EndTime string `json:"endTime,omitempty"`
  1220  	// RequestedCancellation: Output only. Identifies whether the user has
  1221  	// requested cancellation of the operation.
  1222  	RequestedCancellation bool `json:"requestedCancellation,omitempty"`
  1223  	// StatusMessage: Output only. Human-readable status of the operation, if any.
  1224  	StatusMessage string `json:"statusMessage,omitempty"`
  1225  	// Target: Output only. Server-defined resource path for the target of the
  1226  	// operation.
  1227  	Target string `json:"target,omitempty"`
  1228  	// Verb: Output only. Name of the verb executed by the operation.
  1229  	Verb string `json:"verb,omitempty"`
  1230  	// ForceSendFields is a list of field names (e.g. "ApiVersion") to
  1231  	// unconditionally include in API requests. By default, fields with empty or
  1232  	// default values are omitted from API requests. See
  1233  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1234  	// details.
  1235  	ForceSendFields []string `json:"-"`
  1236  	// NullFields is a list of field names (e.g. "ApiVersion") to include in API
  1237  	// requests with the JSON null value. By default, fields with empty values are
  1238  	// omitted from API requests. See
  1239  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1240  	NullFields []string `json:"-"`
  1241  }
  1242  
  1243  func (s *OperationMetadata) MarshalJSON() ([]byte, error) {
  1244  	type NoMethod OperationMetadata
  1245  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1246  }
  1247  
  1248  // PersistentDirectory: A directory to persist across workstation sessions.
  1249  type PersistentDirectory struct {
  1250  	// GcePd: A PersistentDirectory backed by a Compute Engine persistent disk.
  1251  	GcePd *GceRegionalPersistentDisk `json:"gcePd,omitempty"`
  1252  	// MountPath: Optional. Location of this directory in the running workstation.
  1253  	MountPath string `json:"mountPath,omitempty"`
  1254  	// ForceSendFields is a list of field names (e.g. "GcePd") to unconditionally
  1255  	// include in API requests. By default, fields with empty or default values are
  1256  	// omitted from API requests. See
  1257  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1258  	// details.
  1259  	ForceSendFields []string `json:"-"`
  1260  	// NullFields is a list of field names (e.g. "GcePd") to include in API
  1261  	// requests with the JSON null value. By default, fields with empty values are
  1262  	// omitted from API requests. See
  1263  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1264  	NullFields []string `json:"-"`
  1265  }
  1266  
  1267  func (s *PersistentDirectory) MarshalJSON() ([]byte, error) {
  1268  	type NoMethod PersistentDirectory
  1269  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1270  }
  1271  
  1272  // Policy: An Identity and Access Management (IAM) policy, which specifies
  1273  // access controls for Google Cloud resources. A `Policy` is a collection of
  1274  // `bindings`. A `binding` binds one or more `members`, or principals, to a
  1275  // single `role`. Principals can be user accounts, service accounts, Google
  1276  // groups, and domains (such as G Suite). A `role` is a named list of
  1277  // permissions; each `role` can be an IAM predefined role or a user-created
  1278  // custom role. For some types of Google Cloud resources, a `binding` can also
  1279  // specify a `condition`, which is a logical expression that allows access to a
  1280  // resource only if the expression evaluates to `true`. A condition can add
  1281  // constraints based on attributes of the request, the resource, or both. To
  1282  // learn which resources support conditions in their IAM policies, see the IAM
  1283  // documentation
  1284  // (https://cloud.google.com/iam/help/conditions/resource-policies). **JSON
  1285  // example:** ``` { "bindings": [ { "role":
  1286  // "roles/resourcemanager.organizationAdmin", "members": [
  1287  // "user:mike@example.com", "group:admins@example.com", "domain:google.com",
  1288  // "serviceAccount:my-project-id@appspot.gserviceaccount.com" ] }, { "role":
  1289  // "roles/resourcemanager.organizationViewer", "members": [
  1290  // "user:eve@example.com" ], "condition": { "title": "expirable access",
  1291  // "description": "Does not grant access after Sep 2020", "expression":
  1292  // "request.time < timestamp('2020-10-01T00:00:00.000Z')", } } ], "etag":
  1293  // "BwWWja0YfJA=", "version": 3 } ``` **YAML example:** ``` bindings: -
  1294  // members: - user:mike@example.com - group:admins@example.com -
  1295  // domain:google.com - serviceAccount:my-project-id@appspot.gserviceaccount.com
  1296  // role: roles/resourcemanager.organizationAdmin - members: -
  1297  // user:eve@example.com role: roles/resourcemanager.organizationViewer
  1298  // condition: title: expirable access description: Does not grant access after
  1299  // Sep 2020 expression: request.time < timestamp('2020-10-01T00:00:00.000Z')
  1300  // etag: BwWWja0YfJA= version: 3 ``` For a description of IAM and its features,
  1301  // see the IAM documentation (https://cloud.google.com/iam/docs/).
  1302  type Policy struct {
  1303  	// AuditConfigs: Specifies cloud audit logging configuration for this policy.
  1304  	AuditConfigs []*AuditConfig `json:"auditConfigs,omitempty"`
  1305  	// Bindings: Associates a list of `members`, or principals, with a `role`.
  1306  	// Optionally, may specify a `condition` that determines how and when the
  1307  	// `bindings` are applied. Each of the `bindings` must contain at least one
  1308  	// principal. The `bindings` in a `Policy` can refer to up to 1,500 principals;
  1309  	// up to 250 of these principals can be Google groups. Each occurrence of a
  1310  	// principal counts towards these limits. For example, if the `bindings` grant
  1311  	// 50 different roles to `user:alice@example.com`, and not to any other
  1312  	// principal, then you can add another 1,450 principals to the `bindings` in
  1313  	// the `Policy`.
  1314  	Bindings []*Binding `json:"bindings,omitempty"`
  1315  	// Etag: `etag` is used for optimistic concurrency control as a way to help
  1316  	// prevent simultaneous updates of a policy from overwriting each other. It is
  1317  	// strongly suggested that systems make use of the `etag` in the
  1318  	// read-modify-write cycle to perform policy updates in order to avoid race
  1319  	// conditions: An `etag` is returned in the response to `getIamPolicy`, and
  1320  	// systems are expected to put that etag in the request to `setIamPolicy` to
  1321  	// ensure that their change will be applied to the same version of the policy.
  1322  	// **Important:** If you use IAM Conditions, you must include the `etag` field
  1323  	// whenever you call `setIamPolicy`. If you omit this field, then IAM allows
  1324  	// you to overwrite a version `3` policy with a version `1` policy, and all of
  1325  	// the conditions in the version `3` policy are lost.
  1326  	Etag string `json:"etag,omitempty"`
  1327  	// Version: Specifies the format of the policy. Valid values are `0`, `1`, and
  1328  	// `3`. Requests that specify an invalid value are rejected. Any operation that
  1329  	// affects conditional role bindings must specify version `3`. This requirement
  1330  	// applies to the following operations: * Getting a policy that includes a
  1331  	// conditional role binding * Adding a conditional role binding to a policy *
  1332  	// Changing a conditional role binding in a policy * Removing any role binding,
  1333  	// with or without a condition, from a policy that includes conditions
  1334  	// **Important:** If you use IAM Conditions, you must include the `etag` field
  1335  	// whenever you call `setIamPolicy`. If you omit this field, then IAM allows
  1336  	// you to overwrite a version `3` policy with a version `1` policy, and all of
  1337  	// the conditions in the version `3` policy are lost. If a policy does not
  1338  	// include any conditions, operations on that policy may specify any valid
  1339  	// version or leave the field unset. To learn which resources support
  1340  	// conditions in their IAM policies, see the IAM documentation
  1341  	// (https://cloud.google.com/iam/help/conditions/resource-policies).
  1342  	Version int64 `json:"version,omitempty"`
  1343  
  1344  	// ServerResponse contains the HTTP response code and headers from the server.
  1345  	googleapi.ServerResponse `json:"-"`
  1346  	// ForceSendFields is a list of field names (e.g. "AuditConfigs") to
  1347  	// unconditionally include in API requests. By default, fields with empty or
  1348  	// default values are omitted from API requests. See
  1349  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1350  	// details.
  1351  	ForceSendFields []string `json:"-"`
  1352  	// NullFields is a list of field names (e.g. "AuditConfigs") to include in API
  1353  	// requests with the JSON null value. By default, fields with empty values are
  1354  	// omitted from API requests. See
  1355  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1356  	NullFields []string `json:"-"`
  1357  }
  1358  
  1359  func (s *Policy) MarshalJSON() ([]byte, error) {
  1360  	type NoMethod Policy
  1361  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1362  }
  1363  
  1364  // PrivateClusterConfig: Configuration options for private workstation
  1365  // clusters.
  1366  type PrivateClusterConfig struct {
  1367  	// AllowedProjects: Optional. Additional projects that are allowed to attach to
  1368  	// the workstation cluster's service attachment. By default, the workstation
  1369  	// cluster's project and the VPC host project (if different) are allowed.
  1370  	AllowedProjects []string `json:"allowedProjects,omitempty"`
  1371  	// ClusterHostname: Output only. Hostname for the workstation cluster. This
  1372  	// field will be populated only when private endpoint is enabled. To access
  1373  	// workstations in the workstation cluster, create a new DNS zone mapping this
  1374  	// domain name to an internal IP address and a forwarding rule mapping that
  1375  	// address to the service attachment.
  1376  	ClusterHostname string `json:"clusterHostname,omitempty"`
  1377  	// EnablePrivateEndpoint: Immutable. Whether Workstations endpoint is private.
  1378  	EnablePrivateEndpoint bool `json:"enablePrivateEndpoint,omitempty"`
  1379  	// ServiceAttachmentUri: Output only. Service attachment URI for the
  1380  	// workstation cluster. The service attachemnt is created when private endpoint
  1381  	// is enabled. To access workstations in the workstation cluster, configure
  1382  	// access to the managed service using Private Service Connect
  1383  	// (https://cloud.google.com/vpc/docs/configure-private-service-connect-services).
  1384  	ServiceAttachmentUri string `json:"serviceAttachmentUri,omitempty"`
  1385  	// ForceSendFields is a list of field names (e.g. "AllowedProjects") to
  1386  	// unconditionally include in API requests. By default, fields with empty or
  1387  	// default values are omitted from API requests. See
  1388  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1389  	// details.
  1390  	ForceSendFields []string `json:"-"`
  1391  	// NullFields is a list of field names (e.g. "AllowedProjects") to include in
  1392  	// API requests with the JSON null value. By default, fields with empty values
  1393  	// are omitted from API requests. See
  1394  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1395  	NullFields []string `json:"-"`
  1396  }
  1397  
  1398  func (s *PrivateClusterConfig) MarshalJSON() ([]byte, error) {
  1399  	type NoMethod PrivateClusterConfig
  1400  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1401  }
  1402  
  1403  // ReadinessCheck: A readiness check to be performed on a workstation.
  1404  type ReadinessCheck struct {
  1405  	// Path: Optional. Path to which the request should be sent.
  1406  	Path string `json:"path,omitempty"`
  1407  	// Port: Optional. Port to which the request should be sent.
  1408  	Port int64 `json:"port,omitempty"`
  1409  	// ForceSendFields is a list of field names (e.g. "Path") to unconditionally
  1410  	// include in API requests. By default, fields with empty or default values are
  1411  	// omitted from API requests. See
  1412  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1413  	// details.
  1414  	ForceSendFields []string `json:"-"`
  1415  	// NullFields is a list of field names (e.g. "Path") to include in API requests
  1416  	// with the JSON null value. By default, fields with empty values are omitted
  1417  	// from API requests. See
  1418  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1419  	NullFields []string `json:"-"`
  1420  }
  1421  
  1422  func (s *ReadinessCheck) MarshalJSON() ([]byte, error) {
  1423  	type NoMethod ReadinessCheck
  1424  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1425  }
  1426  
  1427  // SetIamPolicyRequest: Request message for `SetIamPolicy` method.
  1428  type SetIamPolicyRequest struct {
  1429  	// Policy: REQUIRED: The complete policy to be applied to the `resource`. The
  1430  	// size of the policy is limited to a few 10s of KB. An empty policy is a valid
  1431  	// policy but certain Google Cloud services (such as Projects) might reject
  1432  	// them.
  1433  	Policy *Policy `json:"policy,omitempty"`
  1434  	// UpdateMask: OPTIONAL: A FieldMask specifying which fields of the policy to
  1435  	// modify. Only the fields in the mask will be modified. If no mask is
  1436  	// provided, the following default mask is used: `paths: "bindings, etag"
  1437  	UpdateMask string `json:"updateMask,omitempty"`
  1438  	// ForceSendFields is a list of field names (e.g. "Policy") to unconditionally
  1439  	// include in API requests. By default, fields with empty or default values are
  1440  	// omitted from API requests. See
  1441  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1442  	// details.
  1443  	ForceSendFields []string `json:"-"`
  1444  	// NullFields is a list of field names (e.g. "Policy") to include in API
  1445  	// requests with the JSON null value. By default, fields with empty values are
  1446  	// omitted from API requests. See
  1447  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1448  	NullFields []string `json:"-"`
  1449  }
  1450  
  1451  func (s *SetIamPolicyRequest) MarshalJSON() ([]byte, error) {
  1452  	type NoMethod SetIamPolicyRequest
  1453  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1454  }
  1455  
  1456  // StartWorkstationRequest: Request message for StartWorkstation.
  1457  type StartWorkstationRequest struct {
  1458  	// BoostConfig: Optional. If set, the workstation starts using the boost
  1459  	// configuration with the specified ID.
  1460  	BoostConfig string `json:"boostConfig,omitempty"`
  1461  	// Etag: Optional. If set, the request will be rejected if the latest version
  1462  	// of the workstation on the server does not have this ETag.
  1463  	Etag string `json:"etag,omitempty"`
  1464  	// ValidateOnly: Optional. If set, validate the request and preview the review,
  1465  	// but do not actually apply it.
  1466  	ValidateOnly bool `json:"validateOnly,omitempty"`
  1467  	// ForceSendFields is a list of field names (e.g. "BoostConfig") to
  1468  	// unconditionally include in API requests. By default, fields with empty or
  1469  	// default values are omitted from API requests. See
  1470  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1471  	// details.
  1472  	ForceSendFields []string `json:"-"`
  1473  	// NullFields is a list of field names (e.g. "BoostConfig") to include in API
  1474  	// requests with the JSON null value. By default, fields with empty values are
  1475  	// omitted from API requests. See
  1476  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1477  	NullFields []string `json:"-"`
  1478  }
  1479  
  1480  func (s *StartWorkstationRequest) MarshalJSON() ([]byte, error) {
  1481  	type NoMethod StartWorkstationRequest
  1482  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1483  }
  1484  
  1485  // Status: The `Status` type defines a logical error model that is suitable for
  1486  // different programming environments, including REST APIs and RPC APIs. It is
  1487  // used by gRPC (https://github.com/grpc). Each `Status` message contains three
  1488  // pieces of data: error code, error message, and error details. You can find
  1489  // out more about this error model and how to work with it in the API Design
  1490  // Guide (https://cloud.google.com/apis/design/errors).
  1491  type Status struct {
  1492  	// Code: The status code, which should be an enum value of google.rpc.Code.
  1493  	Code int64 `json:"code,omitempty"`
  1494  	// Details: A list of messages that carry the error details. There is a common
  1495  	// set of message types for APIs to use.
  1496  	Details []googleapi.RawMessage `json:"details,omitempty"`
  1497  	// Message: A developer-facing error message, which should be in English. Any
  1498  	// user-facing error message should be localized and sent in the
  1499  	// google.rpc.Status.details field, or localized by the client.
  1500  	Message string `json:"message,omitempty"`
  1501  	// ForceSendFields is a list of field names (e.g. "Code") to unconditionally
  1502  	// include in API requests. By default, fields with empty or default values are
  1503  	// omitted from API requests. See
  1504  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1505  	// details.
  1506  	ForceSendFields []string `json:"-"`
  1507  	// NullFields is a list of field names (e.g. "Code") to include in API requests
  1508  	// with the JSON null value. By default, fields with empty values are omitted
  1509  	// from API requests. See
  1510  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1511  	NullFields []string `json:"-"`
  1512  }
  1513  
  1514  func (s *Status) MarshalJSON() ([]byte, error) {
  1515  	type NoMethod Status
  1516  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1517  }
  1518  
  1519  // StopWorkstationRequest: Request message for StopWorkstation.
  1520  type StopWorkstationRequest struct {
  1521  	// Etag: Optional. If set, the request will be rejected if the latest version
  1522  	// of the workstation on the server does not have this ETag.
  1523  	Etag string `json:"etag,omitempty"`
  1524  	// ValidateOnly: Optional. If set, validate the request and preview the review,
  1525  	// but do not actually apply it.
  1526  	ValidateOnly bool `json:"validateOnly,omitempty"`
  1527  	// ForceSendFields is a list of field names (e.g. "Etag") to unconditionally
  1528  	// include in API requests. By default, fields with empty or default values are
  1529  	// omitted from API requests. See
  1530  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1531  	// details.
  1532  	ForceSendFields []string `json:"-"`
  1533  	// NullFields is a list of field names (e.g. "Etag") to include in API requests
  1534  	// with the JSON null value. By default, fields with empty values are omitted
  1535  	// from API requests. See
  1536  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1537  	NullFields []string `json:"-"`
  1538  }
  1539  
  1540  func (s *StopWorkstationRequest) MarshalJSON() ([]byte, error) {
  1541  	type NoMethod StopWorkstationRequest
  1542  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1543  }
  1544  
  1545  // TestIamPermissionsRequest: Request message for `TestIamPermissions` method.
  1546  type TestIamPermissionsRequest struct {
  1547  	// Permissions: The set of permissions to check for the `resource`. Permissions
  1548  	// with wildcards (such as `*` or `storage.*`) are not allowed. For more
  1549  	// information see IAM Overview
  1550  	// (https://cloud.google.com/iam/docs/overview#permissions).
  1551  	Permissions []string `json:"permissions,omitempty"`
  1552  	// ForceSendFields is a list of field names (e.g. "Permissions") to
  1553  	// unconditionally include in API requests. By default, fields with empty or
  1554  	// default values are omitted from API requests. See
  1555  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1556  	// details.
  1557  	ForceSendFields []string `json:"-"`
  1558  	// NullFields is a list of field names (e.g. "Permissions") to include in API
  1559  	// requests with the JSON null value. By default, fields with empty values are
  1560  	// omitted from API requests. See
  1561  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1562  	NullFields []string `json:"-"`
  1563  }
  1564  
  1565  func (s *TestIamPermissionsRequest) MarshalJSON() ([]byte, error) {
  1566  	type NoMethod TestIamPermissionsRequest
  1567  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1568  }
  1569  
  1570  // TestIamPermissionsResponse: Response message for `TestIamPermissions`
  1571  // method.
  1572  type TestIamPermissionsResponse struct {
  1573  	// Permissions: A subset of `TestPermissionsRequest.permissions` that the
  1574  	// caller is allowed.
  1575  	Permissions []string `json:"permissions,omitempty"`
  1576  
  1577  	// ServerResponse contains the HTTP response code and headers from the server.
  1578  	googleapi.ServerResponse `json:"-"`
  1579  	// ForceSendFields is a list of field names (e.g. "Permissions") to
  1580  	// unconditionally include in API requests. By default, fields with empty or
  1581  	// default values are omitted from API requests. See
  1582  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1583  	// details.
  1584  	ForceSendFields []string `json:"-"`
  1585  	// NullFields is a list of field names (e.g. "Permissions") to include in API
  1586  	// requests with the JSON null value. By default, fields with empty values are
  1587  	// omitted from API requests. See
  1588  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1589  	NullFields []string `json:"-"`
  1590  }
  1591  
  1592  func (s *TestIamPermissionsResponse) MarshalJSON() ([]byte, error) {
  1593  	type NoMethod TestIamPermissionsResponse
  1594  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1595  }
  1596  
  1597  // Workstation: A single instance of a developer workstation with its own
  1598  // persistent storage.
  1599  type Workstation struct {
  1600  	// Annotations: Optional. Client-specified annotations.
  1601  	Annotations map[string]string `json:"annotations,omitempty"`
  1602  	// CreateTime: Output only. Time when this workstation was created.
  1603  	CreateTime string `json:"createTime,omitempty"`
  1604  	// DeleteTime: Output only. Time when this workstation was soft-deleted.
  1605  	DeleteTime string `json:"deleteTime,omitempty"`
  1606  	// DisplayName: Optional. Human-readable name for this workstation.
  1607  	DisplayName string `json:"displayName,omitempty"`
  1608  	// Env: Optional. Environment variables passed to the workstation container's
  1609  	// entrypoint.
  1610  	Env map[string]string `json:"env,omitempty"`
  1611  	// Etag: Optional. Checksum computed by the server. May be sent on update and
  1612  	// delete requests to make sure that the client has an up-to-date value before
  1613  	// proceeding.
  1614  	Etag string `json:"etag,omitempty"`
  1615  	// Host: Output only. Host to which clients can send HTTPS traffic that will be
  1616  	// received by the workstation. Authorized traffic will be received to the
  1617  	// workstation as HTTP on port 80. To send traffic to a different port, clients
  1618  	// may prefix the host with the destination port in the format `{port}-{host}`.
  1619  	Host string `json:"host,omitempty"`
  1620  	// KmsKey: Output only. The name of the Google Cloud KMS encryption key used to
  1621  	// encrypt this workstation. The KMS key can only be configured in the
  1622  	// WorkstationConfig. The expected format is
  1623  	// `projects/*/locations/*/keyRings/*/cryptoKeys/*`.
  1624  	KmsKey string `json:"kmsKey,omitempty"`
  1625  	// Labels: Optional. Labels
  1626  	// (https://cloud.google.com/workstations/docs/label-resources) that are
  1627  	// applied to the workstation and that are also propagated to the underlying
  1628  	// Compute Engine resources.
  1629  	Labels map[string]string `json:"labels,omitempty"`
  1630  	// Name: Identifier. Full name of this workstation.
  1631  	Name string `json:"name,omitempty"`
  1632  	// Reconciling: Output only. Indicates whether this workstation is currently
  1633  	// being updated to match its intended state.
  1634  	Reconciling bool `json:"reconciling,omitempty"`
  1635  	// StartTime: Output only. Time when this workstation was most recently
  1636  	// successfully started, regardless of the workstation's initial state.
  1637  	StartTime string `json:"startTime,omitempty"`
  1638  	// State: Output only. Current state of the workstation.
  1639  	//
  1640  	// Possible values:
  1641  	//   "STATE_UNSPECIFIED" - Do not use.
  1642  	//   "STATE_STARTING" - The workstation is not yet ready to accept requests
  1643  	// from users but will be soon.
  1644  	//   "STATE_RUNNING" - The workstation is ready to accept requests from users.
  1645  	//   "STATE_STOPPING" - The workstation is being stopped.
  1646  	//   "STATE_STOPPED" - The workstation is stopped and will not be able to
  1647  	// receive requests until it is started.
  1648  	State string `json:"state,omitempty"`
  1649  	// Uid: Output only. A system-assigned unique identifier for this workstation.
  1650  	Uid string `json:"uid,omitempty"`
  1651  	// UpdateTime: Output only. Time when this workstation was most recently
  1652  	// updated.
  1653  	UpdateTime string `json:"updateTime,omitempty"`
  1654  
  1655  	// ServerResponse contains the HTTP response code and headers from the server.
  1656  	googleapi.ServerResponse `json:"-"`
  1657  	// ForceSendFields is a list of field names (e.g. "Annotations") to
  1658  	// unconditionally include in API requests. By default, fields with empty or
  1659  	// default values are omitted from API requests. See
  1660  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1661  	// details.
  1662  	ForceSendFields []string `json:"-"`
  1663  	// NullFields is a list of field names (e.g. "Annotations") to include in API
  1664  	// requests with the JSON null value. By default, fields with empty values are
  1665  	// omitted from API requests. See
  1666  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1667  	NullFields []string `json:"-"`
  1668  }
  1669  
  1670  func (s *Workstation) MarshalJSON() ([]byte, error) {
  1671  	type NoMethod Workstation
  1672  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1673  }
  1674  
  1675  // WorkstationCluster: A workstation cluster resource in the Cloud Workstations
  1676  // API. Defines a group of workstations in a particular region and the VPC
  1677  // network they're attached to.
  1678  type WorkstationCluster struct {
  1679  	// Annotations: Optional. Client-specified annotations.
  1680  	Annotations map[string]string `json:"annotations,omitempty"`
  1681  	// Conditions: Output only. Status conditions describing the workstation
  1682  	// cluster's current state.
  1683  	Conditions []*Status `json:"conditions,omitempty"`
  1684  	// ControlPlaneIp: Output only. The private IP address of the control plane for
  1685  	// this workstation cluster. Workstation VMs need access to this IP address to
  1686  	// work with the service, so make sure that your firewall rules allow egress
  1687  	// from the workstation VMs to this address.
  1688  	ControlPlaneIp string `json:"controlPlaneIp,omitempty"`
  1689  	// CreateTime: Output only. Time when this workstation cluster was created.
  1690  	CreateTime string `json:"createTime,omitempty"`
  1691  	// Degraded: Output only. Whether this workstation cluster is in degraded mode,
  1692  	// in which case it may require user action to restore full functionality.
  1693  	// Details can be found in conditions.
  1694  	Degraded bool `json:"degraded,omitempty"`
  1695  	// DeleteTime: Output only. Time when this workstation cluster was
  1696  	// soft-deleted.
  1697  	DeleteTime string `json:"deleteTime,omitempty"`
  1698  	// DisplayName: Optional. Human-readable name for this workstation cluster.
  1699  	DisplayName string `json:"displayName,omitempty"`
  1700  	// DomainConfig: Optional. Configuration options for a custom domain.
  1701  	DomainConfig *DomainConfig `json:"domainConfig,omitempty"`
  1702  	// Etag: Optional. Checksum computed by the server. May be sent on update and
  1703  	// delete requests to make sure that the client has an up-to-date value before
  1704  	// proceeding.
  1705  	Etag string `json:"etag,omitempty"`
  1706  	// Labels: Optional. Labels
  1707  	// (https://cloud.google.com/workstations/docs/label-resources) that are
  1708  	// applied to the workstation cluster and that are also propagated to the
  1709  	// underlying Compute Engine resources.
  1710  	Labels map[string]string `json:"labels,omitempty"`
  1711  	// Name: Identifier. Full name of this workstation cluster.
  1712  	Name string `json:"name,omitempty"`
  1713  	// Network: Immutable. Name of the Compute Engine network in which instances
  1714  	// associated with this workstation cluster will be created.
  1715  	Network string `json:"network,omitempty"`
  1716  	// PrivateClusterConfig: Optional. Configuration for private workstation
  1717  	// cluster.
  1718  	PrivateClusterConfig *PrivateClusterConfig `json:"privateClusterConfig,omitempty"`
  1719  	// Reconciling: Output only. Indicates whether this workstation cluster is
  1720  	// currently being updated to match its intended state.
  1721  	Reconciling bool `json:"reconciling,omitempty"`
  1722  	// Subnetwork: Immutable. Name of the Compute Engine subnetwork in which
  1723  	// instances associated with this workstation cluster will be created. Must be
  1724  	// part of the subnetwork specified for this workstation cluster.
  1725  	Subnetwork string `json:"subnetwork,omitempty"`
  1726  	// Uid: Output only. A system-assigned unique identifier for this workstation
  1727  	// cluster.
  1728  	Uid string `json:"uid,omitempty"`
  1729  	// UpdateTime: Output only. Time when this workstation cluster was most
  1730  	// recently updated.
  1731  	UpdateTime string `json:"updateTime,omitempty"`
  1732  
  1733  	// ServerResponse contains the HTTP response code and headers from the server.
  1734  	googleapi.ServerResponse `json:"-"`
  1735  	// ForceSendFields is a list of field names (e.g. "Annotations") to
  1736  	// unconditionally include in API requests. By default, fields with empty or
  1737  	// default values are omitted from API requests. See
  1738  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1739  	// details.
  1740  	ForceSendFields []string `json:"-"`
  1741  	// NullFields is a list of field names (e.g. "Annotations") to include in API
  1742  	// requests with the JSON null value. By default, fields with empty values are
  1743  	// omitted from API requests. See
  1744  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1745  	NullFields []string `json:"-"`
  1746  }
  1747  
  1748  func (s *WorkstationCluster) MarshalJSON() ([]byte, error) {
  1749  	type NoMethod WorkstationCluster
  1750  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1751  }
  1752  
  1753  // WorkstationConfig: A workstation configuration resource in the Cloud
  1754  // Workstations API. Workstation configurations act as templates for
  1755  // workstations. The workstation configuration defines details such as the
  1756  // workstation virtual machine (VM) instance type, persistent storage,
  1757  // container image defining environment, which IDE or Code Editor to use, and
  1758  // more. Administrators and platform teams can also use Identity and Access
  1759  // Management (IAM) (https://cloud.google.com/iam/docs/overview) rules to grant
  1760  // access to teams or to individual developers.
  1761  type WorkstationConfig struct {
  1762  	// Annotations: Optional. Client-specified annotations.
  1763  	Annotations map[string]string `json:"annotations,omitempty"`
  1764  	// Conditions: Output only. Status conditions describing the current resource
  1765  	// state.
  1766  	Conditions []*Status `json:"conditions,omitempty"`
  1767  	// Container: Optional. Container that runs upon startup for each workstation
  1768  	// using this workstation configuration.
  1769  	Container *Container `json:"container,omitempty"`
  1770  	// CreateTime: Output only. Time when this workstation configuration was
  1771  	// created.
  1772  	CreateTime string `json:"createTime,omitempty"`
  1773  	// Degraded: Output only. Whether this resource is degraded, in which case it
  1774  	// may require user action to restore full functionality. See also the
  1775  	// conditions field.
  1776  	Degraded bool `json:"degraded,omitempty"`
  1777  	// DeleteTime: Output only. Time when this workstation configuration was
  1778  	// soft-deleted.
  1779  	DeleteTime string `json:"deleteTime,omitempty"`
  1780  	// DisableTcpConnections: Optional. Disables support for plain TCP connections
  1781  	// in the workstation. By default the service supports TCP connections through
  1782  	// a websocket relay. Setting this option to true disables that relay, which
  1783  	// prevents the usage of services that require plain TCP connections, such as
  1784  	// SSH. When enabled, all communication must occur over HTTPS or WSS.
  1785  	DisableTcpConnections bool `json:"disableTcpConnections,omitempty"`
  1786  	// DisplayName: Optional. Human-readable name for this workstation
  1787  	// configuration.
  1788  	DisplayName string `json:"displayName,omitempty"`
  1789  	// EnableAuditAgent: Optional. Whether to enable Linux `auditd` logging on the
  1790  	// workstation. When enabled, a service account must also be specified that has
  1791  	// `logging.buckets.write` permission on the project. Operating system audit
  1792  	// logging is distinct from Cloud Audit Logs
  1793  	// (https://cloud.google.com/workstations/docs/audit-logging).
  1794  	EnableAuditAgent bool `json:"enableAuditAgent,omitempty"`
  1795  	// EncryptionKey: Immutable. Encrypts resources of this workstation
  1796  	// configuration using a customer-managed encryption key (CMEK). If specified,
  1797  	// the boot disk of the Compute Engine instance and the persistent disk are
  1798  	// encrypted using this encryption key. If this field is not set, the disks are
  1799  	// encrypted using a generated key. Customer-managed encryption keys do not
  1800  	// protect disk metadata. If the customer-managed encryption key is rotated,
  1801  	// when the workstation instance is stopped, the system attempts to recreate
  1802  	// the persistent disk with the new version of the key. Be sure to keep older
  1803  	// versions of the key until the persistent disk is recreated. Otherwise, data
  1804  	// on the persistent disk might be lost. If the encryption key is revoked, the
  1805  	// workstation session automatically stops within 7 hours. Immutable after the
  1806  	// workstation configuration is created.
  1807  	EncryptionKey *CustomerEncryptionKey `json:"encryptionKey,omitempty"`
  1808  	// EphemeralDirectories: Optional. Ephemeral directories which won't persist
  1809  	// across workstation sessions.
  1810  	EphemeralDirectories []*EphemeralDirectory `json:"ephemeralDirectories,omitempty"`
  1811  	// Etag: Optional. Checksum computed by the server. May be sent on update and
  1812  	// delete requests to make sure that the client has an up-to-date value before
  1813  	// proceeding.
  1814  	Etag string `json:"etag,omitempty"`
  1815  	// Host: Optional. Runtime host for the workstation.
  1816  	Host *Host `json:"host,omitempty"`
  1817  	// IdleTimeout: Optional. Number of seconds to wait before automatically
  1818  	// stopping a workstation after it last received user traffic. A value of
  1819  	// "0s" indicates that Cloud Workstations VMs created with this configuration
  1820  	// should never time out due to idleness. Provide duration
  1821  	// (https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#duration)
  1822  	// terminated by `s` for secondsā€”for example, "7200s" (2 hours). The
  1823  	// default is "1200s" (20 minutes).
  1824  	IdleTimeout string `json:"idleTimeout,omitempty"`
  1825  	// Labels: Optional. Labels
  1826  	// (https://cloud.google.com/workstations/docs/label-resources) that are
  1827  	// applied to the workstation configuration and that are also propagated to the
  1828  	// underlying Compute Engine resources.
  1829  	Labels map[string]string `json:"labels,omitempty"`
  1830  	// Name: Identifier. Full name of this workstation configuration.
  1831  	Name string `json:"name,omitempty"`
  1832  	// PersistentDirectories: Optional. Directories to persist across workstation
  1833  	// sessions.
  1834  	PersistentDirectories []*PersistentDirectory `json:"persistentDirectories,omitempty"`
  1835  	// ReadinessChecks: Optional. Readiness checks to perform when starting a
  1836  	// workstation using this workstation configuration. Mark a workstation as
  1837  	// running only after all specified readiness checks return 200 status codes.
  1838  	ReadinessChecks []*ReadinessCheck `json:"readinessChecks,omitempty"`
  1839  	// Reconciling: Output only. Indicates whether this workstation configuration
  1840  	// is currently being updated to match its intended state.
  1841  	Reconciling bool `json:"reconciling,omitempty"`
  1842  	// ReplicaZones: Optional. Immutable. Specifies the zones used to replicate the
  1843  	// VM and disk resources within the region. If set, exactly two zones within
  1844  	// the workstation cluster's region must be specifiedā€”for example,
  1845  	// `['us-central1-a', 'us-central1-f']`. If this field is empty, two default
  1846  	// zones within the region are used. Immutable after the workstation
  1847  	// configuration is created.
  1848  	ReplicaZones []string `json:"replicaZones,omitempty"`
  1849  	// RunningTimeout: Optional. Number of seconds that a workstation can run until
  1850  	// it is automatically shut down. We recommend that workstations be shut down
  1851  	// daily to reduce costs and so that security updates can be applied upon
  1852  	// restart. The idle_timeout and running_timeout fields are independent of each
  1853  	// other. Note that the running_timeout field shuts down VMs after the
  1854  	// specified time, regardless of whether or not the VMs are idle. Provide
  1855  	// duration terminated by `s` for secondsā€”for example, "54000s" (15 hours).
  1856  	// Defaults to "43200s" (12 hours). A value of "0s" indicates that
  1857  	// workstations using this configuration should never time out. If
  1858  	// encryption_key is set, it must be greater than "0s" and less than
  1859  	// "86400s" (24 hours). Warning: A value of "0s" indicates that Cloud
  1860  	// Workstations VMs created with this configuration have no maximum running
  1861  	// time. This is strongly discouraged because you incur costs and will not pick
  1862  	// up security updates.
  1863  	RunningTimeout string `json:"runningTimeout,omitempty"`
  1864  	// Uid: Output only. A system-assigned unique identifier for this workstation
  1865  	// configuration.
  1866  	Uid string `json:"uid,omitempty"`
  1867  	// UpdateTime: Output only. Time when this workstation configuration was most
  1868  	// recently updated.
  1869  	UpdateTime string `json:"updateTime,omitempty"`
  1870  
  1871  	// ServerResponse contains the HTTP response code and headers from the server.
  1872  	googleapi.ServerResponse `json:"-"`
  1873  	// ForceSendFields is a list of field names (e.g. "Annotations") to
  1874  	// unconditionally include in API requests. By default, fields with empty or
  1875  	// default values are omitted from API requests. See
  1876  	// https://pkg.go.dev/google.golang.org/api#hdr-ForceSendFields for more
  1877  	// details.
  1878  	ForceSendFields []string `json:"-"`
  1879  	// NullFields is a list of field names (e.g. "Annotations") to include in API
  1880  	// requests with the JSON null value. By default, fields with empty values are
  1881  	// omitted from API requests. See
  1882  	// https://pkg.go.dev/google.golang.org/api#hdr-NullFields for more details.
  1883  	NullFields []string `json:"-"`
  1884  }
  1885  
  1886  func (s *WorkstationConfig) MarshalJSON() ([]byte, error) {
  1887  	type NoMethod WorkstationConfig
  1888  	return gensupport.MarshalJSON(NoMethod(*s), s.ForceSendFields, s.NullFields)
  1889  }
  1890  
  1891  type ProjectsLocationsOperationsCancelCall struct {
  1892  	s                      *Service
  1893  	name                   string
  1894  	canceloperationrequest *CancelOperationRequest
  1895  	urlParams_             gensupport.URLParams
  1896  	ctx_                   context.Context
  1897  	header_                http.Header
  1898  }
  1899  
  1900  // Cancel: Starts asynchronous cancellation on a long-running operation. The
  1901  // server makes a best effort to cancel the operation, but success is not
  1902  // guaranteed. If the server doesn't support this method, it returns
  1903  // `google.rpc.Code.UNIMPLEMENTED`. Clients can use Operations.GetOperation or
  1904  // other methods to check whether the cancellation succeeded or whether the
  1905  // operation completed despite cancellation. On successful cancellation, the
  1906  // operation is not deleted; instead, it becomes an operation with an
  1907  // Operation.error value with a google.rpc.Status.code of 1, corresponding to
  1908  // `Code.CANCELLED`.
  1909  //
  1910  // - name: The name of the operation resource to be cancelled.
  1911  func (r *ProjectsLocationsOperationsService) Cancel(name string, canceloperationrequest *CancelOperationRequest) *ProjectsLocationsOperationsCancelCall {
  1912  	c := &ProjectsLocationsOperationsCancelCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  1913  	c.name = name
  1914  	c.canceloperationrequest = canceloperationrequest
  1915  	return c
  1916  }
  1917  
  1918  // Fields allows partial responses to be retrieved. See
  1919  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  1920  // details.
  1921  func (c *ProjectsLocationsOperationsCancelCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsCancelCall {
  1922  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  1923  	return c
  1924  }
  1925  
  1926  // Context sets the context to be used in this call's Do method.
  1927  func (c *ProjectsLocationsOperationsCancelCall) Context(ctx context.Context) *ProjectsLocationsOperationsCancelCall {
  1928  	c.ctx_ = ctx
  1929  	return c
  1930  }
  1931  
  1932  // Header returns a http.Header that can be modified by the caller to add
  1933  // headers to the request.
  1934  func (c *ProjectsLocationsOperationsCancelCall) Header() http.Header {
  1935  	if c.header_ == nil {
  1936  		c.header_ = make(http.Header)
  1937  	}
  1938  	return c.header_
  1939  }
  1940  
  1941  func (c *ProjectsLocationsOperationsCancelCall) doRequest(alt string) (*http.Response, error) {
  1942  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  1943  	var body io.Reader = nil
  1944  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.canceloperationrequest)
  1945  	if err != nil {
  1946  		return nil, err
  1947  	}
  1948  	c.urlParams_.Set("alt", alt)
  1949  	c.urlParams_.Set("prettyPrint", "false")
  1950  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}:cancel")
  1951  	urls += "?" + c.urlParams_.Encode()
  1952  	req, err := http.NewRequest("POST", urls, body)
  1953  	if err != nil {
  1954  		return nil, err
  1955  	}
  1956  	req.Header = reqHeaders
  1957  	googleapi.Expand(req.URL, map[string]string{
  1958  		"name": c.name,
  1959  	})
  1960  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  1961  }
  1962  
  1963  // Do executes the "workstations.projects.locations.operations.cancel" call.
  1964  // Any non-2xx status code is an error. Response headers are in either
  1965  // *GoogleProtobufEmpty.ServerResponse.Header or (if a response was returned at
  1966  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  1967  // check whether the returned error was because http.StatusNotModified was
  1968  // returned.
  1969  func (c *ProjectsLocationsOperationsCancelCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
  1970  	gensupport.SetOptions(c.urlParams_, opts...)
  1971  	res, err := c.doRequest("json")
  1972  	if res != nil && res.StatusCode == http.StatusNotModified {
  1973  		if res.Body != nil {
  1974  			res.Body.Close()
  1975  		}
  1976  		return nil, gensupport.WrapError(&googleapi.Error{
  1977  			Code:   res.StatusCode,
  1978  			Header: res.Header,
  1979  		})
  1980  	}
  1981  	if err != nil {
  1982  		return nil, err
  1983  	}
  1984  	defer googleapi.CloseBody(res)
  1985  	if err := googleapi.CheckResponse(res); err != nil {
  1986  		return nil, gensupport.WrapError(err)
  1987  	}
  1988  	ret := &GoogleProtobufEmpty{
  1989  		ServerResponse: googleapi.ServerResponse{
  1990  			Header:         res.Header,
  1991  			HTTPStatusCode: res.StatusCode,
  1992  		},
  1993  	}
  1994  	target := &ret
  1995  	if err := gensupport.DecodeResponse(target, res); err != nil {
  1996  		return nil, err
  1997  	}
  1998  	return ret, nil
  1999  }
  2000  
  2001  type ProjectsLocationsOperationsDeleteCall struct {
  2002  	s          *Service
  2003  	name       string
  2004  	urlParams_ gensupport.URLParams
  2005  	ctx_       context.Context
  2006  	header_    http.Header
  2007  }
  2008  
  2009  // Delete: Deletes a long-running operation. This method indicates that the
  2010  // client is no longer interested in the operation result. It does not cancel
  2011  // the operation. If the server doesn't support this method, it returns
  2012  // `google.rpc.Code.UNIMPLEMENTED`.
  2013  //
  2014  // - name: The name of the operation resource to be deleted.
  2015  func (r *ProjectsLocationsOperationsService) Delete(name string) *ProjectsLocationsOperationsDeleteCall {
  2016  	c := &ProjectsLocationsOperationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2017  	c.name = name
  2018  	return c
  2019  }
  2020  
  2021  // Fields allows partial responses to be retrieved. See
  2022  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2023  // details.
  2024  func (c *ProjectsLocationsOperationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsDeleteCall {
  2025  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2026  	return c
  2027  }
  2028  
  2029  // Context sets the context to be used in this call's Do method.
  2030  func (c *ProjectsLocationsOperationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsOperationsDeleteCall {
  2031  	c.ctx_ = ctx
  2032  	return c
  2033  }
  2034  
  2035  // Header returns a http.Header that can be modified by the caller to add
  2036  // headers to the request.
  2037  func (c *ProjectsLocationsOperationsDeleteCall) Header() http.Header {
  2038  	if c.header_ == nil {
  2039  		c.header_ = make(http.Header)
  2040  	}
  2041  	return c.header_
  2042  }
  2043  
  2044  func (c *ProjectsLocationsOperationsDeleteCall) doRequest(alt string) (*http.Response, error) {
  2045  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2046  	var body io.Reader = nil
  2047  	c.urlParams_.Set("alt", alt)
  2048  	c.urlParams_.Set("prettyPrint", "false")
  2049  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  2050  	urls += "?" + c.urlParams_.Encode()
  2051  	req, err := http.NewRequest("DELETE", urls, body)
  2052  	if err != nil {
  2053  		return nil, err
  2054  	}
  2055  	req.Header = reqHeaders
  2056  	googleapi.Expand(req.URL, map[string]string{
  2057  		"name": c.name,
  2058  	})
  2059  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2060  }
  2061  
  2062  // Do executes the "workstations.projects.locations.operations.delete" call.
  2063  // Any non-2xx status code is an error. Response headers are in either
  2064  // *GoogleProtobufEmpty.ServerResponse.Header or (if a response was returned at
  2065  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  2066  // check whether the returned error was because http.StatusNotModified was
  2067  // returned.
  2068  func (c *ProjectsLocationsOperationsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
  2069  	gensupport.SetOptions(c.urlParams_, opts...)
  2070  	res, err := c.doRequest("json")
  2071  	if res != nil && res.StatusCode == http.StatusNotModified {
  2072  		if res.Body != nil {
  2073  			res.Body.Close()
  2074  		}
  2075  		return nil, gensupport.WrapError(&googleapi.Error{
  2076  			Code:   res.StatusCode,
  2077  			Header: res.Header,
  2078  		})
  2079  	}
  2080  	if err != nil {
  2081  		return nil, err
  2082  	}
  2083  	defer googleapi.CloseBody(res)
  2084  	if err := googleapi.CheckResponse(res); err != nil {
  2085  		return nil, gensupport.WrapError(err)
  2086  	}
  2087  	ret := &GoogleProtobufEmpty{
  2088  		ServerResponse: googleapi.ServerResponse{
  2089  			Header:         res.Header,
  2090  			HTTPStatusCode: res.StatusCode,
  2091  		},
  2092  	}
  2093  	target := &ret
  2094  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2095  		return nil, err
  2096  	}
  2097  	return ret, nil
  2098  }
  2099  
  2100  type ProjectsLocationsOperationsGetCall struct {
  2101  	s            *Service
  2102  	name         string
  2103  	urlParams_   gensupport.URLParams
  2104  	ifNoneMatch_ string
  2105  	ctx_         context.Context
  2106  	header_      http.Header
  2107  }
  2108  
  2109  // Get: Gets the latest state of a long-running operation. Clients can use this
  2110  // method to poll the operation result at intervals as recommended by the API
  2111  // service.
  2112  //
  2113  // - name: The name of the operation resource.
  2114  func (r *ProjectsLocationsOperationsService) Get(name string) *ProjectsLocationsOperationsGetCall {
  2115  	c := &ProjectsLocationsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2116  	c.name = name
  2117  	return c
  2118  }
  2119  
  2120  // Fields allows partial responses to be retrieved. See
  2121  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2122  // details.
  2123  func (c *ProjectsLocationsOperationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsGetCall {
  2124  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2125  	return c
  2126  }
  2127  
  2128  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  2129  // object's ETag matches the given value. This is useful for getting updates
  2130  // only after the object has changed since the last request.
  2131  func (c *ProjectsLocationsOperationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsGetCall {
  2132  	c.ifNoneMatch_ = entityTag
  2133  	return c
  2134  }
  2135  
  2136  // Context sets the context to be used in this call's Do method.
  2137  func (c *ProjectsLocationsOperationsGetCall) Context(ctx context.Context) *ProjectsLocationsOperationsGetCall {
  2138  	c.ctx_ = ctx
  2139  	return c
  2140  }
  2141  
  2142  // Header returns a http.Header that can be modified by the caller to add
  2143  // headers to the request.
  2144  func (c *ProjectsLocationsOperationsGetCall) Header() http.Header {
  2145  	if c.header_ == nil {
  2146  		c.header_ = make(http.Header)
  2147  	}
  2148  	return c.header_
  2149  }
  2150  
  2151  func (c *ProjectsLocationsOperationsGetCall) doRequest(alt string) (*http.Response, error) {
  2152  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2153  	if c.ifNoneMatch_ != "" {
  2154  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  2155  	}
  2156  	var body io.Reader = nil
  2157  	c.urlParams_.Set("alt", alt)
  2158  	c.urlParams_.Set("prettyPrint", "false")
  2159  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  2160  	urls += "?" + c.urlParams_.Encode()
  2161  	req, err := http.NewRequest("GET", urls, body)
  2162  	if err != nil {
  2163  		return nil, err
  2164  	}
  2165  	req.Header = reqHeaders
  2166  	googleapi.Expand(req.URL, map[string]string{
  2167  		"name": c.name,
  2168  	})
  2169  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2170  }
  2171  
  2172  // Do executes the "workstations.projects.locations.operations.get" call.
  2173  // Any non-2xx status code is an error. Response headers are in either
  2174  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  2175  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2176  // whether the returned error was because http.StatusNotModified was returned.
  2177  func (c *ProjectsLocationsOperationsGetCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  2178  	gensupport.SetOptions(c.urlParams_, opts...)
  2179  	res, err := c.doRequest("json")
  2180  	if res != nil && res.StatusCode == http.StatusNotModified {
  2181  		if res.Body != nil {
  2182  			res.Body.Close()
  2183  		}
  2184  		return nil, gensupport.WrapError(&googleapi.Error{
  2185  			Code:   res.StatusCode,
  2186  			Header: res.Header,
  2187  		})
  2188  	}
  2189  	if err != nil {
  2190  		return nil, err
  2191  	}
  2192  	defer googleapi.CloseBody(res)
  2193  	if err := googleapi.CheckResponse(res); err != nil {
  2194  		return nil, gensupport.WrapError(err)
  2195  	}
  2196  	ret := &Operation{
  2197  		ServerResponse: googleapi.ServerResponse{
  2198  			Header:         res.Header,
  2199  			HTTPStatusCode: res.StatusCode,
  2200  		},
  2201  	}
  2202  	target := &ret
  2203  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2204  		return nil, err
  2205  	}
  2206  	return ret, nil
  2207  }
  2208  
  2209  type ProjectsLocationsOperationsListCall struct {
  2210  	s            *Service
  2211  	name         string
  2212  	urlParams_   gensupport.URLParams
  2213  	ifNoneMatch_ string
  2214  	ctx_         context.Context
  2215  	header_      http.Header
  2216  }
  2217  
  2218  // List: Lists operations that match the specified filter in the request. If
  2219  // the server doesn't support this method, it returns `UNIMPLEMENTED`.
  2220  //
  2221  // - name: The name of the operation's parent resource.
  2222  func (r *ProjectsLocationsOperationsService) List(name string) *ProjectsLocationsOperationsListCall {
  2223  	c := &ProjectsLocationsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2224  	c.name = name
  2225  	return c
  2226  }
  2227  
  2228  // Filter sets the optional parameter "filter": The standard list filter.
  2229  func (c *ProjectsLocationsOperationsListCall) Filter(filter string) *ProjectsLocationsOperationsListCall {
  2230  	c.urlParams_.Set("filter", filter)
  2231  	return c
  2232  }
  2233  
  2234  // PageSize sets the optional parameter "pageSize": The standard list page
  2235  // size.
  2236  func (c *ProjectsLocationsOperationsListCall) PageSize(pageSize int64) *ProjectsLocationsOperationsListCall {
  2237  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  2238  	return c
  2239  }
  2240  
  2241  // PageToken sets the optional parameter "pageToken": The standard list page
  2242  // token.
  2243  func (c *ProjectsLocationsOperationsListCall) PageToken(pageToken string) *ProjectsLocationsOperationsListCall {
  2244  	c.urlParams_.Set("pageToken", pageToken)
  2245  	return c
  2246  }
  2247  
  2248  // Fields allows partial responses to be retrieved. See
  2249  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2250  // details.
  2251  func (c *ProjectsLocationsOperationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsOperationsListCall {
  2252  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2253  	return c
  2254  }
  2255  
  2256  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  2257  // object's ETag matches the given value. This is useful for getting updates
  2258  // only after the object has changed since the last request.
  2259  func (c *ProjectsLocationsOperationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsOperationsListCall {
  2260  	c.ifNoneMatch_ = entityTag
  2261  	return c
  2262  }
  2263  
  2264  // Context sets the context to be used in this call's Do method.
  2265  func (c *ProjectsLocationsOperationsListCall) Context(ctx context.Context) *ProjectsLocationsOperationsListCall {
  2266  	c.ctx_ = ctx
  2267  	return c
  2268  }
  2269  
  2270  // Header returns a http.Header that can be modified by the caller to add
  2271  // headers to the request.
  2272  func (c *ProjectsLocationsOperationsListCall) Header() http.Header {
  2273  	if c.header_ == nil {
  2274  		c.header_ = make(http.Header)
  2275  	}
  2276  	return c.header_
  2277  }
  2278  
  2279  func (c *ProjectsLocationsOperationsListCall) doRequest(alt string) (*http.Response, error) {
  2280  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2281  	if c.ifNoneMatch_ != "" {
  2282  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  2283  	}
  2284  	var body io.Reader = nil
  2285  	c.urlParams_.Set("alt", alt)
  2286  	c.urlParams_.Set("prettyPrint", "false")
  2287  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}/operations")
  2288  	urls += "?" + c.urlParams_.Encode()
  2289  	req, err := http.NewRequest("GET", urls, body)
  2290  	if err != nil {
  2291  		return nil, err
  2292  	}
  2293  	req.Header = reqHeaders
  2294  	googleapi.Expand(req.URL, map[string]string{
  2295  		"name": c.name,
  2296  	})
  2297  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2298  }
  2299  
  2300  // Do executes the "workstations.projects.locations.operations.list" call.
  2301  // Any non-2xx status code is an error. Response headers are in either
  2302  // *ListOperationsResponse.ServerResponse.Header or (if a response was returned
  2303  // at all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  2304  // check whether the returned error was because http.StatusNotModified was
  2305  // returned.
  2306  func (c *ProjectsLocationsOperationsListCall) Do(opts ...googleapi.CallOption) (*ListOperationsResponse, error) {
  2307  	gensupport.SetOptions(c.urlParams_, opts...)
  2308  	res, err := c.doRequest("json")
  2309  	if res != nil && res.StatusCode == http.StatusNotModified {
  2310  		if res.Body != nil {
  2311  			res.Body.Close()
  2312  		}
  2313  		return nil, gensupport.WrapError(&googleapi.Error{
  2314  			Code:   res.StatusCode,
  2315  			Header: res.Header,
  2316  		})
  2317  	}
  2318  	if err != nil {
  2319  		return nil, err
  2320  	}
  2321  	defer googleapi.CloseBody(res)
  2322  	if err := googleapi.CheckResponse(res); err != nil {
  2323  		return nil, gensupport.WrapError(err)
  2324  	}
  2325  	ret := &ListOperationsResponse{
  2326  		ServerResponse: googleapi.ServerResponse{
  2327  			Header:         res.Header,
  2328  			HTTPStatusCode: res.StatusCode,
  2329  		},
  2330  	}
  2331  	target := &ret
  2332  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2333  		return nil, err
  2334  	}
  2335  	return ret, nil
  2336  }
  2337  
  2338  // Pages invokes f for each page of results.
  2339  // A non-nil error returned from f will halt the iteration.
  2340  // The provided context supersedes any context provided to the Context method.
  2341  func (c *ProjectsLocationsOperationsListCall) Pages(ctx context.Context, f func(*ListOperationsResponse) error) error {
  2342  	c.ctx_ = ctx
  2343  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  2344  	for {
  2345  		x, err := c.Do()
  2346  		if err != nil {
  2347  			return err
  2348  		}
  2349  		if err := f(x); err != nil {
  2350  			return err
  2351  		}
  2352  		if x.NextPageToken == "" {
  2353  			return nil
  2354  		}
  2355  		c.PageToken(x.NextPageToken)
  2356  	}
  2357  }
  2358  
  2359  type ProjectsLocationsWorkstationClustersCreateCall struct {
  2360  	s                  *Service
  2361  	parent             string
  2362  	workstationcluster *WorkstationCluster
  2363  	urlParams_         gensupport.URLParams
  2364  	ctx_               context.Context
  2365  	header_            http.Header
  2366  }
  2367  
  2368  // Create: Creates a new workstation cluster.
  2369  //
  2370  // - parent: Parent resource name.
  2371  func (r *ProjectsLocationsWorkstationClustersService) Create(parent string, workstationcluster *WorkstationCluster) *ProjectsLocationsWorkstationClustersCreateCall {
  2372  	c := &ProjectsLocationsWorkstationClustersCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2373  	c.parent = parent
  2374  	c.workstationcluster = workstationcluster
  2375  	return c
  2376  }
  2377  
  2378  // ValidateOnly sets the optional parameter "validateOnly": If set, validate
  2379  // the request and preview the review, but do not actually apply it.
  2380  func (c *ProjectsLocationsWorkstationClustersCreateCall) ValidateOnly(validateOnly bool) *ProjectsLocationsWorkstationClustersCreateCall {
  2381  	c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly))
  2382  	return c
  2383  }
  2384  
  2385  // WorkstationClusterId sets the optional parameter "workstationClusterId":
  2386  // Required. ID to use for the workstation cluster.
  2387  func (c *ProjectsLocationsWorkstationClustersCreateCall) WorkstationClusterId(workstationClusterId string) *ProjectsLocationsWorkstationClustersCreateCall {
  2388  	c.urlParams_.Set("workstationClusterId", workstationClusterId)
  2389  	return c
  2390  }
  2391  
  2392  // Fields allows partial responses to be retrieved. See
  2393  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2394  // details.
  2395  func (c *ProjectsLocationsWorkstationClustersCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersCreateCall {
  2396  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2397  	return c
  2398  }
  2399  
  2400  // Context sets the context to be used in this call's Do method.
  2401  func (c *ProjectsLocationsWorkstationClustersCreateCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersCreateCall {
  2402  	c.ctx_ = ctx
  2403  	return c
  2404  }
  2405  
  2406  // Header returns a http.Header that can be modified by the caller to add
  2407  // headers to the request.
  2408  func (c *ProjectsLocationsWorkstationClustersCreateCall) Header() http.Header {
  2409  	if c.header_ == nil {
  2410  		c.header_ = make(http.Header)
  2411  	}
  2412  	return c.header_
  2413  }
  2414  
  2415  func (c *ProjectsLocationsWorkstationClustersCreateCall) doRequest(alt string) (*http.Response, error) {
  2416  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  2417  	var body io.Reader = nil
  2418  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.workstationcluster)
  2419  	if err != nil {
  2420  		return nil, err
  2421  	}
  2422  	c.urlParams_.Set("alt", alt)
  2423  	c.urlParams_.Set("prettyPrint", "false")
  2424  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/workstationClusters")
  2425  	urls += "?" + c.urlParams_.Encode()
  2426  	req, err := http.NewRequest("POST", urls, body)
  2427  	if err != nil {
  2428  		return nil, err
  2429  	}
  2430  	req.Header = reqHeaders
  2431  	googleapi.Expand(req.URL, map[string]string{
  2432  		"parent": c.parent,
  2433  	})
  2434  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2435  }
  2436  
  2437  // Do executes the "workstations.projects.locations.workstationClusters.create" call.
  2438  // Any non-2xx status code is an error. Response headers are in either
  2439  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  2440  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2441  // whether the returned error was because http.StatusNotModified was returned.
  2442  func (c *ProjectsLocationsWorkstationClustersCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  2443  	gensupport.SetOptions(c.urlParams_, opts...)
  2444  	res, err := c.doRequest("json")
  2445  	if res != nil && res.StatusCode == http.StatusNotModified {
  2446  		if res.Body != nil {
  2447  			res.Body.Close()
  2448  		}
  2449  		return nil, gensupport.WrapError(&googleapi.Error{
  2450  			Code:   res.StatusCode,
  2451  			Header: res.Header,
  2452  		})
  2453  	}
  2454  	if err != nil {
  2455  		return nil, err
  2456  	}
  2457  	defer googleapi.CloseBody(res)
  2458  	if err := googleapi.CheckResponse(res); err != nil {
  2459  		return nil, gensupport.WrapError(err)
  2460  	}
  2461  	ret := &Operation{
  2462  		ServerResponse: googleapi.ServerResponse{
  2463  			Header:         res.Header,
  2464  			HTTPStatusCode: res.StatusCode,
  2465  		},
  2466  	}
  2467  	target := &ret
  2468  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2469  		return nil, err
  2470  	}
  2471  	return ret, nil
  2472  }
  2473  
  2474  type ProjectsLocationsWorkstationClustersDeleteCall struct {
  2475  	s          *Service
  2476  	name       string
  2477  	urlParams_ gensupport.URLParams
  2478  	ctx_       context.Context
  2479  	header_    http.Header
  2480  }
  2481  
  2482  // Delete: Deletes the specified workstation cluster.
  2483  //
  2484  // - name: Name of the workstation cluster to delete.
  2485  func (r *ProjectsLocationsWorkstationClustersService) Delete(name string) *ProjectsLocationsWorkstationClustersDeleteCall {
  2486  	c := &ProjectsLocationsWorkstationClustersDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2487  	c.name = name
  2488  	return c
  2489  }
  2490  
  2491  // Etag sets the optional parameter "etag": If set, the request will be
  2492  // rejected if the latest version of the workstation cluster on the server does
  2493  // not have this ETag.
  2494  func (c *ProjectsLocationsWorkstationClustersDeleteCall) Etag(etag string) *ProjectsLocationsWorkstationClustersDeleteCall {
  2495  	c.urlParams_.Set("etag", etag)
  2496  	return c
  2497  }
  2498  
  2499  // Force sets the optional parameter "force": If set, any workstation
  2500  // configurations and workstations in the workstation cluster are also deleted.
  2501  // Otherwise, the request only works if the workstation cluster has no
  2502  // configurations or workstations.
  2503  func (c *ProjectsLocationsWorkstationClustersDeleteCall) Force(force bool) *ProjectsLocationsWorkstationClustersDeleteCall {
  2504  	c.urlParams_.Set("force", fmt.Sprint(force))
  2505  	return c
  2506  }
  2507  
  2508  // ValidateOnly sets the optional parameter "validateOnly": If set, validate
  2509  // the request and preview the review, but do not apply it.
  2510  func (c *ProjectsLocationsWorkstationClustersDeleteCall) ValidateOnly(validateOnly bool) *ProjectsLocationsWorkstationClustersDeleteCall {
  2511  	c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly))
  2512  	return c
  2513  }
  2514  
  2515  // Fields allows partial responses to be retrieved. See
  2516  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2517  // details.
  2518  func (c *ProjectsLocationsWorkstationClustersDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersDeleteCall {
  2519  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2520  	return c
  2521  }
  2522  
  2523  // Context sets the context to be used in this call's Do method.
  2524  func (c *ProjectsLocationsWorkstationClustersDeleteCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersDeleteCall {
  2525  	c.ctx_ = ctx
  2526  	return c
  2527  }
  2528  
  2529  // Header returns a http.Header that can be modified by the caller to add
  2530  // headers to the request.
  2531  func (c *ProjectsLocationsWorkstationClustersDeleteCall) Header() http.Header {
  2532  	if c.header_ == nil {
  2533  		c.header_ = make(http.Header)
  2534  	}
  2535  	return c.header_
  2536  }
  2537  
  2538  func (c *ProjectsLocationsWorkstationClustersDeleteCall) doRequest(alt string) (*http.Response, error) {
  2539  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2540  	var body io.Reader = nil
  2541  	c.urlParams_.Set("alt", alt)
  2542  	c.urlParams_.Set("prettyPrint", "false")
  2543  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  2544  	urls += "?" + c.urlParams_.Encode()
  2545  	req, err := http.NewRequest("DELETE", urls, body)
  2546  	if err != nil {
  2547  		return nil, err
  2548  	}
  2549  	req.Header = reqHeaders
  2550  	googleapi.Expand(req.URL, map[string]string{
  2551  		"name": c.name,
  2552  	})
  2553  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2554  }
  2555  
  2556  // Do executes the "workstations.projects.locations.workstationClusters.delete" call.
  2557  // Any non-2xx status code is an error. Response headers are in either
  2558  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  2559  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2560  // whether the returned error was because http.StatusNotModified was returned.
  2561  func (c *ProjectsLocationsWorkstationClustersDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  2562  	gensupport.SetOptions(c.urlParams_, opts...)
  2563  	res, err := c.doRequest("json")
  2564  	if res != nil && res.StatusCode == http.StatusNotModified {
  2565  		if res.Body != nil {
  2566  			res.Body.Close()
  2567  		}
  2568  		return nil, gensupport.WrapError(&googleapi.Error{
  2569  			Code:   res.StatusCode,
  2570  			Header: res.Header,
  2571  		})
  2572  	}
  2573  	if err != nil {
  2574  		return nil, err
  2575  	}
  2576  	defer googleapi.CloseBody(res)
  2577  	if err := googleapi.CheckResponse(res); err != nil {
  2578  		return nil, gensupport.WrapError(err)
  2579  	}
  2580  	ret := &Operation{
  2581  		ServerResponse: googleapi.ServerResponse{
  2582  			Header:         res.Header,
  2583  			HTTPStatusCode: res.StatusCode,
  2584  		},
  2585  	}
  2586  	target := &ret
  2587  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2588  		return nil, err
  2589  	}
  2590  	return ret, nil
  2591  }
  2592  
  2593  type ProjectsLocationsWorkstationClustersGetCall struct {
  2594  	s            *Service
  2595  	name         string
  2596  	urlParams_   gensupport.URLParams
  2597  	ifNoneMatch_ string
  2598  	ctx_         context.Context
  2599  	header_      http.Header
  2600  }
  2601  
  2602  // Get: Returns the requested workstation cluster.
  2603  //
  2604  // - name: Name of the requested resource.
  2605  func (r *ProjectsLocationsWorkstationClustersService) Get(name string) *ProjectsLocationsWorkstationClustersGetCall {
  2606  	c := &ProjectsLocationsWorkstationClustersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2607  	c.name = name
  2608  	return c
  2609  }
  2610  
  2611  // Fields allows partial responses to be retrieved. See
  2612  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2613  // details.
  2614  func (c *ProjectsLocationsWorkstationClustersGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersGetCall {
  2615  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2616  	return c
  2617  }
  2618  
  2619  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  2620  // object's ETag matches the given value. This is useful for getting updates
  2621  // only after the object has changed since the last request.
  2622  func (c *ProjectsLocationsWorkstationClustersGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsWorkstationClustersGetCall {
  2623  	c.ifNoneMatch_ = entityTag
  2624  	return c
  2625  }
  2626  
  2627  // Context sets the context to be used in this call's Do method.
  2628  func (c *ProjectsLocationsWorkstationClustersGetCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersGetCall {
  2629  	c.ctx_ = ctx
  2630  	return c
  2631  }
  2632  
  2633  // Header returns a http.Header that can be modified by the caller to add
  2634  // headers to the request.
  2635  func (c *ProjectsLocationsWorkstationClustersGetCall) Header() http.Header {
  2636  	if c.header_ == nil {
  2637  		c.header_ = make(http.Header)
  2638  	}
  2639  	return c.header_
  2640  }
  2641  
  2642  func (c *ProjectsLocationsWorkstationClustersGetCall) doRequest(alt string) (*http.Response, error) {
  2643  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2644  	if c.ifNoneMatch_ != "" {
  2645  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  2646  	}
  2647  	var body io.Reader = nil
  2648  	c.urlParams_.Set("alt", alt)
  2649  	c.urlParams_.Set("prettyPrint", "false")
  2650  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  2651  	urls += "?" + c.urlParams_.Encode()
  2652  	req, err := http.NewRequest("GET", urls, body)
  2653  	if err != nil {
  2654  		return nil, err
  2655  	}
  2656  	req.Header = reqHeaders
  2657  	googleapi.Expand(req.URL, map[string]string{
  2658  		"name": c.name,
  2659  	})
  2660  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2661  }
  2662  
  2663  // Do executes the "workstations.projects.locations.workstationClusters.get" call.
  2664  // Any non-2xx status code is an error. Response headers are in either
  2665  // *WorkstationCluster.ServerResponse.Header or (if a response was returned at
  2666  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  2667  // check whether the returned error was because http.StatusNotModified was
  2668  // returned.
  2669  func (c *ProjectsLocationsWorkstationClustersGetCall) Do(opts ...googleapi.CallOption) (*WorkstationCluster, error) {
  2670  	gensupport.SetOptions(c.urlParams_, opts...)
  2671  	res, err := c.doRequest("json")
  2672  	if res != nil && res.StatusCode == http.StatusNotModified {
  2673  		if res.Body != nil {
  2674  			res.Body.Close()
  2675  		}
  2676  		return nil, gensupport.WrapError(&googleapi.Error{
  2677  			Code:   res.StatusCode,
  2678  			Header: res.Header,
  2679  		})
  2680  	}
  2681  	if err != nil {
  2682  		return nil, err
  2683  	}
  2684  	defer googleapi.CloseBody(res)
  2685  	if err := googleapi.CheckResponse(res); err != nil {
  2686  		return nil, gensupport.WrapError(err)
  2687  	}
  2688  	ret := &WorkstationCluster{
  2689  		ServerResponse: googleapi.ServerResponse{
  2690  			Header:         res.Header,
  2691  			HTTPStatusCode: res.StatusCode,
  2692  		},
  2693  	}
  2694  	target := &ret
  2695  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2696  		return nil, err
  2697  	}
  2698  	return ret, nil
  2699  }
  2700  
  2701  type ProjectsLocationsWorkstationClustersListCall struct {
  2702  	s            *Service
  2703  	parent       string
  2704  	urlParams_   gensupport.URLParams
  2705  	ifNoneMatch_ string
  2706  	ctx_         context.Context
  2707  	header_      http.Header
  2708  }
  2709  
  2710  // List: Returns all workstation clusters in the specified location.
  2711  //
  2712  // - parent: Parent resource name.
  2713  func (r *ProjectsLocationsWorkstationClustersService) List(parent string) *ProjectsLocationsWorkstationClustersListCall {
  2714  	c := &ProjectsLocationsWorkstationClustersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2715  	c.parent = parent
  2716  	return c
  2717  }
  2718  
  2719  // PageSize sets the optional parameter "pageSize": Maximum number of items to
  2720  // return.
  2721  func (c *ProjectsLocationsWorkstationClustersListCall) PageSize(pageSize int64) *ProjectsLocationsWorkstationClustersListCall {
  2722  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  2723  	return c
  2724  }
  2725  
  2726  // PageToken sets the optional parameter "pageToken": next_page_token value
  2727  // returned from a previous List request, if any.
  2728  func (c *ProjectsLocationsWorkstationClustersListCall) PageToken(pageToken string) *ProjectsLocationsWorkstationClustersListCall {
  2729  	c.urlParams_.Set("pageToken", pageToken)
  2730  	return c
  2731  }
  2732  
  2733  // Fields allows partial responses to be retrieved. See
  2734  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2735  // details.
  2736  func (c *ProjectsLocationsWorkstationClustersListCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersListCall {
  2737  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2738  	return c
  2739  }
  2740  
  2741  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  2742  // object's ETag matches the given value. This is useful for getting updates
  2743  // only after the object has changed since the last request.
  2744  func (c *ProjectsLocationsWorkstationClustersListCall) IfNoneMatch(entityTag string) *ProjectsLocationsWorkstationClustersListCall {
  2745  	c.ifNoneMatch_ = entityTag
  2746  	return c
  2747  }
  2748  
  2749  // Context sets the context to be used in this call's Do method.
  2750  func (c *ProjectsLocationsWorkstationClustersListCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersListCall {
  2751  	c.ctx_ = ctx
  2752  	return c
  2753  }
  2754  
  2755  // Header returns a http.Header that can be modified by the caller to add
  2756  // headers to the request.
  2757  func (c *ProjectsLocationsWorkstationClustersListCall) Header() http.Header {
  2758  	if c.header_ == nil {
  2759  		c.header_ = make(http.Header)
  2760  	}
  2761  	return c.header_
  2762  }
  2763  
  2764  func (c *ProjectsLocationsWorkstationClustersListCall) doRequest(alt string) (*http.Response, error) {
  2765  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  2766  	if c.ifNoneMatch_ != "" {
  2767  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  2768  	}
  2769  	var body io.Reader = nil
  2770  	c.urlParams_.Set("alt", alt)
  2771  	c.urlParams_.Set("prettyPrint", "false")
  2772  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/workstationClusters")
  2773  	urls += "?" + c.urlParams_.Encode()
  2774  	req, err := http.NewRequest("GET", urls, body)
  2775  	if err != nil {
  2776  		return nil, err
  2777  	}
  2778  	req.Header = reqHeaders
  2779  	googleapi.Expand(req.URL, map[string]string{
  2780  		"parent": c.parent,
  2781  	})
  2782  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2783  }
  2784  
  2785  // Do executes the "workstations.projects.locations.workstationClusters.list" call.
  2786  // Any non-2xx status code is an error. Response headers are in either
  2787  // *ListWorkstationClustersResponse.ServerResponse.Header or (if a response was
  2788  // returned at all) in error.(*googleapi.Error).Header. Use
  2789  // googleapi.IsNotModified to check whether the returned error was because
  2790  // http.StatusNotModified was returned.
  2791  func (c *ProjectsLocationsWorkstationClustersListCall) Do(opts ...googleapi.CallOption) (*ListWorkstationClustersResponse, error) {
  2792  	gensupport.SetOptions(c.urlParams_, opts...)
  2793  	res, err := c.doRequest("json")
  2794  	if res != nil && res.StatusCode == http.StatusNotModified {
  2795  		if res.Body != nil {
  2796  			res.Body.Close()
  2797  		}
  2798  		return nil, gensupport.WrapError(&googleapi.Error{
  2799  			Code:   res.StatusCode,
  2800  			Header: res.Header,
  2801  		})
  2802  	}
  2803  	if err != nil {
  2804  		return nil, err
  2805  	}
  2806  	defer googleapi.CloseBody(res)
  2807  	if err := googleapi.CheckResponse(res); err != nil {
  2808  		return nil, gensupport.WrapError(err)
  2809  	}
  2810  	ret := &ListWorkstationClustersResponse{
  2811  		ServerResponse: googleapi.ServerResponse{
  2812  			Header:         res.Header,
  2813  			HTTPStatusCode: res.StatusCode,
  2814  		},
  2815  	}
  2816  	target := &ret
  2817  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2818  		return nil, err
  2819  	}
  2820  	return ret, nil
  2821  }
  2822  
  2823  // Pages invokes f for each page of results.
  2824  // A non-nil error returned from f will halt the iteration.
  2825  // The provided context supersedes any context provided to the Context method.
  2826  func (c *ProjectsLocationsWorkstationClustersListCall) Pages(ctx context.Context, f func(*ListWorkstationClustersResponse) error) error {
  2827  	c.ctx_ = ctx
  2828  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  2829  	for {
  2830  		x, err := c.Do()
  2831  		if err != nil {
  2832  			return err
  2833  		}
  2834  		if err := f(x); err != nil {
  2835  			return err
  2836  		}
  2837  		if x.NextPageToken == "" {
  2838  			return nil
  2839  		}
  2840  		c.PageToken(x.NextPageToken)
  2841  	}
  2842  }
  2843  
  2844  type ProjectsLocationsWorkstationClustersPatchCall struct {
  2845  	s                  *Service
  2846  	name               string
  2847  	workstationcluster *WorkstationCluster
  2848  	urlParams_         gensupport.URLParams
  2849  	ctx_               context.Context
  2850  	header_            http.Header
  2851  }
  2852  
  2853  // Patch: Updates an existing workstation cluster.
  2854  //
  2855  // - name: Identifier. Full name of this workstation cluster.
  2856  func (r *ProjectsLocationsWorkstationClustersService) Patch(name string, workstationcluster *WorkstationCluster) *ProjectsLocationsWorkstationClustersPatchCall {
  2857  	c := &ProjectsLocationsWorkstationClustersPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2858  	c.name = name
  2859  	c.workstationcluster = workstationcluster
  2860  	return c
  2861  }
  2862  
  2863  // AllowMissing sets the optional parameter "allowMissing": If set, and the
  2864  // workstation cluster is not found, a new workstation cluster will be created.
  2865  // In this situation, update_mask is ignored.
  2866  func (c *ProjectsLocationsWorkstationClustersPatchCall) AllowMissing(allowMissing bool) *ProjectsLocationsWorkstationClustersPatchCall {
  2867  	c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing))
  2868  	return c
  2869  }
  2870  
  2871  // UpdateMask sets the optional parameter "updateMask": Required. Mask that
  2872  // specifies which fields in the workstation cluster should be updated.
  2873  func (c *ProjectsLocationsWorkstationClustersPatchCall) UpdateMask(updateMask string) *ProjectsLocationsWorkstationClustersPatchCall {
  2874  	c.urlParams_.Set("updateMask", updateMask)
  2875  	return c
  2876  }
  2877  
  2878  // ValidateOnly sets the optional parameter "validateOnly": If set, validate
  2879  // the request and preview the review, but do not actually apply it.
  2880  func (c *ProjectsLocationsWorkstationClustersPatchCall) ValidateOnly(validateOnly bool) *ProjectsLocationsWorkstationClustersPatchCall {
  2881  	c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly))
  2882  	return c
  2883  }
  2884  
  2885  // Fields allows partial responses to be retrieved. See
  2886  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  2887  // details.
  2888  func (c *ProjectsLocationsWorkstationClustersPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersPatchCall {
  2889  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  2890  	return c
  2891  }
  2892  
  2893  // Context sets the context to be used in this call's Do method.
  2894  func (c *ProjectsLocationsWorkstationClustersPatchCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersPatchCall {
  2895  	c.ctx_ = ctx
  2896  	return c
  2897  }
  2898  
  2899  // Header returns a http.Header that can be modified by the caller to add
  2900  // headers to the request.
  2901  func (c *ProjectsLocationsWorkstationClustersPatchCall) Header() http.Header {
  2902  	if c.header_ == nil {
  2903  		c.header_ = make(http.Header)
  2904  	}
  2905  	return c.header_
  2906  }
  2907  
  2908  func (c *ProjectsLocationsWorkstationClustersPatchCall) doRequest(alt string) (*http.Response, error) {
  2909  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  2910  	var body io.Reader = nil
  2911  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.workstationcluster)
  2912  	if err != nil {
  2913  		return nil, err
  2914  	}
  2915  	c.urlParams_.Set("alt", alt)
  2916  	c.urlParams_.Set("prettyPrint", "false")
  2917  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  2918  	urls += "?" + c.urlParams_.Encode()
  2919  	req, err := http.NewRequest("PATCH", urls, body)
  2920  	if err != nil {
  2921  		return nil, err
  2922  	}
  2923  	req.Header = reqHeaders
  2924  	googleapi.Expand(req.URL, map[string]string{
  2925  		"name": c.name,
  2926  	})
  2927  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  2928  }
  2929  
  2930  // Do executes the "workstations.projects.locations.workstationClusters.patch" call.
  2931  // Any non-2xx status code is an error. Response headers are in either
  2932  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  2933  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  2934  // whether the returned error was because http.StatusNotModified was returned.
  2935  func (c *ProjectsLocationsWorkstationClustersPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  2936  	gensupport.SetOptions(c.urlParams_, opts...)
  2937  	res, err := c.doRequest("json")
  2938  	if res != nil && res.StatusCode == http.StatusNotModified {
  2939  		if res.Body != nil {
  2940  			res.Body.Close()
  2941  		}
  2942  		return nil, gensupport.WrapError(&googleapi.Error{
  2943  			Code:   res.StatusCode,
  2944  			Header: res.Header,
  2945  		})
  2946  	}
  2947  	if err != nil {
  2948  		return nil, err
  2949  	}
  2950  	defer googleapi.CloseBody(res)
  2951  	if err := googleapi.CheckResponse(res); err != nil {
  2952  		return nil, gensupport.WrapError(err)
  2953  	}
  2954  	ret := &Operation{
  2955  		ServerResponse: googleapi.ServerResponse{
  2956  			Header:         res.Header,
  2957  			HTTPStatusCode: res.StatusCode,
  2958  		},
  2959  	}
  2960  	target := &ret
  2961  	if err := gensupport.DecodeResponse(target, res); err != nil {
  2962  		return nil, err
  2963  	}
  2964  	return ret, nil
  2965  }
  2966  
  2967  type ProjectsLocationsWorkstationClustersWorkstationConfigsCreateCall struct {
  2968  	s                 *Service
  2969  	parent            string
  2970  	workstationconfig *WorkstationConfig
  2971  	urlParams_        gensupport.URLParams
  2972  	ctx_              context.Context
  2973  	header_           http.Header
  2974  }
  2975  
  2976  // Create: Creates a new workstation configuration.
  2977  //
  2978  // - parent: Parent resource name.
  2979  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsService) Create(parent string, workstationconfig *WorkstationConfig) *ProjectsLocationsWorkstationClustersWorkstationConfigsCreateCall {
  2980  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  2981  	c.parent = parent
  2982  	c.workstationconfig = workstationconfig
  2983  	return c
  2984  }
  2985  
  2986  // ValidateOnly sets the optional parameter "validateOnly": If set, validate
  2987  // the request and preview the review, but do not actually apply it.
  2988  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsCreateCall) ValidateOnly(validateOnly bool) *ProjectsLocationsWorkstationClustersWorkstationConfigsCreateCall {
  2989  	c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly))
  2990  	return c
  2991  }
  2992  
  2993  // WorkstationConfigId sets the optional parameter "workstationConfigId":
  2994  // Required. ID to use for the workstation configuration.
  2995  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsCreateCall) WorkstationConfigId(workstationConfigId string) *ProjectsLocationsWorkstationClustersWorkstationConfigsCreateCall {
  2996  	c.urlParams_.Set("workstationConfigId", workstationConfigId)
  2997  	return c
  2998  }
  2999  
  3000  // Fields allows partial responses to be retrieved. See
  3001  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3002  // details.
  3003  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsCreateCall {
  3004  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3005  	return c
  3006  }
  3007  
  3008  // Context sets the context to be used in this call's Do method.
  3009  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsCreateCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsCreateCall {
  3010  	c.ctx_ = ctx
  3011  	return c
  3012  }
  3013  
  3014  // Header returns a http.Header that can be modified by the caller to add
  3015  // headers to the request.
  3016  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsCreateCall) Header() http.Header {
  3017  	if c.header_ == nil {
  3018  		c.header_ = make(http.Header)
  3019  	}
  3020  	return c.header_
  3021  }
  3022  
  3023  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsCreateCall) doRequest(alt string) (*http.Response, error) {
  3024  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3025  	var body io.Reader = nil
  3026  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.workstationconfig)
  3027  	if err != nil {
  3028  		return nil, err
  3029  	}
  3030  	c.urlParams_.Set("alt", alt)
  3031  	c.urlParams_.Set("prettyPrint", "false")
  3032  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/workstationConfigs")
  3033  	urls += "?" + c.urlParams_.Encode()
  3034  	req, err := http.NewRequest("POST", urls, body)
  3035  	if err != nil {
  3036  		return nil, err
  3037  	}
  3038  	req.Header = reqHeaders
  3039  	googleapi.Expand(req.URL, map[string]string{
  3040  		"parent": c.parent,
  3041  	})
  3042  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3043  }
  3044  
  3045  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.create" call.
  3046  // Any non-2xx status code is an error. Response headers are in either
  3047  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  3048  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3049  // whether the returned error was because http.StatusNotModified was returned.
  3050  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  3051  	gensupport.SetOptions(c.urlParams_, opts...)
  3052  	res, err := c.doRequest("json")
  3053  	if res != nil && res.StatusCode == http.StatusNotModified {
  3054  		if res.Body != nil {
  3055  			res.Body.Close()
  3056  		}
  3057  		return nil, gensupport.WrapError(&googleapi.Error{
  3058  			Code:   res.StatusCode,
  3059  			Header: res.Header,
  3060  		})
  3061  	}
  3062  	if err != nil {
  3063  		return nil, err
  3064  	}
  3065  	defer googleapi.CloseBody(res)
  3066  	if err := googleapi.CheckResponse(res); err != nil {
  3067  		return nil, gensupport.WrapError(err)
  3068  	}
  3069  	ret := &Operation{
  3070  		ServerResponse: googleapi.ServerResponse{
  3071  			Header:         res.Header,
  3072  			HTTPStatusCode: res.StatusCode,
  3073  		},
  3074  	}
  3075  	target := &ret
  3076  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3077  		return nil, err
  3078  	}
  3079  	return ret, nil
  3080  }
  3081  
  3082  type ProjectsLocationsWorkstationClustersWorkstationConfigsDeleteCall struct {
  3083  	s          *Service
  3084  	name       string
  3085  	urlParams_ gensupport.URLParams
  3086  	ctx_       context.Context
  3087  	header_    http.Header
  3088  }
  3089  
  3090  // Delete: Deletes the specified workstation configuration.
  3091  //
  3092  // - name: Name of the workstation configuration to delete.
  3093  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsService) Delete(name string) *ProjectsLocationsWorkstationClustersWorkstationConfigsDeleteCall {
  3094  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3095  	c.name = name
  3096  	return c
  3097  }
  3098  
  3099  // Etag sets the optional parameter "etag": If set, the request is rejected if
  3100  // the latest version of the workstation configuration on the server does not
  3101  // have this ETag.
  3102  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsDeleteCall) Etag(etag string) *ProjectsLocationsWorkstationClustersWorkstationConfigsDeleteCall {
  3103  	c.urlParams_.Set("etag", etag)
  3104  	return c
  3105  }
  3106  
  3107  // Force sets the optional parameter "force": If set, any workstations in the
  3108  // workstation configuration are also deleted. Otherwise, the request works
  3109  // only if the workstation configuration has no workstations.
  3110  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsDeleteCall) Force(force bool) *ProjectsLocationsWorkstationClustersWorkstationConfigsDeleteCall {
  3111  	c.urlParams_.Set("force", fmt.Sprint(force))
  3112  	return c
  3113  }
  3114  
  3115  // ValidateOnly sets the optional parameter "validateOnly": If set, validate
  3116  // the request and preview the review, but do not actually apply it.
  3117  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsDeleteCall) ValidateOnly(validateOnly bool) *ProjectsLocationsWorkstationClustersWorkstationConfigsDeleteCall {
  3118  	c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly))
  3119  	return c
  3120  }
  3121  
  3122  // Fields allows partial responses to be retrieved. See
  3123  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3124  // details.
  3125  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsDeleteCall {
  3126  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3127  	return c
  3128  }
  3129  
  3130  // Context sets the context to be used in this call's Do method.
  3131  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsDeleteCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsDeleteCall {
  3132  	c.ctx_ = ctx
  3133  	return c
  3134  }
  3135  
  3136  // Header returns a http.Header that can be modified by the caller to add
  3137  // headers to the request.
  3138  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsDeleteCall) Header() http.Header {
  3139  	if c.header_ == nil {
  3140  		c.header_ = make(http.Header)
  3141  	}
  3142  	return c.header_
  3143  }
  3144  
  3145  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsDeleteCall) doRequest(alt string) (*http.Response, error) {
  3146  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3147  	var body io.Reader = nil
  3148  	c.urlParams_.Set("alt", alt)
  3149  	c.urlParams_.Set("prettyPrint", "false")
  3150  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  3151  	urls += "?" + c.urlParams_.Encode()
  3152  	req, err := http.NewRequest("DELETE", urls, body)
  3153  	if err != nil {
  3154  		return nil, err
  3155  	}
  3156  	req.Header = reqHeaders
  3157  	googleapi.Expand(req.URL, map[string]string{
  3158  		"name": c.name,
  3159  	})
  3160  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3161  }
  3162  
  3163  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.delete" call.
  3164  // Any non-2xx status code is an error. Response headers are in either
  3165  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  3166  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3167  // whether the returned error was because http.StatusNotModified was returned.
  3168  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  3169  	gensupport.SetOptions(c.urlParams_, opts...)
  3170  	res, err := c.doRequest("json")
  3171  	if res != nil && res.StatusCode == http.StatusNotModified {
  3172  		if res.Body != nil {
  3173  			res.Body.Close()
  3174  		}
  3175  		return nil, gensupport.WrapError(&googleapi.Error{
  3176  			Code:   res.StatusCode,
  3177  			Header: res.Header,
  3178  		})
  3179  	}
  3180  	if err != nil {
  3181  		return nil, err
  3182  	}
  3183  	defer googleapi.CloseBody(res)
  3184  	if err := googleapi.CheckResponse(res); err != nil {
  3185  		return nil, gensupport.WrapError(err)
  3186  	}
  3187  	ret := &Operation{
  3188  		ServerResponse: googleapi.ServerResponse{
  3189  			Header:         res.Header,
  3190  			HTTPStatusCode: res.StatusCode,
  3191  		},
  3192  	}
  3193  	target := &ret
  3194  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3195  		return nil, err
  3196  	}
  3197  	return ret, nil
  3198  }
  3199  
  3200  type ProjectsLocationsWorkstationClustersWorkstationConfigsGetCall struct {
  3201  	s            *Service
  3202  	name         string
  3203  	urlParams_   gensupport.URLParams
  3204  	ifNoneMatch_ string
  3205  	ctx_         context.Context
  3206  	header_      http.Header
  3207  }
  3208  
  3209  // Get: Returns the requested workstation configuration.
  3210  //
  3211  // - name: Name of the requested resource.
  3212  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsService) Get(name string) *ProjectsLocationsWorkstationClustersWorkstationConfigsGetCall {
  3213  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3214  	c.name = name
  3215  	return c
  3216  }
  3217  
  3218  // Fields allows partial responses to be retrieved. See
  3219  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3220  // details.
  3221  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsGetCall {
  3222  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3223  	return c
  3224  }
  3225  
  3226  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  3227  // object's ETag matches the given value. This is useful for getting updates
  3228  // only after the object has changed since the last request.
  3229  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsWorkstationClustersWorkstationConfigsGetCall {
  3230  	c.ifNoneMatch_ = entityTag
  3231  	return c
  3232  }
  3233  
  3234  // Context sets the context to be used in this call's Do method.
  3235  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsGetCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsGetCall {
  3236  	c.ctx_ = ctx
  3237  	return c
  3238  }
  3239  
  3240  // Header returns a http.Header that can be modified by the caller to add
  3241  // headers to the request.
  3242  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsGetCall) Header() http.Header {
  3243  	if c.header_ == nil {
  3244  		c.header_ = make(http.Header)
  3245  	}
  3246  	return c.header_
  3247  }
  3248  
  3249  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsGetCall) doRequest(alt string) (*http.Response, error) {
  3250  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3251  	if c.ifNoneMatch_ != "" {
  3252  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3253  	}
  3254  	var body io.Reader = nil
  3255  	c.urlParams_.Set("alt", alt)
  3256  	c.urlParams_.Set("prettyPrint", "false")
  3257  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  3258  	urls += "?" + c.urlParams_.Encode()
  3259  	req, err := http.NewRequest("GET", urls, body)
  3260  	if err != nil {
  3261  		return nil, err
  3262  	}
  3263  	req.Header = reqHeaders
  3264  	googleapi.Expand(req.URL, map[string]string{
  3265  		"name": c.name,
  3266  	})
  3267  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3268  }
  3269  
  3270  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.get" call.
  3271  // Any non-2xx status code is an error. Response headers are in either
  3272  // *WorkstationConfig.ServerResponse.Header or (if a response was returned at
  3273  // all) in error.(*googleapi.Error).Header. Use googleapi.IsNotModified to
  3274  // check whether the returned error was because http.StatusNotModified was
  3275  // returned.
  3276  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsGetCall) Do(opts ...googleapi.CallOption) (*WorkstationConfig, error) {
  3277  	gensupport.SetOptions(c.urlParams_, opts...)
  3278  	res, err := c.doRequest("json")
  3279  	if res != nil && res.StatusCode == http.StatusNotModified {
  3280  		if res.Body != nil {
  3281  			res.Body.Close()
  3282  		}
  3283  		return nil, gensupport.WrapError(&googleapi.Error{
  3284  			Code:   res.StatusCode,
  3285  			Header: res.Header,
  3286  		})
  3287  	}
  3288  	if err != nil {
  3289  		return nil, err
  3290  	}
  3291  	defer googleapi.CloseBody(res)
  3292  	if err := googleapi.CheckResponse(res); err != nil {
  3293  		return nil, gensupport.WrapError(err)
  3294  	}
  3295  	ret := &WorkstationConfig{
  3296  		ServerResponse: googleapi.ServerResponse{
  3297  			Header:         res.Header,
  3298  			HTTPStatusCode: res.StatusCode,
  3299  		},
  3300  	}
  3301  	target := &ret
  3302  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3303  		return nil, err
  3304  	}
  3305  	return ret, nil
  3306  }
  3307  
  3308  type ProjectsLocationsWorkstationClustersWorkstationConfigsGetIamPolicyCall struct {
  3309  	s            *Service
  3310  	resource     string
  3311  	urlParams_   gensupport.URLParams
  3312  	ifNoneMatch_ string
  3313  	ctx_         context.Context
  3314  	header_      http.Header
  3315  }
  3316  
  3317  // GetIamPolicy: Gets the access control policy for a resource. Returns an
  3318  // empty policy if the resource exists and does not have a policy set.
  3319  //
  3320  //   - resource: REQUIRED: The resource for which the policy is being requested.
  3321  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  3322  //     for the appropriate value for this field.
  3323  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsService) GetIamPolicy(resource string) *ProjectsLocationsWorkstationClustersWorkstationConfigsGetIamPolicyCall {
  3324  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3325  	c.resource = resource
  3326  	return c
  3327  }
  3328  
  3329  // OptionsRequestedPolicyVersion sets the optional parameter
  3330  // "options.requestedPolicyVersion": The maximum policy version that will be
  3331  // used to format the policy. Valid values are 0, 1, and 3. Requests specifying
  3332  // an invalid value will be rejected. Requests for policies with any
  3333  // conditional role bindings must specify version 3. Policies with no
  3334  // conditional role bindings may specify any valid value or leave the field
  3335  // unset. The policy in the response might use the policy version that you
  3336  // specified, or it might use a lower policy version. For example, if you
  3337  // specify version 3, but the policy has no conditional role bindings, the
  3338  // response uses version 1. To learn which resources support conditions in
  3339  // their IAM policies, see the IAM documentation
  3340  // (https://cloud.google.com/iam/help/conditions/resource-policies).
  3341  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsWorkstationClustersWorkstationConfigsGetIamPolicyCall {
  3342  	c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion))
  3343  	return c
  3344  }
  3345  
  3346  // Fields allows partial responses to be retrieved. See
  3347  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3348  // details.
  3349  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsGetIamPolicyCall {
  3350  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3351  	return c
  3352  }
  3353  
  3354  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  3355  // object's ETag matches the given value. This is useful for getting updates
  3356  // only after the object has changed since the last request.
  3357  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsWorkstationClustersWorkstationConfigsGetIamPolicyCall {
  3358  	c.ifNoneMatch_ = entityTag
  3359  	return c
  3360  }
  3361  
  3362  // Context sets the context to be used in this call's Do method.
  3363  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsGetIamPolicyCall {
  3364  	c.ctx_ = ctx
  3365  	return c
  3366  }
  3367  
  3368  // Header returns a http.Header that can be modified by the caller to add
  3369  // headers to the request.
  3370  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsGetIamPolicyCall) Header() http.Header {
  3371  	if c.header_ == nil {
  3372  		c.header_ = make(http.Header)
  3373  	}
  3374  	return c.header_
  3375  }
  3376  
  3377  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsGetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  3378  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3379  	if c.ifNoneMatch_ != "" {
  3380  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3381  	}
  3382  	var body io.Reader = nil
  3383  	c.urlParams_.Set("alt", alt)
  3384  	c.urlParams_.Set("prettyPrint", "false")
  3385  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+resource}:getIamPolicy")
  3386  	urls += "?" + c.urlParams_.Encode()
  3387  	req, err := http.NewRequest("GET", urls, body)
  3388  	if err != nil {
  3389  		return nil, err
  3390  	}
  3391  	req.Header = reqHeaders
  3392  	googleapi.Expand(req.URL, map[string]string{
  3393  		"resource": c.resource,
  3394  	})
  3395  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3396  }
  3397  
  3398  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.getIamPolicy" call.
  3399  // Any non-2xx status code is an error. Response headers are in either
  3400  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  3401  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3402  // whether the returned error was because http.StatusNotModified was returned.
  3403  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  3404  	gensupport.SetOptions(c.urlParams_, opts...)
  3405  	res, err := c.doRequest("json")
  3406  	if res != nil && res.StatusCode == http.StatusNotModified {
  3407  		if res.Body != nil {
  3408  			res.Body.Close()
  3409  		}
  3410  		return nil, gensupport.WrapError(&googleapi.Error{
  3411  			Code:   res.StatusCode,
  3412  			Header: res.Header,
  3413  		})
  3414  	}
  3415  	if err != nil {
  3416  		return nil, err
  3417  	}
  3418  	defer googleapi.CloseBody(res)
  3419  	if err := googleapi.CheckResponse(res); err != nil {
  3420  		return nil, gensupport.WrapError(err)
  3421  	}
  3422  	ret := &Policy{
  3423  		ServerResponse: googleapi.ServerResponse{
  3424  			Header:         res.Header,
  3425  			HTTPStatusCode: res.StatusCode,
  3426  		},
  3427  	}
  3428  	target := &ret
  3429  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3430  		return nil, err
  3431  	}
  3432  	return ret, nil
  3433  }
  3434  
  3435  type ProjectsLocationsWorkstationClustersWorkstationConfigsListCall struct {
  3436  	s            *Service
  3437  	parent       string
  3438  	urlParams_   gensupport.URLParams
  3439  	ifNoneMatch_ string
  3440  	ctx_         context.Context
  3441  	header_      http.Header
  3442  }
  3443  
  3444  // List: Returns all workstation configurations in the specified cluster.
  3445  //
  3446  // - parent: Parent resource name.
  3447  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsService) List(parent string) *ProjectsLocationsWorkstationClustersWorkstationConfigsListCall {
  3448  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3449  	c.parent = parent
  3450  	return c
  3451  }
  3452  
  3453  // PageSize sets the optional parameter "pageSize": Maximum number of items to
  3454  // return.
  3455  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListCall) PageSize(pageSize int64) *ProjectsLocationsWorkstationClustersWorkstationConfigsListCall {
  3456  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  3457  	return c
  3458  }
  3459  
  3460  // PageToken sets the optional parameter "pageToken": next_page_token value
  3461  // returned from a previous List request, if any.
  3462  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListCall) PageToken(pageToken string) *ProjectsLocationsWorkstationClustersWorkstationConfigsListCall {
  3463  	c.urlParams_.Set("pageToken", pageToken)
  3464  	return c
  3465  }
  3466  
  3467  // Fields allows partial responses to be retrieved. See
  3468  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3469  // details.
  3470  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsListCall {
  3471  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3472  	return c
  3473  }
  3474  
  3475  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  3476  // object's ETag matches the given value. This is useful for getting updates
  3477  // only after the object has changed since the last request.
  3478  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsWorkstationClustersWorkstationConfigsListCall {
  3479  	c.ifNoneMatch_ = entityTag
  3480  	return c
  3481  }
  3482  
  3483  // Context sets the context to be used in this call's Do method.
  3484  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsListCall {
  3485  	c.ctx_ = ctx
  3486  	return c
  3487  }
  3488  
  3489  // Header returns a http.Header that can be modified by the caller to add
  3490  // headers to the request.
  3491  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListCall) Header() http.Header {
  3492  	if c.header_ == nil {
  3493  		c.header_ = make(http.Header)
  3494  	}
  3495  	return c.header_
  3496  }
  3497  
  3498  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListCall) doRequest(alt string) (*http.Response, error) {
  3499  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3500  	if c.ifNoneMatch_ != "" {
  3501  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3502  	}
  3503  	var body io.Reader = nil
  3504  	c.urlParams_.Set("alt", alt)
  3505  	c.urlParams_.Set("prettyPrint", "false")
  3506  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/workstationConfigs")
  3507  	urls += "?" + c.urlParams_.Encode()
  3508  	req, err := http.NewRequest("GET", urls, body)
  3509  	if err != nil {
  3510  		return nil, err
  3511  	}
  3512  	req.Header = reqHeaders
  3513  	googleapi.Expand(req.URL, map[string]string{
  3514  		"parent": c.parent,
  3515  	})
  3516  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3517  }
  3518  
  3519  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.list" call.
  3520  // Any non-2xx status code is an error. Response headers are in either
  3521  // *ListWorkstationConfigsResponse.ServerResponse.Header or (if a response was
  3522  // returned at all) in error.(*googleapi.Error).Header. Use
  3523  // googleapi.IsNotModified to check whether the returned error was because
  3524  // http.StatusNotModified was returned.
  3525  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListCall) Do(opts ...googleapi.CallOption) (*ListWorkstationConfigsResponse, error) {
  3526  	gensupport.SetOptions(c.urlParams_, opts...)
  3527  	res, err := c.doRequest("json")
  3528  	if res != nil && res.StatusCode == http.StatusNotModified {
  3529  		if res.Body != nil {
  3530  			res.Body.Close()
  3531  		}
  3532  		return nil, gensupport.WrapError(&googleapi.Error{
  3533  			Code:   res.StatusCode,
  3534  			Header: res.Header,
  3535  		})
  3536  	}
  3537  	if err != nil {
  3538  		return nil, err
  3539  	}
  3540  	defer googleapi.CloseBody(res)
  3541  	if err := googleapi.CheckResponse(res); err != nil {
  3542  		return nil, gensupport.WrapError(err)
  3543  	}
  3544  	ret := &ListWorkstationConfigsResponse{
  3545  		ServerResponse: googleapi.ServerResponse{
  3546  			Header:         res.Header,
  3547  			HTTPStatusCode: res.StatusCode,
  3548  		},
  3549  	}
  3550  	target := &ret
  3551  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3552  		return nil, err
  3553  	}
  3554  	return ret, nil
  3555  }
  3556  
  3557  // Pages invokes f for each page of results.
  3558  // A non-nil error returned from f will halt the iteration.
  3559  // The provided context supersedes any context provided to the Context method.
  3560  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListCall) Pages(ctx context.Context, f func(*ListWorkstationConfigsResponse) error) error {
  3561  	c.ctx_ = ctx
  3562  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  3563  	for {
  3564  		x, err := c.Do()
  3565  		if err != nil {
  3566  			return err
  3567  		}
  3568  		if err := f(x); err != nil {
  3569  			return err
  3570  		}
  3571  		if x.NextPageToken == "" {
  3572  			return nil
  3573  		}
  3574  		c.PageToken(x.NextPageToken)
  3575  	}
  3576  }
  3577  
  3578  type ProjectsLocationsWorkstationClustersWorkstationConfigsListUsableCall struct {
  3579  	s            *Service
  3580  	parent       string
  3581  	urlParams_   gensupport.URLParams
  3582  	ifNoneMatch_ string
  3583  	ctx_         context.Context
  3584  	header_      http.Header
  3585  }
  3586  
  3587  // ListUsable: Returns all workstation configurations in the specified cluster
  3588  // on which the caller has the "workstations.workstation.create" permission.
  3589  //
  3590  // - parent: Parent resource name.
  3591  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsService) ListUsable(parent string) *ProjectsLocationsWorkstationClustersWorkstationConfigsListUsableCall {
  3592  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsListUsableCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3593  	c.parent = parent
  3594  	return c
  3595  }
  3596  
  3597  // PageSize sets the optional parameter "pageSize": Maximum number of items to
  3598  // return.
  3599  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListUsableCall) PageSize(pageSize int64) *ProjectsLocationsWorkstationClustersWorkstationConfigsListUsableCall {
  3600  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  3601  	return c
  3602  }
  3603  
  3604  // PageToken sets the optional parameter "pageToken": next_page_token value
  3605  // returned from a previous List request, if any.
  3606  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListUsableCall) PageToken(pageToken string) *ProjectsLocationsWorkstationClustersWorkstationConfigsListUsableCall {
  3607  	c.urlParams_.Set("pageToken", pageToken)
  3608  	return c
  3609  }
  3610  
  3611  // Fields allows partial responses to be retrieved. See
  3612  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3613  // details.
  3614  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListUsableCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsListUsableCall {
  3615  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3616  	return c
  3617  }
  3618  
  3619  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  3620  // object's ETag matches the given value. This is useful for getting updates
  3621  // only after the object has changed since the last request.
  3622  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListUsableCall) IfNoneMatch(entityTag string) *ProjectsLocationsWorkstationClustersWorkstationConfigsListUsableCall {
  3623  	c.ifNoneMatch_ = entityTag
  3624  	return c
  3625  }
  3626  
  3627  // Context sets the context to be used in this call's Do method.
  3628  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListUsableCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsListUsableCall {
  3629  	c.ctx_ = ctx
  3630  	return c
  3631  }
  3632  
  3633  // Header returns a http.Header that can be modified by the caller to add
  3634  // headers to the request.
  3635  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListUsableCall) Header() http.Header {
  3636  	if c.header_ == nil {
  3637  		c.header_ = make(http.Header)
  3638  	}
  3639  	return c.header_
  3640  }
  3641  
  3642  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListUsableCall) doRequest(alt string) (*http.Response, error) {
  3643  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  3644  	if c.ifNoneMatch_ != "" {
  3645  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  3646  	}
  3647  	var body io.Reader = nil
  3648  	c.urlParams_.Set("alt", alt)
  3649  	c.urlParams_.Set("prettyPrint", "false")
  3650  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/workstationConfigs:listUsable")
  3651  	urls += "?" + c.urlParams_.Encode()
  3652  	req, err := http.NewRequest("GET", urls, body)
  3653  	if err != nil {
  3654  		return nil, err
  3655  	}
  3656  	req.Header = reqHeaders
  3657  	googleapi.Expand(req.URL, map[string]string{
  3658  		"parent": c.parent,
  3659  	})
  3660  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3661  }
  3662  
  3663  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.listUsable" call.
  3664  // Any non-2xx status code is an error. Response headers are in either
  3665  // *ListUsableWorkstationConfigsResponse.ServerResponse.Header or (if a
  3666  // response was returned at all) in error.(*googleapi.Error).Header. Use
  3667  // googleapi.IsNotModified to check whether the returned error was because
  3668  // http.StatusNotModified was returned.
  3669  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListUsableCall) Do(opts ...googleapi.CallOption) (*ListUsableWorkstationConfigsResponse, error) {
  3670  	gensupport.SetOptions(c.urlParams_, opts...)
  3671  	res, err := c.doRequest("json")
  3672  	if res != nil && res.StatusCode == http.StatusNotModified {
  3673  		if res.Body != nil {
  3674  			res.Body.Close()
  3675  		}
  3676  		return nil, gensupport.WrapError(&googleapi.Error{
  3677  			Code:   res.StatusCode,
  3678  			Header: res.Header,
  3679  		})
  3680  	}
  3681  	if err != nil {
  3682  		return nil, err
  3683  	}
  3684  	defer googleapi.CloseBody(res)
  3685  	if err := googleapi.CheckResponse(res); err != nil {
  3686  		return nil, gensupport.WrapError(err)
  3687  	}
  3688  	ret := &ListUsableWorkstationConfigsResponse{
  3689  		ServerResponse: googleapi.ServerResponse{
  3690  			Header:         res.Header,
  3691  			HTTPStatusCode: res.StatusCode,
  3692  		},
  3693  	}
  3694  	target := &ret
  3695  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3696  		return nil, err
  3697  	}
  3698  	return ret, nil
  3699  }
  3700  
  3701  // Pages invokes f for each page of results.
  3702  // A non-nil error returned from f will halt the iteration.
  3703  // The provided context supersedes any context provided to the Context method.
  3704  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsListUsableCall) Pages(ctx context.Context, f func(*ListUsableWorkstationConfigsResponse) error) error {
  3705  	c.ctx_ = ctx
  3706  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  3707  	for {
  3708  		x, err := c.Do()
  3709  		if err != nil {
  3710  			return err
  3711  		}
  3712  		if err := f(x); err != nil {
  3713  			return err
  3714  		}
  3715  		if x.NextPageToken == "" {
  3716  			return nil
  3717  		}
  3718  		c.PageToken(x.NextPageToken)
  3719  	}
  3720  }
  3721  
  3722  type ProjectsLocationsWorkstationClustersWorkstationConfigsPatchCall struct {
  3723  	s                 *Service
  3724  	name              string
  3725  	workstationconfig *WorkstationConfig
  3726  	urlParams_        gensupport.URLParams
  3727  	ctx_              context.Context
  3728  	header_           http.Header
  3729  }
  3730  
  3731  // Patch: Updates an existing workstation configuration.
  3732  //
  3733  // - name: Identifier. Full name of this workstation configuration.
  3734  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsService) Patch(name string, workstationconfig *WorkstationConfig) *ProjectsLocationsWorkstationClustersWorkstationConfigsPatchCall {
  3735  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3736  	c.name = name
  3737  	c.workstationconfig = workstationconfig
  3738  	return c
  3739  }
  3740  
  3741  // AllowMissing sets the optional parameter "allowMissing": If set and the
  3742  // workstation configuration is not found, a new workstation configuration will
  3743  // be created. In this situation, update_mask is ignored.
  3744  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsPatchCall) AllowMissing(allowMissing bool) *ProjectsLocationsWorkstationClustersWorkstationConfigsPatchCall {
  3745  	c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing))
  3746  	return c
  3747  }
  3748  
  3749  // UpdateMask sets the optional parameter "updateMask": Required. Mask
  3750  // specifying which fields in the workstation configuration should be updated.
  3751  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsWorkstationClustersWorkstationConfigsPatchCall {
  3752  	c.urlParams_.Set("updateMask", updateMask)
  3753  	return c
  3754  }
  3755  
  3756  // ValidateOnly sets the optional parameter "validateOnly": If set, validate
  3757  // the request and preview the review, but do not actually apply it.
  3758  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsPatchCall) ValidateOnly(validateOnly bool) *ProjectsLocationsWorkstationClustersWorkstationConfigsPatchCall {
  3759  	c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly))
  3760  	return c
  3761  }
  3762  
  3763  // Fields allows partial responses to be retrieved. See
  3764  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3765  // details.
  3766  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsPatchCall {
  3767  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3768  	return c
  3769  }
  3770  
  3771  // Context sets the context to be used in this call's Do method.
  3772  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsPatchCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsPatchCall {
  3773  	c.ctx_ = ctx
  3774  	return c
  3775  }
  3776  
  3777  // Header returns a http.Header that can be modified by the caller to add
  3778  // headers to the request.
  3779  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsPatchCall) Header() http.Header {
  3780  	if c.header_ == nil {
  3781  		c.header_ = make(http.Header)
  3782  	}
  3783  	return c.header_
  3784  }
  3785  
  3786  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsPatchCall) doRequest(alt string) (*http.Response, error) {
  3787  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3788  	var body io.Reader = nil
  3789  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.workstationconfig)
  3790  	if err != nil {
  3791  		return nil, err
  3792  	}
  3793  	c.urlParams_.Set("alt", alt)
  3794  	c.urlParams_.Set("prettyPrint", "false")
  3795  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  3796  	urls += "?" + c.urlParams_.Encode()
  3797  	req, err := http.NewRequest("PATCH", urls, body)
  3798  	if err != nil {
  3799  		return nil, err
  3800  	}
  3801  	req.Header = reqHeaders
  3802  	googleapi.Expand(req.URL, map[string]string{
  3803  		"name": c.name,
  3804  	})
  3805  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3806  }
  3807  
  3808  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.patch" call.
  3809  // Any non-2xx status code is an error. Response headers are in either
  3810  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  3811  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3812  // whether the returned error was because http.StatusNotModified was returned.
  3813  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  3814  	gensupport.SetOptions(c.urlParams_, opts...)
  3815  	res, err := c.doRequest("json")
  3816  	if res != nil && res.StatusCode == http.StatusNotModified {
  3817  		if res.Body != nil {
  3818  			res.Body.Close()
  3819  		}
  3820  		return nil, gensupport.WrapError(&googleapi.Error{
  3821  			Code:   res.StatusCode,
  3822  			Header: res.Header,
  3823  		})
  3824  	}
  3825  	if err != nil {
  3826  		return nil, err
  3827  	}
  3828  	defer googleapi.CloseBody(res)
  3829  	if err := googleapi.CheckResponse(res); err != nil {
  3830  		return nil, gensupport.WrapError(err)
  3831  	}
  3832  	ret := &Operation{
  3833  		ServerResponse: googleapi.ServerResponse{
  3834  			Header:         res.Header,
  3835  			HTTPStatusCode: res.StatusCode,
  3836  		},
  3837  	}
  3838  	target := &ret
  3839  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3840  		return nil, err
  3841  	}
  3842  	return ret, nil
  3843  }
  3844  
  3845  type ProjectsLocationsWorkstationClustersWorkstationConfigsSetIamPolicyCall struct {
  3846  	s                   *Service
  3847  	resource            string
  3848  	setiampolicyrequest *SetIamPolicyRequest
  3849  	urlParams_          gensupport.URLParams
  3850  	ctx_                context.Context
  3851  	header_             http.Header
  3852  }
  3853  
  3854  // SetIamPolicy: Sets the access control policy on the specified resource.
  3855  // Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`,
  3856  // and `PERMISSION_DENIED` errors.
  3857  //
  3858  //   - resource: REQUIRED: The resource for which the policy is being specified.
  3859  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  3860  //     for the appropriate value for this field.
  3861  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsWorkstationClustersWorkstationConfigsSetIamPolicyCall {
  3862  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3863  	c.resource = resource
  3864  	c.setiampolicyrequest = setiampolicyrequest
  3865  	return c
  3866  }
  3867  
  3868  // Fields allows partial responses to be retrieved. See
  3869  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3870  // details.
  3871  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsSetIamPolicyCall {
  3872  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3873  	return c
  3874  }
  3875  
  3876  // Context sets the context to be used in this call's Do method.
  3877  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsSetIamPolicyCall {
  3878  	c.ctx_ = ctx
  3879  	return c
  3880  }
  3881  
  3882  // Header returns a http.Header that can be modified by the caller to add
  3883  // headers to the request.
  3884  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsSetIamPolicyCall) Header() http.Header {
  3885  	if c.header_ == nil {
  3886  		c.header_ = make(http.Header)
  3887  	}
  3888  	return c.header_
  3889  }
  3890  
  3891  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsSetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  3892  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  3893  	var body io.Reader = nil
  3894  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.setiampolicyrequest)
  3895  	if err != nil {
  3896  		return nil, err
  3897  	}
  3898  	c.urlParams_.Set("alt", alt)
  3899  	c.urlParams_.Set("prettyPrint", "false")
  3900  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+resource}:setIamPolicy")
  3901  	urls += "?" + c.urlParams_.Encode()
  3902  	req, err := http.NewRequest("POST", urls, body)
  3903  	if err != nil {
  3904  		return nil, err
  3905  	}
  3906  	req.Header = reqHeaders
  3907  	googleapi.Expand(req.URL, map[string]string{
  3908  		"resource": c.resource,
  3909  	})
  3910  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  3911  }
  3912  
  3913  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.setIamPolicy" call.
  3914  // Any non-2xx status code is an error. Response headers are in either
  3915  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  3916  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  3917  // whether the returned error was because http.StatusNotModified was returned.
  3918  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  3919  	gensupport.SetOptions(c.urlParams_, opts...)
  3920  	res, err := c.doRequest("json")
  3921  	if res != nil && res.StatusCode == http.StatusNotModified {
  3922  		if res.Body != nil {
  3923  			res.Body.Close()
  3924  		}
  3925  		return nil, gensupport.WrapError(&googleapi.Error{
  3926  			Code:   res.StatusCode,
  3927  			Header: res.Header,
  3928  		})
  3929  	}
  3930  	if err != nil {
  3931  		return nil, err
  3932  	}
  3933  	defer googleapi.CloseBody(res)
  3934  	if err := googleapi.CheckResponse(res); err != nil {
  3935  		return nil, gensupport.WrapError(err)
  3936  	}
  3937  	ret := &Policy{
  3938  		ServerResponse: googleapi.ServerResponse{
  3939  			Header:         res.Header,
  3940  			HTTPStatusCode: res.StatusCode,
  3941  		},
  3942  	}
  3943  	target := &ret
  3944  	if err := gensupport.DecodeResponse(target, res); err != nil {
  3945  		return nil, err
  3946  	}
  3947  	return ret, nil
  3948  }
  3949  
  3950  type ProjectsLocationsWorkstationClustersWorkstationConfigsTestIamPermissionsCall struct {
  3951  	s                         *Service
  3952  	resource                  string
  3953  	testiampermissionsrequest *TestIamPermissionsRequest
  3954  	urlParams_                gensupport.URLParams
  3955  	ctx_                      context.Context
  3956  	header_                   http.Header
  3957  }
  3958  
  3959  // TestIamPermissions: Returns permissions that a caller has on the specified
  3960  // resource. If the resource does not exist, this will return an empty set of
  3961  // permissions, not a `NOT_FOUND` error. Note: This operation is designed to be
  3962  // used for building permission-aware UIs and command-line tools, not for
  3963  // authorization checking. This operation may "fail open" without warning.
  3964  //
  3965  //   - resource: REQUIRED: The resource for which the policy detail is being
  3966  //     requested. See Resource names
  3967  //     (https://cloud.google.com/apis/design/resource_names) for the appropriate
  3968  //     value for this field.
  3969  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsLocationsWorkstationClustersWorkstationConfigsTestIamPermissionsCall {
  3970  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  3971  	c.resource = resource
  3972  	c.testiampermissionsrequest = testiampermissionsrequest
  3973  	return c
  3974  }
  3975  
  3976  // Fields allows partial responses to be retrieved. See
  3977  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  3978  // details.
  3979  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsTestIamPermissionsCall {
  3980  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  3981  	return c
  3982  }
  3983  
  3984  // Context sets the context to be used in this call's Do method.
  3985  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsTestIamPermissionsCall {
  3986  	c.ctx_ = ctx
  3987  	return c
  3988  }
  3989  
  3990  // Header returns a http.Header that can be modified by the caller to add
  3991  // headers to the request.
  3992  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsTestIamPermissionsCall) Header() http.Header {
  3993  	if c.header_ == nil {
  3994  		c.header_ = make(http.Header)
  3995  	}
  3996  	return c.header_
  3997  }
  3998  
  3999  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) {
  4000  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  4001  	var body io.Reader = nil
  4002  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.testiampermissionsrequest)
  4003  	if err != nil {
  4004  		return nil, err
  4005  	}
  4006  	c.urlParams_.Set("alt", alt)
  4007  	c.urlParams_.Set("prettyPrint", "false")
  4008  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+resource}:testIamPermissions")
  4009  	urls += "?" + c.urlParams_.Encode()
  4010  	req, err := http.NewRequest("POST", urls, body)
  4011  	if err != nil {
  4012  		return nil, err
  4013  	}
  4014  	req.Header = reqHeaders
  4015  	googleapi.Expand(req.URL, map[string]string{
  4016  		"resource": c.resource,
  4017  	})
  4018  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4019  }
  4020  
  4021  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.testIamPermissions" call.
  4022  // Any non-2xx status code is an error. Response headers are in either
  4023  // *TestIamPermissionsResponse.ServerResponse.Header or (if a response was
  4024  // returned at all) in error.(*googleapi.Error).Header. Use
  4025  // googleapi.IsNotModified to check whether the returned error was because
  4026  // http.StatusNotModified was returned.
  4027  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) {
  4028  	gensupport.SetOptions(c.urlParams_, opts...)
  4029  	res, err := c.doRequest("json")
  4030  	if res != nil && res.StatusCode == http.StatusNotModified {
  4031  		if res.Body != nil {
  4032  			res.Body.Close()
  4033  		}
  4034  		return nil, gensupport.WrapError(&googleapi.Error{
  4035  			Code:   res.StatusCode,
  4036  			Header: res.Header,
  4037  		})
  4038  	}
  4039  	if err != nil {
  4040  		return nil, err
  4041  	}
  4042  	defer googleapi.CloseBody(res)
  4043  	if err := googleapi.CheckResponse(res); err != nil {
  4044  		return nil, gensupport.WrapError(err)
  4045  	}
  4046  	ret := &TestIamPermissionsResponse{
  4047  		ServerResponse: googleapi.ServerResponse{
  4048  			Header:         res.Header,
  4049  			HTTPStatusCode: res.StatusCode,
  4050  		},
  4051  	}
  4052  	target := &ret
  4053  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4054  		return nil, err
  4055  	}
  4056  	return ret, nil
  4057  }
  4058  
  4059  type ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsCreateCall struct {
  4060  	s           *Service
  4061  	parent      string
  4062  	workstation *Workstation
  4063  	urlParams_  gensupport.URLParams
  4064  	ctx_        context.Context
  4065  	header_     http.Header
  4066  }
  4067  
  4068  // Create: Creates a new workstation.
  4069  //
  4070  // - parent: Parent resource name.
  4071  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService) Create(parent string, workstation *Workstation) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsCreateCall {
  4072  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4073  	c.parent = parent
  4074  	c.workstation = workstation
  4075  	return c
  4076  }
  4077  
  4078  // ValidateOnly sets the optional parameter "validateOnly": If set, validate
  4079  // the request and preview the review, but do not actually apply it.
  4080  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsCreateCall) ValidateOnly(validateOnly bool) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsCreateCall {
  4081  	c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly))
  4082  	return c
  4083  }
  4084  
  4085  // WorkstationId sets the optional parameter "workstationId": Required. ID to
  4086  // use for the workstation.
  4087  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsCreateCall) WorkstationId(workstationId string) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsCreateCall {
  4088  	c.urlParams_.Set("workstationId", workstationId)
  4089  	return c
  4090  }
  4091  
  4092  // Fields allows partial responses to be retrieved. See
  4093  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4094  // details.
  4095  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsCreateCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsCreateCall {
  4096  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4097  	return c
  4098  }
  4099  
  4100  // Context sets the context to be used in this call's Do method.
  4101  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsCreateCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsCreateCall {
  4102  	c.ctx_ = ctx
  4103  	return c
  4104  }
  4105  
  4106  // Header returns a http.Header that can be modified by the caller to add
  4107  // headers to the request.
  4108  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsCreateCall) Header() http.Header {
  4109  	if c.header_ == nil {
  4110  		c.header_ = make(http.Header)
  4111  	}
  4112  	return c.header_
  4113  }
  4114  
  4115  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsCreateCall) doRequest(alt string) (*http.Response, error) {
  4116  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  4117  	var body io.Reader = nil
  4118  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.workstation)
  4119  	if err != nil {
  4120  		return nil, err
  4121  	}
  4122  	c.urlParams_.Set("alt", alt)
  4123  	c.urlParams_.Set("prettyPrint", "false")
  4124  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/workstations")
  4125  	urls += "?" + c.urlParams_.Encode()
  4126  	req, err := http.NewRequest("POST", urls, body)
  4127  	if err != nil {
  4128  		return nil, err
  4129  	}
  4130  	req.Header = reqHeaders
  4131  	googleapi.Expand(req.URL, map[string]string{
  4132  		"parent": c.parent,
  4133  	})
  4134  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4135  }
  4136  
  4137  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.workstations.create" call.
  4138  // Any non-2xx status code is an error. Response headers are in either
  4139  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  4140  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  4141  // whether the returned error was because http.StatusNotModified was returned.
  4142  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsCreateCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  4143  	gensupport.SetOptions(c.urlParams_, opts...)
  4144  	res, err := c.doRequest("json")
  4145  	if res != nil && res.StatusCode == http.StatusNotModified {
  4146  		if res.Body != nil {
  4147  			res.Body.Close()
  4148  		}
  4149  		return nil, gensupport.WrapError(&googleapi.Error{
  4150  			Code:   res.StatusCode,
  4151  			Header: res.Header,
  4152  		})
  4153  	}
  4154  	if err != nil {
  4155  		return nil, err
  4156  	}
  4157  	defer googleapi.CloseBody(res)
  4158  	if err := googleapi.CheckResponse(res); err != nil {
  4159  		return nil, gensupport.WrapError(err)
  4160  	}
  4161  	ret := &Operation{
  4162  		ServerResponse: googleapi.ServerResponse{
  4163  			Header:         res.Header,
  4164  			HTTPStatusCode: res.StatusCode,
  4165  		},
  4166  	}
  4167  	target := &ret
  4168  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4169  		return nil, err
  4170  	}
  4171  	return ret, nil
  4172  }
  4173  
  4174  type ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsDeleteCall struct {
  4175  	s          *Service
  4176  	name       string
  4177  	urlParams_ gensupport.URLParams
  4178  	ctx_       context.Context
  4179  	header_    http.Header
  4180  }
  4181  
  4182  // Delete: Deletes the specified workstation.
  4183  //
  4184  // - name: Name of the workstation to delete.
  4185  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService) Delete(name string) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsDeleteCall {
  4186  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4187  	c.name = name
  4188  	return c
  4189  }
  4190  
  4191  // Etag sets the optional parameter "etag": If set, the request will be
  4192  // rejected if the latest version of the workstation on the server does not
  4193  // have this ETag.
  4194  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsDeleteCall) Etag(etag string) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsDeleteCall {
  4195  	c.urlParams_.Set("etag", etag)
  4196  	return c
  4197  }
  4198  
  4199  // ValidateOnly sets the optional parameter "validateOnly": If set, validate
  4200  // the request and preview the review, but do not actually apply it.
  4201  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsDeleteCall) ValidateOnly(validateOnly bool) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsDeleteCall {
  4202  	c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly))
  4203  	return c
  4204  }
  4205  
  4206  // Fields allows partial responses to be retrieved. See
  4207  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4208  // details.
  4209  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsDeleteCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsDeleteCall {
  4210  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4211  	return c
  4212  }
  4213  
  4214  // Context sets the context to be used in this call's Do method.
  4215  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsDeleteCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsDeleteCall {
  4216  	c.ctx_ = ctx
  4217  	return c
  4218  }
  4219  
  4220  // Header returns a http.Header that can be modified by the caller to add
  4221  // headers to the request.
  4222  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsDeleteCall) Header() http.Header {
  4223  	if c.header_ == nil {
  4224  		c.header_ = make(http.Header)
  4225  	}
  4226  	return c.header_
  4227  }
  4228  
  4229  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsDeleteCall) doRequest(alt string) (*http.Response, error) {
  4230  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  4231  	var body io.Reader = nil
  4232  	c.urlParams_.Set("alt", alt)
  4233  	c.urlParams_.Set("prettyPrint", "false")
  4234  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  4235  	urls += "?" + c.urlParams_.Encode()
  4236  	req, err := http.NewRequest("DELETE", urls, body)
  4237  	if err != nil {
  4238  		return nil, err
  4239  	}
  4240  	req.Header = reqHeaders
  4241  	googleapi.Expand(req.URL, map[string]string{
  4242  		"name": c.name,
  4243  	})
  4244  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4245  }
  4246  
  4247  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.workstations.delete" call.
  4248  // Any non-2xx status code is an error. Response headers are in either
  4249  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  4250  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  4251  // whether the returned error was because http.StatusNotModified was returned.
  4252  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsDeleteCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  4253  	gensupport.SetOptions(c.urlParams_, opts...)
  4254  	res, err := c.doRequest("json")
  4255  	if res != nil && res.StatusCode == http.StatusNotModified {
  4256  		if res.Body != nil {
  4257  			res.Body.Close()
  4258  		}
  4259  		return nil, gensupport.WrapError(&googleapi.Error{
  4260  			Code:   res.StatusCode,
  4261  			Header: res.Header,
  4262  		})
  4263  	}
  4264  	if err != nil {
  4265  		return nil, err
  4266  	}
  4267  	defer googleapi.CloseBody(res)
  4268  	if err := googleapi.CheckResponse(res); err != nil {
  4269  		return nil, gensupport.WrapError(err)
  4270  	}
  4271  	ret := &Operation{
  4272  		ServerResponse: googleapi.ServerResponse{
  4273  			Header:         res.Header,
  4274  			HTTPStatusCode: res.StatusCode,
  4275  		},
  4276  	}
  4277  	target := &ret
  4278  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4279  		return nil, err
  4280  	}
  4281  	return ret, nil
  4282  }
  4283  
  4284  type ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGenerateAccessTokenCall struct {
  4285  	s                          *Service
  4286  	workstation                string
  4287  	generateaccesstokenrequest *GenerateAccessTokenRequest
  4288  	urlParams_                 gensupport.URLParams
  4289  	ctx_                       context.Context
  4290  	header_                    http.Header
  4291  }
  4292  
  4293  // GenerateAccessToken: Returns a short-lived credential that can be used to
  4294  // send authenticated and authorized traffic to a workstation.
  4295  //
  4296  //   - workstation: Name of the workstation for which the access token should be
  4297  //     generated.
  4298  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService) GenerateAccessToken(workstation string, generateaccesstokenrequest *GenerateAccessTokenRequest) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGenerateAccessTokenCall {
  4299  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGenerateAccessTokenCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4300  	c.workstation = workstation
  4301  	c.generateaccesstokenrequest = generateaccesstokenrequest
  4302  	return c
  4303  }
  4304  
  4305  // Fields allows partial responses to be retrieved. See
  4306  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4307  // details.
  4308  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGenerateAccessTokenCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGenerateAccessTokenCall {
  4309  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4310  	return c
  4311  }
  4312  
  4313  // Context sets the context to be used in this call's Do method.
  4314  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGenerateAccessTokenCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGenerateAccessTokenCall {
  4315  	c.ctx_ = ctx
  4316  	return c
  4317  }
  4318  
  4319  // Header returns a http.Header that can be modified by the caller to add
  4320  // headers to the request.
  4321  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGenerateAccessTokenCall) Header() http.Header {
  4322  	if c.header_ == nil {
  4323  		c.header_ = make(http.Header)
  4324  	}
  4325  	return c.header_
  4326  }
  4327  
  4328  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGenerateAccessTokenCall) doRequest(alt string) (*http.Response, error) {
  4329  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  4330  	var body io.Reader = nil
  4331  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.generateaccesstokenrequest)
  4332  	if err != nil {
  4333  		return nil, err
  4334  	}
  4335  	c.urlParams_.Set("alt", alt)
  4336  	c.urlParams_.Set("prettyPrint", "false")
  4337  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+workstation}:generateAccessToken")
  4338  	urls += "?" + c.urlParams_.Encode()
  4339  	req, err := http.NewRequest("POST", urls, body)
  4340  	if err != nil {
  4341  		return nil, err
  4342  	}
  4343  	req.Header = reqHeaders
  4344  	googleapi.Expand(req.URL, map[string]string{
  4345  		"workstation": c.workstation,
  4346  	})
  4347  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4348  }
  4349  
  4350  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.workstations.generateAccessToken" call.
  4351  // Any non-2xx status code is an error. Response headers are in either
  4352  // *GenerateAccessTokenResponse.ServerResponse.Header or (if a response was
  4353  // returned at all) in error.(*googleapi.Error).Header. Use
  4354  // googleapi.IsNotModified to check whether the returned error was because
  4355  // http.StatusNotModified was returned.
  4356  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGenerateAccessTokenCall) Do(opts ...googleapi.CallOption) (*GenerateAccessTokenResponse, error) {
  4357  	gensupport.SetOptions(c.urlParams_, opts...)
  4358  	res, err := c.doRequest("json")
  4359  	if res != nil && res.StatusCode == http.StatusNotModified {
  4360  		if res.Body != nil {
  4361  			res.Body.Close()
  4362  		}
  4363  		return nil, gensupport.WrapError(&googleapi.Error{
  4364  			Code:   res.StatusCode,
  4365  			Header: res.Header,
  4366  		})
  4367  	}
  4368  	if err != nil {
  4369  		return nil, err
  4370  	}
  4371  	defer googleapi.CloseBody(res)
  4372  	if err := googleapi.CheckResponse(res); err != nil {
  4373  		return nil, gensupport.WrapError(err)
  4374  	}
  4375  	ret := &GenerateAccessTokenResponse{
  4376  		ServerResponse: googleapi.ServerResponse{
  4377  			Header:         res.Header,
  4378  			HTTPStatusCode: res.StatusCode,
  4379  		},
  4380  	}
  4381  	target := &ret
  4382  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4383  		return nil, err
  4384  	}
  4385  	return ret, nil
  4386  }
  4387  
  4388  type ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetCall struct {
  4389  	s            *Service
  4390  	name         string
  4391  	urlParams_   gensupport.URLParams
  4392  	ifNoneMatch_ string
  4393  	ctx_         context.Context
  4394  	header_      http.Header
  4395  }
  4396  
  4397  // Get: Returns the requested workstation.
  4398  //
  4399  // - name: Name of the requested resource.
  4400  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService) Get(name string) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetCall {
  4401  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4402  	c.name = name
  4403  	return c
  4404  }
  4405  
  4406  // Fields allows partial responses to be retrieved. See
  4407  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4408  // details.
  4409  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetCall {
  4410  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4411  	return c
  4412  }
  4413  
  4414  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  4415  // object's ETag matches the given value. This is useful for getting updates
  4416  // only after the object has changed since the last request.
  4417  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetCall) IfNoneMatch(entityTag string) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetCall {
  4418  	c.ifNoneMatch_ = entityTag
  4419  	return c
  4420  }
  4421  
  4422  // Context sets the context to be used in this call's Do method.
  4423  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetCall {
  4424  	c.ctx_ = ctx
  4425  	return c
  4426  }
  4427  
  4428  // Header returns a http.Header that can be modified by the caller to add
  4429  // headers to the request.
  4430  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetCall) Header() http.Header {
  4431  	if c.header_ == nil {
  4432  		c.header_ = make(http.Header)
  4433  	}
  4434  	return c.header_
  4435  }
  4436  
  4437  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetCall) doRequest(alt string) (*http.Response, error) {
  4438  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  4439  	if c.ifNoneMatch_ != "" {
  4440  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  4441  	}
  4442  	var body io.Reader = nil
  4443  	c.urlParams_.Set("alt", alt)
  4444  	c.urlParams_.Set("prettyPrint", "false")
  4445  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  4446  	urls += "?" + c.urlParams_.Encode()
  4447  	req, err := http.NewRequest("GET", urls, body)
  4448  	if err != nil {
  4449  		return nil, err
  4450  	}
  4451  	req.Header = reqHeaders
  4452  	googleapi.Expand(req.URL, map[string]string{
  4453  		"name": c.name,
  4454  	})
  4455  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4456  }
  4457  
  4458  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.workstations.get" call.
  4459  // Any non-2xx status code is an error. Response headers are in either
  4460  // *Workstation.ServerResponse.Header or (if a response was returned at all) in
  4461  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  4462  // whether the returned error was because http.StatusNotModified was returned.
  4463  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetCall) Do(opts ...googleapi.CallOption) (*Workstation, error) {
  4464  	gensupport.SetOptions(c.urlParams_, opts...)
  4465  	res, err := c.doRequest("json")
  4466  	if res != nil && res.StatusCode == http.StatusNotModified {
  4467  		if res.Body != nil {
  4468  			res.Body.Close()
  4469  		}
  4470  		return nil, gensupport.WrapError(&googleapi.Error{
  4471  			Code:   res.StatusCode,
  4472  			Header: res.Header,
  4473  		})
  4474  	}
  4475  	if err != nil {
  4476  		return nil, err
  4477  	}
  4478  	defer googleapi.CloseBody(res)
  4479  	if err := googleapi.CheckResponse(res); err != nil {
  4480  		return nil, gensupport.WrapError(err)
  4481  	}
  4482  	ret := &Workstation{
  4483  		ServerResponse: googleapi.ServerResponse{
  4484  			Header:         res.Header,
  4485  			HTTPStatusCode: res.StatusCode,
  4486  		},
  4487  	}
  4488  	target := &ret
  4489  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4490  		return nil, err
  4491  	}
  4492  	return ret, nil
  4493  }
  4494  
  4495  type ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetIamPolicyCall struct {
  4496  	s            *Service
  4497  	resource     string
  4498  	urlParams_   gensupport.URLParams
  4499  	ifNoneMatch_ string
  4500  	ctx_         context.Context
  4501  	header_      http.Header
  4502  }
  4503  
  4504  // GetIamPolicy: Gets the access control policy for a resource. Returns an
  4505  // empty policy if the resource exists and does not have a policy set.
  4506  //
  4507  //   - resource: REQUIRED: The resource for which the policy is being requested.
  4508  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  4509  //     for the appropriate value for this field.
  4510  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService) GetIamPolicy(resource string) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetIamPolicyCall {
  4511  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4512  	c.resource = resource
  4513  	return c
  4514  }
  4515  
  4516  // OptionsRequestedPolicyVersion sets the optional parameter
  4517  // "options.requestedPolicyVersion": The maximum policy version that will be
  4518  // used to format the policy. Valid values are 0, 1, and 3. Requests specifying
  4519  // an invalid value will be rejected. Requests for policies with any
  4520  // conditional role bindings must specify version 3. Policies with no
  4521  // conditional role bindings may specify any valid value or leave the field
  4522  // unset. The policy in the response might use the policy version that you
  4523  // specified, or it might use a lower policy version. For example, if you
  4524  // specify version 3, but the policy has no conditional role bindings, the
  4525  // response uses version 1. To learn which resources support conditions in
  4526  // their IAM policies, see the IAM documentation
  4527  // (https://cloud.google.com/iam/help/conditions/resource-policies).
  4528  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetIamPolicyCall {
  4529  	c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion))
  4530  	return c
  4531  }
  4532  
  4533  // Fields allows partial responses to be retrieved. See
  4534  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4535  // details.
  4536  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetIamPolicyCall {
  4537  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4538  	return c
  4539  }
  4540  
  4541  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  4542  // object's ETag matches the given value. This is useful for getting updates
  4543  // only after the object has changed since the last request.
  4544  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetIamPolicyCall) IfNoneMatch(entityTag string) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetIamPolicyCall {
  4545  	c.ifNoneMatch_ = entityTag
  4546  	return c
  4547  }
  4548  
  4549  // Context sets the context to be used in this call's Do method.
  4550  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetIamPolicyCall {
  4551  	c.ctx_ = ctx
  4552  	return c
  4553  }
  4554  
  4555  // Header returns a http.Header that can be modified by the caller to add
  4556  // headers to the request.
  4557  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetIamPolicyCall) Header() http.Header {
  4558  	if c.header_ == nil {
  4559  		c.header_ = make(http.Header)
  4560  	}
  4561  	return c.header_
  4562  }
  4563  
  4564  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  4565  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  4566  	if c.ifNoneMatch_ != "" {
  4567  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  4568  	}
  4569  	var body io.Reader = nil
  4570  	c.urlParams_.Set("alt", alt)
  4571  	c.urlParams_.Set("prettyPrint", "false")
  4572  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+resource}:getIamPolicy")
  4573  	urls += "?" + c.urlParams_.Encode()
  4574  	req, err := http.NewRequest("GET", urls, body)
  4575  	if err != nil {
  4576  		return nil, err
  4577  	}
  4578  	req.Header = reqHeaders
  4579  	googleapi.Expand(req.URL, map[string]string{
  4580  		"resource": c.resource,
  4581  	})
  4582  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4583  }
  4584  
  4585  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.workstations.getIamPolicy" call.
  4586  // Any non-2xx status code is an error. Response headers are in either
  4587  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  4588  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  4589  // whether the returned error was because http.StatusNotModified was returned.
  4590  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  4591  	gensupport.SetOptions(c.urlParams_, opts...)
  4592  	res, err := c.doRequest("json")
  4593  	if res != nil && res.StatusCode == http.StatusNotModified {
  4594  		if res.Body != nil {
  4595  			res.Body.Close()
  4596  		}
  4597  		return nil, gensupport.WrapError(&googleapi.Error{
  4598  			Code:   res.StatusCode,
  4599  			Header: res.Header,
  4600  		})
  4601  	}
  4602  	if err != nil {
  4603  		return nil, err
  4604  	}
  4605  	defer googleapi.CloseBody(res)
  4606  	if err := googleapi.CheckResponse(res); err != nil {
  4607  		return nil, gensupport.WrapError(err)
  4608  	}
  4609  	ret := &Policy{
  4610  		ServerResponse: googleapi.ServerResponse{
  4611  			Header:         res.Header,
  4612  			HTTPStatusCode: res.StatusCode,
  4613  		},
  4614  	}
  4615  	target := &ret
  4616  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4617  		return nil, err
  4618  	}
  4619  	return ret, nil
  4620  }
  4621  
  4622  type ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListCall struct {
  4623  	s            *Service
  4624  	parent       string
  4625  	urlParams_   gensupport.URLParams
  4626  	ifNoneMatch_ string
  4627  	ctx_         context.Context
  4628  	header_      http.Header
  4629  }
  4630  
  4631  // List: Returns all Workstations using the specified workstation
  4632  // configuration.
  4633  //
  4634  // - parent: Parent resource name.
  4635  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService) List(parent string) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListCall {
  4636  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4637  	c.parent = parent
  4638  	return c
  4639  }
  4640  
  4641  // PageSize sets the optional parameter "pageSize": Maximum number of items to
  4642  // return.
  4643  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListCall) PageSize(pageSize int64) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListCall {
  4644  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  4645  	return c
  4646  }
  4647  
  4648  // PageToken sets the optional parameter "pageToken": next_page_token value
  4649  // returned from a previous List request, if any.
  4650  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListCall) PageToken(pageToken string) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListCall {
  4651  	c.urlParams_.Set("pageToken", pageToken)
  4652  	return c
  4653  }
  4654  
  4655  // Fields allows partial responses to be retrieved. See
  4656  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4657  // details.
  4658  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListCall {
  4659  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4660  	return c
  4661  }
  4662  
  4663  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  4664  // object's ETag matches the given value. This is useful for getting updates
  4665  // only after the object has changed since the last request.
  4666  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListCall) IfNoneMatch(entityTag string) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListCall {
  4667  	c.ifNoneMatch_ = entityTag
  4668  	return c
  4669  }
  4670  
  4671  // Context sets the context to be used in this call's Do method.
  4672  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListCall {
  4673  	c.ctx_ = ctx
  4674  	return c
  4675  }
  4676  
  4677  // Header returns a http.Header that can be modified by the caller to add
  4678  // headers to the request.
  4679  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListCall) Header() http.Header {
  4680  	if c.header_ == nil {
  4681  		c.header_ = make(http.Header)
  4682  	}
  4683  	return c.header_
  4684  }
  4685  
  4686  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListCall) doRequest(alt string) (*http.Response, error) {
  4687  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  4688  	if c.ifNoneMatch_ != "" {
  4689  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  4690  	}
  4691  	var body io.Reader = nil
  4692  	c.urlParams_.Set("alt", alt)
  4693  	c.urlParams_.Set("prettyPrint", "false")
  4694  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/workstations")
  4695  	urls += "?" + c.urlParams_.Encode()
  4696  	req, err := http.NewRequest("GET", urls, body)
  4697  	if err != nil {
  4698  		return nil, err
  4699  	}
  4700  	req.Header = reqHeaders
  4701  	googleapi.Expand(req.URL, map[string]string{
  4702  		"parent": c.parent,
  4703  	})
  4704  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4705  }
  4706  
  4707  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.workstations.list" call.
  4708  // Any non-2xx status code is an error. Response headers are in either
  4709  // *ListWorkstationsResponse.ServerResponse.Header or (if a response was
  4710  // returned at all) in error.(*googleapi.Error).Header. Use
  4711  // googleapi.IsNotModified to check whether the returned error was because
  4712  // http.StatusNotModified was returned.
  4713  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListCall) Do(opts ...googleapi.CallOption) (*ListWorkstationsResponse, error) {
  4714  	gensupport.SetOptions(c.urlParams_, opts...)
  4715  	res, err := c.doRequest("json")
  4716  	if res != nil && res.StatusCode == http.StatusNotModified {
  4717  		if res.Body != nil {
  4718  			res.Body.Close()
  4719  		}
  4720  		return nil, gensupport.WrapError(&googleapi.Error{
  4721  			Code:   res.StatusCode,
  4722  			Header: res.Header,
  4723  		})
  4724  	}
  4725  	if err != nil {
  4726  		return nil, err
  4727  	}
  4728  	defer googleapi.CloseBody(res)
  4729  	if err := googleapi.CheckResponse(res); err != nil {
  4730  		return nil, gensupport.WrapError(err)
  4731  	}
  4732  	ret := &ListWorkstationsResponse{
  4733  		ServerResponse: googleapi.ServerResponse{
  4734  			Header:         res.Header,
  4735  			HTTPStatusCode: res.StatusCode,
  4736  		},
  4737  	}
  4738  	target := &ret
  4739  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4740  		return nil, err
  4741  	}
  4742  	return ret, nil
  4743  }
  4744  
  4745  // Pages invokes f for each page of results.
  4746  // A non-nil error returned from f will halt the iteration.
  4747  // The provided context supersedes any context provided to the Context method.
  4748  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListCall) Pages(ctx context.Context, f func(*ListWorkstationsResponse) error) error {
  4749  	c.ctx_ = ctx
  4750  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  4751  	for {
  4752  		x, err := c.Do()
  4753  		if err != nil {
  4754  			return err
  4755  		}
  4756  		if err := f(x); err != nil {
  4757  			return err
  4758  		}
  4759  		if x.NextPageToken == "" {
  4760  			return nil
  4761  		}
  4762  		c.PageToken(x.NextPageToken)
  4763  	}
  4764  }
  4765  
  4766  type ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListUsableCall struct {
  4767  	s            *Service
  4768  	parent       string
  4769  	urlParams_   gensupport.URLParams
  4770  	ifNoneMatch_ string
  4771  	ctx_         context.Context
  4772  	header_      http.Header
  4773  }
  4774  
  4775  // ListUsable: Returns all workstations using the specified workstation
  4776  // configuration on which the caller has the "workstations.workstations.use"
  4777  // permission.
  4778  //
  4779  // - parent: Parent resource name.
  4780  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService) ListUsable(parent string) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListUsableCall {
  4781  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListUsableCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4782  	c.parent = parent
  4783  	return c
  4784  }
  4785  
  4786  // PageSize sets the optional parameter "pageSize": Maximum number of items to
  4787  // return.
  4788  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListUsableCall) PageSize(pageSize int64) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListUsableCall {
  4789  	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
  4790  	return c
  4791  }
  4792  
  4793  // PageToken sets the optional parameter "pageToken": next_page_token value
  4794  // returned from a previous List request, if any.
  4795  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListUsableCall) PageToken(pageToken string) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListUsableCall {
  4796  	c.urlParams_.Set("pageToken", pageToken)
  4797  	return c
  4798  }
  4799  
  4800  // Fields allows partial responses to be retrieved. See
  4801  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4802  // details.
  4803  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListUsableCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListUsableCall {
  4804  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4805  	return c
  4806  }
  4807  
  4808  // IfNoneMatch sets an optional parameter which makes the operation fail if the
  4809  // object's ETag matches the given value. This is useful for getting updates
  4810  // only after the object has changed since the last request.
  4811  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListUsableCall) IfNoneMatch(entityTag string) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListUsableCall {
  4812  	c.ifNoneMatch_ = entityTag
  4813  	return c
  4814  }
  4815  
  4816  // Context sets the context to be used in this call's Do method.
  4817  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListUsableCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListUsableCall {
  4818  	c.ctx_ = ctx
  4819  	return c
  4820  }
  4821  
  4822  // Header returns a http.Header that can be modified by the caller to add
  4823  // headers to the request.
  4824  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListUsableCall) Header() http.Header {
  4825  	if c.header_ == nil {
  4826  		c.header_ = make(http.Header)
  4827  	}
  4828  	return c.header_
  4829  }
  4830  
  4831  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListUsableCall) doRequest(alt string) (*http.Response, error) {
  4832  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "", c.header_)
  4833  	if c.ifNoneMatch_ != "" {
  4834  		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
  4835  	}
  4836  	var body io.Reader = nil
  4837  	c.urlParams_.Set("alt", alt)
  4838  	c.urlParams_.Set("prettyPrint", "false")
  4839  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+parent}/workstations:listUsable")
  4840  	urls += "?" + c.urlParams_.Encode()
  4841  	req, err := http.NewRequest("GET", urls, body)
  4842  	if err != nil {
  4843  		return nil, err
  4844  	}
  4845  	req.Header = reqHeaders
  4846  	googleapi.Expand(req.URL, map[string]string{
  4847  		"parent": c.parent,
  4848  	})
  4849  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4850  }
  4851  
  4852  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.workstations.listUsable" call.
  4853  // Any non-2xx status code is an error. Response headers are in either
  4854  // *ListUsableWorkstationsResponse.ServerResponse.Header or (if a response was
  4855  // returned at all) in error.(*googleapi.Error).Header. Use
  4856  // googleapi.IsNotModified to check whether the returned error was because
  4857  // http.StatusNotModified was returned.
  4858  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListUsableCall) Do(opts ...googleapi.CallOption) (*ListUsableWorkstationsResponse, error) {
  4859  	gensupport.SetOptions(c.urlParams_, opts...)
  4860  	res, err := c.doRequest("json")
  4861  	if res != nil && res.StatusCode == http.StatusNotModified {
  4862  		if res.Body != nil {
  4863  			res.Body.Close()
  4864  		}
  4865  		return nil, gensupport.WrapError(&googleapi.Error{
  4866  			Code:   res.StatusCode,
  4867  			Header: res.Header,
  4868  		})
  4869  	}
  4870  	if err != nil {
  4871  		return nil, err
  4872  	}
  4873  	defer googleapi.CloseBody(res)
  4874  	if err := googleapi.CheckResponse(res); err != nil {
  4875  		return nil, gensupport.WrapError(err)
  4876  	}
  4877  	ret := &ListUsableWorkstationsResponse{
  4878  		ServerResponse: googleapi.ServerResponse{
  4879  			Header:         res.Header,
  4880  			HTTPStatusCode: res.StatusCode,
  4881  		},
  4882  	}
  4883  	target := &ret
  4884  	if err := gensupport.DecodeResponse(target, res); err != nil {
  4885  		return nil, err
  4886  	}
  4887  	return ret, nil
  4888  }
  4889  
  4890  // Pages invokes f for each page of results.
  4891  // A non-nil error returned from f will halt the iteration.
  4892  // The provided context supersedes any context provided to the Context method.
  4893  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsListUsableCall) Pages(ctx context.Context, f func(*ListUsableWorkstationsResponse) error) error {
  4894  	c.ctx_ = ctx
  4895  	defer c.PageToken(c.urlParams_.Get("pageToken"))
  4896  	for {
  4897  		x, err := c.Do()
  4898  		if err != nil {
  4899  			return err
  4900  		}
  4901  		if err := f(x); err != nil {
  4902  			return err
  4903  		}
  4904  		if x.NextPageToken == "" {
  4905  			return nil
  4906  		}
  4907  		c.PageToken(x.NextPageToken)
  4908  	}
  4909  }
  4910  
  4911  type ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsPatchCall struct {
  4912  	s           *Service
  4913  	name        string
  4914  	workstation *Workstation
  4915  	urlParams_  gensupport.URLParams
  4916  	ctx_        context.Context
  4917  	header_     http.Header
  4918  }
  4919  
  4920  // Patch: Updates an existing workstation.
  4921  //
  4922  // - name: Identifier. Full name of this workstation.
  4923  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService) Patch(name string, workstation *Workstation) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsPatchCall {
  4924  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  4925  	c.name = name
  4926  	c.workstation = workstation
  4927  	return c
  4928  }
  4929  
  4930  // AllowMissing sets the optional parameter "allowMissing": If set and the
  4931  // workstation configuration is not found, a new workstation configuration is
  4932  // created. In this situation, update_mask is ignored.
  4933  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsPatchCall) AllowMissing(allowMissing bool) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsPatchCall {
  4934  	c.urlParams_.Set("allowMissing", fmt.Sprint(allowMissing))
  4935  	return c
  4936  }
  4937  
  4938  // UpdateMask sets the optional parameter "updateMask": Required. Mask
  4939  // specifying which fields in the workstation configuration should be updated.
  4940  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsPatchCall) UpdateMask(updateMask string) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsPatchCall {
  4941  	c.urlParams_.Set("updateMask", updateMask)
  4942  	return c
  4943  }
  4944  
  4945  // ValidateOnly sets the optional parameter "validateOnly": If set, validate
  4946  // the request and preview the review, but do not actually apply it.
  4947  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsPatchCall) ValidateOnly(validateOnly bool) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsPatchCall {
  4948  	c.urlParams_.Set("validateOnly", fmt.Sprint(validateOnly))
  4949  	return c
  4950  }
  4951  
  4952  // Fields allows partial responses to be retrieved. See
  4953  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  4954  // details.
  4955  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsPatchCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsPatchCall {
  4956  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  4957  	return c
  4958  }
  4959  
  4960  // Context sets the context to be used in this call's Do method.
  4961  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsPatchCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsPatchCall {
  4962  	c.ctx_ = ctx
  4963  	return c
  4964  }
  4965  
  4966  // Header returns a http.Header that can be modified by the caller to add
  4967  // headers to the request.
  4968  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsPatchCall) Header() http.Header {
  4969  	if c.header_ == nil {
  4970  		c.header_ = make(http.Header)
  4971  	}
  4972  	return c.header_
  4973  }
  4974  
  4975  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsPatchCall) doRequest(alt string) (*http.Response, error) {
  4976  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  4977  	var body io.Reader = nil
  4978  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.workstation)
  4979  	if err != nil {
  4980  		return nil, err
  4981  	}
  4982  	c.urlParams_.Set("alt", alt)
  4983  	c.urlParams_.Set("prettyPrint", "false")
  4984  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}")
  4985  	urls += "?" + c.urlParams_.Encode()
  4986  	req, err := http.NewRequest("PATCH", urls, body)
  4987  	if err != nil {
  4988  		return nil, err
  4989  	}
  4990  	req.Header = reqHeaders
  4991  	googleapi.Expand(req.URL, map[string]string{
  4992  		"name": c.name,
  4993  	})
  4994  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  4995  }
  4996  
  4997  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.workstations.patch" call.
  4998  // Any non-2xx status code is an error. Response headers are in either
  4999  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  5000  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  5001  // whether the returned error was because http.StatusNotModified was returned.
  5002  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsPatchCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  5003  	gensupport.SetOptions(c.urlParams_, opts...)
  5004  	res, err := c.doRequest("json")
  5005  	if res != nil && res.StatusCode == http.StatusNotModified {
  5006  		if res.Body != nil {
  5007  			res.Body.Close()
  5008  		}
  5009  		return nil, gensupport.WrapError(&googleapi.Error{
  5010  			Code:   res.StatusCode,
  5011  			Header: res.Header,
  5012  		})
  5013  	}
  5014  	if err != nil {
  5015  		return nil, err
  5016  	}
  5017  	defer googleapi.CloseBody(res)
  5018  	if err := googleapi.CheckResponse(res); err != nil {
  5019  		return nil, gensupport.WrapError(err)
  5020  	}
  5021  	ret := &Operation{
  5022  		ServerResponse: googleapi.ServerResponse{
  5023  			Header:         res.Header,
  5024  			HTTPStatusCode: res.StatusCode,
  5025  		},
  5026  	}
  5027  	target := &ret
  5028  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5029  		return nil, err
  5030  	}
  5031  	return ret, nil
  5032  }
  5033  
  5034  type ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsSetIamPolicyCall struct {
  5035  	s                   *Service
  5036  	resource            string
  5037  	setiampolicyrequest *SetIamPolicyRequest
  5038  	urlParams_          gensupport.URLParams
  5039  	ctx_                context.Context
  5040  	header_             http.Header
  5041  }
  5042  
  5043  // SetIamPolicy: Sets the access control policy on the specified resource.
  5044  // Replaces any existing policy. Can return `NOT_FOUND`, `INVALID_ARGUMENT`,
  5045  // and `PERMISSION_DENIED` errors.
  5046  //
  5047  //   - resource: REQUIRED: The resource for which the policy is being specified.
  5048  //     See Resource names (https://cloud.google.com/apis/design/resource_names)
  5049  //     for the appropriate value for this field.
  5050  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService) SetIamPolicy(resource string, setiampolicyrequest *SetIamPolicyRequest) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsSetIamPolicyCall {
  5051  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  5052  	c.resource = resource
  5053  	c.setiampolicyrequest = setiampolicyrequest
  5054  	return c
  5055  }
  5056  
  5057  // Fields allows partial responses to be retrieved. See
  5058  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  5059  // details.
  5060  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsSetIamPolicyCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsSetIamPolicyCall {
  5061  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  5062  	return c
  5063  }
  5064  
  5065  // Context sets the context to be used in this call's Do method.
  5066  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsSetIamPolicyCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsSetIamPolicyCall {
  5067  	c.ctx_ = ctx
  5068  	return c
  5069  }
  5070  
  5071  // Header returns a http.Header that can be modified by the caller to add
  5072  // headers to the request.
  5073  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsSetIamPolicyCall) Header() http.Header {
  5074  	if c.header_ == nil {
  5075  		c.header_ = make(http.Header)
  5076  	}
  5077  	return c.header_
  5078  }
  5079  
  5080  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsSetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
  5081  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  5082  	var body io.Reader = nil
  5083  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.setiampolicyrequest)
  5084  	if err != nil {
  5085  		return nil, err
  5086  	}
  5087  	c.urlParams_.Set("alt", alt)
  5088  	c.urlParams_.Set("prettyPrint", "false")
  5089  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+resource}:setIamPolicy")
  5090  	urls += "?" + c.urlParams_.Encode()
  5091  	req, err := http.NewRequest("POST", urls, body)
  5092  	if err != nil {
  5093  		return nil, err
  5094  	}
  5095  	req.Header = reqHeaders
  5096  	googleapi.Expand(req.URL, map[string]string{
  5097  		"resource": c.resource,
  5098  	})
  5099  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5100  }
  5101  
  5102  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.workstations.setIamPolicy" call.
  5103  // Any non-2xx status code is an error. Response headers are in either
  5104  // *Policy.ServerResponse.Header or (if a response was returned at all) in
  5105  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  5106  // whether the returned error was because http.StatusNotModified was returned.
  5107  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*Policy, error) {
  5108  	gensupport.SetOptions(c.urlParams_, opts...)
  5109  	res, err := c.doRequest("json")
  5110  	if res != nil && res.StatusCode == http.StatusNotModified {
  5111  		if res.Body != nil {
  5112  			res.Body.Close()
  5113  		}
  5114  		return nil, gensupport.WrapError(&googleapi.Error{
  5115  			Code:   res.StatusCode,
  5116  			Header: res.Header,
  5117  		})
  5118  	}
  5119  	if err != nil {
  5120  		return nil, err
  5121  	}
  5122  	defer googleapi.CloseBody(res)
  5123  	if err := googleapi.CheckResponse(res); err != nil {
  5124  		return nil, gensupport.WrapError(err)
  5125  	}
  5126  	ret := &Policy{
  5127  		ServerResponse: googleapi.ServerResponse{
  5128  			Header:         res.Header,
  5129  			HTTPStatusCode: res.StatusCode,
  5130  		},
  5131  	}
  5132  	target := &ret
  5133  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5134  		return nil, err
  5135  	}
  5136  	return ret, nil
  5137  }
  5138  
  5139  type ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStartCall struct {
  5140  	s                       *Service
  5141  	name                    string
  5142  	startworkstationrequest *StartWorkstationRequest
  5143  	urlParams_              gensupport.URLParams
  5144  	ctx_                    context.Context
  5145  	header_                 http.Header
  5146  }
  5147  
  5148  // Start: Starts running a workstation so that users can connect to it.
  5149  //
  5150  // - name: Name of the workstation to start.
  5151  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService) Start(name string, startworkstationrequest *StartWorkstationRequest) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStartCall {
  5152  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStartCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  5153  	c.name = name
  5154  	c.startworkstationrequest = startworkstationrequest
  5155  	return c
  5156  }
  5157  
  5158  // Fields allows partial responses to be retrieved. See
  5159  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  5160  // details.
  5161  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStartCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStartCall {
  5162  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  5163  	return c
  5164  }
  5165  
  5166  // Context sets the context to be used in this call's Do method.
  5167  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStartCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStartCall {
  5168  	c.ctx_ = ctx
  5169  	return c
  5170  }
  5171  
  5172  // Header returns a http.Header that can be modified by the caller to add
  5173  // headers to the request.
  5174  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStartCall) Header() http.Header {
  5175  	if c.header_ == nil {
  5176  		c.header_ = make(http.Header)
  5177  	}
  5178  	return c.header_
  5179  }
  5180  
  5181  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStartCall) doRequest(alt string) (*http.Response, error) {
  5182  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  5183  	var body io.Reader = nil
  5184  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.startworkstationrequest)
  5185  	if err != nil {
  5186  		return nil, err
  5187  	}
  5188  	c.urlParams_.Set("alt", alt)
  5189  	c.urlParams_.Set("prettyPrint", "false")
  5190  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}:start")
  5191  	urls += "?" + c.urlParams_.Encode()
  5192  	req, err := http.NewRequest("POST", urls, body)
  5193  	if err != nil {
  5194  		return nil, err
  5195  	}
  5196  	req.Header = reqHeaders
  5197  	googleapi.Expand(req.URL, map[string]string{
  5198  		"name": c.name,
  5199  	})
  5200  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5201  }
  5202  
  5203  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.workstations.start" call.
  5204  // Any non-2xx status code is an error. Response headers are in either
  5205  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  5206  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  5207  // whether the returned error was because http.StatusNotModified was returned.
  5208  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStartCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  5209  	gensupport.SetOptions(c.urlParams_, opts...)
  5210  	res, err := c.doRequest("json")
  5211  	if res != nil && res.StatusCode == http.StatusNotModified {
  5212  		if res.Body != nil {
  5213  			res.Body.Close()
  5214  		}
  5215  		return nil, gensupport.WrapError(&googleapi.Error{
  5216  			Code:   res.StatusCode,
  5217  			Header: res.Header,
  5218  		})
  5219  	}
  5220  	if err != nil {
  5221  		return nil, err
  5222  	}
  5223  	defer googleapi.CloseBody(res)
  5224  	if err := googleapi.CheckResponse(res); err != nil {
  5225  		return nil, gensupport.WrapError(err)
  5226  	}
  5227  	ret := &Operation{
  5228  		ServerResponse: googleapi.ServerResponse{
  5229  			Header:         res.Header,
  5230  			HTTPStatusCode: res.StatusCode,
  5231  		},
  5232  	}
  5233  	target := &ret
  5234  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5235  		return nil, err
  5236  	}
  5237  	return ret, nil
  5238  }
  5239  
  5240  type ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStopCall struct {
  5241  	s                      *Service
  5242  	name                   string
  5243  	stopworkstationrequest *StopWorkstationRequest
  5244  	urlParams_             gensupport.URLParams
  5245  	ctx_                   context.Context
  5246  	header_                http.Header
  5247  }
  5248  
  5249  // Stop: Stops running a workstation, reducing costs.
  5250  //
  5251  // - name: Name of the workstation to stop.
  5252  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService) Stop(name string, stopworkstationrequest *StopWorkstationRequest) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStopCall {
  5253  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStopCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  5254  	c.name = name
  5255  	c.stopworkstationrequest = stopworkstationrequest
  5256  	return c
  5257  }
  5258  
  5259  // Fields allows partial responses to be retrieved. See
  5260  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  5261  // details.
  5262  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStopCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStopCall {
  5263  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  5264  	return c
  5265  }
  5266  
  5267  // Context sets the context to be used in this call's Do method.
  5268  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStopCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStopCall {
  5269  	c.ctx_ = ctx
  5270  	return c
  5271  }
  5272  
  5273  // Header returns a http.Header that can be modified by the caller to add
  5274  // headers to the request.
  5275  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStopCall) Header() http.Header {
  5276  	if c.header_ == nil {
  5277  		c.header_ = make(http.Header)
  5278  	}
  5279  	return c.header_
  5280  }
  5281  
  5282  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStopCall) doRequest(alt string) (*http.Response, error) {
  5283  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  5284  	var body io.Reader = nil
  5285  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.stopworkstationrequest)
  5286  	if err != nil {
  5287  		return nil, err
  5288  	}
  5289  	c.urlParams_.Set("alt", alt)
  5290  	c.urlParams_.Set("prettyPrint", "false")
  5291  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+name}:stop")
  5292  	urls += "?" + c.urlParams_.Encode()
  5293  	req, err := http.NewRequest("POST", urls, body)
  5294  	if err != nil {
  5295  		return nil, err
  5296  	}
  5297  	req.Header = reqHeaders
  5298  	googleapi.Expand(req.URL, map[string]string{
  5299  		"name": c.name,
  5300  	})
  5301  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5302  }
  5303  
  5304  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.workstations.stop" call.
  5305  // Any non-2xx status code is an error. Response headers are in either
  5306  // *Operation.ServerResponse.Header or (if a response was returned at all) in
  5307  // error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
  5308  // whether the returned error was because http.StatusNotModified was returned.
  5309  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsStopCall) Do(opts ...googleapi.CallOption) (*Operation, error) {
  5310  	gensupport.SetOptions(c.urlParams_, opts...)
  5311  	res, err := c.doRequest("json")
  5312  	if res != nil && res.StatusCode == http.StatusNotModified {
  5313  		if res.Body != nil {
  5314  			res.Body.Close()
  5315  		}
  5316  		return nil, gensupport.WrapError(&googleapi.Error{
  5317  			Code:   res.StatusCode,
  5318  			Header: res.Header,
  5319  		})
  5320  	}
  5321  	if err != nil {
  5322  		return nil, err
  5323  	}
  5324  	defer googleapi.CloseBody(res)
  5325  	if err := googleapi.CheckResponse(res); err != nil {
  5326  		return nil, gensupport.WrapError(err)
  5327  	}
  5328  	ret := &Operation{
  5329  		ServerResponse: googleapi.ServerResponse{
  5330  			Header:         res.Header,
  5331  			HTTPStatusCode: res.StatusCode,
  5332  		},
  5333  	}
  5334  	target := &ret
  5335  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5336  		return nil, err
  5337  	}
  5338  	return ret, nil
  5339  }
  5340  
  5341  type ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsTestIamPermissionsCall struct {
  5342  	s                         *Service
  5343  	resource                  string
  5344  	testiampermissionsrequest *TestIamPermissionsRequest
  5345  	urlParams_                gensupport.URLParams
  5346  	ctx_                      context.Context
  5347  	header_                   http.Header
  5348  }
  5349  
  5350  // TestIamPermissions: Returns permissions that a caller has on the specified
  5351  // resource. If the resource does not exist, this will return an empty set of
  5352  // permissions, not a `NOT_FOUND` error. Note: This operation is designed to be
  5353  // used for building permission-aware UIs and command-line tools, not for
  5354  // authorization checking. This operation may "fail open" without warning.
  5355  //
  5356  //   - resource: REQUIRED: The resource for which the policy detail is being
  5357  //     requested. See Resource names
  5358  //     (https://cloud.google.com/apis/design/resource_names) for the appropriate
  5359  //     value for this field.
  5360  func (r *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsService) TestIamPermissions(resource string, testiampermissionsrequest *TestIamPermissionsRequest) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsTestIamPermissionsCall {
  5361  	c := &ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
  5362  	c.resource = resource
  5363  	c.testiampermissionsrequest = testiampermissionsrequest
  5364  	return c
  5365  }
  5366  
  5367  // Fields allows partial responses to be retrieved. See
  5368  // https://developers.google.com/gdata/docs/2.0/basics#PartialResponse for more
  5369  // details.
  5370  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsTestIamPermissionsCall) Fields(s ...googleapi.Field) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsTestIamPermissionsCall {
  5371  	c.urlParams_.Set("fields", googleapi.CombineFields(s))
  5372  	return c
  5373  }
  5374  
  5375  // Context sets the context to be used in this call's Do method.
  5376  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsTestIamPermissionsCall) Context(ctx context.Context) *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsTestIamPermissionsCall {
  5377  	c.ctx_ = ctx
  5378  	return c
  5379  }
  5380  
  5381  // Header returns a http.Header that can be modified by the caller to add
  5382  // headers to the request.
  5383  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsTestIamPermissionsCall) Header() http.Header {
  5384  	if c.header_ == nil {
  5385  		c.header_ = make(http.Header)
  5386  	}
  5387  	return c.header_
  5388  }
  5389  
  5390  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) {
  5391  	reqHeaders := gensupport.SetHeaders(c.s.userAgent(), "application/json", c.header_)
  5392  	var body io.Reader = nil
  5393  	body, err := googleapi.WithoutDataWrapper.JSONReader(c.testiampermissionsrequest)
  5394  	if err != nil {
  5395  		return nil, err
  5396  	}
  5397  	c.urlParams_.Set("alt", alt)
  5398  	c.urlParams_.Set("prettyPrint", "false")
  5399  	urls := googleapi.ResolveRelative(c.s.BasePath, "v1beta/{+resource}:testIamPermissions")
  5400  	urls += "?" + c.urlParams_.Encode()
  5401  	req, err := http.NewRequest("POST", urls, body)
  5402  	if err != nil {
  5403  		return nil, err
  5404  	}
  5405  	req.Header = reqHeaders
  5406  	googleapi.Expand(req.URL, map[string]string{
  5407  		"resource": c.resource,
  5408  	})
  5409  	return gensupport.SendRequest(c.ctx_, c.s.client, req)
  5410  }
  5411  
  5412  // Do executes the "workstations.projects.locations.workstationClusters.workstationConfigs.workstations.testIamPermissions" call.
  5413  // Any non-2xx status code is an error. Response headers are in either
  5414  // *TestIamPermissionsResponse.ServerResponse.Header or (if a response was
  5415  // returned at all) in error.(*googleapi.Error).Header. Use
  5416  // googleapi.IsNotModified to check whether the returned error was because
  5417  // http.StatusNotModified was returned.
  5418  func (c *ProjectsLocationsWorkstationClustersWorkstationConfigsWorkstationsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*TestIamPermissionsResponse, error) {
  5419  	gensupport.SetOptions(c.urlParams_, opts...)
  5420  	res, err := c.doRequest("json")
  5421  	if res != nil && res.StatusCode == http.StatusNotModified {
  5422  		if res.Body != nil {
  5423  			res.Body.Close()
  5424  		}
  5425  		return nil, gensupport.WrapError(&googleapi.Error{
  5426  			Code:   res.StatusCode,
  5427  			Header: res.Header,
  5428  		})
  5429  	}
  5430  	if err != nil {
  5431  		return nil, err
  5432  	}
  5433  	defer googleapi.CloseBody(res)
  5434  	if err := googleapi.CheckResponse(res); err != nil {
  5435  		return nil, gensupport.WrapError(err)
  5436  	}
  5437  	ret := &TestIamPermissionsResponse{
  5438  		ServerResponse: googleapi.ServerResponse{
  5439  			Header:         res.Header,
  5440  			HTTPStatusCode: res.StatusCode,
  5441  		},
  5442  	}
  5443  	target := &ret
  5444  	if err := gensupport.DecodeResponse(target, res); err != nil {
  5445  		return nil, err
  5446  	}
  5447  	return ret, nil
  5448  }
  5449  

View as plain text