// Copyright 2024 Google LLC.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

// Code generated file. DO NOT EDIT.

// Package apigee provides access to the Apigee API.
//
// For product documentation, see: https://cloud.google.com/apigee-api-management/
//
// # Library status
//
// These client libraries are officially supported by Google. However, this
// library is considered complete and is in maintenance mode. This means
// that we will address critical bugs and security issues but will not add
// any new features.
//
// When possible, we recommend using our newer
// [Cloud Client Libraries for Go](https://pkg.go.dev/cloud.google.com/go)
// that are still actively being worked and iterated on.
//
// # Creating a client
//
// Usage example:
//
//	import "google.golang.org/api/apigee/v1"
//	...
//	ctx := context.Background()
//	apigeeService, err := apigee.NewService(ctx)
//
// In this example, Google Application Default Credentials are used for
// authentication. For information on how to create and obtain Application
// Default Credentials, see https://developers.google.com/identity/protocols/application-default-credentials.
//
// # Other authentication options
//
// To use an API key for authentication (note: some APIs do not support API
// keys), use [google.golang.org/api/option.WithAPIKey]:
//
//	apigeeService, err := apigee.NewService(ctx, option.WithAPIKey("AIza..."))
//
// To use an OAuth token (e.g., a user token obtained via a three-legged OAuth
// flow, use [google.golang.org/api/option.WithTokenSource]:
//
//	config := &oauth2.Config{...}
//	// ...
//	token, err := config.Exchange(ctx, ...)
//	apigeeService, err := apigee.NewService(ctx, option.WithTokenSource(config.TokenSource(ctx, token)))
//
// See [google.golang.org/api/option.ClientOption] for details on options.
package apigee // import "google.golang.org/api/apigee/v1"

import (
	"bytes"
	"context"
	"encoding/json"
	"errors"
	"fmt"
	"io"
	"net/http"
	"net/url"
	"strconv"
	"strings"

	googleapi "google.golang.org/api/googleapi"
	internal "google.golang.org/api/internal"
	gensupport "google.golang.org/api/internal/gensupport"
	option "google.golang.org/api/option"
	internaloption "google.golang.org/api/option/internaloption"
	htransport "google.golang.org/api/transport/http"
)

// Always reference these packages, just in case the auto-generated code
// below doesn't.
var _ = bytes.NewBuffer
var _ = strconv.Itoa
var _ = fmt.Sprintf
var _ = json.NewDecoder
var _ = io.Copy
var _ = url.Parse
var _ = gensupport.MarshalJSON
var _ = googleapi.Version
var _ = errors.New
var _ = strings.Replace
var _ = context.Canceled
var _ = internaloption.WithDefaultEndpoint
var _ = internal.Version

const apiId = "apigee:v1"
const apiName = "apigee"
const apiVersion = "v1"
const basePath = "https://apigee.googleapis.com/"
const basePathTemplate = "https://apigee.UNIVERSE_DOMAIN/"
const mtlsBasePath = "https://apigee.mtls.googleapis.com/"
const defaultUniverseDomain = "googleapis.com"

// OAuth2 scopes used by this API.
const (
	// See, edit, configure, and delete your Google Cloud data and see the
	// email address for your Google Account.
	CloudPlatformScope = "https://www.googleapis.com/auth/cloud-platform"
)

// NewService creates a new Service.
func NewService(ctx context.Context, opts ...option.ClientOption) (*Service, error) {
	scopesOption := internaloption.WithDefaultScopes(
		"https://www.googleapis.com/auth/cloud-platform",
	)
	// NOTE: prepend, so we don't override user-specified scopes.
	opts = append([]option.ClientOption{scopesOption}, opts...)
	opts = append(opts, internaloption.WithDefaultEndpoint(basePath))
	opts = append(opts, internaloption.WithDefaultEndpointTemplate(basePathTemplate))
	opts = append(opts, internaloption.WithDefaultMTLSEndpoint(mtlsBasePath))
	opts = append(opts, internaloption.WithDefaultUniverseDomain(defaultUniverseDomain))
	client, endpoint, err := htransport.NewClient(ctx, opts...)
	if err != nil {
		return nil, err
	}
	s, err := New(client)
	if err != nil {
		return nil, err
	}
	if endpoint != "" {
		s.BasePath = endpoint
	}
	return s, nil
}

// New creates a new Service. It uses the provided http.Client for requests.
//
// Deprecated: please use NewService instead.
// To provide a custom HTTP client, use option.WithHTTPClient.
// If you are using google.golang.org/api/googleapis/transport.APIKey, use option.WithAPIKey with NewService instead.
func New(client *http.Client) (*Service, error) {
	if client == nil {
		return nil, errors.New("client is nil")
	}
	s := &Service{client: client, BasePath: basePath}
	s.Hybrid = NewHybridService(s)
	s.Organizations = NewOrganizationsService(s)
	s.Projects = NewProjectsService(s)
	return s, nil
}

type Service struct {
	client    *http.Client
	BasePath  string // API endpoint base URL
	UserAgent string // optional additional User-Agent fragment

	Hybrid *HybridService

	Organizations *OrganizationsService

	Projects *ProjectsService
}

func (s *Service) userAgent() string {
	if s.UserAgent == "" {
		return googleapi.UserAgent
	}
	return googleapi.UserAgent + " " + s.UserAgent
}

func NewHybridService(s *Service) *HybridService {
	rs := &HybridService{s: s}
	rs.Issuers = NewHybridIssuersService(s)
	return rs
}

type HybridService struct {
	s *Service

	Issuers *HybridIssuersService
}

func NewHybridIssuersService(s *Service) *HybridIssuersService {
	rs := &HybridIssuersService{s: s}
	return rs
}

type HybridIssuersService struct {
	s *Service
}

func NewOrganizationsService(s *Service) *OrganizationsService {
	rs := &OrganizationsService{s: s}
	rs.Analytics = NewOrganizationsAnalyticsService(s)
	rs.Apiproducts = NewOrganizationsApiproductsService(s)
	rs.Apis = NewOrganizationsApisService(s)
	rs.Appgroups = NewOrganizationsAppgroupsService(s)
	rs.Apps = NewOrganizationsAppsService(s)
	rs.Datacollectors = NewOrganizationsDatacollectorsService(s)
	rs.Deployments = NewOrganizationsDeploymentsService(s)
	rs.Developers = NewOrganizationsDevelopersService(s)
	rs.EndpointAttachments = NewOrganizationsEndpointAttachmentsService(s)
	rs.Envgroups = NewOrganizationsEnvgroupsService(s)
	rs.Environments = NewOrganizationsEnvironmentsService(s)
	rs.HostQueries = NewOrganizationsHostQueriesService(s)
	rs.HostSecurityReports = NewOrganizationsHostSecurityReportsService(s)
	rs.HostStats = NewOrganizationsHostStatsService(s)
	rs.Instances = NewOrganizationsInstancesService(s)
	rs.Keyvaluemaps = NewOrganizationsKeyvaluemapsService(s)
	rs.Operations = NewOrganizationsOperationsService(s)
	rs.OptimizedHostStats = NewOrganizationsOptimizedHostStatsService(s)
	rs.Reports = NewOrganizationsReportsService(s)
	rs.SecurityProfiles = NewOrganizationsSecurityProfilesService(s)
	rs.Sharedflows = NewOrganizationsSharedflowsService(s)
	rs.Sites = NewOrganizationsSitesService(s)
	return rs
}

type OrganizationsService struct {
	s *Service

	Analytics *OrganizationsAnalyticsService

	Apiproducts *OrganizationsApiproductsService

	Apis *OrganizationsApisService

	Appgroups *OrganizationsAppgroupsService

	Apps *OrganizationsAppsService

	Datacollectors *OrganizationsDatacollectorsService

	Deployments *OrganizationsDeploymentsService

	Developers *OrganizationsDevelopersService

	EndpointAttachments *OrganizationsEndpointAttachmentsService

	Envgroups *OrganizationsEnvgroupsService

	Environments *OrganizationsEnvironmentsService

	HostQueries *OrganizationsHostQueriesService

	HostSecurityReports *OrganizationsHostSecurityReportsService

	HostStats *OrganizationsHostStatsService

	Instances *OrganizationsInstancesService

	Keyvaluemaps *OrganizationsKeyvaluemapsService

	Operations *OrganizationsOperationsService

	OptimizedHostStats *OrganizationsOptimizedHostStatsService

	Reports *OrganizationsReportsService

	SecurityProfiles *OrganizationsSecurityProfilesService

	Sharedflows *OrganizationsSharedflowsService

	Sites *OrganizationsSitesService
}

func NewOrganizationsAnalyticsService(s *Service) *OrganizationsAnalyticsService {
	rs := &OrganizationsAnalyticsService{s: s}
	rs.Datastores = NewOrganizationsAnalyticsDatastoresService(s)
	return rs
}

type OrganizationsAnalyticsService struct {
	s *Service

	Datastores *OrganizationsAnalyticsDatastoresService
}

func NewOrganizationsAnalyticsDatastoresService(s *Service) *OrganizationsAnalyticsDatastoresService {
	rs := &OrganizationsAnalyticsDatastoresService{s: s}
	return rs
}

type OrganizationsAnalyticsDatastoresService struct {
	s *Service
}

func NewOrganizationsApiproductsService(s *Service) *OrganizationsApiproductsService {
	rs := &OrganizationsApiproductsService{s: s}
	rs.Attributes_ = NewOrganizationsApiproductsAttributesService(s)
	rs.Rateplans = NewOrganizationsApiproductsRateplansService(s)
	return rs
}

type OrganizationsApiproductsService struct {
	s *Service

	Attributes_ *OrganizationsApiproductsAttributesService

	Rateplans *OrganizationsApiproductsRateplansService
}

func NewOrganizationsApiproductsAttributesService(s *Service) *OrganizationsApiproductsAttributesService {
	rs := &OrganizationsApiproductsAttributesService{s: s}
	return rs
}

type OrganizationsApiproductsAttributesService struct {
	s *Service
}

func NewOrganizationsApiproductsRateplansService(s *Service) *OrganizationsApiproductsRateplansService {
	rs := &OrganizationsApiproductsRateplansService{s: s}
	return rs
}

type OrganizationsApiproductsRateplansService struct {
	s *Service
}

func NewOrganizationsApisService(s *Service) *OrganizationsApisService {
	rs := &OrganizationsApisService{s: s}
	rs.Deployments = NewOrganizationsApisDeploymentsService(s)
	rs.Keyvaluemaps = NewOrganizationsApisKeyvaluemapsService(s)
	rs.Revisions = NewOrganizationsApisRevisionsService(s)
	return rs
}

type OrganizationsApisService struct {
	s *Service

	Deployments *OrganizationsApisDeploymentsService

	Keyvaluemaps *OrganizationsApisKeyvaluemapsService

	Revisions *OrganizationsApisRevisionsService
}

func NewOrganizationsApisDeploymentsService(s *Service) *OrganizationsApisDeploymentsService {
	rs := &OrganizationsApisDeploymentsService{s: s}
	return rs
}

type OrganizationsApisDeploymentsService struct {
	s *Service
}

func NewOrganizationsApisKeyvaluemapsService(s *Service) *OrganizationsApisKeyvaluemapsService {
	rs := &OrganizationsApisKeyvaluemapsService{s: s}
	rs.Entries = NewOrganizationsApisKeyvaluemapsEntriesService(s)
	return rs
}

type OrganizationsApisKeyvaluemapsService struct {
	s *Service

	Entries *OrganizationsApisKeyvaluemapsEntriesService
}

func NewOrganizationsApisKeyvaluemapsEntriesService(s *Service) *OrganizationsApisKeyvaluemapsEntriesService {
	rs := &OrganizationsApisKeyvaluemapsEntriesService{s: s}
	return rs
}

type OrganizationsApisKeyvaluemapsEntriesService struct {
	s *Service
}

func NewOrganizationsApisRevisionsService(s *Service) *OrganizationsApisRevisionsService {
	rs := &OrganizationsApisRevisionsService{s: s}
	rs.Deployments = NewOrganizationsApisRevisionsDeploymentsService(s)
	return rs
}

type OrganizationsApisRevisionsService struct {
	s *Service

	Deployments *OrganizationsApisRevisionsDeploymentsService
}

func NewOrganizationsApisRevisionsDeploymentsService(s *Service) *OrganizationsApisRevisionsDeploymentsService {
	rs := &OrganizationsApisRevisionsDeploymentsService{s: s}
	return rs
}

type OrganizationsApisRevisionsDeploymentsService struct {
	s *Service
}

func NewOrganizationsAppgroupsService(s *Service) *OrganizationsAppgroupsService {
	rs := &OrganizationsAppgroupsService{s: s}
	rs.Apps = NewOrganizationsAppgroupsAppsService(s)
	return rs
}

type OrganizationsAppgroupsService struct {
	s *Service

	Apps *OrganizationsAppgroupsAppsService
}

func NewOrganizationsAppgroupsAppsService(s *Service) *OrganizationsAppgroupsAppsService {
	rs := &OrganizationsAppgroupsAppsService{s: s}
	rs.Keys = NewOrganizationsAppgroupsAppsKeysService(s)
	return rs
}

type OrganizationsAppgroupsAppsService struct {
	s *Service

	Keys *OrganizationsAppgroupsAppsKeysService
}

func NewOrganizationsAppgroupsAppsKeysService(s *Service) *OrganizationsAppgroupsAppsKeysService {
	rs := &OrganizationsAppgroupsAppsKeysService{s: s}
	rs.Apiproducts = NewOrganizationsAppgroupsAppsKeysApiproductsService(s)
	return rs
}

type OrganizationsAppgroupsAppsKeysService struct {
	s *Service

	Apiproducts *OrganizationsAppgroupsAppsKeysApiproductsService
}

func NewOrganizationsAppgroupsAppsKeysApiproductsService(s *Service) *OrganizationsAppgroupsAppsKeysApiproductsService {
	rs := &OrganizationsAppgroupsAppsKeysApiproductsService{s: s}
	return rs
}

type OrganizationsAppgroupsAppsKeysApiproductsService struct {
	s *Service
}

func NewOrganizationsAppsService(s *Service) *OrganizationsAppsService {
	rs := &OrganizationsAppsService{s: s}
	return rs
}

type OrganizationsAppsService struct {
	s *Service
}

func NewOrganizationsDatacollectorsService(s *Service) *OrganizationsDatacollectorsService {
	rs := &OrganizationsDatacollectorsService{s: s}
	return rs
}

type OrganizationsDatacollectorsService struct {
	s *Service
}

func NewOrganizationsDeploymentsService(s *Service) *OrganizationsDeploymentsService {
	rs := &OrganizationsDeploymentsService{s: s}
	return rs
}

type OrganizationsDeploymentsService struct {
	s *Service
}

func NewOrganizationsDevelopersService(s *Service) *OrganizationsDevelopersService {
	rs := &OrganizationsDevelopersService{s: s}
	rs.Apps = NewOrganizationsDevelopersAppsService(s)
	rs.Attributes_ = NewOrganizationsDevelopersAttributesService(s)
	rs.Balance = NewOrganizationsDevelopersBalanceService(s)
	rs.Subscriptions = NewOrganizationsDevelopersSubscriptionsService(s)
	return rs
}

type OrganizationsDevelopersService struct {
	s *Service

	Apps *OrganizationsDevelopersAppsService

	Attributes_ *OrganizationsDevelopersAttributesService

	Balance *OrganizationsDevelopersBalanceService

	Subscriptions *OrganizationsDevelopersSubscriptionsService
}

func NewOrganizationsDevelopersAppsService(s *Service) *OrganizationsDevelopersAppsService {
	rs := &OrganizationsDevelopersAppsService{s: s}
	rs.Attributes_ = NewOrganizationsDevelopersAppsAttributesService(s)
	rs.Keys = NewOrganizationsDevelopersAppsKeysService(s)
	return rs
}

type OrganizationsDevelopersAppsService struct {
	s *Service

	Attributes_ *OrganizationsDevelopersAppsAttributesService

	Keys *OrganizationsDevelopersAppsKeysService
}

func NewOrganizationsDevelopersAppsAttributesService(s *Service) *OrganizationsDevelopersAppsAttributesService {
	rs := &OrganizationsDevelopersAppsAttributesService{s: s}
	return rs
}

type OrganizationsDevelopersAppsAttributesService struct {
	s *Service
}

func NewOrganizationsDevelopersAppsKeysService(s *Service) *OrganizationsDevelopersAppsKeysService {
	rs := &OrganizationsDevelopersAppsKeysService{s: s}
	rs.Apiproducts = NewOrganizationsDevelopersAppsKeysApiproductsService(s)
	rs.Create_ = NewOrganizationsDevelopersAppsKeysCreateService(s)
	return rs
}

type OrganizationsDevelopersAppsKeysService struct {
	s *Service

	Apiproducts *OrganizationsDevelopersAppsKeysApiproductsService

	Create_ *OrganizationsDevelopersAppsKeysCreateService
}

func NewOrganizationsDevelopersAppsKeysApiproductsService(s *Service) *OrganizationsDevelopersAppsKeysApiproductsService {
	rs := &OrganizationsDevelopersAppsKeysApiproductsService{s: s}
	return rs
}

type OrganizationsDevelopersAppsKeysApiproductsService struct {
	s *Service
}

func NewOrganizationsDevelopersAppsKeysCreateService(s *Service) *OrganizationsDevelopersAppsKeysCreateService {
	rs := &OrganizationsDevelopersAppsKeysCreateService{s: s}
	return rs
}

type OrganizationsDevelopersAppsKeysCreateService struct {
	s *Service
}

func NewOrganizationsDevelopersAttributesService(s *Service) *OrganizationsDevelopersAttributesService {
	rs := &OrganizationsDevelopersAttributesService{s: s}
	return rs
}

type OrganizationsDevelopersAttributesService struct {
	s *Service
}

func NewOrganizationsDevelopersBalanceService(s *Service) *OrganizationsDevelopersBalanceService {
	rs := &OrganizationsDevelopersBalanceService{s: s}
	return rs
}

type OrganizationsDevelopersBalanceService struct {
	s *Service
}

func NewOrganizationsDevelopersSubscriptionsService(s *Service) *OrganizationsDevelopersSubscriptionsService {
	rs := &OrganizationsDevelopersSubscriptionsService{s: s}
	return rs
}

type OrganizationsDevelopersSubscriptionsService struct {
	s *Service
}

func NewOrganizationsEndpointAttachmentsService(s *Service) *OrganizationsEndpointAttachmentsService {
	rs := &OrganizationsEndpointAttachmentsService{s: s}
	return rs
}

type OrganizationsEndpointAttachmentsService struct {
	s *Service
}

func NewOrganizationsEnvgroupsService(s *Service) *OrganizationsEnvgroupsService {
	rs := &OrganizationsEnvgroupsService{s: s}
	rs.Attachments = NewOrganizationsEnvgroupsAttachmentsService(s)
	return rs
}

type OrganizationsEnvgroupsService struct {
	s *Service

	Attachments *OrganizationsEnvgroupsAttachmentsService
}

func NewOrganizationsEnvgroupsAttachmentsService(s *Service) *OrganizationsEnvgroupsAttachmentsService {
	rs := &OrganizationsEnvgroupsAttachmentsService{s: s}
	return rs
}

type OrganizationsEnvgroupsAttachmentsService struct {
	s *Service
}

func NewOrganizationsEnvironmentsService(s *Service) *OrganizationsEnvironmentsService {
	rs := &OrganizationsEnvironmentsService{s: s}
	rs.AddonsConfig = NewOrganizationsEnvironmentsAddonsConfigService(s)
	rs.Analytics = NewOrganizationsEnvironmentsAnalyticsService(s)
	rs.Apis = NewOrganizationsEnvironmentsApisService(s)
	rs.ArchiveDeployments = NewOrganizationsEnvironmentsArchiveDeploymentsService(s)
	rs.Caches = NewOrganizationsEnvironmentsCachesService(s)
	rs.Deployments = NewOrganizationsEnvironmentsDeploymentsService(s)
	rs.Flowhooks = NewOrganizationsEnvironmentsFlowhooksService(s)
	rs.Keystores = NewOrganizationsEnvironmentsKeystoresService(s)
	rs.Keyvaluemaps = NewOrganizationsEnvironmentsKeyvaluemapsService(s)
	rs.OptimizedStats = NewOrganizationsEnvironmentsOptimizedStatsService(s)
	rs.Queries = NewOrganizationsEnvironmentsQueriesService(s)
	rs.References = NewOrganizationsEnvironmentsReferencesService(s)
	rs.Resourcefiles = NewOrganizationsEnvironmentsResourcefilesService(s)
	rs.SecurityActions = NewOrganizationsEnvironmentsSecurityActionsService(s)
	rs.SecurityIncidents = NewOrganizationsEnvironmentsSecurityIncidentsService(s)
	rs.SecurityReports = NewOrganizationsEnvironmentsSecurityReportsService(s)
	rs.SecurityStats = NewOrganizationsEnvironmentsSecurityStatsService(s)
	rs.Sharedflows = NewOrganizationsEnvironmentsSharedflowsService(s)
	rs.Stats = NewOrganizationsEnvironmentsStatsService(s)
	rs.Targetservers = NewOrganizationsEnvironmentsTargetserversService(s)
	rs.TraceConfig = NewOrganizationsEnvironmentsTraceConfigService(s)
	return rs
}

type OrganizationsEnvironmentsService struct {
	s *Service

	AddonsConfig *OrganizationsEnvironmentsAddonsConfigService

	Analytics *OrganizationsEnvironmentsAnalyticsService

	Apis *OrganizationsEnvironmentsApisService

	ArchiveDeployments *OrganizationsEnvironmentsArchiveDeploymentsService

	Caches *OrganizationsEnvironmentsCachesService

	Deployments *OrganizationsEnvironmentsDeploymentsService

	Flowhooks *OrganizationsEnvironmentsFlowhooksService

	Keystores *OrganizationsEnvironmentsKeystoresService

	Keyvaluemaps *OrganizationsEnvironmentsKeyvaluemapsService

	OptimizedStats *OrganizationsEnvironmentsOptimizedStatsService

	Queries *OrganizationsEnvironmentsQueriesService

	References *OrganizationsEnvironmentsReferencesService

	Resourcefiles *OrganizationsEnvironmentsResourcefilesService

	SecurityActions *OrganizationsEnvironmentsSecurityActionsService

	SecurityIncidents *OrganizationsEnvironmentsSecurityIncidentsService

	SecurityReports *OrganizationsEnvironmentsSecurityReportsService

	SecurityStats *OrganizationsEnvironmentsSecurityStatsService

	Sharedflows *OrganizationsEnvironmentsSharedflowsService

	Stats *OrganizationsEnvironmentsStatsService

	Targetservers *OrganizationsEnvironmentsTargetserversService

	TraceConfig *OrganizationsEnvironmentsTraceConfigService
}

func NewOrganizationsEnvironmentsAddonsConfigService(s *Service) *OrganizationsEnvironmentsAddonsConfigService {
	rs := &OrganizationsEnvironmentsAddonsConfigService{s: s}
	return rs
}

type OrganizationsEnvironmentsAddonsConfigService struct {
	s *Service
}

func NewOrganizationsEnvironmentsAnalyticsService(s *Service) *OrganizationsEnvironmentsAnalyticsService {
	rs := &OrganizationsEnvironmentsAnalyticsService{s: s}
	rs.Admin = NewOrganizationsEnvironmentsAnalyticsAdminService(s)
	rs.Exports = NewOrganizationsEnvironmentsAnalyticsExportsService(s)
	return rs
}

type OrganizationsEnvironmentsAnalyticsService struct {
	s *Service

	Admin *OrganizationsEnvironmentsAnalyticsAdminService

	Exports *OrganizationsEnvironmentsAnalyticsExportsService
}

func NewOrganizationsEnvironmentsAnalyticsAdminService(s *Service) *OrganizationsEnvironmentsAnalyticsAdminService {
	rs := &OrganizationsEnvironmentsAnalyticsAdminService{s: s}
	return rs
}

type OrganizationsEnvironmentsAnalyticsAdminService struct {
	s *Service
}

func NewOrganizationsEnvironmentsAnalyticsExportsService(s *Service) *OrganizationsEnvironmentsAnalyticsExportsService {
	rs := &OrganizationsEnvironmentsAnalyticsExportsService{s: s}
	return rs
}

type OrganizationsEnvironmentsAnalyticsExportsService struct {
	s *Service
}

func NewOrganizationsEnvironmentsApisService(s *Service) *OrganizationsEnvironmentsApisService {
	rs := &OrganizationsEnvironmentsApisService{s: s}
	rs.Deployments = NewOrganizationsEnvironmentsApisDeploymentsService(s)
	rs.Revisions = NewOrganizationsEnvironmentsApisRevisionsService(s)
	return rs
}

type OrganizationsEnvironmentsApisService struct {
	s *Service

	Deployments *OrganizationsEnvironmentsApisDeploymentsService

	Revisions *OrganizationsEnvironmentsApisRevisionsService
}

func NewOrganizationsEnvironmentsApisDeploymentsService(s *Service) *OrganizationsEnvironmentsApisDeploymentsService {
	rs := &OrganizationsEnvironmentsApisDeploymentsService{s: s}
	return rs
}

type OrganizationsEnvironmentsApisDeploymentsService struct {
	s *Service
}

func NewOrganizationsEnvironmentsApisRevisionsService(s *Service) *OrganizationsEnvironmentsApisRevisionsService {
	rs := &OrganizationsEnvironmentsApisRevisionsService{s: s}
	rs.Debugsessions = NewOrganizationsEnvironmentsApisRevisionsDebugsessionsService(s)
	rs.Deployments = NewOrganizationsEnvironmentsApisRevisionsDeploymentsService(s)
	return rs
}

type OrganizationsEnvironmentsApisRevisionsService struct {
	s *Service

	Debugsessions *OrganizationsEnvironmentsApisRevisionsDebugsessionsService

	Deployments *OrganizationsEnvironmentsApisRevisionsDeploymentsService
}

func NewOrganizationsEnvironmentsApisRevisionsDebugsessionsService(s *Service) *OrganizationsEnvironmentsApisRevisionsDebugsessionsService {
	rs := &OrganizationsEnvironmentsApisRevisionsDebugsessionsService{s: s}
	rs.Data = NewOrganizationsEnvironmentsApisRevisionsDebugsessionsDataService(s)
	return rs
}

type OrganizationsEnvironmentsApisRevisionsDebugsessionsService struct {
	s *Service

	Data *OrganizationsEnvironmentsApisRevisionsDebugsessionsDataService
}

func NewOrganizationsEnvironmentsApisRevisionsDebugsessionsDataService(s *Service) *OrganizationsEnvironmentsApisRevisionsDebugsessionsDataService {
	rs := &OrganizationsEnvironmentsApisRevisionsDebugsessionsDataService{s: s}
	return rs
}

type OrganizationsEnvironmentsApisRevisionsDebugsessionsDataService struct {
	s *Service
}

func NewOrganizationsEnvironmentsApisRevisionsDeploymentsService(s *Service) *OrganizationsEnvironmentsApisRevisionsDeploymentsService {
	rs := &OrganizationsEnvironmentsApisRevisionsDeploymentsService{s: s}
	return rs
}

type OrganizationsEnvironmentsApisRevisionsDeploymentsService struct {
	s *Service
}

func NewOrganizationsEnvironmentsArchiveDeploymentsService(s *Service) *OrganizationsEnvironmentsArchiveDeploymentsService {
	rs := &OrganizationsEnvironmentsArchiveDeploymentsService{s: s}
	return rs
}

type OrganizationsEnvironmentsArchiveDeploymentsService struct {
	s *Service
}

func NewOrganizationsEnvironmentsCachesService(s *Service) *OrganizationsEnvironmentsCachesService {
	rs := &OrganizationsEnvironmentsCachesService{s: s}
	return rs
}

type OrganizationsEnvironmentsCachesService struct {
	s *Service
}

func NewOrganizationsEnvironmentsDeploymentsService(s *Service) *OrganizationsEnvironmentsDeploymentsService {
	rs := &OrganizationsEnvironmentsDeploymentsService{s: s}
	return rs
}

type OrganizationsEnvironmentsDeploymentsService struct {
	s *Service
}

func NewOrganizationsEnvironmentsFlowhooksService(s *Service) *OrganizationsEnvironmentsFlowhooksService {
	rs := &OrganizationsEnvironmentsFlowhooksService{s: s}
	return rs
}

type OrganizationsEnvironmentsFlowhooksService struct {
	s *Service
}

func NewOrganizationsEnvironmentsKeystoresService(s *Service) *OrganizationsEnvironmentsKeystoresService {
	rs := &OrganizationsEnvironmentsKeystoresService{s: s}
	rs.Aliases = NewOrganizationsEnvironmentsKeystoresAliasesService(s)
	return rs
}

type OrganizationsEnvironmentsKeystoresService struct {
	s *Service

	Aliases *OrganizationsEnvironmentsKeystoresAliasesService
}

func NewOrganizationsEnvironmentsKeystoresAliasesService(s *Service) *OrganizationsEnvironmentsKeystoresAliasesService {
	rs := &OrganizationsEnvironmentsKeystoresAliasesService{s: s}
	return rs
}

type OrganizationsEnvironmentsKeystoresAliasesService struct {
	s *Service
}

func NewOrganizationsEnvironmentsKeyvaluemapsService(s *Service) *OrganizationsEnvironmentsKeyvaluemapsService {
	rs := &OrganizationsEnvironmentsKeyvaluemapsService{s: s}
	rs.Entries = NewOrganizationsEnvironmentsKeyvaluemapsEntriesService(s)
	return rs
}

type OrganizationsEnvironmentsKeyvaluemapsService struct {
	s *Service

	Entries *OrganizationsEnvironmentsKeyvaluemapsEntriesService
}

func NewOrganizationsEnvironmentsKeyvaluemapsEntriesService(s *Service) *OrganizationsEnvironmentsKeyvaluemapsEntriesService {
	rs := &OrganizationsEnvironmentsKeyvaluemapsEntriesService{s: s}
	return rs
}

type OrganizationsEnvironmentsKeyvaluemapsEntriesService struct {
	s *Service
}

func NewOrganizationsEnvironmentsOptimizedStatsService(s *Service) *OrganizationsEnvironmentsOptimizedStatsService {
	rs := &OrganizationsEnvironmentsOptimizedStatsService{s: s}
	return rs
}

type OrganizationsEnvironmentsOptimizedStatsService struct {
	s *Service
}

func NewOrganizationsEnvironmentsQueriesService(s *Service) *OrganizationsEnvironmentsQueriesService {
	rs := &OrganizationsEnvironmentsQueriesService{s: s}
	return rs
}

type OrganizationsEnvironmentsQueriesService struct {
	s *Service
}

func NewOrganizationsEnvironmentsReferencesService(s *Service) *OrganizationsEnvironmentsReferencesService {
	rs := &OrganizationsEnvironmentsReferencesService{s: s}
	return rs
}

type OrganizationsEnvironmentsReferencesService struct {
	s *Service
}

func NewOrganizationsEnvironmentsResourcefilesService(s *Service) *OrganizationsEnvironmentsResourcefilesService {
	rs := &OrganizationsEnvironmentsResourcefilesService{s: s}
	return rs
}

type OrganizationsEnvironmentsResourcefilesService struct {
	s *Service
}

func NewOrganizationsEnvironmentsSecurityActionsService(s *Service) *OrganizationsEnvironmentsSecurityActionsService {
	rs := &OrganizationsEnvironmentsSecurityActionsService{s: s}
	return rs
}

type OrganizationsEnvironmentsSecurityActionsService struct {
	s *Service
}

func NewOrganizationsEnvironmentsSecurityIncidentsService(s *Service) *OrganizationsEnvironmentsSecurityIncidentsService {
	rs := &OrganizationsEnvironmentsSecurityIncidentsService{s: s}
	return rs
}

type OrganizationsEnvironmentsSecurityIncidentsService struct {
	s *Service
}

func NewOrganizationsEnvironmentsSecurityReportsService(s *Service) *OrganizationsEnvironmentsSecurityReportsService {
	rs := &OrganizationsEnvironmentsSecurityReportsService{s: s}
	return rs
}

type OrganizationsEnvironmentsSecurityReportsService struct {
	s *Service
}

func NewOrganizationsEnvironmentsSecurityStatsService(s *Service) *OrganizationsEnvironmentsSecurityStatsService {
	rs := &OrganizationsEnvironmentsSecurityStatsService{s: s}
	return rs
}

type OrganizationsEnvironmentsSecurityStatsService struct {
	s *Service
}

func NewOrganizationsEnvironmentsSharedflowsService(s *Service) *OrganizationsEnvironmentsSharedflowsService {
	rs := &OrganizationsEnvironmentsSharedflowsService{s: s}
	rs.Deployments = NewOrganizationsEnvironmentsSharedflowsDeploymentsService(s)
	rs.Revisions = NewOrganizationsEnvironmentsSharedflowsRevisionsService(s)
	return rs
}

type OrganizationsEnvironmentsSharedflowsService struct {
	s *Service

	Deployments *OrganizationsEnvironmentsSharedflowsDeploymentsService

	Revisions *OrganizationsEnvironmentsSharedflowsRevisionsService
}

func NewOrganizationsEnvironmentsSharedflowsDeploymentsService(s *Service) *OrganizationsEnvironmentsSharedflowsDeploymentsService {
	rs := &OrganizationsEnvironmentsSharedflowsDeploymentsService{s: s}
	return rs
}

type OrganizationsEnvironmentsSharedflowsDeploymentsService struct {
	s *Service
}

func NewOrganizationsEnvironmentsSharedflowsRevisionsService(s *Service) *OrganizationsEnvironmentsSharedflowsRevisionsService {
	rs := &OrganizationsEnvironmentsSharedflowsRevisionsService{s: s}
	return rs
}

type OrganizationsEnvironmentsSharedflowsRevisionsService struct {
	s *Service
}

func NewOrganizationsEnvironmentsStatsService(s *Service) *OrganizationsEnvironmentsStatsService {
	rs := &OrganizationsEnvironmentsStatsService{s: s}
	return rs
}

type OrganizationsEnvironmentsStatsService struct {
	s *Service
}

func NewOrganizationsEnvironmentsTargetserversService(s *Service) *OrganizationsEnvironmentsTargetserversService {
	rs := &OrganizationsEnvironmentsTargetserversService{s: s}
	return rs
}

type OrganizationsEnvironmentsTargetserversService struct {
	s *Service
}

func NewOrganizationsEnvironmentsTraceConfigService(s *Service) *OrganizationsEnvironmentsTraceConfigService {
	rs := &OrganizationsEnvironmentsTraceConfigService{s: s}
	rs.Overrides = NewOrganizationsEnvironmentsTraceConfigOverridesService(s)
	return rs
}

type OrganizationsEnvironmentsTraceConfigService struct {
	s *Service

	Overrides *OrganizationsEnvironmentsTraceConfigOverridesService
}

func NewOrganizationsEnvironmentsTraceConfigOverridesService(s *Service) *OrganizationsEnvironmentsTraceConfigOverridesService {
	rs := &OrganizationsEnvironmentsTraceConfigOverridesService{s: s}
	return rs
}

type OrganizationsEnvironmentsTraceConfigOverridesService struct {
	s *Service
}

func NewOrganizationsHostQueriesService(s *Service) *OrganizationsHostQueriesService {
	rs := &OrganizationsHostQueriesService{s: s}
	return rs
}

type OrganizationsHostQueriesService struct {
	s *Service
}

func NewOrganizationsHostSecurityReportsService(s *Service) *OrganizationsHostSecurityReportsService {
	rs := &OrganizationsHostSecurityReportsService{s: s}
	return rs
}

type OrganizationsHostSecurityReportsService struct {
	s *Service
}

func NewOrganizationsHostStatsService(s *Service) *OrganizationsHostStatsService {
	rs := &OrganizationsHostStatsService{s: s}
	return rs
}

type OrganizationsHostStatsService struct {
	s *Service
}

func NewOrganizationsInstancesService(s *Service) *OrganizationsInstancesService {
	rs := &OrganizationsInstancesService{s: s}
	rs.Attachments = NewOrganizationsInstancesAttachmentsService(s)
	rs.Canaryevaluations = NewOrganizationsInstancesCanaryevaluationsService(s)
	rs.NatAddresses = NewOrganizationsInstancesNatAddressesService(s)
	return rs
}

type OrganizationsInstancesService struct {
	s *Service

	Attachments *OrganizationsInstancesAttachmentsService

	Canaryevaluations *OrganizationsInstancesCanaryevaluationsService

	NatAddresses *OrganizationsInstancesNatAddressesService
}

func NewOrganizationsInstancesAttachmentsService(s *Service) *OrganizationsInstancesAttachmentsService {
	rs := &OrganizationsInstancesAttachmentsService{s: s}
	return rs
}

type OrganizationsInstancesAttachmentsService struct {
	s *Service
}

func NewOrganizationsInstancesCanaryevaluationsService(s *Service) *OrganizationsInstancesCanaryevaluationsService {
	rs := &OrganizationsInstancesCanaryevaluationsService{s: s}
	return rs
}

type OrganizationsInstancesCanaryevaluationsService struct {
	s *Service
}

func NewOrganizationsInstancesNatAddressesService(s *Service) *OrganizationsInstancesNatAddressesService {
	rs := &OrganizationsInstancesNatAddressesService{s: s}
	return rs
}

type OrganizationsInstancesNatAddressesService struct {
	s *Service
}

func NewOrganizationsKeyvaluemapsService(s *Service) *OrganizationsKeyvaluemapsService {
	rs := &OrganizationsKeyvaluemapsService{s: s}
	rs.Entries = NewOrganizationsKeyvaluemapsEntriesService(s)
	return rs
}

type OrganizationsKeyvaluemapsService struct {
	s *Service

	Entries *OrganizationsKeyvaluemapsEntriesService
}

func NewOrganizationsKeyvaluemapsEntriesService(s *Service) *OrganizationsKeyvaluemapsEntriesService {
	rs := &OrganizationsKeyvaluemapsEntriesService{s: s}
	return rs
}

type OrganizationsKeyvaluemapsEntriesService struct {
	s *Service
}

func NewOrganizationsOperationsService(s *Service) *OrganizationsOperationsService {
	rs := &OrganizationsOperationsService{s: s}
	return rs
}

type OrganizationsOperationsService struct {
	s *Service
}

func NewOrganizationsOptimizedHostStatsService(s *Service) *OrganizationsOptimizedHostStatsService {
	rs := &OrganizationsOptimizedHostStatsService{s: s}
	return rs
}

type OrganizationsOptimizedHostStatsService struct {
	s *Service
}

func NewOrganizationsReportsService(s *Service) *OrganizationsReportsService {
	rs := &OrganizationsReportsService{s: s}
	return rs
}

type OrganizationsReportsService struct {
	s *Service
}

func NewOrganizationsSecurityProfilesService(s *Service) *OrganizationsSecurityProfilesService {
	rs := &OrganizationsSecurityProfilesService{s: s}
	rs.Environments = NewOrganizationsSecurityProfilesEnvironmentsService(s)
	return rs
}

type OrganizationsSecurityProfilesService struct {
	s *Service

	Environments *OrganizationsSecurityProfilesEnvironmentsService
}

func NewOrganizationsSecurityProfilesEnvironmentsService(s *Service) *OrganizationsSecurityProfilesEnvironmentsService {
	rs := &OrganizationsSecurityProfilesEnvironmentsService{s: s}
	return rs
}

type OrganizationsSecurityProfilesEnvironmentsService struct {
	s *Service
}

func NewOrganizationsSharedflowsService(s *Service) *OrganizationsSharedflowsService {
	rs := &OrganizationsSharedflowsService{s: s}
	rs.Deployments = NewOrganizationsSharedflowsDeploymentsService(s)
	rs.Revisions = NewOrganizationsSharedflowsRevisionsService(s)
	return rs
}

type OrganizationsSharedflowsService struct {
	s *Service

	Deployments *OrganizationsSharedflowsDeploymentsService

	Revisions *OrganizationsSharedflowsRevisionsService
}

func NewOrganizationsSharedflowsDeploymentsService(s *Service) *OrganizationsSharedflowsDeploymentsService {
	rs := &OrganizationsSharedflowsDeploymentsService{s: s}
	return rs
}

type OrganizationsSharedflowsDeploymentsService struct {
	s *Service
}

func NewOrganizationsSharedflowsRevisionsService(s *Service) *OrganizationsSharedflowsRevisionsService {
	rs := &OrganizationsSharedflowsRevisionsService{s: s}
	rs.Deployments = NewOrganizationsSharedflowsRevisionsDeploymentsService(s)
	return rs
}

type OrganizationsSharedflowsRevisionsService struct {
	s *Service

	Deployments *OrganizationsSharedflowsRevisionsDeploymentsService
}

func NewOrganizationsSharedflowsRevisionsDeploymentsService(s *Service) *OrganizationsSharedflowsRevisionsDeploymentsService {
	rs := &OrganizationsSharedflowsRevisionsDeploymentsService{s: s}
	return rs
}

type OrganizationsSharedflowsRevisionsDeploymentsService struct {
	s *Service
}

func NewOrganizationsSitesService(s *Service) *OrganizationsSitesService {
	rs := &OrganizationsSitesService{s: s}
	rs.Apicategories = NewOrganizationsSitesApicategoriesService(s)
	rs.Apidocs = NewOrganizationsSitesApidocsService(s)
	return rs
}

type OrganizationsSitesService struct {
	s *Service

	Apicategories *OrganizationsSitesApicategoriesService

	Apidocs *OrganizationsSitesApidocsService
}

func NewOrganizationsSitesApicategoriesService(s *Service) *OrganizationsSitesApicategoriesService {
	rs := &OrganizationsSitesApicategoriesService{s: s}
	return rs
}

type OrganizationsSitesApicategoriesService struct {
	s *Service
}

func NewOrganizationsSitesApidocsService(s *Service) *OrganizationsSitesApidocsService {
	rs := &OrganizationsSitesApidocsService{s: s}
	return rs
}

type OrganizationsSitesApidocsService struct {
	s *Service
}

func NewProjectsService(s *Service) *ProjectsService {
	rs := &ProjectsService{s: s}
	return rs
}

type ProjectsService struct {
	s *Service
}

// EdgeConfigstoreBundleBadBundle: Describes why a bundle is invalid.
// Intended for use in error details.
type EdgeConfigstoreBundleBadBundle struct {
	// Violations: Describes all precondition violations.
	Violations []*EdgeConfigstoreBundleBadBundleViolation `json:"violations,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Violations") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Violations") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *EdgeConfigstoreBundleBadBundle) MarshalJSON() ([]byte, error) {
	type NoMethod EdgeConfigstoreBundleBadBundle
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// EdgeConfigstoreBundleBadBundleViolation: A message type used to
// describe a single bundle validation error.
type EdgeConfigstoreBundleBadBundleViolation struct {
	// Description: A description of why the bundle is invalid and how to
	// fix it.
	Description string `json:"description,omitempty"`

	// Filename: The filename (including relative path from the bundle root)
	// in which the error occurred.
	Filename string `json:"filename,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Description") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Description") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *EdgeConfigstoreBundleBadBundleViolation) MarshalJSON() ([]byte, error) {
	type NoMethod EdgeConfigstoreBundleBadBundleViolation
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleApiHttpBody: Message that represents an arbitrary HTTP body. It
// should only be used for payload formats that can't be represented as
// JSON, such as raw binary or an HTML page. This message can be used
// both in streaming and non-streaming API methods in the request as
// well as the response. It can be used as a top-level request field,
// which is convenient if one wants to extract parameters from either
// the URL or HTTP template into the request fields and also want access
// to the raw HTTP body. Example: message GetResourceRequest { // A
// unique request id. string request_id = 1; // The raw HTTP body is
// bound to this field. google.api.HttpBody http_body = 2; } service
// ResourceService { rpc GetResource(GetResourceRequest) returns
// (google.api.HttpBody); rpc UpdateResource(google.api.HttpBody)
// returns (google.protobuf.Empty); } Example with streaming methods:
// service CaldavService { rpc GetCalendar(stream google.api.HttpBody)
// returns (stream google.api.HttpBody); rpc UpdateCalendar(stream
// google.api.HttpBody) returns (stream google.api.HttpBody); } Use of
// this type only changes how the request and response bodies are
// handled, all other features will continue to work unchanged.
type GoogleApiHttpBody struct {
	// ContentType: The HTTP Content-Type header value specifying the
	// content type of the body.
	ContentType string `json:"contentType,omitempty"`

	// Data: The HTTP request/response body as raw binary.
	Data string `json:"data,omitempty"`

	// Extensions: Application specific response metadata. Must be set in
	// the first response for streaming APIs.
	Extensions []googleapi.RawMessage `json:"extensions,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ContentType") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ContentType") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleApiHttpBody) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleApiHttpBody
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1APIProductAssociation: APIProductAssociation has
// the API product and its administrative state association.
type GoogleCloudApigeeV1APIProductAssociation struct {
	// Apiproduct: API product to be associated with the credential.
	Apiproduct string `json:"apiproduct,omitempty"`

	// Status: The API product credential associated status. Valid values
	// are `approved` or `revoked`.
	Status string `json:"status,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Apiproduct") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Apiproduct") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1APIProductAssociation) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1APIProductAssociation
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1Access struct {
	Get *GoogleCloudApigeeV1AccessGet `json:"Get,omitempty"`

	Remove *GoogleCloudApigeeV1AccessRemove `json:"Remove,omitempty"`

	Set *GoogleCloudApigeeV1AccessSet `json:"Set,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Get") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Get") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Access) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Access
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1AccessGet: Get action. For example, "Get" : {
// "name" : "target.name", "value" : "default" }
type GoogleCloudApigeeV1AccessGet struct {
	Name string `json:"name,omitempty"`

	Value string `json:"value,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Name") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Name") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1AccessGet) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1AccessGet
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1AccessLoggingConfig: Access logging configuration
// enables customers to ship the access logs from the tenant projects to
// their own project's cloud logging. The feature is at the instance
// level ad disabled by default. It can be enabled during CreateInstance
// or UpdateInstance.
type GoogleCloudApigeeV1AccessLoggingConfig struct {
	// Enabled: Optional. Boolean flag that specifies whether the customer
	// access log feature is enabled.
	Enabled bool `json:"enabled,omitempty"`

	// Filter: Optional. Ship the access log entries that match the
	// status_code defined in the filter. The status_code is the only
	// expected/supported filter field. (Ex: status_code) The filter will
	// parse it to the Common Expression Language semantics for expression
	// evaluation to build the filter condition. (Ex: "filter": status_code
	// >= 200 && status_code < 300 )
	Filter string `json:"filter,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Enabled") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Enabled") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1AccessLoggingConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1AccessLoggingConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1AccessRemove: Remove action. For example, "Remove"
// : { "name" : "target.name", "success" : true }
type GoogleCloudApigeeV1AccessRemove struct {
	Name string `json:"name,omitempty"`

	Success bool `json:"success,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Name") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Name") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1AccessRemove) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1AccessRemove
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1AccessSet: Set action. For example, "Set" : {
// "name" : "target.name", "success" : true, "value" : "default" }
type GoogleCloudApigeeV1AccessSet struct {
	Name string `json:"name,omitempty"`

	Success bool `json:"success,omitempty"`

	Value string `json:"value,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Name") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Name") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1AccessSet) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1AccessSet
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ActivateNatAddressRequest: Request for
// ActivateNatAddressRequest. Activate the nat address request.
type GoogleCloudApigeeV1ActivateNatAddressRequest struct {
}

// GoogleCloudApigeeV1AddonsConfig: Add-on configurations for the Apigee
// organization.
type GoogleCloudApigeeV1AddonsConfig struct {
	// AdvancedApiOpsConfig: Configuration for the Advanced API Ops add-on.
	AdvancedApiOpsConfig *GoogleCloudApigeeV1AdvancedApiOpsConfig `json:"advancedApiOpsConfig,omitempty"`

	// AnalyticsConfig: Configuration for the Analytics add-on.
	AnalyticsConfig *GoogleCloudApigeeV1AnalyticsConfig `json:"analyticsConfig,omitempty"`

	// ApiSecurityConfig: Configuration for the API Security add-on.
	ApiSecurityConfig *GoogleCloudApigeeV1ApiSecurityConfig `json:"apiSecurityConfig,omitempty"`

	// ConnectorsPlatformConfig: Configuration for the Connectors Platform
	// add-on.
	ConnectorsPlatformConfig *GoogleCloudApigeeV1ConnectorsPlatformConfig `json:"connectorsPlatformConfig,omitempty"`

	// IntegrationConfig: Configuration for the Integration add-on.
	IntegrationConfig *GoogleCloudApigeeV1IntegrationConfig `json:"integrationConfig,omitempty"`

	// MonetizationConfig: Configuration for the Monetization add-on.
	MonetizationConfig *GoogleCloudApigeeV1MonetizationConfig `json:"monetizationConfig,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g.
	// "AdvancedApiOpsConfig") to unconditionally include in API requests.
	// By default, fields with empty or default values are omitted from API
	// requests. However, any non-pointer, non-interface field appearing in
	// ForceSendFields will be sent to the server regardless of whether the
	// field is empty or not. This may be used to include empty fields in
	// Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AdvancedApiOpsConfig") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1AddonsConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1AddonsConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1AdjustDeveloperBalanceRequest: Request for
// AdjustDeveloperBalance.
type GoogleCloudApigeeV1AdjustDeveloperBalanceRequest struct {
	// Adjustment: * A positive value of `adjustment` means that that the
	// API provider wants to adjust the balance for an under-charged
	// developer i.e. the balance of the developer will decrease. * A
	// negative value of `adjustment` means that that the API provider wants
	// to adjust the balance for an over-charged developer i.e. the balance
	// of the developer will increase.
	Adjustment *GoogleTypeMoney `json:"adjustment,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Adjustment") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Adjustment") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1AdjustDeveloperBalanceRequest) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1AdjustDeveloperBalanceRequest
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1AdvancedApiOpsConfig: Configuration for the
// Advanced API Ops add-on.
type GoogleCloudApigeeV1AdvancedApiOpsConfig struct {
	// Enabled: Flag that specifies whether the Advanced API Ops add-on is
	// enabled.
	Enabled bool `json:"enabled,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Enabled") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Enabled") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1AdvancedApiOpsConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1AdvancedApiOpsConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1Alias: Reference to a certificate or
// key/certificate pair.
type GoogleCloudApigeeV1Alias struct {
	// Alias: Resource ID for this alias. Values must match the regular
	// expression `[^/]{1,255}`.
	Alias string `json:"alias,omitempty"`

	// CertsInfo: Chain of certificates under this alias.
	CertsInfo *GoogleCloudApigeeV1Certificate `json:"certsInfo,omitempty"`

	// Type: Type of alias.
	//
	// Possible values:
	//   "ALIAS_TYPE_UNSPECIFIED" - Alias type is not specified.
	//   "CERT" - Certificate.
	//   "KEY_CERT" - Key/certificate pair.
	Type string `json:"type,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Alias") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Alias") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Alias) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Alias
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1AliasRevisionConfig struct {
	// Location: Location of the alias file. For example, a Google Cloud
	// Storage URI.
	Location string `json:"location,omitempty"`

	// Name: Name of the alias revision included in the keystore in the
	// following format:
	// `organizations/{org}/environments/{env}/keystores/{keystore}/aliases/{
	// alias}/revisions/{rev}`
	Name string `json:"name,omitempty"`

	// Possible values:
	//   "ALIAS_TYPE_UNSPECIFIED" - Alias type is not specified.
	//   "CERT" - Certificate.
	//   "KEY_CERT" - Key/certificate pair.
	Type string `json:"type,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Location") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Location") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1AliasRevisionConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1AliasRevisionConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1AnalyticsConfig: Configuration for the Analytics
// add-on.
type GoogleCloudApigeeV1AnalyticsConfig struct {
	// Enabled: Whether the Analytics add-on is enabled.
	Enabled bool `json:"enabled,omitempty"`

	// ExpireTimeMillis: Output only. Time at which the Analytics add-on
	// expires in milliseconds since epoch. If unspecified, the add-on will
	// never expire.
	ExpireTimeMillis int64 `json:"expireTimeMillis,omitempty,string"`

	// State: Output only. The state of the Analytics add-on.
	//
	// Possible values:
	//   "ADDON_STATE_UNSPECIFIED" - Default value.
	//   "ENABLING" - Add-on is in progress of enabling.
	//   "ENABLED" - Add-on is fully enabled and ready to use.
	//   "DISABLING" - Add-on is in progress of disabling.
	//   "DISABLED" - Add-on is fully disabled.
	State string `json:"state,omitempty"`

	// UpdateTime: Output only. The latest update time.
	UpdateTime string `json:"updateTime,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Enabled") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Enabled") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1AnalyticsConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1AnalyticsConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ApiCategory: `ApiCategory` represents an API
// category. Catalog items
// (/apigee/docs/reference/apis/apigee/rest/v1/organizations.sites.apidoc
// s) can be tagged with API categories; users viewing the API catalog
// in the portal will have the option to browse the catalog by category.
type GoogleCloudApigeeV1ApiCategory struct {
	// Id: ID of the category (a UUID).
	Id string `json:"id,omitempty"`

	// Name: Name of the category.
	Name string `json:"name,omitempty"`

	// SiteId: Name of the portal.
	SiteId string `json:"siteId,omitempty"`

	// UpdateTime: Time the category was last modified in milliseconds since
	// epoch.
	UpdateTime int64 `json:"updateTime,omitempty,string"`

	// ForceSendFields is a list of field names (e.g. "Id") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Id") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ApiCategory) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ApiCategory
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ApiCategoryResponse: The API category resource
// wrapped with response status, error_code, etc.
type GoogleCloudApigeeV1ApiCategoryResponse struct {
	// Data: The API category resource.
	Data *GoogleCloudApigeeV1ApiCategory `json:"data,omitempty"`

	// ErrorCode: Unique error code for the request, if any.
	ErrorCode string `json:"errorCode,omitempty"`

	// Message: Description of the operation.
	Message string `json:"message,omitempty"`

	// RequestId: Unique ID of the request.
	RequestId string `json:"requestId,omitempty"`

	// Status: Status of the operation.
	Status string `json:"status,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Data") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Data") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ApiCategoryResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ApiCategoryResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ApiDoc: `ApiDoc` represents an API catalog item.
// Catalog items are used in two ways in a portal: - Users can browse
// and interact with a visual representation of the API documentation -
// The `api_product_name` field provides a link to a backing [API
// product]
// (/apigee/docs/reference/apis/apigee/rest/v1/organizations.apiproducts)
// . Through this link, portal users can create and manage developer
// apps linked to one or more API products.
type GoogleCloudApigeeV1ApiDoc struct {
	// AnonAllowed: Optional. Boolean flag that manages user access to the
	// catalog item. When true, the catalog item has public visibility and
	// can be viewed anonymously; otherwise, only registered users may view
	// it. Note: when the parent portal is enrolled in the audience
	// management feature
	// (https://cloud.google.com/apigee/docs/api-platform/publish/portal/portal-audience#enrolling_in_the_beta_release_of_the_audience_management_feature),
	// and this flag is set to false, visibility is set to an indeterminate
	// state and must be explicitly specified in the management UI (see
	// Manage the visibility of an API in your portal
	// (https://cloud.google.com/apigee/docs/api-platform/publish/portal/publish-apis#visibility)).
	// Additionally, when enrolled in the audience management feature,
	// updates to this flag will be ignored as visibility permissions must
	// be updated in the management UI.
	AnonAllowed bool `json:"anonAllowed,omitempty"`

	// ApiProductName: Required. Immutable. The `name` field of the
	// associated API product
	// (/apigee/docs/reference/apis/apigee/rest/v1/organizations.apiproducts)
	// . A portal may have only one catalog item associated with a given API
	// product.
	ApiProductName string `json:"apiProductName,omitempty"`

	// CategoryIds: Optional. The IDs of the API categories to which this
	// catalog item belongs.
	CategoryIds []string `json:"categoryIds,omitempty"`

	// Description: Optional. Description of the catalog item. Max length is
	// 10,000 characters.
	Description string `json:"description,omitempty"`

	// EdgeAPIProductName: Optional. Immutable. DEPRECATED: use the
	// `apiProductName` field instead
	EdgeAPIProductName string `json:"edgeAPIProductName,omitempty"`

	// GraphqlEndpointUrl: Optional. DEPRECATED: manage documentation
	// through the `getDocumentation` and `updateDocumentation` methods
	GraphqlEndpointUrl string `json:"graphqlEndpointUrl,omitempty"`

	// GraphqlSchema: Optional. DEPRECATED: manage documentation through the
	// `getDocumentation` and `updateDocumentation` methods
	GraphqlSchema string `json:"graphqlSchema,omitempty"`

	// GraphqlSchemaDisplayName: Optional. DEPRECATED: manage documentation
	// through the `getDocumentation` and `updateDocumentation` methods
	GraphqlSchemaDisplayName string `json:"graphqlSchemaDisplayName,omitempty"`

	// Id: Output only. The ID of the catalog item.
	Id int64 `json:"id,omitempty,string"`

	// ImageUrl: Optional. Location of the image used for the catalog item
	// in the catalog. For portal files, this can have the format
	// `/files/{filename}`. Max length is 2,083 characters.
	ImageUrl string `json:"imageUrl,omitempty"`

	// Modified: Output only. Time the catalog item was last modified in
	// milliseconds since epoch.
	Modified int64 `json:"modified,omitempty,string"`

	// Published: Optional. Denotes whether the catalog item is published to
	// the portal or is in a draft state. When the parent portal is enrolled
	// in the audience management feature
	// (https://cloud.google.com/apigee/docs/api-platform/publish/portal/portal-audience#enrolling_in_the_beta_release_of_the_audience_management_feature),
	// the visibility can be set to public on creation by setting the
	// anonAllowed flag to true or further managed in the management UI (see
	// Manage the visibility of an API in your portal
	// (https://cloud.google.com/apigee/docs/api-platform/publish/portal/publish-apis#visibility))
	// before it can be visible to any users. If not enrolled in the
	// audience management feature, the visibility is managed by the
	// `anonAllowed` flag.
	Published bool `json:"published,omitempty"`

	// RequireCallbackUrl: Optional. Whether a callback URL is required when
	// this catalog item's API product is enabled in a developer app. When
	// true, a portal user will be required to input a URL when managing the
	// app (this is typically used for the app's OAuth flow).
	RequireCallbackUrl bool `json:"requireCallbackUrl,omitempty"`

	// SiteId: Output only. The ID of the parent portal.
	SiteId string `json:"siteId,omitempty"`

	// SpecId: Optional. DEPRECATED: DO NOT USE
	SpecId string `json:"specId,omitempty"`

	// Title: Required. The user-facing name of the catalog item. `title`
	// must be a non-empty string with a max length of 255 characters.
	Title string `json:"title,omitempty"`

	// Visibility: Optional. DEPRECATED: use the `published` field instead
	Visibility bool `json:"visibility,omitempty"`

	// ForceSendFields is a list of field names (e.g. "AnonAllowed") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AnonAllowed") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ApiDoc) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ApiDoc
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ApiDocDocumentation: The documentation for a
// catalog item.
type GoogleCloudApigeeV1ApiDocDocumentation struct {
	// GraphqlDocumentation: Optional. GraphQL documentation.
	GraphqlDocumentation *GoogleCloudApigeeV1GraphqlDocumentation `json:"graphqlDocumentation,omitempty"`

	// OasDocumentation: Optional. OpenAPI Specification documentation.
	OasDocumentation *GoogleCloudApigeeV1OASDocumentation `json:"oasDocumentation,omitempty"`

	// ForceSendFields is a list of field names (e.g.
	// "GraphqlDocumentation") to unconditionally include in API requests.
	// By default, fields with empty or default values are omitted from API
	// requests. However, any non-pointer, non-interface field appearing in
	// ForceSendFields will be sent to the server regardless of whether the
	// field is empty or not. This may be used to include empty fields in
	// Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "GraphqlDocumentation") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ApiDocDocumentation) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ApiDocDocumentation
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ApiDocDocumentationResponse: The catalog item
// documentation wrapped with response status, error_code, etc.
type GoogleCloudApigeeV1ApiDocDocumentationResponse struct {
	// Data: Output only. The documentation resource.
	Data *GoogleCloudApigeeV1ApiDocDocumentation `json:"data,omitempty"`

	// ErrorCode: Output only. Unique error code for the request, if any.
	ErrorCode string `json:"errorCode,omitempty"`

	// Message: Output only. Description of the operation.
	Message string `json:"message,omitempty"`

	// RequestId: Output only. Unique ID of the request.
	RequestId string `json:"requestId,omitempty"`

	// Status: Output only. Status of the operation.
	Status string `json:"status,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Data") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Data") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ApiDocDocumentationResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ApiDocDocumentationResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ApiDocResponse: The catalog item resource wrapped
// with response status, error_code, etc.
type GoogleCloudApigeeV1ApiDocResponse struct {
	// Data: The catalog item resource.
	Data *GoogleCloudApigeeV1ApiDoc `json:"data,omitempty"`

	// ErrorCode: Unique error code for the request, if any.
	ErrorCode string `json:"errorCode,omitempty"`

	// Message: Description of the operation.
	Message string `json:"message,omitempty"`

	// RequestId: Unique ID of the request.
	RequestId string `json:"requestId,omitempty"`

	// Status: Status of the operation.
	Status string `json:"status,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Data") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Data") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ApiDocResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ApiDocResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1ApiProduct struct {
	// ApiResources: Comma-separated list of API resources to be bundled in
	// the API product. By default, the resource paths are mapped from the
	// `proxy.pathsuffix` variable. The proxy path suffix is defined as the
	// URI fragment following the ProxyEndpoint base path. For example, if
	// the `apiResources` element is defined to be `/forecastrss` and the
	// base path defined for the API proxy is `/weather`, then only requests
	// to `/weather/forecastrss` are permitted by the API product. You can
	// select a specific path, or you can select all subpaths with the
	// following wildcard: - `/**`: Indicates that all sub-URIs are
	// included. - `/*` : Indicates that only URIs one level down are
	// included. By default, / supports the same resources as /** as well as
	// the base path defined by the API proxy. For example, if the base path
	// of the API proxy is `/v1/weatherapikey`, then the API product
	// supports requests to `/v1/weatherapikey` and to any sub-URIs, such as
	// `/v1/weatherapikey/forecastrss`, `/v1/weatherapikey/region/CA`, and
	// so on. For more information, see Managing API products.
	ApiResources []string `json:"apiResources,omitempty"`

	// ApprovalType: Flag that specifies how API keys are approved to access
	// the APIs defined by the API product. If set to `manual`, the consumer
	// key is generated and returned in "pending" state. In this case, the
	// API keys won't work until they have been explicitly approved. If set
	// to `auto`, the consumer key is generated and returned in "approved"
	// state and can be used immediately. **Note:** Typically, `auto` is
	// used to provide access to free or trial API products that provide
	// limited quota or capabilities.
	ApprovalType string `json:"approvalType,omitempty"`

	// Attributes: Array of attributes that may be used to extend the
	// default API product profile with customer-specific metadata. You can
	// specify a maximum of 18 attributes. Use this property to specify the
	// access level of the API product as either `public`, `private`, or
	// `internal`. Only products marked `public` are available to developers
	// in the Apigee developer portal. For example, you can set a product to
	// `internal` while it is in development and then change access to
	// `public` when it is ready to release on the portal. API products
	// marked as `private` do not appear on the portal, but can be accessed
	// by external developers.
	Attributes []*GoogleCloudApigeeV1Attribute `json:"attributes,omitempty"`

	// CreatedAt: Response only. Creation time of this environment as
	// milliseconds since epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// Description: Description of the API product. Include key information
	// about the API product that is not captured by other fields.
	Description string `json:"description,omitempty"`

	// DisplayName: Name displayed in the UI or developer portal to
	// developers registering for API access.
	DisplayName string `json:"displayName,omitempty"`

	// Environments: Comma-separated list of environment names to which the
	// API product is bound. Requests to environments that are not listed
	// are rejected. By specifying one or more environments, you can bind
	// the resources listed in the API product to a specific environment,
	// preventing developers from accessing those resources through API
	// proxies deployed in another environment. This setting is used, for
	// example, to prevent resources associated with API proxies in `prod`
	// from being accessed by API proxies deployed in `test`.
	Environments []string `json:"environments,omitempty"`

	// GraphqlOperationGroup: Configuration used to group Apigee proxies or
	// remote services with graphQL operation name, graphQL operation type
	// and quotas. This grouping allows us to precisely set quota for a
	// particular combination of graphQL name and operation type for a
	// particular proxy request. If graphQL name is not set, this would
	// imply quota will be applied on all graphQL requests matching the
	// operation type.
	GraphqlOperationGroup *GoogleCloudApigeeV1GraphQLOperationGroup `json:"graphqlOperationGroup,omitempty"`

	// GrpcOperationGroup: Optional. Configuration used to group Apigee
	// proxies with gRPC services and method names. This grouping allows us
	// to set quota for a particular proxy with the gRPC service name and
	// method. If a method name is not set, this implies quota and
	// authorization are applied to all gRPC methods implemented by that
	// proxy for that particular gRPC service.
	GrpcOperationGroup *GoogleCloudApigeeV1GrpcOperationGroup `json:"grpcOperationGroup,omitempty"`

	// LastModifiedAt: Response only. Modified time of this environment as
	// milliseconds since epoch.
	LastModifiedAt int64 `json:"lastModifiedAt,omitempty,string"`

	// Name: Internal name of the API product. Characters you can use in the
	// name are restricted to: `A-Z0-9._\-$ %`. **Note:** The internal name
	// cannot be edited when updating the API product.
	Name string `json:"name,omitempty"`

	// OperationGroup: Configuration used to group Apigee proxies or remote
	// services with resources, method types, and quotas. The resource
	// refers to the resource URI (excluding the base path). With this
	// grouping, the API product creator is able to fine-tune and give
	// precise control over which REST methods have access to specific
	// resources and how many calls can be made (using the `quota` setting).
	// **Note:** The `api_resources` setting cannot be specified for both
	// the API product and operation group; otherwise the call will fail.
	OperationGroup *GoogleCloudApigeeV1OperationGroup `json:"operationGroup,omitempty"`

	// Proxies: Comma-separated list of API proxy names to which this API
	// product is bound. By specifying API proxies, you can associate
	// resources in the API product with specific API proxies, preventing
	// developers from accessing those resources through other API proxies.
	// Apigee rejects requests to API proxies that are not listed. **Note:**
	// The API proxy names must already exist in the specified environment
	// as they will be validated upon creation.
	Proxies []string `json:"proxies,omitempty"`

	// Quota: Number of request messages permitted per app by this API
	// product for the specified `quotaInterval` and `quotaTimeUnit`. For
	// example, a `quota` of 50, for a `quotaInterval` of 12 and a
	// `quotaTimeUnit` of hours means 50 requests are allowed every 12
	// hours.
	Quota string `json:"quota,omitempty"`

	// QuotaCounterScope: Scope of the quota decides how the quota counter
	// gets applied and evaluate for quota violation. If the Scope is set as
	// PROXY, then all the operations defined for the APIproduct that are
	// associated with the same proxy will share the same quota counter set
	// at the APIproduct level, making it a global counter at a proxy level.
	// If the Scope is set as OPERATION, then each operations get the
	// counter set at the API product dedicated, making it a local counter.
	// Note that, the QuotaCounterScope applies only when an operation does
	// not have dedicated quota set for itself.
	//
	// Possible values:
	//   "QUOTA_COUNTER_SCOPE_UNSPECIFIED" - When quota is not explicitly
	// defined for each operation(REST/GraphQL), the limits set at product
	// level will be used as a local counter for quota evaluation by all the
	// operations, independent of proxy association.
	//   "PROXY" - When quota is not explicitly defined for each
	// operation(REST/GraphQL), set at product level will be used as a
	// global counter for quota evaluation by all the operations associated
	// with a particular proxy.
	//   "OPERATION" - When quota is not explicitly defined for each
	// operation(REST/GraphQL), the limits set at product level will be used
	// as a local counter for quota evaluation by all the operations,
	// independent of proxy association. This behavior mimics the same as
	// QUOTA_COUNTER_SCOPE_UNSPECIFIED.
	QuotaCounterScope string `json:"quotaCounterScope,omitempty"`

	// QuotaInterval: Time interval over which the number of request
	// messages is calculated.
	QuotaInterval string `json:"quotaInterval,omitempty"`

	// QuotaTimeUnit: Time unit defined for the `quotaInterval`. Valid
	// values include `minute`, `hour`, `day`, or `month`.
	QuotaTimeUnit string `json:"quotaTimeUnit,omitempty"`

	// Scopes: Comma-separated list of OAuth scopes that are validated at
	// runtime. Apigee validates that the scopes in any access token
	// presented match the scopes defined in the OAuth policy associated
	// with the API product.
	Scopes []string `json:"scopes,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ApiResources") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ApiResources") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ApiProduct) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ApiProduct
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1ApiProductRef struct {
	// Apiproduct: Name of the API product.
	Apiproduct string `json:"apiproduct,omitempty"`

	// Status: Status of the API product. Valid values are `approved` or
	// `revoked`.
	Status string `json:"status,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Apiproduct") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Apiproduct") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ApiProductRef) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ApiProductRef
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ApiProxy: Metadata describing the API proxy
type GoogleCloudApigeeV1ApiProxy struct {
	// ApiProxyType: Output only. The type of the API proxy.
	//
	// Possible values:
	//   "API_PROXY_TYPE_UNSPECIFIED" - API proxy type not specified.
	//   "PROGRAMMABLE" - Programmable API Proxies enable you to develop
	// APIs with highly flexible behavior using bundled policy configuration
	// and one or more programming languages to describe complex sequential
	// and/or conditional flows of logic.
	//   "CONFIGURABLE" - Configurable API Proxies enable you to develop
	// efficient APIs using simple configuration while complex execution
	// control flow logic is handled by Apigee. This type only works with
	// the ARCHIVE deployment type and cannot be combined with the PROXY
	// deployment type.
	ApiProxyType string `json:"apiProxyType,omitempty"`

	// Labels: User labels applied to this API Proxy.
	Labels map[string]string `json:"labels,omitempty"`

	// LatestRevisionId: Output only. The id of the most recently created
	// revision for this api proxy.
	LatestRevisionId string `json:"latestRevisionId,omitempty"`

	// MetaData: Output only. Metadata describing the API proxy.
	MetaData *GoogleCloudApigeeV1EntityMetadata `json:"metaData,omitempty"`

	// Name: Output only. Name of the API proxy.
	Name string `json:"name,omitempty"`

	// ReadOnly: Output only. Whether this proxy is read-only. A read-only
	// proxy cannot have new revisions created through calls to
	// CreateApiProxyRevision. A proxy is read-only if it was generated by
	// an archive.
	ReadOnly bool `json:"readOnly,omitempty"`

	// Revision: Output only. List of revisions defined for the API proxy.
	Revision []string `json:"revision,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ApiProxyType") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ApiProxyType") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ApiProxy) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ApiProxy
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ApiProxyRevision: API proxy revision.
type GoogleCloudApigeeV1ApiProxyRevision struct {
	// Archive: Output only. The archive that generated this proxy revision.
	// This field is only present on proxy revisions that were generated by
	// an archive. Proxies generated by archives cannot be updated, deleted,
	// or deployed to other environments. Format:
	// `organizations/*/environments/*/archiveDeployments/*`
	Archive string `json:"archive,omitempty"`

	// Basepaths: Base URL of the API proxy.
	Basepaths []string `json:"basepaths,omitempty"`

	// ConfigurationVersion: Version of the API proxy configuration schema
	// to which the API proxy conforms. Currently, the only supported value
	// is 4.0 (`majorVersion.minorVersion`). This setting may be used in the
	// future to track the evolution of the API proxy format.
	ConfigurationVersion *GoogleCloudApigeeV1ConfigVersion `json:"configurationVersion,omitempty"`

	// ContextInfo: Revision number, app name, and organization for the API
	// proxy.
	ContextInfo string `json:"contextInfo,omitempty"`

	// CreatedAt: Time that the API proxy revision was created in
	// milliseconds since epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// Description: Description of the API proxy revision.
	Description string `json:"description,omitempty"`

	// DisplayName: Human-readable name of the API proxy.
	DisplayName string `json:"displayName,omitempty"`

	// EntityMetaDataAsProperties: Metadata describing the API proxy
	// revision as a key-value map.
	EntityMetaDataAsProperties map[string]string `json:"entityMetaDataAsProperties,omitempty"`

	// HasExtensiblePolicy: Output only. This field will be marked as true
	// if revision contains any policies marked as extensible.
	HasExtensiblePolicy bool `json:"hasExtensiblePolicy,omitempty"`

	// IntegrationEndpoints: List of IntegrationEndpoints in the
	// '/integration-endpoints' directory of the API proxy. This is a
	// 'manifest' setting designed to provide visibility into the contents
	// of the API proxy.
	IntegrationEndpoints []string `json:"integrationEndpoints,omitempty"`

	// LastModifiedAt: Time that the API proxy revision was last modified in
	// milliseconds since epoch.
	LastModifiedAt int64 `json:"lastModifiedAt,omitempty,string"`

	// Name: Name of the API proxy.
	Name string `json:"name,omitempty"`

	// Policies: List of policy names included in the API proxy revision..
	Policies []string `json:"policies,omitempty"`

	// Proxies: List of proxy names included in the API proxy revision.
	Proxies []string `json:"proxies,omitempty"`

	// ProxyEndpoints: List of ProxyEndpoints in the `/proxies` directory of
	// the API proxy. Typically, this element is included only when the API
	// proxy was created using the Edge UI. This is a 'manifest' setting
	// designed to provide visibility into the contents of the API proxy.
	ProxyEndpoints []string `json:"proxyEndpoints,omitempty"`

	// ResourceFiles: List of resource files included in the API proxy
	// revision.
	ResourceFiles *GoogleCloudApigeeV1ResourceFiles `json:"resourceFiles,omitempty"`

	// Resources: List of the resources included in the API proxy revision
	// formatted as "{type}://{name}".
	Resources []string `json:"resources,omitempty"`

	// Revision: API proxy revision.
	Revision string `json:"revision,omitempty"`

	// SharedFlows: List of the shared flows included in the API proxy
	// revision.
	SharedFlows []string `json:"sharedFlows,omitempty"`

	// Spec: OpenAPI Specification that is associated with the API proxy.
	// The value is set to a URL or to a path in the specification store.
	Spec string `json:"spec,omitempty"`

	// TargetEndpoints: List of TargetEndpoints in the `/targets` directory
	// of the API proxy. Typically, this element is included only when the
	// API proxy was created using the Edge UI. This is a 'manifest' setting
	// designed to provide visibility into the contents of the API proxy.
	TargetEndpoints []string `json:"targetEndpoints,omitempty"`

	// TargetServers: List of TargetServers referenced in any TargetEndpoint
	// in the API proxy. Typically, you will see this element only when the
	// API proxy was created using the Edge UI. This is a 'manifest' setting
	// designed to provide visibility into the contents of the API proxy.
	TargetServers []string `json:"targetServers,omitempty"`

	// Targets: List of the targets included in the API proxy revision.
	Targets []string `json:"targets,omitempty"`

	// Teams: List of the teams included in the API proxy revision.
	Teams []string `json:"teams,omitempty"`

	// Type: Type. Set to `Application`. Maintained for compatibility with
	// the Apigee Edge API.
	Type string `json:"type,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Archive") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Archive") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ApiProxyRevision) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ApiProxyRevision
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ApiSecurityConfig: Configurations of the API
// Security add-on.
type GoogleCloudApigeeV1ApiSecurityConfig struct {
	// Enabled: Flag that specifies whether the API security add-on is
	// enabled.
	Enabled bool `json:"enabled,omitempty"`

	// ExpiresAt: Output only. Time at which the API Security add-on expires
	// in in milliseconds since epoch. If unspecified, the add-on will never
	// expire.
	ExpiresAt int64 `json:"expiresAt,omitempty,string"`

	// ForceSendFields is a list of field names (e.g. "Enabled") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Enabled") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ApiSecurityConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ApiSecurityConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ApiSecurityRuntimeConfig: Response for
// GetApiSecurityRuntimeConfig[EnvironmentService.GetApiSecurityRuntimeCo
// nfig].
type GoogleCloudApigeeV1ApiSecurityRuntimeConfig struct {
	// Location: A list of up to 5 Cloud Storage Blobs that contain
	// SecurityActions.
	Location []string `json:"location,omitempty"`

	// Name: Name of the environment API Security Runtime configuration
	// resource. Format:
	// `organizations/{org}/environments/{env}/apiSecurityRuntimeConfig`
	Name string `json:"name,omitempty"`

	// RevisionId: Revision ID of the API Security Runtime configuration.
	// The higher the value, the more recently the configuration was
	// deployed.
	RevisionId int64 `json:"revisionId,omitempty,string"`

	// Uid: Unique ID for the API Security Runtime configuration. The ID
	// will only change if the environment is deleted and recreated.
	Uid string `json:"uid,omitempty"`

	// UpdateTime: Time that the API Security Runtime configuration was
	// updated.
	UpdateTime string `json:"updateTime,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Location") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Location") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ApiSecurityRuntimeConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ApiSecurityRuntimeConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1App struct {
	// ApiProducts: List of API products associated with the app.
	ApiProducts []*GoogleCloudApigeeV1ApiProductRef `json:"apiProducts,omitempty"`

	// AppGroup: Name of the AppGroup
	AppGroup string `json:"appGroup,omitempty"`

	// AppId: ID of the app.
	AppId string `json:"appId,omitempty"`

	// Attributes: List of attributes.
	Attributes []*GoogleCloudApigeeV1Attribute `json:"attributes,omitempty"`

	// CallbackUrl: Callback URL used by OAuth 2.0 authorization servers to
	// communicate authorization codes back to apps.
	CallbackUrl string `json:"callbackUrl,omitempty"`

	// CompanyName: Name of the company that owns the app.
	CompanyName string `json:"companyName,omitempty"`

	// CreatedAt: Output only. Unix time when the app was created.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// Credentials: Output only. Set of credentials for the app. Credentials
	// are API key/secret pairs associated with API products.
	Credentials []*GoogleCloudApigeeV1Credential `json:"credentials,omitempty"`

	// DeveloperEmail: Email of the developer.
	DeveloperEmail string `json:"developerEmail,omitempty"`

	// DeveloperId: ID of the developer.
	DeveloperId string `json:"developerId,omitempty"`

	// KeyExpiresIn: Duration, in milliseconds, of the consumer key that
	// will be generated for the app. The default value, -1, indicates an
	// infinite validity period. Once set, the expiration can't be updated.
	// json key: keyExpiresIn
	KeyExpiresIn int64 `json:"keyExpiresIn,omitempty,string"`

	// LastModifiedAt: Output only. Last modified time as milliseconds since
	// epoch.
	LastModifiedAt int64 `json:"lastModifiedAt,omitempty,string"`

	// Name: Name of the app.
	Name string `json:"name,omitempty"`

	// Scopes: Scopes to apply to the app. The specified scope names must
	// already exist on the API product that you associate with the app.
	Scopes []string `json:"scopes,omitempty"`

	// Status: Status of the credential.
	Status string `json:"status,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ApiProducts") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ApiProducts") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1App) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1App
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1AppGroup: AppGroup contains the request/response
// fields representing the logical grouping of apps. Note that
// appgroup_id, create_time and update_time cannot be changed by the
// user, and gets updated by the system. The name and the organization
// once provided cannot be edited subsequently.
type GoogleCloudApigeeV1AppGroup struct {
	// AppGroupId: Output only. Internal identifier that cannot be edited
	AppGroupId string `json:"appGroupId,omitempty"`

	// Attributes: A list of attributes
	Attributes []*GoogleCloudApigeeV1Attribute `json:"attributes,omitempty"`

	// ChannelId: channel identifier identifies the owner maintaing this
	// grouping.
	ChannelId string `json:"channelId,omitempty"`

	// ChannelUri: A reference to the associated storefront/marketplace.
	ChannelUri string `json:"channelUri,omitempty"`

	// CreatedAt: Output only. Created time as milliseconds since epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// DisplayName: app group name displayed in the UI
	DisplayName string `json:"displayName,omitempty"`

	// LastModifiedAt: Output only. Modified time as milliseconds since
	// epoch.
	LastModifiedAt int64 `json:"lastModifiedAt,omitempty,string"`

	// Name: Immutable. Name of the AppGroup. Characters you can use in the
	// name are restricted to: A-Z0-9._\-$ %.
	Name string `json:"name,omitempty"`

	// Organization: Immutable. the org the app group is created
	Organization string `json:"organization,omitempty"`

	// Status: Valid values are `active` or `inactive`. Note that the status
	// of the AppGroup should be updated via UpdateAppGroupRequest by
	// setting the action as `active` or `inactive`.
	Status string `json:"status,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "AppGroupId") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AppGroupId") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1AppGroup) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1AppGroup
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1AppGroupApp: Response for
// [GetAppGroupApp].[AppGroupApps.GetAppGroupApp],
// [CreateAppGroupAppRequest].[AppGroupApp.CreateAppGroupAppRequest] and
// [DeleteAppGroupApp].[AppGroupApp.DeleteAppGroupApp]
type GoogleCloudApigeeV1AppGroupApp struct {
	// ApiProducts: List of API products associated with the AppGroup app.
	ApiProducts []string `json:"apiProducts,omitempty"`

	// AppGroup: Immutable. Name of the parent AppGroup whose resource name
	// format is of syntax (organizations/*/appgroups/*).
	AppGroup string `json:"appGroup,omitempty"`

	// AppId: Immutable. ID of the AppGroup app.
	AppId string `json:"appId,omitempty"`

	// Attributes: List of attributes for the AppGroup app.
	Attributes []*GoogleCloudApigeeV1Attribute `json:"attributes,omitempty"`

	// CallbackUrl: Callback URL used by OAuth 2.0 authorization servers to
	// communicate authorization codes back to AppGroup apps.
	CallbackUrl string `json:"callbackUrl,omitempty"`

	// CreatedAt: Output only. Time the AppGroup app was created in
	// milliseconds since epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// Credentials: Output only. Set of credentials for the AppGroup app
	// consisting of the consumer key/secret pairs associated with the API
	// products.
	Credentials []*GoogleCloudApigeeV1Credential `json:"credentials,omitempty"`

	// KeyExpiresIn: Immutable. Expiration time, in seconds, for the
	// consumer key that is generated for the AppGroup app. If not set or
	// left to the default value of `-1`, the API key never expires. The
	// expiration time can't be updated after it is set.
	KeyExpiresIn int64 `json:"keyExpiresIn,omitempty,string"`

	// LastModifiedAt: Output only. Time the AppGroup app was modified in
	// milliseconds since epoch.
	LastModifiedAt int64 `json:"lastModifiedAt,omitempty,string"`

	// Name: Immutable. Name of the AppGroup app whose resource name format
	// is of syntax (organizations/*/appgroups/*/apps/*).
	Name string `json:"name,omitempty"`

	// Scopes: Scopes to apply to the AppGroup app. The specified scopes
	// must already exist for the API product that you associate with the
	// AppGroup app.
	Scopes []string `json:"scopes,omitempty"`

	// Status: Status of the App. Valid values include `approved` or
	// `revoked`.
	Status string `json:"status,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ApiProducts") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ApiProducts") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1AppGroupApp) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1AppGroupApp
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1AppGroupAppKey: AppGroupAppKey contains all the
// information associated with the credentials.
type GoogleCloudApigeeV1AppGroupAppKey struct {
	// ApiProducts: Output only. List of API products and its status for
	// which the credential can be used. **Note**: Use
	// UpdateAppGroupAppKeyApiProductRequest API to make the association
	// after the consumer key and secret are created.
	ApiProducts []*GoogleCloudApigeeV1APIProductAssociation `json:"apiProducts,omitempty"`

	// Attributes: List of attributes associated with the credential.
	Attributes []*GoogleCloudApigeeV1Attribute `json:"attributes,omitempty"`

	// ConsumerKey: Immutable. Consumer key.
	ConsumerKey string `json:"consumerKey,omitempty"`

	// ConsumerSecret: Secret key.
	ConsumerSecret string `json:"consumerSecret,omitempty"`

	// ExpiresAt: Output only. Time the AppGroup app expires in milliseconds
	// since epoch.
	ExpiresAt int64 `json:"expiresAt,omitempty,string"`

	// ExpiresInSeconds: Immutable. Expiration time, in seconds, for the
	// consumer key. If not set or left to the default value of `-1`, the
	// API key never expires. The expiration time can't be updated after it
	// is set.
	ExpiresInSeconds int64 `json:"expiresInSeconds,omitempty,string"`

	// IssuedAt: Output only. Time the AppGroup app was created in
	// milliseconds since epoch.
	IssuedAt int64 `json:"issuedAt,omitempty,string"`

	// Scopes: Scopes to apply to the app. The specified scope names must
	// already be defined for the API product that you associate with the
	// app.
	Scopes []string `json:"scopes,omitempty"`

	// Status: Status of the credential. Valid values include `approved` or
	// `revoked`.
	Status string `json:"status,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ApiProducts") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ApiProducts") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1AppGroupAppKey) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1AppGroupAppKey
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ArchiveDeployment: Archive Deployment information.
type GoogleCloudApigeeV1ArchiveDeployment struct {
	// CreatedAt: Output only. The time at which the Archive Deployment was
	// created in milliseconds since the epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// GcsUri: Input only. The Google Cloud Storage signed URL returned from
	// GenerateUploadUrl and used to upload the Archive zip file.
	GcsUri string `json:"gcsUri,omitempty"`

	// Labels: User-supplied key-value pairs used to organize
	// ArchiveDeployments. Label keys must be between 1 and 63 characters
	// long, have a UTF-8 encoding of maximum 128 bytes, and must conform to
	// the following PCRE regular expression: \p{Ll}\p{Lo}{0,62} Label
	// values must be between 1 and 63 characters long, have a UTF-8
	// encoding of maximum 128 bytes, and must conform to the following PCRE
	// regular expression: [\p{Ll}\p{Lo}\p{N}_-]{0,63} No more than 64
	// labels can be associated with a given store.
	Labels map[string]string `json:"labels,omitempty"`

	// Name: Name of the Archive Deployment in the following format:
	// `organizations/{org}/environments/{env}/archiveDeployments/{id}`.
	Name string `json:"name,omitempty"`

	// Operation: Output only. A reference to the LRO that created this
	// Archive Deployment in the following format:
	// `organizations/{org}/operations/{id}`
	Operation string `json:"operation,omitempty"`

	// UpdatedAt: Output only. The time at which the Archive Deployment was
	// updated in milliseconds since the epoch.
	UpdatedAt int64 `json:"updatedAt,omitempty,string"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "CreatedAt") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "CreatedAt") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ArchiveDeployment) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ArchiveDeployment
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1AsyncQuery struct {
	// Created: Creation time of the query.
	Created string `json:"created,omitempty"`

	// EnvgroupHostname: Hostname is available only when query is executed
	// at host level.
	EnvgroupHostname string `json:"envgroupHostname,omitempty"`

	// Error: Error is set when query fails.
	Error string `json:"error,omitempty"`

	// ExecutionTime: ExecutionTime is available only after the query is
	// completed.
	ExecutionTime string `json:"executionTime,omitempty"`

	// Name: Asynchronous Query Name.
	Name string `json:"name,omitempty"`

	// QueryParams: Contains information like metrics, dimenstions etc of
	// the AsyncQuery.
	QueryParams *GoogleCloudApigeeV1QueryMetadata `json:"queryParams,omitempty"`

	// ReportDefinitionId: Asynchronous Report ID.
	ReportDefinitionId string `json:"reportDefinitionId,omitempty"`

	// Result: Result is available only after the query is completed.
	Result *GoogleCloudApigeeV1AsyncQueryResult `json:"result,omitempty"`

	// ResultFileSize: ResultFileSize is available only after the query is
	// completed.
	ResultFileSize string `json:"resultFileSize,omitempty"`

	// ResultRows: ResultRows is available only after the query is
	// completed.
	ResultRows int64 `json:"resultRows,omitempty,string"`

	// Self: Self link of the query. Example:
	// `/organizations/myorg/environments/myenv/queries/9cfc0d85-0f30-46d6-ae
	// 6f-318d0cb961bd` or following format if query is running at host
	// level:
	// `/organizations/myorg/hostQueries/9cfc0d85-0f30-46d6-ae6f-318d0cb961bd
	// `
	Self string `json:"self,omitempty"`

	// State: Query state could be "enqueued", "running", "completed",
	// "failed".
	State string `json:"state,omitempty"`

	// Updated: Last updated timestamp for the query.
	Updated string `json:"updated,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Created") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Created") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1AsyncQuery) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1AsyncQuery
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1AsyncQueryResult struct {
	// Expires: Query result will be unaccessable after this time.
	Expires string `json:"expires,omitempty"`

	// Self: Self link of the query results. Example:
	// `/organizations/myorg/environments/myenv/queries/9cfc0d85-0f30-46d6-ae
	// 6f-318d0cb961bd/result` or following format if query is running at
	// host level:
	// `/organizations/myorg/hostQueries/9cfc0d85-0f30-46d6-ae6f-318d0cb961bd
	// /result`
	Self string `json:"self,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Expires") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Expires") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1AsyncQueryResult) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1AsyncQueryResult
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1AsyncQueryResultView struct {
	// Code: Error code when there is a failure.
	Code int64 `json:"code,omitempty"`

	// Error: Error message when there is a failure.
	Error string `json:"error,omitempty"`

	// Metadata: Metadata contains information like metrics, dimenstions etc
	// of the AsyncQuery.
	Metadata *GoogleCloudApigeeV1QueryMetadata `json:"metadata,omitempty"`

	// Rows: Rows of query result. Each row is a JSON object. Example:
	// {sum(message_count): 1, developer_app: "(not set)",…}
	Rows []interface{} `json:"rows,omitempty"`

	// State: State of retrieving ResultView.
	State string `json:"state,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Code") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Code") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1AsyncQueryResultView) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1AsyncQueryResultView
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1Attribute: Key-value pair to store extra metadata.
type GoogleCloudApigeeV1Attribute struct {
	// Name: API key of the attribute.
	Name string `json:"name,omitempty"`

	// Value: Value of the attribute.
	Value string `json:"value,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Name") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Name") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Attribute) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Attribute
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1Attributes struct {
	// Attribute: List of attributes.
	Attribute []*GoogleCloudApigeeV1Attribute `json:"attribute,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Attribute") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Attribute") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Attributes) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Attributes
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1BatchUpdateSecurityIncidentsRequest: Request for
// BatchUpdateSecurityIncident.
type GoogleCloudApigeeV1BatchUpdateSecurityIncidentsRequest struct {
	// Requests: Optional. Required. The request message specifying the
	// resources to update. A maximum of 1000 can be modified in a batch.
	Requests []*GoogleCloudApigeeV1UpdateSecurityIncidentRequest `json:"requests,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Requests") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Requests") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1BatchUpdateSecurityIncidentsRequest) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1BatchUpdateSecurityIncidentsRequest
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1BatchUpdateSecurityIncidentsResponse: Response for
// BatchUpdateSecurityIncident.
type GoogleCloudApigeeV1BatchUpdateSecurityIncidentsResponse struct {
	// SecurityIncidents: Output only. Updated security incidents
	SecurityIncidents []*GoogleCloudApigeeV1SecurityIncident `json:"securityIncidents,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "SecurityIncidents")
	// to unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "SecurityIncidents") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1BatchUpdateSecurityIncidentsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1BatchUpdateSecurityIncidentsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1CanaryEvaluation: CanaryEvaluation represents the
// canary analysis between two versions of the runtime that is serving
// requests.
type GoogleCloudApigeeV1CanaryEvaluation struct {
	// Control: Required. The stable version that is serving requests.
	Control string `json:"control,omitempty"`

	// CreateTime: Output only. Create time of the canary evaluation.
	CreateTime string `json:"createTime,omitempty"`

	// EndTime: Required. End time for the evaluation's analysis.
	EndTime string `json:"endTime,omitempty"`

	// MetricLabels: Required. Labels used to filter the metrics used for a
	// canary evaluation.
	MetricLabels *GoogleCloudApigeeV1CanaryEvaluationMetricLabels `json:"metricLabels,omitempty"`

	// Name: Output only. Name of the canary evalution.
	Name string `json:"name,omitempty"`

	// StartTime: Required. Start time for the canary evaluation's analysis.
	StartTime string `json:"startTime,omitempty"`

	// State: Output only. The current state of the canary evaluation.
	//
	// Possible values:
	//   "STATE_UNSPECIFIED" - No state has been specified.
	//   "RUNNING" - The canary evaluation is still in progress.
	//   "SUCCEEDED" - The canary evaluation has finished.
	State string `json:"state,omitempty"`

	// Treatment: Required. The newer version that is serving requests.
	Treatment string `json:"treatment,omitempty"`

	// Verdict: Output only. The resulting verdict of the canary
	// evaluations: NONE, PASS, or FAIL.
	//
	// Possible values:
	//   "VERDICT_UNSPECIFIED" - Verdict is not available yet.
	//   "NONE" - No verdict reached.
	//   "FAIL" - Evaluation is not good.
	//   "PASS" - Evaluation is good.
	Verdict string `json:"verdict,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Control") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Control") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1CanaryEvaluation) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1CanaryEvaluation
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1CanaryEvaluationMetricLabels: Labels that can be
// used to filter Apigee metrics.
type GoogleCloudApigeeV1CanaryEvaluationMetricLabels struct {
	// Env: The environment ID associated with the metrics.
	Env string `json:"env,omitempty"`

	// InstanceId: Required. The instance ID associated with the metrics. In
	// Apigee Hybrid, the value is configured during installation.
	InstanceId string `json:"instance_id,omitempty"`

	// Location: Required. The location associated with the metrics.
	Location string `json:"location,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Env") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Env") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1CanaryEvaluationMetricLabels) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1CanaryEvaluationMetricLabels
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1CertInfo: X.509 certificate as defined in RFC
// 5280.
type GoogleCloudApigeeV1CertInfo struct {
	// BasicConstraints: X.509 basic constraints extension.
	BasicConstraints string `json:"basicConstraints,omitempty"`

	// ExpiryDate: X.509 `notAfter` validity period in milliseconds since
	// epoch.
	ExpiryDate int64 `json:"expiryDate,omitempty,string"`

	// IsValid: Flag that specifies whether the certificate is valid. Flag
	// is set to `Yes` if the certificate is valid, `No` if expired, or `Not
	// yet` if not yet valid.
	IsValid string `json:"isValid,omitempty"`

	// Issuer: X.509 issuer.
	Issuer string `json:"issuer,omitempty"`

	// PublicKey: Public key component of the X.509 subject public key info.
	PublicKey string `json:"publicKey,omitempty"`

	// SerialNumber: X.509 serial number.
	SerialNumber string `json:"serialNumber,omitempty"`

	// SigAlgName: X.509 signatureAlgorithm.
	SigAlgName string `json:"sigAlgName,omitempty"`

	// Subject: X.509 subject.
	Subject string `json:"subject,omitempty"`

	// SubjectAlternativeNames: X.509 subject alternative names (SANs)
	// extension.
	SubjectAlternativeNames []string `json:"subjectAlternativeNames,omitempty"`

	// ValidFrom: X.509 `notBefore` validity period in milliseconds since
	// epoch.
	ValidFrom int64 `json:"validFrom,omitempty,string"`

	// Version: X.509 version.
	Version int64 `json:"version,omitempty"`

	// ForceSendFields is a list of field names (e.g. "BasicConstraints") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "BasicConstraints") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1CertInfo) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1CertInfo
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1Certificate struct {
	// CertInfo: Chain of certificates under this name.
	CertInfo []*GoogleCloudApigeeV1CertInfo `json:"certInfo,omitempty"`

	// ForceSendFields is a list of field names (e.g. "CertInfo") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "CertInfo") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Certificate) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Certificate
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1CommonNameConfig struct {
	MatchWildCards bool `json:"matchWildCards,omitempty"`

	Name string `json:"name,omitempty"`

	// ForceSendFields is a list of field names (e.g. "MatchWildCards") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "MatchWildCards") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1CommonNameConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1CommonNameConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ComputeEnvironmentScoresRequest: Request for
// ComputeEnvironmentScores.
type GoogleCloudApigeeV1ComputeEnvironmentScoresRequest struct {
	// Filters: Optional. Filters are used to filter scored components.
	// Return all the components if no filter is mentioned. Example: [{
	// "scorePath":
	// "/org@myorg/envgroup@myenvgroup/env@myenv/proxies/proxy@myproxy/source
	// " }, { "scorePath":
	// "/org@myorg/envgroup@myenvgroup/env@myenv/proxies/proxy@myproxy/target
	// ", }] This will return components with path:
	// "/org@myorg/envgroup@myenvgroup/env@myenv/proxies/proxy@myproxy/source
	// " OR
	// "/org@myorg/envgroup@myenvgroup/env@myenv/proxies/proxy@myproxy/target
	// "
	Filters []*GoogleCloudApigeeV1ComputeEnvironmentScoresRequestFilter `json:"filters,omitempty"`

	// PageSize: Optional. The maximum number of subcomponents to be
	// returned in a single page. The service may return fewer than this
	// value. If unspecified, at most 100 subcomponents will be returned in
	// a single page.
	PageSize int64 `json:"pageSize,omitempty"`

	// PageToken: Optional. A token that can be sent as `page_token` to
	// retrieve the next page. If this field is omitted, there are no
	// subsequent pages.
	PageToken string `json:"pageToken,omitempty"`

	// TimeRange: Required. Time range for score calculation. At most 14
	// days of scores will be returned.
	TimeRange *GoogleTypeInterval `json:"timeRange,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Filters") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Filters") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ComputeEnvironmentScoresRequest) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ComputeEnvironmentScoresRequest
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ComputeEnvironmentScoresRequestFilter: Filter
// scores by component path. Used custom filter instead of AIP-160 as
// the use cases are highly constrained and predictable.
type GoogleCloudApigeeV1ComputeEnvironmentScoresRequestFilter struct {
	// ScorePath: Optional. Return scores for this component. Example:
	// "/org@myorg/envgroup@myenvgroup/env@myenv/proxies/proxy@myproxy/source
	// "
	ScorePath string `json:"scorePath,omitempty"`

	// ForceSendFields is a list of field names (e.g. "ScorePath") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ScorePath") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ComputeEnvironmentScoresRequestFilter) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ComputeEnvironmentScoresRequestFilter
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ComputeEnvironmentScoresResponse: Response for
// ComputeEnvironmentScores.
type GoogleCloudApigeeV1ComputeEnvironmentScoresResponse struct {
	// NextPageToken: A page token, received from a previous `ComputeScore`
	// call. Provide this to retrieve the subsequent page.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// Scores: List of scores. One score per day.
	Scores []*GoogleCloudApigeeV1Score `json:"scores,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "NextPageToken") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ComputeEnvironmentScoresResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ComputeEnvironmentScoresResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ConfigVersion: Version of the API proxy
// configuration schema. Currently, only 4.0 is supported.
type GoogleCloudApigeeV1ConfigVersion struct {
	// MajorVersion: Major version of the API proxy configuration schema.
	MajorVersion int64 `json:"majorVersion,omitempty"`

	// MinorVersion: Minor version of the API proxy configuration schema.
	MinorVersion int64 `json:"minorVersion,omitempty"`

	// ForceSendFields is a list of field names (e.g. "MajorVersion") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "MajorVersion") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ConfigVersion) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ConfigVersion
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ConnectorsPlatformConfig: Configuration for the
// Connectors Platform add-on.
type GoogleCloudApigeeV1ConnectorsPlatformConfig struct {
	// Enabled: Flag that specifies whether the Connectors Platform add-on
	// is enabled.
	Enabled bool `json:"enabled,omitempty"`

	// ExpiresAt: Output only. Time at which the Connectors Platform add-on
	// expires in milliseconds since epoch. If unspecified, the add-on will
	// never expire.
	ExpiresAt int64 `json:"expiresAt,omitempty,string"`

	// ForceSendFields is a list of field names (e.g. "Enabled") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Enabled") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ConnectorsPlatformConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ConnectorsPlatformConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1Credential struct {
	// ApiProducts: List of API products this credential can be used for.
	ApiProducts []*GoogleCloudApigeeV1ApiProductRef `json:"apiProducts,omitempty"`

	// Attributes: List of attributes associated with this credential.
	Attributes []*GoogleCloudApigeeV1Attribute `json:"attributes,omitempty"`

	// ConsumerKey: Consumer key.
	ConsumerKey string `json:"consumerKey,omitempty"`

	// ConsumerSecret: Secret key.
	ConsumerSecret string `json:"consumerSecret,omitempty"`

	// ExpiresAt: Time the credential will expire in milliseconds since
	// epoch.
	ExpiresAt int64 `json:"expiresAt,omitempty,string"`

	// IssuedAt: Time the credential was issued in milliseconds since epoch.
	IssuedAt int64 `json:"issuedAt,omitempty,string"`

	// Scopes: List of scopes to apply to the app. Specified scopes must
	// already exist on the API product that you associate with the app.
	Scopes []string `json:"scopes,omitempty"`

	// Status: Status of the credential. Valid values include `approved` or
	// `revoked`.
	Status string `json:"status,omitempty"`

	// ForceSendFields is a list of field names (e.g. "ApiProducts") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ApiProducts") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Credential) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Credential
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1CreditDeveloperBalanceRequest: Request for
// CreditDeveloperBalance.
type GoogleCloudApigeeV1CreditDeveloperBalanceRequest struct {
	// TransactionAmount: The amount of money to be credited. The wallet
	// corresponding to the currency specified within `transaction_amount`
	// will be updated. For example, if you specified `currency_code` within
	// `transaction_amount` as "USD", then the amount would be added to the
	// wallet which has the "USD" currency or if no such wallet exists, a
	// new wallet will be created with the "USD" currency.
	TransactionAmount *GoogleTypeMoney `json:"transactionAmount,omitempty"`

	// TransactionId: Each transaction_id uniquely identifies a credit
	// balance request. If multiple requests are received with the same
	// transaction_id, only one of them will be considered.
	TransactionId string `json:"transactionId,omitempty"`

	// ForceSendFields is a list of field names (e.g. "TransactionAmount")
	// to unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "TransactionAmount") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1CreditDeveloperBalanceRequest) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1CreditDeveloperBalanceRequest
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1CustomReport struct {
	// ChartType: This field contains the chart type for the report
	ChartType string `json:"chartType,omitempty"`

	// Comments: Legacy field: not used. This field contains a list of
	// comments associated with custom report
	Comments []string `json:"comments,omitempty"`

	// CreatedAt: Output only. Unix time when the app was created json key:
	// createdAt
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// Dimensions: This contains the list of dimensions for the report
	Dimensions []string `json:"dimensions,omitempty"`

	// DisplayName: This is the display name for the report
	DisplayName string `json:"displayName,omitempty"`

	// Environment: Output only. Environment name
	Environment string `json:"environment,omitempty"`

	// Filter: This field contains the filter expression
	Filter string `json:"filter,omitempty"`

	// FromTime: Legacy field: not used. Contains the from time for the
	// report
	FromTime string `json:"fromTime,omitempty"`

	// LastModifiedAt: Output only. Modified time of this entity as
	// milliseconds since epoch. json key: lastModifiedAt
	LastModifiedAt int64 `json:"lastModifiedAt,omitempty,string"`

	// LastViewedAt: Output only. Last viewed time of this entity as
	// milliseconds since epoch
	LastViewedAt int64 `json:"lastViewedAt,omitempty,string"`

	// Limit: Legacy field: not used This field contains the limit for the
	// result retrieved
	Limit string `json:"limit,omitempty"`

	// Metrics: Required. This contains the list of metrics
	Metrics []*GoogleCloudApigeeV1CustomReportMetric `json:"metrics,omitempty"`

	// Name: Required. Unique identifier for the report T his is a legacy
	// field used to encode custom report unique id
	Name string `json:"name,omitempty"`

	// Offset: Legacy field: not used. This field contains the offset for
	// the data
	Offset string `json:"offset,omitempty"`

	// Organization: Output only. Organization name
	Organization string `json:"organization,omitempty"`

	// Properties: This field contains report properties such as ui metadata
	// etc.
	Properties []*GoogleCloudApigeeV1ReportProperty `json:"properties,omitempty"`

	// SortByCols: Legacy field: not used much. Contains the list of sort by
	// columns
	SortByCols []string `json:"sortByCols,omitempty"`

	// SortOrder: Legacy field: not used much. Contains the sort order for
	// the sort columns
	SortOrder string `json:"sortOrder,omitempty"`

	// Tags: Legacy field: not used. This field contains a list of tags
	// associated with custom report
	Tags []string `json:"tags,omitempty"`

	// TimeUnit: This field contains the time unit of aggregation for the
	// report
	TimeUnit string `json:"timeUnit,omitempty"`

	// ToTime: Legacy field: not used. Contains the end time for the report
	ToTime string `json:"toTime,omitempty"`

	// Topk: Legacy field: not used. This field contains the top k parameter
	// value for restricting the result
	Topk string `json:"topk,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ChartType") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ChartType") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1CustomReport) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1CustomReport
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1CustomReportMetric: This encapsulates a metric
// property of the form sum(message_count) where name is message_count
// and function is sum
type GoogleCloudApigeeV1CustomReportMetric struct {
	// Function: aggregate function
	Function string `json:"function,omitempty"`

	// Name: name of the metric
	Name string `json:"name,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Function") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Function") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1CustomReportMetric) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1CustomReportMetric
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DataCollector: Data collector configuration.
type GoogleCloudApigeeV1DataCollector struct {
	// CreatedAt: Output only. The time at which the data collector was
	// created in milliseconds since the epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// Description: A description of the data collector.
	Description string `json:"description,omitempty"`

	// LastModifiedAt: Output only. The time at which the Data Collector was
	// last updated in milliseconds since the epoch.
	LastModifiedAt int64 `json:"lastModifiedAt,omitempty,string"`

	// Name: ID of the data collector. Must begin with `dc_`.
	Name string `json:"name,omitempty"`

	// Type: Immutable. The type of data this data collector will collect.
	//
	// Possible values:
	//   "TYPE_UNSPECIFIED" - For future compatibility.
	//   "INTEGER" - For integer values.
	//   "FLOAT" - For float values.
	//   "STRING" - For string values.
	//   "BOOLEAN" - For boolean values.
	//   "DATETIME" - For datetime values.
	Type string `json:"type,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "CreatedAt") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "CreatedAt") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DataCollector) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DataCollector
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DataCollectorConfig: Data collector and its
// configuration.
type GoogleCloudApigeeV1DataCollectorConfig struct {
	// Name: Name of the data collector in the following format:
	// `organizations/{org}/datacollectors/{datacollector}`
	Name string `json:"name,omitempty"`

	// Type: Data type accepted by the data collector.
	//
	// Possible values:
	//   "TYPE_UNSPECIFIED" - For future compatibility.
	//   "INTEGER" - For integer values.
	//   "FLOAT" - For float values.
	//   "STRING" - For string values.
	//   "BOOLEAN" - For boolean values.
	//   "DATETIME" - For datetime values.
	Type string `json:"type,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Name") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Name") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DataCollectorConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DataCollectorConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1Datastore: The data store defines the connection
// to export data repository (Cloud Storage, BigQuery), including the
// credentials used to access the data repository.
type GoogleCloudApigeeV1Datastore struct {
	// CreateTime: Output only. Datastore create time, in milliseconds since
	// the epoch of 1970-01-01T00:00:00Z
	CreateTime int64 `json:"createTime,omitempty,string"`

	// DatastoreConfig: Datastore Configurations.
	DatastoreConfig *GoogleCloudApigeeV1DatastoreConfig `json:"datastoreConfig,omitempty"`

	// DisplayName: Required. Display name in UI
	DisplayName string `json:"displayName,omitempty"`

	// LastUpdateTime: Output only. Datastore last update time, in
	// milliseconds since the epoch of 1970-01-01T00:00:00Z
	LastUpdateTime int64 `json:"lastUpdateTime,omitempty,string"`

	// Org: Output only. Organization that the datastore belongs to
	Org string `json:"org,omitempty"`

	// Self: Output only. Resource link of Datastore. Example:
	// `/organizations/{org}/analytics/datastores/{uuid}`
	Self string `json:"self,omitempty"`

	// TargetType: Destination storage type. Supported types `gcs` or
	// `bigquery`.
	TargetType string `json:"targetType,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "CreateTime") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "CreateTime") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Datastore) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Datastore
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DatastoreConfig: Configuration detail for
// datastore
type GoogleCloudApigeeV1DatastoreConfig struct {
	// BucketName: Name of the Cloud Storage bucket. Required for `gcs`
	// target_type.
	BucketName string `json:"bucketName,omitempty"`

	// DatasetName: BigQuery dataset name Required for `bigquery`
	// target_type.
	DatasetName string `json:"datasetName,omitempty"`

	// Path: Path of Cloud Storage bucket Required for `gcs` target_type.
	Path string `json:"path,omitempty"`

	// ProjectId: Required. GCP project in which the datastore exists
	ProjectId string `json:"projectId,omitempty"`

	// TablePrefix: Prefix of BigQuery table Required for `bigquery`
	// target_type.
	TablePrefix string `json:"tablePrefix,omitempty"`

	// ForceSendFields is a list of field names (e.g. "BucketName") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "BucketName") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DatastoreConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DatastoreConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DateRange: Date range of the data to export.
type GoogleCloudApigeeV1DateRange struct {
	// End: Required. End date (exclusive) of the data to export in the
	// format `yyyy-mm-dd`. The date range ends at 00:00:00 UTC on the end
	// date- which will not be in the output.
	End string `json:"end,omitempty"`

	// Start: Required. Start date of the data to export in the format
	// `yyyy-mm-dd`. The date range begins at 00:00:00 UTC on the start
	// date.
	Start string `json:"start,omitempty"`

	// ForceSendFields is a list of field names (e.g. "End") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "End") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DateRange) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DateRange
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1DebugMask struct {
	// FaultJSONPaths: List of JSON paths that specify the JSON elements to
	// be filtered from JSON payloads in error flows.
	FaultJSONPaths []string `json:"faultJSONPaths,omitempty"`

	// FaultXPaths: List of XPaths that specify the XML elements to be
	// filtered from XML payloads in error flows.
	FaultXPaths []string `json:"faultXPaths,omitempty"`

	// Name: Name of the debug mask.
	Name string `json:"name,omitempty"`

	// Namespaces: Map of namespaces to URIs.
	Namespaces map[string]string `json:"namespaces,omitempty"`

	// RequestJSONPaths: List of JSON paths that specify the JSON elements
	// to be filtered from JSON request message payloads.
	RequestJSONPaths []string `json:"requestJSONPaths,omitempty"`

	// RequestXPaths: List of XPaths that specify the XML elements to be
	// filtered from XML request message payloads.
	RequestXPaths []string `json:"requestXPaths,omitempty"`

	// ResponseJSONPaths: List of JSON paths that specify the JSON elements
	// to be filtered from JSON response message payloads.
	ResponseJSONPaths []string `json:"responseJSONPaths,omitempty"`

	// ResponseXPaths: List of XPaths that specify the XML elements to be
	// filtered from XML response message payloads.
	ResponseXPaths []string `json:"responseXPaths,omitempty"`

	// Variables: List of variables that should be masked from the debug
	// output.
	Variables []string `json:"variables,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "FaultJSONPaths") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "FaultJSONPaths") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DebugMask) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DebugMask
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1DebugSession struct {
	// Count: Optional. The number of request to be traced. Min = 1, Max =
	// 15, Default = 10.
	Count int64 `json:"count,omitempty"`

	// CreateTime: Output only. The first transaction creation timestamp,
	// recorded by UAP.
	CreateTime string `json:"createTime,omitempty"`

	// Filter: Optional. A conditional statement which is evaluated against
	// the request message to determine if it should be traced. Syntax
	// matches that of on API Proxy bundle flow Condition.
	Filter string `json:"filter,omitempty"`

	// Name: A unique ID for this DebugSession.
	Name string `json:"name,omitempty"`

	// Timeout: Optional. The time in seconds after which this DebugSession
	// should end. This value will override the value in query param, if
	// both are provided.
	Timeout int64 `json:"timeout,omitempty,string"`

	// Tracesize: Optional. The maximum number of bytes captured from the
	// response payload. Min = 0, Max = 5120, Default = 5120.
	Tracesize int64 `json:"tracesize,omitempty"`

	// Validity: Optional. The length of time, in seconds, that this debug
	// session is valid, starting from when it's received in the control
	// plane. Min = 1, Max = 15, Default = 10.
	Validity int64 `json:"validity,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Count") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Count") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DebugSession) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DebugSession
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DebugSessionTransaction: A transaction contains
// all of the debug information of the entire message flow of an API
// call processed by the runtime plane. The information is collected and
// recorded at critical points of the message flow in the runtime
// apiproxy.
type GoogleCloudApigeeV1DebugSessionTransaction struct {
	// Completed: Flag indicating whether a transaction is completed or not
	Completed bool `json:"completed,omitempty"`

	// Point: List of debug data collected by runtime plane at various
	// defined points in the flow.
	Point []*GoogleCloudApigeeV1Point `json:"point,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Completed") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Completed") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DebugSessionTransaction) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DebugSessionTransaction
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1DeleteCustomReportResponse struct {
	// Message: The response contains only a message field.
	Message string `json:"message,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Message") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Message") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DeleteCustomReportResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DeleteCustomReportResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DeleteResponse: Response for certain delete
// operations.
type GoogleCloudApigeeV1DeleteResponse struct {
	// ErrorCode: Unique error code for the request, if any.
	ErrorCode string `json:"errorCode,omitempty"`

	// GcpResource: Google Cloud name of deleted resource.
	GcpResource string `json:"gcpResource,omitempty"`

	// Message: Description of the operation.
	Message string `json:"message,omitempty"`

	// RequestId: Unique ID of the request.
	RequestId string `json:"requestId,omitempty"`

	// Status: Status of the operation.
	Status string `json:"status,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ErrorCode") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ErrorCode") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DeleteResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DeleteResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1Deployment struct {
	// ApiProxy: API proxy.
	ApiProxy string `json:"apiProxy,omitempty"`

	// DeployStartTime: Time the API proxy was marked `deployed` in the
	// control plane in millisconds since epoch.
	DeployStartTime int64 `json:"deployStartTime,omitempty,string"`

	// Environment: Environment.
	Environment string `json:"environment,omitempty"`

	// Errors: Errors reported for this deployment. Populated only when
	// state == ERROR. **Note**: This field is displayed only when viewing
	// deployment status.
	Errors []*GoogleRpcStatus `json:"errors,omitempty"`

	// Instances: Status reported by each runtime instance. **Note**: This
	// field is displayed only when viewing deployment status.
	Instances []*GoogleCloudApigeeV1InstanceDeploymentStatus `json:"instances,omitempty"`

	// Pods: Status reported by runtime pods. **Note**: **This field is
	// deprecated**. Runtime versions 1.3 and above report instance level
	// status rather than pod status.
	Pods []*GoogleCloudApigeeV1PodStatus `json:"pods,omitempty"`

	// ProxyDeploymentType: Output only. The type of the deployment
	// (standard or extensible) Deployed proxy revision will be marked as
	// extensible in following 2 cases. 1. The deployed proxy revision uses
	// extensible policies. 2. If a environment supports flowhooks and flow
	// hook is configured.
	//
	// Possible values:
	//   "PROXY_DEPLOYMENT_TYPE_UNSPECIFIED" - Default value till public
	// preview. After public preview this value should not be returned.
	//   "STANDARD" - Deployment will be of type Standard if only Standard
	// proxies are used
	//   "EXTENSIBLE" - Proxy will be of type Extensible if deployments uses
	// one or more Extensible proxies
	ProxyDeploymentType string `json:"proxyDeploymentType,omitempty"`

	// Revision: API proxy revision.
	Revision string `json:"revision,omitempty"`

	// RouteConflicts: Conflicts in the desired state routing configuration.
	// The presence of conflicts does not cause the state to be `ERROR`, but
	// it will mean that some of the deployment's base paths are not routed
	// to its environment. If the conflicts change, the state will
	// transition to `PROGRESSING` until the latest configuration is rolled
	// out to all instances. **Note**: This field is displayed only when
	// viewing deployment status.
	RouteConflicts []*GoogleCloudApigeeV1DeploymentChangeReportRoutingConflict `json:"routeConflicts,omitempty"`

	// ServiceAccount: The full resource name of Cloud IAM Service Account
	// that this deployment is using, eg,
	// `projects/-/serviceAccounts/{email}`.
	ServiceAccount string `json:"serviceAccount,omitempty"`

	// State: Current state of the deployment. **Note**: This field is
	// displayed only when viewing deployment status.
	//
	// Possible values:
	//   "RUNTIME_STATE_UNSPECIFIED" - This value should never be returned.
	//   "READY" - Runtime has loaded the deployment.
	//   "PROGRESSING" - Deployment is not fully ready in the runtime.
	//   "ERROR" - Encountered an error with the deployment that requires
	// intervention.
	State string `json:"state,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ApiProxy") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ApiProxy") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Deployment) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Deployment
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DeploymentChangeReport: Response for
// GenerateDeployChangeReport and GenerateUndeployChangeReport. This
// report contains any validation failures that would cause the
// deployment to be rejected, as well changes and conflicts in routing
// that may occur due to the new deployment. The existence of a routing
// warning does not necessarily imply that the deployment request is
// bad, if the desired state of the deployment request is to effect a
// routing change. The primary purposes of the routing messages are: 1)
// To inform users of routing changes that may have an effect on traffic
// currently being routed to other existing deployments. 2) To warn
// users if some base path in the proxy will not receive traffic due to
// an existing deployment having already claimed that base path. The
// presence of routing conflicts/changes will not cause non-dry-run
// DeployApiProxy/UndeployApiProxy requests to be rejected.
type GoogleCloudApigeeV1DeploymentChangeReport struct {
	// RoutingChanges: All routing changes that may result from a deployment
	// request.
	RoutingChanges []*GoogleCloudApigeeV1DeploymentChangeReportRoutingChange `json:"routingChanges,omitempty"`

	// RoutingConflicts: All base path conflicts detected for a deployment
	// request.
	RoutingConflicts []*GoogleCloudApigeeV1DeploymentChangeReportRoutingConflict `json:"routingConflicts,omitempty"`

	// ValidationErrors: Validation errors that would cause the deployment
	// change request to be rejected.
	ValidationErrors *GoogleRpcPreconditionFailure `json:"validationErrors,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "RoutingChanges") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "RoutingChanges") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DeploymentChangeReport) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DeploymentChangeReport
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DeploymentChangeReportRoutingChange: Describes a
// potential routing change that may occur as a result of some
// deployment operation.
type GoogleCloudApigeeV1DeploymentChangeReportRoutingChange struct {
	// Description: Human-readable description of this routing change.
	Description string `json:"description,omitempty"`

	// EnvironmentGroup: Name of the environment group affected by this
	// routing change.
	EnvironmentGroup string `json:"environmentGroup,omitempty"`

	// FromDeployment: Base path/deployment that may stop receiving some
	// traffic.
	FromDeployment *GoogleCloudApigeeV1DeploymentChangeReportRoutingDeployment `json:"fromDeployment,omitempty"`

	// ShouldSequenceRollout: Set to `true` if using sequenced rollout would
	// make this routing change safer. **Note**: This does not necessarily
	// imply that automated sequenced rollout mode is supported for the
	// operation.
	ShouldSequenceRollout bool `json:"shouldSequenceRollout,omitempty"`

	// ToDeployment: Base path/deployment that may start receiving that
	// traffic. May be null if no deployment is able to receive the traffic.
	ToDeployment *GoogleCloudApigeeV1DeploymentChangeReportRoutingDeployment `json:"toDeployment,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Description") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Description") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DeploymentChangeReportRoutingChange) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DeploymentChangeReportRoutingChange
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DeploymentChangeReportRoutingConflict: Describes a
// routing conflict that may cause a deployment not to receive traffic
// at some base path.
type GoogleCloudApigeeV1DeploymentChangeReportRoutingConflict struct {
	// ConflictingDeployment: Existing base path/deployment causing the
	// conflict.
	ConflictingDeployment *GoogleCloudApigeeV1DeploymentChangeReportRoutingDeployment `json:"conflictingDeployment,omitempty"`

	// Description: Human-readable description of this conflict.
	Description string `json:"description,omitempty"`

	// EnvironmentGroup: Name of the environment group in which this
	// conflict exists.
	EnvironmentGroup string `json:"environmentGroup,omitempty"`

	// ForceSendFields is a list of field names (e.g.
	// "ConflictingDeployment") to unconditionally include in API requests.
	// By default, fields with empty or default values are omitted from API
	// requests. However, any non-pointer, non-interface field appearing in
	// ForceSendFields will be sent to the server regardless of whether the
	// field is empty or not. This may be used to include empty fields in
	// Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ConflictingDeployment") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DeploymentChangeReportRoutingConflict) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DeploymentChangeReportRoutingConflict
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DeploymentChangeReportRoutingDeployment: Tuple
// representing a base path and the deployment containing it.
type GoogleCloudApigeeV1DeploymentChangeReportRoutingDeployment struct {
	// ApiProxy: Name of the deployed API proxy revision containing the base
	// path.
	ApiProxy string `json:"apiProxy,omitempty"`

	// Basepath: Base path receiving traffic.
	Basepath string `json:"basepath,omitempty"`

	// Environment: Name of the environment in which the proxy is deployed.
	Environment string `json:"environment,omitempty"`

	// Revision: Name of the deployed API proxy revision containing the base
	// path.
	Revision string `json:"revision,omitempty"`

	// ForceSendFields is a list of field names (e.g. "ApiProxy") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ApiProxy") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DeploymentChangeReportRoutingDeployment) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DeploymentChangeReportRoutingDeployment
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DeploymentConfig: NEXT ID: 11
type GoogleCloudApigeeV1DeploymentConfig struct {
	// Attributes: Additional key-value metadata for the deployment.
	Attributes map[string]string `json:"attributes,omitempty"`

	// BasePath: Base path where the application will be hosted. Defaults to
	// "/".
	BasePath string `json:"basePath,omitempty"`

	// DeploymentGroups: The list of deployment groups in which this proxy
	// should be deployed. Not currently populated for shared flows.
	DeploymentGroups []string `json:"deploymentGroups,omitempty"`

	// Endpoints: A mapping from basepaths to proxy endpoint names in this
	// proxy. Not populated for shared flows.
	Endpoints map[string]string `json:"endpoints,omitempty"`

	// Location: Location of the API proxy bundle as a URI.
	Location string `json:"location,omitempty"`

	// Name: Name of the API or shared flow revision to be deployed in the
	// following format: `organizations/{org}/apis/{api}/revisions/{rev}` or
	// `organizations/{org}/sharedflows/{sharedflow}/revisions/{rev}`
	Name string `json:"name,omitempty"`

	// ProxyUid: Unique ID of the API proxy revision.
	ProxyUid string `json:"proxyUid,omitempty"`

	// ServiceAccount: The service account identity associated with this
	// deployment. If non-empty, will be in the following format:
	// `projects/-/serviceAccounts/{account_email}`
	ServiceAccount string `json:"serviceAccount,omitempty"`

	// Uid: Unique ID. The ID will only change if the deployment is deleted
	// and recreated.
	Uid string `json:"uid,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Attributes") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Attributes") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DeploymentConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DeploymentConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DeploymentGroupConfig: DeploymentGroupConfig
// represents a deployment group that should be present in a particular
// environment.
type GoogleCloudApigeeV1DeploymentGroupConfig struct {
	// DeploymentGroupType: Type of the deployment group, which will be
	// either Standard or Extensible.
	//
	// Possible values:
	//   "DEPLOYMENT_GROUP_TYPE_UNSPECIFIED" - Unspecified type
	//   "STANDARD" - Standard type
	//   "EXTENSIBLE" - Extensible Type
	DeploymentGroupType string `json:"deploymentGroupType,omitempty"`

	// Name: Name of the deployment group in the following format:
	// `organizations/{org}/environments/{env}/deploymentGroups/{group}`.
	Name string `json:"name,omitempty"`

	// RevisionId: Revision number which can be used by the runtime to
	// detect if the deployment group has changed between two versions.
	RevisionId int64 `json:"revisionId,omitempty,string"`

	// Uid: Unique ID. The ID will only change if the deployment group is
	// deleted and recreated.
	Uid string `json:"uid,omitempty"`

	// ForceSendFields is a list of field names (e.g. "DeploymentGroupType")
	// to unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "DeploymentGroupType") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DeploymentGroupConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DeploymentGroupConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1Developer struct {
	// AccessType: Access type.
	AccessType string `json:"accessType,omitempty"`

	// AppFamily: Developer app family.
	AppFamily string `json:"appFamily,omitempty"`

	// Apps: List of apps associated with the developer.
	Apps []string `json:"apps,omitempty"`

	// Attributes: Optional. Developer attributes (name/value pairs). The
	// custom attribute limit is 18.
	Attributes []*GoogleCloudApigeeV1Attribute `json:"attributes,omitempty"`

	// Companies: List of companies associated with the developer.
	Companies []string `json:"companies,omitempty"`

	// CreatedAt: Output only. Time at which the developer was created in
	// milliseconds since epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// DeveloperId: ID of the developer. **Note**: IDs are generated
	// internally by Apigee and are not guaranteed to stay the same over
	// time.
	DeveloperId string `json:"developerId,omitempty"`

	// Email: Required. Email address of the developer. This value is used
	// to uniquely identify the developer in Apigee hybrid. Note that the
	// email address has to be in lowercase only.
	Email string `json:"email,omitempty"`

	// FirstName: Required. First name of the developer.
	FirstName string `json:"firstName,omitempty"`

	// LastModifiedAt: Output only. Time at which the developer was last
	// modified in milliseconds since epoch.
	LastModifiedAt int64 `json:"lastModifiedAt,omitempty,string"`

	// LastName: Required. Last name of the developer.
	LastName string `json:"lastName,omitempty"`

	// OrganizationName: Output only. Name of the Apigee organization in
	// which the developer resides.
	OrganizationName string `json:"organizationName,omitempty"`

	// Status: Output only. Status of the developer. Valid values are
	// `active` and `inactive`.
	Status string `json:"status,omitempty"`

	// UserName: Required. User name of the developer. Not used by Apigee
	// hybrid.
	UserName string `json:"userName,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "AccessType") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AccessType") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Developer) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Developer
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1DeveloperApp struct {
	// ApiProducts: List of API products associated with the developer app.
	ApiProducts []string `json:"apiProducts,omitempty"`

	// AppFamily: Developer app family.
	AppFamily string `json:"appFamily,omitempty"`

	// AppId: ID of the developer app.
	AppId string `json:"appId,omitempty"`

	// Attributes: List of attributes for the developer app.
	Attributes []*GoogleCloudApigeeV1Attribute `json:"attributes,omitempty"`

	// CallbackUrl: Callback URL used by OAuth 2.0 authorization servers to
	// communicate authorization codes back to developer apps.
	CallbackUrl string `json:"callbackUrl,omitempty"`

	// CreatedAt: Output only. Time the developer app was created in
	// milliseconds since epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// Credentials: Output only. Set of credentials for the developer app
	// consisting of the consumer key/secret pairs associated with the API
	// products.
	Credentials []*GoogleCloudApigeeV1Credential `json:"credentials,omitempty"`

	// DeveloperId: ID of the developer.
	DeveloperId string `json:"developerId,omitempty"`

	// KeyExpiresIn: Expiration time, in milliseconds, for the consumer key
	// that is generated for the developer app. If not set or left to the
	// default value of `-1`, the API key never expires. The expiration time
	// can't be updated after it is set.
	KeyExpiresIn int64 `json:"keyExpiresIn,omitempty,string"`

	// LastModifiedAt: Output only. Time the developer app was modified in
	// milliseconds since epoch.
	LastModifiedAt int64 `json:"lastModifiedAt,omitempty,string"`

	// Name: Name of the developer app.
	Name string `json:"name,omitempty"`

	// Scopes: Scopes to apply to the developer app. The specified scopes
	// must already exist for the API product that you associate with the
	// developer app.
	Scopes []string `json:"scopes,omitempty"`

	// Status: Status of the credential. Valid values include `approved` or
	// `revoked`.
	Status string `json:"status,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ApiProducts") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ApiProducts") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DeveloperApp) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DeveloperApp
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1DeveloperAppKey struct {
	// ApiProducts: List of API products for which the credential can be
	// used. **Note**: Do not specify the list of API products when creating
	// a consumer key and secret for a developer app. Instead, use the
	// UpdateDeveloperAppKey API to make the association after the consumer
	// key and secret are created.
	ApiProducts []interface{} `json:"apiProducts,omitempty"`

	// Attributes: List of attributes associated with the credential.
	Attributes []*GoogleCloudApigeeV1Attribute `json:"attributes,omitempty"`

	// ConsumerKey: Consumer key.
	ConsumerKey string `json:"consumerKey,omitempty"`

	// ConsumerSecret: Secret key.
	ConsumerSecret string `json:"consumerSecret,omitempty"`

	// ExpiresAt: Time the developer app expires in milliseconds since
	// epoch.
	ExpiresAt int64 `json:"expiresAt,omitempty,string"`

	// ExpiresInSeconds: Input only. Expiration time, in seconds, for the
	// consumer key. If not set or left to the default value of `-1`, the
	// API key never expires. The expiration time can't be updated after it
	// is set.
	ExpiresInSeconds int64 `json:"expiresInSeconds,omitempty,string"`

	// IssuedAt: Time the developer app was created in milliseconds since
	// epoch.
	IssuedAt int64 `json:"issuedAt,omitempty,string"`

	// Scopes: Scopes to apply to the app. The specified scope names must
	// already be defined for the API product that you associate with the
	// app.
	Scopes []string `json:"scopes,omitempty"`

	// Status: Status of the credential. Valid values include `approved` or
	// `revoked`.
	Status string `json:"status,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ApiProducts") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ApiProducts") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DeveloperAppKey) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DeveloperAppKey
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DeveloperBalance: Account balance for the
// developer.
type GoogleCloudApigeeV1DeveloperBalance struct {
	// Wallets: Output only. List of all wallets. Each individual wallet
	// stores the account balance for a particular currency.
	Wallets []*GoogleCloudApigeeV1DeveloperBalanceWallet `json:"wallets,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Wallets") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Wallets") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DeveloperBalance) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DeveloperBalance
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DeveloperBalanceWallet: Wallet used to manage an
// account balance for a particular currency.
type GoogleCloudApigeeV1DeveloperBalanceWallet struct {
	// Balance: Current remaining balance of the developer for a particular
	// currency.
	Balance *GoogleTypeMoney `json:"balance,omitempty"`

	// LastCreditTime: Output only. Time at which the developer last added
	// credit to the account in milliseconds since epoch.
	LastCreditTime int64 `json:"lastCreditTime,omitempty,string"`

	// ForceSendFields is a list of field names (e.g. "Balance") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Balance") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DeveloperBalanceWallet) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DeveloperBalanceWallet
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DeveloperMonetizationConfig: Monetization
// configuration for the developer.
type GoogleCloudApigeeV1DeveloperMonetizationConfig struct {
	// BillingType: Billing type.
	//
	// Possible values:
	//   "BILLING_TYPE_UNSPECIFIED" - The default/unset value.
	//   "PREPAID" - Developer pays in advance for the use of APIs and the
	// charged amount is deducted from their account balance.
	//   "POSTPAID" - Developer does not maintain an account balance. The
	// API provider bills the developer for API usage.
	BillingType string `json:"billingType,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "BillingType") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "BillingType") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DeveloperMonetizationConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DeveloperMonetizationConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DeveloperSubscription: Structure of a
// DeveloperSubscription.
type GoogleCloudApigeeV1DeveloperSubscription struct {
	// Apiproduct: Name of the API product for which the developer is
	// purchasing a subscription.
	Apiproduct string `json:"apiproduct,omitempty"`

	// CreatedAt: Output only. Time when the API product subscription was
	// created in milliseconds since epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// EndTime: Time when the API product subscription ends in milliseconds
	// since epoch.
	EndTime int64 `json:"endTime,omitempty,string"`

	// LastModifiedAt: Output only. Time when the API product subscription
	// was last modified in milliseconds since epoch.
	LastModifiedAt int64 `json:"lastModifiedAt,omitempty,string"`

	// Name: Output only. Name of the API product subscription.
	Name string `json:"name,omitempty"`

	// StartTime: Time when the API product subscription starts in
	// milliseconds since epoch.
	StartTime int64 `json:"startTime,omitempty,string"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Apiproduct") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Apiproduct") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DeveloperSubscription) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DeveloperSubscription
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DimensionMetric: Encapsulates a metric grouped by
// dimension.
type GoogleCloudApigeeV1DimensionMetric struct {
	// IndividualNames: Individual dimension names. E.g. ["dim1_name",
	// "dim2_name"].
	IndividualNames []string `json:"individualNames,omitempty"`

	// Metrics: List of metrics.
	Metrics []*GoogleCloudApigeeV1Metric `json:"metrics,omitempty"`

	// Name: Comma joined dimension names. E.g. "dim1_name,dim2_name".
	// Deprecated. If name already has comma before join, we may get wrong
	// splits. Please use individual_names.
	Name string `json:"name,omitempty"`

	// ForceSendFields is a list of field names (e.g. "IndividualNames") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "IndividualNames") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DimensionMetric) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DimensionMetric
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1DisableSecurityActionRequest: Message to disable
// an enabled SecurityAction.
type GoogleCloudApigeeV1DisableSecurityActionRequest struct {
}

// GoogleCloudApigeeV1DocumentationFile: Documentation file contents for
// a catalog item.
type GoogleCloudApigeeV1DocumentationFile struct {
	// Contents: Required. The file contents. The max size is 4 MB.
	Contents string `json:"contents,omitempty"`

	// DisplayName: Required. A display name for the file, shown in the
	// management UI. Max length is 255 characters.
	DisplayName string `json:"displayName,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Contents") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Contents") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1DocumentationFile) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1DocumentationFile
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1EnableSecurityActionRequest: Message to enable a
// disabled SecurityAction.
type GoogleCloudApigeeV1EnableSecurityActionRequest struct {
}

// GoogleCloudApigeeV1EndpointAttachment: Apigee endpoint attachment.
// For more information, see [Southbound networking patterns]
// (https://cloud.google.com/apigee/docs/api-platform/architecture/southbound-networking-patterns-endpoints).
type GoogleCloudApigeeV1EndpointAttachment struct {
	// ConnectionState: Output only. State of the endpoint attachment
	// connection to the service attachment.
	//
	// Possible values:
	//   "CONNECTION_STATE_UNSPECIFIED" - The connection state has not been
	// set.
	//   "UNAVAILABLE" - The connection state is unavailable at this time,
	// possibly because the endpoint attachment is currently being
	// provisioned.
	//   "PENDING" - The connection is pending acceptance by the PSC
	// producer.
	//   "ACCEPTED" - The connection has been accepted by the PSC producer.
	//   "REJECTED" - The connection has been rejected by the PSC producer.
	//   "CLOSED" - The connection has been closed by the PSC producer and
	// will not serve traffic going forward.
	//   "FROZEN" - The connection has been frozen by the PSC producer and
	// will not serve traffic.
	//   "NEEDS_ATTENTION" - The connection has been accepted by the PSC
	// producer, but it is not ready to serve the traffic due to producer
	// side issues.
	ConnectionState string `json:"connectionState,omitempty"`

	// Host: Output only. Host that can be used in either the HTTP target
	// endpoint directly or as the host in target server.
	Host string `json:"host,omitempty"`

	// Location: Required. Location of the endpoint attachment.
	Location string `json:"location,omitempty"`

	// Name: Name of the endpoint attachment. Use the following structure in
	// your request:
	// `organizations/{org}/endpointAttachments/{endpoint_attachment}`
	Name string `json:"name,omitempty"`

	// ServiceAttachment: Format: projects/*/regions/*/serviceAttachments/*
	ServiceAttachment string `json:"serviceAttachment,omitempty"`

	// State: Output only. State of the endpoint attachment. Values other
	// than `ACTIVE` mean the resource is not ready to use.
	//
	// Possible values:
	//   "STATE_UNSPECIFIED" - Resource is in an unspecified state.
	//   "CREATING" - Resource is being created.
	//   "ACTIVE" - Resource is provisioned and ready to use.
	//   "DELETING" - The resource is being deleted.
	//   "UPDATING" - The resource is being updated.
	State string `json:"state,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ConnectionState") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ConnectionState") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1EndpointAttachment) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1EndpointAttachment
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1EndpointChainingRule: EndpointChainingRule
// specifies the proxies contained in a particular deployment group, so
// that other deployment groups can find them in chaining calls.
type GoogleCloudApigeeV1EndpointChainingRule struct {
	// DeploymentGroup: The deployment group to target for cross-shard
	// chaining calls to these proxies.
	DeploymentGroup string `json:"deploymentGroup,omitempty"`

	// ProxyIds: List of proxy ids which may be found in the given
	// deployment group.
	ProxyIds []string `json:"proxyIds,omitempty"`

	// ForceSendFields is a list of field names (e.g. "DeploymentGroup") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "DeploymentGroup") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1EndpointChainingRule) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1EndpointChainingRule
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1EntityMetadata: Metadata common to many entities
// in this API.
type GoogleCloudApigeeV1EntityMetadata struct {
	// CreatedAt: Time at which the API proxy was created, in milliseconds
	// since epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// LastModifiedAt: Time at which the API proxy was most recently
	// modified, in milliseconds since epoch.
	LastModifiedAt int64 `json:"lastModifiedAt,omitempty,string"`

	// SubType: The type of entity described
	SubType string `json:"subType,omitempty"`

	// ForceSendFields is a list of field names (e.g. "CreatedAt") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "CreatedAt") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1EntityMetadata) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1EntityMetadata
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1Environment struct {
	// ApiProxyType: Optional. API Proxy type supported by the environment.
	// The type can be set when creating the Environment and cannot be
	// changed.
	//
	// Possible values:
	//   "API_PROXY_TYPE_UNSPECIFIED" - API proxy type not specified.
	//   "PROGRAMMABLE" - Programmable API Proxies enable you to develop
	// APIs with highly flexible behavior using bundled policy configuration
	// and one or more programming languages to describe complex sequential
	// and/or conditional flows of logic.
	//   "CONFIGURABLE" - Configurable API Proxies enable you to develop
	// efficient APIs using simple configuration while complex execution
	// control flow logic is handled by Apigee. This type only works with
	// the ARCHIVE deployment type and cannot be combined with the PROXY
	// deployment type.
	ApiProxyType string `json:"apiProxyType,omitempty"`

	// CreatedAt: Output only. Creation time of this environment as
	// milliseconds since epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// DeploymentType: Optional. Deployment type supported by the
	// environment. The deployment type can be set when creating the
	// environment and cannot be changed. When you enable archive
	// deployment, you will be **prevented from performing** a subset of
	// actions
	// (/apigee/docs/api-platform/local-development/overview#prevented-action
	// s) within the environment, including: * Managing the deployment of
	// API proxy or shared flow revisions * Creating, updating, or deleting
	// resource files * Creating, updating, or deleting target servers
	//
	// Possible values:
	//   "DEPLOYMENT_TYPE_UNSPECIFIED" - Deployment type not specified.
	//   "PROXY" - Proxy deployment enables you to develop and deploy API
	// proxies using Apigee on Google Cloud. This cannot currently be
	// combined with the CONFIGURABLE API proxy type.
	//   "ARCHIVE" - Archive deployment enables you to develop API proxies
	// locally then deploy an archive of your API proxy configuration to an
	// environment in Apigee on Google Cloud. You will be prevented from
	// performing a [subset of
	// actions](/apigee/docs/api-platform/local-development/overview#prevente
	// d-actions) within the environment.
	DeploymentType string `json:"deploymentType,omitempty"`

	// Description: Optional. Description of the environment.
	Description string `json:"description,omitempty"`

	// DisplayName: Optional. Display name for this environment.
	DisplayName string `json:"displayName,omitempty"`

	// ForwardProxyUri: Optional. URI of the forward proxy to be applied to
	// the runtime instances in this environment. Must be in the format of
	// {scheme}://{hostname}:{port}. Note that the scheme must be one of
	// "http" or "https", and the port must be supplied. To remove a forward
	// proxy setting, update the field to an empty value. Note: At this
	// time, PUT operations to add forwardProxyUri to an existing
	// environment fail if the environment has nodeConfig set up. To
	// successfully add the forwardProxyUri setting in this case, include
	// the NodeConfig details with the request.
	ForwardProxyUri string `json:"forwardProxyUri,omitempty"`

	HasAttachedFlowHooks bool `json:"hasAttachedFlowHooks,omitempty"`

	// LastModifiedAt: Output only. Last modification time of this
	// environment as milliseconds since epoch.
	LastModifiedAt int64 `json:"lastModifiedAt,omitempty,string"`

	// Name: Required. Name of the environment. Values must match the
	// regular expression `^[.\\p{Alnum}-_]{1,255}$`
	Name string `json:"name,omitempty"`

	// NodeConfig: Optional. NodeConfig of the environment.
	NodeConfig *GoogleCloudApigeeV1NodeConfig `json:"nodeConfig,omitempty"`

	// Properties: Optional. Key-value pairs that may be used for
	// customizing the environment.
	Properties *GoogleCloudApigeeV1Properties `json:"properties,omitempty"`

	// State: Output only. State of the environment. Values other than
	// ACTIVE means the resource is not ready to use.
	//
	// Possible values:
	//   "STATE_UNSPECIFIED" - Resource is in an unspecified state.
	//   "CREATING" - Resource is being created.
	//   "ACTIVE" - Resource is provisioned and ready to use.
	//   "DELETING" - The resource is being deleted.
	//   "UPDATING" - The resource is being updated.
	State string `json:"state,omitempty"`

	// Type: Optional. EnvironmentType selected for the environment.
	//
	// Possible values:
	//   "ENVIRONMENT_TYPE_UNSPECIFIED" - Environment type not specified.
	//   "BASE" - This is the default type. Base environment has limited
	// capacity and capabilities and are usually used when you are getting
	// started with Apigee or while experimenting. Refer to Apigee's public
	// documentation for more details.
	//   "INTERMEDIATE" - Intermediate environment supports API management
	// features and higher capacity than Base environment. Refer to Apigee's
	// public documentation for more details.
	//   "COMPREHENSIVE" - Comprehensive environment supports advanced
	// capabilites and even higher capacity than Intermediate environment.
	// Refer to Apigee's public documentation for more details.
	Type string `json:"type,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ApiProxyType") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ApiProxyType") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Environment) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Environment
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1EnvironmentConfig struct {
	// AddonsConfig: The latest runtime configurations for add-ons.
	AddonsConfig *GoogleCloudApigeeV1RuntimeAddonsConfig `json:"addonsConfig,omitempty"`

	// ArcConfigLocation: The location for the config blob of API Runtime
	// Control, aka Envoy Adapter, for op-based authentication as a URI,
	// e.g. a Cloud Storage URI. This is only used by Envoy-based gateways.
	ArcConfigLocation string `json:"arcConfigLocation,omitempty"`

	// CreateTime: Time that the environment configuration was created.
	CreateTime string `json:"createTime,omitempty"`

	// DataCollectors: List of data collectors used by the deployments in
	// the environment.
	DataCollectors []*GoogleCloudApigeeV1DataCollectorConfig `json:"dataCollectors,omitempty"`

	// DebugMask: Debug mask that applies to all deployments in the
	// environment.
	DebugMask *GoogleCloudApigeeV1DebugMask `json:"debugMask,omitempty"`

	// DeploymentGroups: List of deployment groups in the environment.
	DeploymentGroups []*GoogleCloudApigeeV1DeploymentGroupConfig `json:"deploymentGroups,omitempty"`

	// Deployments: List of deployments in the environment.
	Deployments []*GoogleCloudApigeeV1DeploymentConfig `json:"deployments,omitempty"`

	// EnvScopedRevisionId: Revision ID for environment-scoped resources
	// (e.g. target servers, keystores) in this config. This ID will
	// increment any time a resource not scoped to a deployment group
	// changes.
	EnvScopedRevisionId int64 `json:"envScopedRevisionId,omitempty,string"`

	// FeatureFlags: Feature flags inherited from the organization and
	// environment.
	FeatureFlags map[string]string `json:"featureFlags,omitempty"`

	// Flowhooks: List of flow hooks in the environment.
	Flowhooks []*GoogleCloudApigeeV1FlowHookConfig `json:"flowhooks,omitempty"`

	// ForwardProxyUri: The forward proxy's url to be used by the runtime.
	// When set, runtime will send requests to the target via the given
	// forward proxy. This is only used by programmable gateways.
	ForwardProxyUri string `json:"forwardProxyUri,omitempty"`

	// GatewayConfigLocation: The location for the gateway config blob as a
	// URI, e.g. a Cloud Storage URI. This is only used by Envoy-based
	// gateways.
	GatewayConfigLocation string `json:"gatewayConfigLocation,omitempty"`

	// Keystores: List of keystores in the environment.
	Keystores []*GoogleCloudApigeeV1KeystoreConfig `json:"keystores,omitempty"`

	// Name: Name of the environment configuration in the following format:
	// `organizations/{org}/environments/{env}/configs/{config}`
	Name string `json:"name,omitempty"`

	// Provider: Used by the Control plane to add context information to
	// help detect the source of the document during diagnostics and
	// debugging.
	Provider string `json:"provider,omitempty"`

	// PubsubTopic: Name of the PubSub topic for the environment.
	PubsubTopic string `json:"pubsubTopic,omitempty"`

	// ResourceReferences: List of resource references in the environment.
	ResourceReferences []*GoogleCloudApigeeV1ReferenceConfig `json:"resourceReferences,omitempty"`

	// Resources: List of resource versions in the environment.
	Resources []*GoogleCloudApigeeV1ResourceConfig `json:"resources,omitempty"`

	// RevisionId: Revision ID of the environment configuration. The higher
	// the value, the more recently the configuration was deployed.
	RevisionId int64 `json:"revisionId,omitempty,string"`

	// SequenceNumber: DEPRECATED: Use revision_id.
	SequenceNumber int64 `json:"sequenceNumber,omitempty,string"`

	// Targets: List of target servers in the environment. Disabled target
	// servers are not displayed.
	Targets []*GoogleCloudApigeeV1TargetServerConfig `json:"targets,omitempty"`

	// TraceConfig: Trace configurations. Contains config for the
	// environment and config overrides for specific API proxies.
	TraceConfig *GoogleCloudApigeeV1RuntimeTraceConfig `json:"traceConfig,omitempty"`

	// Uid: Unique ID for the environment configuration. The ID will only
	// change if the environment is deleted and recreated.
	Uid string `json:"uid,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "AddonsConfig") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AddonsConfig") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1EnvironmentConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1EnvironmentConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1EnvironmentGroup: EnvironmentGroup configuration.
// An environment group is used to group one or more Apigee environments
// under a single host name.
type GoogleCloudApigeeV1EnvironmentGroup struct {
	// CreatedAt: Output only. The time at which the environment group was
	// created as milliseconds since epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// Hostnames: Required. Host names for this environment group.
	Hostnames []string `json:"hostnames,omitempty"`

	// LastModifiedAt: Output only. The time at which the environment group
	// was last updated as milliseconds since epoch.
	LastModifiedAt int64 `json:"lastModifiedAt,omitempty,string"`

	// Name: ID of the environment group.
	Name string `json:"name,omitempty"`

	// State: Output only. State of the environment group. Values other than
	// ACTIVE means the resource is not ready to use.
	//
	// Possible values:
	//   "STATE_UNSPECIFIED" - Resource is in an unspecified state.
	//   "CREATING" - Resource is being created.
	//   "ACTIVE" - Resource is provisioned and ready to use.
	//   "DELETING" - The resource is being deleted.
	//   "UPDATING" - The resource is being updated.
	State string `json:"state,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "CreatedAt") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "CreatedAt") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1EnvironmentGroup) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1EnvironmentGroup
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1EnvironmentGroupAttachment:
// EnvironmentGroupAttachment is a resource which defines an attachment
// of an environment to an environment group.
type GoogleCloudApigeeV1EnvironmentGroupAttachment struct {
	// CreatedAt: Output only. The time at which the environment group
	// attachment was created as milliseconds since epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// Environment: Required. ID of the attached environment.
	Environment string `json:"environment,omitempty"`

	// EnvironmentGroupId: Output only. ID of the environment group.
	EnvironmentGroupId string `json:"environmentGroupId,omitempty"`

	// Name: ID of the environment group attachment.
	Name string `json:"name,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "CreatedAt") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "CreatedAt") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1EnvironmentGroupAttachment) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1EnvironmentGroupAttachment
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1EnvironmentGroupConfig: EnvironmentGroupConfig is
// a revisioned snapshot of an EnvironmentGroup and its associated
// routing rules.
type GoogleCloudApigeeV1EnvironmentGroupConfig struct {
	// EndpointChainingRules: A list of proxies in each deployment group for
	// proxy chaining calls.
	EndpointChainingRules []*GoogleCloudApigeeV1EndpointChainingRule `json:"endpointChainingRules,omitempty"`

	// Hostnames: Host names for the environment group.
	Hostnames []string `json:"hostnames,omitempty"`

	// Location: When this message appears in the top-level IngressConfig,
	// this field will be populated in lieu of the inlined routing_rules and
	// hostnames fields. Some URL for downloading the full
	// EnvironmentGroupConfig for this group.
	Location string `json:"location,omitempty"`

	// Name: Name of the environment group in the following format:
	// `organizations/{org}/envgroups/{envgroup}`.
	Name string `json:"name,omitempty"`

	// RevisionId: Revision id that defines the ordering of the
	// EnvironmentGroupConfig resource. The higher the revision, the more
	// recently the configuration was deployed.
	RevisionId int64 `json:"revisionId,omitempty,string"`

	// RoutingRules: Ordered list of routing rules defining how traffic to
	// this environment group's hostnames should be routed to different
	// environments.
	RoutingRules []*GoogleCloudApigeeV1RoutingRule `json:"routingRules,omitempty"`

	// Uid: A unique id for the environment group config that will only
	// change if the environment group is deleted and recreated.
	Uid string `json:"uid,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g.
	// "EndpointChainingRules") to unconditionally include in API requests.
	// By default, fields with empty or default values are omitted from API
	// requests. However, any non-pointer, non-interface field appearing in
	// ForceSendFields will be sent to the server regardless of whether the
	// field is empty or not. This may be used to include empty fields in
	// Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "EndpointChainingRules") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1EnvironmentGroupConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1EnvironmentGroupConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ExpireDeveloperSubscriptionRequest: Request for
// ExpireDeveloperSubscription.
type GoogleCloudApigeeV1ExpireDeveloperSubscriptionRequest struct {
}

// GoogleCloudApigeeV1Export: Details of an export job.
type GoogleCloudApigeeV1Export struct {
	// Created: Output only. Time the export job was created.
	Created string `json:"created,omitempty"`

	// DatastoreName: Name of the datastore that is the destination of the
	// export job [datastore]
	DatastoreName string `json:"datastoreName,omitempty"`

	// Description: Description of the export job.
	Description string `json:"description,omitempty"`

	// Error: Output only. Error is set when export fails
	Error string `json:"error,omitempty"`

	// ExecutionTime: Output only. Execution time for this export job. If
	// the job is still in progress, it will be set to the amount of time
	// that has elapsed since`created`, in seconds. Else, it will set to
	// (`updated` - `created`), in seconds.
	ExecutionTime string `json:"executionTime,omitempty"`

	// Name: Display name of the export job.
	Name string `json:"name,omitempty"`

	// Self: Output only. Self link of the export job. A URI that can be
	// used to retrieve the status of an export job. Example:
	// `/organizations/myorg/environments/myenv/analytics/exports/9cfc0d85-0f
	// 30-46d6-ae6f-318d0cb961bd`
	Self string `json:"self,omitempty"`

	// State: Output only. Status of the export job. Valid values include
	// `enqueued`, `running`, `completed`, and `failed`.
	State string `json:"state,omitempty"`

	// Updated: Output only. Time the export job was last updated.
	Updated string `json:"updated,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Created") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Created") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Export) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Export
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ExportRequest: Request body for
// [CreateExportRequest]
type GoogleCloudApigeeV1ExportRequest struct {
	// CsvDelimiter: Optional. Delimiter used in the CSV file, if
	// `outputFormat` is set to `csv`. Defaults to the `,` (comma)
	// character. Supported delimiter characters include comma (`,`), pipe
	// (`|`), and tab (`\t`).
	CsvDelimiter string `json:"csvDelimiter,omitempty"`

	// DatastoreName: Required. Name of the preconfigured datastore.
	DatastoreName string `json:"datastoreName,omitempty"`

	// DateRange: Required. Date range of the data to export.
	DateRange *GoogleCloudApigeeV1DateRange `json:"dateRange,omitempty"`

	// Description: Optional. Description of the export job.
	Description string `json:"description,omitempty"`

	// Name: Required. Display name of the export job.
	Name string `json:"name,omitempty"`

	// OutputFormat: Optional. Output format of the export. Valid values
	// include: `csv` or `json`. Defaults to `json`. Note: Configure the
	// delimiter for CSV output using the `csvDelimiter` property.
	OutputFormat string `json:"outputFormat,omitempty"`

	// ForceSendFields is a list of field names (e.g. "CsvDelimiter") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "CsvDelimiter") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ExportRequest) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ExportRequest
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1FlowHook struct {
	// ContinueOnError: Optional. Flag that specifies whether execution
	// should continue if the flow hook throws an exception. Set to `true`
	// to continue execution. Set to `false` to stop execution if the flow
	// hook throws an exception. Defaults to `true`.
	ContinueOnError bool `json:"continueOnError,omitempty"`

	// Description: Description of the flow hook.
	Description string `json:"description,omitempty"`

	// FlowHookPoint: Output only. Where in the API call flow the flow hook
	// is invoked. Must be one of `PreProxyFlowHook`, `PostProxyFlowHook`,
	// `PreTargetFlowHook`, or `PostTargetFlowHook`.
	FlowHookPoint string `json:"flowHookPoint,omitempty"`

	// SharedFlow: Shared flow attached to this flow hook, or empty if there
	// is none attached.
	SharedFlow string `json:"sharedFlow,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ContinueOnError") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ContinueOnError") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1FlowHook) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1FlowHook
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1FlowHookConfig struct {
	// ContinueOnError: Flag that specifies whether the flow should abort
	// after an error in the flow hook. Defaults to `true` (continue on
	// error).
	ContinueOnError bool `json:"continueOnError,omitempty"`

	// Name: Name of the flow hook in the following format:
	// `organizations/{org}/environments/{env}/flowhooks/{point}`. Valid
	// `point` values include: `PreProxyFlowHook`, `PostProxyFlowHook`,
	// `PreTargetFlowHook`, and `PostTargetFlowHook`
	Name string `json:"name,omitempty"`

	// SharedFlowName: Name of the shared flow to invoke in the following
	// format: `organizations/{org}/sharedflows/{sharedflow}`
	SharedFlowName string `json:"sharedFlowName,omitempty"`

	// ForceSendFields is a list of field names (e.g. "ContinueOnError") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ContinueOnError") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1FlowHookConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1FlowHookConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1GenerateDownloadUrlRequest: Request for
// GenerateDownloadUrl method.
type GoogleCloudApigeeV1GenerateDownloadUrlRequest struct {
}

// GoogleCloudApigeeV1GenerateDownloadUrlResponse: Response for
// GenerateDownloadUrl method.
type GoogleCloudApigeeV1GenerateDownloadUrlResponse struct {
	// DownloadUri: The Google Cloud Storage signed URL that can be used to
	// download the Archive zip file.
	DownloadUri string `json:"downloadUri,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "DownloadUri") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "DownloadUri") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1GenerateDownloadUrlResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1GenerateDownloadUrlResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1GenerateUploadUrlRequest: Request for
// GenerateUploadUrl method.
type GoogleCloudApigeeV1GenerateUploadUrlRequest struct {
}

// GoogleCloudApigeeV1GenerateUploadUrlResponse: Response for
// GenerateUploadUrl method.
type GoogleCloudApigeeV1GenerateUploadUrlResponse struct {
	// UploadUri: The Google Cloud Storage signed URL that can be used to
	// upload a new Archive zip file.
	UploadUri string `json:"uploadUri,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "UploadUri") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "UploadUri") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1GenerateUploadUrlResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1GenerateUploadUrlResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1GetAsyncQueryResultUrlResponse: The response for
// GetAsyncQueryResultUrl
type GoogleCloudApigeeV1GetAsyncQueryResultUrlResponse struct {
	// Urls: The list of Signed URLs generated by the CreateAsyncQuery
	// request
	Urls []*GoogleCloudApigeeV1GetAsyncQueryResultUrlResponseURLInfo `json:"urls,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Urls") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Urls") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1GetAsyncQueryResultUrlResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1GetAsyncQueryResultUrlResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1GetAsyncQueryResultUrlResponseURLInfo: A Signed
// URL and the relevant metadata associated with it.
type GoogleCloudApigeeV1GetAsyncQueryResultUrlResponseURLInfo struct {
	// Md5: The MD5 Hash of the JSON data
	Md5 string `json:"md5,omitempty"`

	// SizeBytes: The size of the returned file in bytes
	SizeBytes int64 `json:"sizeBytes,omitempty,string"`

	// Uri: The signed URL of the JSON data. Will be of the form
	// `https://storage.googleapis.com/example-bucket/cat.jpeg?X-Goog-Algorit
	// hm=
	// GOOG4-RSA-SHA256&X-Goog-Credential=example%40example-project.iam.gserv
	// iceaccount
	// .com%2F20181026%2Fus-central1%2Fstorage%2Fgoog4_request&X-Goog-Date=20
	// 181026T18
	// 1309Z&X-Goog-Expires=900&X-Goog-SignedHeaders=host&X-Goog-Signature=24
	// 7a2aa45f16
	// 9edf4d187d54e7cc46e4731b1e6273242c4f4c39a1d2507a0e58706e25e3a85a7dbb89
	// 1d62afa849
	// 6def8e260c1db863d9ace85ff0a184b894b117fe46d1225c82f2aa19efd52cf21d3e20
	// 22b3b868dc
	// c1aca2741951ed5bf3bb25a34f5e9316a2841e8ff4c530b22ceaa1c5ce09c7cbb57326
	// 31510c2058
	// 0e61723f5594de3aea497f195456a2ff2bdd0d13bad47289d8611b6f9cfeef0c46c91a
	// 455b94e90a
	// 66924f722292d21e24d31dcfb38ce0c0f353ffa5a9756fc2a9f2b40bc2113206a81e32
	// 4fc4fd6823
	// a29163fa845c8ae7eca1fcf6e5bb48b3200983c56c5ca81fffb151cca7402beddfc4a7
	// 6b13344703 2ea7abedc098d2eb14a7`
	Uri string `json:"uri,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Md5") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Md5") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1GetAsyncQueryResultUrlResponseURLInfo) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1GetAsyncQueryResultUrlResponseURLInfo
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1GetSyncAuthorizationRequest: Request for
// GetSyncAuthorization.
type GoogleCloudApigeeV1GetSyncAuthorizationRequest struct {
}

// GoogleCloudApigeeV1GraphQLOperation: Represents the pairing of
// GraphQL operation types and the GraphQL operation name.
type GoogleCloudApigeeV1GraphQLOperation struct {
	// Operation: GraphQL operation name. The name and operation type will
	// be used to apply quotas. If no name is specified, the quota will be
	// applied to all GraphQL operations irrespective of their operation
	// names in the payload.
	Operation string `json:"operation,omitempty"`

	// OperationTypes: Required. GraphQL operation types. Valid values
	// include `query` or `mutation`. **Note**: Apigee does not currently
	// support `subscription` types.
	OperationTypes []string `json:"operationTypes,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Operation") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Operation") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1GraphQLOperation) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1GraphQLOperation
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1GraphQLOperationConfig: Binds the resources in a
// proxy or remote service with the GraphQL operation and its associated
// quota enforcement.
type GoogleCloudApigeeV1GraphQLOperationConfig struct {
	// ApiSource: Required. Name of the API proxy endpoint or remote service
	// with which the GraphQL operation and quota are associated.
	ApiSource string `json:"apiSource,omitempty"`

	// Attributes: Custom attributes associated with the operation.
	Attributes []*GoogleCloudApigeeV1Attribute `json:"attributes,omitempty"`

	// Operations: Required. List of GraphQL name/operation type pairs for
	// the proxy or remote service to which quota will be applied. If only
	// operation types are specified, the quota will be applied to all
	// GraphQL requests irrespective of the GraphQL name. **Note**:
	// Currently, you can specify only a single GraphQLOperation. Specifying
	// more than one will cause the operation to fail.
	Operations []*GoogleCloudApigeeV1GraphQLOperation `json:"operations,omitempty"`

	// Quota: Quota parameters to be enforced for the resources, methods,
	// and API source combination. If none are specified, quota enforcement
	// will not be done.
	Quota *GoogleCloudApigeeV1Quota `json:"quota,omitempty"`

	// ForceSendFields is a list of field names (e.g. "ApiSource") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ApiSource") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1GraphQLOperationConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1GraphQLOperationConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1GraphQLOperationGroup: List of graphQL operation
// configuration details associated with Apigee API proxies or remote
// services. Remote services are non-Apigee proxies, such as
// Istio-Envoy.
type GoogleCloudApigeeV1GraphQLOperationGroup struct {
	// OperationConfigType: Flag that specifies whether the configuration is
	// for Apigee API proxy or a remote service. Valid values include
	// `proxy` or `remoteservice`. Defaults to `proxy`. Set to `proxy` when
	// Apigee API proxies are associated with the API product. Set to
	// `remoteservice` when non-Apigee proxies like Istio-Envoy are
	// associated with the API product.
	OperationConfigType string `json:"operationConfigType,omitempty"`

	// OperationConfigs: Required. List of operation configurations for
	// either Apigee API proxies or other remote services that are
	// associated with this API product.
	OperationConfigs []*GoogleCloudApigeeV1GraphQLOperationConfig `json:"operationConfigs,omitempty"`

	// ForceSendFields is a list of field names (e.g. "OperationConfigType")
	// to unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "OperationConfigType") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1GraphQLOperationGroup) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1GraphQLOperationGroup
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1GraphqlDocumentation: GraphQL documentation for a
// catalog item.
type GoogleCloudApigeeV1GraphqlDocumentation struct {
	// EndpointUri: Required. The GraphQL endpoint URI to be queried by API
	// consumers. Max length is 2,083 characters.
	EndpointUri string `json:"endpointUri,omitempty"`

	// Schema: Required. The documentation file contents for the GraphQL
	// schema.
	Schema *GoogleCloudApigeeV1DocumentationFile `json:"schema,omitempty"`

	// ForceSendFields is a list of field names (e.g. "EndpointUri") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "EndpointUri") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1GraphqlDocumentation) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1GraphqlDocumentation
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1GrpcOperationConfig: Binds the resources in a
// proxy or remote service with the gRPC operation and its associated
// quota enforcement.
type GoogleCloudApigeeV1GrpcOperationConfig struct {
	// ApiSource: Required. Name of the API proxy with which the gRPC
	// operation and quota are associated.
	ApiSource string `json:"apiSource,omitempty"`

	// Attributes: Custom attributes associated with the operation.
	Attributes []*GoogleCloudApigeeV1Attribute `json:"attributes,omitempty"`

	// Methods: List of unqualified gRPC method names for the proxy to which
	// quota will be applied. If this field is empty, the Quota will apply
	// to all operations on the gRPC service defined on the proxy. Example:
	// Given a proxy that is configured to serve com.petstore.PetService,
	// the methods com.petstore.PetService.ListPets and
	// com.petstore.PetService.GetPet would be specified here as simply
	// ["ListPets", "GetPet"].
	Methods []string `json:"methods,omitempty"`

	// Quota: Quota parameters to be enforced for the methods and API source
	// combination. If none are specified, quota enforcement will not be
	// done.
	Quota *GoogleCloudApigeeV1Quota `json:"quota,omitempty"`

	// Service: Required. gRPC Service name associated to be associated with
	// the API proxy, on which quota rules can be applied upon.
	Service string `json:"service,omitempty"`

	// ForceSendFields is a list of field names (e.g. "ApiSource") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ApiSource") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1GrpcOperationConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1GrpcOperationConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1GrpcOperationGroup: List of gRPC operation
// configuration details associated with Apigee API proxies.
type GoogleCloudApigeeV1GrpcOperationGroup struct {
	// OperationConfigs: Required. List of operation configurations for
	// either Apigee API proxies that are associated with this API product.
	OperationConfigs []*GoogleCloudApigeeV1GrpcOperationConfig `json:"operationConfigs,omitempty"`

	// ForceSendFields is a list of field names (e.g. "OperationConfigs") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "OperationConfigs") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1GrpcOperationGroup) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1GrpcOperationGroup
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1IngressConfig struct {
	// EnvironmentGroups: List of environment groups in the organization.
	EnvironmentGroups []*GoogleCloudApigeeV1EnvironmentGroupConfig `json:"environmentGroups,omitempty"`

	// Name: Name of the resource in the following format:
	// `organizations/{org}/deployedIngressConfig`.
	Name string `json:"name,omitempty"`

	// RevisionCreateTime: Time at which the IngressConfig revision was
	// created.
	RevisionCreateTime string `json:"revisionCreateTime,omitempty"`

	// RevisionId: Revision id that defines the ordering on IngressConfig
	// resources. The higher the revision, the more recently the
	// configuration was deployed.
	RevisionId int64 `json:"revisionId,omitempty,string"`

	// Uid: A unique id for the ingress config that will only change if the
	// organization is deleted and recreated.
	Uid string `json:"uid,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "EnvironmentGroups")
	// to unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "EnvironmentGroups") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1IngressConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1IngressConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1Instance: Apigee runtime instance.
type GoogleCloudApigeeV1Instance struct {
	// AccessLoggingConfig: Optional. Access logging configuration enables
	// the access logging feature at the instance. Apigee customers can
	// enable access logging to ship the access logs to their own project's
	// cloud logging.
	AccessLoggingConfig *GoogleCloudApigeeV1AccessLoggingConfig `json:"accessLoggingConfig,omitempty"`

	// ConsumerAcceptList: Optional. Customer accept list represents the
	// list of projects (id/number) on customer side that can privately
	// connect to the service attachment. It is an optional field which the
	// customers can provide during the instance creation. By default, the
	// customer project associated with the Apigee organization will be
	// included to the list.
	ConsumerAcceptList []string `json:"consumerAcceptList,omitempty"`

	// CreatedAt: Output only. Time the instance was created in milliseconds
	// since epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// Description: Optional. Description of the instance.
	Description string `json:"description,omitempty"`

	// DiskEncryptionKeyName: Customer Managed Encryption Key (CMEK) used
	// for disk and volume encryption. Required for Apigee paid
	// subscriptions only. Use the following format:
	// `projects/([^/]+)/locations/([^/]+)/keyRings/([^/]+)/cryptoKeys/([^/]+
	// )`
	DiskEncryptionKeyName string `json:"diskEncryptionKeyName,omitempty"`

	// DisplayName: Optional. Display name for the instance.
	DisplayName string `json:"displayName,omitempty"`

	// Host: Output only. Internal hostname or IP address of the Apigee
	// endpoint used by clients to connect to the service.
	Host string `json:"host,omitempty"`

	// IpRange: Optional. Comma-separated list of CIDR blocks of length 22
	// and/or 28 used to create the Apigee instance. Providing CIDR ranges
	// is optional. You can provide just /22 or /28 or both (or neither).
	// Ranges you provide should be freely available as part of a larger
	// named range you have allocated to the Service Networking peering. If
	// this parameter is not provided, Apigee automatically requests an
	// available /22 and /28 CIDR block from Service Networking. Use the /22
	// CIDR block for configuring your firewall needs to allow traffic from
	// Apigee. Input formats: `a.b.c.d/22` or `e.f.g.h/28` or
	// `a.b.c.d/22,e.f.g.h/28`
	IpRange string `json:"ipRange,omitempty"`

	// LastModifiedAt: Output only. Time the instance was last modified in
	// milliseconds since epoch.
	LastModifiedAt int64 `json:"lastModifiedAt,omitempty,string"`

	// Location: Required. Compute Engine location where the instance
	// resides.
	Location string `json:"location,omitempty"`

	// Name: Required. Resource ID of the instance. Values must match the
	// regular expression `^a-z{0,30}[a-z\d]$`.
	Name string `json:"name,omitempty"`

	// PeeringCidrRange: Optional. Size of the CIDR block range that will be
	// reserved by the instance. PAID organizations support `SLASH_16` to
	// `SLASH_20` and defaults to `SLASH_16`. Evaluation organizations
	// support only `SLASH_23`.
	//
	// Possible values:
	//   "CIDR_RANGE_UNSPECIFIED" - Range not specified.
	//   "SLASH_16" - `/16` CIDR range.
	//   "SLASH_17" - `/17` CIDR range.
	//   "SLASH_18" - `/18` CIDR range.
	//   "SLASH_19" - `/19` CIDR range.
	//   "SLASH_20" - `/20` CIDR range.
	//   "SLASH_22" - `/22` CIDR range. Supported for evaluation only.
	//   "SLASH_23" - `/23` CIDR range. Supported for evaluation only.
	PeeringCidrRange string `json:"peeringCidrRange,omitempty"`

	// Port: Output only. Port number of the exposed Apigee endpoint.
	Port string `json:"port,omitempty"`

	// RuntimeVersion: Output only. Version of the runtime system running in
	// the instance. The runtime system is the set of components that serve
	// the API Proxy traffic in your Environments.
	RuntimeVersion string `json:"runtimeVersion,omitempty"`

	// ServiceAttachment: Output only. Resource name of the service
	// attachment created for the instance in the format:
	// `projects/*/regions/*/serviceAttachments/*` Apigee customers can
	// privately forward traffic to this service attachment using the PSC
	// endpoints.
	ServiceAttachment string `json:"serviceAttachment,omitempty"`

	// State: Output only. State of the instance. Values other than `ACTIVE`
	// means the resource is not ready to use.
	//
	// Possible values:
	//   "STATE_UNSPECIFIED" - Resource is in an unspecified state.
	//   "CREATING" - Resource is being created.
	//   "ACTIVE" - Resource is provisioned and ready to use.
	//   "DELETING" - The resource is being deleted.
	//   "UPDATING" - The resource is being updated.
	State string `json:"state,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "AccessLoggingConfig")
	// to unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AccessLoggingConfig") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Instance) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Instance
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1InstanceAttachment: InstanceAttachment represents
// the installation of an environment onto an instance.
type GoogleCloudApigeeV1InstanceAttachment struct {
	// CreatedAt: Output only. Time the attachment was created in
	// milliseconds since epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// Environment: ID of the attached environment.
	Environment string `json:"environment,omitempty"`

	// Name: Output only. ID of the attachment.
	Name string `json:"name,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "CreatedAt") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "CreatedAt") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1InstanceAttachment) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1InstanceAttachment
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1InstanceDeploymentStatus: The status of a
// deployment as reported by a single instance.
type GoogleCloudApigeeV1InstanceDeploymentStatus struct {
	// DeployedRevisions: Revisions currently deployed in MPs.
	DeployedRevisions []*GoogleCloudApigeeV1InstanceDeploymentStatusDeployedRevision `json:"deployedRevisions,omitempty"`

	// DeployedRoutes: Current routes deployed in the ingress routing table.
	// A route which is missing will appear in `missing_routes`.
	DeployedRoutes []*GoogleCloudApigeeV1InstanceDeploymentStatusDeployedRoute `json:"deployedRoutes,omitempty"`

	// Instance: ID of the instance reporting the status.
	Instance string `json:"instance,omitempty"`

	// ForceSendFields is a list of field names (e.g. "DeployedRevisions")
	// to unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "DeployedRevisions") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1InstanceDeploymentStatus) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1InstanceDeploymentStatus
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1InstanceDeploymentStatusDeployedRevision:
// Revisions deployed in the MPs.
type GoogleCloudApigeeV1InstanceDeploymentStatusDeployedRevision struct {
	// Percentage: Percentage of MP replicas reporting this revision.
	Percentage int64 `json:"percentage,omitempty"`

	// Revision: API proxy revision reported as deployed.
	Revision string `json:"revision,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Percentage") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Percentage") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1InstanceDeploymentStatusDeployedRevision) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1InstanceDeploymentStatusDeployedRevision
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1InstanceDeploymentStatusDeployedRoute: Route
// deployed in the ingress routing table.
type GoogleCloudApigeeV1InstanceDeploymentStatusDeployedRoute struct {
	// Basepath: Base path in the routing table.
	Basepath string `json:"basepath,omitempty"`

	// Envgroup: Environment group where this route is installed.
	Envgroup string `json:"envgroup,omitempty"`

	// Environment: Destination environment. This will be empty if the route
	// is not yet reported.
	Environment string `json:"environment,omitempty"`

	// Percentage: Percentage of ingress replicas reporting this route.
	Percentage int64 `json:"percentage,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Basepath") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Basepath") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1InstanceDeploymentStatusDeployedRoute) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1InstanceDeploymentStatusDeployedRoute
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1IntegrationConfig: Configuration for the
// Integration add-on.
type GoogleCloudApigeeV1IntegrationConfig struct {
	// Enabled: Flag that specifies whether the Integration add-on is
	// enabled.
	Enabled bool `json:"enabled,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Enabled") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Enabled") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1IntegrationConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1IntegrationConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1KeyAliasReference struct {
	// AliasId: Alias ID. Must exist in the keystore referred to by the
	// reference.
	AliasId string `json:"aliasId,omitempty"`

	// Reference: Reference name in the following format:
	// `organizations/{org}/environments/{env}/references/{reference}`
	Reference string `json:"reference,omitempty"`

	// ForceSendFields is a list of field names (e.g. "AliasId") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AliasId") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1KeyAliasReference) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1KeyAliasReference
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1KeyValueEntry: Key value map pair where the value
// represents the data associated with the corresponding key. **Note**:
// Supported for Apigee hybrid 1.8.x and higher.
type GoogleCloudApigeeV1KeyValueEntry struct {
	// Name: Resource URI that can be used to identify the scope of the key
	// value map entries.
	Name string `json:"name,omitempty"`

	// Value: Required. Data or payload that is being retrieved and
	// associated with the unique key.
	Value string `json:"value,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Name") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Name") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1KeyValueEntry) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1KeyValueEntry
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1KeyValueMap: Collection of key/value string pairs.
type GoogleCloudApigeeV1KeyValueMap struct {
	// Encrypted: Required. Flag that specifies whether entry values will be
	// encrypted. This field is retained for backward compatibility and the
	// value of encrypted will always be `true`. Apigee X and hybrid do not
	// support unencrypted key value maps.
	Encrypted bool `json:"encrypted,omitempty"`

	// Name: Required. ID of the key value map.
	Name string `json:"name,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Encrypted") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Encrypted") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1KeyValueMap) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1KeyValueMap
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1Keystore: Datastore for Certificates and Aliases.
type GoogleCloudApigeeV1Keystore struct {
	// Aliases: Output only. Aliases in this keystore.
	Aliases []string `json:"aliases,omitempty"`

	// Name: Required. Resource ID for this keystore. Values must match the
	// regular expression `[\w[:space:].-]{1,255}`.
	Name string `json:"name,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Aliases") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Aliases") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Keystore) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Keystore
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1KeystoreConfig struct {
	// Aliases: Aliases in the keystore.
	Aliases []*GoogleCloudApigeeV1AliasRevisionConfig `json:"aliases,omitempty"`

	// Name: Resource name in the following format:
	// `organizations/{org}/environments/{env}/keystores/{keystore}`
	Name string `json:"name,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Aliases") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Aliases") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1KeystoreConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1KeystoreConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListApiCategoriesResponse: The response for
// `ListApiCategoriesRequest`. Next ID: 6
type GoogleCloudApigeeV1ListApiCategoriesResponse struct {
	// Data: The API category resources.
	Data []*GoogleCloudApigeeV1ApiCategory `json:"data,omitempty"`

	// ErrorCode: Unique error code for the request, if any.
	ErrorCode string `json:"errorCode,omitempty"`

	// Message: Description of the operation.
	Message string `json:"message,omitempty"`

	// RequestId: Unique ID of the request.
	RequestId string `json:"requestId,omitempty"`

	// Status: Status of the operation.
	Status string `json:"status,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Data") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Data") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListApiCategoriesResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListApiCategoriesResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1ListApiDocsResponse struct {
	// Data: The catalog item resources.
	Data []*GoogleCloudApigeeV1ApiDoc `json:"data,omitempty"`

	// ErrorCode: Unique error code for the request, if any.
	ErrorCode string `json:"errorCode,omitempty"`

	// Message: Description of the operation.
	Message string `json:"message,omitempty"`

	// NextPageToken: A token, which can be sent as `page_token` to retrieve
	// the next page. If this field is omitted, there are no subsequent
	// pages.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// RequestId: Unique ID of the request.
	RequestId string `json:"requestId,omitempty"`

	// Status: Status of the operation.
	Status string `json:"status,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Data") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Data") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListApiDocsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListApiDocsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1ListApiProductsResponse struct {
	// ApiProduct: Lists all API product names defined for an organization.
	ApiProduct []*GoogleCloudApigeeV1ApiProduct `json:"apiProduct,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ApiProduct") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ApiProduct") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListApiProductsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListApiProductsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListApiProxiesResponse: To change this message, in
// the same CL add a change log in go/changing-api-proto-breaks-ui
type GoogleCloudApigeeV1ListApiProxiesResponse struct {
	Proxies []*GoogleCloudApigeeV1ApiProxy `json:"proxies,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Proxies") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Proxies") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListApiProxiesResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListApiProxiesResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListAppGroupAppsResponse: Response for
// ListAppGroupApps
type GoogleCloudApigeeV1ListAppGroupAppsResponse struct {
	// AppGroupApps: List of AppGroup apps and their credentials.
	AppGroupApps []*GoogleCloudApigeeV1AppGroupApp `json:"appGroupApps,omitempty"`

	// NextPageToken: Token that can be sent as `next_page_token` to
	// retrieve the next page. If this field is omitted, there are no
	// subsequent pages.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "AppGroupApps") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AppGroupApps") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListAppGroupAppsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListAppGroupAppsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListAppGroupsResponse: ListAppGroupsResponse
// contains the 0 or more AppGroups, along with the optional page token
// and the total count of apps.
type GoogleCloudApigeeV1ListAppGroupsResponse struct {
	// AppGroups: List of AppGroups.
	AppGroups []*GoogleCloudApigeeV1AppGroup `json:"appGroups,omitempty"`

	// NextPageToken: Token that can be sent as `next_page_token` to
	// retrieve the next page. If this field is omitted, there are no
	// subsequent pages.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// TotalSize: Total count of AppGroups.
	TotalSize int64 `json:"totalSize,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "AppGroups") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AppGroups") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListAppGroupsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListAppGroupsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1ListAppsResponse struct {
	App []*GoogleCloudApigeeV1App `json:"app,omitempty"`

	// NextPageToken: Token that can be sent as `next_page_token` to
	// retrieve the next page. If this field is omitted, there are no
	// subsequent pages.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// TotalSize: Total count of Apps.
	TotalSize int64 `json:"totalSize,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "App") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "App") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListAppsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListAppsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListArchiveDeploymentsResponse: Response for
// ListArchiveDeployments method.
type GoogleCloudApigeeV1ListArchiveDeploymentsResponse struct {
	// ArchiveDeployments: Archive Deployments in the specified environment.
	ArchiveDeployments []*GoogleCloudApigeeV1ArchiveDeployment `json:"archiveDeployments,omitempty"`

	// NextPageToken: Page token that you can include in a
	// ListArchiveDeployments request to retrieve the next page. If omitted,
	// no subsequent pages exist.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ArchiveDeployments")
	// to unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ArchiveDeployments") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListArchiveDeploymentsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListArchiveDeploymentsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListAsyncQueriesResponse: The response for
// ListAsyncQueries.
type GoogleCloudApigeeV1ListAsyncQueriesResponse struct {
	// Queries: The asynchronous queries belong to requested resource name.
	Queries []*GoogleCloudApigeeV1AsyncQuery `json:"queries,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Queries") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Queries") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListAsyncQueriesResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListAsyncQueriesResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListCustomReportsResponse: This message
// encapsulates a list of custom report definitions
type GoogleCloudApigeeV1ListCustomReportsResponse struct {
	Qualifier []*GoogleCloudApigeeV1CustomReport `json:"qualifier,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Qualifier") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Qualifier") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListCustomReportsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListCustomReportsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListDataCollectorsResponse: Response for
// ListDataCollectors.
type GoogleCloudApigeeV1ListDataCollectorsResponse struct {
	// DataCollectors: Data collectors in the specified organization.
	DataCollectors []*GoogleCloudApigeeV1DataCollector `json:"dataCollectors,omitempty"`

	// NextPageToken: Page token that you can include in a
	// ListDataCollectors request to retrieve the next page. If omitted, no
	// subsequent pages exist.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "DataCollectors") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "DataCollectors") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListDataCollectorsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListDataCollectorsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListDatastoresResponse: The response for
// ListDatastores
type GoogleCloudApigeeV1ListDatastoresResponse struct {
	// Datastores: A list of datastores
	Datastores []*GoogleCloudApigeeV1Datastore `json:"datastores,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Datastores") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Datastores") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListDatastoresResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListDatastoresResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1ListDebugSessionsResponse struct {
	// NextPageToken: Page token that you can include in a
	// ListDebugSessionsRequest to retrieve the next page. If omitted, no
	// subsequent pages exist.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// Sessions: Session info that includes debug session ID and the first
	// transaction creation timestamp.
	Sessions []*GoogleCloudApigeeV1Session `json:"sessions,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "NextPageToken") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListDebugSessionsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListDebugSessionsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1ListDeploymentsResponse struct {
	// Deployments: List of deployments.
	Deployments []*GoogleCloudApigeeV1Deployment `json:"deployments,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Deployments") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Deployments") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListDeploymentsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListDeploymentsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1ListDeveloperAppsResponse struct {
	// App: List of developer apps and their credentials.
	App []*GoogleCloudApigeeV1DeveloperApp `json:"app,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "App") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "App") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListDeveloperAppsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListDeveloperAppsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListDeveloperSubscriptionsResponse: Response for
// ListDeveloperSubscriptions.
type GoogleCloudApigeeV1ListDeveloperSubscriptionsResponse struct {
	// DeveloperSubscriptions: List of all subscriptions.
	DeveloperSubscriptions []*GoogleCloudApigeeV1DeveloperSubscription `json:"developerSubscriptions,omitempty"`

	// NextStartKey: Value that can be sent as `startKey` to retrieve the
	// next page of content. If this field is omitted, there are no
	// subsequent pages.
	NextStartKey string `json:"nextStartKey,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g.
	// "DeveloperSubscriptions") to unconditionally include in API requests.
	// By default, fields with empty or default values are omitted from API
	// requests. However, any non-pointer, non-interface field appearing in
	// ForceSendFields will be sent to the server regardless of whether the
	// field is empty or not. This may be used to include empty fields in
	// Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "DeveloperSubscriptions")
	// to include in API requests with the JSON null value. By default,
	// fields with empty values are omitted from API requests. However, any
	// field with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListDeveloperSubscriptionsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListDeveloperSubscriptionsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListEndpointAttachmentsResponse: Response for
// ListEndpointAttachments method.
type GoogleCloudApigeeV1ListEndpointAttachmentsResponse struct {
	// EndpointAttachments: Endpoint attachments in the specified
	// organization.
	EndpointAttachments []*GoogleCloudApigeeV1EndpointAttachment `json:"endpointAttachments,omitempty"`

	// NextPageToken: Page token that you can include in an
	// `ListEndpointAttachments` request to retrieve the next page. If
	// omitted, no subsequent pages exist.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "EndpointAttachments")
	// to unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "EndpointAttachments") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListEndpointAttachmentsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListEndpointAttachmentsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListEnvironmentGroupAttachmentsResponse: Response
// for ListEnvironmentGroupAttachments.
type GoogleCloudApigeeV1ListEnvironmentGroupAttachmentsResponse struct {
	// EnvironmentGroupAttachments: EnvironmentGroupAttachments for the
	// specified environment group.
	EnvironmentGroupAttachments []*GoogleCloudApigeeV1EnvironmentGroupAttachment `json:"environmentGroupAttachments,omitempty"`

	// NextPageToken: Page token that you can include in a
	// ListEnvironmentGroupAttachments request to retrieve the next page. If
	// omitted, no subsequent pages exist.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g.
	// "EnvironmentGroupAttachments") to unconditionally include in API
	// requests. By default, fields with empty or default values are omitted
	// from API requests. However, any non-pointer, non-interface field
	// appearing in ForceSendFields will be sent to the server regardless of
	// whether the field is empty or not. This may be used to include empty
	// fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g.
	// "EnvironmentGroupAttachments") to include in API requests with the
	// JSON null value. By default, fields with empty values are omitted
	// from API requests. However, any field with an empty value appearing
	// in NullFields will be sent to the server as null. It is an error if a
	// field in this list has a non-empty value. This may be used to include
	// null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListEnvironmentGroupAttachmentsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListEnvironmentGroupAttachmentsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListEnvironmentGroupsResponse: Response for
// ListEnvironmentGroups.
type GoogleCloudApigeeV1ListEnvironmentGroupsResponse struct {
	// EnvironmentGroups: EnvironmentGroups in the specified organization.
	EnvironmentGroups []*GoogleCloudApigeeV1EnvironmentGroup `json:"environmentGroups,omitempty"`

	// NextPageToken: Page token that you can include in a
	// ListEnvironmentGroups request to retrieve the next page. If omitted,
	// no subsequent pages exist.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "EnvironmentGroups")
	// to unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "EnvironmentGroups") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListEnvironmentGroupsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListEnvironmentGroupsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListEnvironmentResourcesResponse: Response for
// ListEnvironmentResources
type GoogleCloudApigeeV1ListEnvironmentResourcesResponse struct {
	// ResourceFile: List of resources files.
	ResourceFile []*GoogleCloudApigeeV1ResourceFile `json:"resourceFile,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ResourceFile") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ResourceFile") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListEnvironmentResourcesResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListEnvironmentResourcesResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListExportsResponse: The response for ListExports
type GoogleCloudApigeeV1ListExportsResponse struct {
	// Exports: Details of the export jobs.
	Exports []*GoogleCloudApigeeV1Export `json:"exports,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Exports") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Exports") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListExportsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListExportsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1ListHybridIssuersResponse struct {
	// Issuers: Lists of hybrid services and its trusted issuer email ids.
	Issuers []*GoogleCloudApigeeV1ServiceIssuersMapping `json:"issuers,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Issuers") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Issuers") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListHybridIssuersResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListHybridIssuersResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListInstanceAttachmentsResponse: Response for
// ListInstanceAttachments.
type GoogleCloudApigeeV1ListInstanceAttachmentsResponse struct {
	// Attachments: Attachments for the instance.
	Attachments []*GoogleCloudApigeeV1InstanceAttachment `json:"attachments,omitempty"`

	// NextPageToken: Page token that you can include in a
	// ListInstanceAttachments request to retrieve the next page of content.
	// If omitted, no subsequent pages exist.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Attachments") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Attachments") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListInstanceAttachmentsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListInstanceAttachmentsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListInstancesResponse: Response for ListInstances.
type GoogleCloudApigeeV1ListInstancesResponse struct {
	// Instances: Instances in the specified organization.
	Instances []*GoogleCloudApigeeV1Instance `json:"instances,omitempty"`

	// NextPageToken: Page token that you can include in a ListInstance
	// request to retrieve the next page of content. If omitted, no
	// subsequent pages exist.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Instances") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Instances") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListInstancesResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListInstancesResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListKeyValueEntriesResponse: The request structure
// for listing key value map keys and its corresponding values.
type GoogleCloudApigeeV1ListKeyValueEntriesResponse struct {
	// KeyValueEntries: One or more key value map keys and values.
	KeyValueEntries []*GoogleCloudApigeeV1KeyValueEntry `json:"keyValueEntries,omitempty"`

	// NextPageToken: Token that can be sent as `next_page_token` to
	// retrieve the next page. If this field is omitted, there are no
	// subsequent pages.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "KeyValueEntries") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "KeyValueEntries") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListKeyValueEntriesResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListKeyValueEntriesResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListNatAddressesResponse: Response for
// ListNatAddresses.
type GoogleCloudApigeeV1ListNatAddressesResponse struct {
	// NatAddresses: List of NAT Addresses for the instance.
	NatAddresses []*GoogleCloudApigeeV1NatAddress `json:"natAddresses,omitempty"`

	// NextPageToken: Page token that you can include in a ListNatAddresses
	// request to retrieve the next page of content. If omitted, no
	// subsequent pages exist.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "NatAddresses") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "NatAddresses") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListNatAddressesResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListNatAddressesResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1ListOfDevelopersResponse struct {
	// Developer: List of developers.
	Developer []*GoogleCloudApigeeV1Developer `json:"developer,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Developer") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Developer") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListOfDevelopersResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListOfDevelopersResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1ListOrganizationsResponse struct {
	// Organizations: List of Apigee organizations and associated Google
	// Cloud projects.
	Organizations []*GoogleCloudApigeeV1OrganizationProjectMapping `json:"organizations,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Organizations") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Organizations") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListOrganizationsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListOrganizationsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListRatePlansResponse: Response for ListRatePlans.
type GoogleCloudApigeeV1ListRatePlansResponse struct {
	// NextStartKey: Value that can be sent as `startKey` to retrieve the
	// next page of content. If this field is omitted, there are no
	// subsequent pages.
	NextStartKey string `json:"nextStartKey,omitempty"`

	// RatePlans: List of rate plans in an organization.
	RatePlans []*GoogleCloudApigeeV1RatePlan `json:"ratePlans,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "NextStartKey") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "NextStartKey") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListRatePlansResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListRatePlansResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListSecurityActionsResponse: Contains a list of
// SecurityActions in response to a ListSecurityActionRequest.
type GoogleCloudApigeeV1ListSecurityActionsResponse struct {
	// NextPageToken: A token, which can be sent as `page_token` to retrieve
	// the next page. If this field is omitted, there are no subsequent
	// pages.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// SecurityActions: The SecurityActions for the specified environment.
	SecurityActions []*GoogleCloudApigeeV1SecurityAction `json:"securityActions,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "NextPageToken") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListSecurityActionsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListSecurityActionsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListSecurityIncidentsResponse: Response for
// ListSecurityIncidents.
type GoogleCloudApigeeV1ListSecurityIncidentsResponse struct {
	// NextPageToken: A token that can be sent as `page_token` to retrieve
	// the next page. If this field is omitted, there are no subsequent
	// pages.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// SecurityIncidents: List of security incidents in the organization
	SecurityIncidents []*GoogleCloudApigeeV1SecurityIncident `json:"securityIncidents,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "NextPageToken") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListSecurityIncidentsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListSecurityIncidentsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListSecurityProfileRevisionsResponse: Response for
// ListSecurityProfileRevisions.
type GoogleCloudApigeeV1ListSecurityProfileRevisionsResponse struct {
	// NextPageToken: A token that can be sent as `page_token` to retrieve
	// the next page. If this field is omitted, there are no subsequent
	// pages.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// SecurityProfiles: List of security profile revisions. The revisions
	// may be attached or unattached to any environment.
	SecurityProfiles []*GoogleCloudApigeeV1SecurityProfile `json:"securityProfiles,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "NextPageToken") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListSecurityProfileRevisionsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListSecurityProfileRevisionsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListSecurityProfilesResponse: Response for
// ListSecurityProfiles.
type GoogleCloudApigeeV1ListSecurityProfilesResponse struct {
	// NextPageToken: A token that can be sent as `page_token` to retrieve
	// the next page. If this field is omitted, there are no subsequent
	// pages.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// SecurityProfiles: List of security profiles in the organization. The
	// profiles may be attached or unattached to any environment. This will
	// return latest revision of each profile.
	SecurityProfiles []*GoogleCloudApigeeV1SecurityProfile `json:"securityProfiles,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "NextPageToken") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListSecurityProfilesResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListSecurityProfilesResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListSecurityReportsResponse: The response for
// SecurityReports.
type GoogleCloudApigeeV1ListSecurityReportsResponse struct {
	// NextPageToken: If the number of security reports exceeded the page
	// size requested, the token can be used to fetch the next page in a
	// subsequent call. If the response is the last page and there are no
	// more reports to return this field is left empty.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// SecurityReports: The security reports belong to requested resource
	// name.
	SecurityReports []*GoogleCloudApigeeV1SecurityReport `json:"securityReports,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "NextPageToken") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListSecurityReportsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListSecurityReportsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListSharedFlowsResponse: To change this message,
// in the same CL add a change log in go/changing-api-proto-breaks-ui
type GoogleCloudApigeeV1ListSharedFlowsResponse struct {
	SharedFlows []*GoogleCloudApigeeV1SharedFlow `json:"sharedFlows,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "SharedFlows") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "SharedFlows") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListSharedFlowsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListSharedFlowsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ListTraceConfigOverridesResponse: Response for
// ListTraceConfigOverrides.
type GoogleCloudApigeeV1ListTraceConfigOverridesResponse struct {
	// NextPageToken: Token value that can be passed as `page_token` to
	// retrieve the next page of content.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// TraceConfigOverrides: List all trace configuration overrides in an
	// environment.
	TraceConfigOverrides []*GoogleCloudApigeeV1TraceConfigOverride `json:"traceConfigOverrides,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "NextPageToken") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ListTraceConfigOverridesResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ListTraceConfigOverridesResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1Metadata: Encapsulates additional information
// about query execution.
type GoogleCloudApigeeV1Metadata struct {
	// Errors: List of error messages as strings.
	Errors []string `json:"errors,omitempty"`

	// Notices: List of additional information such as data source, if
	// result was truncated. For example: ``` "notices": [
	// "Source:Postgres", "PG Host:uappg0rw.e2e.apigeeks.net", "query served
	// by:4b64601e-40de-4eb1-bfb9-eeee7ac929ed", "Table used:
	// edge.api.uapgroup2.agg_api" ]```
	Notices []string `json:"notices,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Errors") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Errors") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Metadata) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Metadata
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1Metric: Encapsulates the metric data point. For
// example: ```{ "name": "sum(message_count)", "values" : [ {
// "timestamp": 1549004400000, "value": "39.0" }, { "timestamp" :
// 1548997200000, "value" : "0.0" } ] }``` or ```{ "name":
// "sum(message_count)", "values" : ["39.0"] }```
type GoogleCloudApigeeV1Metric struct {
	// Name: Metric name.
	Name string `json:"name,omitempty"`

	// Values: List of metric values. Possible value formats include:
	// "values":["39.0"]` or "values":[ { "value": "39.0", "timestamp":
	// 1232434354} ]`
	Values []interface{} `json:"values,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Name") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Name") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Metric) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Metric
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1MetricAggregation: The optionally aggregated
// metric to query with its ordering.
type GoogleCloudApigeeV1MetricAggregation struct {
	// Aggregation: Aggregation function associated with the metric.
	//
	// Possible values:
	//   "AGGREGATION_FUNCTION_UNSPECIFIED" - Unspecified Aggregation
	// function.
	//   "AVG" - Average.
	//   "SUM" - Summation.
	//   "MIN" - Min.
	//   "MAX" - Max.
	//   "COUNT_DISTINCT" - Count distinct
	Aggregation string `json:"aggregation,omitempty"`

	// Name: Name of the metric
	Name string `json:"name,omitempty"`

	// Order: Ordering for this aggregation in the result. For time series
	// this is ignored since the ordering of points depends only on the
	// timestamp, not the values.
	//
	// Possible values:
	//   "ORDER_UNSPECIFIED" - Unspecified order. Default is Descending.
	//   "ASCENDING" - Ascending sort order.
	//   "DESCENDING" - Descending sort order.
	Order string `json:"order,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Aggregation") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Aggregation") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1MetricAggregation) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1MetricAggregation
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1MonetizationConfig: Configuration for the
// Monetization add-on.
type GoogleCloudApigeeV1MonetizationConfig struct {
	// Enabled: Flag that specifies whether the Monetization add-on is
	// enabled.
	Enabled bool `json:"enabled,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Enabled") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Enabled") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1MonetizationConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1MonetizationConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1NatAddress: Apigee NAT(network address
// translation) address. A NAT address is a static external IP address
// used for Internet egress traffic.
type GoogleCloudApigeeV1NatAddress struct {
	// IpAddress: Output only. The static IPV4 address.
	IpAddress string `json:"ipAddress,omitempty"`

	// Name: Required. Resource ID of the NAT address.
	Name string `json:"name,omitempty"`

	// State: Output only. State of the nat address.
	//
	// Possible values:
	//   "STATE_UNSPECIFIED" - The resource is in an unspecified state.
	//   "CREATING" - The NAT address is being created.
	//   "RESERVED" - The NAT address is reserved but not yet used for
	// Internet egress.
	//   "ACTIVE" - The NAT address is active and used for Internet egress.
	//   "DELETING" - The NAT address is being deleted.
	State string `json:"state,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "IpAddress") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "IpAddress") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1NatAddress) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1NatAddress
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1NodeConfig: NodeConfig for setting the min/max
// number of nodes associated with the environment.
type GoogleCloudApigeeV1NodeConfig struct {
	// CurrentAggregateNodeCount: Output only. The current total number of
	// gateway nodes that each environment currently has across all
	// instances.
	CurrentAggregateNodeCount int64 `json:"currentAggregateNodeCount,omitempty,string"`

	// MaxNodeCount: Optional. The maximum total number of gateway nodes
	// that the is reserved for all instances that has the specified
	// environment. If not specified, the default is determined by the
	// recommended maximum number of nodes for that gateway.
	MaxNodeCount int64 `json:"maxNodeCount,omitempty,string"`

	// MinNodeCount: Optional. The minimum total number of gateway nodes
	// that the is reserved for all instances that has the specified
	// environment. If not specified, the default is determined by the
	// recommended minimum number of nodes for that gateway.
	MinNodeCount int64 `json:"minNodeCount,omitempty,string"`

	// ForceSendFields is a list of field names (e.g.
	// "CurrentAggregateNodeCount") to unconditionally include in API
	// requests. By default, fields with empty or default values are omitted
	// from API requests. However, any non-pointer, non-interface field
	// appearing in ForceSendFields will be sent to the server regardless of
	// whether the field is empty or not. This may be used to include empty
	// fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g.
	// "CurrentAggregateNodeCount") to include in API requests with the JSON
	// null value. By default, fields with empty values are omitted from API
	// requests. However, any field with an empty value appearing in
	// NullFields will be sent to the server as null. It is an error if a
	// field in this list has a non-empty value. This may be used to include
	// null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1NodeConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1NodeConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1OASDocumentation: OpenAPI Specification
// documentation for a catalog item.
type GoogleCloudApigeeV1OASDocumentation struct {
	// Format: Output only. The format of the input specification file
	// contents.
	//
	// Possible values:
	//   "FORMAT_UNSPECIFIED" - The format is not available.
	//   "YAML" - YAML format.
	//   "JSON" - JSON format.
	Format string `json:"format,omitempty"`

	// Spec: Required. The documentation file contents for the OpenAPI
	// Specification. JSON and YAML file formats are supported.
	Spec *GoogleCloudApigeeV1DocumentationFile `json:"spec,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Format") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Format") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1OASDocumentation) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1OASDocumentation
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1Operation: Represents the pairing of REST resource
// path and the actions (verbs) allowed on the resource path.
type GoogleCloudApigeeV1Operation struct {
	// Methods: methods refers to the REST verbs as in
	// https://www.w3.org/Protocols/rfc2616/rfc2616-sec9.html. When none
	// specified, all verb types are allowed.
	Methods []string `json:"methods,omitempty"`

	// Resource: Required. REST resource path associated with the API proxy
	// or remote service.
	Resource string `json:"resource,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Methods") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Methods") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Operation) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Operation
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1OperationConfig: Binds the resources in an API
// proxy or remote service with the allowed REST methods and associated
// quota enforcement.
type GoogleCloudApigeeV1OperationConfig struct {
	// ApiSource: Required. Name of the API proxy or remote service with
	// which the resources, methods, and quota are associated.
	ApiSource string `json:"apiSource,omitempty"`

	// Attributes: Custom attributes associated with the operation.
	Attributes []*GoogleCloudApigeeV1Attribute `json:"attributes,omitempty"`

	// Operations: List of resource/method pairs for the API proxy or remote
	// service to which quota will applied. **Note**: Currently, you can
	// specify only a single resource/method pair. The call will fail if
	// more than one resource/method pair is provided.
	Operations []*GoogleCloudApigeeV1Operation `json:"operations,omitempty"`

	// Quota: Quota parameters to be enforced for the resources, methods,
	// and API source combination. If none are specified, quota enforcement
	// will not be done.
	Quota *GoogleCloudApigeeV1Quota `json:"quota,omitempty"`

	// ForceSendFields is a list of field names (e.g. "ApiSource") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ApiSource") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1OperationConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1OperationConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1OperationGroup: List of operation configuration
// details associated with Apigee API proxies or remote services. Remote
// services are non-Apigee proxies, such as Istio-Envoy.
type GoogleCloudApigeeV1OperationGroup struct {
	// OperationConfigType: Flag that specifes whether the configuration is
	// for Apigee API proxy or a remote service. Valid values include
	// `proxy` or `remoteservice`. Defaults to `proxy`. Set to `proxy` when
	// Apigee API proxies are associated with the API product. Set to
	// `remoteservice` when non-Apigee proxies like Istio-Envoy are
	// associated with the API product.
	OperationConfigType string `json:"operationConfigType,omitempty"`

	// OperationConfigs: Required. List of operation configurations for
	// either Apigee API proxies or other remote services that are
	// associated with this API product.
	OperationConfigs []*GoogleCloudApigeeV1OperationConfig `json:"operationConfigs,omitempty"`

	// ForceSendFields is a list of field names (e.g. "OperationConfigType")
	// to unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "OperationConfigType") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1OperationGroup) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1OperationGroup
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1OperationMetadata: Metadata describing an
// Operation.
type GoogleCloudApigeeV1OperationMetadata struct {
	// Possible values:
	//   "OPERATION_TYPE_UNSPECIFIED"
	//   "INSERT"
	//   "DELETE"
	//   "UPDATE"
	OperationType string `json:"operationType,omitempty"`

	// Progress: Progress of the operation.
	Progress *GoogleCloudApigeeV1OperationMetadataProgress `json:"progress,omitempty"`

	// Possible values:
	//   "STATE_UNSPECIFIED"
	//   "NOT_STARTED"
	//   "IN_PROGRESS"
	//   "FINISHED"
	State string `json:"state,omitempty"`

	// TargetResourceName: Name of the resource for which the operation is
	// operating on.
	TargetResourceName string `json:"targetResourceName,omitempty"`

	// Warnings: Warnings encountered while executing the operation.
	Warnings []string `json:"warnings,omitempty"`

	// ForceSendFields is a list of field names (e.g. "OperationType") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "OperationType") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1OperationMetadata) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1OperationMetadata
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1OperationMetadataProgress: Information about
// operation progress.
type GoogleCloudApigeeV1OperationMetadataProgress struct {
	// Description: Description of the operation's progress.
	Description string `json:"description,omitempty"`

	// Details: The additional details of the progress.
	Details googleapi.RawMessage `json:"details,omitempty"`

	// PercentDone: The percentage of the operation progress.
	PercentDone int64 `json:"percentDone,omitempty"`

	// State: State of the operation.
	//
	// Possible values:
	//   "STATE_UNSPECIFIED"
	//   "NOT_STARTED"
	//   "IN_PROGRESS"
	//   "FINISHED"
	State string `json:"state,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Description") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Description") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1OperationMetadataProgress) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1OperationMetadataProgress
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1OptimizedStats struct {
	// Response: Wraps the `stats` response for JavaScript Optimized
	// Scenario with a response key. For example: ```{ "Response": {
	// "TimeUnit": [], "metaData": { "errors": [], "notices": [
	// "Source:Postgres", "Table used: edge.api.aaxgroup001.agg_api", "PG
	// Host:ruappg08-ro.production.apigeeks.net", "query served
	// by:80c4ebca-6a10-4a2e-8faf-c60c1ee306ca" ] }, "resultTruncated":
	// false, "stats": { "data": [ { "identifier": { "names": [ "apiproxy"
	// ], "values": [ "sirjee" ] }, "metric": [ { "env": "prod", "name":
	// "sum(message_count)", "values": [ 36.0 ] }, { "env": "prod", "name":
	// "sum(is_error)", "values": [ 36.0 ] } ] } ] } } }```
	Response *GoogleCloudApigeeV1OptimizedStatsResponse `json:"Response,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Response") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Response") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1OptimizedStats) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1OptimizedStats
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1OptimizedStatsNode: Encapsulates a data node as
// represented below: ``` { "identifier": { "names": [ "apiproxy" ],
// "values": [ "sirjee" ] }, "metric": [ { "env": "prod", "name":
// "sum(message_count)", "values": [ 36.0 ] } ] }``` or ``` { "env":
// "prod", "name": "sum(message_count)", "values": [ 36.0 ] }```
// Depending on whether a dimension is present in the query or not the
// data node type can be a simple metric value or dimension identifier
// with list of metrics.
type GoogleCloudApigeeV1OptimizedStatsNode struct {
	Data []interface{} `json:"data,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Data") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Data") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1OptimizedStatsNode) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1OptimizedStatsNode
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1OptimizedStatsResponse: Encapsulates a response
// format for JavaScript Optimized Scenario.
type GoogleCloudApigeeV1OptimizedStatsResponse struct {
	// TimeUnit: List of time unit values. Time unit refers to an epoch
	// timestamp value.
	TimeUnit googleapi.Int64s `json:"TimeUnit,omitempty"`

	// MetaData: Metadata information about the query executed.
	MetaData *GoogleCloudApigeeV1Metadata `json:"metaData,omitempty"`

	// ResultTruncated: Boolean flag that indicates whether the results were
	// truncated based on the limit parameter.
	ResultTruncated bool `json:"resultTruncated,omitempty"`

	// Stats: `stats` results.
	Stats *GoogleCloudApigeeV1OptimizedStatsNode `json:"stats,omitempty"`

	// ForceSendFields is a list of field names (e.g. "TimeUnit") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "TimeUnit") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1OptimizedStatsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1OptimizedStatsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1Organization struct {
	// AddonsConfig: Addon configurations of the Apigee organization.
	AddonsConfig *GoogleCloudApigeeV1AddonsConfig `json:"addonsConfig,omitempty"`

	// AnalyticsRegion: Required. DEPRECATED: This field will eventually be
	// deprecated and replaced with a differently-named field. Primary
	// Google Cloud region for analytics data storage. For valid values, see
	// Create an Apigee organization
	// (https://cloud.google.com/apigee/docs/api-platform/get-started/create-org).
	AnalyticsRegion string `json:"analyticsRegion,omitempty"`

	// ApiConsumerDataEncryptionKeyName: Cloud KMS key name used for
	// encrypting API consumer data. Required for US/EU regions when
	// BillingType (#BillingType) is `SUBSCRIPTION`. When BillingType
	// (#BillingType) is `EVALUATION` or the region is not US/EU, a
	// Google-Managed encryption key will be used. Format:
	// `projects/*/locations/*/keyRings/*/cryptoKeys/*`
	ApiConsumerDataEncryptionKeyName string `json:"apiConsumerDataEncryptionKeyName,omitempty"`

	// ApiConsumerDataLocation: This field is needed only for customers with
	// control plane in US or EU. Apigee stores some control plane data only
	// in single region. This field determines which single region Apigee
	// should use. For example: "us-west1" when control plane is in US or
	// "europe-west2" when control plane is in EU.
	ApiConsumerDataLocation string `json:"apiConsumerDataLocation,omitempty"`

	// ApigeeProjectId: Output only. Apigee Project ID associated with the
	// organization. Use this project to allowlist Apigee in the Service
	// Attachment when using private service connect with Apigee.
	ApigeeProjectId string `json:"apigeeProjectId,omitempty"`

	// Attributes: Not used by Apigee.
	Attributes []string `json:"attributes,omitempty"`

	// AuthorizedNetwork: Compute Engine network used for Service Networking
	// to be peered with Apigee runtime instances. See Getting started with
	// the Service Networking API
	// (https://cloud.google.com/service-infrastructure/docs/service-networking/getting-started).
	// Valid only when RuntimeType (#RuntimeType) is set to `CLOUD`. The
	// value must be set before the creation of a runtime instance and can
	// be updated only when there are no runtime instances. For example:
	// `default`. Apigee also supports shared VPC (that is, the host network
	// project is not the same as the one that is peering with Apigee). See
	// Shared VPC overview (https://cloud.google.com/vpc/docs/shared-vpc).
	// To use a shared VPC network, use the following format:
	// `projects/{host-project-id}/{region}/networks/{network-name}`. For
	// example: `projects/my-sharedvpc-host/global/networks/mynetwork`
	// **Note:** Not supported for Apigee hybrid.
	AuthorizedNetwork string `json:"authorizedNetwork,omitempty"`

	// BillingType: Billing type of the Apigee organization. See Apigee
	// pricing (https://cloud.google.com/apigee/pricing).
	//
	// Possible values:
	//   "BILLING_TYPE_UNSPECIFIED" - Billing type not specified.
	//   "SUBSCRIPTION" - A pre-paid subscription to Apigee.
	//   "EVALUATION" - Free and limited access to Apigee for evaluation
	// purposes only.
	//   "PAYG" - Access to Apigee using a Pay-As-You-Go plan.
	BillingType string `json:"billingType,omitempty"`

	// CaCertificate: Output only. Base64-encoded public certificate for the
	// root CA of the Apigee organization. Valid only when RuntimeType
	// (#RuntimeType) is `CLOUD`.
	CaCertificate string `json:"caCertificate,omitempty"`

	// ControlPlaneEncryptionKeyName: Cloud KMS key name used for encrypting
	// control plane data that is stored in a multi region. Required when
	// BillingType (#BillingType) is `SUBSCRIPTION`. When BillingType
	// (#BillingType) is `EVALUATION`, a Google-Managed encryption key will
	// be used. Format: `projects/*/locations/*/keyRings/*/cryptoKeys/*`
	ControlPlaneEncryptionKeyName string `json:"controlPlaneEncryptionKeyName,omitempty"`

	// CreatedAt: Output only. Time that the Apigee organization was created
	// in milliseconds since epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// CustomerName: Not used by Apigee.
	CustomerName string `json:"customerName,omitempty"`

	// Description: Description of the Apigee organization.
	Description string `json:"description,omitempty"`

	// DisableVpcPeering: Optional. Flag that specifies whether the VPC
	// Peering through Private Google Access should be disabled between the
	// consumer network and Apigee. Valid only when RuntimeType is set to
	// CLOUD. Required if an authorizedNetwork on the consumer project is
	// not provided, in which case the flag should be set to true. The value
	// must be set before the creation of any Apigee runtime instance and
	// can be updated only when there are no runtime instances. **Note:**
	// Apigee will be deprecating the vpc peering model that requires you to
	// provide 'authorizedNetwork', by making the non-peering model as the
	// default way of provisioning Apigee organization in future. So, this
	// will be a temporary flag to enable the transition. Not supported for
	// Apigee hybrid.
	DisableVpcPeering bool `json:"disableVpcPeering,omitempty"`

	// DisplayName: Display name for the Apigee organization. Unused, but
	// reserved for future use.
	DisplayName string `json:"displayName,omitempty"`

	// Environments: Output only. List of environments in the Apigee
	// organization.
	Environments []string `json:"environments,omitempty"`

	// ExpiresAt: Output only. Time that the Apigee organization is
	// scheduled for deletion.
	ExpiresAt int64 `json:"expiresAt,omitempty,string"`

	// LastModifiedAt: Output only. Time that the Apigee organization was
	// last modified in milliseconds since epoch.
	LastModifiedAt int64 `json:"lastModifiedAt,omitempty,string"`

	// Name: Output only. Name of the Apigee organization.
	Name string `json:"name,omitempty"`

	// PortalDisabled: Configuration for the Portals settings.
	PortalDisabled bool `json:"portalDisabled,omitempty"`

	// ProjectId: Output only. Project ID associated with the Apigee
	// organization.
	ProjectId string `json:"projectId,omitempty"`

	// Properties: Properties defined in the Apigee organization profile.
	Properties *GoogleCloudApigeeV1Properties `json:"properties,omitempty"`

	// RuntimeDatabaseEncryptionKeyName: Cloud KMS key name used for
	// encrypting the data that is stored and replicated across runtime
	// instances. Update is not allowed after the organization is created.
	// Required when RuntimeType (#RuntimeType) is `CLOUD`. If not specified
	// when RuntimeType (#RuntimeType) is `TRIAL`, a Google-Managed
	// encryption key will be used. For example:
	// "projects/foo/locations/us/keyRings/bar/cryptoKeys/baz". **Note:**
	// Not supported for Apigee hybrid.
	RuntimeDatabaseEncryptionKeyName string `json:"runtimeDatabaseEncryptionKeyName,omitempty"`

	// RuntimeType: Required. Runtime type of the Apigee organization based
	// on the Apigee subscription purchased.
	//
	// Possible values:
	//   "RUNTIME_TYPE_UNSPECIFIED" - Runtime type not specified.
	//   "CLOUD" - Google-managed Apigee runtime.
	//   "HYBRID" - User-managed Apigee hybrid runtime.
	RuntimeType string `json:"runtimeType,omitempty"`

	// State: Output only. State of the organization. Values other than
	// ACTIVE means the resource is not ready to use.
	//
	// Possible values:
	//   "STATE_UNSPECIFIED" - Resource is in an unspecified state.
	//   "CREATING" - Resource is being created.
	//   "ACTIVE" - Resource is provisioned and ready to use.
	//   "DELETING" - The resource is being deleted.
	//   "UPDATING" - The resource is being updated.
	State string `json:"state,omitempty"`

	// SubscriptionPlan: Output only. Subscription plan that the customer
	// has purchased. Output only.
	//
	// Possible values:
	//   "SUBSCRIPTION_PLAN_UNSPECIFIED" - Subscription plan not specified.
	//   "SUBSCRIPTION_2021" - Traditional subscription plan.
	//   "SUBSCRIPTION_2024" - New subscription plan that provides standard
	// proxy and scaled proxy implementation.
	SubscriptionPlan string `json:"subscriptionPlan,omitempty"`

	// SubscriptionType: Output only. DEPRECATED: This will eventually be
	// replaced by BillingType. Subscription type of the Apigee
	// organization. Valid values include trial (free, limited, and for
	// evaluation purposes only) or paid (full subscription has been
	// purchased). See Apigee pricing
	// (https://cloud.google.com/apigee/pricing/).
	//
	// Possible values:
	//   "SUBSCRIPTION_TYPE_UNSPECIFIED" - Subscription type not specified.
	//   "PAID" - Full subscription to Apigee has been purchased.
	//   "TRIAL" - Subscription to Apigee is free, limited, and used for
	// evaluation purposes only.
	SubscriptionType string `json:"subscriptionType,omitempty"`

	// Type: Not used by Apigee.
	//
	// Possible values:
	//   "TYPE_UNSPECIFIED" - Subscription type not specified.
	//   "TYPE_TRIAL" - Subscription to Apigee is free, limited, and used
	// for evaluation purposes only.
	//   "TYPE_PAID" - Full subscription to Apigee has been purchased. See
	// [Apigee pricing](https://cloud.google.com/apigee/pricing/).
	//   "TYPE_INTERNAL" - For internal users only.
	Type string `json:"type,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "AddonsConfig") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AddonsConfig") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Organization) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Organization
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1OrganizationProjectMapping struct {
	// Location: Output only. The Google Cloud region where control plane
	// data is located. For more information, see
	// https://cloud.google.com/about/locations/.
	Location string `json:"location,omitempty"`

	// Organization: Name of the Apigee organization.
	Organization string `json:"organization,omitempty"`

	// ProjectId: Google Cloud project associated with the Apigee
	// organization
	ProjectId string `json:"projectId,omitempty"`

	// ProjectIds: DEPRECATED: Use `project_id`. An Apigee Organization is
	// mapped to a single project.
	ProjectIds []string `json:"projectIds,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Location") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Location") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1OrganizationProjectMapping) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1OrganizationProjectMapping
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1PodStatus struct {
	// AppVersion: Version of the application running in the pod.
	AppVersion string `json:"appVersion,omitempty"`

	// DeploymentStatus: Status of the deployment. Valid values include: -
	// `deployed`: Successful. - `error` : Failed. - `pending` : Pod has not
	// yet reported on the deployment.
	DeploymentStatus string `json:"deploymentStatus,omitempty"`

	// DeploymentStatusTime: Time the deployment status was reported in
	// milliseconds since epoch.
	DeploymentStatusTime int64 `json:"deploymentStatusTime,omitempty,string"`

	// DeploymentTime: Time the proxy was deployed in milliseconds since
	// epoch.
	DeploymentTime int64 `json:"deploymentTime,omitempty,string"`

	// PodName: Name of the pod which is reporting the status.
	PodName string `json:"podName,omitempty"`

	// PodStatus: Overall status of the pod (not this specific deployment).
	// Valid values include: - `active`: Up to date. - `stale` : Recently
	// out of date. Pods that have not reported status in a long time are
	// excluded from the output.
	PodStatus string `json:"podStatus,omitempty"`

	// PodStatusTime: Time the pod status was reported in milliseconds since
	// epoch.
	PodStatusTime int64 `json:"podStatusTime,omitempty,string"`

	// StatusCode: Code associated with the deployment status.
	StatusCode string `json:"statusCode,omitempty"`

	// StatusCodeDetails: Human-readable message associated with the status
	// code.
	StatusCodeDetails string `json:"statusCodeDetails,omitempty"`

	// ForceSendFields is a list of field names (e.g. "AppVersion") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AppVersion") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1PodStatus) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1PodStatus
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1Point: Point is a group of information collected
// by runtime plane at critical points of the message flow of the
// processed API request. This is a list of supported point IDs,
// categorized to three major buckets. For each category, debug points
// that we are currently supporting are listed below: - Flow status
// debug points: StateChange FlowInfo Condition Execution DebugMask
// Error - Flow control debug points: FlowCallout Paused Resumed
// FlowReturn BreakFlow Error - Runtime debug points: ScriptExecutor
// FlowCalloutStepDefinition CustomTarget StepDefinition
// Oauth2ServicePoint RaiseFault NodeJS The detail information of the
// given debug point is stored in a list of results.
type GoogleCloudApigeeV1Point struct {
	// Id: Name of a step in the transaction.
	Id string `json:"id,omitempty"`

	// Results: List of results extracted from a given debug point.
	Results []*GoogleCloudApigeeV1Result `json:"results,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Id") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Id") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Point) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Point
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ProfileConfig: ProfileConfig defines a set of
// categories and policies which will be used to compute security score.
type GoogleCloudApigeeV1ProfileConfig struct {
	// Categories: List of categories of profile config.
	Categories []*GoogleCloudApigeeV1ProfileConfigCategory `json:"categories,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Categories") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Categories") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ProfileConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ProfileConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ProfileConfigAbuse: Checks for abuse, which
// includes any requests sent to the API for purposes other than what it
// is intended for, such as high volumes of requests, data scraping, and
// abuse related to authorization.
type GoogleCloudApigeeV1ProfileConfigAbuse struct {
}

// GoogleCloudApigeeV1ProfileConfigAuthorization: By default, following
// policies will be included: - JWS - JWT - OAuth - BasicAuth - APIKey
type GoogleCloudApigeeV1ProfileConfigAuthorization struct {
}

// GoogleCloudApigeeV1ProfileConfigCORS: Checks to see if you have CORS
// policy in place.
type GoogleCloudApigeeV1ProfileConfigCORS struct {
}

// GoogleCloudApigeeV1ProfileConfigCategory: Advanced API Security
// provides security profile that scores the following categories.
type GoogleCloudApigeeV1ProfileConfigCategory struct {
	// Abuse: Checks for abuse, which includes any requests sent to the API
	// for purposes other than what it is intended for, such as high volumes
	// of requests, data scraping, and abuse related to authorization.
	Abuse *GoogleCloudApigeeV1ProfileConfigAbuse `json:"abuse,omitempty"`

	// Authorization: Checks to see if you have an authorization policy in
	// place.
	Authorization *GoogleCloudApigeeV1ProfileConfigAuthorization `json:"authorization,omitempty"`

	// Cors: Checks to see if you have CORS policy in place.
	Cors *GoogleCloudApigeeV1ProfileConfigCORS `json:"cors,omitempty"`

	// Mediation: Checks to see if you have a mediation policy in place.
	Mediation *GoogleCloudApigeeV1ProfileConfigMediation `json:"mediation,omitempty"`

	// Mtls: Checks to see if you have configured mTLS for the target
	// server.
	Mtls *GoogleCloudApigeeV1ProfileConfigMTLS `json:"mtls,omitempty"`

	// Threat: Checks to see if you have a threat protection policy in
	// place.
	Threat *GoogleCloudApigeeV1ProfileConfigThreat `json:"threat,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Abuse") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Abuse") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ProfileConfigCategory) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ProfileConfigCategory
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ProfileConfigMTLS: Checks to see if you have
// configured mTLS for the target server.
type GoogleCloudApigeeV1ProfileConfigMTLS struct {
}

// GoogleCloudApigeeV1ProfileConfigMediation: By default, following
// policies will be included: - OASValidation - SOAPMessageValidation
type GoogleCloudApigeeV1ProfileConfigMediation struct {
}

// GoogleCloudApigeeV1ProfileConfigThreat: By default, following
// policies will be included: - XMLThreatProtection -
// JSONThreatProtection
type GoogleCloudApigeeV1ProfileConfigThreat struct {
}

// GoogleCloudApigeeV1Properties: Message for compatibility with legacy
// Edge specification for Java Properties object in JSON.
type GoogleCloudApigeeV1Properties struct {
	// Property: List of all properties in the object
	Property []*GoogleCloudApigeeV1Property `json:"property,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Property") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Property") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Properties) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Properties
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1Property: A single property entry in the
// Properties message.
type GoogleCloudApigeeV1Property struct {
	// Name: The property key
	Name string `json:"name,omitempty"`

	// Value: The property value
	Value string `json:"value,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Name") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Name") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Property) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Property
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ProvisionOrganizationRequest: Request for
// ProvisionOrganization.
type GoogleCloudApigeeV1ProvisionOrganizationRequest struct {
	// AnalyticsRegion: Primary Cloud Platform region for analytics data
	// storage. For valid values, see Create an organization
	// (https://cloud.google.com/apigee/docs/hybrid/latest/precog-provision).
	// Defaults to `us-west1`.
	AnalyticsRegion string `json:"analyticsRegion,omitempty"`

	// AuthorizedNetwork: Compute Engine network used for Service Networking
	// to be peered with Apigee runtime instances. See Getting started with
	// the Service Networking API
	// (https://cloud.google.com/service-infrastructure/docs/service-networking/getting-started).
	// Apigee also supports shared VPC (that is, the host network project is
	// not the same as the one that is peering with Apigee). See Shared VPC
	// overview (https://cloud.google.com/vpc/docs/shared-vpc). To use a
	// shared VPC network, use the following format:
	// `projects/{host-project-id}/{region}/networks/{network-name}`. For
	// example: `projects/my-sharedvpc-host/global/networks/mynetwork`
	AuthorizedNetwork string `json:"authorizedNetwork,omitempty"`

	// DisableVpcPeering: Optional. Flag that specifies whether the VPC
	// Peering through Private Google Access should be disabled between the
	// consumer network and Apigee. Required if an authorizedNetwork on the
	// consumer project is not provided, in which case the flag should be
	// set to true. The value must be set before the creation of any Apigee
	// runtime instance and can be updated only when there are no runtime
	// instances. **Note:** Apigee will be deprecating the vpc peering model
	// that requires you to provide 'authorizedNetwork', by making the
	// non-peering model as the default way of provisioning Apigee
	// organization in future. So, this will be a temporary flag to enable
	// the transition. Not supported for Apigee hybrid.
	DisableVpcPeering bool `json:"disableVpcPeering,omitempty"`

	// RuntimeLocation: Cloud Platform location for the runtime instance.
	// Defaults to zone `us-west1-a`. If a region is provided, `EVAL`
	// organizations will use the region for automatically selecting a zone
	// for the runtime instance.
	RuntimeLocation string `json:"runtimeLocation,omitempty"`

	// ForceSendFields is a list of field names (e.g. "AnalyticsRegion") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AnalyticsRegion") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ProvisionOrganizationRequest) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ProvisionOrganizationRequest
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1Query struct {
	// CsvDelimiter: Delimiter used in the CSV file, if `outputFormat` is
	// set to `csv`. Defaults to the `,` (comma) character. Supported
	// delimiter characters include comma (`,`), pipe (`|`), and tab (`\t`).
	CsvDelimiter string `json:"csvDelimiter,omitempty"`

	// Dimensions: A list of dimensions.
	// https://docs.apigee.com/api-platform/analytics/analytics-reference#dimensions
	Dimensions []string `json:"dimensions,omitempty"`

	// EnvgroupHostname: Hostname needs to be specified if query intends to
	// run at host level. This field is only allowed when query is submitted
	// by CreateHostAsyncQuery where analytics data will be grouped by
	// organization and hostname.
	EnvgroupHostname string `json:"envgroupHostname,omitempty"`

	// Filter: Boolean expression that can be used to filter data. Filter
	// expressions can be combined using AND/OR terms and should be fully
	// parenthesized to avoid ambiguity. See Analytics metrics, dimensions,
	// and filters reference
	// https://docs.apigee.com/api-platform/analytics/analytics-reference
	// for more information on the fields available to filter on. For more
	// information on the tokens that you use to build filter expressions,
	// see Filter expression syntax.
	// https://docs.apigee.com/api-platform/analytics/asynch-reports-api#filter-expression-syntax
	Filter string `json:"filter,omitempty"`

	// GroupByTimeUnit: Time unit used to group the result set. Valid values
	// include: second, minute, hour, day, week, or month. If a query
	// includes groupByTimeUnit, then the result is an aggregation based on
	// the specified time unit and the resultant timestamp does not include
	// milliseconds precision. If a query omits groupByTimeUnit, then the
	// resultant timestamp includes milliseconds precision.
	GroupByTimeUnit string `json:"groupByTimeUnit,omitempty"`

	// Limit: Maximum number of rows that can be returned in the result.
	Limit int64 `json:"limit,omitempty"`

	// Metrics: A list of Metrics.
	Metrics []*GoogleCloudApigeeV1QueryMetric `json:"metrics,omitempty"`

	// Name: Asynchronous Query Name.
	Name string `json:"name,omitempty"`

	// OutputFormat: Valid values include: `csv` or `json`. Defaults to
	// `json`. Note: Configure the delimiter for CSV output using the
	// csvDelimiter property.
	OutputFormat string `json:"outputFormat,omitempty"`

	// ReportDefinitionId: Asynchronous Report ID.
	ReportDefinitionId string `json:"reportDefinitionId,omitempty"`

	// TimeRange: Required. Time range for the query. Can use the following
	// predefined strings to specify the time range: `last60minutes`
	// `last24hours` `last7days` Or, specify the timeRange as a structure
	// describing start and end timestamps in the ISO format:
	// yyyy-mm-ddThh:mm:ssZ. Example: "timeRange": { "start":
	// "2018-07-29T00:13:00Z", "end": "2018-08-01T00:18:00Z" }
	TimeRange interface{} `json:"timeRange,omitempty"`

	// ForceSendFields is a list of field names (e.g. "CsvDelimiter") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "CsvDelimiter") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Query) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Query
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1QueryMetadata struct {
	// Dimensions: Dimensions of the AsyncQuery.
	Dimensions []string `json:"dimensions,omitempty"`

	// EndTimestamp: End timestamp of the query range.
	EndTimestamp string `json:"endTimestamp,omitempty"`

	// Metrics: Metrics of the AsyncQuery. Example:
	// ["name:message_count,func:sum,alias:sum_message_count"]
	Metrics []string `json:"metrics,omitempty"`

	// OutputFormat: Output format.
	OutputFormat string `json:"outputFormat,omitempty"`

	// StartTimestamp: Start timestamp of the query range.
	StartTimestamp string `json:"startTimestamp,omitempty"`

	// TimeUnit: Query GroupBy time unit.
	TimeUnit string `json:"timeUnit,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Dimensions") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Dimensions") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1QueryMetadata) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1QueryMetadata
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1QueryMetric: More info about Metric:
// https://docs.apigee.com/api-platform/analytics/analytics-reference#metrics
type GoogleCloudApigeeV1QueryMetric struct {
	// Alias: Alias for the metric. Alias will be used to replace metric
	// name in query results.
	Alias string `json:"alias,omitempty"`

	// Function: Aggregation function: avg, min, max, or sum.
	Function string `json:"function,omitempty"`

	// Name: Required. Metric name.
	Name string `json:"name,omitempty"`

	// Operator: One of `+`, `-`, `/`, `%`, `*`.
	Operator string `json:"operator,omitempty"`

	// Value: Operand value should be provided when operator is set.
	Value string `json:"value,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Alias") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Alias") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1QueryMetric) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1QueryMetric
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1QueryTabularStatsRequest: Request payload
// representing the query to be run for fetching security statistics as
// rows.
type GoogleCloudApigeeV1QueryTabularStatsRequest struct {
	// Dimensions: Required. List of dimension names to group the
	// aggregations by.
	Dimensions []string `json:"dimensions,omitempty"`

	// Filter: Filter further on specific dimension values. Follows the same
	// grammar as custom report's filter expressions. Example, apiproxy eq
	// 'foobar'.
	// https://cloud.google.com/apigee/docs/api-platform/analytics/analytics-reference#filters
	Filter string `json:"filter,omitempty"`

	// Metrics: Required. List of metrics and their aggregations.
	Metrics []*GoogleCloudApigeeV1MetricAggregation `json:"metrics,omitempty"`

	// PageSize: Page size represents the number of rows.
	PageSize int64 `json:"pageSize,omitempty"`

	// PageToken: Identifies a sequence of rows.
	PageToken string `json:"pageToken,omitempty"`

	// TimeRange: Time range for the stats.
	TimeRange *GoogleTypeInterval `json:"timeRange,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Dimensions") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Dimensions") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1QueryTabularStatsRequest) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1QueryTabularStatsRequest
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1QueryTabularStatsResponse: Encapsulates two kinds
// of stats that are results of the dimensions and aggregations
// requested. - Tabular rows. - Time series data. Example of tabular
// rows, Represents security stats results as a row of flat values.
type GoogleCloudApigeeV1QueryTabularStatsResponse struct {
	// Columns: Column names corresponding to the same order as the inner
	// values in the stats field.
	Columns []string `json:"columns,omitempty"`

	// NextPageToken: Next page token.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// Values: Resultant rows from the executed query.
	Values [][]interface{} `json:"values,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Columns") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Columns") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1QueryTabularStatsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1QueryTabularStatsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1QueryTimeSeriesStatsRequest:
// QueryTimeSeriesStatsRequest represents a query that returns a
// collection of time series sequences grouped by their values.
type GoogleCloudApigeeV1QueryTimeSeriesStatsRequest struct {
	// Dimensions: List of dimension names to group the aggregations by. If
	// no dimensions are passed, a single trend line representing the
	// requested metric aggregations grouped by environment is returned.
	Dimensions []string `json:"dimensions,omitempty"`

	// Filter: Filter further on specific dimension values. Follows the same
	// grammar as custom report's filter expressions. Example, apiproxy eq
	// 'foobar'.
	// https://cloud.google.com/apigee/docs/api-platform/analytics/analytics-reference#filters
	Filter string `json:"filter,omitempty"`

	// Metrics: Required. List of metrics and their aggregations.
	Metrics []*GoogleCloudApigeeV1MetricAggregation `json:"metrics,omitempty"`

	// PageSize: Page size represents the number of time series sequences,
	// one per unique set of dimensions and their values.
	PageSize int64 `json:"pageSize,omitempty"`

	// PageToken: Page token stands for a specific collection of time series
	// sequences.
	PageToken string `json:"pageToken,omitempty"`

	// TimeRange: Required. Time range for the stats.
	TimeRange *GoogleTypeInterval `json:"timeRange,omitempty"`

	// TimestampOrder: Order the sequences in increasing or decreasing order
	// of timestamps. Default is descending order of timestamps (latest
	// first).
	//
	// Possible values:
	//   "ORDER_UNSPECIFIED" - Unspecified order. Default is Descending.
	//   "ASCENDING" - Ascending sort order.
	//   "DESCENDING" - Descending sort order.
	TimestampOrder string `json:"timestampOrder,omitempty"`

	// WindowSize: Time buckets to group the stats by.
	//
	// Possible values:
	//   "WINDOW_SIZE_UNSPECIFIED" - Unspecified window size. Default is 1
	// hour.
	//   "MINUTE" - 1 Minute window
	//   "HOUR" - 1 Hour window
	//   "DAY" - 1 Day window
	//   "MONTH" - 1 Month window
	WindowSize string `json:"windowSize,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Dimensions") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Dimensions") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1QueryTimeSeriesStatsRequest) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1QueryTimeSeriesStatsRequest
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1QueryTimeSeriesStatsResponse: Represents security
// stats result as a collection of time series sequences.
type GoogleCloudApigeeV1QueryTimeSeriesStatsResponse struct {
	// Columns: Column names corresponding to the same order as the inner
	// values in the stats field.
	Columns []string `json:"columns,omitempty"`

	// NextPageToken: Next page token.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// Values: Results of the query returned as a JSON array.
	Values []*GoogleCloudApigeeV1QueryTimeSeriesStatsResponseSequence `json:"values,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Columns") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Columns") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1QueryTimeSeriesStatsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1QueryTimeSeriesStatsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1QueryTimeSeriesStatsResponseSequence: A sequence
// of time series.
type GoogleCloudApigeeV1QueryTimeSeriesStatsResponseSequence struct {
	// Dimensions: Map of dimensions and their values that uniquely
	// identifies a time series sequence.
	Dimensions map[string]string `json:"dimensions,omitempty"`

	// Points: List of points. First value of each inner list is a
	// timestamp.
	Points [][]interface{} `json:"points,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Dimensions") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Dimensions") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1QueryTimeSeriesStatsResponseSequence) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1QueryTimeSeriesStatsResponseSequence
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1Quota: Quota contains the essential parameters
// needed that can be applied on the resources, methods, API source
// combination associated with this API product. While Quota is
// optional, setting it prevents requests from exceeding the provisioned
// parameters.
type GoogleCloudApigeeV1Quota struct {
	// Interval: Required. Time interval over which the number of request
	// messages is calculated.
	Interval string `json:"interval,omitempty"`

	// Limit: Required. Upper limit allowed for the time interval and time
	// unit specified. Requests exceeding this limit will be rejected.
	Limit string `json:"limit,omitempty"`

	// TimeUnit: Time unit defined for the `interval`. Valid values include
	// `minute`, `hour`, `day`, or `month`. If `limit` and `interval` are
	// valid, the default value is `hour`; otherwise, the default is null.
	TimeUnit string `json:"timeUnit,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Interval") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Interval") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Quota) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Quota
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1RatePlan: Rate plan details.
type GoogleCloudApigeeV1RatePlan struct {
	// Apiproduct: Name of the API product that the rate plan is associated
	// with.
	Apiproduct string `json:"apiproduct,omitempty"`

	// BillingPeriod: Frequency at which the customer will be billed.
	//
	// Possible values:
	//   "BILLING_PERIOD_UNSPECIFIED" - Billing period not specified.
	//   "WEEKLY" - Weekly billing period. **Note**: Not supported by Apigee
	// at this time.
	//   "MONTHLY" - Monthly billing period.
	BillingPeriod string `json:"billingPeriod,omitempty"`

	// ConsumptionPricingRates: API call volume ranges and the fees charged
	// when the total number of API calls is within a given range. The
	// method used to calculate the final fee depends on the selected
	// pricing model. For example, if the pricing model is `STAIRSTEP` and
	// the ranges are defined as follows: ``` { "start": 1, "end": 100,
	// "fee": 75 }, { "start": 101, "end": 200, "fee": 100 }, } ``` Then the
	// following fees would be charged based on the total number of API
	// calls (assuming the currency selected is `USD`): * 1 call costs $75 *
	// 50 calls cost $75 * 150 calls cost $100 The number of API calls
	// cannot exceed 200.
	ConsumptionPricingRates []*GoogleCloudApigeeV1RateRange `json:"consumptionPricingRates,omitempty"`

	// ConsumptionPricingType: Pricing model used for consumption-based
	// charges.
	//
	// Possible values:
	//   "CONSUMPTION_PRICING_TYPE_UNSPECIFIED" - Pricing model not
	// specified. This is the default.
	//   "FIXED_PER_UNIT" - Fixed rate charged for each API call.
	//   "BANDED" - Variable rate charged for each API call based on price
	// tiers. Example: * 1-100 calls cost $2 per call * 101-200 calls cost
	// $1.50 per call * 201-300 calls cost $1 per call * Total price for 50
	// calls: 50 x $2 = $100 * Total price for 150 calls: 100 x $2 + 50 x
	// $1.5 = $275 * Total price for 250 calls: 100 x $2 + 100 x $1.5 + 50 x
	// $1 = $400. **Note**: Not supported by Apigee at this time.
	//   "TIERED" - **Note**: Not supported by Apigee at this time.
	//   "STAIRSTEP" - **Note**: Not supported by Apigee at this time.
	ConsumptionPricingType string `json:"consumptionPricingType,omitempty"`

	// CreatedAt: Output only. Time that the rate plan was created in
	// milliseconds since epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// CurrencyCode: Currency to be used for billing. Consists of a
	// three-letter code as defined by the ISO 4217
	// (https://en.wikipedia.org/wiki/ISO_4217) standard.
	CurrencyCode string `json:"currencyCode,omitempty"`

	// Description: Description of the rate plan.
	Description string `json:"description,omitempty"`

	// DisplayName: Display name of the rate plan.
	DisplayName string `json:"displayName,omitempty"`

	// EndTime: Time when the rate plan will expire in milliseconds since
	// epoch. Set to 0 or `null` to indicate that the rate plan should never
	// expire.
	EndTime int64 `json:"endTime,omitempty,string"`

	// FixedFeeFrequency: Frequency at which the fixed fee is charged.
	FixedFeeFrequency int64 `json:"fixedFeeFrequency,omitempty"`

	// FixedRecurringFee: Fixed amount that is charged at a defined interval
	// and billed in advance of use of the API product. The fee will be
	// prorated for the first billing period.
	FixedRecurringFee *GoogleTypeMoney `json:"fixedRecurringFee,omitempty"`

	// LastModifiedAt: Output only. Time the rate plan was last modified in
	// milliseconds since epoch.
	LastModifiedAt int64 `json:"lastModifiedAt,omitempty,string"`

	// Name: Output only. Name of the rate plan.
	Name string `json:"name,omitempty"`

	// PaymentFundingModel: DEPRECATED: This field is no longer supported
	// and will eventually be removed when Apigee Hybrid 1.5/1.6 is no
	// longer supported. Instead, use the `billingType` field inside
	// `DeveloperMonetizationConfig` resource. Flag that specifies the
	// billing account type, prepaid or postpaid.
	//
	// Possible values:
	//   "PAYMENT_FUNDING_MODEL_UNSPECIFIED" - Billing account type not
	// specified.
	//   "PREPAID" - Prepaid billing account type. Developer pays in advance
	// for the use of your API products. Funds are deducted from their
	// prepaid account balance. **Note**: Not supported by Apigee at this
	// time.
	//   "POSTPAID" - Postpaid billing account type. Developer is billed
	// through an invoice after using your API products.
	PaymentFundingModel string `json:"paymentFundingModel,omitempty"`

	// RevenueShareRates: Details of the revenue sharing model.
	RevenueShareRates []*GoogleCloudApigeeV1RevenueShareRange `json:"revenueShareRates,omitempty"`

	// RevenueShareType: Method used to calculate the revenue that is shared
	// with developers.
	//
	// Possible values:
	//   "REVENUE_SHARE_TYPE_UNSPECIFIED" - Revenue share type is not
	// specified.
	//   "FIXED" - Fixed percentage of the total revenue will be shared. The
	// percentage to be shared can be configured by the API provider.
	//   "VOLUME_BANDED" - Amount of revenue shared depends on the number of
	// API calls. The API call volume ranges and the revenue share
	// percentage for each volume can be configured by the API provider.
	// **Note**: Not supported by Apigee at this time.
	RevenueShareType string `json:"revenueShareType,omitempty"`

	// SetupFee: Initial, one-time fee paid when purchasing the API product.
	SetupFee *GoogleTypeMoney `json:"setupFee,omitempty"`

	// StartTime: Time when the rate plan becomes active in milliseconds
	// since epoch.
	StartTime int64 `json:"startTime,omitempty,string"`

	// State: Current state of the rate plan (draft or published).
	//
	// Possible values:
	//   "STATE_UNSPECIFIED" - State of the rate plan is not specified.
	//   "DRAFT" - Rate plan is in draft mode and only visible to API
	// providers.
	//   "PUBLISHED" - Rate plan is published and will become visible to
	// developers for the configured duration (between `startTime` and
	// `endTime`).
	State string `json:"state,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Apiproduct") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Apiproduct") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1RatePlan) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1RatePlan
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1RateRange: API call volume range and the fees
// charged when the total number of API calls is within the range.
type GoogleCloudApigeeV1RateRange struct {
	// End: Ending value of the range. Set to 0 or `null` for the last range
	// of values.
	End int64 `json:"end,omitempty,string"`

	// Fee: Fee to charge when total number of API calls falls within this
	// range.
	Fee *GoogleTypeMoney `json:"fee,omitempty"`

	// Start: Starting value of the range. Set to 0 or `null` for the
	// initial range of values.
	Start int64 `json:"start,omitempty,string"`

	// ForceSendFields is a list of field names (e.g. "End") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "End") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1RateRange) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1RateRange
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1Reference: A Reference configuration. References
// must refer to a keystore that also exists in the parent environment.
type GoogleCloudApigeeV1Reference struct {
	// Description: Optional. A human-readable description of this
	// reference.
	Description string `json:"description,omitempty"`

	// Name: Required. The resource id of this reference. Values must match
	// the regular expression [\w\s\-.]+.
	Name string `json:"name,omitempty"`

	// Refers: Required. The id of the resource to which this reference
	// refers. Must be the id of a resource that exists in the parent
	// environment and is of the given resource_type.
	Refers string `json:"refers,omitempty"`

	// ResourceType: The type of resource referred to by this reference.
	// Valid values are 'KeyStore' or 'TrustStore'.
	ResourceType string `json:"resourceType,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Description") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Description") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Reference) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Reference
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1ReferenceConfig struct {
	// Name: Name of the reference in the following format:
	// `organizations/{org}/environments/{env}/references/{reference}`
	Name string `json:"name,omitempty"`

	// ResourceName: Name of the referenced resource in the following
	// format: `organizations/{org}/environments/{env}/keystores/{keystore}`
	// Only references to keystore resources are supported.
	ResourceName string `json:"resourceName,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Name") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Name") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ReferenceConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ReferenceConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ReportInstanceStatusRequest: Request for
// ReportInstanceStatus.
type GoogleCloudApigeeV1ReportInstanceStatusRequest struct {
	// InstanceUid: A unique ID for the instance which is guaranteed to be
	// unique in case the user installs multiple hybrid runtimes with the
	// same instance ID.
	InstanceUid string `json:"instanceUid,omitempty"`

	// ReportTime: The time the report was generated in the runtime. Used to
	// prevent an old status from overwriting a newer one. An instance
	// should space out it's status reports so that clock skew does not play
	// a factor.
	ReportTime string `json:"reportTime,omitempty"`

	// Resources: Status for config resources
	Resources []*GoogleCloudApigeeV1ResourceStatus `json:"resources,omitempty"`

	// ForceSendFields is a list of field names (e.g. "InstanceUid") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "InstanceUid") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ReportInstanceStatusRequest) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ReportInstanceStatusRequest
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ReportInstanceStatusResponse: Placeholder for
// future enhancements to status reporting protocol
type GoogleCloudApigeeV1ReportInstanceStatusResponse struct {
	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`
}

type GoogleCloudApigeeV1ReportProperty struct {
	// Property: name of the property
	Property string `json:"property,omitempty"`

	// Value: property values
	Value []*GoogleCloudApigeeV1Attribute `json:"value,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Property") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Property") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ReportProperty) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ReportProperty
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1ResourceConfig struct {
	// Location: Location of the resource as a URI.
	Location string `json:"location,omitempty"`

	// Name: Resource name in the following format:
	// `organizations/{org}/environments/{env}/resourcefiles/{type}/{file}/re
	// visions/{rev}` Only environment-scoped resource files are supported.
	Name string `json:"name,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Location") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Location") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ResourceConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ResourceConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ResourceFile: Metadata about a resource file.
type GoogleCloudApigeeV1ResourceFile struct {
	// Name: ID of the resource file.
	Name string `json:"name,omitempty"`

	// Type: Resource file type. {{ resource_file_type }}
	Type string `json:"type,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Name") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Name") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ResourceFile) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ResourceFile
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ResourceFiles: List of resource files.
type GoogleCloudApigeeV1ResourceFiles struct {
	// ResourceFile: List of resource files.
	ResourceFile []*GoogleCloudApigeeV1ResourceFile `json:"resourceFile,omitempty"`

	// ForceSendFields is a list of field names (e.g. "ResourceFile") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ResourceFile") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ResourceFiles) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ResourceFiles
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ResourceStatus: The status of a resource loaded in
// the runtime.
type GoogleCloudApigeeV1ResourceStatus struct {
	// Resource: The resource name. Currently only two resources are
	// supported: EnvironmentGroup -
	// organizations/{org}/envgroups/{envgroup} EnvironmentConfig -
	// organizations/{org}/environments/{environment}/deployedConfig
	Resource string `json:"resource,omitempty"`

	// Revisions: Revisions of the resource currently deployed in the
	// instance.
	Revisions []*GoogleCloudApigeeV1RevisionStatus `json:"revisions,omitempty"`

	// TotalReplicas: The total number of replicas that should have this
	// resource.
	TotalReplicas int64 `json:"totalReplicas,omitempty"`

	// Uid: The uid of the resource. In the unexpected case that the
	// instance has multiple uids for the same name, they should be reported
	// under separate ResourceStatuses.
	Uid string `json:"uid,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Resource") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Resource") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ResourceStatus) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ResourceStatus
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1Result: Result is short for "action result", could
// be different types identified by "action_result" field. Supported
// types: 1. DebugInfo : generic debug info collected by runtime
// recorded as a list of properties. For example, the contents could be
// virtual host info, state change result, or execution metadata.
// Required fields : properties, timestamp 2. RequestMessage:
// information of a http request. Contains headers, request URI and http
// methods type.Required fields : headers, uri, verb 3. ResponseMessage:
// information of a http response. Contains headers, reason phrase and
// http status code. Required fields : headers, reasonPhrase, statusCode
// 4. ErrorMessage: information of a http error message. Contains detail
// error message, reason phrase and status code. Required fields :
// content, headers, reasonPhrase, statusCode 5. VariableAccess: a list
// of variable access actions, can be Get, Set and Remove. Required
// fields : accessList
type GoogleCloudApigeeV1Result struct {
	// ActionResult: Type of the action result. Can be one of the five:
	// DebugInfo, RequestMessage, ResponseMessage, ErrorMessage,
	// VariableAccess
	ActionResult string `json:"ActionResult,omitempty"`

	// AccessList: A list of variable access actions agaist the api proxy.
	// Supported values: Get, Set, Remove.
	AccessList []*GoogleCloudApigeeV1Access `json:"accessList,omitempty"`

	// Content: Error message content. for example, "content" :
	// "{\"fault\":{\"faultstring\":\"API timed
	// out\",\"detail\":{\"errorcode\":\"flow.APITimedOut\"}}}"
	Content string `json:"content,omitempty"`

	// Headers: A list of HTTP headers. for example, '"headers" : [ { "name"
	// : "Content-Length", "value" : "83" }, { "name" : "Content-Type",
	// "value" : "application/json" } ]'
	Headers []*GoogleCloudApigeeV1Property `json:"headers,omitempty"`

	// Properties: Name value pairs used for DebugInfo ActionResult.
	Properties *GoogleCloudApigeeV1Properties `json:"properties,omitempty"`

	// ReasonPhrase: HTTP response phrase
	ReasonPhrase string `json:"reasonPhrase,omitempty"`

	// StatusCode: HTTP response code
	StatusCode string `json:"statusCode,omitempty"`

	// Timestamp: Timestamp of when the result is recorded. Its format is
	// dd-mm-yy hh:mm:ss:xxx. For example, "timestamp" : "12-08-19
	// 00:31:59:960"
	Timestamp string `json:"timestamp,omitempty"`

	// URI: The relative path of the api proxy. for example, "uRI" :
	// "/iloveapis"
	URI string `json:"uRI,omitempty"`

	// Verb: HTTP method verb
	Verb string `json:"verb,omitempty"`

	// ForceSendFields is a list of field names (e.g. "ActionResult") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ActionResult") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Result) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Result
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1RevenueShareRange: API call volume range and the
// percentage of revenue to share with the developer when the total
// number of API calls is within the range.
type GoogleCloudApigeeV1RevenueShareRange struct {
	// End: Ending value of the range. Set to 0 or `null` for the last range
	// of values.
	End int64 `json:"end,omitempty,string"`

	// SharePercentage: Percentage of the revenue to be shared with the
	// developer. For example, to share 21 percent of the total revenue with
	// the developer, set this value to 21. Specify a decimal number with a
	// maximum of two digits following the decimal point.
	SharePercentage float64 `json:"sharePercentage,omitempty"`

	// Start: Starting value of the range. Set to 0 or `null` for the
	// initial range of values.
	Start int64 `json:"start,omitempty,string"`

	// ForceSendFields is a list of field names (e.g. "End") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "End") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1RevenueShareRange) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1RevenueShareRange
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

func (s *GoogleCloudApigeeV1RevenueShareRange) UnmarshalJSON(data []byte) error {
	type NoMethod GoogleCloudApigeeV1RevenueShareRange
	var s1 struct {
		SharePercentage gensupport.JSONFloat64 `json:"sharePercentage"`
		*NoMethod
	}
	s1.NoMethod = (*NoMethod)(s)
	if err := json.Unmarshal(data, &s1); err != nil {
		return err
	}
	s.SharePercentage = float64(s1.SharePercentage)
	return nil
}

// GoogleCloudApigeeV1RevisionStatus: The status of a specific resource
// revision.
type GoogleCloudApigeeV1RevisionStatus struct {
	// Errors: Errors reported when attempting to load this revision.
	Errors []*GoogleCloudApigeeV1UpdateError `json:"errors,omitempty"`

	// JsonSpec: The json content of the resource revision. Large specs
	// should be sent individually via the spec field to avoid hitting
	// request size limits.
	JsonSpec string `json:"jsonSpec,omitempty"`

	// Replicas: The number of replicas that have successfully loaded this
	// revision.
	Replicas int64 `json:"replicas,omitempty"`

	// RevisionId: The revision of the resource.
	RevisionId string `json:"revisionId,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Errors") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Errors") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1RevisionStatus) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1RevisionStatus
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1RoutingRule struct {
	// Basepath: URI path prefix used to route to the specified environment.
	// May contain one or more wildcards. For example, path segments
	// consisting of a single `*` character will match any string.
	Basepath string `json:"basepath,omitempty"`

	// DeploymentGroup: Name of a deployment group in an environment bound
	// to the environment group in the following format:
	// `organizations/{org}/environment/{env}/deploymentGroups/{group}` Only
	// one of environment or deployment_group will be set.
	DeploymentGroup string `json:"deploymentGroup,omitempty"`

	// EnvGroupRevision: The env group config revision_id when this rule was
	// added or last updated. This value is set when the rule is created and
	// will only update if the the environment_id changes. It is used to
	// determine if the runtime is up to date with respect to this rule.
	// This field is omitted from the IngressConfig unless the
	// GetDeployedIngressConfig API is called with view=FULL.
	EnvGroupRevision int64 `json:"envGroupRevision,omitempty,string"`

	// Environment: Name of an environment bound to the environment group in
	// the following format: `organizations/{org}/environments/{env}`. Only
	// one of environment or deployment_group will be set.
	Environment string `json:"environment,omitempty"`

	// OtherTargets: Conflicting targets, which will be resource names
	// specifying either deployment groups or environments.
	OtherTargets []string `json:"otherTargets,omitempty"`

	// Receiver: The resource name of the proxy revision that is receiving
	// this basepath in the following format:
	// `organizations/{org}/apis/{api}/revisions/{rev}`. This field is
	// omitted from the IngressConfig unless the GetDeployedIngressConfig
	// API is called with view=FULL.
	Receiver string `json:"receiver,omitempty"`

	// UpdateTime: The unix timestamp when this rule was updated. This is
	// updated whenever env_group_revision is updated. This field is omitted
	// from the IngressConfig unless the GetDeployedIngressConfig API is
	// called with view=FULL.
	UpdateTime string `json:"updateTime,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Basepath") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Basepath") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1RoutingRule) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1RoutingRule
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1RuntimeAddonsConfig: RuntimeAddonsConfig defines
// the runtime configurations for add-ons in an environment.
type GoogleCloudApigeeV1RuntimeAddonsConfig struct {
	// AnalyticsConfig: Runtime configuration for Analytics add-on.
	AnalyticsConfig *GoogleCloudApigeeV1RuntimeAnalyticsConfig `json:"analyticsConfig,omitempty"`

	// ApiSecurityConfig: Runtime configuration for API Security add-on.
	ApiSecurityConfig *GoogleCloudApigeeV1RuntimeApiSecurityConfig `json:"apiSecurityConfig,omitempty"`

	// Name: Name of the addons config in the format:
	// `organizations/{org}/environments/{env}/addonsConfig`
	Name string `json:"name,omitempty"`

	// RevisionId: Revision number used by the runtime to detect config
	// changes.
	RevisionId string `json:"revisionId,omitempty"`

	// Uid: UID is to detect if config is recreated after deletion. The
	// add-on config will only be deleted when the environment itself gets
	// deleted, thus it will always be the same as the UID of
	// EnvironmentConfig.
	Uid string `json:"uid,omitempty"`

	// ForceSendFields is a list of field names (e.g. "AnalyticsConfig") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AnalyticsConfig") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1RuntimeAddonsConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1RuntimeAddonsConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1RuntimeAnalyticsConfig: Runtime configuration for
// the Analytics add-on.
type GoogleCloudApigeeV1RuntimeAnalyticsConfig struct {
	// BillingPipelineEnabled: If Runtime should send billing data to AX or
	// not.
	BillingPipelineEnabled bool `json:"billingPipelineEnabled,omitempty"`

	// Enabled: If the Analytics is enabled or not.
	Enabled bool `json:"enabled,omitempty"`

	// ForceSendFields is a list of field names (e.g.
	// "BillingPipelineEnabled") to unconditionally include in API requests.
	// By default, fields with empty or default values are omitted from API
	// requests. However, any non-pointer, non-interface field appearing in
	// ForceSendFields will be sent to the server regardless of whether the
	// field is empty or not. This may be used to include empty fields in
	// Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "BillingPipelineEnabled")
	// to include in API requests with the JSON null value. By default,
	// fields with empty values are omitted from API requests. However, any
	// field with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1RuntimeAnalyticsConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1RuntimeAnalyticsConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1RuntimeApiSecurityConfig: Runtime configuration
// for the API Security add-on.
type GoogleCloudApigeeV1RuntimeApiSecurityConfig struct {
	// Enabled: If the API Security is enabled or not.
	Enabled bool `json:"enabled,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Enabled") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Enabled") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1RuntimeApiSecurityConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1RuntimeApiSecurityConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1RuntimeConfig: Runtime configuration for the
// organization. Response for GetRuntimeConfig.
type GoogleCloudApigeeV1RuntimeConfig struct {
	// AnalyticsBucket: Cloud Storage bucket used for uploading Analytics
	// records.
	AnalyticsBucket string `json:"analyticsBucket,omitempty"`

	// Name: Name of the resource in the following format:
	// `organizations/{org}/runtimeConfig`.
	Name string `json:"name,omitempty"`

	// TenantProjectId: Output only. Tenant project ID associated with the
	// Apigee organization. The tenant project is used to host
	// Google-managed resources that are dedicated to this Apigee
	// organization. Clients have limited access to resources within the
	// tenant project used to support Apigee runtime instances. Access to
	// the tenant project is managed using SetSyncAuthorization. It can be
	// empty if the tenant project hasn't been created yet.
	TenantProjectId string `json:"tenantProjectId,omitempty"`

	// TraceBucket: Cloud Storage bucket used for uploading Trace records.
	TraceBucket string `json:"traceBucket,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "AnalyticsBucket") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AnalyticsBucket") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1RuntimeConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1RuntimeConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1RuntimeTraceConfig: NEXT ID: 8 RuntimeTraceConfig
// defines the configurations for distributed trace in an environment.
type GoogleCloudApigeeV1RuntimeTraceConfig struct {
	// Endpoint: Endpoint of the exporter.
	Endpoint string `json:"endpoint,omitempty"`

	// Exporter: Exporter that is used to view the distributed trace
	// captured using OpenCensus. An exporter sends traces to any backend
	// that is capable of consuming them. Recorded spans can be exported by
	// registered exporters.
	//
	// Possible values:
	//   "EXPORTER_UNSPECIFIED" - Exporter unspecified
	//   "JAEGER" - Jaeger exporter
	//   "CLOUD_TRACE" - Cloudtrace exporter
	Exporter string `json:"exporter,omitempty"`

	// Name: Name of the trace config in the following format:
	// `organizations/{org}/environment/{env}/traceConfig`
	Name string `json:"name,omitempty"`

	// Overrides: List of trace configuration overrides for spicific API
	// proxies.
	Overrides []*GoogleCloudApigeeV1RuntimeTraceConfigOverride `json:"overrides,omitempty"`

	// RevisionCreateTime: The timestamp that the revision was created or
	// updated.
	RevisionCreateTime string `json:"revisionCreateTime,omitempty"`

	// RevisionId: Revision number which can be used by the runtime to
	// detect if the trace config has changed between two versions.
	RevisionId string `json:"revisionId,omitempty"`

	// SamplingConfig: Trace configuration for all API proxies in an
	// environment.
	SamplingConfig *GoogleCloudApigeeV1RuntimeTraceSamplingConfig `json:"samplingConfig,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Endpoint") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Endpoint") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1RuntimeTraceConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1RuntimeTraceConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1RuntimeTraceConfigOverride: NEXT ID: 7 Trace
// configuration override for a specific API proxy in an environment.
type GoogleCloudApigeeV1RuntimeTraceConfigOverride struct {
	// ApiProxy: Name of the API proxy that will have its trace
	// configuration overridden following format:
	// `organizations/{org}/apis/{api}`
	ApiProxy string `json:"apiProxy,omitempty"`

	// Name: Name of the trace config override in the following format:
	// `organizations/{org}/environment/{env}/traceConfig/overrides/{override
	// }`
	Name string `json:"name,omitempty"`

	// RevisionCreateTime: The timestamp that the revision was created or
	// updated.
	RevisionCreateTime string `json:"revisionCreateTime,omitempty"`

	// RevisionId: Revision number which can be used by the runtime to
	// detect if the trace config override has changed between two versions.
	RevisionId string `json:"revisionId,omitempty"`

	// SamplingConfig: Trace configuration override for a specific API proxy
	// in an environment.
	SamplingConfig *GoogleCloudApigeeV1RuntimeTraceSamplingConfig `json:"samplingConfig,omitempty"`

	// Uid: Unique ID for the configuration override. The ID will only
	// change if the override is deleted and recreated. Corresponds to
	// name's "override" field.
	Uid string `json:"uid,omitempty"`

	// ForceSendFields is a list of field names (e.g. "ApiProxy") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ApiProxy") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1RuntimeTraceConfigOverride) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1RuntimeTraceConfigOverride
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1RuntimeTraceSamplingConfig: NEXT ID: 3
// RuntimeTraceSamplingConfig represents the detail settings of
// distributed tracing. Only the fields that are defined in the
// distributed trace configuration can be overridden using the
// distribute trace configuration override APIs.
type GoogleCloudApigeeV1RuntimeTraceSamplingConfig struct {
	// Sampler: Sampler of distributed tracing. OFF is the default value.
	//
	// Possible values:
	//   "SAMPLER_UNSPECIFIED" - Sampler unspecified.
	//   "OFF" - OFF means distributed trace is disabled, or the sampling
	// probability is 0.
	//   "PROBABILITY" - PROBABILITY means traces are captured on a
	// probability that defined by sampling_rate. The sampling rate is
	// limited to 0 to 0.5 when this is set.
	Sampler string `json:"sampler,omitempty"`

	// SamplingRate: Field sampling rate. This value is only applicable when
	// using the PROBABILITY sampler. The supported values are > 0 and <=
	// 0.5.
	SamplingRate float64 `json:"samplingRate,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Sampler") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Sampler") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1RuntimeTraceSamplingConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1RuntimeTraceSamplingConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

func (s *GoogleCloudApigeeV1RuntimeTraceSamplingConfig) UnmarshalJSON(data []byte) error {
	type NoMethod GoogleCloudApigeeV1RuntimeTraceSamplingConfig
	var s1 struct {
		SamplingRate gensupport.JSONFloat64 `json:"samplingRate"`
		*NoMethod
	}
	s1.NoMethod = (*NoMethod)(s)
	if err := json.Unmarshal(data, &s1); err != nil {
		return err
	}
	s.SamplingRate = float64(s1.SamplingRate)
	return nil
}

// GoogleCloudApigeeV1Schema: Response for Schema call
type GoogleCloudApigeeV1Schema struct {
	// Dimensions: List of schema fields grouped as dimensions.
	Dimensions []*GoogleCloudApigeeV1SchemaSchemaElement `json:"dimensions,omitempty"`

	// Meta: Additional metadata associated with schema. This is a legacy
	// field and usually consists of an empty array of strings.
	Meta []string `json:"meta,omitempty"`

	// Metrics: List of schema fields grouped as dimensions that can be used
	// with an aggregate function such as `sum`, `avg`, `min`, and `max`.
	Metrics []*GoogleCloudApigeeV1SchemaSchemaElement `json:"metrics,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Dimensions") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Dimensions") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Schema) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Schema
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SchemaSchemaElement: Message type for the schema
// element
type GoogleCloudApigeeV1SchemaSchemaElement struct {
	// Name: Name of the field.
	Name string `json:"name,omitempty"`

	// Properties: Properties for the schema field. For example: {
	// "createTime": "2016-02-26T10:23:09.592Z", "custom": "false", "type":
	// "string" }
	Properties *GoogleCloudApigeeV1SchemaSchemaProperty `json:"properties,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Name") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Name") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SchemaSchemaElement) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SchemaSchemaElement
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SchemaSchemaProperty: Properties for the schema
// field.
type GoogleCloudApigeeV1SchemaSchemaProperty struct {
	// CreateTime: Time the field was created in RFC3339 string form. For
	// example: `2016-02-26T10:23:09.592Z`.
	CreateTime string `json:"createTime,omitempty"`

	// Custom: Flag that specifies whether the field is standard in the
	// dataset or a custom field created by the customer. `true` indicates
	// that it is a custom field.
	Custom string `json:"custom,omitempty"`

	// Type: Data type of the field.
	Type string `json:"type,omitempty"`

	// ForceSendFields is a list of field names (e.g. "CreateTime") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "CreateTime") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SchemaSchemaProperty) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SchemaSchemaProperty
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1Score: Represents Security Score.
type GoogleCloudApigeeV1Score struct {
	// Component: Component containing score, recommendations and actions.
	Component *GoogleCloudApigeeV1ScoreComponent `json:"component,omitempty"`

	// Subcomponents: List of all the drilldown score components.
	Subcomponents []*GoogleCloudApigeeV1ScoreComponent `json:"subcomponents,omitempty"`

	// TimeRange: Start and end time for the score.
	TimeRange *GoogleTypeInterval `json:"timeRange,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Component") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Component") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Score) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Score
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ScoreComponent: Component is an individual
// security element that is scored.
type GoogleCloudApigeeV1ScoreComponent struct {
	// CalculateTime: Time when score was calculated.
	CalculateTime string `json:"calculateTime,omitempty"`

	// DataCaptureTime: Time in the requested time period when data was last
	// captured to compute the score.
	DataCaptureTime string `json:"dataCaptureTime,omitempty"`

	// DrilldownPaths: List of paths for next components.
	DrilldownPaths []string `json:"drilldownPaths,omitempty"`

	// Recommendations: List of recommendations to improve API security.
	Recommendations []*GoogleCloudApigeeV1ScoreComponentRecommendation `json:"recommendations,omitempty"`

	// Score: Score for the component.
	Score int64 `json:"score,omitempty"`

	// ScorePath: Path of the component. Example:
	// /org@myorg/envgroup@myenvgroup/proxies/proxy@myproxy
	ScorePath string `json:"scorePath,omitempty"`

	// ForceSendFields is a list of field names (e.g. "CalculateTime") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "CalculateTime") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ScoreComponent) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ScoreComponent
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ScoreComponentRecommendation: Recommendation based
// on security concerns and score.
type GoogleCloudApigeeV1ScoreComponentRecommendation struct {
	// Actions: Actions for the recommendation to improve the security
	// score.
	Actions []*GoogleCloudApigeeV1ScoreComponentRecommendationAction `json:"actions,omitempty"`

	// Description: Description of the recommendation.
	Description string `json:"description,omitempty"`

	// Impact: Potential impact of this recommendation on the overall score.
	// This denotes how important this recommendation is to improve the
	// score.
	Impact int64 `json:"impact,omitempty"`

	// Title: Title represents recommendation title.
	Title string `json:"title,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Actions") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Actions") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ScoreComponentRecommendation) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ScoreComponentRecommendation
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ScoreComponentRecommendationAction: Action to
// improve security score.
type GoogleCloudApigeeV1ScoreComponentRecommendationAction struct {
	// ActionContext: Action context for the action.
	ActionContext *GoogleCloudApigeeV1ScoreComponentRecommendationActionActionContext `json:"actionContext,omitempty"`

	// Description: Description of the action.
	Description string `json:"description,omitempty"`

	// ForceSendFields is a list of field names (e.g. "ActionContext") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ActionContext") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ScoreComponentRecommendationAction) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ScoreComponentRecommendationAction
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1ScoreComponentRecommendationActionActionContext:
// Action context are all the relevant details for the action.
type GoogleCloudApigeeV1ScoreComponentRecommendationActionActionContext struct {
	// DocumentationLink: Documentation link for the action.
	DocumentationLink string `json:"documentationLink,omitempty"`

	// ForceSendFields is a list of field names (e.g. "DocumentationLink")
	// to unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "DocumentationLink") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ScoreComponentRecommendationActionActionContext) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ScoreComponentRecommendationActionActionContext
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecurityAction: A SecurityAction is rule that can
// be enforced at an environment level. The result is one of: - A denied
// API call - An explicitly allowed API call - A flagged API call (HTTP
// headers added before the target receives it) At least one condition
// is required to create a SecurityAction.
type GoogleCloudApigeeV1SecurityAction struct {
	// Allow: Allow a request through if it matches this SecurityAction.
	Allow *GoogleCloudApigeeV1SecurityActionAllow `json:"allow,omitempty"`

	// ConditionConfig: Required. A valid SecurityAction must contain at
	// least one condition.
	ConditionConfig *GoogleCloudApigeeV1SecurityActionConditionConfig `json:"conditionConfig,omitempty"`

	// CreateTime: Output only. The create time for this SecurityAction.
	CreateTime string `json:"createTime,omitempty"`

	// Deny: Deny a request through if it matches this SecurityAction.
	Deny *GoogleCloudApigeeV1SecurityActionDeny `json:"deny,omitempty"`

	// Description: Optional. An optional user provided description of the
	// SecurityAction.
	Description string `json:"description,omitempty"`

	// ExpireTime: The expiration for this SecurityAction.
	ExpireTime string `json:"expireTime,omitempty"`

	// Flag: Flag a request through if it matches this SecurityAction.
	Flag *GoogleCloudApigeeV1SecurityActionFlag `json:"flag,omitempty"`

	// Name: Immutable. This field is ignored during creation as per
	// AIP-133. Please set the `security_action_id` field in the
	// CreateSecurityActionRequest when creating a new SecurityAction.
	// Format:
	// organizations/{org}/environments/{env}/securityActions/{security_actio
	// n}
	Name string `json:"name,omitempty"`

	// State: Required. Only an ENABLED SecurityAction is enforced. An
	// ENABLED SecurityAction past its expiration time will not be enforced.
	//
	// Possible values:
	//   "STATE_UNSPECIFIED" - The default value. This only exists for
	// forward compatibility. A create request with this value will be
	// rejected.
	//   "ENABLED" - An ENABLED SecurityAction is actively enforced if the
	// `expiration_time` is in the future.
	//   "DISABLED" - A disabled SecurityAction is never enforced.
	State string `json:"state,omitempty"`

	// Ttl: Input only. The TTL for this SecurityAction.
	Ttl string `json:"ttl,omitempty"`

	// UpdateTime: Output only. The update time for this SecurityAction.
	// This reflects when this SecurityAction changed states.
	UpdateTime string `json:"updateTime,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Allow") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Allow") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecurityAction) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecurityAction
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecurityActionAllow: Message that should be set in
// case of an Allow Action. This does not have any fields.
type GoogleCloudApigeeV1SecurityActionAllow struct {
}

// GoogleCloudApigeeV1SecurityActionConditionConfig: The following are a
// list of conditions. A valid SecurityAction must contain at least one
// condition. Within a condition, each element is ORed. Across
// conditions elements are ANDed. For example if a SecurityAction has
// the following: ip_address_ranges: ["ip1", "ip2"] and bot_reasons:
// ["Flooder", "Robot Abuser"] then this is interpreted as: enforce the
// action if the incoming request has ((ip_address_ranges = "ip1" OR
// ip_address_ranges = "ip2") AND (bot_reasons="Flooder" OR
// bot_reasons="Robot Abuser")). Conditions other than ip_address_ranges
// and bot_reasons cannot be ANDed.
type GoogleCloudApigeeV1SecurityActionConditionConfig struct {
	// AccessTokens: Optional. A list of access_tokens. Limit 1000 per
	// action.
	AccessTokens []string `json:"accessTokens,omitempty"`

	// ApiKeys: Optional. A list of API keys. Limit 1000 per action.
	ApiKeys []string `json:"apiKeys,omitempty"`

	// ApiProducts: Optional. A list of API Products. Limit 1000 per action.
	ApiProducts []string `json:"apiProducts,omitempty"`

	// BotReasons: Optional. A list of Bot Reasons. Current options:
	// Flooder, Brute Guessor, Static Content Scraper, OAuth Abuser, Robot
	// Abuser, TorListRule, Advanced Anomaly Detection, Advanced API
	// Scraper, Search Engine Crawlers, Public Clouds, Public Cloud AWS,
	// Public Cloud Azure, and Public Cloud Google.
	BotReasons []string `json:"botReasons,omitempty"`

	// DeveloperApps: Optional. A list of developer apps. Limit 1000 per
	// action.
	DeveloperApps []string `json:"developerApps,omitempty"`

	// Developers: Optional. A list of developers. Limit 1000 per action.
	Developers []string `json:"developers,omitempty"`

	// IpAddressRanges: Optional. A list of IP addresses. This could be
	// either IPv4 or IPv6. Limited to 100 per action.
	IpAddressRanges []string `json:"ipAddressRanges,omitempty"`

	// UserAgents: Optional. A list of user agents to deny. We look for
	// exact matches. Limit 50 per action.
	UserAgents []string `json:"userAgents,omitempty"`

	// ForceSendFields is a list of field names (e.g. "AccessTokens") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AccessTokens") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecurityActionConditionConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecurityActionConditionConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecurityActionDeny: Message that should be set in
// case of a Deny Action.
type GoogleCloudApigeeV1SecurityActionDeny struct {
	// ResponseCode: Optional. The HTTP response code if the Action = DENY.
	ResponseCode int64 `json:"responseCode,omitempty"`

	// ForceSendFields is a list of field names (e.g. "ResponseCode") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ResponseCode") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecurityActionDeny) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecurityActionDeny
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecurityActionFlag: The message that should be set
// in the case of a Flag action.
type GoogleCloudApigeeV1SecurityActionFlag struct {
	// Headers: Optional. A list of HTTP headers to be sent to the target in
	// case of a FLAG SecurityAction. Limit 5 headers per SecurityAction. At
	// least one is mandatory.
	Headers []*GoogleCloudApigeeV1SecurityActionHttpHeader `json:"headers,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Headers") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Headers") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecurityActionFlag) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecurityActionFlag
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecurityActionHttpHeader: An HTTP header.
type GoogleCloudApigeeV1SecurityActionHttpHeader struct {
	// Name: The header name to be sent to the target.
	Name string `json:"name,omitempty"`

	// Value: The header value to be sent to the target.
	Value string `json:"value,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Name") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Name") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecurityActionHttpHeader) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecurityActionHttpHeader
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecurityActionsConfig: SecurityActionsConfig
// reflects the current state of the SecurityActions feature. This is a
// singleton resource: https://google.aip.dev/156
type GoogleCloudApigeeV1SecurityActionsConfig struct {
	// Enabled: The flag that controls whether this feature is enabled. This
	// is `unset` by default. When this flag is `false`, even if individual
	// rules are enabled, no SecurityActions will be enforced.
	Enabled bool `json:"enabled,omitempty"`

	// Name: This is a singleton resource, the name will always be set by
	// SecurityActions and any user input will be ignored. The name is
	// always:
	// `organizations/{org}/environments/{env}/security_actions_config`
	Name string `json:"name,omitempty"`

	// UpdateTime: Output only. The update time for configuration.
	UpdateTime string `json:"updateTime,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Enabled") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Enabled") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecurityActionsConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecurityActionsConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecurityIncident: Represents an SecurityIncident
// resource.
type GoogleCloudApigeeV1SecurityIncident struct {
	// DetectionTypes: Output only. Detection types which are part of the
	// incident. Examples: Flooder, OAuth Abuser, Static Content Scraper,
	// Anomaly Detection.
	DetectionTypes []string `json:"detectionTypes,omitempty"`

	// DisplayName: Optional. Display name of the security incident.
	DisplayName string `json:"displayName,omitempty"`

	// FirstDetectedTime: Output only. The time when events associated with
	// the incident were first detected.
	FirstDetectedTime string `json:"firstDetectedTime,omitempty"`

	// LastDetectedTime: Output only. The time when events associated with
	// the incident were last detected.
	LastDetectedTime string `json:"lastDetectedTime,omitempty"`

	// LastObservabilityChangeTime: Output only. The time when the incident
	// observability was last changed.
	LastObservabilityChangeTime string `json:"lastObservabilityChangeTime,omitempty"`

	// Name: Immutable. Name of the security incident resource. Format:
	// organizations/{org}/environments/{environment}/securityIncidents/{inci
	// dent} Example:
	// organizations/apigee-org/environments/dev/securityIncidents/1234-5678-
	// 9101-1111
	Name string `json:"name,omitempty"`

	// Observability: Optional. Indicates if the user archived this
	// incident.
	//
	// Possible values:
	//   "OBSERVABILITY_UNSPECIFIED" - The incident observability is
	// unspecified.
	//   "ACTIVE" - The incident is currently active. Can change to this
	// status from archived.
	//   "ARCHIVED" - The incident is currently archived and was archived by
	// the customer.
	Observability string `json:"observability,omitempty"`

	// RiskLevel: Output only. Risk level of the incident.
	//
	// Possible values:
	//   "RISK_LEVEL_UNSPECIFIED" - Risk Level Unspecified.
	//   "LOW" - Risk level of the incident is low.
	//   "MODERATE" - Risk level of the incident is moderate.
	//   "SEVERE" - Risk level of the incident is severe.
	RiskLevel string `json:"riskLevel,omitempty"`

	// TrafficCount: Total traffic detected as part of the incident.
	TrafficCount int64 `json:"trafficCount,omitempty,string"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "DetectionTypes") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "DetectionTypes") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecurityIncident) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecurityIncident
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecurityProfile: Represents a SecurityProfile
// resource.
type GoogleCloudApigeeV1SecurityProfile struct {
	// Description: Description of the security profile.
	Description string `json:"description,omitempty"`

	// DisplayName: DEPRECATED: DO NOT USE Display name of the security
	// profile.
	DisplayName string `json:"displayName,omitempty"`

	// Environments: List of environments attached to security profile.
	Environments []*GoogleCloudApigeeV1SecurityProfileEnvironment `json:"environments,omitempty"`

	// MaxScore: Output only. Maximum security score that can be generated
	// by this profile.
	MaxScore int64 `json:"maxScore,omitempty"`

	// MinScore: Output only. Minimum security score that can be generated
	// by this profile.
	MinScore int64 `json:"minScore,omitempty"`

	// Name: Immutable. Name of the security profile resource. Format:
	// organizations/{org}/securityProfiles/{profile}
	Name string `json:"name,omitempty"`

	// ProfileConfig: Required. Customized profile configuration that
	// computes the security score.
	ProfileConfig *GoogleCloudApigeeV1ProfileConfig `json:"profileConfig,omitempty"`

	// RevisionCreateTime: Output only. The time when revision was created.
	RevisionCreateTime string `json:"revisionCreateTime,omitempty"`

	// RevisionId: Output only. Revision ID of the security profile.
	RevisionId int64 `json:"revisionId,omitempty,string"`

	// RevisionPublishTime: Output only. DEPRECATED: DO NOT USE The time
	// when revision was published. Once published, the security profile
	// revision cannot be updated further and can be attached to
	// environments.
	RevisionPublishTime string `json:"revisionPublishTime,omitempty"`

	// RevisionUpdateTime: Output only. The time when revision was updated.
	RevisionUpdateTime string `json:"revisionUpdateTime,omitempty"`

	// ScoringConfigs: List of profile scoring configs in this revision.
	ScoringConfigs []*GoogleCloudApigeeV1SecurityProfileScoringConfig `json:"scoringConfigs,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Description") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Description") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecurityProfile) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecurityProfile
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecurityProfileEnvironment: Environment
// information of attached environments. Scoring an environment is
// enabled only if it is attached to a security profile.
type GoogleCloudApigeeV1SecurityProfileEnvironment struct {
	// AttachTime: Output only. Time at which environment was attached to
	// the security profile.
	AttachTime string `json:"attachTime,omitempty"`

	// Environment: Output only. Name of the environment.
	Environment string `json:"environment,omitempty"`

	// ForceSendFields is a list of field names (e.g. "AttachTime") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AttachTime") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecurityProfileEnvironment) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecurityProfileEnvironment
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecurityProfileEnvironmentAssociation: Represents
// a SecurityProfileEnvironmentAssociation resource.
type GoogleCloudApigeeV1SecurityProfileEnvironmentAssociation struct {
	// AttachTime: Output only. The time when environment was attached to
	// the security profile.
	AttachTime string `json:"attachTime,omitempty"`

	// Name: Immutable. Name of the environment that the profile is attached
	// to.
	Name string `json:"name,omitempty"`

	// SecurityProfileRevisionId: DEPRECATED: DO NOT USE Revision ID of the
	// security profile.
	SecurityProfileRevisionId int64 `json:"securityProfileRevisionId,omitempty,string"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "AttachTime") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AttachTime") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecurityProfileEnvironmentAssociation) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecurityProfileEnvironmentAssociation
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecurityProfileScoringConfig: Security
// configurations to manage scoring.
type GoogleCloudApigeeV1SecurityProfileScoringConfig struct {
	// Description: Description of the config.
	Description string `json:"description,omitempty"`

	// ScorePath: Path of the component config used for scoring.
	ScorePath string `json:"scorePath,omitempty"`

	// Title: Title of the config.
	Title string `json:"title,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Description") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Description") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecurityProfileScoringConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecurityProfileScoringConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecurityReport: SecurityReport saves all the
// information about the created security report.
type GoogleCloudApigeeV1SecurityReport struct {
	// Created: Creation time of the query.
	Created string `json:"created,omitempty"`

	// DisplayName: Display Name specified by the user.
	DisplayName string `json:"displayName,omitempty"`

	// EnvgroupHostname: Hostname is available only when query is executed
	// at host level.
	EnvgroupHostname string `json:"envgroupHostname,omitempty"`

	// Error: Error is set when query fails.
	Error string `json:"error,omitempty"`

	// ExecutionTime: ExecutionTime is available only after the query is
	// completed.
	ExecutionTime string `json:"executionTime,omitempty"`

	// QueryParams: Contains information like metrics, dimenstions etc of
	// the Security Report.
	QueryParams *GoogleCloudApigeeV1SecurityReportMetadata `json:"queryParams,omitempty"`

	// ReportDefinitionId: Report Definition ID.
	ReportDefinitionId string `json:"reportDefinitionId,omitempty"`

	// Result: Result is available only after the query is completed.
	Result *GoogleCloudApigeeV1SecurityReportResultMetadata `json:"result,omitempty"`

	// ResultFileSize: ResultFileSize is available only after the query is
	// completed.
	ResultFileSize string `json:"resultFileSize,omitempty"`

	// ResultRows: ResultRows is available only after the query is
	// completed.
	ResultRows int64 `json:"resultRows,omitempty,string"`

	// Self: Self link of the query. Example:
	// `/organizations/myorg/environments/myenv/securityReports/9cfc0d85-0f30
	// -46d6-ae6f-318d0cb961bd` or following format if query is running at
	// host level:
	// `/organizations/myorg/hostSecurityReports/9cfc0d85-0f30-46d6-ae6f-318d
	// 0cb961bd`
	Self string `json:"self,omitempty"`

	// State: Query state could be "enqueued", "running", "completed",
	// "expired" and "failed".
	State string `json:"state,omitempty"`

	// Updated: Output only. Last updated timestamp for the query.
	Updated string `json:"updated,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Created") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Created") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecurityReport) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecurityReport
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecurityReportMetadata: Metadata for the security
// report.
type GoogleCloudApigeeV1SecurityReportMetadata struct {
	// Dimensions: Dimensions of the SecurityReport.
	Dimensions []string `json:"dimensions,omitempty"`

	// EndTimestamp: End timestamp of the query range.
	EndTimestamp string `json:"endTimestamp,omitempty"`

	// Metrics: Metrics of the SecurityReport. Example:
	// ["name:bot_count,func:sum,alias:sum_bot_count"]
	Metrics []string `json:"metrics,omitempty"`

	// MimeType: MIME type / Output format.
	MimeType string `json:"mimeType,omitempty"`

	// StartTimestamp: Start timestamp of the query range.
	StartTimestamp string `json:"startTimestamp,omitempty"`

	// TimeUnit: Query GroupBy time unit. Example: "seconds", "minute",
	// "hour"
	TimeUnit string `json:"timeUnit,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Dimensions") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Dimensions") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecurityReportMetadata) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecurityReportMetadata
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecurityReportQuery: Body structure when user
// makes a request to create a security report.
type GoogleCloudApigeeV1SecurityReportQuery struct {
	// CsvDelimiter: Delimiter used in the CSV file, if `outputFormat` is
	// set to `csv`. Defaults to the `,` (comma) character. Supported
	// delimiter characters include comma (`,`), pipe (`|`), and tab (`\t`).
	CsvDelimiter string `json:"csvDelimiter,omitempty"`

	// Dimensions: A list of dimensions.
	// https://docs.apigee.com/api-platform/analytics/analytics-reference#dimensions
	Dimensions []string `json:"dimensions,omitempty"`

	// DisplayName: Security Report display name which users can specify.
	DisplayName string `json:"displayName,omitempty"`

	// EnvgroupHostname: Hostname needs to be specified if query intends to
	// run at host level. This field is only allowed when query is submitted
	// by CreateHostSecurityReport where analytics data will be grouped by
	// organization and hostname.
	EnvgroupHostname string `json:"envgroupHostname,omitempty"`

	// Filter: Boolean expression that can be used to filter data. Filter
	// expressions can be combined using AND/OR terms and should be fully
	// parenthesized to avoid ambiguity. See Analytics metrics, dimensions,
	// and filters reference
	// https://docs.apigee.com/api-platform/analytics/analytics-reference
	// for more information on the fields available to filter on. For more
	// information on the tokens that you use to build filter expressions,
	// see Filter expression syntax.
	// https://docs.apigee.com/api-platform/analytics/asynch-reports-api#filter-expression-syntax
	Filter string `json:"filter,omitempty"`

	// GroupByTimeUnit: Time unit used to group the result set. Valid values
	// include: second, minute, hour, day, week, or month. If a query
	// includes groupByTimeUnit, then the result is an aggregation based on
	// the specified time unit and the resultant timestamp does not include
	// milliseconds precision. If a query omits groupByTimeUnit, then the
	// resultant timestamp includes milliseconds precision.
	GroupByTimeUnit string `json:"groupByTimeUnit,omitempty"`

	// Limit: Maximum number of rows that can be returned in the result.
	Limit int64 `json:"limit,omitempty"`

	// Metrics: A list of Metrics.
	Metrics []*GoogleCloudApigeeV1SecurityReportQueryMetric `json:"metrics,omitempty"`

	// MimeType: Valid values include: `csv` or `json`. Defaults to `json`.
	// Note: Configure the delimiter for CSV output using the csvDelimiter
	// property.
	MimeType string `json:"mimeType,omitempty"`

	// ReportDefinitionId: Report Definition ID.
	ReportDefinitionId string `json:"reportDefinitionId,omitempty"`

	// TimeRange: Required. Time range for the query. Can use the following
	// predefined strings to specify the time range: `last60minutes`
	// `last24hours` `last7days` Or, specify the timeRange as a structure
	// describing start and end timestamps in the ISO format:
	// yyyy-mm-ddThh:mm:ssZ. Example: "timeRange": { "start":
	// "2018-07-29T00:13:00Z", "end": "2018-08-01T00:18:00Z" }
	TimeRange interface{} `json:"timeRange,omitempty"`

	// ForceSendFields is a list of field names (e.g. "CsvDelimiter") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "CsvDelimiter") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecurityReportQuery) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecurityReportQuery
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecurityReportQueryMetric: Metric of the Query
type GoogleCloudApigeeV1SecurityReportQueryMetric struct {
	// AggregationFunction: Aggregation function: avg, min, max, or sum.
	AggregationFunction string `json:"aggregationFunction,omitempty"`

	// Alias: Alias for the metric. Alias will be used to replace metric
	// name in query results.
	Alias string `json:"alias,omitempty"`

	// Name: Required. Metric name.
	Name string `json:"name,omitempty"`

	// Operator: One of `+`, `-`, `/`, `%`, `*`.
	Operator string `json:"operator,omitempty"`

	// Value: Operand value should be provided when operator is set.
	Value string `json:"value,omitempty"`

	// ForceSendFields is a list of field names (e.g. "AggregationFunction")
	// to unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AggregationFunction") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecurityReportQueryMetric) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecurityReportQueryMetric
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecurityReportResultMetadata: Contains
// informations about the security report results.
type GoogleCloudApigeeV1SecurityReportResultMetadata struct {
	// Expires: Output only. Expire_time is set to 7 days after report
	// creation. Query result will be unaccessable after this time. Example:
	// "2021-05-04T13:38:52-07:00"
	Expires string `json:"expires,omitempty"`

	// Self: Self link of the query results. Example:
	// `/organizations/myorg/environments/myenv/securityReports/9cfc0d85-0f30
	// -46d6-ae6f-318d0cb961bd/result` or following format if query is
	// running at host level:
	// `/organizations/myorg/hostSecurityReports/9cfc0d85-0f30-46d6-ae6f-318d
	// 0cb961bd/result`
	Self string `json:"self,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Expires") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Expires") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecurityReportResultMetadata) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecurityReportResultMetadata
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecurityReportResultView: The response for
// security report result view APIs.
type GoogleCloudApigeeV1SecurityReportResultView struct {
	// Code: Error code when there is a failure.
	Code int64 `json:"code,omitempty"`

	// Error: Error message when there is a failure.
	Error string `json:"error,omitempty"`

	// Metadata: Metadata contains information like metrics, dimenstions etc
	// of the security report.
	Metadata *GoogleCloudApigeeV1SecurityReportMetadata `json:"metadata,omitempty"`

	// Rows: Rows of security report result. Each row is a JSON object.
	// Example: {sum(message_count): 1, developer_app: "(not set)",…}
	Rows []interface{} `json:"rows,omitempty"`

	// State: State of retrieving ResultView.
	State string `json:"state,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Code") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Code") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecurityReportResultView) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecurityReportResultView
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SecuritySettings: SecuritySettings reflects the
// current state of the SecuritySettings feature.
type GoogleCloudApigeeV1SecuritySettings struct {
	// MlRetrainingFeedbackEnabled: Optional. If true the user consents to
	// the use of ML models for Abuse detection.
	MlRetrainingFeedbackEnabled bool `json:"mlRetrainingFeedbackEnabled,omitempty"`

	// Name: Identifier. Full resource name is always
	// `organizations/{org}/securitySettings`.
	Name string `json:"name,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g.
	// "MlRetrainingFeedbackEnabled") to unconditionally include in API
	// requests. By default, fields with empty or default values are omitted
	// from API requests. However, any non-pointer, non-interface field
	// appearing in ForceSendFields will be sent to the server regardless of
	// whether the field is empty or not. This may be used to include empty
	// fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g.
	// "MlRetrainingFeedbackEnabled") to include in API requests with the
	// JSON null value. By default, fields with empty values are omitted
	// from API requests. However, any field with an empty value appearing
	// in NullFields will be sent to the server as null. It is an error if a
	// field in this list has a non-empty value. This may be used to include
	// null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SecuritySettings) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SecuritySettings
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1ServiceIssuersMapping struct {
	// EmailIds: List of trusted issuer email ids.
	EmailIds []string `json:"emailIds,omitempty"`

	// Service: String indicating the Apigee service name.
	Service string `json:"service,omitempty"`

	// ForceSendFields is a list of field names (e.g. "EmailIds") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "EmailIds") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1ServiceIssuersMapping) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1ServiceIssuersMapping
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1Session: Session carries the debug session id and
// its creation time.
type GoogleCloudApigeeV1Session struct {
	// Id: The debug session ID.
	Id string `json:"id,omitempty"`

	// TimestampMs: The first transaction creation timestamp in millisecond,
	// recorded by UAP.
	TimestampMs int64 `json:"timestampMs,omitempty,string"`

	// ForceSendFields is a list of field names (e.g. "Id") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Id") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Session) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Session
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SetAddonEnablementRequest: Request for
// SetAddonEnablement.
type GoogleCloudApigeeV1SetAddonEnablementRequest struct {
	// AnalyticsEnabled: If the Analytics should be enabled in the
	// environment.
	AnalyticsEnabled bool `json:"analyticsEnabled,omitempty"`

	// ApiSecurityEnabled: If the API Security should be enabled in the
	// environment.
	ApiSecurityEnabled bool `json:"apiSecurityEnabled,omitempty"`

	// ForceSendFields is a list of field names (e.g. "AnalyticsEnabled") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AnalyticsEnabled") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SetAddonEnablementRequest) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SetAddonEnablementRequest
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SetAddonsRequest: Request for SetAddons.
type GoogleCloudApigeeV1SetAddonsRequest struct {
	// AddonsConfig: Required. Add-on configurations.
	AddonsConfig *GoogleCloudApigeeV1AddonsConfig `json:"addonsConfig,omitempty"`

	// ForceSendFields is a list of field names (e.g. "AddonsConfig") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AddonsConfig") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SetAddonsRequest) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SetAddonsRequest
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SharedFlow: The metadata describing a shared flow
type GoogleCloudApigeeV1SharedFlow struct {
	// LatestRevisionId: The id of the most recently created revision for
	// this shared flow.
	LatestRevisionId string `json:"latestRevisionId,omitempty"`

	// MetaData: Metadata describing the shared flow.
	MetaData *GoogleCloudApigeeV1EntityMetadata `json:"metaData,omitempty"`

	// Name: The ID of the shared flow.
	Name string `json:"name,omitempty"`

	// Revision: A list of revisions of this shared flow.
	Revision []string `json:"revision,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "LatestRevisionId") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "LatestRevisionId") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SharedFlow) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SharedFlow
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1SharedFlowRevision: The metadata describing a
// shared flow revision.
type GoogleCloudApigeeV1SharedFlowRevision struct {
	// ConfigurationVersion: The version of the configuration schema to
	// which this shared flow conforms. The only supported value currently
	// is majorVersion 4 and minorVersion 0. This setting may be used in the
	// future to enable evolution of the shared flow format.
	ConfigurationVersion *GoogleCloudApigeeV1ConfigVersion `json:"configurationVersion,omitempty"`

	// ContextInfo: A textual description of the shared flow revision.
	ContextInfo string `json:"contextInfo,omitempty"`

	// CreatedAt: Time at which this shared flow revision was created, in
	// milliseconds since epoch.
	CreatedAt int64 `json:"createdAt,omitempty,string"`

	// Description: Description of the shared flow revision.
	Description string `json:"description,omitempty"`

	// DisplayName: The human readable name of this shared flow.
	DisplayName string `json:"displayName,omitempty"`

	// EntityMetaDataAsProperties: A Key-Value map of metadata about this
	// shared flow revision.
	EntityMetaDataAsProperties map[string]string `json:"entityMetaDataAsProperties,omitempty"`

	// LastModifiedAt: Time at which this shared flow revision was most
	// recently modified, in milliseconds since epoch.
	LastModifiedAt int64 `json:"lastModifiedAt,omitempty,string"`

	// Name: The resource ID of the parent shared flow.
	Name string `json:"name,omitempty"`

	// Policies: A list of policy names included in this shared flow
	// revision.
	Policies []string `json:"policies,omitempty"`

	// ResourceFiles: The resource files included in this shared flow
	// revision.
	ResourceFiles *GoogleCloudApigeeV1ResourceFiles `json:"resourceFiles,omitempty"`

	// Resources: A list of the resources included in this shared flow
	// revision formatted as "{type}://{name}".
	Resources []string `json:"resources,omitempty"`

	// Revision: The resource ID of this revision.
	Revision string `json:"revision,omitempty"`

	// SharedFlows: A list of the shared flow names included in this shared
	// flow revision.
	SharedFlows []string `json:"sharedFlows,omitempty"`

	// Type: The string "Application"
	Type string `json:"type,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g.
	// "ConfigurationVersion") to unconditionally include in API requests.
	// By default, fields with empty or default values are omitted from API
	// requests. However, any non-pointer, non-interface field appearing in
	// ForceSendFields will be sent to the server regardless of whether the
	// field is empty or not. This may be used to include empty fields in
	// Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ConfigurationVersion") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SharedFlowRevision) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SharedFlowRevision
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1Stats: Encapsulates a `stats` response.
type GoogleCloudApigeeV1Stats struct {
	// Environments: List of query results on the environment level.
	Environments []*GoogleCloudApigeeV1StatsEnvironmentStats `json:"environments,omitempty"`

	// Hosts: List of query results grouped by host.
	Hosts []*GoogleCloudApigeeV1StatsHostStats `json:"hosts,omitempty"`

	// MetaData: Metadata information.
	MetaData *GoogleCloudApigeeV1Metadata `json:"metaData,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Environments") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Environments") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Stats) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Stats
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1StatsEnvironmentStats: Encapsulates the
// environment wrapper: ``` "environments": [ { "metrics": [ { "name":
// "sum(message_count)", "values": [ "2.52056245E8" ] } ], "name":
// "prod" } ]```
type GoogleCloudApigeeV1StatsEnvironmentStats struct {
	// Dimensions: List of metrics grouped under dimensions.
	Dimensions []*GoogleCloudApigeeV1DimensionMetric `json:"dimensions,omitempty"`

	// Metrics: In the final response, only one of the following fields will
	// be present based on the dimensions provided. If no dimensions are
	// provided, then only top-level metrics is provided. If dimensions are
	// included, then there will be a top-level dimensions field under
	// environments which will contain metrics values and the dimension
	// name. Example: ``` "environments": [ { "dimensions": [ { "metrics": [
	// { "name": "sum(message_count)", "values": [ "2.14049521E8" ] } ],
	// "name": "nit_proxy" } ], "name": "prod" } ]``` or ``"environments":
	// [ { "metrics": [ { "name": "sum(message_count)", "values": [
	// "2.19026331E8" ] } ], "name": "prod" } ]``` List of metric values.
	Metrics []*GoogleCloudApigeeV1Metric `json:"metrics,omitempty"`

	// Name: Name of the environment.
	Name string `json:"name,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Dimensions") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Dimensions") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1StatsEnvironmentStats) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1StatsEnvironmentStats
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1StatsHostStats: Encapsulates the hostname wrapper:
// ``` "hosts": [ { "metrics": [ { "name": "sum(message_count)",
// "values": [ "2.52056245E8" ] } ], "name": "example.com" } ]```
type GoogleCloudApigeeV1StatsHostStats struct {
	// Dimensions: List of metrics grouped under dimensions.
	Dimensions []*GoogleCloudApigeeV1DimensionMetric `json:"dimensions,omitempty"`

	// Metrics: In the final response, only one of the following fields will
	// be present based on the dimensions provided. If no dimensions are
	// provided, then only the top-level metrics are provided. If dimensions
	// are included, then there will be a top-level dimensions field under
	// hostnames which will contain metrics values and the dimension name.
	// Example: ``` "hosts": [ { "dimensions": [ { "metrics": [ { "name":
	// "sum(message_count)", "values": [ "2.14049521E8" ] } ], "name":
	// "nit_proxy" } ], "name": "example.com" } ]``` OR ``"hosts": [ {
	// "metrics": [ { "name": "sum(message_count)", "values": [
	// "2.19026331E8" ] } ], "name": "example.com" } ]``` List of metric
	// values.
	Metrics []*GoogleCloudApigeeV1Metric `json:"metrics,omitempty"`

	// Name: Hostname used in query.
	Name string `json:"name,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Dimensions") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Dimensions") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1StatsHostStats) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1StatsHostStats
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1Subscription: Pub/Sub subscription of an
// environment.
type GoogleCloudApigeeV1Subscription struct {
	// Name: Full name of the Pub/Sub subcription. Use the following
	// structure in your request: `subscription
	// "projects/foo/subscription/bar"
	Name string `json:"name,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Name") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Name") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1Subscription) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1Subscription
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1SyncAuthorization struct {
	// Etag: Entity tag (ETag) used for optimistic concurrency control as a
	// way to help prevent simultaneous updates from overwriting each other.
	// For example, when you call getSyncAuthorization
	// (organizations/getSyncAuthorization) an ETag is returned in the
	// response. Pass that ETag when calling the setSyncAuthorization
	// (organizations/setSyncAuthorization) to ensure that you are updating
	// the correct version. If you don't pass the ETag in the call to
	// `setSyncAuthorization`, then the existing authorization is
	// overwritten indiscriminately. **Note**: We strongly recommend that
	// you use the ETag in the read-modify-write cycle to avoid race
	// conditions.
	Etag string `json:"etag,omitempty"`

	// Identities: Required. Array of service accounts to grant access to
	// control plane resources, each specified using the following format:
	// `serviceAccount:` service-account-name. The service-account-name is
	// formatted like an email address. For example:
	// `my-synchronizer-manager-service_account@my_project_id.iam.gserviceacc
	// ount.com` You might specify multiple service accounts, for example,
	// if you have multiple environments and wish to assign a unique service
	// account to each one. The service accounts must have **Apigee
	// Synchronizer Manager** role. See also Create service accounts
	// (https://cloud.google.com/apigee/docs/hybrid/latest/sa-about#create-the-service-accounts).
	Identities []string `json:"identities,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Etag") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Etag") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1SyncAuthorization) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1SyncAuthorization
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1TargetServer: TargetServer configuration.
// TargetServers are used to decouple a proxy TargetEndpoint
// HTTPTargetConnections from concrete URLs for backend services.
type GoogleCloudApigeeV1TargetServer struct {
	// Description: Optional. A human-readable description of this
	// TargetServer.
	Description string `json:"description,omitempty"`

	// Host: Required. The host name this target connects to. Value must be
	// a valid hostname as described by RFC-1123.
	Host string `json:"host,omitempty"`

	// IsEnabled: Optional. Enabling/disabling a TargetServer is useful when
	// TargetServers are used in load balancing configurations, and one or
	// more TargetServers need to taken out of rotation periodically.
	// Defaults to true.
	IsEnabled bool `json:"isEnabled,omitempty"`

	// Name: Required. The resource id of this target server. Values must
	// match the regular expression
	Name string `json:"name,omitempty"`

	// Port: Required. The port number this target connects to on the given
	// host. Value must be between 1 and 65535, inclusive.
	Port int64 `json:"port,omitempty"`

	// Protocol: Immutable. The protocol used by this TargetServer.
	//
	// Possible values:
	//   "PROTOCOL_UNSPECIFIED" - UNSPECIFIED defaults to HTTP for backwards
	// compatibility.
	//   "HTTP" - The TargetServer uses HTTP.
	//   "HTTP2" - The TargetSever uses HTTP2.
	//   "GRPC_TARGET" - The TargetServer uses GRPC.
	//   "GRPC" - GRPC TargetServer to be used in ExternalCallout Policy.
	// Prefer to use EXTERNAL_CALLOUT instead. TODO(b/266125112) deprecate
	// once EXTERNAL _CALLOUT generally available.
	//   "EXTERNAL_CALLOUT" - The TargetServer is to be used in the
	// ExternalCallout Policy
	Protocol string `json:"protocol,omitempty"`

	// SSLInfo: Optional. Specifies TLS configuration info for this
	// TargetServer. The JSON name is `sSLInfo` for legacy/backwards
	// compatibility reasons -- Edge originally supported SSL, and the name
	// is still used for TLS configuration.
	SSLInfo *GoogleCloudApigeeV1TlsInfo `json:"sSLInfo,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Description") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Description") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1TargetServer) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1TargetServer
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1TargetServerConfig struct {
	// Enabled: Whether the target server is enabled. An empty/omitted value
	// for this field should be interpreted as true.
	Enabled bool `json:"enabled,omitempty"`

	// Host: Host name of the target server.
	Host string `json:"host,omitempty"`

	// Name: Target server revision name in the following format:
	// `organizations/{org}/environments/{env}/targetservers/{targetserver}/r
	// evisions/{rev}`
	Name string `json:"name,omitempty"`

	// Port: Port number for the target server.
	Port int64 `json:"port,omitempty"`

	// Protocol: The protocol used by this target server.
	//
	// Possible values:
	//   "PROTOCOL_UNSPECIFIED" - UNSPECIFIED defaults to HTTP for backwards
	// compatibility.
	//   "HTTP" - The TargetServer uses HTTP.
	//   "HTTP2" - The TargetSever uses HTTP2.
	//   "GRPC_TARGET" - The TargetServer uses GRPC.
	//   "GRPC" - GRPC TargetServer to be used in ExternalCallout Policy.
	// Prefer to use EXTERNAL_CALLOUT instead. TODO(b/266125112) deprecate
	// once EXTERNAL _CALLOUT generally available.
	//   "EXTERNAL_CALLOUT" - The TargetServer is to be used in the
	// ExternalCallout Policy
	Protocol string `json:"protocol,omitempty"`

	// TlsInfo: TLS settings for the target server.
	TlsInfo *GoogleCloudApigeeV1TlsInfoConfig `json:"tlsInfo,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Enabled") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Enabled") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1TargetServerConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1TargetServerConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1TestDatastoreResponse: The response for
// TestDatastore
type GoogleCloudApigeeV1TestDatastoreResponse struct {
	// Error: Output only. Error message of test connection failure
	Error string `json:"error,omitempty"`

	// State: Output only. It could be `completed` or `failed`
	State string `json:"state,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Error") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Error") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1TestDatastoreResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1TestDatastoreResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1TlsInfo: TLS configuration information for virtual
// hosts and TargetServers.
type GoogleCloudApigeeV1TlsInfo struct {
	// Ciphers: The SSL/TLS cipher suites to be used. For programmable
	// proxies, it must be one of the cipher suite names listed in:
	// http://docs.oracle.com/javase/8/docs/technotes/guides/security/StandardNames.html#ciphersuites.
	// For configurable proxies, it must follow the configuration specified
	// in:
	// https://commondatastorage.googleapis.com/chromium-boringssl-docs/ssl.h.html#Cipher-suite-configuration.
	// This setting has no effect for configurable proxies when negotiating
	// TLS 1.3.
	Ciphers []string `json:"ciphers,omitempty"`

	// ClientAuthEnabled: Optional. Enables two-way TLS.
	ClientAuthEnabled bool `json:"clientAuthEnabled,omitempty"`

	// CommonName: The TLS Common Name of the certificate.
	CommonName *GoogleCloudApigeeV1TlsInfoCommonName `json:"commonName,omitempty"`

	// Enabled: Required. Enables TLS. If false, neither one-way nor two-way
	// TLS will be enabled.
	Enabled bool `json:"enabled,omitempty"`

	// IgnoreValidationErrors: If true, Edge ignores TLS certificate errors.
	// Valid when configuring TLS for target servers and target endpoints,
	// and when configuring virtual hosts that use 2-way TLS. When used with
	// a target endpoint/target server, if the backend system uses SNI and
	// returns a cert with a subject Distinguished Name (DN) that does not
	// match the hostname, there is no way to ignore the error and the
	// connection fails.
	IgnoreValidationErrors bool `json:"ignoreValidationErrors,omitempty"`

	// KeyAlias: Required if `client_auth_enabled` is true. The resource ID
	// for the alias containing the private key and cert.
	KeyAlias string `json:"keyAlias,omitempty"`

	// KeyStore: Required if `client_auth_enabled` is true. The resource ID
	// of the keystore.
	KeyStore string `json:"keyStore,omitempty"`

	// Protocols: The TLS versioins to be used.
	Protocols []string `json:"protocols,omitempty"`

	// TrustStore: The resource ID of the truststore.
	TrustStore string `json:"trustStore,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Ciphers") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Ciphers") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1TlsInfo) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1TlsInfo
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1TlsInfoCommonName struct {
	// Value: The TLS Common Name string of the certificate.
	Value string `json:"value,omitempty"`

	// WildcardMatch: Indicates whether the cert should be matched against
	// as a wildcard cert.
	WildcardMatch bool `json:"wildcardMatch,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Value") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Value") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1TlsInfoCommonName) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1TlsInfoCommonName
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

type GoogleCloudApigeeV1TlsInfoConfig struct {
	// Ciphers: List of ciphers that are granted access.
	Ciphers []string `json:"ciphers,omitempty"`

	// ClientAuthEnabled: Flag that specifies whether client-side
	// authentication is enabled for the target server. Enables two-way TLS.
	ClientAuthEnabled bool `json:"clientAuthEnabled,omitempty"`

	// CommonName: Common name to validate the target server against.
	CommonName *GoogleCloudApigeeV1CommonNameConfig `json:"commonName,omitempty"`

	// Enabled: Flag that specifies whether one-way TLS is enabled. Set to
	// `true` to enable one-way TLS.
	Enabled bool `json:"enabled,omitempty"`

	// IgnoreValidationErrors: Flag that specifies whether to ignore TLS
	// certificate validation errors. Set to `true` to ignore errors.
	IgnoreValidationErrors bool `json:"ignoreValidationErrors,omitempty"`

	// KeyAlias: Name of the alias used for client-side authentication in
	// the following format:
	// `organizations/{org}/environments/{env}/keystores/{keystore}/aliases/{
	// alias}`
	KeyAlias string `json:"keyAlias,omitempty"`

	// KeyAliasReference: Reference name and alias pair to use for
	// client-side authentication.
	KeyAliasReference *GoogleCloudApigeeV1KeyAliasReference `json:"keyAliasReference,omitempty"`

	// Protocols: List of TLS protocols that are granted access.
	Protocols []string `json:"protocols,omitempty"`

	// TrustStore: Name of the keystore or keystore reference containing
	// trusted certificates for the server in the following format:
	// `organizations/{org}/environments/{env}/keystores/{keystore}` or
	// `organizations/{org}/environments/{env}/references/{reference}`
	TrustStore string `json:"trustStore,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Ciphers") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Ciphers") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1TlsInfoConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1TlsInfoConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1TraceConfig: TraceConfig defines the
// configurations in an environment of distributed trace.
type GoogleCloudApigeeV1TraceConfig struct {
	// Endpoint: Required. Endpoint of the exporter.
	Endpoint string `json:"endpoint,omitempty"`

	// Exporter: Required. Exporter that is used to view the distributed
	// trace captured using OpenCensus. An exporter sends traces to any
	// backend that is capable of consuming them. Recorded spans can be
	// exported by registered exporters.
	//
	// Possible values:
	//   "EXPORTER_UNSPECIFIED" - Exporter unspecified
	//   "JAEGER" - Jaeger exporter
	//   "CLOUD_TRACE" - Cloudtrace exporter
	Exporter string `json:"exporter,omitempty"`

	// SamplingConfig: Distributed trace configuration for all API proxies
	// in an environment. You can also override the configuration for a
	// specific API proxy using the distributed trace configuration
	// overrides API.
	SamplingConfig *GoogleCloudApigeeV1TraceSamplingConfig `json:"samplingConfig,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Endpoint") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Endpoint") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1TraceConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1TraceConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1TraceConfigOverride: A representation of a
// configuration override.
type GoogleCloudApigeeV1TraceConfigOverride struct {
	// ApiProxy: ID of the API proxy that will have its trace configuration
	// overridden.
	ApiProxy string `json:"apiProxy,omitempty"`

	// Name: ID of the trace configuration override specified as a
	// system-generated UUID.
	Name string `json:"name,omitempty"`

	// SamplingConfig: Trace configuration to override.
	SamplingConfig *GoogleCloudApigeeV1TraceSamplingConfig `json:"samplingConfig,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "ApiProxy") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ApiProxy") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1TraceConfigOverride) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1TraceConfigOverride
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1TraceSamplingConfig: TraceSamplingConfig
// represents the detail settings of distributed tracing. Only the
// fields that are defined in the distributed trace configuration can be
// overridden using the distribute trace configuration override APIs.
type GoogleCloudApigeeV1TraceSamplingConfig struct {
	// Sampler: Sampler of distributed tracing. OFF is the default value.
	//
	// Possible values:
	//   "SAMPLER_UNSPECIFIED" - Sampler unspecified.
	//   "OFF" - OFF means distributed trace is disabled, or the sampling
	// probability is 0.
	//   "PROBABILITY" - PROBABILITY means traces are captured on a
	// probability that defined by sampling_rate. The sampling rate is
	// limited to 0 to 0.5 when this is set.
	Sampler string `json:"sampler,omitempty"`

	// SamplingRate: Field sampling rate. This value is only applicable when
	// using the PROBABILITY sampler. The supported values are > 0 and <=
	// 0.5.
	SamplingRate float64 `json:"samplingRate,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Sampler") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Sampler") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1TraceSamplingConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1TraceSamplingConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

func (s *GoogleCloudApigeeV1TraceSamplingConfig) UnmarshalJSON(data []byte) error {
	type NoMethod GoogleCloudApigeeV1TraceSamplingConfig
	var s1 struct {
		SamplingRate gensupport.JSONFloat64 `json:"samplingRate"`
		*NoMethod
	}
	s1.NoMethod = (*NoMethod)(s)
	if err := json.Unmarshal(data, &s1); err != nil {
		return err
	}
	s.SamplingRate = float64(s1.SamplingRate)
	return nil
}

// GoogleCloudApigeeV1UpdateAppGroupAppKeyRequest: Request for
// UpdateAppGroupAppKey
type GoogleCloudApigeeV1UpdateAppGroupAppKeyRequest struct {
	// Action: Approve or revoke the consumer key by setting this value to
	// `approve` or `revoke` respectively. The `Content-Type` header, if
	// set, must be set to `application/octet-stream`, with empty body.
	Action string `json:"action,omitempty"`

	// ApiProducts: The list of API products that will be associated with
	// the credential. This list will be appended to the existing list of
	// associated API Products for this App Key. Duplicates will be ignored.
	ApiProducts []string `json:"apiProducts,omitempty"`

	// AppGroupAppKey: The new AppGroupKey to be amended. Note that the
	// status can be updated only via action.
	AppGroupAppKey *GoogleCloudApigeeV1AppGroupAppKey `json:"appGroupAppKey,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Action") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Action") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1UpdateAppGroupAppKeyRequest) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1UpdateAppGroupAppKeyRequest
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1UpdateError: Details on why a resource update
// failed in the runtime.
type GoogleCloudApigeeV1UpdateError struct {
	// Code: Status code.
	//
	// Possible values:
	//   "OK" - Not an error; returned on success. HTTP Mapping: 200 OK
	//   "CANCELLED" - The operation was cancelled, typically by the caller.
	// HTTP Mapping: 499 Client Closed Request
	//   "UNKNOWN" - Unknown error. For example, this error may be returned
	// when a `Status` value received from another address space belongs to
	// an error space that is not known in this address space. Also errors
	// raised by APIs that do not return enough error information may be
	// converted to this error. HTTP Mapping: 500 Internal Server Error
	//   "INVALID_ARGUMENT" - The client specified an invalid argument. Note
	// that this differs from `FAILED_PRECONDITION`. `INVALID_ARGUMENT`
	// indicates arguments that are problematic regardless of the state of
	// the system (e.g., a malformed file name). HTTP Mapping: 400 Bad
	// Request
	//   "DEADLINE_EXCEEDED" - The deadline expired before the operation
	// could complete. For operations that change the state of the system,
	// this error may be returned even if the operation has completed
	// successfully. For example, a successful response from a server could
	// have been delayed long enough for the deadline to expire. HTTP
	// Mapping: 504 Gateway Timeout
	//   "NOT_FOUND" - Some requested entity (e.g., file or directory) was
	// not found. Note to server developers: if a request is denied for an
	// entire class of users, such as gradual feature rollout or
	// undocumented allowlist, `NOT_FOUND` may be used. If a request is
	// denied for some users within a class of users, such as user-based
	// access control, `PERMISSION_DENIED` must be used. HTTP Mapping: 404
	// Not Found
	//   "ALREADY_EXISTS" - The entity that a client attempted to create
	// (e.g., file or directory) already exists. HTTP Mapping: 409 Conflict
	//   "PERMISSION_DENIED" - The caller does not have permission to
	// execute the specified operation. `PERMISSION_DENIED` must not be used
	// for rejections caused by exhausting some resource (use
	// `RESOURCE_EXHAUSTED` instead for those errors). `PERMISSION_DENIED`
	// must not be used if the caller can not be identified (use
	// `UNAUTHENTICATED` instead for those errors). This error code does not
	// imply the request is valid or the requested entity exists or
	// satisfies other pre-conditions. HTTP Mapping: 403 Forbidden
	//   "UNAUTHENTICATED" - The request does not have valid authentication
	// credentials for the operation. HTTP Mapping: 401 Unauthorized
	//   "RESOURCE_EXHAUSTED" - Some resource has been exhausted, perhaps a
	// per-user quota, or perhaps the entire file system is out of space.
	// HTTP Mapping: 429 Too Many Requests
	//   "FAILED_PRECONDITION" - The operation was rejected because the
	// system is not in a state required for the operation's execution. For
	// example, the directory to be deleted is non-empty, an rmdir operation
	// is applied to a non-directory, etc. Service implementors can use the
	// following guidelines to decide between `FAILED_PRECONDITION`,
	// `ABORTED`, and `UNAVAILABLE`: (a) Use `UNAVAILABLE` if the client can
	// retry just the failing call. (b) Use `ABORTED` if the client should
	// retry at a higher level. For example, when a client-specified
	// test-and-set fails, indicating the client should restart a
	// read-modify-write sequence. (c) Use `FAILED_PRECONDITION` if the
	// client should not retry until the system state has been explicitly
	// fixed. For example, if an "rmdir" fails because the directory is
	// non-empty, `FAILED_PRECONDITION` should be returned since the client
	// should not retry unless the files are deleted from the directory.
	// HTTP Mapping: 400 Bad Request
	//   "ABORTED" - The operation was aborted, typically due to a
	// concurrency issue such as a sequencer check failure or transaction
	// abort. See the guidelines above for deciding between
	// `FAILED_PRECONDITION`, `ABORTED`, and `UNAVAILABLE`. HTTP Mapping:
	// 409 Conflict
	//   "OUT_OF_RANGE" - The operation was attempted past the valid range.
	// E.g., seeking or reading past end-of-file. Unlike `INVALID_ARGUMENT`,
	// this error indicates a problem that may be fixed if the system state
	// changes. For example, a 32-bit file system will generate
	// `INVALID_ARGUMENT` if asked to read at an offset that is not in the
	// range [0,2^32-1], but it will generate `OUT_OF_RANGE` if asked to
	// read from an offset past the current file size. There is a fair bit
	// of overlap between `FAILED_PRECONDITION` and `OUT_OF_RANGE`. We
	// recommend using `OUT_OF_RANGE` (the more specific error) when it
	// applies so that callers who are iterating through a space can easily
	// look for an `OUT_OF_RANGE` error to detect when they are done. HTTP
	// Mapping: 400 Bad Request
	//   "UNIMPLEMENTED" - The operation is not implemented or is not
	// supported/enabled in this service. HTTP Mapping: 501 Not Implemented
	//   "INTERNAL" - Internal errors. This means that some invariants
	// expected by the underlying system have been broken. This error code
	// is reserved for serious errors. HTTP Mapping: 500 Internal Server
	// Error
	//   "UNAVAILABLE" - The service is currently unavailable. This is most
	// likely a transient condition, which can be corrected by retrying with
	// a backoff. Note that it is not always safe to retry non-idempotent
	// operations. See the guidelines above for deciding between
	// `FAILED_PRECONDITION`, `ABORTED`, and `UNAVAILABLE`. HTTP Mapping:
	// 503 Service Unavailable
	//   "DATA_LOSS" - Unrecoverable data loss or corruption. HTTP Mapping:
	// 500 Internal Server Error
	Code string `json:"code,omitempty"`

	// Message: User-friendly error message.
	Message string `json:"message,omitempty"`

	// Resource: The sub resource specific to this error (e.g. a proxy
	// deployed within the EnvironmentConfig). If empty the error refers to
	// the top level resource.
	Resource string `json:"resource,omitempty"`

	// Type: A string that uniquely identifies the type of error. This
	// provides a more reliable means to deduplicate errors across revisions
	// and instances.
	Type string `json:"type,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Code") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Code") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1UpdateError) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1UpdateError
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleCloudApigeeV1UpdateSecurityIncidentRequest: Request for
// UpdateSecurityIncident.
type GoogleCloudApigeeV1UpdateSecurityIncidentRequest struct {
	// SecurityIncident: Required. The security incident to update. Must
	// contain all existing populated fields of the current incident.
	SecurityIncident *GoogleCloudApigeeV1SecurityIncident `json:"securityIncident,omitempty"`

	// UpdateMask: Required. The list of fields to update. Allowed fields
	// are: LINT.IfChange(allowed_update_fields_comment) - observability
	// LINT.ThenChange()
	UpdateMask string `json:"updateMask,omitempty"`

	// ForceSendFields is a list of field names (e.g. "SecurityIncident") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "SecurityIncident") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleCloudApigeeV1UpdateSecurityIncidentRequest) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleCloudApigeeV1UpdateSecurityIncidentRequest
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleIamV1AuditConfig: Specifies the audit configuration for a
// service. The configuration determines which permission types are
// logged, and what identities, if any, are exempted from logging. An
// AuditConfig must have one or more AuditLogConfigs. If there are
// AuditConfigs for both `allServices` and a specific service, the union
// of the two AuditConfigs is used for that service: the log_types
// specified in each AuditConfig are enabled, and the exempted_members
// in each AuditLogConfig are exempted. Example Policy with multiple
// AuditConfigs: { "audit_configs": [ { "service": "allServices",
// "audit_log_configs": [ { "log_type": "DATA_READ", "exempted_members":
// [ "user:jose@example.com" ] }, { "log_type": "DATA_WRITE" }, {
// "log_type": "ADMIN_READ" } ] }, { "service":
// "sampleservice.googleapis.com", "audit_log_configs": [ { "log_type":
// "DATA_READ" }, { "log_type": "DATA_WRITE", "exempted_members": [
// "user:aliya@example.com" ] } ] } ] } For sampleservice, this policy
// enables DATA_READ, DATA_WRITE and ADMIN_READ logging. It also exempts
// `jose@example.com` from DATA_READ logging, and `aliya@example.com`
// from DATA_WRITE logging.
type GoogleIamV1AuditConfig struct {
	// AuditLogConfigs: The configuration for logging of each type of
	// permission.
	AuditLogConfigs []*GoogleIamV1AuditLogConfig `json:"auditLogConfigs,omitempty"`

	// Service: Specifies a service that will be enabled for audit logging.
	// For example, `storage.googleapis.com`, `cloudsql.googleapis.com`.
	// `allServices` is a special value that covers all services.
	Service string `json:"service,omitempty"`

	// ForceSendFields is a list of field names (e.g. "AuditLogConfigs") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AuditLogConfigs") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleIamV1AuditConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleIamV1AuditConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleIamV1AuditLogConfig: Provides the configuration for logging a
// type of permissions. Example: { "audit_log_configs": [ { "log_type":
// "DATA_READ", "exempted_members": [ "user:jose@example.com" ] }, {
// "log_type": "DATA_WRITE" } ] } This enables 'DATA_READ' and
// 'DATA_WRITE' logging, while exempting jose@example.com from DATA_READ
// logging.
type GoogleIamV1AuditLogConfig struct {
	// ExemptedMembers: Specifies the identities that do not cause logging
	// for this type of permission. Follows the same format of
	// Binding.members.
	ExemptedMembers []string `json:"exemptedMembers,omitempty"`

	// LogType: The log type that this config enables.
	//
	// Possible values:
	//   "LOG_TYPE_UNSPECIFIED" - Default case. Should never be this.
	//   "ADMIN_READ" - Admin reads. Example: CloudIAM getIamPolicy
	//   "DATA_WRITE" - Data writes. Example: CloudSQL Users create
	//   "DATA_READ" - Data reads. Example: CloudSQL Users list
	LogType string `json:"logType,omitempty"`

	// ForceSendFields is a list of field names (e.g. "ExemptedMembers") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "ExemptedMembers") to
	// include in API requests with the JSON null value. By default, fields
	// with empty values are omitted from API requests. However, any field
	// with an empty value appearing in NullFields will be sent to the
	// server as null. It is an error if a field in this list has a
	// non-empty value. This may be used to include null fields in Patch
	// requests.
	NullFields []string `json:"-"`
}

func (s *GoogleIamV1AuditLogConfig) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleIamV1AuditLogConfig
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleIamV1Binding: Associates `members`, or principals, with a
// `role`.
type GoogleIamV1Binding struct {
	// Condition: The condition that is associated with this binding. If the
	// condition evaluates to `true`, then this binding applies to the
	// current request. If the condition evaluates to `false`, then this
	// binding does not apply to the current request. However, a different
	// role binding might grant the same role to one or more of the
	// principals in this binding. To learn which resources support
	// conditions in their IAM policies, see the IAM documentation
	// (https://cloud.google.com/iam/help/conditions/resource-policies).
	Condition *GoogleTypeExpr `json:"condition,omitempty"`

	// Members: Specifies the principals requesting access for a Google
	// Cloud resource. `members` can have the following values: *
	// `allUsers`: A special identifier that represents anyone who is on the
	// internet; with or without a Google account. *
	// `allAuthenticatedUsers`: A special identifier that represents anyone
	// who is authenticated with a Google account or a service account. Does
	// not include identities that come from external identity providers
	// (IdPs) through identity federation. * `user:{emailid}`: An email
	// address that represents a specific Google account. For example,
	// `alice@example.com` . * `serviceAccount:{emailid}`: An email address
	// that represents a Google service account. For example,
	// `my-other-app@appspot.gserviceaccount.com`. *
	// `serviceAccount:{projectid}.svc.id.goog[{namespace}/{kubernetes-sa}]`:
	//  An identifier for a Kubernetes service account
	// (https://cloud.google.com/kubernetes-engine/docs/how-to/kubernetes-service-accounts).
	// For example, `my-project.svc.id.goog[my-namespace/my-kubernetes-sa]`.
	// * `group:{emailid}`: An email address that represents a Google group.
	// For example, `admins@example.com`. * `domain:{domain}`: The G Suite
	// domain (primary) that represents all the users of that domain. For
	// example, `google.com` or `example.com`. *
	// `principal://iam.googleapis.com/locations/global/workforcePools/{pool_
	// id}/subject/{subject_attribute_value}`: A single identity in a
	// workforce identity pool. *
	// `principalSet://iam.googleapis.com/locations/global/workforcePools/{po
	// ol_id}/group/{group_id}`: All workforce identities in a group. *
	// `principalSet://iam.googleapis.com/locations/global/workforcePools/{po
	// ol_id}/attribute.{attribute_name}/{attribute_value}`: All workforce
	// identities with a specific attribute value. *
	// `principalSet://iam.googleapis.com/locations/global/workforcePools/{po
	// ol_id}/*`: All identities in a workforce identity pool. *
	// `principal://iam.googleapis.com/projects/{project_number}/locations/gl
	// obal/workloadIdentityPools/{pool_id}/subject/{subject_attribute_value}
	// `: A single identity in a workload identity pool. *
	// `principalSet://iam.googleapis.com/projects/{project_number}/locations
	// /global/workloadIdentityPools/{pool_id}/group/{group_id}`: A workload
	// identity pool group. *
	// `principalSet://iam.googleapis.com/projects/{project_number}/locations
	// /global/workloadIdentityPools/{pool_id}/attribute.{attribute_name}/{at
	// tribute_value}`: All identities in a workload identity pool with a
	// certain attribute. *
	// `principalSet://iam.googleapis.com/projects/{project_number}/locations
	// /global/workloadIdentityPools/{pool_id}/*`: All identities in a
	// workload identity pool. * `deleted:user:{emailid}?uid={uniqueid}`: An
	// email address (plus unique identifier) representing a user that has
	// been recently deleted. For example,
	// `alice@example.com?uid=123456789012345678901`. If the user is
	// recovered, this value reverts to `user:{emailid}` and the recovered
	// user retains the role in the binding. *
	// `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address
	// (plus unique identifier) representing a service account that has been
	// recently deleted. For example,
	// `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`.
	// If the service account is undeleted, this value reverts to
	// `serviceAccount:{emailid}` and the undeleted service account retains
	// the role in the binding. * `deleted:group:{emailid}?uid={uniqueid}`:
	// An email address (plus unique identifier) representing a Google group
	// that has been recently deleted. For example,
	// `admins@example.com?uid=123456789012345678901`. If the group is
	// recovered, this value reverts to `group:{emailid}` and the recovered
	// group retains the role in the binding. *
	// `deleted:principal://iam.googleapis.com/locations/global/workforcePool
	// s/{pool_id}/subject/{subject_attribute_value}`: Deleted single
	// identity in a workforce identity pool. For example,
	// `deleted:principal://iam.googleapis.com/locations/global/workforcePool
	// s/my-pool-id/subject/my-subject-attribute-value`.
	Members []string `json:"members,omitempty"`

	// Role: Role that is assigned to the list of `members`, or principals.
	// For example, `roles/viewer`, `roles/editor`, or `roles/owner`. For an
	// overview of the IAM roles and permissions, see the IAM documentation
	// (https://cloud.google.com/iam/docs/roles-overview). For a list of the
	// available pre-defined roles, see here
	// (https://cloud.google.com/iam/docs/understanding-roles).
	Role string `json:"role,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Condition") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Condition") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleIamV1Binding) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleIamV1Binding
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleIamV1Policy: An Identity and Access Management (IAM) policy,
// which specifies access controls for Google Cloud resources. A
// `Policy` is a collection of `bindings`. A `binding` binds one or more
// `members`, or principals, to a single `role`. Principals can be user
// accounts, service accounts, Google groups, and domains (such as G
// Suite). A `role` is a named list of permissions; each `role` can be
// an IAM predefined role or a user-created custom role. For some types
// of Google Cloud resources, a `binding` can also specify a
// `condition`, which is a logical expression that allows access to a
// resource only if the expression evaluates to `true`. A condition can
// add constraints based on attributes of the request, the resource, or
// both. To learn which resources support conditions in their IAM
// policies, see the IAM documentation
// (https://cloud.google.com/iam/help/conditions/resource-policies).
// **JSON example:** ``` { "bindings": [ { "role":
// "roles/resourcemanager.organizationAdmin", "members": [
// "user:mike@example.com", "group:admins@example.com",
// "domain:google.com",
// "serviceAccount:my-project-id@appspot.gserviceaccount.com" ] }, {
// "role": "roles/resourcemanager.organizationViewer", "members": [
// "user:eve@example.com" ], "condition": { "title": "expirable access",
// "description": "Does not grant access after Sep 2020", "expression":
// "request.time < timestamp('2020-10-01T00:00:00.000Z')", } } ],
// "etag": "BwWWja0YfJA=", "version": 3 } ``` **YAML example:** ```
// bindings: - members: - user:mike@example.com -
// group:admins@example.com - domain:google.com -
// serviceAccount:my-project-id@appspot.gserviceaccount.com role:
// roles/resourcemanager.organizationAdmin - members: -
// user:eve@example.com role: roles/resourcemanager.organizationViewer
// condition: title: expirable access description: Does not grant access
// after Sep 2020 expression: request.time <
// timestamp('2020-10-01T00:00:00.000Z') etag: BwWWja0YfJA= version: 3
// ``` For a description of IAM and its features, see the IAM
// documentation (https://cloud.google.com/iam/docs/).
type GoogleIamV1Policy struct {
	// AuditConfigs: Specifies cloud audit logging configuration for this
	// policy.
	AuditConfigs []*GoogleIamV1AuditConfig `json:"auditConfigs,omitempty"`

	// Bindings: Associates a list of `members`, or principals, with a
	// `role`. Optionally, may specify a `condition` that determines how and
	// when the `bindings` are applied. Each of the `bindings` must contain
	// at least one principal. The `bindings` in a `Policy` can refer to up
	// to 1,500 principals; up to 250 of these principals can be Google
	// groups. Each occurrence of a principal counts towards these limits.
	// For example, if the `bindings` grant 50 different roles to
	// `user:alice@example.com`, and not to any other principal, then you
	// can add another 1,450 principals to the `bindings` in the `Policy`.
	Bindings []*GoogleIamV1Binding `json:"bindings,omitempty"`

	// Etag: `etag` is used for optimistic concurrency control as a way to
	// help prevent simultaneous updates of a policy from overwriting each
	// other. It is strongly suggested that systems make use of the `etag`
	// in the read-modify-write cycle to perform policy updates in order to
	// avoid race conditions: An `etag` is returned in the response to
	// `getIamPolicy`, and systems are expected to put that etag in the
	// request to `setIamPolicy` to ensure that their change will be applied
	// to the same version of the policy. **Important:** If you use IAM
	// Conditions, you must include the `etag` field whenever you call
	// `setIamPolicy`. If you omit this field, then IAM allows you to
	// overwrite a version `3` policy with a version `1` policy, and all of
	// the conditions in the version `3` policy are lost.
	Etag string `json:"etag,omitempty"`

	// Version: Specifies the format of the policy. Valid values are `0`,
	// `1`, and `3`. Requests that specify an invalid value are rejected.
	// Any operation that affects conditional role bindings must specify
	// version `3`. This requirement applies to the following operations: *
	// Getting a policy that includes a conditional role binding * Adding a
	// conditional role binding to a policy * Changing a conditional role
	// binding in a policy * Removing any role binding, with or without a
	// condition, from a policy that includes conditions **Important:** If
	// you use IAM Conditions, you must include the `etag` field whenever
	// you call `setIamPolicy`. If you omit this field, then IAM allows you
	// to overwrite a version `3` policy with a version `1` policy, and all
	// of the conditions in the version `3` policy are lost. If a policy
	// does not include any conditions, operations on that policy may
	// specify any valid version or leave the field unset. To learn which
	// resources support conditions in their IAM policies, see the IAM
	// documentation
	// (https://cloud.google.com/iam/help/conditions/resource-policies).
	Version int64 `json:"version,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "AuditConfigs") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "AuditConfigs") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleIamV1Policy) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleIamV1Policy
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleIamV1SetIamPolicyRequest: Request message for `SetIamPolicy`
// method.
type GoogleIamV1SetIamPolicyRequest struct {
	// Policy: REQUIRED: The complete policy to be applied to the
	// `resource`. The size of the policy is limited to a few 10s of KB. An
	// empty policy is a valid policy but certain Google Cloud services
	// (such as Projects) might reject them.
	Policy *GoogleIamV1Policy `json:"policy,omitempty"`

	// UpdateMask: OPTIONAL: A FieldMask specifying which fields of the
	// policy to modify. Only the fields in the mask will be modified. If no
	// mask is provided, the following default mask is used: `paths:
	// "bindings, etag"
	UpdateMask string `json:"updateMask,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Policy") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Policy") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleIamV1SetIamPolicyRequest) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleIamV1SetIamPolicyRequest
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleIamV1TestIamPermissionsRequest: Request message for
// `TestIamPermissions` method.
type GoogleIamV1TestIamPermissionsRequest struct {
	// Permissions: The set of permissions to check for the `resource`.
	// Permissions with wildcards (such as `*` or `storage.*`) are not
	// allowed. For more information see IAM Overview
	// (https://cloud.google.com/iam/docs/overview#permissions).
	Permissions []string `json:"permissions,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Permissions") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Permissions") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleIamV1TestIamPermissionsRequest) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleIamV1TestIamPermissionsRequest
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleIamV1TestIamPermissionsResponse: Response message for
// `TestIamPermissions` method.
type GoogleIamV1TestIamPermissionsResponse struct {
	// Permissions: A subset of `TestPermissionsRequest.permissions` that
	// the caller is allowed.
	Permissions []string `json:"permissions,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Permissions") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Permissions") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleIamV1TestIamPermissionsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleIamV1TestIamPermissionsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleLongrunningListOperationsResponse: The response message for
// Operations.ListOperations.
type GoogleLongrunningListOperationsResponse struct {
	// NextPageToken: The standard List next-page token.
	NextPageToken string `json:"nextPageToken,omitempty"`

	// Operations: A list of operations that matches the specified filter in
	// the request.
	Operations []*GoogleLongrunningOperation `json:"operations,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "NextPageToken") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "NextPageToken") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleLongrunningListOperationsResponse) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleLongrunningListOperationsResponse
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleLongrunningOperation: This resource represents a long-running
// operation that is the result of a network API call.
type GoogleLongrunningOperation struct {
	// Done: If the value is `false`, it means the operation is still in
	// progress. If `true`, the operation is completed, and either `error`
	// or `response` is available.
	Done bool `json:"done,omitempty"`

	// Error: The error result of the operation in case of failure or
	// cancellation.
	Error *GoogleRpcStatus `json:"error,omitempty"`

	// Metadata: Service-specific metadata associated with the operation. It
	// typically contains progress information and common metadata such as
	// create time. Some services might not provide such metadata. Any
	// method that returns a long-running operation should document the
	// metadata type, if any.
	Metadata googleapi.RawMessage `json:"metadata,omitempty"`

	// Name: The server-assigned name, which is only unique within the same
	// service that originally returns it. If you use the default HTTP
	// mapping, the `name` should be a resource name ending with
	// `operations/{unique_id}`.
	Name string `json:"name,omitempty"`

	// Response: The normal, successful response of the operation. If the
	// original method returns no data on success, such as `Delete`, the
	// response is `google.protobuf.Empty`. If the original method is
	// standard `Get`/`Create`/`Update`, the response should be the
	// resource. For other methods, the response should have the type
	// `XxxResponse`, where `Xxx` is the original method name. For example,
	// if the original method name is `TakeSnapshot()`, the inferred
	// response type is `TakeSnapshotResponse`.
	Response googleapi.RawMessage `json:"response,omitempty"`

	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`

	// ForceSendFields is a list of field names (e.g. "Done") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Done") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleLongrunningOperation) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleLongrunningOperation
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleProtobufEmpty: A generic empty message that you can re-use to
// avoid defining duplicated empty messages in your APIs. A typical
// example is to use it as the request or the response type of an API
// method. For instance: service Foo { rpc Bar(google.protobuf.Empty)
// returns (google.protobuf.Empty); }
type GoogleProtobufEmpty struct {
	// ServerResponse contains the HTTP response code and headers from the
	// server.
	googleapi.ServerResponse `json:"-"`
}

// GoogleRpcPreconditionFailure: Describes what preconditions have
// failed. For example, if an RPC failed because it required the Terms
// of Service to be acknowledged, it could list the terms of service
// violation in the PreconditionFailure message.
type GoogleRpcPreconditionFailure struct {
	// Violations: Describes all precondition violations.
	Violations []*GoogleRpcPreconditionFailureViolation `json:"violations,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Violations") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Violations") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleRpcPreconditionFailure) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleRpcPreconditionFailure
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleRpcPreconditionFailureViolation: A message type used to
// describe a single precondition failure.
type GoogleRpcPreconditionFailureViolation struct {
	// Description: A description of how the precondition failed. Developers
	// can use this description to understand how to fix the failure. For
	// example: "Terms of service not accepted".
	Description string `json:"description,omitempty"`

	// Subject: The subject, relative to the type, that failed. For example,
	// "google.com/cloud" relative to the "TOS" type would indicate which
	// terms of service is being referenced.
	Subject string `json:"subject,omitempty"`

	// Type: The type of PreconditionFailure. We recommend using a
	// service-specific enum type to define the supported precondition
	// violation subjects. For example, "TOS" for "Terms of Service
	// violation".
	Type string `json:"type,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Description") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Description") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleRpcPreconditionFailureViolation) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleRpcPreconditionFailureViolation
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleRpcStatus: The `Status` type defines a logical error model that
// is suitable for different programming environments, including REST
// APIs and RPC APIs. It is used by gRPC (https://github.com/grpc). Each
// `Status` message contains three pieces of data: error code, error
// message, and error details. You can find out more about this error
// model and how to work with it in the API Design Guide
// (https://cloud.google.com/apis/design/errors).
type GoogleRpcStatus struct {
	// Code: The status code, which should be an enum value of
	// google.rpc.Code.
	Code int64 `json:"code,omitempty"`

	// Details: A list of messages that carry the error details. There is a
	// common set of message types for APIs to use.
	Details []googleapi.RawMessage `json:"details,omitempty"`

	// Message: A developer-facing error message, which should be in
	// English. Any user-facing error message should be localized and sent
	// in the google.rpc.Status.details field, or localized by the client.
	Message string `json:"message,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Code") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Code") to include in API
	// requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleRpcStatus) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleRpcStatus
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleTypeExpr: Represents a textual expression in the Common
// Expression Language (CEL) syntax. CEL is a C-like expression
// language. The syntax and semantics of CEL are documented at
// https://github.com/google/cel-spec. Example (Comparison): title:
// "Summary size limit" description: "Determines if a summary is less
// than 100 chars" expression: "document.summary.size() < 100" Example
// (Equality): title: "Requestor is owner" description: "Determines if
// requestor is the document owner" expression: "document.owner ==
// request.auth.claims.email" Example (Logic): title: "Public documents"
// description: "Determine whether the document should be publicly
// visible" expression: "document.type != 'private' && document.type !=
// 'internal'" Example (Data Manipulation): title: "Notification string"
// description: "Create a notification string with a timestamp."
// expression: "'New message received at ' +
// string(document.create_time)" The exact variables and functions that
// may be referenced within an expression are determined by the service
// that evaluates it. See the service documentation for additional
// information.
type GoogleTypeExpr struct {
	// Description: Optional. Description of the expression. This is a
	// longer text which describes the expression, e.g. when hovered over it
	// in a UI.
	Description string `json:"description,omitempty"`

	// Expression: Textual representation of an expression in Common
	// Expression Language syntax.
	Expression string `json:"expression,omitempty"`

	// Location: Optional. String indicating the location of the expression
	// for error reporting, e.g. a file name and a position in the file.
	Location string `json:"location,omitempty"`

	// Title: Optional. Title for the expression, i.e. a short string
	// describing its purpose. This can be used e.g. in UIs which allow to
	// enter the expression.
	Title string `json:"title,omitempty"`

	// ForceSendFields is a list of field names (e.g. "Description") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "Description") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleTypeExpr) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleTypeExpr
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleTypeInterval: Represents a time interval, encoded as a
// Timestamp start (inclusive) and a Timestamp end (exclusive). The
// start must be less than or equal to the end. When the start equals
// the end, the interval is empty (matches no time). When both start and
// end are unspecified, the interval matches any time.
type GoogleTypeInterval struct {
	// EndTime: Optional. Exclusive end of the interval. If specified, a
	// Timestamp matching this interval will have to be before the end.
	EndTime string `json:"endTime,omitempty"`

	// StartTime: Optional. Inclusive start of the interval. If specified, a
	// Timestamp matching this interval will have to be the same or after
	// the start.
	StartTime string `json:"startTime,omitempty"`

	// ForceSendFields is a list of field names (e.g. "EndTime") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "EndTime") to include in
	// API requests with the JSON null value. By default, fields with empty
	// values are omitted from API requests. However, any field with an
	// empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleTypeInterval) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleTypeInterval
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// GoogleTypeMoney: Represents an amount of money with its currency
// type.
type GoogleTypeMoney struct {
	// CurrencyCode: The three-letter currency code defined in ISO 4217.
	CurrencyCode string `json:"currencyCode,omitempty"`

	// Nanos: Number of nano (10^-9) units of the amount. The value must be
	// between -999,999,999 and +999,999,999 inclusive. If `units` is
	// positive, `nanos` must be positive or zero. If `units` is zero,
	// `nanos` can be positive, zero, or negative. If `units` is negative,
	// `nanos` must be negative or zero. For example $-1.75 is represented
	// as `units`=-1 and `nanos`=-750,000,000.
	Nanos int64 `json:"nanos,omitempty"`

	// Units: The whole units of the amount. For example if `currencyCode`
	// is "USD", then 1 unit is one US dollar.
	Units int64 `json:"units,omitempty,string"`

	// ForceSendFields is a list of field names (e.g. "CurrencyCode") to
	// unconditionally include in API requests. By default, fields with
	// empty or default values are omitted from API requests. However, any
	// non-pointer, non-interface field appearing in ForceSendFields will be
	// sent to the server regardless of whether the field is empty or not.
	// This may be used to include empty fields in Patch requests.
	ForceSendFields []string `json:"-"`

	// NullFields is a list of field names (e.g. "CurrencyCode") to include
	// in API requests with the JSON null value. By default, fields with
	// empty values are omitted from API requests. However, any field with
	// an empty value appearing in NullFields will be sent to the server as
	// null. It is an error if a field in this list has a non-empty value.
	// This may be used to include null fields in Patch requests.
	NullFields []string `json:"-"`
}

func (s *GoogleTypeMoney) MarshalJSON() ([]byte, error) {
	type NoMethod GoogleTypeMoney
	raw := NoMethod(*s)
	return gensupport.MarshalJSON(raw, s.ForceSendFields, s.NullFields)
}

// method id "apigee.hybrid.issuers.list":

type HybridIssuersListCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists hybrid services and its trusted issuers service account
// ids. This api is authenticated and unauthorized(allow all the users)
// and used by runtime authn-authz service to query control plane's
// issuer service account ids.
//
// - name: Must be of the form `hybrid/issuers`.
func (r *HybridIssuersService) List(name string) *HybridIssuersListCall {
	c := &HybridIssuersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *HybridIssuersListCall) Fields(s ...googleapi.Field) *HybridIssuersListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *HybridIssuersListCall) IfNoneMatch(entityTag string) *HybridIssuersListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *HybridIssuersListCall) Context(ctx context.Context) *HybridIssuersListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *HybridIssuersListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *HybridIssuersListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.hybrid.issuers.list" call.
// Exactly one of *GoogleCloudApigeeV1ListHybridIssuersResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListHybridIssuersResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *HybridIssuersListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListHybridIssuersResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListHybridIssuersResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists hybrid services and its trusted issuers service account ids. This api is authenticated and unauthorized(allow all the users) and used by runtime authn-authz service to query control plane's issuer service account ids.",
	//   "flatPath": "v1/hybrid/issuers",
	//   "httpMethod": "GET",
	//   "id": "apigee.hybrid.issuers.list",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Must be of the form `hybrid/issuers`.",
	//       "location": "path",
	//       "pattern": "^hybrid/issuers$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListHybridIssuersResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.create":

type OrganizationsCreateCall struct {
	s                               *Service
	googlecloudapigeev1organization *GoogleCloudApigeeV1Organization
	urlParams_                      gensupport.URLParams
	ctx_                            context.Context
	header_                         http.Header
}

// Create: Creates an Apigee organization. See Create an Apigee
// organization
// (https://cloud.google.com/apigee/docs/api-platform/get-started/create-org).
func (r *OrganizationsService) Create(googlecloudapigeev1organization *GoogleCloudApigeeV1Organization) *OrganizationsCreateCall {
	c := &OrganizationsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.googlecloudapigeev1organization = googlecloudapigeev1organization
	return c
}

// Parent sets the optional parameter "parent": Required. Name of the
// Google Cloud project in which to associate the Apigee organization.
// Pass the information as a query parameter using the following
// structure in your request: `projects/`
func (c *OrganizationsCreateCall) Parent(parent string) *OrganizationsCreateCall {
	c.urlParams_.Set("parent", parent)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsCreateCall) Fields(s ...googleapi.Field) *OrganizationsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsCreateCall) Context(ctx context.Context) *OrganizationsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1organization)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/organizations")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.create" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates an Apigee organization. See [Create an Apigee organization](https://cloud.google.com/apigee/docs/api-platform/get-started/create-org).",
	//   "flatPath": "v1/organizations",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.create",
	//   "parameterOrder": [],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the Google Cloud project in which to associate the Apigee organization. Pass the information as a query parameter using the following structure in your request: `projects/`",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/organizations",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Organization"
	//   },
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.delete":

type OrganizationsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Delete an Apigee organization. For organizations with
// BillingType EVALUATION, an immediate deletion is performed. For paid
// organizations (Subscription or Pay-as-you-go), a soft-deletion is
// performed. The organization can be restored within the soft-deletion
// period, which is specified using the `retention` field in the request
// or by filing a support ticket with Apigee. During the data retention
// period specified in the request, the Apigee organization cannot be
// recreated in the same Google Cloud project. **IMPORTANT: The default
// data retention setting for this operation is 7 days. To permanently
// delete the organization in 24 hours, set the retention parameter to
// `MINIMUM`.**
//
//   - name: Name of the organization. Use the following structure in your
//     request: `organizations/{org}`.
func (r *OrganizationsService) Delete(name string) *OrganizationsDeleteCall {
	c := &OrganizationsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Retention sets the optional parameter "retention": This setting is
// applicable only for organizations that are soft-deleted (i.e.,
// BillingType is not EVALUATION). It controls how long Organization
// data will be retained after the initial delete operation completes.
// During this period, the Organization may be restored to its last
// known state. After this period, the Organization will no longer be
// able to be restored. **Note: During the data retention period
// specified using this field, the Apigee organization cannot be
// recreated in the same GCP project.**
//
// Possible values:
//
//	"DELETION_RETENTION_UNSPECIFIED" - Default data retention setting
//
// of seven days will be applied.
//
//	"MINIMUM" - Organization data will be retained for the minimum
//
// period of 24 hours.
func (c *OrganizationsDeleteCall) Retention(retention string) *OrganizationsDeleteCall {
	c.urlParams_.Set("retention", retention)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDeleteCall) Context(ctx context.Context) *OrganizationsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.delete" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Delete an Apigee organization. For organizations with BillingType EVALUATION, an immediate deletion is performed. For paid organizations (Subscription or Pay-as-you-go), a soft-deletion is performed. The organization can be restored within the soft-deletion period, which is specified using the `retention` field in the request or by filing a support ticket with Apigee. During the data retention period specified in the request, the Apigee organization cannot be recreated in the same Google Cloud project. **IMPORTANT: The default data retention setting for this operation is 7 days. To permanently delete the organization in 24 hours, set the retention parameter to `MINIMUM`.**",
	//   "flatPath": "v1/organizations/{organizationsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the organization. Use the following structure in your request: `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "retention": {
	//       "description": "Optional. This setting is applicable only for organizations that are soft-deleted (i.e., BillingType is not EVALUATION). It controls how long Organization data will be retained after the initial delete operation completes. During this period, the Organization may be restored to its last known state. After this period, the Organization will no longer be able to be restored. **Note: During the data retention period specified using this field, the Apigee organization cannot be recreated in the same GCP project.**",
	//       "enum": [
	//         "DELETION_RETENTION_UNSPECIFIED",
	//         "MINIMUM"
	//       ],
	//       "enumDescriptions": [
	//         "Default data retention setting of seven days will be applied.",
	//         "Organization data will be retained for the minimum period of 24 hours."
	//       ],
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.get":

type OrganizationsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets the profile for an Apigee organization. See Understanding
// organizations
// (https://cloud.google.com/apigee/docs/api-platform/fundamentals/organization-structure).
//
//   - name: Apigee organization name in the following format:
//     `organizations/{org}`.
func (r *OrganizationsService) Get(name string) *OrganizationsGetCall {
	c := &OrganizationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsGetCall) Fields(s ...googleapi.Field) *OrganizationsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsGetCall) IfNoneMatch(entityTag string) *OrganizationsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsGetCall) Context(ctx context.Context) *OrganizationsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.get" call.
// Exactly one of *GoogleCloudApigeeV1Organization or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Organization.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Organization, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Organization{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the profile for an Apigee organization. See [Understanding organizations](https://cloud.google.com/apigee/docs/api-platform/fundamentals/organization-structure).",
	//   "flatPath": "v1/organizations/{organizationsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Apigee organization name in the following format: `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Organization"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.getDeployedIngressConfig":

type OrganizationsGetDeployedIngressConfigCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetDeployedIngressConfig: Gets the deployed ingress configuration for
// an organization.
//
//   - name: Name of the deployed configuration for the organization in
//     the following format: 'organizations/{org}/deployedIngressConfig'.
func (r *OrganizationsService) GetDeployedIngressConfig(name string) *OrganizationsGetDeployedIngressConfigCall {
	c := &OrganizationsGetDeployedIngressConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// View sets the optional parameter "view": When set to FULL, additional
// details about the specific deployments receiving traffic will be
// included in the IngressConfig response's RoutingRules.
//
// Possible values:
//
//	"INGRESS_CONFIG_VIEW_UNSPECIFIED" - The default/unset value. The
//
// API will default to the BASIC view.
//
//	"BASIC" - Include all ingress config data necessary for the runtime
//
// to configure ingress, but no more. Routing rules will include only
// basepath and destination environment. This the default value.
//
//	"FULL" - Include all ingress config data, including internal debug
//
// info for each routing rule such as the proxy claiming a particular
// basepath and when the routing rule first appeared in the env group.
func (c *OrganizationsGetDeployedIngressConfigCall) View(view string) *OrganizationsGetDeployedIngressConfigCall {
	c.urlParams_.Set("view", view)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsGetDeployedIngressConfigCall) Fields(s ...googleapi.Field) *OrganizationsGetDeployedIngressConfigCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsGetDeployedIngressConfigCall) IfNoneMatch(entityTag string) *OrganizationsGetDeployedIngressConfigCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsGetDeployedIngressConfigCall) Context(ctx context.Context) *OrganizationsGetDeployedIngressConfigCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsGetDeployedIngressConfigCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsGetDeployedIngressConfigCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.getDeployedIngressConfig" call.
// Exactly one of *GoogleCloudApigeeV1IngressConfig or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1IngressConfig.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsGetDeployedIngressConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1IngressConfig, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1IngressConfig{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the deployed ingress configuration for an organization.",
	//   "flatPath": "v1/organizations/{organizationsId}/deployedIngressConfig",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.getDeployedIngressConfig",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the deployed configuration for the organization in the following format: 'organizations/{org}/deployedIngressConfig'.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/deployedIngressConfig$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "view": {
	//       "description": "When set to FULL, additional details about the specific deployments receiving traffic will be included in the IngressConfig response's RoutingRules.",
	//       "enum": [
	//         "INGRESS_CONFIG_VIEW_UNSPECIFIED",
	//         "BASIC",
	//         "FULL"
	//       ],
	//       "enumDescriptions": [
	//         "The default/unset value. The API will default to the BASIC view.",
	//         "Include all ingress config data necessary for the runtime to configure ingress, but no more. Routing rules will include only basepath and destination environment. This the default value.",
	//         "Include all ingress config data, including internal debug info for each routing rule such as the proxy claiming a particular basepath and when the routing rule first appeared in the env group."
	//       ],
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1IngressConfig"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.getProjectMapping":

type OrganizationsGetProjectMappingCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetProjectMapping: Gets the project ID and region for an Apigee
// organization.
//
//   - name: Apigee organization name in the following format:
//     `organizations/{org}`.
func (r *OrganizationsService) GetProjectMapping(name string) *OrganizationsGetProjectMappingCall {
	c := &OrganizationsGetProjectMappingCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsGetProjectMappingCall) Fields(s ...googleapi.Field) *OrganizationsGetProjectMappingCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsGetProjectMappingCall) IfNoneMatch(entityTag string) *OrganizationsGetProjectMappingCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsGetProjectMappingCall) Context(ctx context.Context) *OrganizationsGetProjectMappingCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsGetProjectMappingCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsGetProjectMappingCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:getProjectMapping")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.getProjectMapping" call.
// Exactly one of *GoogleCloudApigeeV1OrganizationProjectMapping or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1OrganizationProjectMapping.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsGetProjectMappingCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1OrganizationProjectMapping, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1OrganizationProjectMapping{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the project ID and region for an Apigee organization.",
	//   "flatPath": "v1/organizations/{organizationsId}:getProjectMapping",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.getProjectMapping",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Apigee organization name in the following format: `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}:getProjectMapping",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1OrganizationProjectMapping"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.getRuntimeConfig":

type OrganizationsGetRuntimeConfigCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetRuntimeConfig: Get runtime config for an organization.
//
//   - name: Name of the runtime config for the organization in the
//     following format: 'organizations/{org}/runtimeConfig'.
func (r *OrganizationsService) GetRuntimeConfig(name string) *OrganizationsGetRuntimeConfigCall {
	c := &OrganizationsGetRuntimeConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsGetRuntimeConfigCall) Fields(s ...googleapi.Field) *OrganizationsGetRuntimeConfigCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsGetRuntimeConfigCall) IfNoneMatch(entityTag string) *OrganizationsGetRuntimeConfigCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsGetRuntimeConfigCall) Context(ctx context.Context) *OrganizationsGetRuntimeConfigCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsGetRuntimeConfigCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsGetRuntimeConfigCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.getRuntimeConfig" call.
// Exactly one of *GoogleCloudApigeeV1RuntimeConfig or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1RuntimeConfig.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsGetRuntimeConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1RuntimeConfig, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1RuntimeConfig{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Get runtime config for an organization.",
	//   "flatPath": "v1/organizations/{organizationsId}/runtimeConfig",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.getRuntimeConfig",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the runtime config for the organization in the following format: 'organizations/{org}/runtimeConfig'.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/runtimeConfig$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1RuntimeConfig"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.getSecuritySettings":

type OrganizationsGetSecuritySettingsCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetSecuritySettings: GetSecuritySettings gets the security settings
// for API Security.
//
//   - name: The name of the SecuritySettings to retrieve. This will
//     always be: 'organizations/{org}/securitySettings'.
func (r *OrganizationsService) GetSecuritySettings(name string) *OrganizationsGetSecuritySettingsCall {
	c := &OrganizationsGetSecuritySettingsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsGetSecuritySettingsCall) Fields(s ...googleapi.Field) *OrganizationsGetSecuritySettingsCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsGetSecuritySettingsCall) IfNoneMatch(entityTag string) *OrganizationsGetSecuritySettingsCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsGetSecuritySettingsCall) Context(ctx context.Context) *OrganizationsGetSecuritySettingsCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsGetSecuritySettingsCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsGetSecuritySettingsCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.getSecuritySettings" call.
// Exactly one of *GoogleCloudApigeeV1SecuritySettings or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SecuritySettings.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsGetSecuritySettingsCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecuritySettings, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecuritySettings{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "GetSecuritySettings gets the security settings for API Security.",
	//   "flatPath": "v1/organizations/{organizationsId}/securitySettings",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.getSecuritySettings",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the SecuritySettings to retrieve. This will always be: 'organizations/{org}/securitySettings'.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/securitySettings$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecuritySettings"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.getSyncAuthorization":

type OrganizationsGetSyncAuthorizationCall struct {
	s                                              *Service
	name                                           string
	googlecloudapigeev1getsyncauthorizationrequest *GoogleCloudApigeeV1GetSyncAuthorizationRequest
	urlParams_                                     gensupport.URLParams
	ctx_                                           context.Context
	header_                                        http.Header
}

// GetSyncAuthorization: Lists the service accounts with the permissions
// required to allow the Synchronizer to download environment data from
// the control plane. An ETag is returned in the response to
// `getSyncAuthorization`. Pass that ETag when calling
// setSyncAuthorization (setSyncAuthorization) to ensure that you are
// updating the correct version. If you don't pass the ETag in the call
// to `setSyncAuthorization`, then the existing authorization is
// overwritten indiscriminately. For more information, see Configure the
// Synchronizer
// (https://cloud.google.com/apigee/docs/hybrid/latest/synchronizer-access).
// **Note**: Available to Apigee hybrid only.
//
//   - name: Name of the Apigee organization. Use the following structure
//     in your request: `organizations/{org}`.
func (r *OrganizationsService) GetSyncAuthorization(name string, googlecloudapigeev1getsyncauthorizationrequest *GoogleCloudApigeeV1GetSyncAuthorizationRequest) *OrganizationsGetSyncAuthorizationCall {
	c := &OrganizationsGetSyncAuthorizationCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1getsyncauthorizationrequest = googlecloudapigeev1getsyncauthorizationrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsGetSyncAuthorizationCall) Fields(s ...googleapi.Field) *OrganizationsGetSyncAuthorizationCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsGetSyncAuthorizationCall) Context(ctx context.Context) *OrganizationsGetSyncAuthorizationCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsGetSyncAuthorizationCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsGetSyncAuthorizationCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1getsyncauthorizationrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:getSyncAuthorization")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.getSyncAuthorization" call.
// Exactly one of *GoogleCloudApigeeV1SyncAuthorization or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SyncAuthorization.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsGetSyncAuthorizationCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SyncAuthorization, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SyncAuthorization{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists the service accounts with the permissions required to allow the Synchronizer to download environment data from the control plane. An ETag is returned in the response to `getSyncAuthorization`. Pass that ETag when calling [setSyncAuthorization](setSyncAuthorization) to ensure that you are updating the correct version. If you don't pass the ETag in the call to `setSyncAuthorization`, then the existing authorization is overwritten indiscriminately. For more information, see [Configure the Synchronizer](https://cloud.google.com/apigee/docs/hybrid/latest/synchronizer-access). **Note**: Available to Apigee hybrid only.",
	//   "flatPath": "v1/organizations/{organizationsId}:getSyncAuthorization",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.getSyncAuthorization",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the Apigee organization. Use the following structure in your request: `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}:getSyncAuthorization",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1GetSyncAuthorizationRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SyncAuthorization"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.list":

type OrganizationsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists the Apigee organizations and associated Google Cloud
// projects that you have permission to access. See Understanding
// organizations
// (https://cloud.google.com/apigee/docs/api-platform/fundamentals/organization-structure).
//
//   - parent: Use the following structure in your request:
//     `organizations`.
func (r *OrganizationsService) List(parent string) *OrganizationsListCall {
	c := &OrganizationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsListCall) Fields(s ...googleapi.Field) *OrganizationsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsListCall) IfNoneMatch(entityTag string) *OrganizationsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsListCall) Context(ctx context.Context) *OrganizationsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.list" call.
// Exactly one of *GoogleCloudApigeeV1ListOrganizationsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListOrganizationsResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListOrganizationsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListOrganizationsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists the Apigee organizations and associated Google Cloud projects that you have permission to access. See [Understanding organizations](https://cloud.google.com/apigee/docs/api-platform/fundamentals/organization-structure).",
	//   "flatPath": "v1/organizations",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Use the following structure in your request: `organizations`",
	//       "location": "path",
	//       "pattern": "^organizations$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListOrganizationsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.setAddons":

type OrganizationsSetAddonsCall struct {
	s                                   *Service
	org                                 string
	googlecloudapigeev1setaddonsrequest *GoogleCloudApigeeV1SetAddonsRequest
	urlParams_                          gensupport.URLParams
	ctx_                                context.Context
	header_                             http.Header
}

// SetAddons: Configures the add-ons for the Apigee organization. The
// existing add-on configuration will be fully replaced.
//
//   - org: Name of the organization. Use the following structure in your
//     request: `organizations/{org}`.
func (r *OrganizationsService) SetAddons(org string, googlecloudapigeev1setaddonsrequest *GoogleCloudApigeeV1SetAddonsRequest) *OrganizationsSetAddonsCall {
	c := &OrganizationsSetAddonsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.org = org
	c.googlecloudapigeev1setaddonsrequest = googlecloudapigeev1setaddonsrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSetAddonsCall) Fields(s ...googleapi.Field) *OrganizationsSetAddonsCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSetAddonsCall) Context(ctx context.Context) *OrganizationsSetAddonsCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSetAddonsCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSetAddonsCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1setaddonsrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+org}:setAddons")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"org": c.org,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.setAddons" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsSetAddonsCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Configures the add-ons for the Apigee organization. The existing add-on configuration will be fully replaced.",
	//   "flatPath": "v1/organizations/{organizationsId}:setAddons",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.setAddons",
	//   "parameterOrder": [
	//     "org"
	//   ],
	//   "parameters": {
	//     "org": {
	//       "description": "Required. Name of the organization. Use the following structure in your request: `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+org}:setAddons",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1SetAddonsRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.setSyncAuthorization":

type OrganizationsSetSyncAuthorizationCall struct {
	s                                    *Service
	name                                 string
	googlecloudapigeev1syncauthorization *GoogleCloudApigeeV1SyncAuthorization
	urlParams_                           gensupport.URLParams
	ctx_                                 context.Context
	header_                              http.Header
}

// SetSyncAuthorization: Sets the permissions required to allow the
// Synchronizer to download environment data from the control plane. You
// must call this API to enable proper functioning of hybrid. Pass the
// ETag when calling `setSyncAuthorization` to ensure that you are
// updating the correct version. To get an ETag, call
// getSyncAuthorization (getSyncAuthorization). If you don't pass the
// ETag in the call to `setSyncAuthorization`, then the existing
// authorization is overwritten indiscriminately. For more information,
// see Configure the Synchronizer
// (https://cloud.google.com/apigee/docs/hybrid/latest/synchronizer-access).
// **Note**: Available to Apigee hybrid only.
//
//   - name: Name of the Apigee organization. Use the following structure
//     in your request: `organizations/{org}`.
func (r *OrganizationsService) SetSyncAuthorization(name string, googlecloudapigeev1syncauthorization *GoogleCloudApigeeV1SyncAuthorization) *OrganizationsSetSyncAuthorizationCall {
	c := &OrganizationsSetSyncAuthorizationCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1syncauthorization = googlecloudapigeev1syncauthorization
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSetSyncAuthorizationCall) Fields(s ...googleapi.Field) *OrganizationsSetSyncAuthorizationCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSetSyncAuthorizationCall) Context(ctx context.Context) *OrganizationsSetSyncAuthorizationCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSetSyncAuthorizationCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSetSyncAuthorizationCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1syncauthorization)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:setSyncAuthorization")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.setSyncAuthorization" call.
// Exactly one of *GoogleCloudApigeeV1SyncAuthorization or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SyncAuthorization.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSetSyncAuthorizationCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SyncAuthorization, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SyncAuthorization{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Sets the permissions required to allow the Synchronizer to download environment data from the control plane. You must call this API to enable proper functioning of hybrid. Pass the ETag when calling `setSyncAuthorization` to ensure that you are updating the correct version. To get an ETag, call [getSyncAuthorization](getSyncAuthorization). If you don't pass the ETag in the call to `setSyncAuthorization`, then the existing authorization is overwritten indiscriminately. For more information, see [Configure the Synchronizer](https://cloud.google.com/apigee/docs/hybrid/latest/synchronizer-access). **Note**: Available to Apigee hybrid only.",
	//   "flatPath": "v1/organizations/{organizationsId}:setSyncAuthorization",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.setSyncAuthorization",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the Apigee organization. Use the following structure in your request: `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}:setSyncAuthorization",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1SyncAuthorization"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SyncAuthorization"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.update":

type OrganizationsUpdateCall struct {
	s                               *Service
	name                            string
	googlecloudapigeev1organization *GoogleCloudApigeeV1Organization
	urlParams_                      gensupport.URLParams
	ctx_                            context.Context
	header_                         http.Header
}

// Update: Updates the properties for an Apigee organization. No other
// fields in the organization profile will be updated.
//
//   - name: Apigee organization name in the following format:
//     `organizations/{org}`.
func (r *OrganizationsService) Update(name string, googlecloudapigeev1organization *GoogleCloudApigeeV1Organization) *OrganizationsUpdateCall {
	c := &OrganizationsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1organization = googlecloudapigeev1organization
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsUpdateCall) Fields(s ...googleapi.Field) *OrganizationsUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsUpdateCall) Context(ctx context.Context) *OrganizationsUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1organization)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.update" call.
// Exactly one of *GoogleCloudApigeeV1Organization or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Organization.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Organization, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Organization{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates the properties for an Apigee organization. No other fields in the organization profile will be updated.",
	//   "flatPath": "v1/organizations/{organizationsId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.update",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Apigee organization name in the following format: `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Organization"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Organization"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.updateSecuritySettings":

type OrganizationsUpdateSecuritySettingsCall struct {
	s                                   *Service
	name                                string
	googlecloudapigeev1securitysettings *GoogleCloudApigeeV1SecuritySettings
	urlParams_                          gensupport.URLParams
	ctx_                                context.Context
	header_                             http.Header
}

// UpdateSecuritySettings: UpdateSecuritySettings updates the current
// security settings for API Security.
//
//   - name: Identifier. Full resource name is always
//     `organizations/{org}/securitySettings`.
func (r *OrganizationsService) UpdateSecuritySettings(name string, googlecloudapigeev1securitysettings *GoogleCloudApigeeV1SecuritySettings) *OrganizationsUpdateSecuritySettingsCall {
	c := &OrganizationsUpdateSecuritySettingsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1securitysettings = googlecloudapigeev1securitysettings
	return c
}

// UpdateMask sets the optional parameter "updateMask": The list of
// fields to update. Allowed fields are: -
// ml_retraining_feedback_enabled
func (c *OrganizationsUpdateSecuritySettingsCall) UpdateMask(updateMask string) *OrganizationsUpdateSecuritySettingsCall {
	c.urlParams_.Set("updateMask", updateMask)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsUpdateSecuritySettingsCall) Fields(s ...googleapi.Field) *OrganizationsUpdateSecuritySettingsCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsUpdateSecuritySettingsCall) Context(ctx context.Context) *OrganizationsUpdateSecuritySettingsCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsUpdateSecuritySettingsCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsUpdateSecuritySettingsCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1securitysettings)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PATCH", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.updateSecuritySettings" call.
// Exactly one of *GoogleCloudApigeeV1SecuritySettings or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SecuritySettings.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsUpdateSecuritySettingsCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecuritySettings, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecuritySettings{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "UpdateSecuritySettings updates the current security settings for API Security.",
	//   "flatPath": "v1/organizations/{organizationsId}/securitySettings",
	//   "httpMethod": "PATCH",
	//   "id": "apigee.organizations.updateSecuritySettings",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Identifier. Full resource name is always `organizations/{org}/securitySettings`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/securitySettings$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "updateMask": {
	//       "description": "Optional. The list of fields to update. Allowed fields are: - ml_retraining_feedback_enabled",
	//       "format": "google-fieldmask",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1SecuritySettings"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecuritySettings"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.analytics.datastores.create":

type OrganizationsAnalyticsDatastoresCreateCall struct {
	s                            *Service
	parent                       string
	googlecloudapigeev1datastore *GoogleCloudApigeeV1Datastore
	urlParams_                   gensupport.URLParams
	ctx_                         context.Context
	header_                      http.Header
}

// Create: Create a Datastore for an org
//
//   - parent: The parent organization name. Must be of the form
//     `organizations/{org}`.
func (r *OrganizationsAnalyticsDatastoresService) Create(parent string, googlecloudapigeev1datastore *GoogleCloudApigeeV1Datastore) *OrganizationsAnalyticsDatastoresCreateCall {
	c := &OrganizationsAnalyticsDatastoresCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1datastore = googlecloudapigeev1datastore
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAnalyticsDatastoresCreateCall) Fields(s ...googleapi.Field) *OrganizationsAnalyticsDatastoresCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAnalyticsDatastoresCreateCall) Context(ctx context.Context) *OrganizationsAnalyticsDatastoresCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAnalyticsDatastoresCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAnalyticsDatastoresCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1datastore)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/analytics/datastores")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.analytics.datastores.create" call.
// Exactly one of *GoogleCloudApigeeV1Datastore or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Datastore.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsAnalyticsDatastoresCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Datastore, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Datastore{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Create a Datastore for an org",
	//   "flatPath": "v1/organizations/{organizationsId}/analytics/datastores",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.analytics.datastores.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. The parent organization name. Must be of the form `organizations/{org}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/analytics/datastores",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Datastore"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Datastore"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.analytics.datastores.delete":

type OrganizationsAnalyticsDatastoresDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Delete a Datastore from an org.
//
//   - name: Resource name of the Datastore to be deleted. Must be of the
//     form `organizations/{org}/analytics/datastores/{datastoreId}`.
func (r *OrganizationsAnalyticsDatastoresService) Delete(name string) *OrganizationsAnalyticsDatastoresDeleteCall {
	c := &OrganizationsAnalyticsDatastoresDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAnalyticsDatastoresDeleteCall) Fields(s ...googleapi.Field) *OrganizationsAnalyticsDatastoresDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAnalyticsDatastoresDeleteCall) Context(ctx context.Context) *OrganizationsAnalyticsDatastoresDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAnalyticsDatastoresDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAnalyticsDatastoresDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.analytics.datastores.delete" call.
// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsAnalyticsDatastoresDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleProtobufEmpty{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Delete a Datastore from an org.",
	//   "flatPath": "v1/organizations/{organizationsId}/analytics/datastores/{datastoresId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.analytics.datastores.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Resource name of the Datastore to be deleted. Must be of the form `organizations/{org}/analytics/datastores/{datastoreId}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/analytics/datastores/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleProtobufEmpty"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.analytics.datastores.get":

type OrganizationsAnalyticsDatastoresGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Get a Datastore
//
//   - name: Resource name of the Datastore to be get. Must be of the form
//     `organizations/{org}/analytics/datastores/{datastoreId}`.
func (r *OrganizationsAnalyticsDatastoresService) Get(name string) *OrganizationsAnalyticsDatastoresGetCall {
	c := &OrganizationsAnalyticsDatastoresGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAnalyticsDatastoresGetCall) Fields(s ...googleapi.Field) *OrganizationsAnalyticsDatastoresGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsAnalyticsDatastoresGetCall) IfNoneMatch(entityTag string) *OrganizationsAnalyticsDatastoresGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAnalyticsDatastoresGetCall) Context(ctx context.Context) *OrganizationsAnalyticsDatastoresGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAnalyticsDatastoresGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAnalyticsDatastoresGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.analytics.datastores.get" call.
// Exactly one of *GoogleCloudApigeeV1Datastore or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Datastore.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsAnalyticsDatastoresGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Datastore, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Datastore{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Get a Datastore",
	//   "flatPath": "v1/organizations/{organizationsId}/analytics/datastores/{datastoresId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.analytics.datastores.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Resource name of the Datastore to be get. Must be of the form `organizations/{org}/analytics/datastores/{datastoreId}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/analytics/datastores/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Datastore"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.analytics.datastores.list":

type OrganizationsAnalyticsDatastoresListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: List Datastores
//
//   - parent: The parent organization name. Must be of the form
//     `organizations/{org}`.
func (r *OrganizationsAnalyticsDatastoresService) List(parent string) *OrganizationsAnalyticsDatastoresListCall {
	c := &OrganizationsAnalyticsDatastoresListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// TargetType sets the optional parameter "targetType": TargetType is
// used to fetch all Datastores that match the type
func (c *OrganizationsAnalyticsDatastoresListCall) TargetType(targetType string) *OrganizationsAnalyticsDatastoresListCall {
	c.urlParams_.Set("targetType", targetType)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAnalyticsDatastoresListCall) Fields(s ...googleapi.Field) *OrganizationsAnalyticsDatastoresListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsAnalyticsDatastoresListCall) IfNoneMatch(entityTag string) *OrganizationsAnalyticsDatastoresListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAnalyticsDatastoresListCall) Context(ctx context.Context) *OrganizationsAnalyticsDatastoresListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAnalyticsDatastoresListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAnalyticsDatastoresListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/analytics/datastores")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.analytics.datastores.list" call.
// Exactly one of *GoogleCloudApigeeV1ListDatastoresResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListDatastoresResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsAnalyticsDatastoresListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListDatastoresResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListDatastoresResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "List Datastores",
	//   "flatPath": "v1/organizations/{organizationsId}/analytics/datastores",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.analytics.datastores.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. The parent organization name. Must be of the form `organizations/{org}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "targetType": {
	//       "description": "Optional. TargetType is used to fetch all Datastores that match the type",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/analytics/datastores",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListDatastoresResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.analytics.datastores.test":

type OrganizationsAnalyticsDatastoresTestCall struct {
	s                            *Service
	parent                       string
	googlecloudapigeev1datastore *GoogleCloudApigeeV1Datastore
	urlParams_                   gensupport.URLParams
	ctx_                         context.Context
	header_                      http.Header
}

// Test: Test if Datastore configuration is correct. This includes
// checking if credentials provided by customer have required
// permissions in target destination storage
//
//   - parent: The parent organization name Must be of the form
//     `organizations/{org}`.
func (r *OrganizationsAnalyticsDatastoresService) Test(parent string, googlecloudapigeev1datastore *GoogleCloudApigeeV1Datastore) *OrganizationsAnalyticsDatastoresTestCall {
	c := &OrganizationsAnalyticsDatastoresTestCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1datastore = googlecloudapigeev1datastore
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAnalyticsDatastoresTestCall) Fields(s ...googleapi.Field) *OrganizationsAnalyticsDatastoresTestCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAnalyticsDatastoresTestCall) Context(ctx context.Context) *OrganizationsAnalyticsDatastoresTestCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAnalyticsDatastoresTestCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAnalyticsDatastoresTestCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1datastore)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/analytics/datastores:test")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.analytics.datastores.test" call.
// Exactly one of *GoogleCloudApigeeV1TestDatastoreResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1TestDatastoreResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsAnalyticsDatastoresTestCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1TestDatastoreResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1TestDatastoreResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Test if Datastore configuration is correct. This includes checking if credentials provided by customer have required permissions in target destination storage",
	//   "flatPath": "v1/organizations/{organizationsId}/analytics/datastores:test",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.analytics.datastores.test",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. The parent organization name Must be of the form `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/analytics/datastores:test",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Datastore"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1TestDatastoreResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.analytics.datastores.update":

type OrganizationsAnalyticsDatastoresUpdateCall struct {
	s                            *Service
	name                         string
	googlecloudapigeev1datastore *GoogleCloudApigeeV1Datastore
	urlParams_                   gensupport.URLParams
	ctx_                         context.Context
	header_                      http.Header
}

// Update: Update a Datastore
//
//   - name: The resource name of datastore to be updated. Must be of the
//     form `organizations/{org}/analytics/datastores/{datastoreId}`.
func (r *OrganizationsAnalyticsDatastoresService) Update(name string, googlecloudapigeev1datastore *GoogleCloudApigeeV1Datastore) *OrganizationsAnalyticsDatastoresUpdateCall {
	c := &OrganizationsAnalyticsDatastoresUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1datastore = googlecloudapigeev1datastore
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAnalyticsDatastoresUpdateCall) Fields(s ...googleapi.Field) *OrganizationsAnalyticsDatastoresUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAnalyticsDatastoresUpdateCall) Context(ctx context.Context) *OrganizationsAnalyticsDatastoresUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAnalyticsDatastoresUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAnalyticsDatastoresUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1datastore)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.analytics.datastores.update" call.
// Exactly one of *GoogleCloudApigeeV1Datastore or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Datastore.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsAnalyticsDatastoresUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Datastore, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Datastore{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Update a Datastore",
	//   "flatPath": "v1/organizations/{organizationsId}/analytics/datastores/{datastoresId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.analytics.datastores.update",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The resource name of datastore to be updated. Must be of the form `organizations/{org}/analytics/datastores/{datastoreId}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/analytics/datastores/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Datastore"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Datastore"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apiproducts.attributes":

type OrganizationsApiproductsAttributesCall struct {
	s                             *Service
	name                          string
	googlecloudapigeev1attributes *GoogleCloudApigeeV1Attributes
	urlParams_                    gensupport.URLParams
	ctx_                          context.Context
	header_                       http.Header
}

// Attributes: Updates or creates API product attributes. This API
// **replaces** the current list of attributes with the attributes
// specified in the request body. In this way, you can update existing
// attributes, add new attributes, or delete existing attributes by
// omitting them from the request body. **Note**: OAuth access tokens
// and Key Management Service (KMS) entities (apps, developers, and API
// products) are cached for 180 seconds (current default). Any custom
// attributes associated with entities also get cached for at least 180
// seconds after entity is accessed during runtime. In this case, the
// `ExpiresIn` element on the OAuthV2 policy won't be able to expire an
// access token in less than 180 seconds.
//
//   - name: Name of the API product. Use the following structure in your
//     request: `organizations/{org}/apiproducts/{apiproduct}`.
func (r *OrganizationsApiproductsService) Attributes(name string, googlecloudapigeev1attributes *GoogleCloudApigeeV1Attributes) *OrganizationsApiproductsAttributesCall {
	c := &OrganizationsApiproductsAttributesCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1attributes = googlecloudapigeev1attributes
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApiproductsAttributesCall) Fields(s ...googleapi.Field) *OrganizationsApiproductsAttributesCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApiproductsAttributesCall) Context(ctx context.Context) *OrganizationsApiproductsAttributesCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApiproductsAttributesCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApiproductsAttributesCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1attributes)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/attributes")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apiproducts.attributes" call.
// Exactly one of *GoogleCloudApigeeV1Attributes or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Attributes.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApiproductsAttributesCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Attributes, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Attributes{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates or creates API product attributes. This API **replaces** the current list of attributes with the attributes specified in the request body. In this way, you can update existing attributes, add new attributes, or delete existing attributes by omitting them from the request body. **Note**: OAuth access tokens and Key Management Service (KMS) entities (apps, developers, and API products) are cached for 180 seconds (current default). Any custom attributes associated with entities also get cached for at least 180 seconds after entity is accessed during runtime. In this case, the `ExpiresIn` element on the OAuthV2 policy won't be able to expire an access token in less than 180 seconds.",
	//   "flatPath": "v1/organizations/{organizationsId}/apiproducts/{apiproductsId}/attributes",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.apiproducts.attributes",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the API product. Use the following structure in your request: `organizations/{org}/apiproducts/{apiproduct}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apiproducts/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}/attributes",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Attributes"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Attributes"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apiproducts.create":

type OrganizationsApiproductsCreateCall struct {
	s                             *Service
	parent                        string
	googlecloudapigeev1apiproduct *GoogleCloudApigeeV1ApiProduct
	urlParams_                    gensupport.URLParams
	ctx_                          context.Context
	header_                       http.Header
}

// Create: Creates an API product in an organization. You create API
// products after you have proxied backend services using API proxies.
// An API product is a collection of API resources combined with quota
// settings and metadata that you can use to deliver customized and
// productized API bundles to your developer community. This metadata
// can include: - Scope - Environments - API proxies - Extensible
// profile API products enable you repackage APIs on the fly, without
// having to do any additional coding or configuration. Apigee
// recommends that you start with a simple API product including only
// required elements. You then provision credentials to apps to enable
// them to start testing your APIs. After you have authentication and
// authorization working against a simple API product, you can iterate
// to create finer-grained API products, defining different sets of API
// resources for each API product. **WARNING:** - If you don't specify
// an API proxy in the request body, *any* app associated with the
// product can make calls to *any* API in your entire organization. - If
// you don't specify an environment in the request body, the product
// allows access to all environments. For more information, see What is
// an API product?
//
//   - parent: Name of the organization in which the API product will be
//     created. Use the following structure in your request:
//     `organizations/{org}`.
func (r *OrganizationsApiproductsService) Create(parent string, googlecloudapigeev1apiproduct *GoogleCloudApigeeV1ApiProduct) *OrganizationsApiproductsCreateCall {
	c := &OrganizationsApiproductsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1apiproduct = googlecloudapigeev1apiproduct
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApiproductsCreateCall) Fields(s ...googleapi.Field) *OrganizationsApiproductsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApiproductsCreateCall) Context(ctx context.Context) *OrganizationsApiproductsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApiproductsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApiproductsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1apiproduct)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/apiproducts")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apiproducts.create" call.
// Exactly one of *GoogleCloudApigeeV1ApiProduct or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1ApiProduct.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApiproductsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiProduct, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiProduct{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates an API product in an organization. You create API products after you have proxied backend services using API proxies. An API product is a collection of API resources combined with quota settings and metadata that you can use to deliver customized and productized API bundles to your developer community. This metadata can include: - Scope - Environments - API proxies - Extensible profile API products enable you repackage APIs on the fly, without having to do any additional coding or configuration. Apigee recommends that you start with a simple API product including only required elements. You then provision credentials to apps to enable them to start testing your APIs. After you have authentication and authorization working against a simple API product, you can iterate to create finer-grained API products, defining different sets of API resources for each API product. **WARNING:** - If you don't specify an API proxy in the request body, *any* app associated with the product can make calls to *any* API in your entire organization. - If you don't specify an environment in the request body, the product allows access to all environments. For more information, see What is an API product?",
	//   "flatPath": "v1/organizations/{organizationsId}/apiproducts",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.apiproducts.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the organization in which the API product will be created. Use the following structure in your request: `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/apiproducts",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1ApiProduct"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiProduct"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apiproducts.delete":

type OrganizationsApiproductsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an API product from an organization. Deleting an API
// product causes app requests to the resource URIs defined in the API
// product to fail. Ensure that you create a new API product to serve
// existing apps, unless your intention is to disable access to the
// resources defined in the API product. The API product name required
// in the request URL is the internal name of the product, not the
// display name. While they may be the same, it depends on whether the
// API product was created via the UI or the API. View the list of API
// products to verify the internal name.
//
//   - name: Name of the API product. Use the following structure in your
//     request: `organizations/{org}/apiproducts/{apiproduct}`.
func (r *OrganizationsApiproductsService) Delete(name string) *OrganizationsApiproductsDeleteCall {
	c := &OrganizationsApiproductsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApiproductsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsApiproductsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApiproductsDeleteCall) Context(ctx context.Context) *OrganizationsApiproductsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApiproductsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApiproductsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apiproducts.delete" call.
// Exactly one of *GoogleCloudApigeeV1ApiProduct or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1ApiProduct.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApiproductsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiProduct, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiProduct{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an API product from an organization. Deleting an API product causes app requests to the resource URIs defined in the API product to fail. Ensure that you create a new API product to serve existing apps, unless your intention is to disable access to the resources defined in the API product. The API product name required in the request URL is the internal name of the product, not the display name. While they may be the same, it depends on whether the API product was created via the UI or the API. View the list of API products to verify the internal name.",
	//   "flatPath": "v1/organizations/{organizationsId}/apiproducts/{apiproductsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.apiproducts.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the API product. Use the following structure in your request: `organizations/{org}/apiproducts/{apiproduct}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apiproducts/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiProduct"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apiproducts.get":

type OrganizationsApiproductsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets configuration details for an API product. The API product
// name required in the request URL is the internal name of the product,
// not the display name. While they may be the same, it depends on
// whether the API product was created via the UI or the API. View the
// list of API products to verify the internal name.
//
//   - name: Name of the API product. Use the following structure in your
//     request: `organizations/{org}/apiproducts/{apiproduct}`.
func (r *OrganizationsApiproductsService) Get(name string) *OrganizationsApiproductsGetCall {
	c := &OrganizationsApiproductsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApiproductsGetCall) Fields(s ...googleapi.Field) *OrganizationsApiproductsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsApiproductsGetCall) IfNoneMatch(entityTag string) *OrganizationsApiproductsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApiproductsGetCall) Context(ctx context.Context) *OrganizationsApiproductsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApiproductsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApiproductsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apiproducts.get" call.
// Exactly one of *GoogleCloudApigeeV1ApiProduct or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1ApiProduct.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApiproductsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiProduct, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiProduct{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets configuration details for an API product. The API product name required in the request URL is the internal name of the product, not the display name. While they may be the same, it depends on whether the API product was created via the UI or the API. View the list of API products to verify the internal name.",
	//   "flatPath": "v1/organizations/{organizationsId}/apiproducts/{apiproductsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.apiproducts.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the API product. Use the following structure in your request: `organizations/{org}/apiproducts/{apiproduct}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apiproducts/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiProduct"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apiproducts.list":

type OrganizationsApiproductsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all API product names for an organization. Filter the
// list by passing an `attributename` and `attibutevalue`. The maximum
// number of API products returned is 1000. You can paginate the list of
// API products returned using the `startKey` and `count` query
// parameters.
//
//   - parent: Name of the organization. Use the following structure in
//     your request: `organizations/{org}`.
func (r *OrganizationsApiproductsService) List(parent string) *OrganizationsApiproductsListCall {
	c := &OrganizationsApiproductsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Attributename sets the optional parameter "attributename": Name of
// the attribute used to filter the search.
func (c *OrganizationsApiproductsListCall) Attributename(attributename string) *OrganizationsApiproductsListCall {
	c.urlParams_.Set("attributename", attributename)
	return c
}

// Attributevalue sets the optional parameter "attributevalue": Value of
// the attribute used to filter the search.
func (c *OrganizationsApiproductsListCall) Attributevalue(attributevalue string) *OrganizationsApiproductsListCall {
	c.urlParams_.Set("attributevalue", attributevalue)
	return c
}

// Count sets the optional parameter "count": Enter the number of API
// products you want returned in the API call. The limit is 1000.
func (c *OrganizationsApiproductsListCall) Count(count int64) *OrganizationsApiproductsListCall {
	c.urlParams_.Set("count", fmt.Sprint(count))
	return c
}

// Expand sets the optional parameter "expand": Flag that specifies
// whether to expand the results. Set to `true` to get expanded details
// about each API.
func (c *OrganizationsApiproductsListCall) Expand(expand bool) *OrganizationsApiproductsListCall {
	c.urlParams_.Set("expand", fmt.Sprint(expand))
	return c
}

// StartKey sets the optional parameter "startKey": Gets a list of API
// products starting with a specific API product in the list. For
// example, if you're returning 50 API products at a time (using the
// `count` query parameter), you can view products 50-99 by entering the
// name of the 50th API product in the first API (without using
// `startKey`). Product name is case sensitive.
func (c *OrganizationsApiproductsListCall) StartKey(startKey string) *OrganizationsApiproductsListCall {
	c.urlParams_.Set("startKey", startKey)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApiproductsListCall) Fields(s ...googleapi.Field) *OrganizationsApiproductsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsApiproductsListCall) IfNoneMatch(entityTag string) *OrganizationsApiproductsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApiproductsListCall) Context(ctx context.Context) *OrganizationsApiproductsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApiproductsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApiproductsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/apiproducts")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apiproducts.list" call.
// Exactly one of *GoogleCloudApigeeV1ListApiProductsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListApiProductsResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsApiproductsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListApiProductsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListApiProductsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all API product names for an organization. Filter the list by passing an `attributename` and `attibutevalue`. The maximum number of API products returned is 1000. You can paginate the list of API products returned using the `startKey` and `count` query parameters.",
	//   "flatPath": "v1/organizations/{organizationsId}/apiproducts",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.apiproducts.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "attributename": {
	//       "description": "Name of the attribute used to filter the search.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "attributevalue": {
	//       "description": "Value of the attribute used to filter the search.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "count": {
	//       "description": "Enter the number of API products you want returned in the API call. The limit is 1000.",
	//       "format": "int64",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "expand": {
	//       "description": "Flag that specifies whether to expand the results. Set to `true` to get expanded details about each API.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the organization. Use the following structure in your request: `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "startKey": {
	//       "description": "Gets a list of API products starting with a specific API product in the list. For example, if you're returning 50 API products at a time (using the `count` query parameter), you can view products 50-99 by entering the name of the 50th API product in the first API (without using `startKey`). Product name is case sensitive.",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/apiproducts",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListApiProductsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apiproducts.update":

type OrganizationsApiproductsUpdateCall struct {
	s                             *Service
	name                          string
	googlecloudapigeev1apiproduct *GoogleCloudApigeeV1ApiProduct
	urlParams_                    gensupport.URLParams
	ctx_                          context.Context
	header_                       http.Header
}

// Update: Updates an existing API product. You must include all
// required values, whether or not you are updating them, as well as any
// optional values that you are updating. The API product name required
// in the request URL is the internal name of the product, not the
// display name. While they may be the same, it depends on whether the
// API product was created via UI or API. View the list of API products
// to identify their internal names.
//
//   - name: Name of the API product. Use the following structure in your
//     request: `organizations/{org}/apiproducts/{apiproduct}`.
func (r *OrganizationsApiproductsService) Update(name string, googlecloudapigeev1apiproduct *GoogleCloudApigeeV1ApiProduct) *OrganizationsApiproductsUpdateCall {
	c := &OrganizationsApiproductsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1apiproduct = googlecloudapigeev1apiproduct
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApiproductsUpdateCall) Fields(s ...googleapi.Field) *OrganizationsApiproductsUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApiproductsUpdateCall) Context(ctx context.Context) *OrganizationsApiproductsUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApiproductsUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApiproductsUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1apiproduct)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apiproducts.update" call.
// Exactly one of *GoogleCloudApigeeV1ApiProduct or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1ApiProduct.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApiproductsUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiProduct, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiProduct{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates an existing API product. You must include all required values, whether or not you are updating them, as well as any optional values that you are updating. The API product name required in the request URL is the internal name of the product, not the display name. While they may be the same, it depends on whether the API product was created via UI or API. View the list of API products to identify their internal names.",
	//   "flatPath": "v1/organizations/{organizationsId}/apiproducts/{apiproductsId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.apiproducts.update",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the API product. Use the following structure in your request: `organizations/{org}/apiproducts/{apiproduct}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apiproducts/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1ApiProduct"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiProduct"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apiproducts.attributes.delete":

type OrganizationsApiproductsAttributesDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an API product attribute.
//
//   - name: Name of the API product attribute. Use the following
//     structure in your request:
//     `organizations/{org}/apiproducts/{apiproduct}/attributes/{attribute}
//     `.
func (r *OrganizationsApiproductsAttributesService) Delete(name string) *OrganizationsApiproductsAttributesDeleteCall {
	c := &OrganizationsApiproductsAttributesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApiproductsAttributesDeleteCall) Fields(s ...googleapi.Field) *OrganizationsApiproductsAttributesDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApiproductsAttributesDeleteCall) Context(ctx context.Context) *OrganizationsApiproductsAttributesDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApiproductsAttributesDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApiproductsAttributesDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apiproducts.attributes.delete" call.
// Exactly one of *GoogleCloudApigeeV1Attribute or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Attribute.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApiproductsAttributesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Attribute, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Attribute{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an API product attribute.",
	//   "flatPath": "v1/organizations/{organizationsId}/apiproducts/{apiproductsId}/attributes/{attributesId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.apiproducts.attributes.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the API product attribute. Use the following structure in your request: `organizations/{org}/apiproducts/{apiproduct}/attributes/{attribute}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apiproducts/[^/]+/attributes/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Attribute"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apiproducts.attributes.get":

type OrganizationsApiproductsAttributesGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets the value of an API product attribute.
//
//   - name: Name of the API product attribute. Use the following
//     structure in your request:
//     `organizations/{org}/apiproducts/{apiproduct}/attributes/{attribute}
//     `.
func (r *OrganizationsApiproductsAttributesService) Get(name string) *OrganizationsApiproductsAttributesGetCall {
	c := &OrganizationsApiproductsAttributesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApiproductsAttributesGetCall) Fields(s ...googleapi.Field) *OrganizationsApiproductsAttributesGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsApiproductsAttributesGetCall) IfNoneMatch(entityTag string) *OrganizationsApiproductsAttributesGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApiproductsAttributesGetCall) Context(ctx context.Context) *OrganizationsApiproductsAttributesGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApiproductsAttributesGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApiproductsAttributesGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apiproducts.attributes.get" call.
// Exactly one of *GoogleCloudApigeeV1Attribute or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Attribute.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApiproductsAttributesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Attribute, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Attribute{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the value of an API product attribute.",
	//   "flatPath": "v1/organizations/{organizationsId}/apiproducts/{apiproductsId}/attributes/{attributesId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.apiproducts.attributes.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the API product attribute. Use the following structure in your request: `organizations/{org}/apiproducts/{apiproduct}/attributes/{attribute}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apiproducts/[^/]+/attributes/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Attribute"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apiproducts.attributes.list":

type OrganizationsApiproductsAttributesListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all API product attributes.
//
//   - parent: Name of the API product. Use the following structure in
//     your request: `organizations/{org}/apiproducts/{apiproduct}`.
func (r *OrganizationsApiproductsAttributesService) List(parent string) *OrganizationsApiproductsAttributesListCall {
	c := &OrganizationsApiproductsAttributesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApiproductsAttributesListCall) Fields(s ...googleapi.Field) *OrganizationsApiproductsAttributesListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsApiproductsAttributesListCall) IfNoneMatch(entityTag string) *OrganizationsApiproductsAttributesListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApiproductsAttributesListCall) Context(ctx context.Context) *OrganizationsApiproductsAttributesListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApiproductsAttributesListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApiproductsAttributesListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/attributes")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apiproducts.attributes.list" call.
// Exactly one of *GoogleCloudApigeeV1Attributes or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Attributes.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApiproductsAttributesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Attributes, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Attributes{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all API product attributes.",
	//   "flatPath": "v1/organizations/{organizationsId}/apiproducts/{apiproductsId}/attributes",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.apiproducts.attributes.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the API product. Use the following structure in your request: `organizations/{org}/apiproducts/{apiproduct}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apiproducts/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/attributes",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Attributes"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apiproducts.attributes.updateApiProductAttribute":

type OrganizationsApiproductsAttributesUpdateApiProductAttributeCall struct {
	s                            *Service
	name                         string
	googlecloudapigeev1attribute *GoogleCloudApigeeV1Attribute
	urlParams_                   gensupport.URLParams
	ctx_                         context.Context
	header_                      http.Header
}

// UpdateApiProductAttribute: Updates the value of an API product
// attribute. **Note**: OAuth access tokens and Key Management Service
// (KMS) entities (apps, developers, and API products) are cached for
// 180 seconds (current default). Any custom attributes associated with
// entities also get cached for at least 180 seconds after entity is
// accessed during runtime. In this case, the `ExpiresIn` element on the
// OAuthV2 policy won't be able to expire an access token in less than
// 180 seconds.
//
//   - name: Name of the API product. Use the following structure in your
//     request: `organizations/{org}/apiproducts/{apiproduct}`.
func (r *OrganizationsApiproductsAttributesService) UpdateApiProductAttribute(name string, googlecloudapigeev1attribute *GoogleCloudApigeeV1Attribute) *OrganizationsApiproductsAttributesUpdateApiProductAttributeCall {
	c := &OrganizationsApiproductsAttributesUpdateApiProductAttributeCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1attribute = googlecloudapigeev1attribute
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApiproductsAttributesUpdateApiProductAttributeCall) Fields(s ...googleapi.Field) *OrganizationsApiproductsAttributesUpdateApiProductAttributeCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApiproductsAttributesUpdateApiProductAttributeCall) Context(ctx context.Context) *OrganizationsApiproductsAttributesUpdateApiProductAttributeCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApiproductsAttributesUpdateApiProductAttributeCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApiproductsAttributesUpdateApiProductAttributeCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1attribute)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apiproducts.attributes.updateApiProductAttribute" call.
// Exactly one of *GoogleCloudApigeeV1Attribute or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Attribute.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApiproductsAttributesUpdateApiProductAttributeCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Attribute, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Attribute{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates the value of an API product attribute. **Note**: OAuth access tokens and Key Management Service (KMS) entities (apps, developers, and API products) are cached for 180 seconds (current default). Any custom attributes associated with entities also get cached for at least 180 seconds after entity is accessed during runtime. In this case, the `ExpiresIn` element on the OAuthV2 policy won't be able to expire an access token in less than 180 seconds.",
	//   "flatPath": "v1/organizations/{organizationsId}/apiproducts/{apiproductsId}/attributes/{attributesId}",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.apiproducts.attributes.updateApiProductAttribute",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the API product. Use the following structure in your request: `organizations/{org}/apiproducts/{apiproduct}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apiproducts/[^/]+/attributes/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Attribute"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Attribute"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apiproducts.rateplans.create":

type OrganizationsApiproductsRateplansCreateCall struct {
	s                           *Service
	parent                      string
	googlecloudapigeev1rateplan *GoogleCloudApigeeV1RatePlan
	urlParams_                  gensupport.URLParams
	ctx_                        context.Context
	header_                     http.Header
}

// Create: Create a rate plan that is associated with an API product in
// an organization. Using rate plans, API product owners can monetize
// their API products by configuring one or more of the following: -
// Billing frequency - Initial setup fees for using an API product -
// Payment funding model (postpaid only) - Fixed recurring or
// consumption-based charges for using an API product - Revenue sharing
// with developer partners An API product can have multiple rate plans
// associated with it but *only one* rate plan can be active at any
// point of time. **Note: From the developer's perspective, they
// purchase API products not rate plans.
//
//   - parent: Name of the API product that is associated with the rate
//     plan. Use the following structure in your request:
//     `organizations/{org}/apiproducts/{apiproduct}`.
func (r *OrganizationsApiproductsRateplansService) Create(parent string, googlecloudapigeev1rateplan *GoogleCloudApigeeV1RatePlan) *OrganizationsApiproductsRateplansCreateCall {
	c := &OrganizationsApiproductsRateplansCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1rateplan = googlecloudapigeev1rateplan
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApiproductsRateplansCreateCall) Fields(s ...googleapi.Field) *OrganizationsApiproductsRateplansCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApiproductsRateplansCreateCall) Context(ctx context.Context) *OrganizationsApiproductsRateplansCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApiproductsRateplansCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApiproductsRateplansCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1rateplan)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/rateplans")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apiproducts.rateplans.create" call.
// Exactly one of *GoogleCloudApigeeV1RatePlan or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1RatePlan.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApiproductsRateplansCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1RatePlan, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1RatePlan{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Create a rate plan that is associated with an API product in an organization. Using rate plans, API product owners can monetize their API products by configuring one or more of the following: - Billing frequency - Initial setup fees for using an API product - Payment funding model (postpaid only) - Fixed recurring or consumption-based charges for using an API product - Revenue sharing with developer partners An API product can have multiple rate plans associated with it but *only one* rate plan can be active at any point of time. **Note: From the developer's perspective, they purchase API products not rate plans.",
	//   "flatPath": "v1/organizations/{organizationsId}/apiproducts/{apiproductsId}/rateplans",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.apiproducts.rateplans.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the API product that is associated with the rate plan. Use the following structure in your request: `organizations/{org}/apiproducts/{apiproduct}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apiproducts/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/rateplans",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1RatePlan"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1RatePlan"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apiproducts.rateplans.delete":

type OrganizationsApiproductsRateplansDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a rate plan.
//
//   - name: ID of the rate plan. Use the following structure in your
//     request:
//     `organizations/{org}/apiproducts/{apiproduct}/rateplans/{rateplan}`.
func (r *OrganizationsApiproductsRateplansService) Delete(name string) *OrganizationsApiproductsRateplansDeleteCall {
	c := &OrganizationsApiproductsRateplansDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApiproductsRateplansDeleteCall) Fields(s ...googleapi.Field) *OrganizationsApiproductsRateplansDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApiproductsRateplansDeleteCall) Context(ctx context.Context) *OrganizationsApiproductsRateplansDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApiproductsRateplansDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApiproductsRateplansDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apiproducts.rateplans.delete" call.
// Exactly one of *GoogleCloudApigeeV1RatePlan or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1RatePlan.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApiproductsRateplansDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1RatePlan, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1RatePlan{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a rate plan.",
	//   "flatPath": "v1/organizations/{organizationsId}/apiproducts/{apiproductsId}/rateplans/{rateplansId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.apiproducts.rateplans.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. ID of the rate plan. Use the following structure in your request: `organizations/{org}/apiproducts/{apiproduct}/rateplans/{rateplan}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apiproducts/[^/]+/rateplans/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1RatePlan"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apiproducts.rateplans.get":

type OrganizationsApiproductsRateplansGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets the details of a rate plan.
//
//   - name: Name of the rate plan. Use the following structure in your
//     request:
//     `organizations/{org}/apiproducts/{apiproduct}/rateplans/{rateplan}`.
func (r *OrganizationsApiproductsRateplansService) Get(name string) *OrganizationsApiproductsRateplansGetCall {
	c := &OrganizationsApiproductsRateplansGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApiproductsRateplansGetCall) Fields(s ...googleapi.Field) *OrganizationsApiproductsRateplansGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsApiproductsRateplansGetCall) IfNoneMatch(entityTag string) *OrganizationsApiproductsRateplansGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApiproductsRateplansGetCall) Context(ctx context.Context) *OrganizationsApiproductsRateplansGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApiproductsRateplansGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApiproductsRateplansGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apiproducts.rateplans.get" call.
// Exactly one of *GoogleCloudApigeeV1RatePlan or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1RatePlan.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApiproductsRateplansGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1RatePlan, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1RatePlan{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the details of a rate plan.",
	//   "flatPath": "v1/organizations/{organizationsId}/apiproducts/{apiproductsId}/rateplans/{rateplansId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.apiproducts.rateplans.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the rate plan. Use the following structure in your request: `organizations/{org}/apiproducts/{apiproduct}/rateplans/{rateplan}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apiproducts/[^/]+/rateplans/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1RatePlan"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apiproducts.rateplans.list":

type OrganizationsApiproductsRateplansListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all the rate plans for an API product.
//
//   - parent: Name of the API product. Use the following structure in
//     your request: `organizations/{org}/apiproducts/{apiproduct}` Use
//     `organizations/{org}/apiproducts/-` to return rate plans for all
//     API products within the organization.
func (r *OrganizationsApiproductsRateplansService) List(parent string) *OrganizationsApiproductsRateplansListCall {
	c := &OrganizationsApiproductsRateplansListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Count sets the optional parameter "count": Number of rate plans to
// return in the API call. Use with the `startKey` parameter to provide
// more targeted filtering. The maximum limit is 1000. Defaults to 100.
func (c *OrganizationsApiproductsRateplansListCall) Count(count int64) *OrganizationsApiproductsRateplansListCall {
	c.urlParams_.Set("count", fmt.Sprint(count))
	return c
}

// Expand sets the optional parameter "expand": Flag that specifies
// whether to expand the results. Set to `true` to get expanded details
// about each API. Defaults to `false`.
func (c *OrganizationsApiproductsRateplansListCall) Expand(expand bool) *OrganizationsApiproductsRateplansListCall {
	c.urlParams_.Set("expand", fmt.Sprint(expand))
	return c
}

// OrderBy sets the optional parameter "orderBy": Name of the attribute
// used for sorting. Valid values include: * `name`: Name of the rate
// plan. * `state`: State of the rate plan (`DRAFT`, `PUBLISHED`). *
// `startTime`: Time when the rate plan becomes active. * `endTime`:
// Time when the rate plan expires. **Note**: Not supported by Apigee at
// this time.
func (c *OrganizationsApiproductsRateplansListCall) OrderBy(orderBy string) *OrganizationsApiproductsRateplansListCall {
	c.urlParams_.Set("orderBy", orderBy)
	return c
}

// StartKey sets the optional parameter "startKey": Name of the rate
// plan from which to start displaying the list of rate plans. If
// omitted, the list starts from the first item. For example, to view
// the rate plans from 51-150, set the value of `startKey` to the name
// of the 51st rate plan and set the value of `count` to 100.
func (c *OrganizationsApiproductsRateplansListCall) StartKey(startKey string) *OrganizationsApiproductsRateplansListCall {
	c.urlParams_.Set("startKey", startKey)
	return c
}

// State sets the optional parameter "state": State of the rate plans
// (`DRAFT`, `PUBLISHED`) that you want to display.
//
// Possible values:
//
//	"STATE_UNSPECIFIED" - State of the rate plan is not specified.
//	"DRAFT" - Rate plan is in draft mode and only visible to API
//
// providers.
//
//	"PUBLISHED" - Rate plan is published and will become visible to
//
// developers for the configured duration (between `startTime` and
// `endTime`).
func (c *OrganizationsApiproductsRateplansListCall) State(state string) *OrganizationsApiproductsRateplansListCall {
	c.urlParams_.Set("state", state)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApiproductsRateplansListCall) Fields(s ...googleapi.Field) *OrganizationsApiproductsRateplansListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsApiproductsRateplansListCall) IfNoneMatch(entityTag string) *OrganizationsApiproductsRateplansListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApiproductsRateplansListCall) Context(ctx context.Context) *OrganizationsApiproductsRateplansListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApiproductsRateplansListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApiproductsRateplansListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/rateplans")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apiproducts.rateplans.list" call.
// Exactly one of *GoogleCloudApigeeV1ListRatePlansResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListRatePlansResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsApiproductsRateplansListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListRatePlansResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListRatePlansResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all the rate plans for an API product.",
	//   "flatPath": "v1/organizations/{organizationsId}/apiproducts/{apiproductsId}/rateplans",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.apiproducts.rateplans.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "count": {
	//       "description": "Number of rate plans to return in the API call. Use with the `startKey` parameter to provide more targeted filtering. The maximum limit is 1000. Defaults to 100.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "expand": {
	//       "description": "Flag that specifies whether to expand the results. Set to `true` to get expanded details about each API. Defaults to `false`.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "orderBy": {
	//       "description": "Name of the attribute used for sorting. Valid values include: * `name`: Name of the rate plan. * `state`: State of the rate plan (`DRAFT`, `PUBLISHED`). * `startTime`: Time when the rate plan becomes active. * `endTime`: Time when the rate plan expires. **Note**: Not supported by Apigee at this time.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the API product. Use the following structure in your request: `organizations/{org}/apiproducts/{apiproduct}` Use `organizations/{org}/apiproducts/-` to return rate plans for all API products within the organization.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apiproducts/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "startKey": {
	//       "description": "Name of the rate plan from which to start displaying the list of rate plans. If omitted, the list starts from the first item. For example, to view the rate plans from 51-150, set the value of `startKey` to the name of the 51st rate plan and set the value of `count` to 100.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "state": {
	//       "description": "State of the rate plans (`DRAFT`, `PUBLISHED`) that you want to display.",
	//       "enum": [
	//         "STATE_UNSPECIFIED",
	//         "DRAFT",
	//         "PUBLISHED"
	//       ],
	//       "enumDescriptions": [
	//         "State of the rate plan is not specified.",
	//         "Rate plan is in draft mode and only visible to API providers.",
	//         "Rate plan is published and will become visible to developers for the configured duration (between `startTime` and `endTime`)."
	//       ],
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/rateplans",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListRatePlansResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apiproducts.rateplans.update":

type OrganizationsApiproductsRateplansUpdateCall struct {
	s                           *Service
	name                        string
	googlecloudapigeev1rateplan *GoogleCloudApigeeV1RatePlan
	urlParams_                  gensupport.URLParams
	ctx_                        context.Context
	header_                     http.Header
}

// Update: Updates an existing rate plan.
//
//   - name: Name of the rate plan. Use the following structure in your
//     request:
//     `organizations/{org}/apiproducts/{apiproduct}/rateplans/{rateplan}`.
func (r *OrganizationsApiproductsRateplansService) Update(name string, googlecloudapigeev1rateplan *GoogleCloudApigeeV1RatePlan) *OrganizationsApiproductsRateplansUpdateCall {
	c := &OrganizationsApiproductsRateplansUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1rateplan = googlecloudapigeev1rateplan
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApiproductsRateplansUpdateCall) Fields(s ...googleapi.Field) *OrganizationsApiproductsRateplansUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApiproductsRateplansUpdateCall) Context(ctx context.Context) *OrganizationsApiproductsRateplansUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApiproductsRateplansUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApiproductsRateplansUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1rateplan)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apiproducts.rateplans.update" call.
// Exactly one of *GoogleCloudApigeeV1RatePlan or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1RatePlan.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApiproductsRateplansUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1RatePlan, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1RatePlan{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates an existing rate plan.",
	//   "flatPath": "v1/organizations/{organizationsId}/apiproducts/{apiproductsId}/rateplans/{rateplansId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.apiproducts.rateplans.update",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the rate plan. Use the following structure in your request: `organizations/{org}/apiproducts/{apiproduct}/rateplans/{rateplan}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apiproducts/[^/]+/rateplans/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1RatePlan"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1RatePlan"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apis.create":

type OrganizationsApisCreateCall struct {
	s                 *Service
	parent            string
	googleapihttpbody *GoogleApiHttpBody
	urlParams_        gensupport.URLParams
	ctx_              context.Context
	header_           http.Header
}

// Create: Creates an API proxy. The API proxy created will not be
// accessible at runtime until it is deployed to an environment. Create
// a new API proxy by setting the `name` query parameter to the name of
// the API proxy. Import an API proxy configuration bundle stored in zip
// format on your local machine to your organization by doing the
// following: * Set the `name` query parameter to the name of the API
// proxy. * Set the `action` query parameter to `import`. * Set the
// `Content-Type` header to `multipart/form-data`. * Pass as a file the
// name of API proxy configuration bundle stored in zip format on your
// local machine using the `file` form field. **Note**: To validate the
// API proxy configuration bundle only without importing it, set the
// `action` query parameter to `validate`. When importing an API proxy
// configuration bundle, if the API proxy does not exist, it will be
// created. If the API proxy exists, then a new revision is created.
// Invalid API proxy configurations are rejected, and a list of
// validation errors is returned to the client.
//
//   - parent: Name of the organization in the following format:
//     `organizations/{org}`.
func (r *OrganizationsApisService) Create(parent string, googleapihttpbody *GoogleApiHttpBody) *OrganizationsApisCreateCall {
	c := &OrganizationsApisCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googleapihttpbody = googleapihttpbody
	return c
}

// Action sets the optional parameter "action": Action to perform when
// importing an API proxy configuration bundle. Set this parameter to
// one of the following values: * `import` to import the API proxy
// configuration bundle. * `validate` to validate the API proxy
// configuration bundle without importing it.
func (c *OrganizationsApisCreateCall) Action(action string) *OrganizationsApisCreateCall {
	c.urlParams_.Set("action", action)
	return c
}

// Name sets the optional parameter "name": Name of the API proxy.
// Restrict the characters used to: A-Za-z0-9._-
func (c *OrganizationsApisCreateCall) Name(name string) *OrganizationsApisCreateCall {
	c.urlParams_.Set("name", name)
	return c
}

// Validate sets the optional parameter "validate": Ignored. All uploads
// are validated regardless of the value of this field. Maintained for
// compatibility with Apigee Edge API.
func (c *OrganizationsApisCreateCall) Validate(validate bool) *OrganizationsApisCreateCall {
	c.urlParams_.Set("validate", fmt.Sprint(validate))
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApisCreateCall) Fields(s ...googleapi.Field) *OrganizationsApisCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApisCreateCall) Context(ctx context.Context) *OrganizationsApisCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApisCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApisCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleapihttpbody)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/apis")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apis.create" call.
// Exactly one of *GoogleCloudApigeeV1ApiProxyRevision or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1ApiProxyRevision.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsApisCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiProxyRevision, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiProxyRevision{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates an API proxy. The API proxy created will not be accessible at runtime until it is deployed to an environment. Create a new API proxy by setting the `name` query parameter to the name of the API proxy. Import an API proxy configuration bundle stored in zip format on your local machine to your organization by doing the following: * Set the `name` query parameter to the name of the API proxy. * Set the `action` query parameter to `import`. * Set the `Content-Type` header to `multipart/form-data`. * Pass as a file the name of API proxy configuration bundle stored in zip format on your local machine using the `file` form field. **Note**: To validate the API proxy configuration bundle only without importing it, set the `action` query parameter to `validate`. When importing an API proxy configuration bundle, if the API proxy does not exist, it will be created. If the API proxy exists, then a new revision is created. Invalid API proxy configurations are rejected, and a list of validation errors is returned to the client.",
	//   "flatPath": "v1/organizations/{organizationsId}/apis",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.apis.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "action": {
	//       "description": "Action to perform when importing an API proxy configuration bundle. Set this parameter to one of the following values: * `import` to import the API proxy configuration bundle. * `validate` to validate the API proxy configuration bundle without importing it.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "Name of the API proxy. Restrict the characters used to: A-Za-z0-9._-",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the organization in the following format: `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "validate": {
	//       "description": "Ignored. All uploads are validated regardless of the value of this field. Maintained for compatibility with Apigee Edge API.",
	//       "location": "query",
	//       "type": "boolean"
	//     }
	//   },
	//   "path": "v1/{+parent}/apis",
	//   "request": {
	//     "$ref": "GoogleApiHttpBody"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiProxyRevision"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apis.delete":

type OrganizationsApisDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an API proxy and all associated endpoints, policies,
// resources, and revisions. The API proxy must be undeployed before you
// can delete it.
//
//   - name: Name of the API proxy in the following format:
//     `organizations/{org}/apis/{api}`.
func (r *OrganizationsApisService) Delete(name string) *OrganizationsApisDeleteCall {
	c := &OrganizationsApisDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApisDeleteCall) Fields(s ...googleapi.Field) *OrganizationsApisDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApisDeleteCall) Context(ctx context.Context) *OrganizationsApisDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApisDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApisDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apis.delete" call.
// Exactly one of *GoogleCloudApigeeV1ApiProxy or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1ApiProxy.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApisDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiProxy, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiProxy{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an API proxy and all associated endpoints, policies, resources, and revisions. The API proxy must be undeployed before you can delete it.",
	//   "flatPath": "v1/organizations/{organizationsId}/apis/{apisId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.apis.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the API proxy in the following format: `organizations/{org}/apis/{api}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apis/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiProxy"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apis.get":

type OrganizationsApisGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets an API proxy including a list of existing revisions.
//
//   - name: Name of the API proxy in the following format:
//     `organizations/{org}/apis/{api}`.
func (r *OrganizationsApisService) Get(name string) *OrganizationsApisGetCall {
	c := &OrganizationsApisGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApisGetCall) Fields(s ...googleapi.Field) *OrganizationsApisGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsApisGetCall) IfNoneMatch(entityTag string) *OrganizationsApisGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApisGetCall) Context(ctx context.Context) *OrganizationsApisGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApisGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApisGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apis.get" call.
// Exactly one of *GoogleCloudApigeeV1ApiProxy or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1ApiProxy.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApisGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiProxy, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiProxy{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets an API proxy including a list of existing revisions.",
	//   "flatPath": "v1/organizations/{organizationsId}/apis/{apisId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.apis.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the API proxy in the following format: `organizations/{org}/apis/{api}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apis/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiProxy"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apis.list":

type OrganizationsApisListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists the names of all API proxies in an organization. The
// names returned correspond to the names defined in the configuration
// files for each API proxy.
//
//   - parent: Name of the organization in the following format:
//     `organizations/{org}`.
func (r *OrganizationsApisService) List(parent string) *OrganizationsApisListCall {
	c := &OrganizationsApisListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// IncludeMetaData sets the optional parameter "includeMetaData": Flag
// that specifies whether to include API proxy metadata in the response.
func (c *OrganizationsApisListCall) IncludeMetaData(includeMetaData bool) *OrganizationsApisListCall {
	c.urlParams_.Set("includeMetaData", fmt.Sprint(includeMetaData))
	return c
}

// IncludeRevisions sets the optional parameter "includeRevisions": Flag
// that specifies whether to include a list of revisions in the
// response.
func (c *OrganizationsApisListCall) IncludeRevisions(includeRevisions bool) *OrganizationsApisListCall {
	c.urlParams_.Set("includeRevisions", fmt.Sprint(includeRevisions))
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApisListCall) Fields(s ...googleapi.Field) *OrganizationsApisListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsApisListCall) IfNoneMatch(entityTag string) *OrganizationsApisListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApisListCall) Context(ctx context.Context) *OrganizationsApisListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApisListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApisListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/apis")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apis.list" call.
// Exactly one of *GoogleCloudApigeeV1ListApiProxiesResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListApiProxiesResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsApisListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListApiProxiesResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListApiProxiesResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists the names of all API proxies in an organization. The names returned correspond to the names defined in the configuration files for each API proxy.",
	//   "flatPath": "v1/organizations/{organizationsId}/apis",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.apis.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "includeMetaData": {
	//       "description": "Flag that specifies whether to include API proxy metadata in the response.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "includeRevisions": {
	//       "description": "Flag that specifies whether to include a list of revisions in the response.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the organization in the following format: `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/apis",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListApiProxiesResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apis.patch":

type OrganizationsApisPatchCall struct {
	s                           *Service
	name                        string
	googlecloudapigeev1apiproxy *GoogleCloudApigeeV1ApiProxy
	urlParams_                  gensupport.URLParams
	ctx_                        context.Context
	header_                     http.Header
}

// Patch: Updates an existing API proxy.
//
//   - name: API proxy to update in the following format:
//     `organizations/{org}/apis/{api}`.
func (r *OrganizationsApisService) Patch(name string, googlecloudapigeev1apiproxy *GoogleCloudApigeeV1ApiProxy) *OrganizationsApisPatchCall {
	c := &OrganizationsApisPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1apiproxy = googlecloudapigeev1apiproxy
	return c
}

// UpdateMask sets the optional parameter "updateMask": Required. The
// list of fields to update.
func (c *OrganizationsApisPatchCall) UpdateMask(updateMask string) *OrganizationsApisPatchCall {
	c.urlParams_.Set("updateMask", updateMask)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApisPatchCall) Fields(s ...googleapi.Field) *OrganizationsApisPatchCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApisPatchCall) Context(ctx context.Context) *OrganizationsApisPatchCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApisPatchCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApisPatchCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1apiproxy)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PATCH", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apis.patch" call.
// Exactly one of *GoogleCloudApigeeV1ApiProxy or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1ApiProxy.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApisPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiProxy, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiProxy{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates an existing API proxy.",
	//   "flatPath": "v1/organizations/{organizationsId}/apis/{apisId}",
	//   "httpMethod": "PATCH",
	//   "id": "apigee.organizations.apis.patch",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. API proxy to update in the following format: `organizations/{org}/apis/{api}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apis/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "updateMask": {
	//       "description": "Required. The list of fields to update.",
	//       "format": "google-fieldmask",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1ApiProxy"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiProxy"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apis.deployments.list":

type OrganizationsApisDeploymentsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all deployments of an API proxy.
//
//   - parent: Name of the API proxy for which to return deployment
//     information in the following format:
//     `organizations/{org}/apis/{api}`.
func (r *OrganizationsApisDeploymentsService) List(parent string) *OrganizationsApisDeploymentsListCall {
	c := &OrganizationsApisDeploymentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApisDeploymentsListCall) Fields(s ...googleapi.Field) *OrganizationsApisDeploymentsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsApisDeploymentsListCall) IfNoneMatch(entityTag string) *OrganizationsApisDeploymentsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApisDeploymentsListCall) Context(ctx context.Context) *OrganizationsApisDeploymentsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApisDeploymentsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApisDeploymentsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/deployments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apis.deployments.list" call.
// Exactly one of *GoogleCloudApigeeV1ListDeploymentsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListDeploymentsResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsApisDeploymentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListDeploymentsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListDeploymentsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all deployments of an API proxy.",
	//   "flatPath": "v1/organizations/{organizationsId}/apis/{apisId}/deployments",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.apis.deployments.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the API proxy for which to return deployment information in the following format: `organizations/{org}/apis/{api}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apis/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/deployments",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListDeploymentsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apis.keyvaluemaps.create":

type OrganizationsApisKeyvaluemapsCreateCall struct {
	s                              *Service
	parent                         string
	googlecloudapigeev1keyvaluemap *GoogleCloudApigeeV1KeyValueMap
	urlParams_                     gensupport.URLParams
	ctx_                           context.Context
	header_                        http.Header
}

// Create: Creates a key value map in an API proxy.
//
//   - parent: Name of the environment in which to create the key value
//     map. Use the following structure in your request:
//     `organizations/{org}/apis/{api}`.
func (r *OrganizationsApisKeyvaluemapsService) Create(parent string, googlecloudapigeev1keyvaluemap *GoogleCloudApigeeV1KeyValueMap) *OrganizationsApisKeyvaluemapsCreateCall {
	c := &OrganizationsApisKeyvaluemapsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1keyvaluemap = googlecloudapigeev1keyvaluemap
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApisKeyvaluemapsCreateCall) Fields(s ...googleapi.Field) *OrganizationsApisKeyvaluemapsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApisKeyvaluemapsCreateCall) Context(ctx context.Context) *OrganizationsApisKeyvaluemapsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApisKeyvaluemapsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApisKeyvaluemapsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1keyvaluemap)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/keyvaluemaps")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apis.keyvaluemaps.create" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueMap or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueMap.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApisKeyvaluemapsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueMap, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueMap{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a key value map in an API proxy.",
	//   "flatPath": "v1/organizations/{organizationsId}/apis/{apisId}/keyvaluemaps",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.apis.keyvaluemaps.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the environment in which to create the key value map. Use the following structure in your request: `organizations/{org}/apis/{api}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apis/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/keyvaluemaps",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueMap"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueMap"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apis.keyvaluemaps.delete":

type OrganizationsApisKeyvaluemapsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a key value map from an API proxy.
//
//   - name: Name of the key value map. Use the following structure in
//     your request:
//     `organizations/{org}/apis/{api}/keyvaluemaps/{keyvaluemap}`.
func (r *OrganizationsApisKeyvaluemapsService) Delete(name string) *OrganizationsApisKeyvaluemapsDeleteCall {
	c := &OrganizationsApisKeyvaluemapsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApisKeyvaluemapsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsApisKeyvaluemapsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApisKeyvaluemapsDeleteCall) Context(ctx context.Context) *OrganizationsApisKeyvaluemapsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApisKeyvaluemapsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApisKeyvaluemapsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apis.keyvaluemaps.delete" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueMap or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueMap.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApisKeyvaluemapsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueMap, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueMap{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a key value map from an API proxy.",
	//   "flatPath": "v1/organizations/{organizationsId}/apis/{apisId}/keyvaluemaps/{keyvaluemapsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.apis.keyvaluemaps.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the key value map. Use the following structure in your request: `organizations/{org}/apis/{api}/keyvaluemaps/{keyvaluemap}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apis/[^/]+/keyvaluemaps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueMap"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apis.keyvaluemaps.entries.create":

type OrganizationsApisKeyvaluemapsEntriesCreateCall struct {
	s                                *Service
	parent                           string
	googlecloudapigeev1keyvalueentry *GoogleCloudApigeeV1KeyValueEntry
	urlParams_                       gensupport.URLParams
	ctx_                             context.Context
	header_                          http.Header
}

// Create: Creates key value entries in a key value map scoped to an
// organization, environment, or API proxy. **Note**: Supported for
// Apigee hybrid 1.8.x and higher.
//
//   - parent: Scope as indicated by the URI in which to create the key
//     value map entry. Use **one** of the following structures in your
//     request: *
//     `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`
//     . *
//     `organizations/{organization}/environments/{environment}/keyvaluemap
//     s/{keyvaluemap}` *
//     `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.
func (r *OrganizationsApisKeyvaluemapsEntriesService) Create(parent string, googlecloudapigeev1keyvalueentry *GoogleCloudApigeeV1KeyValueEntry) *OrganizationsApisKeyvaluemapsEntriesCreateCall {
	c := &OrganizationsApisKeyvaluemapsEntriesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1keyvalueentry = googlecloudapigeev1keyvalueentry
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApisKeyvaluemapsEntriesCreateCall) Fields(s ...googleapi.Field) *OrganizationsApisKeyvaluemapsEntriesCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApisKeyvaluemapsEntriesCreateCall) Context(ctx context.Context) *OrganizationsApisKeyvaluemapsEntriesCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApisKeyvaluemapsEntriesCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApisKeyvaluemapsEntriesCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1keyvalueentry)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/entries")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apis.keyvaluemaps.entries.create" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueEntry or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueEntry.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApisKeyvaluemapsEntriesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueEntry, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueEntry{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates key value entries in a key value map scoped to an organization, environment, or API proxy. **Note**: Supported for Apigee hybrid 1.8.x and higher.",
	//   "flatPath": "v1/organizations/{organizationsId}/apis/{apisId}/keyvaluemaps/{keyvaluemapsId}/entries",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.apis.keyvaluemaps.entries.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Scope as indicated by the URI in which to create the key value map entry. Use **one** of the following structures in your request: * `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`. * `organizations/{organization}/environments/{environment}/keyvaluemaps/{keyvaluemap}` * `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apis/[^/]+/keyvaluemaps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/entries",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apis.keyvaluemaps.entries.delete":

type OrganizationsApisKeyvaluemapsEntriesDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a key value entry from a key value map scoped to an
// organization, environment, or API proxy. **Notes:** * After you
// delete the key value entry, the policy consuming the entry will
// continue to function with its cached values for a few minutes. This
// is expected behavior. * Supported for Apigee hybrid 1.8.x and higher.
//
//   - name: Scope as indicated by the URI in which to delete the key
//     value map entry. Use **one** of the following structures in your
//     request: *
//     `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}/
//     entries/{entry}`. *
//     `organizations/{organization}/environments/{environment}/keyvaluemap
//     s/{keyvaluemap}/entries/{entry}` *
//     `organizations/{organization}/keyvaluemaps/{keyvaluemap}/entries/{en
//     try}`.
func (r *OrganizationsApisKeyvaluemapsEntriesService) Delete(name string) *OrganizationsApisKeyvaluemapsEntriesDeleteCall {
	c := &OrganizationsApisKeyvaluemapsEntriesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApisKeyvaluemapsEntriesDeleteCall) Fields(s ...googleapi.Field) *OrganizationsApisKeyvaluemapsEntriesDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApisKeyvaluemapsEntriesDeleteCall) Context(ctx context.Context) *OrganizationsApisKeyvaluemapsEntriesDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApisKeyvaluemapsEntriesDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApisKeyvaluemapsEntriesDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apis.keyvaluemaps.entries.delete" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueEntry or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueEntry.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApisKeyvaluemapsEntriesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueEntry, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueEntry{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a key value entry from a key value map scoped to an organization, environment, or API proxy. **Notes:** * After you delete the key value entry, the policy consuming the entry will continue to function with its cached values for a few minutes. This is expected behavior. * Supported for Apigee hybrid 1.8.x and higher.",
	//   "flatPath": "v1/organizations/{organizationsId}/apis/{apisId}/keyvaluemaps/{keyvaluemapsId}/entries/{entriesId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.apis.keyvaluemaps.entries.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Scope as indicated by the URI in which to delete the key value map entry. Use **one** of the following structures in your request: * `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}/entries/{entry}`. * `organizations/{organization}/environments/{environment}/keyvaluemaps/{keyvaluemap}/entries/{entry}` * `organizations/{organization}/keyvaluemaps/{keyvaluemap}/entries/{entry}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apis/[^/]+/keyvaluemaps/[^/]+/entries/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apis.keyvaluemaps.entries.get":

type OrganizationsApisKeyvaluemapsEntriesGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Get the key value entry value for a key value map scoped to an
// organization, environment, or API proxy. **Note**: Supported for
// Apigee hybrid 1.8.x and higher.
//
//   - name: Scope as indicated by the URI in which to fetch the key value
//     map entry/value. Use **one** of the following structures in your
//     request: *
//     `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}/
//     entries/{entry}`. *
//     `organizations/{organization}/environments/{environment}/keyvaluemap
//     s/{keyvaluemap}/entries/{entry}` *
//     `organizations/{organization}/keyvaluemaps/{keyvaluemap}/entries/{en
//     try}`.
func (r *OrganizationsApisKeyvaluemapsEntriesService) Get(name string) *OrganizationsApisKeyvaluemapsEntriesGetCall {
	c := &OrganizationsApisKeyvaluemapsEntriesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApisKeyvaluemapsEntriesGetCall) Fields(s ...googleapi.Field) *OrganizationsApisKeyvaluemapsEntriesGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsApisKeyvaluemapsEntriesGetCall) IfNoneMatch(entityTag string) *OrganizationsApisKeyvaluemapsEntriesGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApisKeyvaluemapsEntriesGetCall) Context(ctx context.Context) *OrganizationsApisKeyvaluemapsEntriesGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApisKeyvaluemapsEntriesGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApisKeyvaluemapsEntriesGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apis.keyvaluemaps.entries.get" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueEntry or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueEntry.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApisKeyvaluemapsEntriesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueEntry, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueEntry{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Get the key value entry value for a key value map scoped to an organization, environment, or API proxy. **Note**: Supported for Apigee hybrid 1.8.x and higher.",
	//   "flatPath": "v1/organizations/{organizationsId}/apis/{apisId}/keyvaluemaps/{keyvaluemapsId}/entries/{entriesId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.apis.keyvaluemaps.entries.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Scope as indicated by the URI in which to fetch the key value map entry/value. Use **one** of the following structures in your request: * `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}/entries/{entry}`. * `organizations/{organization}/environments/{environment}/keyvaluemaps/{keyvaluemap}/entries/{entry}` * `organizations/{organization}/keyvaluemaps/{keyvaluemap}/entries/{entry}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apis/[^/]+/keyvaluemaps/[^/]+/entries/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apis.keyvaluemaps.entries.list":

type OrganizationsApisKeyvaluemapsEntriesListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists key value entries for key values maps scoped to an
// organization, environment, or API proxy. **Note**: Supported for
// Apigee hybrid 1.8.x and higher.
//
//   - parent: Scope as indicated by the URI in which to list key value
//     maps. Use **one** of the following structures in your request: *
//     `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`
//     . *
//     `organizations/{organization}/environments/{environment}/keyvaluemap
//     s/{keyvaluemap}` *
//     `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.
func (r *OrganizationsApisKeyvaluemapsEntriesService) List(parent string) *OrganizationsApisKeyvaluemapsEntriesListCall {
	c := &OrganizationsApisKeyvaluemapsEntriesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// PageSize sets the optional parameter "pageSize": Maximum number of
// key value entries to return. If unspecified, at most 100 entries will
// be returned.
func (c *OrganizationsApisKeyvaluemapsEntriesListCall) PageSize(pageSize int64) *OrganizationsApisKeyvaluemapsEntriesListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": Page token. If
// provides, must be a valid key value entry returned from a previous
// call that can be used to retrieve the next page.
func (c *OrganizationsApisKeyvaluemapsEntriesListCall) PageToken(pageToken string) *OrganizationsApisKeyvaluemapsEntriesListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApisKeyvaluemapsEntriesListCall) Fields(s ...googleapi.Field) *OrganizationsApisKeyvaluemapsEntriesListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsApisKeyvaluemapsEntriesListCall) IfNoneMatch(entityTag string) *OrganizationsApisKeyvaluemapsEntriesListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApisKeyvaluemapsEntriesListCall) Context(ctx context.Context) *OrganizationsApisKeyvaluemapsEntriesListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApisKeyvaluemapsEntriesListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApisKeyvaluemapsEntriesListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/entries")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apis.keyvaluemaps.entries.list" call.
// Exactly one of *GoogleCloudApigeeV1ListKeyValueEntriesResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListKeyValueEntriesResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsApisKeyvaluemapsEntriesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListKeyValueEntriesResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListKeyValueEntriesResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists key value entries for key values maps scoped to an organization, environment, or API proxy. **Note**: Supported for Apigee hybrid 1.8.x and higher.",
	//   "flatPath": "v1/organizations/{organizationsId}/apis/{apisId}/keyvaluemaps/{keyvaluemapsId}/entries",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.apis.keyvaluemaps.entries.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "pageSize": {
	//       "description": "Optional. Maximum number of key value entries to return. If unspecified, at most 100 entries will be returned.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Optional. Page token. If provides, must be a valid key value entry returned from a previous call that can be used to retrieve the next page.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Scope as indicated by the URI in which to list key value maps. Use **one** of the following structures in your request: * `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`. * `organizations/{organization}/environments/{environment}/keyvaluemaps/{keyvaluemap}` * `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apis/[^/]+/keyvaluemaps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/entries",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListKeyValueEntriesResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsApisKeyvaluemapsEntriesListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListKeyValueEntriesResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.apis.keyvaluemaps.entries.update":

type OrganizationsApisKeyvaluemapsEntriesUpdateCall struct {
	s                                *Service
	name                             string
	googlecloudapigeev1keyvalueentry *GoogleCloudApigeeV1KeyValueEntry
	urlParams_                       gensupport.URLParams
	ctx_                             context.Context
	header_                          http.Header
}

// Update: Update key value entry scoped to an organization,
// environment, or API proxy for an existing key.
//
//   - name: Scope as indicated by the URI in which to create the key
//     value map entry. Use **one** of the following structures in your
//     request: *
//     `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`
//     . *
//     `organizations/{organization}/environments/{environment}/keyvaluemap
//     s/{keyvaluemap}` *
//     `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.
func (r *OrganizationsApisKeyvaluemapsEntriesService) Update(name string, googlecloudapigeev1keyvalueentry *GoogleCloudApigeeV1KeyValueEntry) *OrganizationsApisKeyvaluemapsEntriesUpdateCall {
	c := &OrganizationsApisKeyvaluemapsEntriesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1keyvalueentry = googlecloudapigeev1keyvalueentry
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApisKeyvaluemapsEntriesUpdateCall) Fields(s ...googleapi.Field) *OrganizationsApisKeyvaluemapsEntriesUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApisKeyvaluemapsEntriesUpdateCall) Context(ctx context.Context) *OrganizationsApisKeyvaluemapsEntriesUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApisKeyvaluemapsEntriesUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApisKeyvaluemapsEntriesUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1keyvalueentry)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apis.keyvaluemaps.entries.update" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueEntry or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueEntry.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApisKeyvaluemapsEntriesUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueEntry, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueEntry{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Update key value entry scoped to an organization, environment, or API proxy for an existing key.",
	//   "flatPath": "v1/organizations/{organizationsId}/apis/{apisId}/keyvaluemaps/{keyvaluemapsId}/entries/{entriesId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.apis.keyvaluemaps.entries.update",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Scope as indicated by the URI in which to create the key value map entry. Use **one** of the following structures in your request: * `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`. * `organizations/{organization}/environments/{environment}/keyvaluemaps/{keyvaluemap}` * `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apis/[^/]+/keyvaluemaps/[^/]+/entries/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apis.revisions.delete":

type OrganizationsApisRevisionsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an API proxy revision and all policies, resources,
// endpoints, and revisions associated with it. The API proxy revision
// must be undeployed before you can delete it.
//
//   - name: API proxy revision in the following format:
//     `organizations/{org}/apis/{api}/revisions/{rev}`.
func (r *OrganizationsApisRevisionsService) Delete(name string) *OrganizationsApisRevisionsDeleteCall {
	c := &OrganizationsApisRevisionsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApisRevisionsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsApisRevisionsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApisRevisionsDeleteCall) Context(ctx context.Context) *OrganizationsApisRevisionsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApisRevisionsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApisRevisionsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apis.revisions.delete" call.
// Exactly one of *GoogleCloudApigeeV1ApiProxyRevision or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1ApiProxyRevision.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsApisRevisionsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiProxyRevision, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiProxyRevision{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an API proxy revision and all policies, resources, endpoints, and revisions associated with it. The API proxy revision must be undeployed before you can delete it.",
	//   "flatPath": "v1/organizations/{organizationsId}/apis/{apisId}/revisions/{revisionsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.apis.revisions.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. API proxy revision in the following format: `organizations/{org}/apis/{api}/revisions/{rev}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apis/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiProxyRevision"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apis.revisions.get":

type OrganizationsApisRevisionsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets an API proxy revision. To download the API proxy
// configuration bundle for the specified revision as a zip file, set
// the `format` query parameter to `bundle`. If you are using curl,
// specify `-o filename.zip` to save the output to a file; otherwise, it
// displays to `stdout`. Then, develop the API proxy configuration
// locally and upload the updated API proxy configuration revision, as
// described in updateApiProxyRevision (updateApiProxyRevision).
//
//   - name: API proxy revision in the following format:
//     `organizations/{org}/apis/{api}/revisions/{rev}`.
func (r *OrganizationsApisRevisionsService) Get(name string) *OrganizationsApisRevisionsGetCall {
	c := &OrganizationsApisRevisionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Format sets the optional parameter "format": Format used when
// downloading the API proxy configuration revision. Set to `bundle` to
// download the API proxy configuration revision as a zip file.
func (c *OrganizationsApisRevisionsGetCall) Format(format string) *OrganizationsApisRevisionsGetCall {
	c.urlParams_.Set("format", format)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApisRevisionsGetCall) Fields(s ...googleapi.Field) *OrganizationsApisRevisionsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsApisRevisionsGetCall) IfNoneMatch(entityTag string) *OrganizationsApisRevisionsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApisRevisionsGetCall) Context(ctx context.Context) *OrganizationsApisRevisionsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApisRevisionsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApisRevisionsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apis.revisions.get" call.
// Exactly one of *GoogleApiHttpBody or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleApiHttpBody.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsApisRevisionsGetCall) Do(opts ...googleapi.CallOption) (*GoogleApiHttpBody, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleApiHttpBody{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets an API proxy revision. To download the API proxy configuration bundle for the specified revision as a zip file, set the `format` query parameter to `bundle`. If you are using curl, specify `-o filename.zip` to save the output to a file; otherwise, it displays to `stdout`. Then, develop the API proxy configuration locally and upload the updated API proxy configuration revision, as described in [updateApiProxyRevision](updateApiProxyRevision).",
	//   "flatPath": "v1/organizations/{organizationsId}/apis/{apisId}/revisions/{revisionsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.apis.revisions.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "format": {
	//       "description": "Format used when downloading the API proxy configuration revision. Set to `bundle` to download the API proxy configuration revision as a zip file.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "Required. API proxy revision in the following format: `organizations/{org}/apis/{api}/revisions/{rev}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apis/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleApiHttpBody"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apis.revisions.updateApiProxyRevision":

type OrganizationsApisRevisionsUpdateApiProxyRevisionCall struct {
	s                 *Service
	name              string
	googleapihttpbody *GoogleApiHttpBody
	urlParams_        gensupport.URLParams
	ctx_              context.Context
	header_           http.Header
}

// UpdateApiProxyRevision: Updates an existing API proxy revision by
// uploading the API proxy configuration bundle as a zip file from your
// local machine. You can update only API proxy revisions that have
// never been deployed. After deployment, an API proxy revision becomes
// immutable, even if it is undeployed. Set the `Content-Type` header to
// either `multipart/form-data` or `application/octet-stream`.
//
//   - name: API proxy revision to update in the following format:
//     `organizations/{org}/apis/{api}/revisions/{rev}`.
func (r *OrganizationsApisRevisionsService) UpdateApiProxyRevision(name string, googleapihttpbody *GoogleApiHttpBody) *OrganizationsApisRevisionsUpdateApiProxyRevisionCall {
	c := &OrganizationsApisRevisionsUpdateApiProxyRevisionCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googleapihttpbody = googleapihttpbody
	return c
}

// Validate sets the optional parameter "validate": Ignored. All uploads
// are validated regardless of the value of this field. Maintained for
// compatibility with Apigee Edge API.
func (c *OrganizationsApisRevisionsUpdateApiProxyRevisionCall) Validate(validate bool) *OrganizationsApisRevisionsUpdateApiProxyRevisionCall {
	c.urlParams_.Set("validate", fmt.Sprint(validate))
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApisRevisionsUpdateApiProxyRevisionCall) Fields(s ...googleapi.Field) *OrganizationsApisRevisionsUpdateApiProxyRevisionCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApisRevisionsUpdateApiProxyRevisionCall) Context(ctx context.Context) *OrganizationsApisRevisionsUpdateApiProxyRevisionCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApisRevisionsUpdateApiProxyRevisionCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApisRevisionsUpdateApiProxyRevisionCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleapihttpbody)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apis.revisions.updateApiProxyRevision" call.
// Exactly one of *GoogleCloudApigeeV1ApiProxyRevision or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1ApiProxyRevision.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsApisRevisionsUpdateApiProxyRevisionCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiProxyRevision, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiProxyRevision{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates an existing API proxy revision by uploading the API proxy configuration bundle as a zip file from your local machine. You can update only API proxy revisions that have never been deployed. After deployment, an API proxy revision becomes immutable, even if it is undeployed. Set the `Content-Type` header to either `multipart/form-data` or `application/octet-stream`.",
	//   "flatPath": "v1/organizations/{organizationsId}/apis/{apisId}/revisions/{revisionsId}",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.apis.revisions.updateApiProxyRevision",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. API proxy revision to update in the following format: `organizations/{org}/apis/{api}/revisions/{rev}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apis/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "validate": {
	//       "description": "Ignored. All uploads are validated regardless of the value of this field. Maintained for compatibility with Apigee Edge API.",
	//       "location": "query",
	//       "type": "boolean"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleApiHttpBody"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiProxyRevision"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apis.revisions.deployments.list":

type OrganizationsApisRevisionsDeploymentsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all deployments of an API proxy revision.
//
//   - parent: Name of the API proxy revision for which to return
//     deployment information in the following format:
//     `organizations/{org}/apis/{api}/revisions/{rev}`.
func (r *OrganizationsApisRevisionsDeploymentsService) List(parent string) *OrganizationsApisRevisionsDeploymentsListCall {
	c := &OrganizationsApisRevisionsDeploymentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsApisRevisionsDeploymentsListCall) Fields(s ...googleapi.Field) *OrganizationsApisRevisionsDeploymentsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsApisRevisionsDeploymentsListCall) IfNoneMatch(entityTag string) *OrganizationsApisRevisionsDeploymentsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsApisRevisionsDeploymentsListCall) Context(ctx context.Context) *OrganizationsApisRevisionsDeploymentsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsApisRevisionsDeploymentsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsApisRevisionsDeploymentsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/deployments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apis.revisions.deployments.list" call.
// Exactly one of *GoogleCloudApigeeV1ListDeploymentsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListDeploymentsResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsApisRevisionsDeploymentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListDeploymentsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListDeploymentsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all deployments of an API proxy revision.",
	//   "flatPath": "v1/organizations/{organizationsId}/apis/{apisId}/revisions/{revisionsId}/deployments",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.apis.revisions.deployments.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the API proxy revision for which to return deployment information in the following format: `organizations/{org}/apis/{api}/revisions/{rev}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apis/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/deployments",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListDeploymentsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.appgroups.create":

type OrganizationsAppgroupsCreateCall struct {
	s                           *Service
	parent                      string
	googlecloudapigeev1appgroup *GoogleCloudApigeeV1AppGroup
	urlParams_                  gensupport.URLParams
	ctx_                        context.Context
	header_                     http.Header
}

// Create: Creates an AppGroup. Once created, user can register apps
// under the AppGroup to obtain secret key and password. At creation
// time, the AppGroup's state is set as `active`.
//
//   - parent: Name of the Apigee organization in which the AppGroup is
//     created. Use the following structure in your request:
//     `organizations/{org}`.
func (r *OrganizationsAppgroupsService) Create(parent string, googlecloudapigeev1appgroup *GoogleCloudApigeeV1AppGroup) *OrganizationsAppgroupsCreateCall {
	c := &OrganizationsAppgroupsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1appgroup = googlecloudapigeev1appgroup
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppgroupsCreateCall) Fields(s ...googleapi.Field) *OrganizationsAppgroupsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppgroupsCreateCall) Context(ctx context.Context) *OrganizationsAppgroupsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppgroupsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppgroupsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1appgroup)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/appgroups")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.appgroups.create" call.
// Exactly one of *GoogleCloudApigeeV1AppGroup or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1AppGroup.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsAppgroupsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AppGroup, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AppGroup{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates an AppGroup. Once created, user can register apps under the AppGroup to obtain secret key and password. At creation time, the AppGroup's state is set as `active`.",
	//   "flatPath": "v1/organizations/{organizationsId}/appgroups",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.appgroups.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the Apigee organization in which the AppGroup is created. Use the following structure in your request: `organizations/{org}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/appgroups",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1AppGroup"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AppGroup"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.appgroups.delete":

type OrganizationsAppgroupsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an AppGroup. All app and API keys associations with
// the AppGroup are also removed. **Warning**: This API will permanently
// delete the AppGroup and related artifacts. **Note**: The delete
// operation is asynchronous. The AppGroup app is deleted immediately,
// but its associated resources, such as apps and API keys, may take
// anywhere from a few seconds to a few minutes to be deleted.
//
//   - name: Name of the AppGroup. Use the following structure in your
//     request: `organizations/{org}/appgroups/{app_group_name}`.
func (r *OrganizationsAppgroupsService) Delete(name string) *OrganizationsAppgroupsDeleteCall {
	c := &OrganizationsAppgroupsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppgroupsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsAppgroupsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppgroupsDeleteCall) Context(ctx context.Context) *OrganizationsAppgroupsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppgroupsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppgroupsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.appgroups.delete" call.
// Exactly one of *GoogleCloudApigeeV1AppGroup or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1AppGroup.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsAppgroupsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AppGroup, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AppGroup{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an AppGroup. All app and API keys associations with the AppGroup are also removed. **Warning**: This API will permanently delete the AppGroup and related artifacts. **Note**: The delete operation is asynchronous. The AppGroup app is deleted immediately, but its associated resources, such as apps and API keys, may take anywhere from a few seconds to a few minutes to be deleted.",
	//   "flatPath": "v1/organizations/{organizationsId}/appgroups/{appgroupsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.appgroups.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the AppGroup. Use the following structure in your request: `organizations/{org}/appgroups/{app_group_name}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/appgroups/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AppGroup"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.appgroups.get":

type OrganizationsAppgroupsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Returns the AppGroup details for the provided AppGroup name in
// the request URI.
//
//   - name: Name of the AppGroup. Use the following structure in your
//     request: `organizations/{org}/appgroups/{app_group_name}`.
func (r *OrganizationsAppgroupsService) Get(name string) *OrganizationsAppgroupsGetCall {
	c := &OrganizationsAppgroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppgroupsGetCall) Fields(s ...googleapi.Field) *OrganizationsAppgroupsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsAppgroupsGetCall) IfNoneMatch(entityTag string) *OrganizationsAppgroupsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppgroupsGetCall) Context(ctx context.Context) *OrganizationsAppgroupsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppgroupsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppgroupsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.appgroups.get" call.
// Exactly one of *GoogleCloudApigeeV1AppGroup or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1AppGroup.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsAppgroupsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AppGroup, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AppGroup{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Returns the AppGroup details for the provided AppGroup name in the request URI.",
	//   "flatPath": "v1/organizations/{organizationsId}/appgroups/{appgroupsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.appgroups.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the AppGroup. Use the following structure in your request: `organizations/{org}/appgroups/{app_group_name}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/appgroups/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AppGroup"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.appgroups.list":

type OrganizationsAppgroupsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all AppGroups in an organization. A maximum of 1000
// AppGroups are returned in the response if PageSize is not specified,
// or if the PageSize is greater than 1000.
//
//   - parent: Name of the Apigee organization. Use the following
//     structure in your request: `organizations/{org}`.
func (r *OrganizationsAppgroupsService) List(parent string) *OrganizationsAppgroupsListCall {
	c := &OrganizationsAppgroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Filter sets the optional parameter "filter": The filter expression to
// be used to get the list of AppGroups, where filtering can be done on
// status, channelId or channelUri of the app group. Examples:
// filter=status=active", filter=channelId=, filter=channelUri=
func (c *OrganizationsAppgroupsListCall) Filter(filter string) *OrganizationsAppgroupsListCall {
	c.urlParams_.Set("filter", filter)
	return c
}

// PageSize sets the optional parameter "pageSize": Count of AppGroups a
// single page can have in the response. If unspecified, at most 1000
// AppGroups will be returned. The maximum value is 1000; values above
// 1000 will be coerced to 1000.
func (c *OrganizationsAppgroupsListCall) PageSize(pageSize int64) *OrganizationsAppgroupsListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": The starting index
// record for listing the AppGroups.
func (c *OrganizationsAppgroupsListCall) PageToken(pageToken string) *OrganizationsAppgroupsListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppgroupsListCall) Fields(s ...googleapi.Field) *OrganizationsAppgroupsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsAppgroupsListCall) IfNoneMatch(entityTag string) *OrganizationsAppgroupsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppgroupsListCall) Context(ctx context.Context) *OrganizationsAppgroupsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppgroupsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppgroupsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/appgroups")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.appgroups.list" call.
// Exactly one of *GoogleCloudApigeeV1ListAppGroupsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListAppGroupsResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsAppgroupsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListAppGroupsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListAppGroupsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all AppGroups in an organization. A maximum of 1000 AppGroups are returned in the response if PageSize is not specified, or if the PageSize is greater than 1000.",
	//   "flatPath": "v1/organizations/{organizationsId}/appgroups",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.appgroups.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "filter": {
	//       "description": "The filter expression to be used to get the list of AppGroups, where filtering can be done on status, channelId or channelUri of the app group. Examples: filter=status=active\", filter=channelId=, filter=channelUri=",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "pageSize": {
	//       "description": "Count of AppGroups a single page can have in the response. If unspecified, at most 1000 AppGroups will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "The starting index record for listing the AppGroups.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the Apigee organization. Use the following structure in your request: `organizations/{org}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/appgroups",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListAppGroupsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsAppgroupsListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListAppGroupsResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.appgroups.update":

type OrganizationsAppgroupsUpdateCall struct {
	s                           *Service
	name                        string
	googlecloudapigeev1appgroup *GoogleCloudApigeeV1AppGroup
	urlParams_                  gensupport.URLParams
	ctx_                        context.Context
	header_                     http.Header
}

// Update: Updates an AppGroup. This API replaces the existing AppGroup
// details with those specified in the request. Include or exclude any
// existing details that you want to retain or delete, respectively.
// Note that the state of the AppGroup should be updated using `action`,
// and not via AppGroup.
//
//   - name: Name of the AppGroup. Use the following structure in your
//     request: `organizations/{org}/appgroups/{app_group_name}`.
func (r *OrganizationsAppgroupsService) Update(name string, googlecloudapigeev1appgroup *GoogleCloudApigeeV1AppGroup) *OrganizationsAppgroupsUpdateCall {
	c := &OrganizationsAppgroupsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1appgroup = googlecloudapigeev1appgroup
	return c
}

// Action sets the optional parameter "action": Activate or de-activate
// the AppGroup by setting the action as `active` or `inactive`. The
// `Content-Type` header must be set to `application/octet-stream`, with
// empty body.
func (c *OrganizationsAppgroupsUpdateCall) Action(action string) *OrganizationsAppgroupsUpdateCall {
	c.urlParams_.Set("action", action)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppgroupsUpdateCall) Fields(s ...googleapi.Field) *OrganizationsAppgroupsUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppgroupsUpdateCall) Context(ctx context.Context) *OrganizationsAppgroupsUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppgroupsUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppgroupsUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1appgroup)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.appgroups.update" call.
// Exactly one of *GoogleCloudApigeeV1AppGroup or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1AppGroup.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsAppgroupsUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AppGroup, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AppGroup{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates an AppGroup. This API replaces the existing AppGroup details with those specified in the request. Include or exclude any existing details that you want to retain or delete, respectively. Note that the state of the AppGroup should be updated using `action`, and not via AppGroup.",
	//   "flatPath": "v1/organizations/{organizationsId}/appgroups/{appgroupsId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.appgroups.update",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "action": {
	//       "description": "Activate or de-activate the AppGroup by setting the action as `active` or `inactive`. The `Content-Type` header must be set to `application/octet-stream`, with empty body.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "Required. Name of the AppGroup. Use the following structure in your request: `organizations/{org}/appgroups/{app_group_name}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/appgroups/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1AppGroup"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AppGroup"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.appgroups.apps.create":

type OrganizationsAppgroupsAppsCreateCall struct {
	s                              *Service
	parent                         string
	googlecloudapigeev1appgroupapp *GoogleCloudApigeeV1AppGroupApp
	urlParams_                     gensupport.URLParams
	ctx_                           context.Context
	header_                        http.Header
}

// Create: Creates an app and associates it with an AppGroup. This API
// associates the AppGroup app with the specified API product and
// auto-generates an API key for the app to use in calls to API proxies
// inside that API product. The `name` is the unique ID of the app that
// you can use in API calls.
//
//   - parent: Name of the AppGroup. Use the following structure in your
//     request: `organizations/{org}/appgroups/{app_group_name}`.
func (r *OrganizationsAppgroupsAppsService) Create(parent string, googlecloudapigeev1appgroupapp *GoogleCloudApigeeV1AppGroupApp) *OrganizationsAppgroupsAppsCreateCall {
	c := &OrganizationsAppgroupsAppsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1appgroupapp = googlecloudapigeev1appgroupapp
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppgroupsAppsCreateCall) Fields(s ...googleapi.Field) *OrganizationsAppgroupsAppsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppgroupsAppsCreateCall) Context(ctx context.Context) *OrganizationsAppgroupsAppsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppgroupsAppsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppgroupsAppsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1appgroupapp)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/apps")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.appgroups.apps.create" call.
// Exactly one of *GoogleCloudApigeeV1AppGroupApp or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1AppGroupApp.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsAppgroupsAppsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AppGroupApp, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AppGroupApp{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates an app and associates it with an AppGroup. This API associates the AppGroup app with the specified API product and auto-generates an API key for the app to use in calls to API proxies inside that API product. The `name` is the unique ID of the app that you can use in API calls.",
	//   "flatPath": "v1/organizations/{organizationsId}/appgroups/{appgroupsId}/apps",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.appgroups.apps.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the AppGroup. Use the following structure in your request: `organizations/{org}/appgroups/{app_group_name}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/appgroups/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/apps",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1AppGroupApp"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AppGroupApp"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.appgroups.apps.delete":

type OrganizationsAppgroupsAppsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an AppGroup app. **Note**: The delete operation is
// asynchronous. The AppGroup app is deleted immediately, but its
// associated resources, such as app keys or access tokens, may take
// anywhere from a few seconds to a few minutes to be deleted.
//
//   - name: Name of the AppGroup app. Use the following structure in your
//     request:
//     `organizations/{org}/appgroups/{app_group_name}/apps/{app}`.
func (r *OrganizationsAppgroupsAppsService) Delete(name string) *OrganizationsAppgroupsAppsDeleteCall {
	c := &OrganizationsAppgroupsAppsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppgroupsAppsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsAppgroupsAppsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppgroupsAppsDeleteCall) Context(ctx context.Context) *OrganizationsAppgroupsAppsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppgroupsAppsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppgroupsAppsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.appgroups.apps.delete" call.
// Exactly one of *GoogleCloudApigeeV1AppGroupApp or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1AppGroupApp.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsAppgroupsAppsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AppGroupApp, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AppGroupApp{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an AppGroup app. **Note**: The delete operation is asynchronous. The AppGroup app is deleted immediately, but its associated resources, such as app keys or access tokens, may take anywhere from a few seconds to a few minutes to be deleted.",
	//   "flatPath": "v1/organizations/{organizationsId}/appgroups/{appgroupsId}/apps/{appsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.appgroups.apps.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the AppGroup app. Use the following structure in your request: `organizations/{org}/appgroups/{app_group_name}/apps/{app}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/appgroups/[^/]+/apps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AppGroupApp"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.appgroups.apps.get":

type OrganizationsAppgroupsAppsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Returns the details for an AppGroup app.
//
//   - name: Name of the AppGroup app. Use the following structure in your
//     request:
//     `organizations/{org}/appgroups/{app_group_name}/apps/{app}`.
func (r *OrganizationsAppgroupsAppsService) Get(name string) *OrganizationsAppgroupsAppsGetCall {
	c := &OrganizationsAppgroupsAppsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppgroupsAppsGetCall) Fields(s ...googleapi.Field) *OrganizationsAppgroupsAppsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsAppgroupsAppsGetCall) IfNoneMatch(entityTag string) *OrganizationsAppgroupsAppsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppgroupsAppsGetCall) Context(ctx context.Context) *OrganizationsAppgroupsAppsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppgroupsAppsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppgroupsAppsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.appgroups.apps.get" call.
// Exactly one of *GoogleCloudApigeeV1AppGroupApp or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1AppGroupApp.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsAppgroupsAppsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AppGroupApp, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AppGroupApp{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Returns the details for an AppGroup app.",
	//   "flatPath": "v1/organizations/{organizationsId}/appgroups/{appgroupsId}/apps/{appsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.appgroups.apps.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the AppGroup app. Use the following structure in your request: `organizations/{org}/appgroups/{app_group_name}/apps/{app}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/appgroups/[^/]+/apps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AppGroupApp"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.appgroups.apps.list":

type OrganizationsAppgroupsAppsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all apps created by an AppGroup in an Apigee
// organization. Optionally, you can request an expanded view of the
// AppGroup apps. Lists all AppGroupApps in an AppGroup. A maximum of
// 1000 AppGroup apps are returned in the response if PageSize is not
// specified, or if the PageSize is greater than 1000.
//
//   - parent: Name of the AppGroup. Use the following structure in your
//     request: `organizations/{org}/appgroups/{app_group_name}`.
func (r *OrganizationsAppgroupsAppsService) List(parent string) *OrganizationsAppgroupsAppsListCall {
	c := &OrganizationsAppgroupsAppsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// PageSize sets the optional parameter "pageSize": Maximum number
// entries to return. If unspecified, at most 1000 entries will be
// returned.
func (c *OrganizationsAppgroupsAppsListCall) PageSize(pageSize int64) *OrganizationsAppgroupsAppsListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": Page token. If
// provides, must be a valid AppGroup app returned from a previous call
// that can be used to retrieve the next page.
func (c *OrganizationsAppgroupsAppsListCall) PageToken(pageToken string) *OrganizationsAppgroupsAppsListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppgroupsAppsListCall) Fields(s ...googleapi.Field) *OrganizationsAppgroupsAppsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsAppgroupsAppsListCall) IfNoneMatch(entityTag string) *OrganizationsAppgroupsAppsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppgroupsAppsListCall) Context(ctx context.Context) *OrganizationsAppgroupsAppsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppgroupsAppsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppgroupsAppsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/apps")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.appgroups.apps.list" call.
// Exactly one of *GoogleCloudApigeeV1ListAppGroupAppsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListAppGroupAppsResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsAppgroupsAppsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListAppGroupAppsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListAppGroupAppsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all apps created by an AppGroup in an Apigee organization. Optionally, you can request an expanded view of the AppGroup apps. Lists all AppGroupApps in an AppGroup. A maximum of 1000 AppGroup apps are returned in the response if PageSize is not specified, or if the PageSize is greater than 1000.",
	//   "flatPath": "v1/organizations/{organizationsId}/appgroups/{appgroupsId}/apps",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.appgroups.apps.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "pageSize": {
	//       "description": "Optional. Maximum number entries to return. If unspecified, at most 1000 entries will be returned.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Optional. Page token. If provides, must be a valid AppGroup app returned from a previous call that can be used to retrieve the next page.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the AppGroup. Use the following structure in your request: `organizations/{org}/appgroups/{app_group_name}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/appgroups/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/apps",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListAppGroupAppsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsAppgroupsAppsListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListAppGroupAppsResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.appgroups.apps.update":

type OrganizationsAppgroupsAppsUpdateCall struct {
	s                              *Service
	name                           string
	googlecloudapigeev1appgroupapp *GoogleCloudApigeeV1AppGroupApp
	urlParams_                     gensupport.URLParams
	ctx_                           context.Context
	header_                        http.Header
}

// Update: Updates the details for an AppGroup app. In addition, you can
// add an API product to an AppGroup app and automatically generate an
// API key for the app to use when calling APIs in the API product. If
// you want to use an existing API key for the API product, add the API
// product to the API key using the UpdateAppGroupAppKey API. Using this
// API, you cannot update the app name, as it is the primary key used to
// identify the app and cannot be changed. This API replaces the
// existing attributes with those specified in the request. Include or
// exclude any existing attributes that you want to retain or delete,
// respectively.
//
//   - name: Name of the AppGroup app. Use the following structure in your
//     request:
//     `organizations/{org}/appgroups/{app_group_name}/apps/{app}`.
func (r *OrganizationsAppgroupsAppsService) Update(name string, googlecloudapigeev1appgroupapp *GoogleCloudApigeeV1AppGroupApp) *OrganizationsAppgroupsAppsUpdateCall {
	c := &OrganizationsAppgroupsAppsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1appgroupapp = googlecloudapigeev1appgroupapp
	return c
}

// Action sets the optional parameter "action": Approve or revoke the
// consumer key by setting this value to `approve` or `revoke`. The
// `Content-Type` header must be set to `application/octet-stream`, with
// empty body.
func (c *OrganizationsAppgroupsAppsUpdateCall) Action(action string) *OrganizationsAppgroupsAppsUpdateCall {
	c.urlParams_.Set("action", action)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppgroupsAppsUpdateCall) Fields(s ...googleapi.Field) *OrganizationsAppgroupsAppsUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppgroupsAppsUpdateCall) Context(ctx context.Context) *OrganizationsAppgroupsAppsUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppgroupsAppsUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppgroupsAppsUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1appgroupapp)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.appgroups.apps.update" call.
// Exactly one of *GoogleCloudApigeeV1AppGroupApp or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1AppGroupApp.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsAppgroupsAppsUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AppGroupApp, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AppGroupApp{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates the details for an AppGroup app. In addition, you can add an API product to an AppGroup app and automatically generate an API key for the app to use when calling APIs in the API product. If you want to use an existing API key for the API product, add the API product to the API key using the UpdateAppGroupAppKey API. Using this API, you cannot update the app name, as it is the primary key used to identify the app and cannot be changed. This API replaces the existing attributes with those specified in the request. Include or exclude any existing attributes that you want to retain or delete, respectively.",
	//   "flatPath": "v1/organizations/{organizationsId}/appgroups/{appgroupsId}/apps/{appsId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.appgroups.apps.update",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "action": {
	//       "description": "Approve or revoke the consumer key by setting this value to `approve` or `revoke`. The `Content-Type` header must be set to `application/octet-stream`, with empty body.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "Required. Name of the AppGroup app. Use the following structure in your request: `organizations/{org}/appgroups/{app_group_name}/apps/{app}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/appgroups/[^/]+/apps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1AppGroupApp"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AppGroupApp"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.appgroups.apps.keys.create":

type OrganizationsAppgroupsAppsKeysCreateCall struct {
	s                                 *Service
	parent                            string
	googlecloudapigeev1appgroupappkey *GoogleCloudApigeeV1AppGroupAppKey
	urlParams_                        gensupport.URLParams
	ctx_                              context.Context
	header_                           http.Header
}

// Create: Creates a custom consumer key and secret for a AppGroup app.
// This is particularly useful if you want to migrate existing consumer
// keys and secrets to Apigee from another system. Consumer keys and
// secrets can contain letters, numbers, underscores, and hyphens. No
// other special characters are allowed. To avoid service disruptions, a
// consumer key and secret should not exceed 2 KBs each. **Note**: When
// creating the consumer key and secret, an association to API products
// will not be made. Therefore, you should not specify the associated
// API products in your request. Instead, use the
// ProductizeAppGroupAppKey API to make the association after the
// consumer key and secret are created. If a consumer key and secret
// already exist, you can keep them or delete them using the
// DeleteAppGroupAppKey API.
//
//   - parent: Parent of the AppGroup app key. Use the following structure
//     in your request:
//     `organizations/{org}/appgroups/{app_group_name}/apps/{app}/keys`.
func (r *OrganizationsAppgroupsAppsKeysService) Create(parent string, googlecloudapigeev1appgroupappkey *GoogleCloudApigeeV1AppGroupAppKey) *OrganizationsAppgroupsAppsKeysCreateCall {
	c := &OrganizationsAppgroupsAppsKeysCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1appgroupappkey = googlecloudapigeev1appgroupappkey
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppgroupsAppsKeysCreateCall) Fields(s ...googleapi.Field) *OrganizationsAppgroupsAppsKeysCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppgroupsAppsKeysCreateCall) Context(ctx context.Context) *OrganizationsAppgroupsAppsKeysCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppgroupsAppsKeysCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppgroupsAppsKeysCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1appgroupappkey)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/keys")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.appgroups.apps.keys.create" call.
// Exactly one of *GoogleCloudApigeeV1AppGroupAppKey or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1AppGroupAppKey.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsAppgroupsAppsKeysCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AppGroupAppKey, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AppGroupAppKey{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a custom consumer key and secret for a AppGroup app. This is particularly useful if you want to migrate existing consumer keys and secrets to Apigee from another system. Consumer keys and secrets can contain letters, numbers, underscores, and hyphens. No other special characters are allowed. To avoid service disruptions, a consumer key and secret should not exceed 2 KBs each. **Note**: When creating the consumer key and secret, an association to API products will not be made. Therefore, you should not specify the associated API products in your request. Instead, use the ProductizeAppGroupAppKey API to make the association after the consumer key and secret are created. If a consumer key and secret already exist, you can keep them or delete them using the DeleteAppGroupAppKey API.",
	//   "flatPath": "v1/organizations/{organizationsId}/appgroups/{appgroupsId}/apps/{appsId}/keys",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.appgroups.apps.keys.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Parent of the AppGroup app key. Use the following structure in your request: `organizations/{org}/appgroups/{app_group_name}/apps/{app}/keys`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/appgroups/[^/]+/apps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/keys",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1AppGroupAppKey"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AppGroupAppKey"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.appgroups.apps.keys.delete":

type OrganizationsAppgroupsAppsKeysDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an app's consumer key and removes all API products
// associated with the app. After the consumer key is deleted, it cannot
// be used to access any APIs.
//
//   - name: Name of the AppGroup app key. Use the following structure in
//     your request:
//     `organizations/{org}/appgroups/{app_group_name}/apps/{app}/keys/{key
//     }`.
func (r *OrganizationsAppgroupsAppsKeysService) Delete(name string) *OrganizationsAppgroupsAppsKeysDeleteCall {
	c := &OrganizationsAppgroupsAppsKeysDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppgroupsAppsKeysDeleteCall) Fields(s ...googleapi.Field) *OrganizationsAppgroupsAppsKeysDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppgroupsAppsKeysDeleteCall) Context(ctx context.Context) *OrganizationsAppgroupsAppsKeysDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppgroupsAppsKeysDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppgroupsAppsKeysDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.appgroups.apps.keys.delete" call.
// Exactly one of *GoogleCloudApigeeV1AppGroupAppKey or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1AppGroupAppKey.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsAppgroupsAppsKeysDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AppGroupAppKey, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AppGroupAppKey{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an app's consumer key and removes all API products associated with the app. After the consumer key is deleted, it cannot be used to access any APIs.",
	//   "flatPath": "v1/organizations/{organizationsId}/appgroups/{appgroupsId}/apps/{appsId}/keys/{keysId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.appgroups.apps.keys.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the AppGroup app key. Use the following structure in your request: `organizations/{org}/appgroups/{app_group_name}/apps/{app}/keys/{key}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/appgroups/[^/]+/apps/[^/]+/keys/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AppGroupAppKey"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.appgroups.apps.keys.get":

type OrganizationsAppgroupsAppsKeysGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets details for a consumer key for a AppGroup app, including
// the key and secret value, associated API products, and other
// information.
//
//   - name: Name of the AppGroup app key. Use the following structure in
//     your request:
//     `organizations/{org}/appgroups/{app_group_name}/apps/{app}/keys/{key
//     }`.
func (r *OrganizationsAppgroupsAppsKeysService) Get(name string) *OrganizationsAppgroupsAppsKeysGetCall {
	c := &OrganizationsAppgroupsAppsKeysGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppgroupsAppsKeysGetCall) Fields(s ...googleapi.Field) *OrganizationsAppgroupsAppsKeysGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsAppgroupsAppsKeysGetCall) IfNoneMatch(entityTag string) *OrganizationsAppgroupsAppsKeysGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppgroupsAppsKeysGetCall) Context(ctx context.Context) *OrganizationsAppgroupsAppsKeysGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppgroupsAppsKeysGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppgroupsAppsKeysGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.appgroups.apps.keys.get" call.
// Exactly one of *GoogleCloudApigeeV1AppGroupAppKey or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1AppGroupAppKey.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsAppgroupsAppsKeysGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AppGroupAppKey, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AppGroupAppKey{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets details for a consumer key for a AppGroup app, including the key and secret value, associated API products, and other information.",
	//   "flatPath": "v1/organizations/{organizationsId}/appgroups/{appgroupsId}/apps/{appsId}/keys/{keysId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.appgroups.apps.keys.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the AppGroup app key. Use the following structure in your request: `organizations/{org}/appgroups/{app_group_name}/apps/{app}/keys/{key}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/appgroups/[^/]+/apps/[^/]+/keys/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AppGroupAppKey"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.appgroups.apps.keys.updateAppGroupAppKey":

type OrganizationsAppgroupsAppsKeysUpdateAppGroupAppKeyCall struct {
	s                                              *Service
	name                                           string
	googlecloudapigeev1updateappgroupappkeyrequest *GoogleCloudApigeeV1UpdateAppGroupAppKeyRequest
	urlParams_                                     gensupport.URLParams
	ctx_                                           context.Context
	header_                                        http.Header
}

// UpdateAppGroupAppKey: Adds an API product to an AppGroupAppKey,
// enabling the app that holds the key to access the API resources
// bundled in the API product. In addition, you can add attributes to
// the AppGroupAppKey. This API replaces the existing attributes with
// those specified in the request. Include or exclude any existing
// attributes that you want to retain or delete, respectively. You can
// use the same key to access all API products associated with the app.
//
//   - name: Name of the AppGroup app key. Use the following structure in
//     your request:
//     `organizations/{org}/appgroups/{app_group_name}/apps/{app}/keys/{key
//     }`.
func (r *OrganizationsAppgroupsAppsKeysService) UpdateAppGroupAppKey(name string, googlecloudapigeev1updateappgroupappkeyrequest *GoogleCloudApigeeV1UpdateAppGroupAppKeyRequest) *OrganizationsAppgroupsAppsKeysUpdateAppGroupAppKeyCall {
	c := &OrganizationsAppgroupsAppsKeysUpdateAppGroupAppKeyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1updateappgroupappkeyrequest = googlecloudapigeev1updateappgroupappkeyrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppgroupsAppsKeysUpdateAppGroupAppKeyCall) Fields(s ...googleapi.Field) *OrganizationsAppgroupsAppsKeysUpdateAppGroupAppKeyCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppgroupsAppsKeysUpdateAppGroupAppKeyCall) Context(ctx context.Context) *OrganizationsAppgroupsAppsKeysUpdateAppGroupAppKeyCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppgroupsAppsKeysUpdateAppGroupAppKeyCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppgroupsAppsKeysUpdateAppGroupAppKeyCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1updateappgroupappkeyrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.appgroups.apps.keys.updateAppGroupAppKey" call.
// Exactly one of *GoogleCloudApigeeV1AppGroupAppKey or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1AppGroupAppKey.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsAppgroupsAppsKeysUpdateAppGroupAppKeyCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AppGroupAppKey, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AppGroupAppKey{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Adds an API product to an AppGroupAppKey, enabling the app that holds the key to access the API resources bundled in the API product. In addition, you can add attributes to the AppGroupAppKey. This API replaces the existing attributes with those specified in the request. Include or exclude any existing attributes that you want to retain or delete, respectively. You can use the same key to access all API products associated with the app.",
	//   "flatPath": "v1/organizations/{organizationsId}/appgroups/{appgroupsId}/apps/{appsId}/keys/{keysId}",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.appgroups.apps.keys.updateAppGroupAppKey",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the AppGroup app key. Use the following structure in your request: `organizations/{org}/appgroups/{app_group_name}/apps/{app}/keys/{key}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/appgroups/[^/]+/apps/[^/]+/keys/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1UpdateAppGroupAppKeyRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AppGroupAppKey"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.appgroups.apps.keys.apiproducts.delete":

type OrganizationsAppgroupsAppsKeysApiproductsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Removes an API product from an app's consumer key. After the
// API product is removed, the app cannot access the API resources
// defined in that API product. **Note**: The consumer key is not
// removed, only its association with the API product.
//
//   - name: Parent of the AppGroup app key. Use the following structure
//     in your request:
//     `organizations/{org}/appgroups/{app_group_name}/apps/{app}/keys/{key
//     }/apiproducts/{apiproduct}`.
func (r *OrganizationsAppgroupsAppsKeysApiproductsService) Delete(name string) *OrganizationsAppgroupsAppsKeysApiproductsDeleteCall {
	c := &OrganizationsAppgroupsAppsKeysApiproductsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppgroupsAppsKeysApiproductsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsAppgroupsAppsKeysApiproductsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppgroupsAppsKeysApiproductsDeleteCall) Context(ctx context.Context) *OrganizationsAppgroupsAppsKeysApiproductsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppgroupsAppsKeysApiproductsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppgroupsAppsKeysApiproductsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.appgroups.apps.keys.apiproducts.delete" call.
// Exactly one of *GoogleCloudApigeeV1AppGroupAppKey or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1AppGroupAppKey.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsAppgroupsAppsKeysApiproductsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AppGroupAppKey, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AppGroupAppKey{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Removes an API product from an app's consumer key. After the API product is removed, the app cannot access the API resources defined in that API product. **Note**: The consumer key is not removed, only its association with the API product.",
	//   "flatPath": "v1/organizations/{organizationsId}/appgroups/{appgroupsId}/apps/{appsId}/keys/{keysId}/apiproducts/{apiproductsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.appgroups.apps.keys.apiproducts.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Parent of the AppGroup app key. Use the following structure in your request: `organizations/{org}/appgroups/{app_group_name}/apps/{app}/keys/{key}/apiproducts/{apiproduct}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/appgroups/[^/]+/apps/[^/]+/keys/[^/]+/apiproducts/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AppGroupAppKey"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.appgroups.apps.keys.apiproducts.updateAppGroupAppKeyApiProduct":

type OrganizationsAppgroupsAppsKeysApiproductsUpdateAppGroupAppKeyApiProductCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// UpdateAppGroupAppKeyApiProduct: Approves or revokes the consumer key
// for an API product. After a consumer key is approved, the app can use
// it to access APIs. A consumer key that is revoked or pending cannot
// be used to access an API. Any access tokens associated with a revoked
// consumer key will remain active. However, Apigee checks the status of
// the consumer key and if set to `revoked` will not allow access to the
// API.
//
//   - name: Name of the API product in the developer app key in the
//     following format:
//     `organizations/{org}/appgroups/{app_group_name}/apps/{app}/keys/{key
//     }/apiproducts/{apiproduct}`.
func (r *OrganizationsAppgroupsAppsKeysApiproductsService) UpdateAppGroupAppKeyApiProduct(name string) *OrganizationsAppgroupsAppsKeysApiproductsUpdateAppGroupAppKeyApiProductCall {
	c := &OrganizationsAppgroupsAppsKeysApiproductsUpdateAppGroupAppKeyApiProductCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Action sets the optional parameter "action": Approve or revoke the
// consumer key by setting this value to `approve` or `revoke`
// respectively. The `Content-Type` header, if set, must be set to
// `application/octet-stream`, with empty body.
func (c *OrganizationsAppgroupsAppsKeysApiproductsUpdateAppGroupAppKeyApiProductCall) Action(action string) *OrganizationsAppgroupsAppsKeysApiproductsUpdateAppGroupAppKeyApiProductCall {
	c.urlParams_.Set("action", action)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppgroupsAppsKeysApiproductsUpdateAppGroupAppKeyApiProductCall) Fields(s ...googleapi.Field) *OrganizationsAppgroupsAppsKeysApiproductsUpdateAppGroupAppKeyApiProductCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppgroupsAppsKeysApiproductsUpdateAppGroupAppKeyApiProductCall) Context(ctx context.Context) *OrganizationsAppgroupsAppsKeysApiproductsUpdateAppGroupAppKeyApiProductCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppgroupsAppsKeysApiproductsUpdateAppGroupAppKeyApiProductCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppgroupsAppsKeysApiproductsUpdateAppGroupAppKeyApiProductCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.appgroups.apps.keys.apiproducts.updateAppGroupAppKeyApiProduct" call.
// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsAppgroupsAppsKeysApiproductsUpdateAppGroupAppKeyApiProductCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleProtobufEmpty{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Approves or revokes the consumer key for an API product. After a consumer key is approved, the app can use it to access APIs. A consumer key that is revoked or pending cannot be used to access an API. Any access tokens associated with a revoked consumer key will remain active. However, Apigee checks the status of the consumer key and if set to `revoked` will not allow access to the API.",
	//   "flatPath": "v1/organizations/{organizationsId}/appgroups/{appgroupsId}/apps/{appsId}/keys/{keysId}/apiproducts/{apiproductsId}",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.appgroups.apps.keys.apiproducts.updateAppGroupAppKeyApiProduct",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "action": {
	//       "description": "Approve or revoke the consumer key by setting this value to `approve` or `revoke` respectively. The `Content-Type` header, if set, must be set to `application/octet-stream`, with empty body.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "Required. Name of the API product in the developer app key in the following format: `organizations/{org}/appgroups/{app_group_name}/apps/{app}/keys/{key}/apiproducts/{apiproduct}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/appgroups/[^/]+/apps/[^/]+/keys/[^/]+/apiproducts/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleProtobufEmpty"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apps.get":

type OrganizationsAppsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets the app profile for the specified app ID.
//
//   - name: App ID in the following format:
//     `organizations/{org}/apps/{app}`.
func (r *OrganizationsAppsService) Get(name string) *OrganizationsAppsGetCall {
	c := &OrganizationsAppsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppsGetCall) Fields(s ...googleapi.Field) *OrganizationsAppsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsAppsGetCall) IfNoneMatch(entityTag string) *OrganizationsAppsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppsGetCall) Context(ctx context.Context) *OrganizationsAppsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apps.get" call.
// Exactly one of *GoogleCloudApigeeV1App or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1App.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsAppsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1App, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1App{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the app profile for the specified app ID.",
	//   "flatPath": "v1/organizations/{organizationsId}/apps/{appsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.apps.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. App ID in the following format: `organizations/{org}/apps/{app}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/apps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1App"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.apps.list":

type OrganizationsAppsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists IDs of apps within an organization that have the
// specified app status (approved or revoked) or are of the specified
// app type (developer or company).
//
//   - parent: Resource path of the parent in the following format:
//     `organizations/{org}`.
func (r *OrganizationsAppsService) List(parent string) *OrganizationsAppsListCall {
	c := &OrganizationsAppsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// ApiProduct sets the optional parameter "apiProduct": API product.
func (c *OrganizationsAppsListCall) ApiProduct(apiProduct string) *OrganizationsAppsListCall {
	c.urlParams_.Set("apiProduct", apiProduct)
	return c
}

// Apptype sets the optional parameter "apptype": 'apptype' is no longer
// available. Use a 'filter' instead.
func (c *OrganizationsAppsListCall) Apptype(apptype string) *OrganizationsAppsListCall {
	c.urlParams_.Set("apptype", apptype)
	return c
}

// Expand sets the optional parameter "expand": Flag that specifies
// whether to return an expanded list of apps for the organization.
// Defaults to `false`.
func (c *OrganizationsAppsListCall) Expand(expand bool) *OrganizationsAppsListCall {
	c.urlParams_.Set("expand", fmt.Sprint(expand))
	return c
}

// Filter sets the optional parameter "filter": The filter expression to
// be used to get the list of apps, where filtering can be done on
// developerEmail, apiProduct, consumerKey, status, appId, appName,
// appType and appGroup. Examples: "developerEmail=foo@bar.com",
// "appType=AppGroup", or "appType=Developer" "filter" is supported from
// ver 1.10.0 and above.
func (c *OrganizationsAppsListCall) Filter(filter string) *OrganizationsAppsListCall {
	c.urlParams_.Set("filter", filter)
	return c
}

// Ids sets the optional parameter "ids": Comma-separated list of app
// IDs on which to filter.
func (c *OrganizationsAppsListCall) Ids(ids string) *OrganizationsAppsListCall {
	c.urlParams_.Set("ids", ids)
	return c
}

// IncludeCred sets the optional parameter "includeCred": Flag that
// specifies whether to include credentials in the response.
func (c *OrganizationsAppsListCall) IncludeCred(includeCred bool) *OrganizationsAppsListCall {
	c.urlParams_.Set("includeCred", fmt.Sprint(includeCred))
	return c
}

// KeyStatus sets the optional parameter "keyStatus": Key status of the
// app. Valid values include `approved` or `revoked`. Defaults to
// `approved`.
func (c *OrganizationsAppsListCall) KeyStatus(keyStatus string) *OrganizationsAppsListCall {
	c.urlParams_.Set("keyStatus", keyStatus)
	return c
}

// PageSize sets the optional parameter "pageSize": Count of apps a
// single page can have in the response. If unspecified, at most 100
// apps will be returned. The maximum value is 100; values above 100
// will be coerced to 100. "page_size" is supported from ver 1.10.0 and
// above.
func (c *OrganizationsAppsListCall) PageSize(pageSize int64) *OrganizationsAppsListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": The starting index
// record for listing the developers. "page_token" is supported from ver
// 1.10.0 and above.
func (c *OrganizationsAppsListCall) PageToken(pageToken string) *OrganizationsAppsListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Rows sets the optional parameter "rows": Maximum number of app IDs to
// return. Defaults to 10000.
func (c *OrganizationsAppsListCall) Rows(rows int64) *OrganizationsAppsListCall {
	c.urlParams_.Set("rows", fmt.Sprint(rows))
	return c
}

// StartKey sets the optional parameter "startKey": Returns the list of
// apps starting from the specified app ID.
func (c *OrganizationsAppsListCall) StartKey(startKey string) *OrganizationsAppsListCall {
	c.urlParams_.Set("startKey", startKey)
	return c
}

// Status sets the optional parameter "status": Filter by the status of
// the app. Valid values are `approved` or `revoked`. Defaults to
// `approved`.
func (c *OrganizationsAppsListCall) Status(status string) *OrganizationsAppsListCall {
	c.urlParams_.Set("status", status)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsAppsListCall) Fields(s ...googleapi.Field) *OrganizationsAppsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsAppsListCall) IfNoneMatch(entityTag string) *OrganizationsAppsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsAppsListCall) Context(ctx context.Context) *OrganizationsAppsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsAppsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsAppsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/apps")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.apps.list" call.
// Exactly one of *GoogleCloudApigeeV1ListAppsResponse or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1ListAppsResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsAppsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListAppsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListAppsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists IDs of apps within an organization that have the specified app status (approved or revoked) or are of the specified app type (developer or company).",
	//   "flatPath": "v1/organizations/{organizationsId}/apps",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.apps.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "apiProduct": {
	//       "description": "API product.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "apptype": {
	//       "description": "Optional. 'apptype' is no longer available. Use a 'filter' instead.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "expand": {
	//       "description": "Optional. Flag that specifies whether to return an expanded list of apps for the organization. Defaults to `false`.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "filter": {
	//       "description": "Optional. The filter expression to be used to get the list of apps, where filtering can be done on developerEmail, apiProduct, consumerKey, status, appId, appName, appType and appGroup. Examples: \"developerEmail=foo@bar.com\", \"appType=AppGroup\", or \"appType=Developer\" \"filter\" is supported from ver 1.10.0 and above.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "ids": {
	//       "description": "Optional. Comma-separated list of app IDs on which to filter.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "includeCred": {
	//       "description": "Optional. Flag that specifies whether to include credentials in the response.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "keyStatus": {
	//       "description": "Optional. Key status of the app. Valid values include `approved` or `revoked`. Defaults to `approved`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "pageSize": {
	//       "description": "Optional. Count of apps a single page can have in the response. If unspecified, at most 100 apps will be returned. The maximum value is 100; values above 100 will be coerced to 100. \"page_size\" is supported from ver 1.10.0 and above.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Optional. The starting index record for listing the developers. \"page_token\" is supported from ver 1.10.0 and above.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Resource path of the parent in the following format: `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "rows": {
	//       "description": "Optional. Maximum number of app IDs to return. Defaults to 10000.",
	//       "format": "int64",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "startKey": {
	//       "description": "Returns the list of apps starting from the specified app ID.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "status": {
	//       "description": "Optional. Filter by the status of the app. Valid values are `approved` or `revoked`. Defaults to `approved`.",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/apps",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListAppsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsAppsListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListAppsResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.datacollectors.create":

type OrganizationsDatacollectorsCreateCall struct {
	s                                *Service
	parent                           string
	googlecloudapigeev1datacollector *GoogleCloudApigeeV1DataCollector
	urlParams_                       gensupport.URLParams
	ctx_                             context.Context
	header_                          http.Header
}

// Create: Creates a new data collector.
//
//   - parent: Name of the organization in which to create the data
//     collector in the following format: `organizations/{org}`.
func (r *OrganizationsDatacollectorsService) Create(parent string, googlecloudapigeev1datacollector *GoogleCloudApigeeV1DataCollector) *OrganizationsDatacollectorsCreateCall {
	c := &OrganizationsDatacollectorsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1datacollector = googlecloudapigeev1datacollector
	return c
}

// DataCollectorId sets the optional parameter "dataCollectorId": ID of
// the data collector. Overrides any ID in the data collector resource.
// Must be a string beginning with `dc_` that contains only letters,
// numbers, and underscores.
func (c *OrganizationsDatacollectorsCreateCall) DataCollectorId(dataCollectorId string) *OrganizationsDatacollectorsCreateCall {
	c.urlParams_.Set("dataCollectorId", dataCollectorId)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDatacollectorsCreateCall) Fields(s ...googleapi.Field) *OrganizationsDatacollectorsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDatacollectorsCreateCall) Context(ctx context.Context) *OrganizationsDatacollectorsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDatacollectorsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDatacollectorsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1datacollector)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/datacollectors")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.datacollectors.create" call.
// Exactly one of *GoogleCloudApigeeV1DataCollector or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DataCollector.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDatacollectorsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DataCollector, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DataCollector{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a new data collector.",
	//   "flatPath": "v1/organizations/{organizationsId}/datacollectors",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.datacollectors.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "dataCollectorId": {
	//       "description": "ID of the data collector. Overrides any ID in the data collector resource. Must be a string beginning with `dc_` that contains only letters, numbers, and underscores.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the organization in which to create the data collector in the following format: `organizations/{org}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/datacollectors",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1DataCollector"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DataCollector"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.datacollectors.delete":

type OrganizationsDatacollectorsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a data collector.
//
//   - name: Name of the data collector in the following format:
//     `organizations/{org}/datacollectors/{data_collector_id}`.
func (r *OrganizationsDatacollectorsService) Delete(name string) *OrganizationsDatacollectorsDeleteCall {
	c := &OrganizationsDatacollectorsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDatacollectorsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsDatacollectorsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDatacollectorsDeleteCall) Context(ctx context.Context) *OrganizationsDatacollectorsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDatacollectorsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDatacollectorsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.datacollectors.delete" call.
// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDatacollectorsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleProtobufEmpty{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a data collector.",
	//   "flatPath": "v1/organizations/{organizationsId}/datacollectors/{datacollectorsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.datacollectors.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the data collector in the following format: `organizations/{org}/datacollectors/{data_collector_id}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/datacollectors/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleProtobufEmpty"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.datacollectors.get":

type OrganizationsDatacollectorsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets a data collector.
//
//   - name: Name of the data collector in the following format:
//     `organizations/{org}/datacollectors/{data_collector_id}`.
func (r *OrganizationsDatacollectorsService) Get(name string) *OrganizationsDatacollectorsGetCall {
	c := &OrganizationsDatacollectorsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDatacollectorsGetCall) Fields(s ...googleapi.Field) *OrganizationsDatacollectorsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsDatacollectorsGetCall) IfNoneMatch(entityTag string) *OrganizationsDatacollectorsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDatacollectorsGetCall) Context(ctx context.Context) *OrganizationsDatacollectorsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDatacollectorsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDatacollectorsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.datacollectors.get" call.
// Exactly one of *GoogleCloudApigeeV1DataCollector or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DataCollector.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDatacollectorsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DataCollector, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DataCollector{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets a data collector.",
	//   "flatPath": "v1/organizations/{organizationsId}/datacollectors/{datacollectorsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.datacollectors.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the data collector in the following format: `organizations/{org}/datacollectors/{data_collector_id}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/datacollectors/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DataCollector"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.datacollectors.list":

type OrganizationsDatacollectorsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all data collectors.
//
//   - parent: Name of the organization for which to list data collectors
//     in the following format: `organizations/{org}`.
func (r *OrganizationsDatacollectorsService) List(parent string) *OrganizationsDatacollectorsListCall {
	c := &OrganizationsDatacollectorsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// PageSize sets the optional parameter "pageSize": Maximum number of
// data collectors to return. The page size defaults to 25.
func (c *OrganizationsDatacollectorsListCall) PageSize(pageSize int64) *OrganizationsDatacollectorsListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": Page token,
// returned from a previous ListDataCollectors call, that you can use to
// retrieve the next page.
func (c *OrganizationsDatacollectorsListCall) PageToken(pageToken string) *OrganizationsDatacollectorsListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDatacollectorsListCall) Fields(s ...googleapi.Field) *OrganizationsDatacollectorsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsDatacollectorsListCall) IfNoneMatch(entityTag string) *OrganizationsDatacollectorsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDatacollectorsListCall) Context(ctx context.Context) *OrganizationsDatacollectorsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDatacollectorsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDatacollectorsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/datacollectors")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.datacollectors.list" call.
// Exactly one of *GoogleCloudApigeeV1ListDataCollectorsResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListDataCollectorsResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDatacollectorsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListDataCollectorsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListDataCollectorsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all data collectors.",
	//   "flatPath": "v1/organizations/{organizationsId}/datacollectors",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.datacollectors.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "pageSize": {
	//       "description": "Maximum number of data collectors to return. The page size defaults to 25.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Page token, returned from a previous ListDataCollectors call, that you can use to retrieve the next page.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the organization for which to list data collectors in the following format: `organizations/{org}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/datacollectors",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListDataCollectorsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsDatacollectorsListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListDataCollectorsResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.datacollectors.patch":

type OrganizationsDatacollectorsPatchCall struct {
	s                                *Service
	name                             string
	googlecloudapigeev1datacollector *GoogleCloudApigeeV1DataCollector
	urlParams_                       gensupport.URLParams
	ctx_                             context.Context
	header_                          http.Header
}

// Patch: Updates a data collector.
//
//   - name: Name of the data collector in the following format:
//     `organizations/{org}/datacollectors/{data_collector_id}`.
func (r *OrganizationsDatacollectorsService) Patch(name string, googlecloudapigeev1datacollector *GoogleCloudApigeeV1DataCollector) *OrganizationsDatacollectorsPatchCall {
	c := &OrganizationsDatacollectorsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1datacollector = googlecloudapigeev1datacollector
	return c
}

// UpdateMask sets the optional parameter "updateMask": List of fields
// to be updated.
func (c *OrganizationsDatacollectorsPatchCall) UpdateMask(updateMask string) *OrganizationsDatacollectorsPatchCall {
	c.urlParams_.Set("updateMask", updateMask)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDatacollectorsPatchCall) Fields(s ...googleapi.Field) *OrganizationsDatacollectorsPatchCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDatacollectorsPatchCall) Context(ctx context.Context) *OrganizationsDatacollectorsPatchCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDatacollectorsPatchCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDatacollectorsPatchCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1datacollector)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PATCH", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.datacollectors.patch" call.
// Exactly one of *GoogleCloudApigeeV1DataCollector or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DataCollector.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDatacollectorsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DataCollector, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DataCollector{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates a data collector.",
	//   "flatPath": "v1/organizations/{organizationsId}/datacollectors/{datacollectorsId}",
	//   "httpMethod": "PATCH",
	//   "id": "apigee.organizations.datacollectors.patch",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the data collector in the following format: `organizations/{org}/datacollectors/{data_collector_id}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/datacollectors/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "updateMask": {
	//       "description": "List of fields to be updated.",
	//       "format": "google-fieldmask",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1DataCollector"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DataCollector"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.deployments.list":

type OrganizationsDeploymentsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all deployments of API proxies or shared flows.
//
//   - parent: Name of the organization for which to return deployment
//     information in the following format: `organizations/{org}`.
func (r *OrganizationsDeploymentsService) List(parent string) *OrganizationsDeploymentsListCall {
	c := &OrganizationsDeploymentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// SharedFlows sets the optional parameter "sharedFlows": Flag that
// specifies whether to return shared flow or API proxy deployments. Set
// to `true` to return shared flow deployments; set to `false` to return
// API proxy deployments. Defaults to `false`.
func (c *OrganizationsDeploymentsListCall) SharedFlows(sharedFlows bool) *OrganizationsDeploymentsListCall {
	c.urlParams_.Set("sharedFlows", fmt.Sprint(sharedFlows))
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDeploymentsListCall) Fields(s ...googleapi.Field) *OrganizationsDeploymentsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsDeploymentsListCall) IfNoneMatch(entityTag string) *OrganizationsDeploymentsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDeploymentsListCall) Context(ctx context.Context) *OrganizationsDeploymentsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDeploymentsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDeploymentsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/deployments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.deployments.list" call.
// Exactly one of *GoogleCloudApigeeV1ListDeploymentsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListDeploymentsResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDeploymentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListDeploymentsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListDeploymentsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all deployments of API proxies or shared flows.",
	//   "flatPath": "v1/organizations/{organizationsId}/deployments",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.deployments.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the organization for which to return deployment information in the following format: `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "sharedFlows": {
	//       "description": "Optional. Flag that specifies whether to return shared flow or API proxy deployments. Set to `true` to return shared flow deployments; set to `false` to return API proxy deployments. Defaults to `false`.",
	//       "location": "query",
	//       "type": "boolean"
	//     }
	//   },
	//   "path": "v1/{+parent}/deployments",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListDeploymentsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.attributes":

type OrganizationsDevelopersAttributesCall struct {
	s                             *Service
	parent                        string
	googlecloudapigeev1attributes *GoogleCloudApigeeV1Attributes
	urlParams_                    gensupport.URLParams
	ctx_                          context.Context
	header_                       http.Header
}

// Attributes: Updates developer attributes. This API replaces the
// existing attributes with those specified in the request. Add new
// attributes, and include or exclude any existing attributes that you
// want to retain or remove, respectively. The custom attribute limit is
// 18. **Note**: OAuth access tokens and Key Management Service (KMS)
// entities (apps, developers, and API products) are cached for 180
// seconds (default). Any custom attributes associated with these
// entities are cached for at least 180 seconds after the entity is
// accessed at runtime. Therefore, an `ExpiresIn` element on the OAuthV2
// policy won't be able to expire an access token in less than 180
// seconds.
//
//   - parent: Email address of the developer for which attributes are
//     being updated. Use the following structure in your request:
//     `organizations/{org}/developers/{developer_email}`.
func (r *OrganizationsDevelopersService) Attributes(parent string, googlecloudapigeev1attributes *GoogleCloudApigeeV1Attributes) *OrganizationsDevelopersAttributesCall {
	c := &OrganizationsDevelopersAttributesCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1attributes = googlecloudapigeev1attributes
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAttributesCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAttributesCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAttributesCall) Context(ctx context.Context) *OrganizationsDevelopersAttributesCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAttributesCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAttributesCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1attributes)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/attributes")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.attributes" call.
// Exactly one of *GoogleCloudApigeeV1Attributes or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Attributes.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersAttributesCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Attributes, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Attributes{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates developer attributes. This API replaces the existing attributes with those specified in the request. Add new attributes, and include or exclude any existing attributes that you want to retain or remove, respectively. The custom attribute limit is 18. **Note**: OAuth access tokens and Key Management Service (KMS) entities (apps, developers, and API products) are cached for 180 seconds (default). Any custom attributes associated with these entities are cached for at least 180 seconds after the entity is accessed at runtime. Therefore, an `ExpiresIn` element on the OAuthV2 policy won't be able to expire an access token in less than 180 seconds.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/attributes",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.developers.attributes",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Email address of the developer for which attributes are being updated. Use the following structure in your request: `organizations/{org}/developers/{developer_email}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/attributes",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Attributes"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Attributes"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.create":

type OrganizationsDevelopersCreateCall struct {
	s                            *Service
	parent                       string
	googlecloudapigeev1developer *GoogleCloudApigeeV1Developer
	urlParams_                   gensupport.URLParams
	ctx_                         context.Context
	header_                      http.Header
}

// Create: Creates a developer. Once created, the developer can register
// an app and obtain an API key. At creation time, a developer is set as
// `active`. To change the developer status, use the SetDeveloperStatus
// API.
//
//   - parent: Name of the Apigee organization in which the developer is
//     created. Use the following structure in your request:
//     `organizations/{org}`.
func (r *OrganizationsDevelopersService) Create(parent string, googlecloudapigeev1developer *GoogleCloudApigeeV1Developer) *OrganizationsDevelopersCreateCall {
	c := &OrganizationsDevelopersCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1developer = googlecloudapigeev1developer
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersCreateCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersCreateCall) Context(ctx context.Context) *OrganizationsDevelopersCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1developer)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/developers")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.create" call.
// Exactly one of *GoogleCloudApigeeV1Developer or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Developer.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Developer, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Developer{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a developer. Once created, the developer can register an app and obtain an API key. At creation time, a developer is set as `active`. To change the developer status, use the SetDeveloperStatus API.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.developers.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the Apigee organization in which the developer is created. Use the following structure in your request: `organizations/{org}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/developers",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Developer"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Developer"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.delete":

type OrganizationsDevelopersDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a developer. All apps and API keys associated with
// the developer are also removed. **Warning**: This API will
// permanently delete the developer and related artifacts. To avoid
// permanently deleting developers and their artifacts, set the
// developer status to `inactive` using the SetDeveloperStatus API.
// **Note**: The delete operation is asynchronous. The developer app is
// deleted immediately, but its associated resources, such as apps and
// API keys, may take anywhere from a few seconds to a few minutes to be
// deleted.
//
//   - name: Email address of the developer. Use the following structure
//     in your request: `organizations/{org}/developers/{developer_email}`.
func (r *OrganizationsDevelopersService) Delete(name string) *OrganizationsDevelopersDeleteCall {
	c := &OrganizationsDevelopersDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersDeleteCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersDeleteCall) Context(ctx context.Context) *OrganizationsDevelopersDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.delete" call.
// Exactly one of *GoogleCloudApigeeV1Developer or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Developer.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Developer, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Developer{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a developer. All apps and API keys associated with the developer are also removed. **Warning**: This API will permanently delete the developer and related artifacts. To avoid permanently deleting developers and their artifacts, set the developer status to `inactive` using the SetDeveloperStatus API. **Note**: The delete operation is asynchronous. The developer app is deleted immediately, but its associated resources, such as apps and API keys, may take anywhere from a few seconds to a few minutes to be deleted.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.developers.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Email address of the developer. Use the following structure in your request: `organizations/{org}/developers/{developer_email}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Developer"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.get":

type OrganizationsDevelopersGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Returns the developer details, including the developer's name,
// email address, apps, and other information. **Note**: The response
// includes only the first 100 developer apps.
//
//   - name: Email address of the developer. Use the following structure
//     in your request: `organizations/{org}/developers/{developer_email}`.
func (r *OrganizationsDevelopersService) Get(name string) *OrganizationsDevelopersGetCall {
	c := &OrganizationsDevelopersGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Action sets the optional parameter "action": Status of the developer.
// Valid values are `active` or `inactive`.
func (c *OrganizationsDevelopersGetCall) Action(action string) *OrganizationsDevelopersGetCall {
	c.urlParams_.Set("action", action)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersGetCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsDevelopersGetCall) IfNoneMatch(entityTag string) *OrganizationsDevelopersGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersGetCall) Context(ctx context.Context) *OrganizationsDevelopersGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.get" call.
// Exactly one of *GoogleCloudApigeeV1Developer or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Developer.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Developer, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Developer{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Returns the developer details, including the developer's name, email address, apps, and other information. **Note**: The response includes only the first 100 developer apps.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.developers.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "action": {
	//       "description": "Status of the developer. Valid values are `active` or `inactive`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "Required. Email address of the developer. Use the following structure in your request: `organizations/{org}/developers/{developer_email}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Developer"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.getBalance":

type OrganizationsDevelopersGetBalanceCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetBalance: Gets the account balance for the developer.
//
//   - name: Account balance for the developer. Use the following
//     structure in your request:
//     `organizations/{org}/developers/{developer}/balance`.
func (r *OrganizationsDevelopersService) GetBalance(name string) *OrganizationsDevelopersGetBalanceCall {
	c := &OrganizationsDevelopersGetBalanceCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersGetBalanceCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersGetBalanceCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsDevelopersGetBalanceCall) IfNoneMatch(entityTag string) *OrganizationsDevelopersGetBalanceCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersGetBalanceCall) Context(ctx context.Context) *OrganizationsDevelopersGetBalanceCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersGetBalanceCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersGetBalanceCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.getBalance" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperBalance or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DeveloperBalance.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersGetBalanceCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperBalance, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperBalance{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the account balance for the developer.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/balance",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.developers.getBalance",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Account balance for the developer. Use the following structure in your request: `organizations/{org}/developers/{developer}/balance`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/balance$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperBalance"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.getMonetizationConfig":

type OrganizationsDevelopersGetMonetizationConfigCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetMonetizationConfig: Gets the monetization configuration for the
// developer.
//
//   - name: Monetization configuration for the developer. Use the
//     following structure in your request:
//     `organizations/{org}/developers/{developer}/monetizationConfig`.
func (r *OrganizationsDevelopersService) GetMonetizationConfig(name string) *OrganizationsDevelopersGetMonetizationConfigCall {
	c := &OrganizationsDevelopersGetMonetizationConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersGetMonetizationConfigCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersGetMonetizationConfigCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsDevelopersGetMonetizationConfigCall) IfNoneMatch(entityTag string) *OrganizationsDevelopersGetMonetizationConfigCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersGetMonetizationConfigCall) Context(ctx context.Context) *OrganizationsDevelopersGetMonetizationConfigCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersGetMonetizationConfigCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersGetMonetizationConfigCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.getMonetizationConfig" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperMonetizationConfig or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1DeveloperMonetizationConfig.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersGetMonetizationConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperMonetizationConfig, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperMonetizationConfig{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the monetization configuration for the developer.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/monetizationConfig",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.developers.getMonetizationConfig",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Monetization configuration for the developer. Use the following structure in your request: `organizations/{org}/developers/{developer}/monetizationConfig`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/monetizationConfig$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperMonetizationConfig"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.list":

type OrganizationsDevelopersListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all developers in an organization by email address. By
// default, the response does not include company developers. Set the
// `includeCompany` query parameter to `true` to include company
// developers. **Note**: A maximum of 1000 developers are returned in
// the response. You paginate the list of developers returned using the
// `startKey` and `count` query parameters.
//
//   - parent: Name of the Apigee organization. Use the following
//     structure in your request: `organizations/{org}`.
func (r *OrganizationsDevelopersService) List(parent string) *OrganizationsDevelopersListCall {
	c := &OrganizationsDevelopersListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// App sets the optional parameter "app": List only Developers that are
// associated with the app. Note that start_key, count are not
// applicable for this filter criteria.
func (c *OrganizationsDevelopersListCall) App(app string) *OrganizationsDevelopersListCall {
	c.urlParams_.Set("app", app)
	return c
}

// Count sets the optional parameter "count": Number of developers to
// return in the API call. Use with the `startKey` parameter to provide
// more targeted filtering. The limit is 1000.
func (c *OrganizationsDevelopersListCall) Count(count int64) *OrganizationsDevelopersListCall {
	c.urlParams_.Set("count", fmt.Sprint(count))
	return c
}

// Expand sets the optional parameter "expand": Specifies whether to
// expand the results. Set to `true` to expand the results. This query
// parameter is not valid if you use the `count` or `startKey` query
// parameters.
func (c *OrganizationsDevelopersListCall) Expand(expand bool) *OrganizationsDevelopersListCall {
	c.urlParams_.Set("expand", fmt.Sprint(expand))
	return c
}

// Ids sets the optional parameter "ids": List of IDs to include,
// separated by commas.
func (c *OrganizationsDevelopersListCall) Ids(ids string) *OrganizationsDevelopersListCall {
	c.urlParams_.Set("ids", ids)
	return c
}

// IncludeCompany sets the optional parameter "includeCompany": Flag
// that specifies whether to include company details in the response.
func (c *OrganizationsDevelopersListCall) IncludeCompany(includeCompany bool) *OrganizationsDevelopersListCall {
	c.urlParams_.Set("includeCompany", fmt.Sprint(includeCompany))
	return c
}

// StartKey sets the optional parameter "startKey": **Note**: Must be
// used in conjunction with the `count` parameter. Email address of the
// developer from which to start displaying the list of developers. For
// example, if the an unfiltered list returns: ``` westley@example.com
// fezzik@example.com buttercup@example.com ``` and your `startKey` is
// `fezzik@example.com`, the list returned will be ```
// fezzik@example.com buttercup@example.com ```
func (c *OrganizationsDevelopersListCall) StartKey(startKey string) *OrganizationsDevelopersListCall {
	c.urlParams_.Set("startKey", startKey)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersListCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsDevelopersListCall) IfNoneMatch(entityTag string) *OrganizationsDevelopersListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersListCall) Context(ctx context.Context) *OrganizationsDevelopersListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/developers")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.list" call.
// Exactly one of *GoogleCloudApigeeV1ListOfDevelopersResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListOfDevelopersResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListOfDevelopersResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListOfDevelopersResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all developers in an organization by email address. By default, the response does not include company developers. Set the `includeCompany` query parameter to `true` to include company developers. **Note**: A maximum of 1000 developers are returned in the response. You paginate the list of developers returned using the `startKey` and `count` query parameters.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.developers.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "app": {
	//       "description": "Optional. List only Developers that are associated with the app. Note that start_key, count are not applicable for this filter criteria.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "count": {
	//       "description": "Optional. Number of developers to return in the API call. Use with the `startKey` parameter to provide more targeted filtering. The limit is 1000.",
	//       "format": "int64",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "expand": {
	//       "description": "Specifies whether to expand the results. Set to `true` to expand the results. This query parameter is not valid if you use the `count` or `startKey` query parameters.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "ids": {
	//       "description": "Optional. List of IDs to include, separated by commas.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "includeCompany": {
	//       "description": "Flag that specifies whether to include company details in the response.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the Apigee organization. Use the following structure in your request: `organizations/{org}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "startKey": {
	//       "description": "**Note**: Must be used in conjunction with the `count` parameter. Email address of the developer from which to start displaying the list of developers. For example, if the an unfiltered list returns: ``` westley@example.com fezzik@example.com buttercup@example.com ``` and your `startKey` is `fezzik@example.com`, the list returned will be ``` fezzik@example.com buttercup@example.com ```",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/developers",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListOfDevelopersResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.setDeveloperStatus":

type OrganizationsDevelopersSetDeveloperStatusCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// SetDeveloperStatus: Sets the status of a developer. A developer is
// `active` by default. If you set a developer's status to `inactive`,
// the API keys assigned to the developer apps are no longer valid even
// though the API keys are set to `approved`. Inactive developers can
// still sign in to the developer portal and create apps; however, any
// new API keys generated during app creation won't work. To set the
// status of a developer, set the `action` query parameter to `active`
// or `inactive`, and the `Content-Type` header to
// `application/octet-stream`. If successful, the API call returns the
// following HTTP status code: `204 No Content`
//
//   - name: Name of the developer. Use the following structure in your
//     request: `organizations/{org}/developers/{developer_id}`.
func (r *OrganizationsDevelopersService) SetDeveloperStatus(name string) *OrganizationsDevelopersSetDeveloperStatusCall {
	c := &OrganizationsDevelopersSetDeveloperStatusCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Action sets the optional parameter "action": Status of the developer.
// Valid values are `active` and `inactive`.
func (c *OrganizationsDevelopersSetDeveloperStatusCall) Action(action string) *OrganizationsDevelopersSetDeveloperStatusCall {
	c.urlParams_.Set("action", action)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersSetDeveloperStatusCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersSetDeveloperStatusCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersSetDeveloperStatusCall) Context(ctx context.Context) *OrganizationsDevelopersSetDeveloperStatusCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersSetDeveloperStatusCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersSetDeveloperStatusCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.setDeveloperStatus" call.
// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersSetDeveloperStatusCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleProtobufEmpty{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Sets the status of a developer. A developer is `active` by default. If you set a developer's status to `inactive`, the API keys assigned to the developer apps are no longer valid even though the API keys are set to `approved`. Inactive developers can still sign in to the developer portal and create apps; however, any new API keys generated during app creation won't work. To set the status of a developer, set the `action` query parameter to `active` or `inactive`, and the `Content-Type` header to `application/octet-stream`. If successful, the API call returns the following HTTP status code: `204 No Content`",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.developers.setDeveloperStatus",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "action": {
	//       "description": "Status of the developer. Valid values are `active` and `inactive`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "Required. Name of the developer. Use the following structure in your request: `organizations/{org}/developers/{developer_id}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleProtobufEmpty"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.update":

type OrganizationsDevelopersUpdateCall struct {
	s                            *Service
	name                         string
	googlecloudapigeev1developer *GoogleCloudApigeeV1Developer
	urlParams_                   gensupport.URLParams
	ctx_                         context.Context
	header_                      http.Header
}

// Update: Updates a developer. This API replaces the existing developer
// details with those specified in the request. Include or exclude any
// existing details that you want to retain or delete, respectively. The
// custom attribute limit is 18. **Note**: OAuth access tokens and Key
// Management Service (KMS) entities (apps, developers, and API
// products) are cached for 180 seconds (current default). Any custom
// attributes associated with these entities are cached for at least 180
// seconds after the entity is accessed at runtime. Therefore, an
// `ExpiresIn` element on the OAuthV2 policy won't be able to expire an
// access token in less than 180 seconds.
//
//   - name: Email address of the developer. Use the following structure
//     in your request: `organizations/{org}/developers/{developer_email}`.
func (r *OrganizationsDevelopersService) Update(name string, googlecloudapigeev1developer *GoogleCloudApigeeV1Developer) *OrganizationsDevelopersUpdateCall {
	c := &OrganizationsDevelopersUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1developer = googlecloudapigeev1developer
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersUpdateCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersUpdateCall) Context(ctx context.Context) *OrganizationsDevelopersUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1developer)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.update" call.
// Exactly one of *GoogleCloudApigeeV1Developer or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Developer.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Developer, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Developer{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates a developer. This API replaces the existing developer details with those specified in the request. Include or exclude any existing details that you want to retain or delete, respectively. The custom attribute limit is 18. **Note**: OAuth access tokens and Key Management Service (KMS) entities (apps, developers, and API products) are cached for 180 seconds (current default). Any custom attributes associated with these entities are cached for at least 180 seconds after the entity is accessed at runtime. Therefore, an `ExpiresIn` element on the OAuthV2 policy won't be able to expire an access token in less than 180 seconds.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.developers.update",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Email address of the developer. Use the following structure in your request: `organizations/{org}/developers/{developer_email}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Developer"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Developer"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.updateMonetizationConfig":

type OrganizationsDevelopersUpdateMonetizationConfigCall struct {
	s                                              *Service
	name                                           string
	googlecloudapigeev1developermonetizationconfig *GoogleCloudApigeeV1DeveloperMonetizationConfig
	urlParams_                                     gensupport.URLParams
	ctx_                                           context.Context
	header_                                        http.Header
}

// UpdateMonetizationConfig: Updates the monetization configuration for
// the developer.
//
//   - name: Monetization configuration for the developer. Use the
//     following structure in your request:
//     `organizations/{org}/developers/{developer}/monetizationConfig`.
func (r *OrganizationsDevelopersService) UpdateMonetizationConfig(name string, googlecloudapigeev1developermonetizationconfig *GoogleCloudApigeeV1DeveloperMonetizationConfig) *OrganizationsDevelopersUpdateMonetizationConfigCall {
	c := &OrganizationsDevelopersUpdateMonetizationConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1developermonetizationconfig = googlecloudapigeev1developermonetizationconfig
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersUpdateMonetizationConfigCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersUpdateMonetizationConfigCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersUpdateMonetizationConfigCall) Context(ctx context.Context) *OrganizationsDevelopersUpdateMonetizationConfigCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersUpdateMonetizationConfigCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersUpdateMonetizationConfigCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1developermonetizationconfig)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.updateMonetizationConfig" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperMonetizationConfig or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1DeveloperMonetizationConfig.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersUpdateMonetizationConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperMonetizationConfig, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperMonetizationConfig{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates the monetization configuration for the developer.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/monetizationConfig",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.developers.updateMonetizationConfig",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Monetization configuration for the developer. Use the following structure in your request: `organizations/{org}/developers/{developer}/monetizationConfig`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/monetizationConfig$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperMonetizationConfig"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperMonetizationConfig"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.attributes":

type OrganizationsDevelopersAppsAttributesCall struct {
	s                             *Service
	name                          string
	googlecloudapigeev1attributes *GoogleCloudApigeeV1Attributes
	urlParams_                    gensupport.URLParams
	ctx_                          context.Context
	header_                       http.Header
}

// Attributes: Updates attributes for a developer app. This API replaces
// the current attributes with those specified in the request.
//
//   - name: Name of the developer app. Use the following structure in
//     your request:
//     `organizations/{org}/developers/{developer_email}/apps/{app}`.
func (r *OrganizationsDevelopersAppsService) Attributes(name string, googlecloudapigeev1attributes *GoogleCloudApigeeV1Attributes) *OrganizationsDevelopersAppsAttributesCall {
	c := &OrganizationsDevelopersAppsAttributesCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1attributes = googlecloudapigeev1attributes
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsAttributesCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsAttributesCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsAttributesCall) Context(ctx context.Context) *OrganizationsDevelopersAppsAttributesCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsAttributesCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsAttributesCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1attributes)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/attributes")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.attributes" call.
// Exactly one of *GoogleCloudApigeeV1Attributes or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Attributes.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersAppsAttributesCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Attributes, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Attributes{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates attributes for a developer app. This API replaces the current attributes with those specified in the request.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps/{appsId}/attributes",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.developers.apps.attributes",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the developer app. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/apps/{app}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/apps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}/attributes",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Attributes"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Attributes"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.create":

type OrganizationsDevelopersAppsCreateCall struct {
	s                               *Service
	parent                          string
	googlecloudapigeev1developerapp *GoogleCloudApigeeV1DeveloperApp
	urlParams_                      gensupport.URLParams
	ctx_                            context.Context
	header_                         http.Header
}

// Create: Creates an app associated with a developer. This API
// associates the developer app with the specified API product and
// auto-generates an API key for the app to use in calls to API proxies
// inside that API product. The `name` is the unique ID of the app that
// you can use in API calls. The `DisplayName` (set as an attribute)
// appears in the UI. If you don't set the `DisplayName` attribute, the
// `name` appears in the UI.
//
//   - parent: Name of the developer. Use the following structure in your
//     request: `organizations/{org}/developers/{developer_email}`.
func (r *OrganizationsDevelopersAppsService) Create(parent string, googlecloudapigeev1developerapp *GoogleCloudApigeeV1DeveloperApp) *OrganizationsDevelopersAppsCreateCall {
	c := &OrganizationsDevelopersAppsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1developerapp = googlecloudapigeev1developerapp
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsCreateCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsCreateCall) Context(ctx context.Context) *OrganizationsDevelopersAppsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1developerapp)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/apps")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.create" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperApp or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DeveloperApp.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersAppsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperApp, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperApp{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates an app associated with a developer. This API associates the developer app with the specified API product and auto-generates an API key for the app to use in calls to API proxies inside that API product. The `name` is the unique ID of the app that you can use in API calls. The `DisplayName` (set as an attribute) appears in the UI. If you don't set the `DisplayName` attribute, the `name` appears in the UI.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.developers.apps.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the developer. Use the following structure in your request: `organizations/{org}/developers/{developer_email}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/apps",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperApp"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperApp"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.delete":

type OrganizationsDevelopersAppsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a developer app. **Note**: The delete operation is
// asynchronous. The developer app is deleted immediately, but its
// associated resources, such as app keys or access tokens, may take
// anywhere from a few seconds to a few minutes to be deleted.
//
//   - name: Name of the developer app. Use the following structure in
//     your request:
//     `organizations/{org}/developers/{developer_email}/apps/{app}`.
func (r *OrganizationsDevelopersAppsService) Delete(name string) *OrganizationsDevelopersAppsDeleteCall {
	c := &OrganizationsDevelopersAppsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsDeleteCall) Context(ctx context.Context) *OrganizationsDevelopersAppsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.delete" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperApp or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DeveloperApp.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersAppsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperApp, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperApp{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a developer app. **Note**: The delete operation is asynchronous. The developer app is deleted immediately, but its associated resources, such as app keys or access tokens, may take anywhere from a few seconds to a few minutes to be deleted.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps/{appsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.developers.apps.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the developer app. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/apps/{app}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/apps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperApp"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.generateKeyPairOrUpdateDeveloperAppStatus":

type OrganizationsDevelopersAppsGenerateKeyPairOrUpdateDeveloperAppStatusCall struct {
	s                               *Service
	name                            string
	googlecloudapigeev1developerapp *GoogleCloudApigeeV1DeveloperApp
	urlParams_                      gensupport.URLParams
	ctx_                            context.Context
	header_                         http.Header
}

// GenerateKeyPairOrUpdateDeveloperAppStatus: Manages access to a
// developer app by enabling you to: * Approve or revoke a developer app
// * Generate a new consumer key and secret for a developer app To
// approve or revoke a developer app, set the `action` query parameter
// to `approve` or `revoke`, respectively, and the `Content-Type` header
// to `application/octet-stream`. If a developer app is revoked, none of
// its API keys are valid for API calls even though the keys are still
// approved. If successful, the API call returns the following HTTP
// status code: `204 No Content` To generate a new consumer key and
// secret for a developer app, pass the new key/secret details. Rather
// than replace an existing key, this API generates a new key. In this
// case, multiple key pairs may be associated with a single developer
// app. Each key pair has an independent status (`approve` or `revoke`)
// and expiration time. Any approved, non-expired key can be used in an
// API call. For example, if you're using API key rotation, you can
// generate new keys with expiration times that overlap keys that are
// going to expire. You might also generate a new consumer key/secret if
// the security of the original key/secret is compromised. The
// `keyExpiresIn` property defines the expiration time for the API key
// in milliseconds. If you don't set this property or set it to `-1`,
// the API key never expires. **Notes**: * When generating a new
// key/secret, this API replaces the existing attributes, notes, and
// callback URLs with those specified in the request. Include or exclude
// any existing information that you want to retain or delete,
// respectively. * To migrate existing consumer keys and secrets to
// hybrid from another system, see the CreateDeveloperAppKey API.
//
//   - name: Name of the developer app. Use the following structure in
//     your request:
//     `organizations/{org}/developers/{developer_email}/apps/{app}`.
func (r *OrganizationsDevelopersAppsService) GenerateKeyPairOrUpdateDeveloperAppStatus(name string, googlecloudapigeev1developerapp *GoogleCloudApigeeV1DeveloperApp) *OrganizationsDevelopersAppsGenerateKeyPairOrUpdateDeveloperAppStatusCall {
	c := &OrganizationsDevelopersAppsGenerateKeyPairOrUpdateDeveloperAppStatusCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1developerapp = googlecloudapigeev1developerapp
	return c
}

// Action sets the optional parameter "action": Action. Valid values are
// `approve` or `revoke`.
func (c *OrganizationsDevelopersAppsGenerateKeyPairOrUpdateDeveloperAppStatusCall) Action(action string) *OrganizationsDevelopersAppsGenerateKeyPairOrUpdateDeveloperAppStatusCall {
	c.urlParams_.Set("action", action)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsGenerateKeyPairOrUpdateDeveloperAppStatusCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsGenerateKeyPairOrUpdateDeveloperAppStatusCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsGenerateKeyPairOrUpdateDeveloperAppStatusCall) Context(ctx context.Context) *OrganizationsDevelopersAppsGenerateKeyPairOrUpdateDeveloperAppStatusCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsGenerateKeyPairOrUpdateDeveloperAppStatusCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsGenerateKeyPairOrUpdateDeveloperAppStatusCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1developerapp)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.generateKeyPairOrUpdateDeveloperAppStatus" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperApp or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DeveloperApp.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersAppsGenerateKeyPairOrUpdateDeveloperAppStatusCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperApp, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperApp{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Manages access to a developer app by enabling you to: * Approve or revoke a developer app * Generate a new consumer key and secret for a developer app To approve or revoke a developer app, set the `action` query parameter to `approve` or `revoke`, respectively, and the `Content-Type` header to `application/octet-stream`. If a developer app is revoked, none of its API keys are valid for API calls even though the keys are still approved. If successful, the API call returns the following HTTP status code: `204 No Content` To generate a new consumer key and secret for a developer app, pass the new key/secret details. Rather than replace an existing key, this API generates a new key. In this case, multiple key pairs may be associated with a single developer app. Each key pair has an independent status (`approve` or `revoke`) and expiration time. Any approved, non-expired key can be used in an API call. For example, if you're using API key rotation, you can generate new keys with expiration times that overlap keys that are going to expire. You might also generate a new consumer key/secret if the security of the original key/secret is compromised. The `keyExpiresIn` property defines the expiration time for the API key in milliseconds. If you don't set this property or set it to `-1`, the API key never expires. **Notes**: * When generating a new key/secret, this API replaces the existing attributes, notes, and callback URLs with those specified in the request. Include or exclude any existing information that you want to retain or delete, respectively. * To migrate existing consumer keys and secrets to hybrid from another system, see the CreateDeveloperAppKey API.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps/{appsId}",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.developers.apps.generateKeyPairOrUpdateDeveloperAppStatus",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "action": {
	//       "description": "Action. Valid values are `approve` or `revoke`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "Required. Name of the developer app. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/apps/{app}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/apps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperApp"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperApp"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.get":

type OrganizationsDevelopersAppsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Returns the details for a developer app.
//
//   - name: Name of the developer app. Use the following structure in
//     your request:
//     `organizations/{org}/developers/{developer_email}/apps/{app}`.
func (r *OrganizationsDevelopersAppsService) Get(name string) *OrganizationsDevelopersAppsGetCall {
	c := &OrganizationsDevelopersAppsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Entity sets the optional parameter "entity": **Note**: Must be used
// in conjunction with the `query` parameter. Set to `apiresources` to
// return the number of API resources that have been approved for access
// by a developer app in the specified Apigee organization.
func (c *OrganizationsDevelopersAppsGetCall) Entity(entity string) *OrganizationsDevelopersAppsGetCall {
	c.urlParams_.Set("entity", entity)
	return c
}

// Query sets the optional parameter "query": **Note**: Must be used in
// conjunction with the `entity` parameter. Set to `count` to return the
// number of API resources that have been approved for access by a
// developer app in the specified Apigee organization.
func (c *OrganizationsDevelopersAppsGetCall) Query(query string) *OrganizationsDevelopersAppsGetCall {
	c.urlParams_.Set("query", query)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsGetCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsDevelopersAppsGetCall) IfNoneMatch(entityTag string) *OrganizationsDevelopersAppsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsGetCall) Context(ctx context.Context) *OrganizationsDevelopersAppsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.get" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperApp or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DeveloperApp.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersAppsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperApp, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperApp{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Returns the details for a developer app.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps/{appsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.developers.apps.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "entity": {
	//       "description": "**Note**: Must be used in conjunction with the `query` parameter. Set to `apiresources` to return the number of API resources that have been approved for access by a developer app in the specified Apigee organization.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "Required. Name of the developer app. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/apps/{app}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/apps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "query": {
	//       "description": "**Note**: Must be used in conjunction with the `entity` parameter. Set to `count` to return the number of API resources that have been approved for access by a developer app in the specified Apigee organization.",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperApp"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.list":

type OrganizationsDevelopersAppsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all apps created by a developer in an Apigee
// organization. Optionally, you can request an expanded view of the
// developer apps. A maximum of 100 developer apps are returned per API
// call. You can paginate the list of deveoper apps returned using the
// `startKey` and `count` query parameters.
//
//   - parent: Name of the developer. Use the following structure in your
//     request: `organizations/{org}/developers/{developer_email}`.
func (r *OrganizationsDevelopersAppsService) List(parent string) *OrganizationsDevelopersAppsListCall {
	c := &OrganizationsDevelopersAppsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Count sets the optional parameter "count": Number of developer apps
// to return in the API call. Use with the `startKey` parameter to
// provide more targeted filtering. The limit is 1000.
func (c *OrganizationsDevelopersAppsListCall) Count(count int64) *OrganizationsDevelopersAppsListCall {
	c.urlParams_.Set("count", fmt.Sprint(count))
	return c
}

// Expand sets the optional parameter "expand": Specifies whether to
// expand the results. Set to `true` to expand the results. This query
// parameter is not valid if you use the `count` or `startKey` query
// parameters.
func (c *OrganizationsDevelopersAppsListCall) Expand(expand bool) *OrganizationsDevelopersAppsListCall {
	c.urlParams_.Set("expand", fmt.Sprint(expand))
	return c
}

// ShallowExpand sets the optional parameter "shallowExpand": Specifies
// whether to expand the results in shallow mode. Set to `true` to
// expand the results in shallow mode.
func (c *OrganizationsDevelopersAppsListCall) ShallowExpand(shallowExpand bool) *OrganizationsDevelopersAppsListCall {
	c.urlParams_.Set("shallowExpand", fmt.Sprint(shallowExpand))
	return c
}

// StartKey sets the optional parameter "startKey": **Note**: Must be
// used in conjunction with the `count` parameter. Name of the developer
// app from which to start displaying the list of developer apps. For
// example, if you're returning 50 developer apps at a time (using the
// `count` query parameter), you can view developer apps 50-99 by
// entering the name of the 50th developer app. The developer app name
// is case sensitive.
func (c *OrganizationsDevelopersAppsListCall) StartKey(startKey string) *OrganizationsDevelopersAppsListCall {
	c.urlParams_.Set("startKey", startKey)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsListCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsDevelopersAppsListCall) IfNoneMatch(entityTag string) *OrganizationsDevelopersAppsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsListCall) Context(ctx context.Context) *OrganizationsDevelopersAppsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/apps")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.list" call.
// Exactly one of *GoogleCloudApigeeV1ListDeveloperAppsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListDeveloperAppsResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersAppsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListDeveloperAppsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListDeveloperAppsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all apps created by a developer in an Apigee organization. Optionally, you can request an expanded view of the developer apps. A maximum of 100 developer apps are returned per API call. You can paginate the list of deveoper apps returned using the `startKey` and `count` query parameters.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.developers.apps.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "count": {
	//       "description": "Number of developer apps to return in the API call. Use with the `startKey` parameter to provide more targeted filtering. The limit is 1000.",
	//       "format": "int64",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "expand": {
	//       "description": "Optional. Specifies whether to expand the results. Set to `true` to expand the results. This query parameter is not valid if you use the `count` or `startKey` query parameters.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the developer. Use the following structure in your request: `organizations/{org}/developers/{developer_email}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "shallowExpand": {
	//       "description": "Optional. Specifies whether to expand the results in shallow mode. Set to `true` to expand the results in shallow mode.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "startKey": {
	//       "description": "**Note**: Must be used in conjunction with the `count` parameter. Name of the developer app from which to start displaying the list of developer apps. For example, if you're returning 50 developer apps at a time (using the `count` query parameter), you can view developer apps 50-99 by entering the name of the 50th developer app. The developer app name is case sensitive.",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/apps",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListDeveloperAppsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.update":

type OrganizationsDevelopersAppsUpdateCall struct {
	s                               *Service
	name                            string
	googlecloudapigeev1developerapp *GoogleCloudApigeeV1DeveloperApp
	urlParams_                      gensupport.URLParams
	ctx_                            context.Context
	header_                         http.Header
}

// Update: Updates the details for a developer app. In addition, you can
// add an API product to a developer app and automatically generate an
// API key for the app to use when calling APIs in the API product. If
// you want to use an existing API key for the API product, add the API
// product to the API key using the UpdateDeveloperAppKey API. Using
// this API, you cannot update the following: * App name as it is the
// primary key used to identify the app and cannot be changed. * Scopes
// associated with the app. Instead, use the ReplaceDeveloperAppKey API.
// This API replaces the existing attributes with those specified in the
// request. Include or exclude any existing attributes that you want to
// retain or delete, respectively.
//
//   - name: Name of the developer app. Use the following structure in
//     your request:
//     `organizations/{org}/developers/{developer_email}/apps/{app}`.
func (r *OrganizationsDevelopersAppsService) Update(name string, googlecloudapigeev1developerapp *GoogleCloudApigeeV1DeveloperApp) *OrganizationsDevelopersAppsUpdateCall {
	c := &OrganizationsDevelopersAppsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1developerapp = googlecloudapigeev1developerapp
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsUpdateCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsUpdateCall) Context(ctx context.Context) *OrganizationsDevelopersAppsUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1developerapp)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.update" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperApp or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DeveloperApp.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersAppsUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperApp, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperApp{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates the details for a developer app. In addition, you can add an API product to a developer app and automatically generate an API key for the app to use when calling APIs in the API product. If you want to use an existing API key for the API product, add the API product to the API key using the UpdateDeveloperAppKey API. Using this API, you cannot update the following: * App name as it is the primary key used to identify the app and cannot be changed. * Scopes associated with the app. Instead, use the ReplaceDeveloperAppKey API. This API replaces the existing attributes with those specified in the request. Include or exclude any existing attributes that you want to retain or delete, respectively.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps/{appsId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.developers.apps.update",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the developer app. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/apps/{app}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/apps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperApp"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperApp"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.attributes.delete":

type OrganizationsDevelopersAppsAttributesDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a developer app attribute.
//
//   - name: Name of the developer app attribute. Use the following
//     structure in your request:
//     `organizations/{org}/developers/{developer_email}/apps/{app}/attribu
//     tes/{attribute}`.
func (r *OrganizationsDevelopersAppsAttributesService) Delete(name string) *OrganizationsDevelopersAppsAttributesDeleteCall {
	c := &OrganizationsDevelopersAppsAttributesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsAttributesDeleteCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsAttributesDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsAttributesDeleteCall) Context(ctx context.Context) *OrganizationsDevelopersAppsAttributesDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsAttributesDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsAttributesDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.attributes.delete" call.
// Exactly one of *GoogleCloudApigeeV1Attribute or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Attribute.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersAppsAttributesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Attribute, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Attribute{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a developer app attribute.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps/{appsId}/attributes/{attributesId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.developers.apps.attributes.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the developer app attribute. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/apps/{app}/attributes/{attribute}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/apps/[^/]+/attributes/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Attribute"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.attributes.get":

type OrganizationsDevelopersAppsAttributesGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Returns a developer app attribute.
//
//   - name: Name of the developer app attribute. Use the following
//     structure in your request:
//     `organizations/{org}/developers/{developer_email}/apps/{app}/attribu
//     tes/{attribute}`.
func (r *OrganizationsDevelopersAppsAttributesService) Get(name string) *OrganizationsDevelopersAppsAttributesGetCall {
	c := &OrganizationsDevelopersAppsAttributesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsAttributesGetCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsAttributesGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsDevelopersAppsAttributesGetCall) IfNoneMatch(entityTag string) *OrganizationsDevelopersAppsAttributesGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsAttributesGetCall) Context(ctx context.Context) *OrganizationsDevelopersAppsAttributesGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsAttributesGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsAttributesGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.attributes.get" call.
// Exactly one of *GoogleCloudApigeeV1Attribute or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Attribute.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersAppsAttributesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Attribute, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Attribute{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Returns a developer app attribute.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps/{appsId}/attributes/{attributesId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.developers.apps.attributes.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the developer app attribute. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/apps/{app}/attributes/{attribute}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/apps/[^/]+/attributes/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Attribute"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.attributes.list":

type OrganizationsDevelopersAppsAttributesListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Returns a list of all developer app attributes.
//
//   - parent: Name of the developer app. Use the following structure in
//     your request:
//     `organizations/{org}/developers/{developer_email}/apps/{app}`.
func (r *OrganizationsDevelopersAppsAttributesService) List(parent string) *OrganizationsDevelopersAppsAttributesListCall {
	c := &OrganizationsDevelopersAppsAttributesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsAttributesListCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsAttributesListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsDevelopersAppsAttributesListCall) IfNoneMatch(entityTag string) *OrganizationsDevelopersAppsAttributesListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsAttributesListCall) Context(ctx context.Context) *OrganizationsDevelopersAppsAttributesListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsAttributesListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsAttributesListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/attributes")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.attributes.list" call.
// Exactly one of *GoogleCloudApigeeV1Attributes or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Attributes.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersAppsAttributesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Attributes, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Attributes{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Returns a list of all developer app attributes.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps/{appsId}/attributes",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.developers.apps.attributes.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the developer app. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/apps/{app}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/apps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/attributes",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Attributes"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.attributes.updateDeveloperAppAttribute":

type OrganizationsDevelopersAppsAttributesUpdateDeveloperAppAttributeCall struct {
	s                            *Service
	name                         string
	googlecloudapigeev1attribute *GoogleCloudApigeeV1Attribute
	urlParams_                   gensupport.URLParams
	ctx_                         context.Context
	header_                      http.Header
}

// UpdateDeveloperAppAttribute: Updates a developer app attribute.
// **Note**: OAuth access tokens and Key Management Service (KMS)
// entities (apps, developers, and API products) are cached for 180
// seconds (current default). Any custom attributes associated with
// these entities are cached for at least 180 seconds after the entity
// is accessed at runtime. Therefore, an `ExpiresIn` element on the
// OAuthV2 policy won't be able to expire an access token in less than
// 180 seconds.
//
//   - name: Name of the developer app attribute. Use the following
//     structure in your request:
//     `organizations/{org}/developers/{developer_email}/apps/{app}/attribu
//     tes/{attribute}`.
func (r *OrganizationsDevelopersAppsAttributesService) UpdateDeveloperAppAttribute(name string, googlecloudapigeev1attribute *GoogleCloudApigeeV1Attribute) *OrganizationsDevelopersAppsAttributesUpdateDeveloperAppAttributeCall {
	c := &OrganizationsDevelopersAppsAttributesUpdateDeveloperAppAttributeCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1attribute = googlecloudapigeev1attribute
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsAttributesUpdateDeveloperAppAttributeCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsAttributesUpdateDeveloperAppAttributeCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsAttributesUpdateDeveloperAppAttributeCall) Context(ctx context.Context) *OrganizationsDevelopersAppsAttributesUpdateDeveloperAppAttributeCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsAttributesUpdateDeveloperAppAttributeCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsAttributesUpdateDeveloperAppAttributeCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1attribute)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.attributes.updateDeveloperAppAttribute" call.
// Exactly one of *GoogleCloudApigeeV1Attribute or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Attribute.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersAppsAttributesUpdateDeveloperAppAttributeCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Attribute, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Attribute{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates a developer app attribute. **Note**: OAuth access tokens and Key Management Service (KMS) entities (apps, developers, and API products) are cached for 180 seconds (current default). Any custom attributes associated with these entities are cached for at least 180 seconds after the entity is accessed at runtime. Therefore, an `ExpiresIn` element on the OAuthV2 policy won't be able to expire an access token in less than 180 seconds.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps/{appsId}/attributes/{attributesId}",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.developers.apps.attributes.updateDeveloperAppAttribute",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the developer app attribute. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/apps/{app}/attributes/{attribute}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/apps/[^/]+/attributes/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Attribute"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Attribute"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.keys.create":

type OrganizationsDevelopersAppsKeysCreateCall struct {
	s                                  *Service
	parent                             string
	googlecloudapigeev1developerappkey *GoogleCloudApigeeV1DeveloperAppKey
	urlParams_                         gensupport.URLParams
	ctx_                               context.Context
	header_                            http.Header
}

// Create: Creates a custom consumer key and secret for a developer app.
// This is particularly useful if you want to migrate existing consumer
// keys and secrets to Apigee from another system. Consumer keys and
// secrets can contain letters, numbers, underscores, and hyphens. No
// other special characters are allowed. To avoid service disruptions, a
// consumer key and secret should not exceed 2 KBs each. **Note**: When
// creating the consumer key and secret, an association to API products
// will not be made. Therefore, you should not specify the associated
// API products in your request. Instead, use the UpdateDeveloperAppKey
// API to make the association after the consumer key and secret are
// created. If a consumer key and secret already exist, you can keep
// them or delete them using the DeleteDeveloperAppKey API. **Note**:
// All keys start out with status=approved, even if status=revoked is
// passed when the key is created. To revoke a key, use the
// UpdateDeveloperAppKey API.
//
//   - parent: Parent of the developer app key. Use the following
//     structure in your request:
//     'organizations/{org}/developers/{developerEmail}/apps/{appName}'.
func (r *OrganizationsDevelopersAppsKeysService) Create(parent string, googlecloudapigeev1developerappkey *GoogleCloudApigeeV1DeveloperAppKey) *OrganizationsDevelopersAppsKeysCreateCall {
	c := &OrganizationsDevelopersAppsKeysCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1developerappkey = googlecloudapigeev1developerappkey
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsKeysCreateCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsKeysCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsKeysCreateCall) Context(ctx context.Context) *OrganizationsDevelopersAppsKeysCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsKeysCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsKeysCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1developerappkey)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/keys")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.keys.create" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperAppKey or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DeveloperAppKey.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersAppsKeysCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperAppKey, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperAppKey{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a custom consumer key and secret for a developer app. This is particularly useful if you want to migrate existing consumer keys and secrets to Apigee from another system. Consumer keys and secrets can contain letters, numbers, underscores, and hyphens. No other special characters are allowed. To avoid service disruptions, a consumer key and secret should not exceed 2 KBs each. **Note**: When creating the consumer key and secret, an association to API products will not be made. Therefore, you should not specify the associated API products in your request. Instead, use the UpdateDeveloperAppKey API to make the association after the consumer key and secret are created. If a consumer key and secret already exist, you can keep them or delete them using the DeleteDeveloperAppKey API. **Note**: All keys start out with status=approved, even if status=revoked is passed when the key is created. To revoke a key, use the UpdateDeveloperAppKey API.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps/{appsId}/keys",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.developers.apps.keys.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Parent of the developer app key. Use the following structure in your request: 'organizations/{org}/developers/{developerEmail}/apps/{appName}'",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/apps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/keys",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperAppKey"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperAppKey"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.keys.delete":

type OrganizationsDevelopersAppsKeysDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an app's consumer key and removes all API products
// associated with the app. After the consumer key is deleted, it cannot
// be used to access any APIs. **Note**: After you delete a consumer
// key, you may want to: 1. Create a new consumer key and secret for the
// developer app using the CreateDeveloperAppKey API, and subsequently
// add an API product to the key using the UpdateDeveloperAppKey API. 2.
// Delete the developer app, if it is no longer required.
//
//   - name: Name of the developer app key. Use the following structure in
//     your request:
//     `organizations/{org}/developers/{developer_email}/apps/{app}/keys/{k
//     ey}`.
func (r *OrganizationsDevelopersAppsKeysService) Delete(name string) *OrganizationsDevelopersAppsKeysDeleteCall {
	c := &OrganizationsDevelopersAppsKeysDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsKeysDeleteCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsKeysDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsKeysDeleteCall) Context(ctx context.Context) *OrganizationsDevelopersAppsKeysDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsKeysDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsKeysDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.keys.delete" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperAppKey or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DeveloperAppKey.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersAppsKeysDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperAppKey, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperAppKey{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an app's consumer key and removes all API products associated with the app. After the consumer key is deleted, it cannot be used to access any APIs. **Note**: After you delete a consumer key, you may want to: 1. Create a new consumer key and secret for the developer app using the CreateDeveloperAppKey API, and subsequently add an API product to the key using the UpdateDeveloperAppKey API. 2. Delete the developer app, if it is no longer required.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps/{appsId}/keys/{keysId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.developers.apps.keys.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Name of the developer app key. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/apps/{app}/keys/{key}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/apps/[^/]+/keys/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperAppKey"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.keys.get":

type OrganizationsDevelopersAppsKeysGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets details for a consumer key for a developer app, including
// the key and secret value, associated API products, and other
// information.
//
//   - name: Name of the developer app key. Use the following structure in
//     your request:
//     `organizations/{org}/developers/{developer_email}/apps/{app}/keys/{k
//     ey}`.
func (r *OrganizationsDevelopersAppsKeysService) Get(name string) *OrganizationsDevelopersAppsKeysGetCall {
	c := &OrganizationsDevelopersAppsKeysGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsKeysGetCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsKeysGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsDevelopersAppsKeysGetCall) IfNoneMatch(entityTag string) *OrganizationsDevelopersAppsKeysGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsKeysGetCall) Context(ctx context.Context) *OrganizationsDevelopersAppsKeysGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsKeysGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsKeysGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.keys.get" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperAppKey or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DeveloperAppKey.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersAppsKeysGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperAppKey, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperAppKey{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets details for a consumer key for a developer app, including the key and secret value, associated API products, and other information.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps/{appsId}/keys/{keysId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.developers.apps.keys.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Name of the developer app key. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/apps/{app}/keys/{key}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/apps/[^/]+/keys/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperAppKey"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.keys.replaceDeveloperAppKey":

type OrganizationsDevelopersAppsKeysReplaceDeveloperAppKeyCall struct {
	s                                  *Service
	name                               string
	googlecloudapigeev1developerappkey *GoogleCloudApigeeV1DeveloperAppKey
	urlParams_                         gensupport.URLParams
	ctx_                               context.Context
	header_                            http.Header
}

// ReplaceDeveloperAppKey: Updates the scope of an app. This API
// replaces the existing scopes with those specified in the request.
// Include or exclude any existing scopes that you want to retain or
// delete, respectively. The specified scopes must already be defined
// for the API products associated with the app. This API sets the
// `scopes` element under the `apiProducts` element in the attributes of
// the app.
//
//   - name: Name of the developer app key. Use the following structure in
//     your request:
//     `organizations/{org}/developers/{developer_email}/apps/{app}/keys/{k
//     ey}`.
func (r *OrganizationsDevelopersAppsKeysService) ReplaceDeveloperAppKey(name string, googlecloudapigeev1developerappkey *GoogleCloudApigeeV1DeveloperAppKey) *OrganizationsDevelopersAppsKeysReplaceDeveloperAppKeyCall {
	c := &OrganizationsDevelopersAppsKeysReplaceDeveloperAppKeyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1developerappkey = googlecloudapigeev1developerappkey
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsKeysReplaceDeveloperAppKeyCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsKeysReplaceDeveloperAppKeyCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsKeysReplaceDeveloperAppKeyCall) Context(ctx context.Context) *OrganizationsDevelopersAppsKeysReplaceDeveloperAppKeyCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsKeysReplaceDeveloperAppKeyCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsKeysReplaceDeveloperAppKeyCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1developerappkey)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.keys.replaceDeveloperAppKey" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperAppKey or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DeveloperAppKey.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersAppsKeysReplaceDeveloperAppKeyCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperAppKey, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperAppKey{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates the scope of an app. This API replaces the existing scopes with those specified in the request. Include or exclude any existing scopes that you want to retain or delete, respectively. The specified scopes must already be defined for the API products associated with the app. This API sets the `scopes` element under the `apiProducts` element in the attributes of the app.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps/{appsId}/keys/{keysId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.developers.apps.keys.replaceDeveloperAppKey",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Name of the developer app key. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/apps/{app}/keys/{key}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/apps/[^/]+/keys/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperAppKey"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperAppKey"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.keys.updateDeveloperAppKey":

type OrganizationsDevelopersAppsKeysUpdateDeveloperAppKeyCall struct {
	s                                  *Service
	name                               string
	googlecloudapigeev1developerappkey *GoogleCloudApigeeV1DeveloperAppKey
	urlParams_                         gensupport.URLParams
	ctx_                               context.Context
	header_                            http.Header
}

// UpdateDeveloperAppKey: Adds an API product to a developer app key,
// enabling the app that holds the key to access the API resources
// bundled in the API product. In addition, you can add attributes to a
// developer app key. This API replaces the existing attributes with
// those specified in the request. Include or exclude any existing
// attributes that you want to retain or delete, respectively. You can
// use the same key to access all API products associated with the app.
//
//   - name: Name of the developer app key. Use the following structure in
//     your request:
//     `organizations/{org}/developers/{developer_email}/apps/{app}/keys/{k
//     ey}`.
func (r *OrganizationsDevelopersAppsKeysService) UpdateDeveloperAppKey(name string, googlecloudapigeev1developerappkey *GoogleCloudApigeeV1DeveloperAppKey) *OrganizationsDevelopersAppsKeysUpdateDeveloperAppKeyCall {
	c := &OrganizationsDevelopersAppsKeysUpdateDeveloperAppKeyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1developerappkey = googlecloudapigeev1developerappkey
	return c
}

// Action sets the optional parameter "action": Approve or revoke the
// consumer key by setting this value to `approve` or `revoke`,
// respectively. The `Content-Type` header must be set to
// `application/octet-stream`.
func (c *OrganizationsDevelopersAppsKeysUpdateDeveloperAppKeyCall) Action(action string) *OrganizationsDevelopersAppsKeysUpdateDeveloperAppKeyCall {
	c.urlParams_.Set("action", action)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsKeysUpdateDeveloperAppKeyCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsKeysUpdateDeveloperAppKeyCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsKeysUpdateDeveloperAppKeyCall) Context(ctx context.Context) *OrganizationsDevelopersAppsKeysUpdateDeveloperAppKeyCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsKeysUpdateDeveloperAppKeyCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsKeysUpdateDeveloperAppKeyCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1developerappkey)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.keys.updateDeveloperAppKey" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperAppKey or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DeveloperAppKey.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersAppsKeysUpdateDeveloperAppKeyCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperAppKey, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperAppKey{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Adds an API product to a developer app key, enabling the app that holds the key to access the API resources bundled in the API product. In addition, you can add attributes to a developer app key. This API replaces the existing attributes with those specified in the request. Include or exclude any existing attributes that you want to retain or delete, respectively. You can use the same key to access all API products associated with the app.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps/{appsId}/keys/{keysId}",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.developers.apps.keys.updateDeveloperAppKey",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "action": {
	//       "description": "Approve or revoke the consumer key by setting this value to `approve` or `revoke`, respectively. The `Content-Type` header must be set to `application/octet-stream`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "Name of the developer app key. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/apps/{app}/keys/{key}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/apps/[^/]+/keys/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperAppKey"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperAppKey"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.keys.apiproducts.delete":

type OrganizationsDevelopersAppsKeysApiproductsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Removes an API product from an app's consumer key. After the
// API product is removed, the app cannot access the API resources
// defined in that API product. **Note**: The consumer key is not
// removed, only its association with the API product.
//
//   - name: Name of the API product in the developer app key in the
//     following format:
//     `organizations/{org}/developers/{developer_email}/apps/{app}/keys/{k
//     ey}/apiproducts/{apiproduct}`.
func (r *OrganizationsDevelopersAppsKeysApiproductsService) Delete(name string) *OrganizationsDevelopersAppsKeysApiproductsDeleteCall {
	c := &OrganizationsDevelopersAppsKeysApiproductsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsKeysApiproductsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsKeysApiproductsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsKeysApiproductsDeleteCall) Context(ctx context.Context) *OrganizationsDevelopersAppsKeysApiproductsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsKeysApiproductsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsKeysApiproductsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.keys.apiproducts.delete" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperAppKey or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DeveloperAppKey.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersAppsKeysApiproductsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperAppKey, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperAppKey{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Removes an API product from an app's consumer key. After the API product is removed, the app cannot access the API resources defined in that API product. **Note**: The consumer key is not removed, only its association with the API product.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps/{appsId}/keys/{keysId}/apiproducts/{apiproductsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.developers.apps.keys.apiproducts.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Name of the API product in the developer app key in the following format: `organizations/{org}/developers/{developer_email}/apps/{app}/keys/{key}/apiproducts/{apiproduct}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/apps/[^/]+/keys/[^/]+/apiproducts/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperAppKey"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.keys.apiproducts.updateDeveloperAppKeyApiProduct":

type OrganizationsDevelopersAppsKeysApiproductsUpdateDeveloperAppKeyApiProductCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// UpdateDeveloperAppKeyApiProduct: Approves or revokes the consumer key
// for an API product. After a consumer key is approved, the app can use
// it to access APIs. A consumer key that is revoked or pending cannot
// be used to access an API. Any access tokens associated with a revoked
// consumer key will remain active. However, Apigee checks the status of
// the consumer key and if set to `revoked` will not allow access to the
// API.
//
//   - name: Name of the API product in the developer app key in the
//     following format:
//     `organizations/{org}/developers/{developer_email}/apps/{app}/keys/{k
//     ey}/apiproducts/{apiproduct}`.
func (r *OrganizationsDevelopersAppsKeysApiproductsService) UpdateDeveloperAppKeyApiProduct(name string) *OrganizationsDevelopersAppsKeysApiproductsUpdateDeveloperAppKeyApiProductCall {
	c := &OrganizationsDevelopersAppsKeysApiproductsUpdateDeveloperAppKeyApiProductCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Action sets the optional parameter "action": Approve or revoke the
// consumer key by setting this value to `approve` or `revoke`,
// respectively.
func (c *OrganizationsDevelopersAppsKeysApiproductsUpdateDeveloperAppKeyApiProductCall) Action(action string) *OrganizationsDevelopersAppsKeysApiproductsUpdateDeveloperAppKeyApiProductCall {
	c.urlParams_.Set("action", action)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsKeysApiproductsUpdateDeveloperAppKeyApiProductCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsKeysApiproductsUpdateDeveloperAppKeyApiProductCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsKeysApiproductsUpdateDeveloperAppKeyApiProductCall) Context(ctx context.Context) *OrganizationsDevelopersAppsKeysApiproductsUpdateDeveloperAppKeyApiProductCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsKeysApiproductsUpdateDeveloperAppKeyApiProductCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsKeysApiproductsUpdateDeveloperAppKeyApiProductCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.keys.apiproducts.updateDeveloperAppKeyApiProduct" call.
// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersAppsKeysApiproductsUpdateDeveloperAppKeyApiProductCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleProtobufEmpty{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Approves or revokes the consumer key for an API product. After a consumer key is approved, the app can use it to access APIs. A consumer key that is revoked or pending cannot be used to access an API. Any access tokens associated with a revoked consumer key will remain active. However, Apigee checks the status of the consumer key and if set to `revoked` will not allow access to the API.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps/{appsId}/keys/{keysId}/apiproducts/{apiproductsId}",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.developers.apps.keys.apiproducts.updateDeveloperAppKeyApiProduct",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "action": {
	//       "description": "Approve or revoke the consumer key by setting this value to `approve` or `revoke`, respectively.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "Name of the API product in the developer app key in the following format: `organizations/{org}/developers/{developer_email}/apps/{app}/keys/{key}/apiproducts/{apiproduct}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/apps/[^/]+/keys/[^/]+/apiproducts/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleProtobufEmpty"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.apps.keys.create.create":

type OrganizationsDevelopersAppsKeysCreateCreateCall struct {
	s                                  *Service
	parent                             string
	googlecloudapigeev1developerappkey *GoogleCloudApigeeV1DeveloperAppKey
	urlParams_                         gensupport.URLParams
	ctx_                               context.Context
	header_                            http.Header
}

// Create: Creates a custom consumer key and secret for a developer app.
// This is particularly useful if you want to migrate existing consumer
// keys and secrets to Apigee from another system. Consumer keys and
// secrets can contain letters, numbers, underscores, and hyphens. No
// other special characters are allowed. To avoid service disruptions, a
// consumer key and secret should not exceed 2 KBs each. **Note**: When
// creating the consumer key and secret, an association to API products
// will not be made. Therefore, you should not specify the associated
// API products in your request. Instead, use the UpdateDeveloperAppKey
// API to make the association after the consumer key and secret are
// created. If a consumer key and secret already exist, you can keep
// them or delete them using the DeleteDeveloperAppKey API. **Note**:
// All keys start out with status=approved, even if status=revoked is
// passed when the key is created. To revoke a key, use the
// UpdateDeveloperAppKey API.
//
//   - parent: Parent of the developer app key. Use the following
//     structure in your request:
//     'organizations/{org}/developers/{developerEmail}/apps/{appName}'.
func (r *OrganizationsDevelopersAppsKeysCreateService) Create(parent string, googlecloudapigeev1developerappkey *GoogleCloudApigeeV1DeveloperAppKey) *OrganizationsDevelopersAppsKeysCreateCreateCall {
	c := &OrganizationsDevelopersAppsKeysCreateCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1developerappkey = googlecloudapigeev1developerappkey
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAppsKeysCreateCreateCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAppsKeysCreateCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAppsKeysCreateCreateCall) Context(ctx context.Context) *OrganizationsDevelopersAppsKeysCreateCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAppsKeysCreateCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAppsKeysCreateCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1developerappkey)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/keys/create")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.apps.keys.create.create" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperAppKey or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DeveloperAppKey.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersAppsKeysCreateCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperAppKey, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperAppKey{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a custom consumer key and secret for a developer app. This is particularly useful if you want to migrate existing consumer keys and secrets to Apigee from another system. Consumer keys and secrets can contain letters, numbers, underscores, and hyphens. No other special characters are allowed. To avoid service disruptions, a consumer key and secret should not exceed 2 KBs each. **Note**: When creating the consumer key and secret, an association to API products will not be made. Therefore, you should not specify the associated API products in your request. Instead, use the UpdateDeveloperAppKey API to make the association after the consumer key and secret are created. If a consumer key and secret already exist, you can keep them or delete them using the DeleteDeveloperAppKey API. **Note**: All keys start out with status=approved, even if status=revoked is passed when the key is created. To revoke a key, use the UpdateDeveloperAppKey API.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/apps/{appsId}/keys/create",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.developers.apps.keys.create.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Parent of the developer app key. Use the following structure in your request: 'organizations/{org}/developers/{developerEmail}/apps/{appName}'",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/apps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/keys/create",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperAppKey"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperAppKey"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.attributes.delete":

type OrganizationsDevelopersAttributesDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a developer attribute.
//
//   - name: Name of the developer attribute. Use the following structure
//     in your request:
//     `organizations/{org}/developers/{developer_email}/attributes/{attrib
//     ute}`.
func (r *OrganizationsDevelopersAttributesService) Delete(name string) *OrganizationsDevelopersAttributesDeleteCall {
	c := &OrganizationsDevelopersAttributesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAttributesDeleteCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAttributesDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAttributesDeleteCall) Context(ctx context.Context) *OrganizationsDevelopersAttributesDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAttributesDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAttributesDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.attributes.delete" call.
// Exactly one of *GoogleCloudApigeeV1Attribute or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Attribute.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersAttributesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Attribute, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Attribute{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a developer attribute.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/attributes/{attributesId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.developers.attributes.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the developer attribute. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/attributes/{attribute}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/attributes/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Attribute"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.attributes.get":

type OrganizationsDevelopersAttributesGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Returns the value of the specified developer attribute.
//
//   - name: Name of the developer attribute. Use the following structure
//     in your request:
//     `organizations/{org}/developers/{developer_email}/attributes/{attrib
//     ute}`.
func (r *OrganizationsDevelopersAttributesService) Get(name string) *OrganizationsDevelopersAttributesGetCall {
	c := &OrganizationsDevelopersAttributesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAttributesGetCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAttributesGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsDevelopersAttributesGetCall) IfNoneMatch(entityTag string) *OrganizationsDevelopersAttributesGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAttributesGetCall) Context(ctx context.Context) *OrganizationsDevelopersAttributesGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAttributesGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAttributesGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.attributes.get" call.
// Exactly one of *GoogleCloudApigeeV1Attribute or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Attribute.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersAttributesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Attribute, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Attribute{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Returns the value of the specified developer attribute.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/attributes/{attributesId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.developers.attributes.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the developer attribute. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/attributes/{attribute}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/attributes/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Attribute"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.attributes.list":

type OrganizationsDevelopersAttributesListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Returns a list of all developer attributes.
//
//   - parent: Email address of the developer for which attributes are
//     being listed. Use the following structure in your request:
//     `organizations/{org}/developers/{developer_email}`.
func (r *OrganizationsDevelopersAttributesService) List(parent string) *OrganizationsDevelopersAttributesListCall {
	c := &OrganizationsDevelopersAttributesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAttributesListCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAttributesListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsDevelopersAttributesListCall) IfNoneMatch(entityTag string) *OrganizationsDevelopersAttributesListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAttributesListCall) Context(ctx context.Context) *OrganizationsDevelopersAttributesListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAttributesListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAttributesListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/attributes")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.attributes.list" call.
// Exactly one of *GoogleCloudApigeeV1Attributes or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Attributes.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersAttributesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Attributes, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Attributes{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Returns a list of all developer attributes.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/attributes",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.developers.attributes.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Email address of the developer for which attributes are being listed. Use the following structure in your request: `organizations/{org}/developers/{developer_email}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/attributes",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Attributes"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.attributes.updateDeveloperAttribute":

type OrganizationsDevelopersAttributesUpdateDeveloperAttributeCall struct {
	s                            *Service
	name                         string
	googlecloudapigeev1attribute *GoogleCloudApigeeV1Attribute
	urlParams_                   gensupport.URLParams
	ctx_                         context.Context
	header_                      http.Header
}

// UpdateDeveloperAttribute: Updates a developer attribute. **Note**:
// OAuth access tokens and Key Management Service (KMS) entities (apps,
// developers, and API products) are cached for 180 seconds (default).
// Any custom attributes associated with these entities are cached for
// at least 180 seconds after the entity is accessed at runtime.
// Therefore, an `ExpiresIn` element on the OAuthV2 policy won't be able
// to expire an access token in less than 180 seconds.
//
//   - name: Name of the developer attribute. Use the following structure
//     in your request:
//     `organizations/{org}/developers/{developer_email}/attributes/{attrib
//     ute}`.
func (r *OrganizationsDevelopersAttributesService) UpdateDeveloperAttribute(name string, googlecloudapigeev1attribute *GoogleCloudApigeeV1Attribute) *OrganizationsDevelopersAttributesUpdateDeveloperAttributeCall {
	c := &OrganizationsDevelopersAttributesUpdateDeveloperAttributeCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1attribute = googlecloudapigeev1attribute
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersAttributesUpdateDeveloperAttributeCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersAttributesUpdateDeveloperAttributeCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersAttributesUpdateDeveloperAttributeCall) Context(ctx context.Context) *OrganizationsDevelopersAttributesUpdateDeveloperAttributeCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersAttributesUpdateDeveloperAttributeCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersAttributesUpdateDeveloperAttributeCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1attribute)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.attributes.updateDeveloperAttribute" call.
// Exactly one of *GoogleCloudApigeeV1Attribute or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Attribute.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsDevelopersAttributesUpdateDeveloperAttributeCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Attribute, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Attribute{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates a developer attribute. **Note**: OAuth access tokens and Key Management Service (KMS) entities (apps, developers, and API products) are cached for 180 seconds (default). Any custom attributes associated with these entities are cached for at least 180 seconds after the entity is accessed at runtime. Therefore, an `ExpiresIn` element on the OAuthV2 policy won't be able to expire an access token in less than 180 seconds.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/attributes/{attributesId}",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.developers.attributes.updateDeveloperAttribute",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the developer attribute. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/attributes/{attribute}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/attributes/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Attribute"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Attribute"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.balance.adjust":

type OrganizationsDevelopersBalanceAdjustCall struct {
	s                                                *Service
	name                                             string
	googlecloudapigeev1adjustdeveloperbalancerequest *GoogleCloudApigeeV1AdjustDeveloperBalanceRequest
	urlParams_                                       gensupport.URLParams
	ctx_                                             context.Context
	header_                                          http.Header
}

// Adjust: Adjust the prepaid balance for the developer. This API will
// be used in scenarios where the developer has been under-charged or
// over-charged.
//
//   - name: Account balance for the developer. Use the following
//     structure in your request:
//     `organizations/{org}/developers/{developer}/balance`.
func (r *OrganizationsDevelopersBalanceService) Adjust(name string, googlecloudapigeev1adjustdeveloperbalancerequest *GoogleCloudApigeeV1AdjustDeveloperBalanceRequest) *OrganizationsDevelopersBalanceAdjustCall {
	c := &OrganizationsDevelopersBalanceAdjustCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1adjustdeveloperbalancerequest = googlecloudapigeev1adjustdeveloperbalancerequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersBalanceAdjustCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersBalanceAdjustCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersBalanceAdjustCall) Context(ctx context.Context) *OrganizationsDevelopersBalanceAdjustCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersBalanceAdjustCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersBalanceAdjustCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1adjustdeveloperbalancerequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:adjust")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.balance.adjust" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperBalance or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DeveloperBalance.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersBalanceAdjustCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperBalance, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperBalance{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Adjust the prepaid balance for the developer. This API will be used in scenarios where the developer has been under-charged or over-charged.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/balance:adjust",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.developers.balance.adjust",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Account balance for the developer. Use the following structure in your request: `organizations/{org}/developers/{developer}/balance`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/balance$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}:adjust",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1AdjustDeveloperBalanceRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperBalance"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.balance.credit":

type OrganizationsDevelopersBalanceCreditCall struct {
	s                                                *Service
	name                                             string
	googlecloudapigeev1creditdeveloperbalancerequest *GoogleCloudApigeeV1CreditDeveloperBalanceRequest
	urlParams_                                       gensupport.URLParams
	ctx_                                             context.Context
	header_                                          http.Header
}

// Credit: Credits the account balance for the developer.
//
//   - name: Account balance for the developer. Use the following
//     structure in your request:
//     `organizations/{org}/developers/{developer}/balance`.
func (r *OrganizationsDevelopersBalanceService) Credit(name string, googlecloudapigeev1creditdeveloperbalancerequest *GoogleCloudApigeeV1CreditDeveloperBalanceRequest) *OrganizationsDevelopersBalanceCreditCall {
	c := &OrganizationsDevelopersBalanceCreditCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1creditdeveloperbalancerequest = googlecloudapigeev1creditdeveloperbalancerequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersBalanceCreditCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersBalanceCreditCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersBalanceCreditCall) Context(ctx context.Context) *OrganizationsDevelopersBalanceCreditCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersBalanceCreditCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersBalanceCreditCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1creditdeveloperbalancerequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:credit")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.balance.credit" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperBalance or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DeveloperBalance.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersBalanceCreditCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperBalance, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperBalance{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Credits the account balance for the developer.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/balance:credit",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.developers.balance.credit",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Account balance for the developer. Use the following structure in your request: `organizations/{org}/developers/{developer}/balance`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/balance$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}:credit",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1CreditDeveloperBalanceRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperBalance"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.subscriptions.create":

type OrganizationsDevelopersSubscriptionsCreateCall struct {
	s                                        *Service
	parent                                   string
	googlecloudapigeev1developersubscription *GoogleCloudApigeeV1DeveloperSubscription
	urlParams_                               gensupport.URLParams
	ctx_                                     context.Context
	header_                                  http.Header
}

// Create: Creates a subscription to an API product.
//
//   - parent: Email address of the developer that is purchasing a
//     subscription to the API product. Use the following structure in
//     your request: `organizations/{org}/developers/{developer_email}`.
func (r *OrganizationsDevelopersSubscriptionsService) Create(parent string, googlecloudapigeev1developersubscription *GoogleCloudApigeeV1DeveloperSubscription) *OrganizationsDevelopersSubscriptionsCreateCall {
	c := &OrganizationsDevelopersSubscriptionsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1developersubscription = googlecloudapigeev1developersubscription
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersSubscriptionsCreateCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersSubscriptionsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersSubscriptionsCreateCall) Context(ctx context.Context) *OrganizationsDevelopersSubscriptionsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersSubscriptionsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersSubscriptionsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1developersubscription)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/subscriptions")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.subscriptions.create" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperSubscription or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1DeveloperSubscription.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersSubscriptionsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperSubscription, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperSubscription{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a subscription to an API product. ",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/subscriptions",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.developers.subscriptions.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Email address of the developer that is purchasing a subscription to the API product. Use the following structure in your request: `organizations/{org}/developers/{developer_email}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/subscriptions",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperSubscription"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperSubscription"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.subscriptions.expire":

type OrganizationsDevelopersSubscriptionsExpireCall struct {
	s                                                     *Service
	name                                                  string
	googlecloudapigeev1expiredevelopersubscriptionrequest *GoogleCloudApigeeV1ExpireDeveloperSubscriptionRequest
	urlParams_                                            gensupport.URLParams
	ctx_                                                  context.Context
	header_                                               http.Header
}

// Expire: Expires an API product subscription immediately.
//
//   - name: Name of the API product subscription. Use the following
//     structure in your request:
//     `organizations/{org}/developers/{developer_email}/subscriptions/{sub
//     scription}`.
func (r *OrganizationsDevelopersSubscriptionsService) Expire(name string, googlecloudapigeev1expiredevelopersubscriptionrequest *GoogleCloudApigeeV1ExpireDeveloperSubscriptionRequest) *OrganizationsDevelopersSubscriptionsExpireCall {
	c := &OrganizationsDevelopersSubscriptionsExpireCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1expiredevelopersubscriptionrequest = googlecloudapigeev1expiredevelopersubscriptionrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersSubscriptionsExpireCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersSubscriptionsExpireCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersSubscriptionsExpireCall) Context(ctx context.Context) *OrganizationsDevelopersSubscriptionsExpireCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersSubscriptionsExpireCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersSubscriptionsExpireCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1expiredevelopersubscriptionrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:expire")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.subscriptions.expire" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperSubscription or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1DeveloperSubscription.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersSubscriptionsExpireCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperSubscription, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperSubscription{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Expires an API product subscription immediately.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/subscriptions/{subscriptionsId}:expire",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.developers.subscriptions.expire",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the API product subscription. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/subscriptions/{subscription}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/subscriptions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}:expire",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1ExpireDeveloperSubscriptionRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperSubscription"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.subscriptions.get":

type OrganizationsDevelopersSubscriptionsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets details for an API product subscription.
//
//   - name: Name of the API product subscription. Use the following
//     structure in your request:
//     `organizations/{org}/developers/{developer_email}/subscriptions/{sub
//     scription}`.
func (r *OrganizationsDevelopersSubscriptionsService) Get(name string) *OrganizationsDevelopersSubscriptionsGetCall {
	c := &OrganizationsDevelopersSubscriptionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersSubscriptionsGetCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersSubscriptionsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsDevelopersSubscriptionsGetCall) IfNoneMatch(entityTag string) *OrganizationsDevelopersSubscriptionsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersSubscriptionsGetCall) Context(ctx context.Context) *OrganizationsDevelopersSubscriptionsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersSubscriptionsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersSubscriptionsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.subscriptions.get" call.
// Exactly one of *GoogleCloudApigeeV1DeveloperSubscription or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1DeveloperSubscription.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersSubscriptionsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeveloperSubscription, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeveloperSubscription{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets details for an API product subscription.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/subscriptions/{subscriptionsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.developers.subscriptions.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the API product subscription. Use the following structure in your request: `organizations/{org}/developers/{developer_email}/subscriptions/{subscription}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+/subscriptions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeveloperSubscription"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.developers.subscriptions.list":

type OrganizationsDevelopersSubscriptionsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all API product subscriptions for a developer.
//
//   - parent: Email address of the developer. Use the following structure
//     in your request: `organizations/{org}/developers/{developer_email}`.
func (r *OrganizationsDevelopersSubscriptionsService) List(parent string) *OrganizationsDevelopersSubscriptionsListCall {
	c := &OrganizationsDevelopersSubscriptionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Count sets the optional parameter "count": Number of API product
// subscriptions to return in the API call. Use with `startKey` to
// provide more targeted filtering. Defaults to 100. The maximum limit
// is 1000.
func (c *OrganizationsDevelopersSubscriptionsListCall) Count(count int64) *OrganizationsDevelopersSubscriptionsListCall {
	c.urlParams_.Set("count", fmt.Sprint(count))
	return c
}

// StartKey sets the optional parameter "startKey": Name of the API
// product subscription from which to start displaying the list of
// subscriptions. If omitted, the list starts from the first item. For
// example, to view the API product subscriptions from 51-150, set the
// value of `startKey` to the name of the 51st subscription and set the
// value of `count` to 100.
func (c *OrganizationsDevelopersSubscriptionsListCall) StartKey(startKey string) *OrganizationsDevelopersSubscriptionsListCall {
	c.urlParams_.Set("startKey", startKey)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsDevelopersSubscriptionsListCall) Fields(s ...googleapi.Field) *OrganizationsDevelopersSubscriptionsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsDevelopersSubscriptionsListCall) IfNoneMatch(entityTag string) *OrganizationsDevelopersSubscriptionsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsDevelopersSubscriptionsListCall) Context(ctx context.Context) *OrganizationsDevelopersSubscriptionsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsDevelopersSubscriptionsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsDevelopersSubscriptionsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/subscriptions")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.developers.subscriptions.list" call.
// Exactly one of *GoogleCloudApigeeV1ListDeveloperSubscriptionsResponse
// or error will be non-nil. Any non-2xx status code is an error.
// Response headers are in either
// *GoogleCloudApigeeV1ListDeveloperSubscriptionsResponse.ServerResponse.
// Header or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsDevelopersSubscriptionsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListDeveloperSubscriptionsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListDeveloperSubscriptionsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all API product subscriptions for a developer.",
	//   "flatPath": "v1/organizations/{organizationsId}/developers/{developersId}/subscriptions",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.developers.subscriptions.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "count": {
	//       "description": "Number of API product subscriptions to return in the API call. Use with `startKey` to provide more targeted filtering. Defaults to 100. The maximum limit is 1000.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "parent": {
	//       "description": "Required. Email address of the developer. Use the following structure in your request: `organizations/{org}/developers/{developer_email}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/developers/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "startKey": {
	//       "description": "Name of the API product subscription from which to start displaying the list of subscriptions. If omitted, the list starts from the first item. For example, to view the API product subscriptions from 51-150, set the value of `startKey` to the name of the 51st subscription and set the value of `count` to 100.",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/subscriptions",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListDeveloperSubscriptionsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.endpointAttachments.create":

type OrganizationsEndpointAttachmentsCreateCall struct {
	s                                     *Service
	parent                                string
	googlecloudapigeev1endpointattachment *GoogleCloudApigeeV1EndpointAttachment
	urlParams_                            gensupport.URLParams
	ctx_                                  context.Context
	header_                               http.Header
}

// Create: Creates an endpoint attachment. **Note:** Not supported for
// Apigee hybrid.
//
// - parent: Organization the endpoint attachment will be created in.
func (r *OrganizationsEndpointAttachmentsService) Create(parent string, googlecloudapigeev1endpointattachment *GoogleCloudApigeeV1EndpointAttachment) *OrganizationsEndpointAttachmentsCreateCall {
	c := &OrganizationsEndpointAttachmentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1endpointattachment = googlecloudapigeev1endpointattachment
	return c
}

// EndpointAttachmentId sets the optional parameter
// "endpointAttachmentId": ID to use for the endpoint attachment. ID
// must start with a lowercase letter followed by up to 31 lowercase
// letters, numbers, or hyphens, and cannot end with a hyphen. The
// minimum length is 2.
func (c *OrganizationsEndpointAttachmentsCreateCall) EndpointAttachmentId(endpointAttachmentId string) *OrganizationsEndpointAttachmentsCreateCall {
	c.urlParams_.Set("endpointAttachmentId", endpointAttachmentId)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEndpointAttachmentsCreateCall) Fields(s ...googleapi.Field) *OrganizationsEndpointAttachmentsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEndpointAttachmentsCreateCall) Context(ctx context.Context) *OrganizationsEndpointAttachmentsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEndpointAttachmentsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEndpointAttachmentsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1endpointattachment)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/endpointAttachments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.endpointAttachments.create" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEndpointAttachmentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates an endpoint attachment. **Note:** Not supported for Apigee hybrid.",
	//   "flatPath": "v1/organizations/{organizationsId}/endpointAttachments",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.endpointAttachments.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "endpointAttachmentId": {
	//       "description": "ID to use for the endpoint attachment. ID must start with a lowercase letter followed by up to 31 lowercase letters, numbers, or hyphens, and cannot end with a hyphen. The minimum length is 2.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Organization the endpoint attachment will be created in.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/endpointAttachments",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1EndpointAttachment"
	//   },
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.endpointAttachments.delete":

type OrganizationsEndpointAttachmentsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an endpoint attachment.
//
//   - name: Name of the endpoint attachment. Use the following structure
//     in your request:
//     `organizations/{org}/endpointAttachments/{endpoint_attachment}`.
func (r *OrganizationsEndpointAttachmentsService) Delete(name string) *OrganizationsEndpointAttachmentsDeleteCall {
	c := &OrganizationsEndpointAttachmentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEndpointAttachmentsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsEndpointAttachmentsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEndpointAttachmentsDeleteCall) Context(ctx context.Context) *OrganizationsEndpointAttachmentsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEndpointAttachmentsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEndpointAttachmentsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.endpointAttachments.delete" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEndpointAttachmentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an endpoint attachment.",
	//   "flatPath": "v1/organizations/{organizationsId}/endpointAttachments/{endpointAttachmentsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.endpointAttachments.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the endpoint attachment. Use the following structure in your request: `organizations/{org}/endpointAttachments/{endpoint_attachment}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/endpointAttachments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.endpointAttachments.get":

type OrganizationsEndpointAttachmentsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets the endpoint attachment.
//
//   - name: Name of the endpoint attachment. Use the following structure
//     in your request:
//     `organizations/{org}/endpointAttachments/{endpoint_attachment}`.
func (r *OrganizationsEndpointAttachmentsService) Get(name string) *OrganizationsEndpointAttachmentsGetCall {
	c := &OrganizationsEndpointAttachmentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEndpointAttachmentsGetCall) Fields(s ...googleapi.Field) *OrganizationsEndpointAttachmentsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEndpointAttachmentsGetCall) IfNoneMatch(entityTag string) *OrganizationsEndpointAttachmentsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEndpointAttachmentsGetCall) Context(ctx context.Context) *OrganizationsEndpointAttachmentsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEndpointAttachmentsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEndpointAttachmentsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.endpointAttachments.get" call.
// Exactly one of *GoogleCloudApigeeV1EndpointAttachment or error will
// be non-nil. Any non-2xx status code is an error. Response headers are
// in either
// *GoogleCloudApigeeV1EndpointAttachment.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEndpointAttachmentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1EndpointAttachment, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1EndpointAttachment{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the endpoint attachment.",
	//   "flatPath": "v1/organizations/{organizationsId}/endpointAttachments/{endpointAttachmentsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.endpointAttachments.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the endpoint attachment. Use the following structure in your request: `organizations/{org}/endpointAttachments/{endpoint_attachment}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/endpointAttachments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1EndpointAttachment"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.endpointAttachments.list":

type OrganizationsEndpointAttachmentsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists the endpoint attachments in an organization.
//
//   - parent: Name of the organization for which to list endpoint
//     attachments. Use the following structure in your request:
//     `organizations/{org}`.
func (r *OrganizationsEndpointAttachmentsService) List(parent string) *OrganizationsEndpointAttachmentsListCall {
	c := &OrganizationsEndpointAttachmentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// PageSize sets the optional parameter "pageSize": Maximum number of
// endpoint attachments to return. If unspecified, at most 25
// attachments will be returned.
func (c *OrganizationsEndpointAttachmentsListCall) PageSize(pageSize int64) *OrganizationsEndpointAttachmentsListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": Page token,
// returned from a previous `ListEndpointAttachments` call, that you can
// use to retrieve the next page.
func (c *OrganizationsEndpointAttachmentsListCall) PageToken(pageToken string) *OrganizationsEndpointAttachmentsListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEndpointAttachmentsListCall) Fields(s ...googleapi.Field) *OrganizationsEndpointAttachmentsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEndpointAttachmentsListCall) IfNoneMatch(entityTag string) *OrganizationsEndpointAttachmentsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEndpointAttachmentsListCall) Context(ctx context.Context) *OrganizationsEndpointAttachmentsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEndpointAttachmentsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEndpointAttachmentsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/endpointAttachments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.endpointAttachments.list" call.
// Exactly one of *GoogleCloudApigeeV1ListEndpointAttachmentsResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListEndpointAttachmentsResponse.ServerResponse.Hea
// der or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEndpointAttachmentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListEndpointAttachmentsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListEndpointAttachmentsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists the endpoint attachments in an organization.",
	//   "flatPath": "v1/organizations/{organizationsId}/endpointAttachments",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.endpointAttachments.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "pageSize": {
	//       "description": "Optional. Maximum number of endpoint attachments to return. If unspecified, at most 25 attachments will be returned.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Optional. Page token, returned from a previous `ListEndpointAttachments` call, that you can use to retrieve the next page.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the organization for which to list endpoint attachments. Use the following structure in your request: `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/endpointAttachments",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListEndpointAttachmentsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsEndpointAttachmentsListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListEndpointAttachmentsResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.envgroups.create":

type OrganizationsEnvgroupsCreateCall struct {
	s                                   *Service
	parent                              string
	googlecloudapigeev1environmentgroup *GoogleCloudApigeeV1EnvironmentGroup
	urlParams_                          gensupport.URLParams
	ctx_                                context.Context
	header_                             http.Header
}

// Create: Creates a new environment group.
//
//   - parent: Name of the organization in which to create the environment
//     group in the following format: `organizations/{org}`.
func (r *OrganizationsEnvgroupsService) Create(parent string, googlecloudapigeev1environmentgroup *GoogleCloudApigeeV1EnvironmentGroup) *OrganizationsEnvgroupsCreateCall {
	c := &OrganizationsEnvgroupsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1environmentgroup = googlecloudapigeev1environmentgroup
	return c
}

// Name sets the optional parameter "name": ID of the environment group.
// Overrides any ID in the environment_group resource.
func (c *OrganizationsEnvgroupsCreateCall) Name(name string) *OrganizationsEnvgroupsCreateCall {
	c.urlParams_.Set("name", name)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvgroupsCreateCall) Fields(s ...googleapi.Field) *OrganizationsEnvgroupsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvgroupsCreateCall) Context(ctx context.Context) *OrganizationsEnvgroupsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvgroupsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvgroupsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1environmentgroup)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/envgroups")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.envgroups.create" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvgroupsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a new environment group.",
	//   "flatPath": "v1/organizations/{organizationsId}/envgroups",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.envgroups.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Optional. ID of the environment group. Overrides any ID in the environment_group resource.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the organization in which to create the environment group in the following format: `organizations/{org}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/envgroups",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1EnvironmentGroup"
	//   },
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.envgroups.delete":

type OrganizationsEnvgroupsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an environment group.
//
//   - name: Name of the environment group in the following format:
//     `organizations/{org}/envgroups/{envgroup}`.
func (r *OrganizationsEnvgroupsService) Delete(name string) *OrganizationsEnvgroupsDeleteCall {
	c := &OrganizationsEnvgroupsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvgroupsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsEnvgroupsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvgroupsDeleteCall) Context(ctx context.Context) *OrganizationsEnvgroupsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvgroupsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvgroupsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.envgroups.delete" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvgroupsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an environment group.",
	//   "flatPath": "v1/organizations/{organizationsId}/envgroups/{envgroupsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.envgroups.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the environment group in the following format: `organizations/{org}/envgroups/{envgroup}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/envgroups/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.envgroups.get":

type OrganizationsEnvgroupsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets an environment group.
//
//   - name: Name of the environment group in the following format:
//     `organizations/{org}/envgroups/{envgroup}`.
func (r *OrganizationsEnvgroupsService) Get(name string) *OrganizationsEnvgroupsGetCall {
	c := &OrganizationsEnvgroupsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvgroupsGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvgroupsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvgroupsGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvgroupsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvgroupsGetCall) Context(ctx context.Context) *OrganizationsEnvgroupsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvgroupsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvgroupsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.envgroups.get" call.
// Exactly one of *GoogleCloudApigeeV1EnvironmentGroup or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1EnvironmentGroup.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvgroupsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1EnvironmentGroup, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1EnvironmentGroup{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets an environment group.",
	//   "flatPath": "v1/organizations/{organizationsId}/envgroups/{envgroupsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.envgroups.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the environment group in the following format: `organizations/{org}/envgroups/{envgroup}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/envgroups/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1EnvironmentGroup"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.envgroups.getDeployedIngressConfig":

type OrganizationsEnvgroupsGetDeployedIngressConfigCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetDeployedIngressConfig: Gets the deployed ingress configuration for
// an environment group.
//
//   - name: Name of the deployed configuration for the environment group
//     in the following format:
//     'organizations/{org}/envgroups/{envgroup}/deployedIngressConfig'.
func (r *OrganizationsEnvgroupsService) GetDeployedIngressConfig(name string) *OrganizationsEnvgroupsGetDeployedIngressConfigCall {
	c := &OrganizationsEnvgroupsGetDeployedIngressConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// View sets the optional parameter "view": When set to FULL, additional
// details about the specific deployments receiving traffic will be
// included in the IngressConfig response's RoutingRules.
//
// Possible values:
//
//	"INGRESS_CONFIG_VIEW_UNSPECIFIED" - The default/unset value. The
//
// API will default to the BASIC view.
//
//	"BASIC" - Include all ingress config data necessary for the runtime
//
// to configure ingress, but no more. Routing rules will include only
// basepath and destination environment. This the default value.
//
//	"FULL" - Include all ingress config data, including internal debug
//
// info for each routing rule such as the proxy claiming a particular
// basepath and when the routing rule first appeared in the env group.
func (c *OrganizationsEnvgroupsGetDeployedIngressConfigCall) View(view string) *OrganizationsEnvgroupsGetDeployedIngressConfigCall {
	c.urlParams_.Set("view", view)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvgroupsGetDeployedIngressConfigCall) Fields(s ...googleapi.Field) *OrganizationsEnvgroupsGetDeployedIngressConfigCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvgroupsGetDeployedIngressConfigCall) IfNoneMatch(entityTag string) *OrganizationsEnvgroupsGetDeployedIngressConfigCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvgroupsGetDeployedIngressConfigCall) Context(ctx context.Context) *OrganizationsEnvgroupsGetDeployedIngressConfigCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvgroupsGetDeployedIngressConfigCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvgroupsGetDeployedIngressConfigCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.envgroups.getDeployedIngressConfig" call.
// Exactly one of *GoogleCloudApigeeV1EnvironmentGroupConfig or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1EnvironmentGroupConfig.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvgroupsGetDeployedIngressConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1EnvironmentGroupConfig, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1EnvironmentGroupConfig{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the deployed ingress configuration for an environment group.",
	//   "flatPath": "v1/organizations/{organizationsId}/envgroups/{envgroupsId}/deployedIngressConfig",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.envgroups.getDeployedIngressConfig",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the deployed configuration for the environment group in the following format: 'organizations/{org}/envgroups/{envgroup}/deployedIngressConfig'.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/envgroups/[^/]+/deployedIngressConfig$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "view": {
	//       "description": "When set to FULL, additional details about the specific deployments receiving traffic will be included in the IngressConfig response's RoutingRules.",
	//       "enum": [
	//         "INGRESS_CONFIG_VIEW_UNSPECIFIED",
	//         "BASIC",
	//         "FULL"
	//       ],
	//       "enumDescriptions": [
	//         "The default/unset value. The API will default to the BASIC view.",
	//         "Include all ingress config data necessary for the runtime to configure ingress, but no more. Routing rules will include only basepath and destination environment. This the default value.",
	//         "Include all ingress config data, including internal debug info for each routing rule such as the proxy claiming a particular basepath and when the routing rule first appeared in the env group."
	//       ],
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1EnvironmentGroupConfig"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.envgroups.list":

type OrganizationsEnvgroupsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all environment groups.
//
//   - parent: Name of the organization for which to list environment
//     groups in the following format: `organizations/{org}`.
func (r *OrganizationsEnvgroupsService) List(parent string) *OrganizationsEnvgroupsListCall {
	c := &OrganizationsEnvgroupsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// PageSize sets the optional parameter "pageSize": Maximum number of
// environment groups to return. The page size defaults to 25.
func (c *OrganizationsEnvgroupsListCall) PageSize(pageSize int64) *OrganizationsEnvgroupsListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": Page token,
// returned from a previous ListEnvironmentGroups call, that you can use
// to retrieve the next page.
func (c *OrganizationsEnvgroupsListCall) PageToken(pageToken string) *OrganizationsEnvgroupsListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvgroupsListCall) Fields(s ...googleapi.Field) *OrganizationsEnvgroupsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvgroupsListCall) IfNoneMatch(entityTag string) *OrganizationsEnvgroupsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvgroupsListCall) Context(ctx context.Context) *OrganizationsEnvgroupsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvgroupsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvgroupsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/envgroups")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.envgroups.list" call.
// Exactly one of *GoogleCloudApigeeV1ListEnvironmentGroupsResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListEnvironmentGroupsResponse.ServerResponse.Heade
// r or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvgroupsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListEnvironmentGroupsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListEnvironmentGroupsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all environment groups.",
	//   "flatPath": "v1/organizations/{organizationsId}/envgroups",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.envgroups.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "pageSize": {
	//       "description": "Maximum number of environment groups to return. The page size defaults to 25.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Page token, returned from a previous ListEnvironmentGroups call, that you can use to retrieve the next page.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the organization for which to list environment groups in the following format: `organizations/{org}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/envgroups",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListEnvironmentGroupsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsEnvgroupsListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListEnvironmentGroupsResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.envgroups.patch":

type OrganizationsEnvgroupsPatchCall struct {
	s                                   *Service
	name                                string
	googlecloudapigeev1environmentgroup *GoogleCloudApigeeV1EnvironmentGroup
	urlParams_                          gensupport.URLParams
	ctx_                                context.Context
	header_                             http.Header
}

// Patch: Updates an environment group.
//
//   - name: Name of the environment group to update in the format:
//     `organizations/{org}/envgroups/{envgroup}.
func (r *OrganizationsEnvgroupsService) Patch(name string, googlecloudapigeev1environmentgroup *GoogleCloudApigeeV1EnvironmentGroup) *OrganizationsEnvgroupsPatchCall {
	c := &OrganizationsEnvgroupsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1environmentgroup = googlecloudapigeev1environmentgroup
	return c
}

// UpdateMask sets the optional parameter "updateMask": List of fields
// to be updated.
func (c *OrganizationsEnvgroupsPatchCall) UpdateMask(updateMask string) *OrganizationsEnvgroupsPatchCall {
	c.urlParams_.Set("updateMask", updateMask)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvgroupsPatchCall) Fields(s ...googleapi.Field) *OrganizationsEnvgroupsPatchCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvgroupsPatchCall) Context(ctx context.Context) *OrganizationsEnvgroupsPatchCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvgroupsPatchCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvgroupsPatchCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1environmentgroup)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PATCH", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.envgroups.patch" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvgroupsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates an environment group.",
	//   "flatPath": "v1/organizations/{organizationsId}/envgroups/{envgroupsId}",
	//   "httpMethod": "PATCH",
	//   "id": "apigee.organizations.envgroups.patch",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the environment group to update in the format: `organizations/{org}/envgroups/{envgroup}.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/envgroups/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "updateMask": {
	//       "description": "Optional. List of fields to be updated.",
	//       "format": "google-fieldmask",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1EnvironmentGroup"
	//   },
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.envgroups.attachments.create":

type OrganizationsEnvgroupsAttachmentsCreateCall struct {
	s                                             *Service
	parent                                        string
	googlecloudapigeev1environmentgroupattachment *GoogleCloudApigeeV1EnvironmentGroupAttachment
	urlParams_                                    gensupport.URLParams
	ctx_                                          context.Context
	header_                                       http.Header
}

// Create: Creates a new attachment of an environment to an environment
// group.
//
//   - parent: EnvironmentGroup under which to create the attachment in
//     the following format: `organizations/{org}/envgroups/{envgroup}`.
func (r *OrganizationsEnvgroupsAttachmentsService) Create(parent string, googlecloudapigeev1environmentgroupattachment *GoogleCloudApigeeV1EnvironmentGroupAttachment) *OrganizationsEnvgroupsAttachmentsCreateCall {
	c := &OrganizationsEnvgroupsAttachmentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1environmentgroupattachment = googlecloudapigeev1environmentgroupattachment
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvgroupsAttachmentsCreateCall) Fields(s ...googleapi.Field) *OrganizationsEnvgroupsAttachmentsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvgroupsAttachmentsCreateCall) Context(ctx context.Context) *OrganizationsEnvgroupsAttachmentsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvgroupsAttachmentsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvgroupsAttachmentsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1environmentgroupattachment)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/attachments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.envgroups.attachments.create" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvgroupsAttachmentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a new attachment of an environment to an environment group.",
	//   "flatPath": "v1/organizations/{organizationsId}/envgroups/{envgroupsId}/attachments",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.envgroups.attachments.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. EnvironmentGroup under which to create the attachment in the following format: `organizations/{org}/envgroups/{envgroup}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/envgroups/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/attachments",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1EnvironmentGroupAttachment"
	//   },
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.envgroups.attachments.delete":

type OrganizationsEnvgroupsAttachmentsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an environment group attachment.
//
//   - name: Name of the environment group attachment to delete in the
//     following format:
//     `organizations/{org}/envgroups/{envgroup}/attachments/{attachment}`.
func (r *OrganizationsEnvgroupsAttachmentsService) Delete(name string) *OrganizationsEnvgroupsAttachmentsDeleteCall {
	c := &OrganizationsEnvgroupsAttachmentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvgroupsAttachmentsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsEnvgroupsAttachmentsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvgroupsAttachmentsDeleteCall) Context(ctx context.Context) *OrganizationsEnvgroupsAttachmentsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvgroupsAttachmentsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvgroupsAttachmentsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.envgroups.attachments.delete" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvgroupsAttachmentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an environment group attachment.",
	//   "flatPath": "v1/organizations/{organizationsId}/envgroups/{envgroupsId}/attachments/{attachmentsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.envgroups.attachments.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the environment group attachment to delete in the following format: `organizations/{org}/envgroups/{envgroup}/attachments/{attachment}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/envgroups/[^/]+/attachments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.envgroups.attachments.get":

type OrganizationsEnvgroupsAttachmentsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets an environment group attachment.
//
//   - name: Name of the environment group attachment in the following
//     format:
//     `organizations/{org}/envgroups/{envgroup}/attachments/{attachment}`.
func (r *OrganizationsEnvgroupsAttachmentsService) Get(name string) *OrganizationsEnvgroupsAttachmentsGetCall {
	c := &OrganizationsEnvgroupsAttachmentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvgroupsAttachmentsGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvgroupsAttachmentsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvgroupsAttachmentsGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvgroupsAttachmentsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvgroupsAttachmentsGetCall) Context(ctx context.Context) *OrganizationsEnvgroupsAttachmentsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvgroupsAttachmentsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvgroupsAttachmentsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.envgroups.attachments.get" call.
// Exactly one of *GoogleCloudApigeeV1EnvironmentGroupAttachment or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1EnvironmentGroupAttachment.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvgroupsAttachmentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1EnvironmentGroupAttachment, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1EnvironmentGroupAttachment{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets an environment group attachment.",
	//   "flatPath": "v1/organizations/{organizationsId}/envgroups/{envgroupsId}/attachments/{attachmentsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.envgroups.attachments.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the environment group attachment in the following format: `organizations/{org}/envgroups/{envgroup}/attachments/{attachment}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/envgroups/[^/]+/attachments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1EnvironmentGroupAttachment"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.envgroups.attachments.list":

type OrganizationsEnvgroupsAttachmentsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all attachments of an environment group.
//
//   - parent: Name of the environment group in the following format:
//     `organizations/{org}/envgroups/{envgroup}`.
func (r *OrganizationsEnvgroupsAttachmentsService) List(parent string) *OrganizationsEnvgroupsAttachmentsListCall {
	c := &OrganizationsEnvgroupsAttachmentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// PageSize sets the optional parameter "pageSize": Maximum number of
// environment group attachments to return. The page size defaults to
// 25.
func (c *OrganizationsEnvgroupsAttachmentsListCall) PageSize(pageSize int64) *OrganizationsEnvgroupsAttachmentsListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": Page token,
// returned by a previous ListEnvironmentGroupAttachments call, that you
// can use to retrieve the next page.
func (c *OrganizationsEnvgroupsAttachmentsListCall) PageToken(pageToken string) *OrganizationsEnvgroupsAttachmentsListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvgroupsAttachmentsListCall) Fields(s ...googleapi.Field) *OrganizationsEnvgroupsAttachmentsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvgroupsAttachmentsListCall) IfNoneMatch(entityTag string) *OrganizationsEnvgroupsAttachmentsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvgroupsAttachmentsListCall) Context(ctx context.Context) *OrganizationsEnvgroupsAttachmentsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvgroupsAttachmentsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvgroupsAttachmentsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/attachments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.envgroups.attachments.list" call.
// Exactly one of
// *GoogleCloudApigeeV1ListEnvironmentGroupAttachmentsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListEnvironmentGroupAttachmentsResponse.ServerResp
// onse.Header or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvgroupsAttachmentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListEnvironmentGroupAttachmentsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListEnvironmentGroupAttachmentsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all attachments of an environment group.",
	//   "flatPath": "v1/organizations/{organizationsId}/envgroups/{envgroupsId}/attachments",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.envgroups.attachments.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "pageSize": {
	//       "description": "Maximum number of environment group attachments to return. The page size defaults to 25.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Page token, returned by a previous ListEnvironmentGroupAttachments call, that you can use to retrieve the next page.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the environment group in the following format: `organizations/{org}/envgroups/{envgroup}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/envgroups/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/attachments",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListEnvironmentGroupAttachmentsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsEnvgroupsAttachmentsListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListEnvironmentGroupAttachmentsResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.environments.create":

type OrganizationsEnvironmentsCreateCall struct {
	s                              *Service
	parent                         string
	googlecloudapigeev1environment *GoogleCloudApigeeV1Environment
	urlParams_                     gensupport.URLParams
	ctx_                           context.Context
	header_                        http.Header
}

// Create: Creates an environment in an organization.
//
//   - parent: Name of the organization in which the environment will be
//     created. Use the following structure in your request:
//     `organizations/{org}`.
func (r *OrganizationsEnvironmentsService) Create(parent string, googlecloudapigeev1environment *GoogleCloudApigeeV1Environment) *OrganizationsEnvironmentsCreateCall {
	c := &OrganizationsEnvironmentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1environment = googlecloudapigeev1environment
	return c
}

// Name sets the optional parameter "name": Name of the environment.
func (c *OrganizationsEnvironmentsCreateCall) Name(name string) *OrganizationsEnvironmentsCreateCall {
	c.urlParams_.Set("name", name)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsCreateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsCreateCall) Context(ctx context.Context) *OrganizationsEnvironmentsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1environment)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/environments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.create" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates an environment in an organization.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Optional. Name of the environment.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the organization in which the environment will be created. Use the following structure in your request: `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/environments",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Environment"
	//   },
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.delete":

type OrganizationsEnvironmentsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an environment from an organization. **Warning: You
// must delete all key value maps and key value entries before you
// delete an environment.** Otherwise, if you re-create the environment
// the key value map entry operations will encounter
// encryption/decryption discrepancies.
//
//   - name: Name of the environment. Use the following structure in your
//     request: `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsService) Delete(name string) *OrganizationsEnvironmentsDeleteCall {
	c := &OrganizationsEnvironmentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsDeleteCall) Context(ctx context.Context) *OrganizationsEnvironmentsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.delete" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an environment from an organization. **Warning: You must delete all key value maps and key value entries before you delete an environment.** Otherwise, if you re-create the environment the key value map entry operations will encounter encryption/decryption discrepancies.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.environments.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the environment. Use the following structure in your request: `organizations/{org}/environments/{env}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.get":

type OrganizationsEnvironmentsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets environment details.
//
//   - name: Name of the environment. Use the following structure in your
//     request: `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsService) Get(name string) *OrganizationsEnvironmentsGetCall {
	c := &OrganizationsEnvironmentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.get" call.
// Exactly one of *GoogleCloudApigeeV1Environment or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Environment.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Environment, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Environment{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets environment details.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the environment. Use the following structure in your request: `organizations/{org}/environments/{env}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Environment"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.getAddonsConfig":

type OrganizationsEnvironmentsGetAddonsConfigCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetAddonsConfig: Gets the add-ons config of an environment.
//
//   - name: Name of the add-ons config. Must be in the format of
//     `/organizations/{org}/environments/{env}/addonsConfig`.
func (r *OrganizationsEnvironmentsService) GetAddonsConfig(name string) *OrganizationsEnvironmentsGetAddonsConfigCall {
	c := &OrganizationsEnvironmentsGetAddonsConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsGetAddonsConfigCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsGetAddonsConfigCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsGetAddonsConfigCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsGetAddonsConfigCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsGetAddonsConfigCall) Context(ctx context.Context) *OrganizationsEnvironmentsGetAddonsConfigCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsGetAddonsConfigCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsGetAddonsConfigCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.getAddonsConfig" call.
// Exactly one of *GoogleCloudApigeeV1AddonsConfig or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1AddonsConfig.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsGetAddonsConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AddonsConfig, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AddonsConfig{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the add-ons config of an environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/addonsConfig",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.getAddonsConfig",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the add-ons config. Must be in the format of `/organizations/{org}/environments/{env}/addonsConfig`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/addonsConfig$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AddonsConfig"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.getApiSecurityRuntimeConfig":

type OrganizationsEnvironmentsGetApiSecurityRuntimeConfigCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetApiSecurityRuntimeConfig: Gets the API Security runtime
// configuration for an environment. This named ApiSecurityRuntimeConfig
// to prevent conflicts with ApiSecurityConfig from addon config.
//
//   - name: Name of the environment API Security Runtime configuration
//     resource. Use the following structure in your request:
//     `organizations/{org}/environments/{env}/apiSecurityRuntimeConfig`.
func (r *OrganizationsEnvironmentsService) GetApiSecurityRuntimeConfig(name string) *OrganizationsEnvironmentsGetApiSecurityRuntimeConfigCall {
	c := &OrganizationsEnvironmentsGetApiSecurityRuntimeConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsGetApiSecurityRuntimeConfigCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsGetApiSecurityRuntimeConfigCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsGetApiSecurityRuntimeConfigCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsGetApiSecurityRuntimeConfigCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsGetApiSecurityRuntimeConfigCall) Context(ctx context.Context) *OrganizationsEnvironmentsGetApiSecurityRuntimeConfigCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsGetApiSecurityRuntimeConfigCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsGetApiSecurityRuntimeConfigCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.getApiSecurityRuntimeConfig" call.
// Exactly one of *GoogleCloudApigeeV1ApiSecurityRuntimeConfig or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ApiSecurityRuntimeConfig.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsGetApiSecurityRuntimeConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiSecurityRuntimeConfig, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiSecurityRuntimeConfig{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the API Security runtime configuration for an environment. This named ApiSecurityRuntimeConfig to prevent conflicts with ApiSecurityConfig from addon config.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/apiSecurityRuntimeConfig",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.getApiSecurityRuntimeConfig",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the environment API Security Runtime configuration resource. Use the following structure in your request: `organizations/{org}/environments/{env}/apiSecurityRuntimeConfig`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/apiSecurityRuntimeConfig$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiSecurityRuntimeConfig"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.getDebugmask":

type OrganizationsEnvironmentsGetDebugmaskCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetDebugmask: Gets the debug mask singleton resource for an
// environment.
//
//   - name: Name of the debug mask. Use the following structure in your
//     request: `organizations/{org}/environments/{env}/debugmask`.
func (r *OrganizationsEnvironmentsService) GetDebugmask(name string) *OrganizationsEnvironmentsGetDebugmaskCall {
	c := &OrganizationsEnvironmentsGetDebugmaskCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsGetDebugmaskCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsGetDebugmaskCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsGetDebugmaskCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsGetDebugmaskCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsGetDebugmaskCall) Context(ctx context.Context) *OrganizationsEnvironmentsGetDebugmaskCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsGetDebugmaskCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsGetDebugmaskCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.getDebugmask" call.
// Exactly one of *GoogleCloudApigeeV1DebugMask or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DebugMask.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsGetDebugmaskCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DebugMask, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DebugMask{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the debug mask singleton resource for an environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/debugmask",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.getDebugmask",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the debug mask. Use the following structure in your request: `organizations/{org}/environments/{env}/debugmask`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/debugmask$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DebugMask"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.getDeployedConfig":

type OrganizationsEnvironmentsGetDeployedConfigCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetDeployedConfig: Gets the deployed configuration for an
// environment.
//
//   - name: Name of the environment deployed configuration resource. Use
//     the following structure in your request:
//     `organizations/{org}/environments/{env}/deployedConfig`.
func (r *OrganizationsEnvironmentsService) GetDeployedConfig(name string) *OrganizationsEnvironmentsGetDeployedConfigCall {
	c := &OrganizationsEnvironmentsGetDeployedConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsGetDeployedConfigCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsGetDeployedConfigCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsGetDeployedConfigCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsGetDeployedConfigCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsGetDeployedConfigCall) Context(ctx context.Context) *OrganizationsEnvironmentsGetDeployedConfigCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsGetDeployedConfigCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsGetDeployedConfigCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.getDeployedConfig" call.
// Exactly one of *GoogleCloudApigeeV1EnvironmentConfig or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1EnvironmentConfig.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsGetDeployedConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1EnvironmentConfig, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1EnvironmentConfig{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the deployed configuration for an environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/deployedConfig",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.getDeployedConfig",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the environment deployed configuration resource. Use the following structure in your request: `organizations/{org}/environments/{env}/deployedConfig`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/deployedConfig$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1EnvironmentConfig"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.getIamPolicy":

type OrganizationsEnvironmentsGetIamPolicyCall struct {
	s            *Service
	resource     string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetIamPolicy: Gets the IAM policy on an environment. For more
// information, see Manage users, roles, and permissions using the API
// (https://cloud.google.com/apigee/docs/api-platform/system-administration/manage-users-roles).
// You must have the `apigee.environments.getIamPolicy` permission to
// call this API.
//
//   - resource: REQUIRED: The resource for which the policy is being
//     requested. See Resource names
//     (https://cloud.google.com/apis/design/resource_names) for the
//     appropriate value for this field.
func (r *OrganizationsEnvironmentsService) GetIamPolicy(resource string) *OrganizationsEnvironmentsGetIamPolicyCall {
	c := &OrganizationsEnvironmentsGetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.resource = resource
	return c
}

// OptionsRequestedPolicyVersion sets the optional parameter
// "options.requestedPolicyVersion": The maximum policy version that
// will be used to format the policy. Valid values are 0, 1, and 3.
// Requests specifying an invalid value will be rejected. Requests for
// policies with any conditional role bindings must specify version 3.
// Policies with no conditional role bindings may specify any valid
// value or leave the field unset. The policy in the response might use
// the policy version that you specified, or it might use a lower policy
// version. For example, if you specify version 3, but the policy has no
// conditional role bindings, the response uses version 1. To learn
// which resources support conditions in their IAM policies, see the IAM
// documentation
// (https://cloud.google.com/iam/help/conditions/resource-policies).
func (c *OrganizationsEnvironmentsGetIamPolicyCall) OptionsRequestedPolicyVersion(optionsRequestedPolicyVersion int64) *OrganizationsEnvironmentsGetIamPolicyCall {
	c.urlParams_.Set("options.requestedPolicyVersion", fmt.Sprint(optionsRequestedPolicyVersion))
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsGetIamPolicyCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsGetIamPolicyCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsGetIamPolicyCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsGetIamPolicyCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsGetIamPolicyCall) Context(ctx context.Context) *OrganizationsEnvironmentsGetIamPolicyCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsGetIamPolicyCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsGetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:getIamPolicy")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"resource": c.resource,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.getIamPolicy" call.
// Exactly one of *GoogleIamV1Policy or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleIamV1Policy.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsGetIamPolicyCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1Policy, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleIamV1Policy{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the IAM policy on an environment. For more information, see [Manage users, roles, and permissions using the API](https://cloud.google.com/apigee/docs/api-platform/system-administration/manage-users-roles). You must have the `apigee.environments.getIamPolicy` permission to call this API.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}:getIamPolicy",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.getIamPolicy",
	//   "parameterOrder": [
	//     "resource"
	//   ],
	//   "parameters": {
	//     "options.requestedPolicyVersion": {
	//       "description": "Optional. The maximum policy version that will be used to format the policy. Valid values are 0, 1, and 3. Requests specifying an invalid value will be rejected. Requests for policies with any conditional role bindings must specify version 3. Policies with no conditional role bindings may specify any valid value or leave the field unset. The policy in the response might use the policy version that you specified, or it might use a lower policy version. For example, if you specify version 3, but the policy has no conditional role bindings, the response uses version 1. To learn which resources support conditions in their IAM policies, see the [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "resource": {
	//       "description": "REQUIRED: The resource for which the policy is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+resource}:getIamPolicy",
	//   "response": {
	//     "$ref": "GoogleIamV1Policy"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.getSecurityActionsConfig":

type OrganizationsEnvironmentsGetSecurityActionsConfigCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetSecurityActionsConfig: GetSecurityActionConfig returns the current
// SecurityActions configuration.
//
//   - name: The name of the SecurityActionsConfig to retrieve. This will
//     always be:
//     `organizations/{org}/environments/{env}/security_actions_config`.
func (r *OrganizationsEnvironmentsService) GetSecurityActionsConfig(name string) *OrganizationsEnvironmentsGetSecurityActionsConfigCall {
	c := &OrganizationsEnvironmentsGetSecurityActionsConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsGetSecurityActionsConfigCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsGetSecurityActionsConfigCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsGetSecurityActionsConfigCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsGetSecurityActionsConfigCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsGetSecurityActionsConfigCall) Context(ctx context.Context) *OrganizationsEnvironmentsGetSecurityActionsConfigCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsGetSecurityActionsConfigCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsGetSecurityActionsConfigCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.getSecurityActionsConfig" call.
// Exactly one of *GoogleCloudApigeeV1SecurityActionsConfig or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1SecurityActionsConfig.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsGetSecurityActionsConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityActionsConfig, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityActionsConfig{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "GetSecurityActionConfig returns the current SecurityActions configuration.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityActionsConfig",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.getSecurityActionsConfig",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the SecurityActionsConfig to retrieve. This will always be: `organizations/{org}/environments/{env}/security_actions_config`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/securityActionsConfig$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityActionsConfig"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.getTraceConfig":

type OrganizationsEnvironmentsGetTraceConfigCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetTraceConfig: Get distributed trace configuration in an
// environment.
//
//   - name: Name of the trace configuration. Use the following structure
//     in your request: "organizations/*/environments/*/traceConfig".
func (r *OrganizationsEnvironmentsService) GetTraceConfig(name string) *OrganizationsEnvironmentsGetTraceConfigCall {
	c := &OrganizationsEnvironmentsGetTraceConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsGetTraceConfigCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsGetTraceConfigCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsGetTraceConfigCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsGetTraceConfigCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsGetTraceConfigCall) Context(ctx context.Context) *OrganizationsEnvironmentsGetTraceConfigCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsGetTraceConfigCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsGetTraceConfigCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.getTraceConfig" call.
// Exactly one of *GoogleCloudApigeeV1TraceConfig or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1TraceConfig.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsGetTraceConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1TraceConfig, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1TraceConfig{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Get distributed trace configuration in an environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/traceConfig",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.getTraceConfig",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the trace configuration. Use the following structure in your request: \"organizations/*/environments/*/traceConfig\".",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/traceConfig$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1TraceConfig"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.modifyEnvironment":

type OrganizationsEnvironmentsModifyEnvironmentCall struct {
	s                              *Service
	name                           string
	googlecloudapigeev1environment *GoogleCloudApigeeV1Environment
	urlParams_                     gensupport.URLParams
	ctx_                           context.Context
	header_                        http.Header
}

// ModifyEnvironment: Updates properties for an Apigee environment with
// patch semantics using a field mask. **Note:** Not supported for
// Apigee hybrid.
//
//   - name: Name of the environment. Use the following structure in your
//     request: `organizations/{org}/environments/{environment}`.
func (r *OrganizationsEnvironmentsService) ModifyEnvironment(name string, googlecloudapigeev1environment *GoogleCloudApigeeV1Environment) *OrganizationsEnvironmentsModifyEnvironmentCall {
	c := &OrganizationsEnvironmentsModifyEnvironmentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1environment = googlecloudapigeev1environment
	return c
}

// UpdateMask sets the optional parameter "updateMask": List of fields
// to be updated. Fields that can be updated: node_config.
func (c *OrganizationsEnvironmentsModifyEnvironmentCall) UpdateMask(updateMask string) *OrganizationsEnvironmentsModifyEnvironmentCall {
	c.urlParams_.Set("updateMask", updateMask)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsModifyEnvironmentCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsModifyEnvironmentCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsModifyEnvironmentCall) Context(ctx context.Context) *OrganizationsEnvironmentsModifyEnvironmentCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsModifyEnvironmentCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsModifyEnvironmentCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1environment)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PATCH", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.modifyEnvironment" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsModifyEnvironmentCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates properties for an Apigee environment with patch semantics using a field mask. **Note:** Not supported for Apigee hybrid.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}",
	//   "httpMethod": "PATCH",
	//   "id": "apigee.organizations.environments.modifyEnvironment",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the environment. Use the following structure in your request: `organizations/{org}/environments/{environment}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "updateMask": {
	//       "description": "List of fields to be updated. Fields that can be updated: node_config.",
	//       "format": "google-fieldmask",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Environment"
	//   },
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.setIamPolicy":

type OrganizationsEnvironmentsSetIamPolicyCall struct {
	s                              *Service
	resource                       string
	googleiamv1setiampolicyrequest *GoogleIamV1SetIamPolicyRequest
	urlParams_                     gensupport.URLParams
	ctx_                           context.Context
	header_                        http.Header
}

// SetIamPolicy: Sets the IAM policy on an environment, if the policy
// already exists it will be replaced. For more information, see Manage
// users, roles, and permissions using the API
// (https://cloud.google.com/apigee/docs/api-platform/system-administration/manage-users-roles).
// You must have the `apigee.environments.setIamPolicy` permission to
// call this API.
//
//   - resource: REQUIRED: The resource for which the policy is being
//     specified. See Resource names
//     (https://cloud.google.com/apis/design/resource_names) for the
//     appropriate value for this field.
func (r *OrganizationsEnvironmentsService) SetIamPolicy(resource string, googleiamv1setiampolicyrequest *GoogleIamV1SetIamPolicyRequest) *OrganizationsEnvironmentsSetIamPolicyCall {
	c := &OrganizationsEnvironmentsSetIamPolicyCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.resource = resource
	c.googleiamv1setiampolicyrequest = googleiamv1setiampolicyrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSetIamPolicyCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSetIamPolicyCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSetIamPolicyCall) Context(ctx context.Context) *OrganizationsEnvironmentsSetIamPolicyCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSetIamPolicyCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSetIamPolicyCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleiamv1setiampolicyrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:setIamPolicy")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"resource": c.resource,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.setIamPolicy" call.
// Exactly one of *GoogleIamV1Policy or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleIamV1Policy.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsSetIamPolicyCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1Policy, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleIamV1Policy{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Sets the IAM policy on an environment, if the policy already exists it will be replaced. For more information, see [Manage users, roles, and permissions using the API](https://cloud.google.com/apigee/docs/api-platform/system-administration/manage-users-roles). You must have the `apigee.environments.setIamPolicy` permission to call this API.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}:setIamPolicy",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.setIamPolicy",
	//   "parameterOrder": [
	//     "resource"
	//   ],
	//   "parameters": {
	//     "resource": {
	//       "description": "REQUIRED: The resource for which the policy is being specified. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+resource}:setIamPolicy",
	//   "request": {
	//     "$ref": "GoogleIamV1SetIamPolicyRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleIamV1Policy"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.subscribe":

type OrganizationsEnvironmentsSubscribeCall struct {
	s          *Service
	parent     string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Subscribe: Creates a subscription for the environment's Pub/Sub
// topic. The server will assign a random name for this subscription.
// The "name" and "push_config" must *not* be specified.
//
//   - parent: Name of the environment. Use the following structure in
//     your request: `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsService) Subscribe(parent string) *OrganizationsEnvironmentsSubscribeCall {
	c := &OrganizationsEnvironmentsSubscribeCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSubscribeCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSubscribeCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSubscribeCall) Context(ctx context.Context) *OrganizationsEnvironmentsSubscribeCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSubscribeCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSubscribeCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}:subscribe")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.subscribe" call.
// Exactly one of *GoogleCloudApigeeV1Subscription or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Subscription.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsSubscribeCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Subscription, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Subscription{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a subscription for the environment's Pub/Sub topic. The server will assign a random name for this subscription. The \"name\" and \"push_config\" must *not* be specified.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}:subscribe",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.subscribe",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the environment. Use the following structure in your request: `organizations/{org}/environments/{env}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}:subscribe",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Subscription"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.testIamPermissions":

type OrganizationsEnvironmentsTestIamPermissionsCall struct {
	s                                    *Service
	resource                             string
	googleiamv1testiampermissionsrequest *GoogleIamV1TestIamPermissionsRequest
	urlParams_                           gensupport.URLParams
	ctx_                                 context.Context
	header_                              http.Header
}

// TestIamPermissions: Tests the permissions of a user on an
// environment, and returns a subset of permissions that the user has on
// the environment. If the environment does not exist, an empty
// permission set is returned (a NOT_FOUND error is not returned).
//
//   - resource: REQUIRED: The resource for which the policy detail is
//     being requested. See Resource names
//     (https://cloud.google.com/apis/design/resource_names) for the
//     appropriate value for this field.
func (r *OrganizationsEnvironmentsService) TestIamPermissions(resource string, googleiamv1testiampermissionsrequest *GoogleIamV1TestIamPermissionsRequest) *OrganizationsEnvironmentsTestIamPermissionsCall {
	c := &OrganizationsEnvironmentsTestIamPermissionsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.resource = resource
	c.googleiamv1testiampermissionsrequest = googleiamv1testiampermissionsrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsTestIamPermissionsCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsTestIamPermissionsCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsTestIamPermissionsCall) Context(ctx context.Context) *OrganizationsEnvironmentsTestIamPermissionsCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsTestIamPermissionsCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsTestIamPermissionsCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleiamv1testiampermissionsrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+resource}:testIamPermissions")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"resource": c.resource,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.testIamPermissions" call.
// Exactly one of *GoogleIamV1TestIamPermissionsResponse or error will
// be non-nil. Any non-2xx status code is an error. Response headers are
// in either
// *GoogleIamV1TestIamPermissionsResponse.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsTestIamPermissionsCall) Do(opts ...googleapi.CallOption) (*GoogleIamV1TestIamPermissionsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleIamV1TestIamPermissionsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Tests the permissions of a user on an environment, and returns a subset of permissions that the user has on the environment. If the environment does not exist, an empty permission set is returned (a NOT_FOUND error is not returned).",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}:testIamPermissions",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.testIamPermissions",
	//   "parameterOrder": [
	//     "resource"
	//   ],
	//   "parameters": {
	//     "resource": {
	//       "description": "REQUIRED: The resource for which the policy detail is being requested. See [Resource names](https://cloud.google.com/apis/design/resource_names) for the appropriate value for this field.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+resource}:testIamPermissions",
	//   "request": {
	//     "$ref": "GoogleIamV1TestIamPermissionsRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleIamV1TestIamPermissionsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.unsubscribe":

type OrganizationsEnvironmentsUnsubscribeCall struct {
	s                               *Service
	parent                          string
	googlecloudapigeev1subscription *GoogleCloudApigeeV1Subscription
	urlParams_                      gensupport.URLParams
	ctx_                            context.Context
	header_                         http.Header
}

// Unsubscribe: Deletes a subscription for the environment's Pub/Sub
// topic.
//
//   - parent: Name of the environment. Use the following structure in
//     your request: `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsService) Unsubscribe(parent string, googlecloudapigeev1subscription *GoogleCloudApigeeV1Subscription) *OrganizationsEnvironmentsUnsubscribeCall {
	c := &OrganizationsEnvironmentsUnsubscribeCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1subscription = googlecloudapigeev1subscription
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsUnsubscribeCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsUnsubscribeCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsUnsubscribeCall) Context(ctx context.Context) *OrganizationsEnvironmentsUnsubscribeCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsUnsubscribeCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsUnsubscribeCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1subscription)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}:unsubscribe")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.unsubscribe" call.
// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsUnsubscribeCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleProtobufEmpty{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a subscription for the environment's Pub/Sub topic.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}:unsubscribe",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.unsubscribe",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the environment. Use the following structure in your request: `organizations/{org}/environments/{env}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}:unsubscribe",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Subscription"
	//   },
	//   "response": {
	//     "$ref": "GoogleProtobufEmpty"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.update":

type OrganizationsEnvironmentsUpdateCall struct {
	s                              *Service
	name                           string
	googlecloudapigeev1environment *GoogleCloudApigeeV1Environment
	urlParams_                     gensupport.URLParams
	ctx_                           context.Context
	header_                        http.Header
}

// Update: Updates an existing environment. When updating properties,
// you must pass all existing properties to the API, even if they are
// not being changed. If you omit properties from the payload, the
// properties are removed. To get the current list of properties for the
// environment, use the Get Environment API (get). **Note**: Both `PUT`
// and `POST` methods are supported for updating an existing
// environment.
//
//   - name: Name of the environment. Use the following structure in your
//     request: `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsService) Update(name string, googlecloudapigeev1environment *GoogleCloudApigeeV1Environment) *OrganizationsEnvironmentsUpdateCall {
	c := &OrganizationsEnvironmentsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1environment = googlecloudapigeev1environment
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsUpdateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsUpdateCall) Context(ctx context.Context) *OrganizationsEnvironmentsUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1environment)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.update" call.
// Exactly one of *GoogleCloudApigeeV1Environment or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Environment.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Environment, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Environment{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates an existing environment. When updating properties, you must pass all existing properties to the API, even if they are not being changed. If you omit properties from the payload, the properties are removed. To get the current list of properties for the environment, use the [Get Environment API](get). **Note**: Both `PUT` and `POST` methods are supported for updating an existing environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.environments.update",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the environment. Use the following structure in your request: `organizations/{org}/environments/{env}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Environment"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Environment"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.updateDebugmask":

type OrganizationsEnvironmentsUpdateDebugmaskCall struct {
	s                            *Service
	name                         string
	googlecloudapigeev1debugmask *GoogleCloudApigeeV1DebugMask
	urlParams_                   gensupport.URLParams
	ctx_                         context.Context
	header_                      http.Header
}

// UpdateDebugmask: Updates the debug mask singleton resource for an
// environment.
//
// - name: Name of the debug mask.
func (r *OrganizationsEnvironmentsService) UpdateDebugmask(name string, googlecloudapigeev1debugmask *GoogleCloudApigeeV1DebugMask) *OrganizationsEnvironmentsUpdateDebugmaskCall {
	c := &OrganizationsEnvironmentsUpdateDebugmaskCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1debugmask = googlecloudapigeev1debugmask
	return c
}

// ReplaceRepeatedFields sets the optional parameter
// "replaceRepeatedFields": Boolean flag that specifies whether to
// replace existing values in the debug mask when doing an update. Set
// to true to replace existing values. The default behavior is to append
// the values (false).
func (c *OrganizationsEnvironmentsUpdateDebugmaskCall) ReplaceRepeatedFields(replaceRepeatedFields bool) *OrganizationsEnvironmentsUpdateDebugmaskCall {
	c.urlParams_.Set("replaceRepeatedFields", fmt.Sprint(replaceRepeatedFields))
	return c
}

// UpdateMask sets the optional parameter "updateMask": Field debug mask
// to support partial updates.
func (c *OrganizationsEnvironmentsUpdateDebugmaskCall) UpdateMask(updateMask string) *OrganizationsEnvironmentsUpdateDebugmaskCall {
	c.urlParams_.Set("updateMask", updateMask)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsUpdateDebugmaskCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsUpdateDebugmaskCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsUpdateDebugmaskCall) Context(ctx context.Context) *OrganizationsEnvironmentsUpdateDebugmaskCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsUpdateDebugmaskCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsUpdateDebugmaskCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1debugmask)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PATCH", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.updateDebugmask" call.
// Exactly one of *GoogleCloudApigeeV1DebugMask or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DebugMask.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsUpdateDebugmaskCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DebugMask, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DebugMask{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates the debug mask singleton resource for an environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/debugmask",
	//   "httpMethod": "PATCH",
	//   "id": "apigee.organizations.environments.updateDebugmask",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Name of the debug mask.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/debugmask$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "replaceRepeatedFields": {
	//       "description": "Boolean flag that specifies whether to replace existing values in the debug mask when doing an update. Set to true to replace existing values. The default behavior is to append the values (false).",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "updateMask": {
	//       "description": "Field debug mask to support partial updates.",
	//       "format": "google-fieldmask",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1DebugMask"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DebugMask"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.updateEnvironment":

type OrganizationsEnvironmentsUpdateEnvironmentCall struct {
	s                              *Service
	name                           string
	googlecloudapigeev1environment *GoogleCloudApigeeV1Environment
	urlParams_                     gensupport.URLParams
	ctx_                           context.Context
	header_                        http.Header
}

// UpdateEnvironment: Updates an existing environment. When updating
// properties, you must pass all existing properties to the API, even if
// they are not being changed. If you omit properties from the payload,
// the properties are removed. To get the current list of properties for
// the environment, use the Get Environment API (get). **Note**: Both
// `PUT` and `POST` methods are supported for updating an existing
// environment.
//
//   - name: Name of the environment. Use the following structure in your
//     request: `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsService) UpdateEnvironment(name string, googlecloudapigeev1environment *GoogleCloudApigeeV1Environment) *OrganizationsEnvironmentsUpdateEnvironmentCall {
	c := &OrganizationsEnvironmentsUpdateEnvironmentCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1environment = googlecloudapigeev1environment
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsUpdateEnvironmentCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsUpdateEnvironmentCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsUpdateEnvironmentCall) Context(ctx context.Context) *OrganizationsEnvironmentsUpdateEnvironmentCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsUpdateEnvironmentCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsUpdateEnvironmentCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1environment)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.updateEnvironment" call.
// Exactly one of *GoogleCloudApigeeV1Environment or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Environment.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsUpdateEnvironmentCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Environment, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Environment{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates an existing environment. When updating properties, you must pass all existing properties to the API, even if they are not being changed. If you omit properties from the payload, the properties are removed. To get the current list of properties for the environment, use the [Get Environment API](get). **Note**: Both `PUT` and `POST` methods are supported for updating an existing environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.updateEnvironment",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the environment. Use the following structure in your request: `organizations/{org}/environments/{env}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Environment"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Environment"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.updateSecurityActionsConfig":

type OrganizationsEnvironmentsUpdateSecurityActionsConfigCall struct {
	s                                        *Service
	name                                     string
	googlecloudapigeev1securityactionsconfig *GoogleCloudApigeeV1SecurityActionsConfig
	urlParams_                               gensupport.URLParams
	ctx_                                     context.Context
	header_                                  http.Header
}

// UpdateSecurityActionsConfig: UpdateSecurityActionConfig updates the
// current SecurityActions configuration. This method is used to
// enable/disable the feature at the environment level.
//
//   - name: This is a singleton resource, the name will always be set by
//     SecurityActions and any user input will be ignored. The name is
//     always:
//     `organizations/{org}/environments/{env}/security_actions_config`.
func (r *OrganizationsEnvironmentsService) UpdateSecurityActionsConfig(name string, googlecloudapigeev1securityactionsconfig *GoogleCloudApigeeV1SecurityActionsConfig) *OrganizationsEnvironmentsUpdateSecurityActionsConfigCall {
	c := &OrganizationsEnvironmentsUpdateSecurityActionsConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1securityactionsconfig = googlecloudapigeev1securityactionsconfig
	return c
}

// UpdateMask sets the optional parameter "updateMask": The list of
// fields to update.
func (c *OrganizationsEnvironmentsUpdateSecurityActionsConfigCall) UpdateMask(updateMask string) *OrganizationsEnvironmentsUpdateSecurityActionsConfigCall {
	c.urlParams_.Set("updateMask", updateMask)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsUpdateSecurityActionsConfigCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsUpdateSecurityActionsConfigCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsUpdateSecurityActionsConfigCall) Context(ctx context.Context) *OrganizationsEnvironmentsUpdateSecurityActionsConfigCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsUpdateSecurityActionsConfigCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsUpdateSecurityActionsConfigCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1securityactionsconfig)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PATCH", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.updateSecurityActionsConfig" call.
// Exactly one of *GoogleCloudApigeeV1SecurityActionsConfig or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1SecurityActionsConfig.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsUpdateSecurityActionsConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityActionsConfig, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityActionsConfig{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "UpdateSecurityActionConfig updates the current SecurityActions configuration. This method is used to enable/disable the feature at the environment level.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityActionsConfig",
	//   "httpMethod": "PATCH",
	//   "id": "apigee.organizations.environments.updateSecurityActionsConfig",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "This is a singleton resource, the name will always be set by SecurityActions and any user input will be ignored. The name is always: `organizations/{org}/environments/{env}/security_actions_config`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/securityActionsConfig$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "updateMask": {
	//       "description": "The list of fields to update.",
	//       "format": "google-fieldmask",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1SecurityActionsConfig"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityActionsConfig"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.updateTraceConfig":

type OrganizationsEnvironmentsUpdateTraceConfigCall struct {
	s                              *Service
	name                           string
	googlecloudapigeev1traceconfig *GoogleCloudApigeeV1TraceConfig
	urlParams_                     gensupport.URLParams
	ctx_                           context.Context
	header_                        http.Header
}

// UpdateTraceConfig: Updates the trace configurations in an
// environment. Note that the repeated fields have replace semantics
// when included in the field mask and that they will be overwritten by
// the value of the fields in the request body.
//
//   - name: Name of the trace configuration. Use the following structure
//     in your request: "organizations/*/environments/*/traceConfig".
func (r *OrganizationsEnvironmentsService) UpdateTraceConfig(name string, googlecloudapigeev1traceconfig *GoogleCloudApigeeV1TraceConfig) *OrganizationsEnvironmentsUpdateTraceConfigCall {
	c := &OrganizationsEnvironmentsUpdateTraceConfigCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1traceconfig = googlecloudapigeev1traceconfig
	return c
}

// UpdateMask sets the optional parameter "updateMask": List of fields
// to be updated.
func (c *OrganizationsEnvironmentsUpdateTraceConfigCall) UpdateMask(updateMask string) *OrganizationsEnvironmentsUpdateTraceConfigCall {
	c.urlParams_.Set("updateMask", updateMask)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsUpdateTraceConfigCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsUpdateTraceConfigCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsUpdateTraceConfigCall) Context(ctx context.Context) *OrganizationsEnvironmentsUpdateTraceConfigCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsUpdateTraceConfigCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsUpdateTraceConfigCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1traceconfig)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PATCH", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.updateTraceConfig" call.
// Exactly one of *GoogleCloudApigeeV1TraceConfig or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1TraceConfig.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsUpdateTraceConfigCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1TraceConfig, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1TraceConfig{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates the trace configurations in an environment. Note that the repeated fields have replace semantics when included in the field mask and that they will be overwritten by the value of the fields in the request body.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/traceConfig",
	//   "httpMethod": "PATCH",
	//   "id": "apigee.organizations.environments.updateTraceConfig",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the trace configuration. Use the following structure in your request: \"organizations/*/environments/*/traceConfig\".",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/traceConfig$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "updateMask": {
	//       "description": "List of fields to be updated.",
	//       "format": "google-fieldmask",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1TraceConfig"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1TraceConfig"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.addonsConfig.setAddonEnablement":

type OrganizationsEnvironmentsAddonsConfigSetAddonEnablementCall struct {
	s                                            *Service
	name                                         string
	googlecloudapigeev1setaddonenablementrequest *GoogleCloudApigeeV1SetAddonEnablementRequest
	urlParams_                                   gensupport.URLParams
	ctx_                                         context.Context
	header_                                      http.Header
}

// SetAddonEnablement: Updates an add-on enablement status of an
// environment.
//
//   - name: Name of the add-ons config. Must be in the format of
//     `/organizations/{org}/environments/{env}/addonsConfig`.
func (r *OrganizationsEnvironmentsAddonsConfigService) SetAddonEnablement(name string, googlecloudapigeev1setaddonenablementrequest *GoogleCloudApigeeV1SetAddonEnablementRequest) *OrganizationsEnvironmentsAddonsConfigSetAddonEnablementCall {
	c := &OrganizationsEnvironmentsAddonsConfigSetAddonEnablementCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1setaddonenablementrequest = googlecloudapigeev1setaddonenablementrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsAddonsConfigSetAddonEnablementCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsAddonsConfigSetAddonEnablementCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsAddonsConfigSetAddonEnablementCall) Context(ctx context.Context) *OrganizationsEnvironmentsAddonsConfigSetAddonEnablementCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsAddonsConfigSetAddonEnablementCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsAddonsConfigSetAddonEnablementCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1setaddonenablementrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:setAddonEnablement")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.addonsConfig.setAddonEnablement" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsAddonsConfigSetAddonEnablementCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates an add-on enablement status of an environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/addonsConfig:setAddonEnablement",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.addonsConfig.setAddonEnablement",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the add-ons config. Must be in the format of `/organizations/{org}/environments/{env}/addonsConfig`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/addonsConfig$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}:setAddonEnablement",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1SetAddonEnablementRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.analytics.admin.getSchemav2":

type OrganizationsEnvironmentsAnalyticsAdminGetSchemav2Call struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetSchemav2: Gets a list of metrics and dimensions that can be used
// to create analytics queries and reports. Each schema element contains
// the name of the field, its associated type, and a flag indicating
// whether it is a standard or custom field.
//
//   - name: Path to the schema. Use the following structure in your
//     request:
//     `organizations/{org}/environments/{env}/analytics/admin/schemav2`.
func (r *OrganizationsEnvironmentsAnalyticsAdminService) GetSchemav2(name string) *OrganizationsEnvironmentsAnalyticsAdminGetSchemav2Call {
	c := &OrganizationsEnvironmentsAnalyticsAdminGetSchemav2Call{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// DisableCache sets the optional parameter "disableCache": Flag that
// specifies whether the schema is be read from the database or cache.
// Set to `true` to read the schema from the database. Defaults to
// cache.
func (c *OrganizationsEnvironmentsAnalyticsAdminGetSchemav2Call) DisableCache(disableCache bool) *OrganizationsEnvironmentsAnalyticsAdminGetSchemav2Call {
	c.urlParams_.Set("disableCache", fmt.Sprint(disableCache))
	return c
}

// Type sets the optional parameter "type": Required. Name of the
// dataset for which you want to retrieve the schema. For example:
// `fact` or `agg_cus1`
func (c *OrganizationsEnvironmentsAnalyticsAdminGetSchemav2Call) Type(type_ string) *OrganizationsEnvironmentsAnalyticsAdminGetSchemav2Call {
	c.urlParams_.Set("type", type_)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsAnalyticsAdminGetSchemav2Call) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsAnalyticsAdminGetSchemav2Call {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsAnalyticsAdminGetSchemav2Call) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsAnalyticsAdminGetSchemav2Call {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsAnalyticsAdminGetSchemav2Call) Context(ctx context.Context) *OrganizationsEnvironmentsAnalyticsAdminGetSchemav2Call {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsAnalyticsAdminGetSchemav2Call) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsAnalyticsAdminGetSchemav2Call) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.analytics.admin.getSchemav2" call.
// Exactly one of *GoogleCloudApigeeV1Schema or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1Schema.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsAnalyticsAdminGetSchemav2Call) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Schema, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Schema{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets a list of metrics and dimensions that can be used to create analytics queries and reports. Each schema element contains the name of the field, its associated type, and a flag indicating whether it is a standard or custom field.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/analytics/admin/schemav2",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.analytics.admin.getSchemav2",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "disableCache": {
	//       "description": "Flag that specifies whether the schema is be read from the database or cache. Set to `true` to read the schema from the database. Defaults to cache.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "name": {
	//       "description": "Required. Path to the schema. Use the following structure in your request: `organizations/{org}/environments/{env}/analytics/admin/schemav2`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/analytics/admin/schemav2$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "type": {
	//       "description": "Required. Name of the dataset for which you want to retrieve the schema. For example: `fact` or `agg_cus1`",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Schema"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.analytics.exports.create":

type OrganizationsEnvironmentsAnalyticsExportsCreateCall struct {
	s                                *Service
	parent                           string
	googlecloudapigeev1exportrequest *GoogleCloudApigeeV1ExportRequest
	urlParams_                       gensupport.URLParams
	ctx_                             context.Context
	header_                          http.Header
}

// Create: Submit a data export job to be processed in the background.
// If the request is successful, the API returns a 201 status, a URI
// that can be used to retrieve the status of the export job, and the
// `state` value of "enqueued".
//
//   - parent: Names of the parent organization and environment. Must be
//     of the form `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsAnalyticsExportsService) Create(parent string, googlecloudapigeev1exportrequest *GoogleCloudApigeeV1ExportRequest) *OrganizationsEnvironmentsAnalyticsExportsCreateCall {
	c := &OrganizationsEnvironmentsAnalyticsExportsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1exportrequest = googlecloudapigeev1exportrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsAnalyticsExportsCreateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsAnalyticsExportsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsAnalyticsExportsCreateCall) Context(ctx context.Context) *OrganizationsEnvironmentsAnalyticsExportsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsAnalyticsExportsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsAnalyticsExportsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1exportrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/analytics/exports")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.analytics.exports.create" call.
// Exactly one of *GoogleCloudApigeeV1Export or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1Export.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsAnalyticsExportsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Export, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Export{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Submit a data export job to be processed in the background. If the request is successful, the API returns a 201 status, a URI that can be used to retrieve the status of the export job, and the `state` value of \"enqueued\".",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/analytics/exports",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.analytics.exports.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Names of the parent organization and environment. Must be of the form `organizations/{org}/environments/{env}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/analytics/exports",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1ExportRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Export"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.analytics.exports.get":

type OrganizationsEnvironmentsAnalyticsExportsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets the details and status of an analytics export job. If the
// export job is still in progress, its `state` is set to "running".
// After the export job has completed successfully, its `state` is set
// to "completed". If the export job fails, its `state` is set to
// `failed`.
//
// - name: Resource name of the export to get.
func (r *OrganizationsEnvironmentsAnalyticsExportsService) Get(name string) *OrganizationsEnvironmentsAnalyticsExportsGetCall {
	c := &OrganizationsEnvironmentsAnalyticsExportsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsAnalyticsExportsGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsAnalyticsExportsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsAnalyticsExportsGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsAnalyticsExportsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsAnalyticsExportsGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsAnalyticsExportsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsAnalyticsExportsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsAnalyticsExportsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.analytics.exports.get" call.
// Exactly one of *GoogleCloudApigeeV1Export or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1Export.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsAnalyticsExportsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Export, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Export{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the details and status of an analytics export job. If the export job is still in progress, its `state` is set to \"running\". After the export job has completed successfully, its `state` is set to \"completed\". If the export job fails, its `state` is set to `failed`.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/analytics/exports/{exportsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.analytics.exports.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Resource name of the export to get.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/analytics/exports/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Export"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.analytics.exports.list":

type OrganizationsEnvironmentsAnalyticsExportsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists the details and status of all analytics export jobs
// belonging to the parent organization and environment.
//
//   - parent: Names of the parent organization and environment. Must be
//     of the form `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsAnalyticsExportsService) List(parent string) *OrganizationsEnvironmentsAnalyticsExportsListCall {
	c := &OrganizationsEnvironmentsAnalyticsExportsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsAnalyticsExportsListCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsAnalyticsExportsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsAnalyticsExportsListCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsAnalyticsExportsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsAnalyticsExportsListCall) Context(ctx context.Context) *OrganizationsEnvironmentsAnalyticsExportsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsAnalyticsExportsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsAnalyticsExportsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/analytics/exports")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.analytics.exports.list" call.
// Exactly one of *GoogleCloudApigeeV1ListExportsResponse or error will
// be non-nil. Any non-2xx status code is an error. Response headers are
// in either
// *GoogleCloudApigeeV1ListExportsResponse.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsAnalyticsExportsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListExportsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListExportsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists the details and status of all analytics export jobs belonging to the parent organization and environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/analytics/exports",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.analytics.exports.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Names of the parent organization and environment. Must be of the form `organizations/{org}/environments/{env}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/analytics/exports",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListExportsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.apis.deployments.list":

type OrganizationsEnvironmentsApisDeploymentsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all deployments of an API proxy in an environment.
//
//   - parent: Name representing an API proxy in an environment in the
//     following format:
//     `organizations/{org}/environments/{env}/apis/{api}`.
func (r *OrganizationsEnvironmentsApisDeploymentsService) List(parent string) *OrganizationsEnvironmentsApisDeploymentsListCall {
	c := &OrganizationsEnvironmentsApisDeploymentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsApisDeploymentsListCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsApisDeploymentsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsApisDeploymentsListCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsApisDeploymentsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsApisDeploymentsListCall) Context(ctx context.Context) *OrganizationsEnvironmentsApisDeploymentsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsApisDeploymentsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsApisDeploymentsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/deployments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.apis.deployments.list" call.
// Exactly one of *GoogleCloudApigeeV1ListDeploymentsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListDeploymentsResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsApisDeploymentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListDeploymentsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListDeploymentsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all deployments of an API proxy in an environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/apis/{apisId}/deployments",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.apis.deployments.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name representing an API proxy in an environment in the following format: `organizations/{org}/environments/{env}/apis/{api}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/apis/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/deployments",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListDeploymentsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.apis.revisions.deploy":

type OrganizationsEnvironmentsApisRevisionsDeployCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Deploy: Deploys a revision of an API proxy. If another revision of
// the same API proxy revision is currently deployed, set the `override`
// parameter to `true` to have this revision replace the currently
// deployed revision. You cannot invoke an API proxy until it has been
// deployed to an environment. After you deploy an API proxy revision,
// you cannot edit it. To edit the API proxy, you must create and deploy
// a new revision. For a request path
// `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}/dep
// loyments`, two permissions are required: *
// `apigee.deployments.create` on the resource
// `organizations/{org}/environments/{env}` *
// `apigee.proxyrevisions.deploy` on the resource
// `organizations/{org}/apis/{api}/revisions/{rev}`
//
//   - name: Name of the API proxy revision deployment in the following
//     format:
//     `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}`.
func (r *OrganizationsEnvironmentsApisRevisionsService) Deploy(name string) *OrganizationsEnvironmentsApisRevisionsDeployCall {
	c := &OrganizationsEnvironmentsApisRevisionsDeployCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Override sets the optional parameter "override": Flag that specifies
// whether the new deployment replaces other deployed revisions of the
// API proxy in the environment. Set `override` to `true` to replace
// other deployed revisions. By default, `override` is `false` and the
// deployment is rejected if other revisions of the API proxy are
// deployed in the environment.
func (c *OrganizationsEnvironmentsApisRevisionsDeployCall) Override(override bool) *OrganizationsEnvironmentsApisRevisionsDeployCall {
	c.urlParams_.Set("override", fmt.Sprint(override))
	return c
}

// SequencedRollout sets the optional parameter "sequencedRollout": Flag
// that specifies whether to enable sequenced rollout. If set to `true`,
// the routing rules for this deployment and the environment changes to
// add the deployment will be rolled out in a safe order. This reduces
// the risk of downtime that could be caused by changing the environment
// group's routing before the new destination for the affected traffic
// is ready to receive it. This should only be necessary if the new
// deployment will be capturing traffic from another environment under a
// shared environment group or if traffic will be rerouted to a
// different environment due to a base path removal. The
// generateDeployChangeReport API may be used to examine routing changes
// before issuing the deployment request, and its response will indicate
// if a sequenced rollout is recommended for the deployment.
func (c *OrganizationsEnvironmentsApisRevisionsDeployCall) SequencedRollout(sequencedRollout bool) *OrganizationsEnvironmentsApisRevisionsDeployCall {
	c.urlParams_.Set("sequencedRollout", fmt.Sprint(sequencedRollout))
	return c
}

// ServiceAccount sets the optional parameter "serviceAccount": Google
// Cloud IAM service account. The service account represents the
// identity of the deployed proxy, and determines what permissions it
// has. The format must be
// `{ACCOUNT_ID}@{PROJECT}.iam.gserviceaccount.com`.
func (c *OrganizationsEnvironmentsApisRevisionsDeployCall) ServiceAccount(serviceAccount string) *OrganizationsEnvironmentsApisRevisionsDeployCall {
	c.urlParams_.Set("serviceAccount", serviceAccount)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsApisRevisionsDeployCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsApisRevisionsDeployCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsApisRevisionsDeployCall) Context(ctx context.Context) *OrganizationsEnvironmentsApisRevisionsDeployCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsApisRevisionsDeployCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsApisRevisionsDeployCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/deployments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.apis.revisions.deploy" call.
// Exactly one of *GoogleCloudApigeeV1Deployment or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Deployment.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsApisRevisionsDeployCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Deployment, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Deployment{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deploys a revision of an API proxy. If another revision of the same API proxy revision is currently deployed, set the `override` parameter to `true` to have this revision replace the currently deployed revision. You cannot invoke an API proxy until it has been deployed to an environment. After you deploy an API proxy revision, you cannot edit it. To edit the API proxy, you must create and deploy a new revision. For a request path `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}/deployments`, two permissions are required: * `apigee.deployments.create` on the resource `organizations/{org}/environments/{env}` * `apigee.proxyrevisions.deploy` on the resource `organizations/{org}/apis/{api}/revisions/{rev}` ",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/apis/{apisId}/revisions/{revisionsId}/deployments",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.apis.revisions.deploy",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the API proxy revision deployment in the following format: `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/apis/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "override": {
	//       "description": "Flag that specifies whether the new deployment replaces other deployed revisions of the API proxy in the environment. Set `override` to `true` to replace other deployed revisions. By default, `override` is `false` and the deployment is rejected if other revisions of the API proxy are deployed in the environment.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "sequencedRollout": {
	//       "description": "Flag that specifies whether to enable sequenced rollout. If set to `true`, the routing rules for this deployment and the environment changes to add the deployment will be rolled out in a safe order. This reduces the risk of downtime that could be caused by changing the environment group's routing before the new destination for the affected traffic is ready to receive it. This should only be necessary if the new deployment will be capturing traffic from another environment under a shared environment group or if traffic will be rerouted to a different environment due to a base path removal. The generateDeployChangeReport API may be used to examine routing changes before issuing the deployment request, and its response will indicate if a sequenced rollout is recommended for the deployment.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "serviceAccount": {
	//       "description": "Google Cloud IAM service account. The service account represents the identity of the deployed proxy, and determines what permissions it has. The format must be `{ACCOUNT_ID}@{PROJECT}.iam.gserviceaccount.com`.",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}/deployments",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Deployment"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.apis.revisions.getDeployments":

type OrganizationsEnvironmentsApisRevisionsGetDeploymentsCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetDeployments: Gets the deployment of an API proxy revision and
// actual state reported by runtime pods.
//
//   - name: Name representing an API proxy revision in an environment in
//     the following format:
//     `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}`.
func (r *OrganizationsEnvironmentsApisRevisionsService) GetDeployments(name string) *OrganizationsEnvironmentsApisRevisionsGetDeploymentsCall {
	c := &OrganizationsEnvironmentsApisRevisionsGetDeploymentsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsApisRevisionsGetDeploymentsCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsApisRevisionsGetDeploymentsCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsApisRevisionsGetDeploymentsCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsApisRevisionsGetDeploymentsCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsApisRevisionsGetDeploymentsCall) Context(ctx context.Context) *OrganizationsEnvironmentsApisRevisionsGetDeploymentsCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsApisRevisionsGetDeploymentsCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsApisRevisionsGetDeploymentsCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/deployments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.apis.revisions.getDeployments" call.
// Exactly one of *GoogleCloudApigeeV1Deployment or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Deployment.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsApisRevisionsGetDeploymentsCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Deployment, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Deployment{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the deployment of an API proxy revision and actual state reported by runtime pods.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/apis/{apisId}/revisions/{revisionsId}/deployments",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.apis.revisions.getDeployments",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name representing an API proxy revision in an environment in the following format: `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/apis/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}/deployments",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Deployment"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.apis.revisions.undeploy":

type OrganizationsEnvironmentsApisRevisionsUndeployCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Undeploy: Undeploys an API proxy revision from an environment. For a
// request path
// `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}/dep
// loyments`, two permissions are required: *
// `apigee.deployments.delete` on the resource
// `organizations/{org}/environments/{env}` *
// `apigee.proxyrevisions.undeploy` on the resource
// `organizations/{org}/apis/{api}/revisions/{rev}`
//
//   - name: Name of the API proxy revision deployment in the following
//     format:
//     `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}`.
func (r *OrganizationsEnvironmentsApisRevisionsService) Undeploy(name string) *OrganizationsEnvironmentsApisRevisionsUndeployCall {
	c := &OrganizationsEnvironmentsApisRevisionsUndeployCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// SequencedRollout sets the optional parameter "sequencedRollout": Flag
// that specifies whether to enable sequenced rollout. If set to `true`,
// the environment group routing rules corresponding to this deployment
// will be removed before removing the deployment from the runtime. This
// is likely to be a rare use case; it is only needed when the intended
// effect of undeploying this proxy is to cause the traffic it currently
// handles to be rerouted to some other existing proxy in the
// environment group. The GenerateUndeployChangeReport API may be used
// to examine routing changes before issuing the undeployment request,
// and its response will indicate if a sequenced rollout is recommended
// for the undeployment.
func (c *OrganizationsEnvironmentsApisRevisionsUndeployCall) SequencedRollout(sequencedRollout bool) *OrganizationsEnvironmentsApisRevisionsUndeployCall {
	c.urlParams_.Set("sequencedRollout", fmt.Sprint(sequencedRollout))
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsApisRevisionsUndeployCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsApisRevisionsUndeployCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsApisRevisionsUndeployCall) Context(ctx context.Context) *OrganizationsEnvironmentsApisRevisionsUndeployCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsApisRevisionsUndeployCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsApisRevisionsUndeployCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/deployments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.apis.revisions.undeploy" call.
// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsApisRevisionsUndeployCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleProtobufEmpty{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Undeploys an API proxy revision from an environment. For a request path `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}/deployments`, two permissions are required: * `apigee.deployments.delete` on the resource `organizations/{org}/environments/{env}` * `apigee.proxyrevisions.undeploy` on the resource `organizations/{org}/apis/{api}/revisions/{rev}`",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/apis/{apisId}/revisions/{revisionsId}/deployments",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.environments.apis.revisions.undeploy",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the API proxy revision deployment in the following format: `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/apis/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "sequencedRollout": {
	//       "description": "Flag that specifies whether to enable sequenced rollout. If set to `true`, the environment group routing rules corresponding to this deployment will be removed before removing the deployment from the runtime. This is likely to be a rare use case; it is only needed when the intended effect of undeploying this proxy is to cause the traffic it currently handles to be rerouted to some other existing proxy in the environment group. The GenerateUndeployChangeReport API may be used to examine routing changes before issuing the undeployment request, and its response will indicate if a sequenced rollout is recommended for the undeployment.",
	//       "location": "query",
	//       "type": "boolean"
	//     }
	//   },
	//   "path": "v1/{+name}/deployments",
	//   "response": {
	//     "$ref": "GoogleProtobufEmpty"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.apis.revisions.debugsessions.create":

type OrganizationsEnvironmentsApisRevisionsDebugsessionsCreateCall struct {
	s                               *Service
	parent                          string
	googlecloudapigeev1debugsession *GoogleCloudApigeeV1DebugSession
	urlParams_                      gensupport.URLParams
	ctx_                            context.Context
	header_                         http.Header
}

// Create: Creates a debug session for a deployed API Proxy revision.
//
//   - parent: The resource name of the API Proxy revision deployment for
//     which to create the DebugSession. Must be of the form
//     `organizations/{organization}/environments/{environment}/apis/{api}/
//     revisions/{revision}`.
func (r *OrganizationsEnvironmentsApisRevisionsDebugsessionsService) Create(parent string, googlecloudapigeev1debugsession *GoogleCloudApigeeV1DebugSession) *OrganizationsEnvironmentsApisRevisionsDebugsessionsCreateCall {
	c := &OrganizationsEnvironmentsApisRevisionsDebugsessionsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1debugsession = googlecloudapigeev1debugsession
	return c
}

// Timeout sets the optional parameter "timeout": The time in seconds
// after which this DebugSession should end. A timeout specified in
// DebugSession will overwrite this value.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsCreateCall) Timeout(timeout int64) *OrganizationsEnvironmentsApisRevisionsDebugsessionsCreateCall {
	c.urlParams_.Set("timeout", fmt.Sprint(timeout))
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsCreateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsApisRevisionsDebugsessionsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsCreateCall) Context(ctx context.Context) *OrganizationsEnvironmentsApisRevisionsDebugsessionsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1debugsession)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/debugsessions")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.apis.revisions.debugsessions.create" call.
// Exactly one of *GoogleCloudApigeeV1DebugSession or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DebugSession.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DebugSession, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DebugSession{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a debug session for a deployed API Proxy revision.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/apis/{apisId}/revisions/{revisionsId}/debugsessions",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.apis.revisions.debugsessions.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. The resource name of the API Proxy revision deployment for which to create the DebugSession. Must be of the form `organizations/{organization}/environments/{environment}/apis/{api}/revisions/{revision}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/apis/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "timeout": {
	//       "description": "Optional. The time in seconds after which this DebugSession should end. A timeout specified in DebugSession will overwrite this value.",
	//       "format": "int64",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/debugsessions",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1DebugSession"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DebugSession"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.apis.revisions.debugsessions.deleteData":

type OrganizationsEnvironmentsApisRevisionsDebugsessionsDeleteDataCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// DeleteData: Deletes the data from a debug session. This does not
// cancel the debug session or prevent further data from being collected
// if the session is still active in runtime pods.
//
//   - name: The name of the debug session to delete. Must be of the form:
//     `organizations/{organization}/environments/{environment}/apis/{api}/
//     revisions/{revision}/debugsessions/{debugsession}`.
func (r *OrganizationsEnvironmentsApisRevisionsDebugsessionsService) DeleteData(name string) *OrganizationsEnvironmentsApisRevisionsDebugsessionsDeleteDataCall {
	c := &OrganizationsEnvironmentsApisRevisionsDebugsessionsDeleteDataCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsDeleteDataCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsApisRevisionsDebugsessionsDeleteDataCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsDeleteDataCall) Context(ctx context.Context) *OrganizationsEnvironmentsApisRevisionsDebugsessionsDeleteDataCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsDeleteDataCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsDeleteDataCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/data")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.apis.revisions.debugsessions.deleteData" call.
// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsDeleteDataCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleProtobufEmpty{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes the data from a debug session. This does not cancel the debug session or prevent further data from being collected if the session is still active in runtime pods.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/apis/{apisId}/revisions/{revisionsId}/debugsessions/{debugsessionsId}/data",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.environments.apis.revisions.debugsessions.deleteData",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the debug session to delete. Must be of the form: `organizations/{organization}/environments/{environment}/apis/{api}/revisions/{revision}/debugsessions/{debugsession}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/apis/[^/]+/revisions/[^/]+/debugsessions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}/data",
	//   "response": {
	//     "$ref": "GoogleProtobufEmpty"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.apis.revisions.debugsessions.get":

type OrganizationsEnvironmentsApisRevisionsDebugsessionsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Retrieves a debug session.
//
//   - name: The name of the debug session to retrieve. Must be of the
//     form:
//     `organizations/{organization}/environments/{environment}/apis/{api}/
//     revisions/{revision}/debugsessions/{session}`.
func (r *OrganizationsEnvironmentsApisRevisionsDebugsessionsService) Get(name string) *OrganizationsEnvironmentsApisRevisionsDebugsessionsGetCall {
	c := &OrganizationsEnvironmentsApisRevisionsDebugsessionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsApisRevisionsDebugsessionsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsApisRevisionsDebugsessionsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsApisRevisionsDebugsessionsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.apis.revisions.debugsessions.get" call.
// Exactly one of *GoogleCloudApigeeV1DebugSession or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DebugSession.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DebugSession, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DebugSession{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Retrieves a debug session.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/apis/{apisId}/revisions/{revisionsId}/debugsessions/{debugsessionsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.apis.revisions.debugsessions.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the debug session to retrieve. Must be of the form: `organizations/{organization}/environments/{environment}/apis/{api}/revisions/{revision}/debugsessions/{session}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/apis/[^/]+/revisions/[^/]+/debugsessions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DebugSession"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.apis.revisions.debugsessions.list":

type OrganizationsEnvironmentsApisRevisionsDebugsessionsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists debug sessions that are currently active in the given API
// Proxy revision.
//
//   - parent: The name of the API Proxy revision deployment for which to
//     list debug sessions. Must be of the form:
//     `organizations/{organization}/environments/{environment}/apis/{api}/
//     revisions/{revision}`.
func (r *OrganizationsEnvironmentsApisRevisionsDebugsessionsService) List(parent string) *OrganizationsEnvironmentsApisRevisionsDebugsessionsListCall {
	c := &OrganizationsEnvironmentsApisRevisionsDebugsessionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// PageSize sets the optional parameter "pageSize": Maximum number of
// debug sessions to return. The page size defaults to 25.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsListCall) PageSize(pageSize int64) *OrganizationsEnvironmentsApisRevisionsDebugsessionsListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": Page token,
// returned from a previous ListDebugSessions call, that you can use to
// retrieve the next page.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsListCall) PageToken(pageToken string) *OrganizationsEnvironmentsApisRevisionsDebugsessionsListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsListCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsApisRevisionsDebugsessionsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsListCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsApisRevisionsDebugsessionsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsListCall) Context(ctx context.Context) *OrganizationsEnvironmentsApisRevisionsDebugsessionsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/debugsessions")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.apis.revisions.debugsessions.list" call.
// Exactly one of *GoogleCloudApigeeV1ListDebugSessionsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListDebugSessionsResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListDebugSessionsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListDebugSessionsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists debug sessions that are currently active in the given API Proxy revision.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/apis/{apisId}/revisions/{revisionsId}/debugsessions",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.apis.revisions.debugsessions.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "pageSize": {
	//       "description": "Maximum number of debug sessions to return. The page size defaults to 25.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Page token, returned from a previous ListDebugSessions call, that you can use to retrieve the next page.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. The name of the API Proxy revision deployment for which to list debug sessions. Must be of the form: `organizations/{organization}/environments/{environment}/apis/{api}/revisions/{revision}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/apis/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/debugsessions",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListDebugSessionsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListDebugSessionsResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.environments.apis.revisions.debugsessions.data.get":

type OrganizationsEnvironmentsApisRevisionsDebugsessionsDataGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets the debug data from a transaction.
//
//   - name: The name of the debug session transaction. Must be of the
//     form:
//     `organizations/{organization}/environments/{environment}/apis/{api}/
//     revisions/{revision}/debugsessions/{session}/data/{transaction}`.
func (r *OrganizationsEnvironmentsApisRevisionsDebugsessionsDataService) Get(name string) *OrganizationsEnvironmentsApisRevisionsDebugsessionsDataGetCall {
	c := &OrganizationsEnvironmentsApisRevisionsDebugsessionsDataGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsDataGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsApisRevisionsDebugsessionsDataGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsDataGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsApisRevisionsDebugsessionsDataGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsDataGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsApisRevisionsDebugsessionsDataGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsDataGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsDataGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.apis.revisions.debugsessions.data.get" call.
// Exactly one of *GoogleCloudApigeeV1DebugSessionTransaction or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1DebugSessionTransaction.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsApisRevisionsDebugsessionsDataGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DebugSessionTransaction, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DebugSessionTransaction{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the debug data from a transaction.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/apis/{apisId}/revisions/{revisionsId}/debugsessions/{debugsessionsId}/data/{dataId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.apis.revisions.debugsessions.data.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the debug session transaction. Must be of the form: `organizations/{organization}/environments/{environment}/apis/{api}/revisions/{revision}/debugsessions/{session}/data/{transaction}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/apis/[^/]+/revisions/[^/]+/debugsessions/[^/]+/data/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DebugSessionTransaction"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.apis.revisions.deployments.generateDeployChangeReport":

type OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateDeployChangeReportCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// GenerateDeployChangeReport: Generates a report for a dry run analysis
// of a DeployApiProxy request without committing the deployment. In
// addition to the standard validations performed when adding
// deployments, additional analysis will be done to detect possible
// traffic routing changes that would result from this deployment being
// created. Any potential routing conflicts or unsafe changes will be
// reported in the response. This routing analysis is not performed for
// a non-dry-run DeployApiProxy request. For a request path
// `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}/dep
// loyments:generateDeployChangeReport`, two permissions are required: *
// `apigee.deployments.create` on the resource
// `organizations/{org}/environments/{env}` *
// `apigee.proxyrevisions.deploy` on the resource
// `organizations/{org}/apis/{api}/revisions/{rev}`
//
//   - name: Name of the API proxy revision deployment in the following
//     format:
//     `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}`.
func (r *OrganizationsEnvironmentsApisRevisionsDeploymentsService) GenerateDeployChangeReport(name string) *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateDeployChangeReportCall {
	c := &OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateDeployChangeReportCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Override sets the optional parameter "override": Flag that specifies
// whether to force the deployment of the new revision over the
// currently deployed revision by overriding conflict checks.
func (c *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateDeployChangeReportCall) Override(override bool) *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateDeployChangeReportCall {
	c.urlParams_.Set("override", fmt.Sprint(override))
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateDeployChangeReportCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateDeployChangeReportCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateDeployChangeReportCall) Context(ctx context.Context) *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateDeployChangeReportCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateDeployChangeReportCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateDeployChangeReportCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/deployments:generateDeployChangeReport")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.apis.revisions.deployments.generateDeployChangeReport" call.
// Exactly one of *GoogleCloudApigeeV1DeploymentChangeReport or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1DeploymentChangeReport.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateDeployChangeReportCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeploymentChangeReport, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeploymentChangeReport{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Generates a report for a dry run analysis of a DeployApiProxy request without committing the deployment. In addition to the standard validations performed when adding deployments, additional analysis will be done to detect possible traffic routing changes that would result from this deployment being created. Any potential routing conflicts or unsafe changes will be reported in the response. This routing analysis is not performed for a non-dry-run DeployApiProxy request. For a request path `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}/deployments:generateDeployChangeReport`, two permissions are required: * `apigee.deployments.create` on the resource `organizations/{org}/environments/{env}` * `apigee.proxyrevisions.deploy` on the resource `organizations/{org}/apis/{api}/revisions/{rev}`",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/apis/{apisId}/revisions/{revisionsId}/deployments:generateDeployChangeReport",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.apis.revisions.deployments.generateDeployChangeReport",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Name of the API proxy revision deployment in the following format: `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/apis/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "override": {
	//       "description": "Flag that specifies whether to force the deployment of the new revision over the currently deployed revision by overriding conflict checks.",
	//       "location": "query",
	//       "type": "boolean"
	//     }
	//   },
	//   "path": "v1/{+name}/deployments:generateDeployChangeReport",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeploymentChangeReport"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.apis.revisions.deployments.generateUndeployChangeReport":

type OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateUndeployChangeReportCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// GenerateUndeployChangeReport: Generates a report for a dry run
// analysis of an UndeployApiProxy request without committing the
// undeploy. In addition to the standard validations performed when
// removing deployments, additional analysis will be done to detect
// possible traffic routing changes that would result from this
// deployment being removed. Any potential routing conflicts or unsafe
// changes will be reported in the response. This routing analysis is
// not performed for a non-dry-run UndeployApiProxy request. For a
// request path
// `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}/dep
// loyments:generateUndeployChangeReport`, two permissions are required:
// * `apigee.deployments.delete` on the resource
// `organizations/{org}/environments/{env}` *
// `apigee.proxyrevisions.undeploy` on the resource
// `organizations/{org}/apis/{api}/revisions/{rev}`
//
//   - name: Name of the API proxy revision deployment in the following
//     format:
//     `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}`.
func (r *OrganizationsEnvironmentsApisRevisionsDeploymentsService) GenerateUndeployChangeReport(name string) *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateUndeployChangeReportCall {
	c := &OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateUndeployChangeReportCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateUndeployChangeReportCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateUndeployChangeReportCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateUndeployChangeReportCall) Context(ctx context.Context) *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateUndeployChangeReportCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateUndeployChangeReportCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateUndeployChangeReportCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/deployments:generateUndeployChangeReport")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.apis.revisions.deployments.generateUndeployChangeReport" call.
// Exactly one of *GoogleCloudApigeeV1DeploymentChangeReport or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1DeploymentChangeReport.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsApisRevisionsDeploymentsGenerateUndeployChangeReportCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeploymentChangeReport, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeploymentChangeReport{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Generates a report for a dry run analysis of an UndeployApiProxy request without committing the undeploy. In addition to the standard validations performed when removing deployments, additional analysis will be done to detect possible traffic routing changes that would result from this deployment being removed. Any potential routing conflicts or unsafe changes will be reported in the response. This routing analysis is not performed for a non-dry-run UndeployApiProxy request. For a request path `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}/deployments:generateUndeployChangeReport`, two permissions are required: * `apigee.deployments.delete` on the resource `organizations/{org}/environments/{env}` * `apigee.proxyrevisions.undeploy` on the resource `organizations/{org}/apis/{api}/revisions/{rev}`",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/apis/{apisId}/revisions/{revisionsId}/deployments:generateUndeployChangeReport",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.apis.revisions.deployments.generateUndeployChangeReport",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Name of the API proxy revision deployment in the following format: `organizations/{org}/environments/{env}/apis/{api}/revisions/{rev}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/apis/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}/deployments:generateUndeployChangeReport",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeploymentChangeReport"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.archiveDeployments.create":

type OrganizationsEnvironmentsArchiveDeploymentsCreateCall struct {
	s                                    *Service
	parent                               string
	googlecloudapigeev1archivedeployment *GoogleCloudApigeeV1ArchiveDeployment
	urlParams_                           gensupport.URLParams
	ctx_                                 context.Context
	header_                              http.Header
}

// Create: Creates a new ArchiveDeployment.
//
// - parent: The Environment this Archive Deployment will be created in.
func (r *OrganizationsEnvironmentsArchiveDeploymentsService) Create(parent string, googlecloudapigeev1archivedeployment *GoogleCloudApigeeV1ArchiveDeployment) *OrganizationsEnvironmentsArchiveDeploymentsCreateCall {
	c := &OrganizationsEnvironmentsArchiveDeploymentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1archivedeployment = googlecloudapigeev1archivedeployment
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsArchiveDeploymentsCreateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsArchiveDeploymentsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsArchiveDeploymentsCreateCall) Context(ctx context.Context) *OrganizationsEnvironmentsArchiveDeploymentsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsArchiveDeploymentsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsArchiveDeploymentsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1archivedeployment)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/archiveDeployments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.archiveDeployments.create" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsArchiveDeploymentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a new ArchiveDeployment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/archiveDeployments",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.archiveDeployments.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. The Environment this Archive Deployment will be created in.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/archiveDeployments",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1ArchiveDeployment"
	//   },
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.archiveDeployments.delete":

type OrganizationsEnvironmentsArchiveDeploymentsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an archive deployment.
//
//   - name: Name of the Archive Deployment in the following format:
//     `organizations/{org}/environments/{env}/archiveDeployments/{id}`.
func (r *OrganizationsEnvironmentsArchiveDeploymentsService) Delete(name string) *OrganizationsEnvironmentsArchiveDeploymentsDeleteCall {
	c := &OrganizationsEnvironmentsArchiveDeploymentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsArchiveDeploymentsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsArchiveDeploymentsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsArchiveDeploymentsDeleteCall) Context(ctx context.Context) *OrganizationsEnvironmentsArchiveDeploymentsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsArchiveDeploymentsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsArchiveDeploymentsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.archiveDeployments.delete" call.
// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsArchiveDeploymentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleProtobufEmpty{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an archive deployment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/archiveDeployments/{archiveDeploymentsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.environments.archiveDeployments.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the Archive Deployment in the following format: `organizations/{org}/environments/{env}/archiveDeployments/{id}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/archiveDeployments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleProtobufEmpty"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.archiveDeployments.generateDownloadUrl":

type OrganizationsEnvironmentsArchiveDeploymentsGenerateDownloadUrlCall struct {
	s                                             *Service
	name                                          string
	googlecloudapigeev1generatedownloadurlrequest *GoogleCloudApigeeV1GenerateDownloadUrlRequest
	urlParams_                                    gensupport.URLParams
	ctx_                                          context.Context
	header_                                       http.Header
}

// GenerateDownloadUrl: Generates a signed URL for downloading the
// original zip file used to create an Archive Deployment. The URL is
// only valid for a limited period and should be used within minutes
// after generation. Each call returns a new upload URL.
//
// - name: The name of the Archive Deployment you want to download.
func (r *OrganizationsEnvironmentsArchiveDeploymentsService) GenerateDownloadUrl(name string, googlecloudapigeev1generatedownloadurlrequest *GoogleCloudApigeeV1GenerateDownloadUrlRequest) *OrganizationsEnvironmentsArchiveDeploymentsGenerateDownloadUrlCall {
	c := &OrganizationsEnvironmentsArchiveDeploymentsGenerateDownloadUrlCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1generatedownloadurlrequest = googlecloudapigeev1generatedownloadurlrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsArchiveDeploymentsGenerateDownloadUrlCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsArchiveDeploymentsGenerateDownloadUrlCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsArchiveDeploymentsGenerateDownloadUrlCall) Context(ctx context.Context) *OrganizationsEnvironmentsArchiveDeploymentsGenerateDownloadUrlCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsArchiveDeploymentsGenerateDownloadUrlCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsArchiveDeploymentsGenerateDownloadUrlCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1generatedownloadurlrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:generateDownloadUrl")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.archiveDeployments.generateDownloadUrl" call.
// Exactly one of *GoogleCloudApigeeV1GenerateDownloadUrlResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1GenerateDownloadUrlResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsArchiveDeploymentsGenerateDownloadUrlCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1GenerateDownloadUrlResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1GenerateDownloadUrlResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Generates a signed URL for downloading the original zip file used to create an Archive Deployment. The URL is only valid for a limited period and should be used within minutes after generation. Each call returns a new upload URL.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/archiveDeployments/{archiveDeploymentsId}:generateDownloadUrl",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.archiveDeployments.generateDownloadUrl",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the Archive Deployment you want to download.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/archiveDeployments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}:generateDownloadUrl",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1GenerateDownloadUrlRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1GenerateDownloadUrlResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.archiveDeployments.generateUploadUrl":

type OrganizationsEnvironmentsArchiveDeploymentsGenerateUploadUrlCall struct {
	s                                           *Service
	parent                                      string
	googlecloudapigeev1generateuploadurlrequest *GoogleCloudApigeeV1GenerateUploadUrlRequest
	urlParams_                                  gensupport.URLParams
	ctx_                                        context.Context
	header_                                     http.Header
}

// GenerateUploadUrl: Generates a signed URL for uploading an Archive
// zip file to Google Cloud Storage. Once the upload is complete, the
// signed URL should be passed to CreateArchiveDeployment. When
// uploading to the generated signed URL, please follow these
// restrictions: * Source file type should be a zip file. * Source file
// size should not exceed 1GB limit. * No credentials should be attached
// - the signed URLs provide access to the target bucket using internal
// service identity; if credentials were attached, the identity from the
// credentials would be used, but that identity does not have
// permissions to upload files to the URL. When making a HTTP PUT
// request, these two headers need to be specified: * `content-type:
// application/zip` * `x-goog-content-length-range: 0,1073741824` And
// this header SHOULD NOT be specified: * `Authorization: Bearer
// YOUR_TOKEN`
//
// - parent: The organization and environment to upload to.
func (r *OrganizationsEnvironmentsArchiveDeploymentsService) GenerateUploadUrl(parent string, googlecloudapigeev1generateuploadurlrequest *GoogleCloudApigeeV1GenerateUploadUrlRequest) *OrganizationsEnvironmentsArchiveDeploymentsGenerateUploadUrlCall {
	c := &OrganizationsEnvironmentsArchiveDeploymentsGenerateUploadUrlCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1generateuploadurlrequest = googlecloudapigeev1generateuploadurlrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsArchiveDeploymentsGenerateUploadUrlCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsArchiveDeploymentsGenerateUploadUrlCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsArchiveDeploymentsGenerateUploadUrlCall) Context(ctx context.Context) *OrganizationsEnvironmentsArchiveDeploymentsGenerateUploadUrlCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsArchiveDeploymentsGenerateUploadUrlCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsArchiveDeploymentsGenerateUploadUrlCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1generateuploadurlrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/archiveDeployments:generateUploadUrl")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.archiveDeployments.generateUploadUrl" call.
// Exactly one of *GoogleCloudApigeeV1GenerateUploadUrlResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1GenerateUploadUrlResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsArchiveDeploymentsGenerateUploadUrlCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1GenerateUploadUrlResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1GenerateUploadUrlResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Generates a signed URL for uploading an Archive zip file to Google Cloud Storage. Once the upload is complete, the signed URL should be passed to CreateArchiveDeployment. When uploading to the generated signed URL, please follow these restrictions: * Source file type should be a zip file. * Source file size should not exceed 1GB limit. * No credentials should be attached - the signed URLs provide access to the target bucket using internal service identity; if credentials were attached, the identity from the credentials would be used, but that identity does not have permissions to upload files to the URL. When making a HTTP PUT request, these two headers need to be specified: * `content-type: application/zip` * `x-goog-content-length-range: 0,1073741824` And this header SHOULD NOT be specified: * `Authorization: Bearer YOUR_TOKEN`",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/archiveDeployments:generateUploadUrl",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.archiveDeployments.generateUploadUrl",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. The organization and environment to upload to.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/archiveDeployments:generateUploadUrl",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1GenerateUploadUrlRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1GenerateUploadUrlResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.archiveDeployments.get":

type OrganizationsEnvironmentsArchiveDeploymentsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets the specified ArchiveDeployment.
//
//   - name: Name of the Archive Deployment in the following format:
//     `organizations/{org}/environments/{env}/archiveDeployments/{id}`.
func (r *OrganizationsEnvironmentsArchiveDeploymentsService) Get(name string) *OrganizationsEnvironmentsArchiveDeploymentsGetCall {
	c := &OrganizationsEnvironmentsArchiveDeploymentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsArchiveDeploymentsGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsArchiveDeploymentsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsArchiveDeploymentsGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsArchiveDeploymentsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsArchiveDeploymentsGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsArchiveDeploymentsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsArchiveDeploymentsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsArchiveDeploymentsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.archiveDeployments.get" call.
// Exactly one of *GoogleCloudApigeeV1ArchiveDeployment or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1ArchiveDeployment.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsArchiveDeploymentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ArchiveDeployment, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ArchiveDeployment{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the specified ArchiveDeployment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/archiveDeployments/{archiveDeploymentsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.archiveDeployments.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the Archive Deployment in the following format: `organizations/{org}/environments/{env}/archiveDeployments/{id}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/archiveDeployments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ArchiveDeployment"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.archiveDeployments.list":

type OrganizationsEnvironmentsArchiveDeploymentsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists the ArchiveDeployments in the specified Environment.
//
//   - parent: Name of the Environment for which to list Archive
//     Deployments in the format:
//     `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsArchiveDeploymentsService) List(parent string) *OrganizationsEnvironmentsArchiveDeploymentsListCall {
	c := &OrganizationsEnvironmentsArchiveDeploymentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Filter sets the optional parameter "filter": An optional query used
// to return a subset of Archive Deployments using the semantics defined
// in https://google.aip.dev/160.
func (c *OrganizationsEnvironmentsArchiveDeploymentsListCall) Filter(filter string) *OrganizationsEnvironmentsArchiveDeploymentsListCall {
	c.urlParams_.Set("filter", filter)
	return c
}

// PageSize sets the optional parameter "pageSize": Maximum number of
// Archive Deployments to return. If unspecified, at most 25 deployments
// will be returned.
func (c *OrganizationsEnvironmentsArchiveDeploymentsListCall) PageSize(pageSize int64) *OrganizationsEnvironmentsArchiveDeploymentsListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": Page token,
// returned from a previous ListArchiveDeployments call, that you can
// use to retrieve the next page.
func (c *OrganizationsEnvironmentsArchiveDeploymentsListCall) PageToken(pageToken string) *OrganizationsEnvironmentsArchiveDeploymentsListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsArchiveDeploymentsListCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsArchiveDeploymentsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsArchiveDeploymentsListCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsArchiveDeploymentsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsArchiveDeploymentsListCall) Context(ctx context.Context) *OrganizationsEnvironmentsArchiveDeploymentsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsArchiveDeploymentsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsArchiveDeploymentsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/archiveDeployments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.archiveDeployments.list" call.
// Exactly one of *GoogleCloudApigeeV1ListArchiveDeploymentsResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListArchiveDeploymentsResponse.ServerResponse.Head
// er or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsArchiveDeploymentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListArchiveDeploymentsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListArchiveDeploymentsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists the ArchiveDeployments in the specified Environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/archiveDeployments",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.archiveDeployments.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "filter": {
	//       "description": "Optional. An optional query used to return a subset of Archive Deployments using the semantics defined in https://google.aip.dev/160.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "pageSize": {
	//       "description": "Optional. Maximum number of Archive Deployments to return. If unspecified, at most 25 deployments will be returned.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Optional. Page token, returned from a previous ListArchiveDeployments call, that you can use to retrieve the next page.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the Environment for which to list Archive Deployments in the format: `organizations/{org}/environments/{env}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/archiveDeployments",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListArchiveDeploymentsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsEnvironmentsArchiveDeploymentsListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListArchiveDeploymentsResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.environments.archiveDeployments.patch":

type OrganizationsEnvironmentsArchiveDeploymentsPatchCall struct {
	s                                    *Service
	name                                 string
	googlecloudapigeev1archivedeployment *GoogleCloudApigeeV1ArchiveDeployment
	urlParams_                           gensupport.URLParams
	ctx_                                 context.Context
	header_                              http.Header
}

// Patch: Updates an existing ArchiveDeployment. Labels can modified but
// most of the other fields are not modifiable.
//
//   - name: Name of the Archive Deployment in the following format:
//     `organizations/{org}/environments/{env}/archiveDeployments/{id}`.
func (r *OrganizationsEnvironmentsArchiveDeploymentsService) Patch(name string, googlecloudapigeev1archivedeployment *GoogleCloudApigeeV1ArchiveDeployment) *OrganizationsEnvironmentsArchiveDeploymentsPatchCall {
	c := &OrganizationsEnvironmentsArchiveDeploymentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1archivedeployment = googlecloudapigeev1archivedeployment
	return c
}

// UpdateMask sets the optional parameter "updateMask": Required. The
// list of fields to be updated.
func (c *OrganizationsEnvironmentsArchiveDeploymentsPatchCall) UpdateMask(updateMask string) *OrganizationsEnvironmentsArchiveDeploymentsPatchCall {
	c.urlParams_.Set("updateMask", updateMask)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsArchiveDeploymentsPatchCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsArchiveDeploymentsPatchCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsArchiveDeploymentsPatchCall) Context(ctx context.Context) *OrganizationsEnvironmentsArchiveDeploymentsPatchCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsArchiveDeploymentsPatchCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsArchiveDeploymentsPatchCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1archivedeployment)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PATCH", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.archiveDeployments.patch" call.
// Exactly one of *GoogleCloudApigeeV1ArchiveDeployment or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1ArchiveDeployment.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsArchiveDeploymentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ArchiveDeployment, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ArchiveDeployment{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates an existing ArchiveDeployment. Labels can modified but most of the other fields are not modifiable.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/archiveDeployments/{archiveDeploymentsId}",
	//   "httpMethod": "PATCH",
	//   "id": "apigee.organizations.environments.archiveDeployments.patch",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Name of the Archive Deployment in the following format: `organizations/{org}/environments/{env}/archiveDeployments/{id}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/archiveDeployments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "updateMask": {
	//       "description": "Required. The list of fields to be updated.",
	//       "format": "google-fieldmask",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1ArchiveDeployment"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ArchiveDeployment"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.caches.delete":

type OrganizationsEnvironmentsCachesDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a cache.
//
//   - name: Cache resource name of the form:
//     `organizations/{organization_id}/environments/{environment_id}/cache
//     s/{cache_id}`.
func (r *OrganizationsEnvironmentsCachesService) Delete(name string) *OrganizationsEnvironmentsCachesDeleteCall {
	c := &OrganizationsEnvironmentsCachesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsCachesDeleteCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsCachesDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsCachesDeleteCall) Context(ctx context.Context) *OrganizationsEnvironmentsCachesDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsCachesDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsCachesDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.caches.delete" call.
// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsCachesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleProtobufEmpty{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a cache.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/caches/{cachesId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.environments.caches.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Cache resource name of the form: `organizations/{organization_id}/environments/{environment_id}/caches/{cache_id}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/caches/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleProtobufEmpty"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.deployments.list":

type OrganizationsEnvironmentsDeploymentsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all deployments of API proxies or shared flows in an
// environment.
//
//   - parent: Name of the environment for which to return deployment
//     information in the following format:
//     `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsDeploymentsService) List(parent string) *OrganizationsEnvironmentsDeploymentsListCall {
	c := &OrganizationsEnvironmentsDeploymentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// SharedFlows sets the optional parameter "sharedFlows": Flag that
// specifies whether to return shared flow or API proxy deployments. Set
// to `true` to return shared flow deployments; set to `false` to return
// API proxy deployments. Defaults to `false`.
func (c *OrganizationsEnvironmentsDeploymentsListCall) SharedFlows(sharedFlows bool) *OrganizationsEnvironmentsDeploymentsListCall {
	c.urlParams_.Set("sharedFlows", fmt.Sprint(sharedFlows))
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsDeploymentsListCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsDeploymentsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsDeploymentsListCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsDeploymentsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsDeploymentsListCall) Context(ctx context.Context) *OrganizationsEnvironmentsDeploymentsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsDeploymentsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsDeploymentsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/deployments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.deployments.list" call.
// Exactly one of *GoogleCloudApigeeV1ListDeploymentsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListDeploymentsResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsDeploymentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListDeploymentsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListDeploymentsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all deployments of API proxies or shared flows in an environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/deployments",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.deployments.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the environment for which to return deployment information in the following format: `organizations/{org}/environments/{env}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "sharedFlows": {
	//       "description": "Optional. Flag that specifies whether to return shared flow or API proxy deployments. Set to `true` to return shared flow deployments; set to `false` to return API proxy deployments. Defaults to `false`.",
	//       "location": "query",
	//       "type": "boolean"
	//     }
	//   },
	//   "path": "v1/{+parent}/deployments",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListDeploymentsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.flowhooks.attachSharedFlowToFlowHook":

type OrganizationsEnvironmentsFlowhooksAttachSharedFlowToFlowHookCall struct {
	s                           *Service
	name                        string
	googlecloudapigeev1flowhook *GoogleCloudApigeeV1FlowHook
	urlParams_                  gensupport.URLParams
	ctx_                        context.Context
	header_                     http.Header
}

// AttachSharedFlowToFlowHook: Attaches a shared flow to a flow hook.
//
//   - name: Name of the flow hook to which the shared flow should be
//     attached in the following format:
//     `organizations/{org}/environments/{env}/flowhooks/{flowhook}`.
func (r *OrganizationsEnvironmentsFlowhooksService) AttachSharedFlowToFlowHook(name string, googlecloudapigeev1flowhook *GoogleCloudApigeeV1FlowHook) *OrganizationsEnvironmentsFlowhooksAttachSharedFlowToFlowHookCall {
	c := &OrganizationsEnvironmentsFlowhooksAttachSharedFlowToFlowHookCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1flowhook = googlecloudapigeev1flowhook
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsFlowhooksAttachSharedFlowToFlowHookCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsFlowhooksAttachSharedFlowToFlowHookCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsFlowhooksAttachSharedFlowToFlowHookCall) Context(ctx context.Context) *OrganizationsEnvironmentsFlowhooksAttachSharedFlowToFlowHookCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsFlowhooksAttachSharedFlowToFlowHookCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsFlowhooksAttachSharedFlowToFlowHookCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1flowhook)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.flowhooks.attachSharedFlowToFlowHook" call.
// Exactly one of *GoogleCloudApigeeV1FlowHook or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1FlowHook.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsFlowhooksAttachSharedFlowToFlowHookCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1FlowHook, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1FlowHook{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Attaches a shared flow to a flow hook.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/flowhooks/{flowhooksId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.environments.flowhooks.attachSharedFlowToFlowHook",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the flow hook to which the shared flow should be attached in the following format: `organizations/{org}/environments/{env}/flowhooks/{flowhook}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/flowhooks/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1FlowHook"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1FlowHook"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.flowhooks.detachSharedFlowFromFlowHook":

type OrganizationsEnvironmentsFlowhooksDetachSharedFlowFromFlowHookCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// DetachSharedFlowFromFlowHook: Detaches a shared flow from a flow
// hook.
//
//   - name: Name of the flow hook to detach in the following format:
//     `organizations/{org}/environments/{env}/flowhooks/{flowhook}`.
func (r *OrganizationsEnvironmentsFlowhooksService) DetachSharedFlowFromFlowHook(name string) *OrganizationsEnvironmentsFlowhooksDetachSharedFlowFromFlowHookCall {
	c := &OrganizationsEnvironmentsFlowhooksDetachSharedFlowFromFlowHookCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsFlowhooksDetachSharedFlowFromFlowHookCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsFlowhooksDetachSharedFlowFromFlowHookCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsFlowhooksDetachSharedFlowFromFlowHookCall) Context(ctx context.Context) *OrganizationsEnvironmentsFlowhooksDetachSharedFlowFromFlowHookCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsFlowhooksDetachSharedFlowFromFlowHookCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsFlowhooksDetachSharedFlowFromFlowHookCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.flowhooks.detachSharedFlowFromFlowHook" call.
// Exactly one of *GoogleCloudApigeeV1FlowHook or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1FlowHook.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsFlowhooksDetachSharedFlowFromFlowHookCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1FlowHook, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1FlowHook{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Detaches a shared flow from a flow hook.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/flowhooks/{flowhooksId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.environments.flowhooks.detachSharedFlowFromFlowHook",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the flow hook to detach in the following format: `organizations/{org}/environments/{env}/flowhooks/{flowhook}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/flowhooks/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1FlowHook"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.flowhooks.get":

type OrganizationsEnvironmentsFlowhooksGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Returns the name of the shared flow attached to the specified
// flow hook. If there's no shared flow attached to the flow hook, the
// API does not return an error; it simply does not return a name in the
// response.
//
//   - name: Name of the flow hook in the following format:
//     `organizations/{org}/environments/{env}/flowhooks/{flowhook}`.
func (r *OrganizationsEnvironmentsFlowhooksService) Get(name string) *OrganizationsEnvironmentsFlowhooksGetCall {
	c := &OrganizationsEnvironmentsFlowhooksGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsFlowhooksGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsFlowhooksGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsFlowhooksGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsFlowhooksGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsFlowhooksGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsFlowhooksGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsFlowhooksGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsFlowhooksGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.flowhooks.get" call.
// Exactly one of *GoogleCloudApigeeV1FlowHook or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1FlowHook.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsFlowhooksGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1FlowHook, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1FlowHook{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Returns the name of the shared flow attached to the specified flow hook. If there's no shared flow attached to the flow hook, the API does not return an error; it simply does not return a name in the response.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/flowhooks/{flowhooksId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.flowhooks.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the flow hook in the following format: `organizations/{org}/environments/{env}/flowhooks/{flowhook}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/flowhooks/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1FlowHook"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.keystores.create":

type OrganizationsEnvironmentsKeystoresCreateCall struct {
	s                           *Service
	parent                      string
	googlecloudapigeev1keystore *GoogleCloudApigeeV1Keystore
	urlParams_                  gensupport.URLParams
	ctx_                        context.Context
	header_                     http.Header
}

// Create: Creates a keystore or truststore. - Keystore: Contains
// certificates and their associated keys. - Truststore: Contains
// trusted certificates used to validate a server's certificate. These
// certificates are typically self-signed certificates or certificates
// that are not signed by a trusted CA.
//
//   - parent: Name of the environment in which to create the keystore.
//     Use the following format in your request:
//     `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsKeystoresService) Create(parent string, googlecloudapigeev1keystore *GoogleCloudApigeeV1Keystore) *OrganizationsEnvironmentsKeystoresCreateCall {
	c := &OrganizationsEnvironmentsKeystoresCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1keystore = googlecloudapigeev1keystore
	return c
}

// Name sets the optional parameter "name": Name of the keystore.
// Overrides the value in Keystore.
func (c *OrganizationsEnvironmentsKeystoresCreateCall) Name(name string) *OrganizationsEnvironmentsKeystoresCreateCall {
	c.urlParams_.Set("name", name)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsKeystoresCreateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsKeystoresCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsKeystoresCreateCall) Context(ctx context.Context) *OrganizationsEnvironmentsKeystoresCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsKeystoresCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsKeystoresCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1keystore)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/keystores")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.keystores.create" call.
// Exactly one of *GoogleCloudApigeeV1Keystore or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1Keystore.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsKeystoresCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Keystore, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Keystore{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a keystore or truststore. - Keystore: Contains certificates and their associated keys. - Truststore: Contains trusted certificates used to validate a server's certificate. These certificates are typically self-signed certificates or certificates that are not signed by a trusted CA.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/keystores",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.keystores.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Optional. Name of the keystore. Overrides the value in Keystore.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the environment in which to create the keystore. Use the following format in your request: `organizations/{org}/environments/{env}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/keystores",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Keystore"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Keystore"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.keystores.delete":

type OrganizationsEnvironmentsKeystoresDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a keystore or truststore.
//
//   - name: Name of the keystore. Use the following format in your
//     request:
//     `organizations/{org}/environments/{env}/keystores/{keystore}`.
func (r *OrganizationsEnvironmentsKeystoresService) Delete(name string) *OrganizationsEnvironmentsKeystoresDeleteCall {
	c := &OrganizationsEnvironmentsKeystoresDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsKeystoresDeleteCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsKeystoresDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsKeystoresDeleteCall) Context(ctx context.Context) *OrganizationsEnvironmentsKeystoresDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsKeystoresDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsKeystoresDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.keystores.delete" call.
// Exactly one of *GoogleCloudApigeeV1Keystore or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1Keystore.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsKeystoresDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Keystore, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Keystore{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a keystore or truststore.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/keystores/{keystoresId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.environments.keystores.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the keystore. Use the following format in your request: `organizations/{org}/environments/{env}/keystores/{keystore}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/keystores/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Keystore"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.keystores.get":

type OrganizationsEnvironmentsKeystoresGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets a keystore or truststore.
//
//   - name: Name of the keystore. Use the following format in your
//     request:
//     `organizations/{org}/environments/{env}/keystores/{keystore}`.
func (r *OrganizationsEnvironmentsKeystoresService) Get(name string) *OrganizationsEnvironmentsKeystoresGetCall {
	c := &OrganizationsEnvironmentsKeystoresGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsKeystoresGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsKeystoresGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsKeystoresGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsKeystoresGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsKeystoresGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsKeystoresGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsKeystoresGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsKeystoresGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.keystores.get" call.
// Exactly one of *GoogleCloudApigeeV1Keystore or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1Keystore.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsKeystoresGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Keystore, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Keystore{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets a keystore or truststore.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/keystores/{keystoresId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.keystores.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the keystore. Use the following format in your request: `organizations/{org}/environments/{env}/keystores/{keystore}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/keystores/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Keystore"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.keystores.aliases.create":

type OrganizationsEnvironmentsKeystoresAliasesCreateCall struct {
	s                 *Service
	parent            string
	googleapihttpbody *GoogleApiHttpBody
	urlParams_        gensupport.URLParams
	ctx_              context.Context
	header_           http.Header
}

// Create: Creates an alias from a key/certificate pair. The structure
// of the request is controlled by the `format` query parameter: -
// `keycertfile` - Separate PEM-encoded key and certificate files are
// uploaded. Set `Content-Type: multipart/form-data` and include the
// `keyFile`, `certFile`, and `password` (if keys are encrypted) fields
// in the request body. If uploading to a truststore, omit `keyFile`. -
// `pkcs12` - A PKCS12 file is uploaded. Set `Content-Type:
// multipart/form-data`, provide the file in the `file` field, and
// include the `password` field if the file is encrypted in the request
// body. - `selfsignedcert` - A new private key and certificate are
// generated. Set `Content-Type: application/json` and include
// CertificateGenerationSpec in the request body.
//
//   - parent: Name of the keystore. Use the following format in your
//     request:
//     `organizations/{org}/environments/{env}/keystores/{keystore}`.
func (r *OrganizationsEnvironmentsKeystoresAliasesService) Create(parent string, googleapihttpbody *GoogleApiHttpBody) *OrganizationsEnvironmentsKeystoresAliasesCreateCall {
	c := &OrganizationsEnvironmentsKeystoresAliasesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googleapihttpbody = googleapihttpbody
	return c
}

// Password sets the optional parameter "_password": DEPRECATED: For
// improved security, specify the password in the request body instead
// of using the query parameter. To specify the password in the request
// body, set `Content-type: multipart/form-data` part with name
// `password`. Password for the private key file, if required.
func (c *OrganizationsEnvironmentsKeystoresAliasesCreateCall) Password(Password string) *OrganizationsEnvironmentsKeystoresAliasesCreateCall {
	c.urlParams_.Set("_password", Password)
	return c
}

// Alias sets the optional parameter "alias": Alias for the
// key/certificate pair. Values must match the regular expression
// `[\w\s-.]{1,255}`. This must be provided for all formats except
// `selfsignedcert`; self-signed certs may specify the alias in either
// this parameter or the JSON body.
func (c *OrganizationsEnvironmentsKeystoresAliasesCreateCall) Alias(alias string) *OrganizationsEnvironmentsKeystoresAliasesCreateCall {
	c.urlParams_.Set("alias", alias)
	return c
}

// Format sets the optional parameter "format": Required. Format of the
// data. Valid values include: `selfsignedcert`, `keycertfile`, or
// `pkcs12`
func (c *OrganizationsEnvironmentsKeystoresAliasesCreateCall) Format(format string) *OrganizationsEnvironmentsKeystoresAliasesCreateCall {
	c.urlParams_.Set("format", format)
	return c
}

// IgnoreExpiryValidation sets the optional parameter
// "ignoreExpiryValidation": Flag that specifies whether to ignore
// expiry validation. If set to `true`, no expiry validation will be
// performed.
func (c *OrganizationsEnvironmentsKeystoresAliasesCreateCall) IgnoreExpiryValidation(ignoreExpiryValidation bool) *OrganizationsEnvironmentsKeystoresAliasesCreateCall {
	c.urlParams_.Set("ignoreExpiryValidation", fmt.Sprint(ignoreExpiryValidation))
	return c
}

// IgnoreNewlineValidation sets the optional parameter
// "ignoreNewlineValidation": Flag that specifies whether to ignore
// newline validation. If set to `true`, no error is thrown when the
// file contains a certificate chain with no newline between each
// certificate. Defaults to `false`.
func (c *OrganizationsEnvironmentsKeystoresAliasesCreateCall) IgnoreNewlineValidation(ignoreNewlineValidation bool) *OrganizationsEnvironmentsKeystoresAliasesCreateCall {
	c.urlParams_.Set("ignoreNewlineValidation", fmt.Sprint(ignoreNewlineValidation))
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsKeystoresAliasesCreateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsKeystoresAliasesCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsKeystoresAliasesCreateCall) Context(ctx context.Context) *OrganizationsEnvironmentsKeystoresAliasesCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsKeystoresAliasesCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsKeystoresAliasesCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleapihttpbody)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/aliases")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.keystores.aliases.create" call.
// Exactly one of *GoogleCloudApigeeV1Alias or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1Alias.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsKeystoresAliasesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Alias, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Alias{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates an alias from a key/certificate pair. The structure of the request is controlled by the `format` query parameter: - `keycertfile` - Separate PEM-encoded key and certificate files are uploaded. Set `Content-Type: multipart/form-data` and include the `keyFile`, `certFile`, and `password` (if keys are encrypted) fields in the request body. If uploading to a truststore, omit `keyFile`. - `pkcs12` - A PKCS12 file is uploaded. Set `Content-Type: multipart/form-data`, provide the file in the `file` field, and include the `password` field if the file is encrypted in the request body. - `selfsignedcert` - A new private key and certificate are generated. Set `Content-Type: application/json` and include CertificateGenerationSpec in the request body.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/keystores/{keystoresId}/aliases",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.keystores.aliases.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "_password": {
	//       "description": "DEPRECATED: For improved security, specify the password in the request body instead of using the query parameter. To specify the password in the request body, set `Content-type: multipart/form-data` part with name `password`. Password for the private key file, if required.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "alias": {
	//       "description": "Alias for the key/certificate pair. Values must match the regular expression `[\\w\\s-.]{1,255}`. This must be provided for all formats except `selfsignedcert`; self-signed certs may specify the alias in either this parameter or the JSON body.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "format": {
	//       "description": "Required. Format of the data. Valid values include: `selfsignedcert`, `keycertfile`, or `pkcs12`",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "ignoreExpiryValidation": {
	//       "description": "Flag that specifies whether to ignore expiry validation. If set to `true`, no expiry validation will be performed.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "ignoreNewlineValidation": {
	//       "description": "Flag that specifies whether to ignore newline validation. If set to `true`, no error is thrown when the file contains a certificate chain with no newline between each certificate. Defaults to `false`.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the keystore. Use the following format in your request: `organizations/{org}/environments/{env}/keystores/{keystore}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/keystores/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/aliases",
	//   "request": {
	//     "$ref": "GoogleApiHttpBody"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Alias"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.keystores.aliases.csr":

type OrganizationsEnvironmentsKeystoresAliasesCsrCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Csr: Generates a PKCS #10 Certificate Signing Request for the private
// key in an alias.
//
//   - name: Name of the alias. Use the following format in your request:
//     `organizations/{org}/environments/{env}/keystores/{keystore}/aliases
//     /{alias}`.
func (r *OrganizationsEnvironmentsKeystoresAliasesService) Csr(name string) *OrganizationsEnvironmentsKeystoresAliasesCsrCall {
	c := &OrganizationsEnvironmentsKeystoresAliasesCsrCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsKeystoresAliasesCsrCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsKeystoresAliasesCsrCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsKeystoresAliasesCsrCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsKeystoresAliasesCsrCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsKeystoresAliasesCsrCall) Context(ctx context.Context) *OrganizationsEnvironmentsKeystoresAliasesCsrCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsKeystoresAliasesCsrCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsKeystoresAliasesCsrCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/csr")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.keystores.aliases.csr" call.
// Exactly one of *GoogleApiHttpBody or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleApiHttpBody.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsKeystoresAliasesCsrCall) Do(opts ...googleapi.CallOption) (*GoogleApiHttpBody, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleApiHttpBody{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Generates a PKCS #10 Certificate Signing Request for the private key in an alias.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/keystores/{keystoresId}/aliases/{aliasesId}/csr",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.keystores.aliases.csr",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the alias. Use the following format in your request: `organizations/{org}/environments/{env}/keystores/{keystore}/aliases/{alias}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/keystores/[^/]+/aliases/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}/csr",
	//   "response": {
	//     "$ref": "GoogleApiHttpBody"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.keystores.aliases.delete":

type OrganizationsEnvironmentsKeystoresAliasesDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an alias.
//
//   - name: Name of the alias. Use the following format in your request:
//     `organizations/{org}/environments/{env}/keystores/{keystore}/aliases
//     /{alias}`.
func (r *OrganizationsEnvironmentsKeystoresAliasesService) Delete(name string) *OrganizationsEnvironmentsKeystoresAliasesDeleteCall {
	c := &OrganizationsEnvironmentsKeystoresAliasesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsKeystoresAliasesDeleteCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsKeystoresAliasesDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsKeystoresAliasesDeleteCall) Context(ctx context.Context) *OrganizationsEnvironmentsKeystoresAliasesDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsKeystoresAliasesDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsKeystoresAliasesDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.keystores.aliases.delete" call.
// Exactly one of *GoogleCloudApigeeV1Alias or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1Alias.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsKeystoresAliasesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Alias, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Alias{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an alias.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/keystores/{keystoresId}/aliases/{aliasesId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.environments.keystores.aliases.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the alias. Use the following format in your request: `organizations/{org}/environments/{env}/keystores/{keystore}/aliases/{alias}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/keystores/[^/]+/aliases/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Alias"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.keystores.aliases.get":

type OrganizationsEnvironmentsKeystoresAliasesGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets an alias.
//
//   - name: Name of the alias. Use the following format in your request:
//     `organizations/{org}/environments/{env}/keystores/{keystore}/aliases
//     /{alias}`.
func (r *OrganizationsEnvironmentsKeystoresAliasesService) Get(name string) *OrganizationsEnvironmentsKeystoresAliasesGetCall {
	c := &OrganizationsEnvironmentsKeystoresAliasesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsKeystoresAliasesGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsKeystoresAliasesGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsKeystoresAliasesGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsKeystoresAliasesGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsKeystoresAliasesGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsKeystoresAliasesGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsKeystoresAliasesGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsKeystoresAliasesGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.keystores.aliases.get" call.
// Exactly one of *GoogleCloudApigeeV1Alias or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1Alias.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsKeystoresAliasesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Alias, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Alias{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets an alias.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/keystores/{keystoresId}/aliases/{aliasesId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.keystores.aliases.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the alias. Use the following format in your request: `organizations/{org}/environments/{env}/keystores/{keystore}/aliases/{alias}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/keystores/[^/]+/aliases/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Alias"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.keystores.aliases.getCertificate":

type OrganizationsEnvironmentsKeystoresAliasesGetCertificateCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetCertificate: Gets the certificate from an alias in PEM-encoded
// form.
//
//   - name: Name of the alias. Use the following format in your request:
//     `organizations/{org}/environments/{env}/keystores/{keystore}/aliases
//     /{alias}`.
func (r *OrganizationsEnvironmentsKeystoresAliasesService) GetCertificate(name string) *OrganizationsEnvironmentsKeystoresAliasesGetCertificateCall {
	c := &OrganizationsEnvironmentsKeystoresAliasesGetCertificateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsKeystoresAliasesGetCertificateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsKeystoresAliasesGetCertificateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsKeystoresAliasesGetCertificateCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsKeystoresAliasesGetCertificateCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsKeystoresAliasesGetCertificateCall) Context(ctx context.Context) *OrganizationsEnvironmentsKeystoresAliasesGetCertificateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsKeystoresAliasesGetCertificateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsKeystoresAliasesGetCertificateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/certificate")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.keystores.aliases.getCertificate" call.
// Exactly one of *GoogleApiHttpBody or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleApiHttpBody.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsKeystoresAliasesGetCertificateCall) Do(opts ...googleapi.CallOption) (*GoogleApiHttpBody, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleApiHttpBody{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the certificate from an alias in PEM-encoded form.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/keystores/{keystoresId}/aliases/{aliasesId}/certificate",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.keystores.aliases.getCertificate",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the alias. Use the following format in your request: `organizations/{org}/environments/{env}/keystores/{keystore}/aliases/{alias}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/keystores/[^/]+/aliases/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}/certificate",
	//   "response": {
	//     "$ref": "GoogleApiHttpBody"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.keystores.aliases.update":

type OrganizationsEnvironmentsKeystoresAliasesUpdateCall struct {
	s                 *Service
	name              string
	googleapihttpbody *GoogleApiHttpBody
	urlParams_        gensupport.URLParams
	ctx_              context.Context
	header_           http.Header
}

// Update: Updates the certificate in an alias.
//
//   - name: Name of the alias. Use the following format in your request:
//     `organizations/{org}/environments/{env}/keystores/{keystore}/aliases
//     /{alias}`.
func (r *OrganizationsEnvironmentsKeystoresAliasesService) Update(name string, googleapihttpbody *GoogleApiHttpBody) *OrganizationsEnvironmentsKeystoresAliasesUpdateCall {
	c := &OrganizationsEnvironmentsKeystoresAliasesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googleapihttpbody = googleapihttpbody
	return c
}

// IgnoreExpiryValidation sets the optional parameter
// "ignoreExpiryValidation": Required. Flag that specifies whether to
// ignore expiry validation. If set to `true`, no expiry validation will
// be performed.
func (c *OrganizationsEnvironmentsKeystoresAliasesUpdateCall) IgnoreExpiryValidation(ignoreExpiryValidation bool) *OrganizationsEnvironmentsKeystoresAliasesUpdateCall {
	c.urlParams_.Set("ignoreExpiryValidation", fmt.Sprint(ignoreExpiryValidation))
	return c
}

// IgnoreNewlineValidation sets the optional parameter
// "ignoreNewlineValidation": Flag that specifies whether to ignore
// newline validation. If set to `true`, no error is thrown when the
// file contains a certificate chain with no newline between each
// certificate. Defaults to `false`.
func (c *OrganizationsEnvironmentsKeystoresAliasesUpdateCall) IgnoreNewlineValidation(ignoreNewlineValidation bool) *OrganizationsEnvironmentsKeystoresAliasesUpdateCall {
	c.urlParams_.Set("ignoreNewlineValidation", fmt.Sprint(ignoreNewlineValidation))
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsKeystoresAliasesUpdateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsKeystoresAliasesUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsKeystoresAliasesUpdateCall) Context(ctx context.Context) *OrganizationsEnvironmentsKeystoresAliasesUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsKeystoresAliasesUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsKeystoresAliasesUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleapihttpbody)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.keystores.aliases.update" call.
// Exactly one of *GoogleCloudApigeeV1Alias or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1Alias.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsKeystoresAliasesUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Alias, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Alias{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates the certificate in an alias.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/keystores/{keystoresId}/aliases/{aliasesId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.environments.keystores.aliases.update",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "ignoreExpiryValidation": {
	//       "description": "Required. Flag that specifies whether to ignore expiry validation. If set to `true`, no expiry validation will be performed.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "ignoreNewlineValidation": {
	//       "description": "Flag that specifies whether to ignore newline validation. If set to `true`, no error is thrown when the file contains a certificate chain with no newline between each certificate. Defaults to `false`.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "name": {
	//       "description": "Required. Name of the alias. Use the following format in your request: `organizations/{org}/environments/{env}/keystores/{keystore}/aliases/{alias}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/keystores/[^/]+/aliases/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleApiHttpBody"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Alias"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.keyvaluemaps.create":

type OrganizationsEnvironmentsKeyvaluemapsCreateCall struct {
	s                              *Service
	parent                         string
	googlecloudapigeev1keyvaluemap *GoogleCloudApigeeV1KeyValueMap
	urlParams_                     gensupport.URLParams
	ctx_                           context.Context
	header_                        http.Header
}

// Create: Creates a key value map in an environment.
//
//   - parent: Name of the environment in which to create the key value
//     map. Use the following structure in your request:
//     `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsKeyvaluemapsService) Create(parent string, googlecloudapigeev1keyvaluemap *GoogleCloudApigeeV1KeyValueMap) *OrganizationsEnvironmentsKeyvaluemapsCreateCall {
	c := &OrganizationsEnvironmentsKeyvaluemapsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1keyvaluemap = googlecloudapigeev1keyvaluemap
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsKeyvaluemapsCreateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsKeyvaluemapsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsKeyvaluemapsCreateCall) Context(ctx context.Context) *OrganizationsEnvironmentsKeyvaluemapsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsKeyvaluemapsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsKeyvaluemapsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1keyvaluemap)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/keyvaluemaps")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.keyvaluemaps.create" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueMap or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueMap.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsKeyvaluemapsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueMap, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueMap{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a key value map in an environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/keyvaluemaps",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.keyvaluemaps.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the environment in which to create the key value map. Use the following structure in your request: `organizations/{org}/environments/{env}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/keyvaluemaps",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueMap"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueMap"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.keyvaluemaps.delete":

type OrganizationsEnvironmentsKeyvaluemapsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a key value map from an environment.
//
//   - name: Name of the key value map. Use the following structure in
//     your request:
//     `organizations/{org}/environments/{env}/keyvaluemaps/{keyvaluemap}`.
func (r *OrganizationsEnvironmentsKeyvaluemapsService) Delete(name string) *OrganizationsEnvironmentsKeyvaluemapsDeleteCall {
	c := &OrganizationsEnvironmentsKeyvaluemapsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsKeyvaluemapsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsKeyvaluemapsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsKeyvaluemapsDeleteCall) Context(ctx context.Context) *OrganizationsEnvironmentsKeyvaluemapsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsKeyvaluemapsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsKeyvaluemapsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.keyvaluemaps.delete" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueMap or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueMap.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsKeyvaluemapsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueMap, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueMap{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a key value map from an environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/keyvaluemaps/{keyvaluemapsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.environments.keyvaluemaps.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the key value map. Use the following structure in your request: `organizations/{org}/environments/{env}/keyvaluemaps/{keyvaluemap}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/keyvaluemaps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueMap"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.keyvaluemaps.entries.create":

type OrganizationsEnvironmentsKeyvaluemapsEntriesCreateCall struct {
	s                                *Service
	parent                           string
	googlecloudapigeev1keyvalueentry *GoogleCloudApigeeV1KeyValueEntry
	urlParams_                       gensupport.URLParams
	ctx_                             context.Context
	header_                          http.Header
}

// Create: Creates key value entries in a key value map scoped to an
// organization, environment, or API proxy. **Note**: Supported for
// Apigee hybrid 1.8.x and higher.
//
//   - parent: Scope as indicated by the URI in which to create the key
//     value map entry. Use **one** of the following structures in your
//     request: *
//     `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`
//     . *
//     `organizations/{organization}/environments/{environment}/keyvaluemap
//     s/{keyvaluemap}` *
//     `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.
func (r *OrganizationsEnvironmentsKeyvaluemapsEntriesService) Create(parent string, googlecloudapigeev1keyvalueentry *GoogleCloudApigeeV1KeyValueEntry) *OrganizationsEnvironmentsKeyvaluemapsEntriesCreateCall {
	c := &OrganizationsEnvironmentsKeyvaluemapsEntriesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1keyvalueentry = googlecloudapigeev1keyvalueentry
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesCreateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsKeyvaluemapsEntriesCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesCreateCall) Context(ctx context.Context) *OrganizationsEnvironmentsKeyvaluemapsEntriesCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1keyvalueentry)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/entries")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.keyvaluemaps.entries.create" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueEntry or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueEntry.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueEntry, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueEntry{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates key value entries in a key value map scoped to an organization, environment, or API proxy. **Note**: Supported for Apigee hybrid 1.8.x and higher.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/keyvaluemaps/{keyvaluemapsId}/entries",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.keyvaluemaps.entries.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Scope as indicated by the URI in which to create the key value map entry. Use **one** of the following structures in your request: * `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`. * `organizations/{organization}/environments/{environment}/keyvaluemaps/{keyvaluemap}` * `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/keyvaluemaps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/entries",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.keyvaluemaps.entries.delete":

type OrganizationsEnvironmentsKeyvaluemapsEntriesDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a key value entry from a key value map scoped to an
// organization, environment, or API proxy. **Notes:** * After you
// delete the key value entry, the policy consuming the entry will
// continue to function with its cached values for a few minutes. This
// is expected behavior. * Supported for Apigee hybrid 1.8.x and higher.
//
//   - name: Scope as indicated by the URI in which to delete the key
//     value map entry. Use **one** of the following structures in your
//     request: *
//     `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}/
//     entries/{entry}`. *
//     `organizations/{organization}/environments/{environment}/keyvaluemap
//     s/{keyvaluemap}/entries/{entry}` *
//     `organizations/{organization}/keyvaluemaps/{keyvaluemap}/entries/{en
//     try}`.
func (r *OrganizationsEnvironmentsKeyvaluemapsEntriesService) Delete(name string) *OrganizationsEnvironmentsKeyvaluemapsEntriesDeleteCall {
	c := &OrganizationsEnvironmentsKeyvaluemapsEntriesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesDeleteCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsKeyvaluemapsEntriesDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesDeleteCall) Context(ctx context.Context) *OrganizationsEnvironmentsKeyvaluemapsEntriesDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.keyvaluemaps.entries.delete" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueEntry or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueEntry.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueEntry, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueEntry{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a key value entry from a key value map scoped to an organization, environment, or API proxy. **Notes:** * After you delete the key value entry, the policy consuming the entry will continue to function with its cached values for a few minutes. This is expected behavior. * Supported for Apigee hybrid 1.8.x and higher.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/keyvaluemaps/{keyvaluemapsId}/entries/{entriesId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.environments.keyvaluemaps.entries.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Scope as indicated by the URI in which to delete the key value map entry. Use **one** of the following structures in your request: * `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}/entries/{entry}`. * `organizations/{organization}/environments/{environment}/keyvaluemaps/{keyvaluemap}/entries/{entry}` * `organizations/{organization}/keyvaluemaps/{keyvaluemap}/entries/{entry}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/keyvaluemaps/[^/]+/entries/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.keyvaluemaps.entries.get":

type OrganizationsEnvironmentsKeyvaluemapsEntriesGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Get the key value entry value for a key value map scoped to an
// organization, environment, or API proxy. **Note**: Supported for
// Apigee hybrid 1.8.x and higher.
//
//   - name: Scope as indicated by the URI in which to fetch the key value
//     map entry/value. Use **one** of the following structures in your
//     request: *
//     `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}/
//     entries/{entry}`. *
//     `organizations/{organization}/environments/{environment}/keyvaluemap
//     s/{keyvaluemap}/entries/{entry}` *
//     `organizations/{organization}/keyvaluemaps/{keyvaluemap}/entries/{en
//     try}`.
func (r *OrganizationsEnvironmentsKeyvaluemapsEntriesService) Get(name string) *OrganizationsEnvironmentsKeyvaluemapsEntriesGetCall {
	c := &OrganizationsEnvironmentsKeyvaluemapsEntriesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsKeyvaluemapsEntriesGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsKeyvaluemapsEntriesGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsKeyvaluemapsEntriesGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.keyvaluemaps.entries.get" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueEntry or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueEntry.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueEntry, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueEntry{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Get the key value entry value for a key value map scoped to an organization, environment, or API proxy. **Note**: Supported for Apigee hybrid 1.8.x and higher.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/keyvaluemaps/{keyvaluemapsId}/entries/{entriesId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.keyvaluemaps.entries.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Scope as indicated by the URI in which to fetch the key value map entry/value. Use **one** of the following structures in your request: * `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}/entries/{entry}`. * `organizations/{organization}/environments/{environment}/keyvaluemaps/{keyvaluemap}/entries/{entry}` * `organizations/{organization}/keyvaluemaps/{keyvaluemap}/entries/{entry}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/keyvaluemaps/[^/]+/entries/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.keyvaluemaps.entries.list":

type OrganizationsEnvironmentsKeyvaluemapsEntriesListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists key value entries for key values maps scoped to an
// organization, environment, or API proxy. **Note**: Supported for
// Apigee hybrid 1.8.x and higher.
//
//   - parent: Scope as indicated by the URI in which to list key value
//     maps. Use **one** of the following structures in your request: *
//     `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`
//     . *
//     `organizations/{organization}/environments/{environment}/keyvaluemap
//     s/{keyvaluemap}` *
//     `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.
func (r *OrganizationsEnvironmentsKeyvaluemapsEntriesService) List(parent string) *OrganizationsEnvironmentsKeyvaluemapsEntriesListCall {
	c := &OrganizationsEnvironmentsKeyvaluemapsEntriesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// PageSize sets the optional parameter "pageSize": Maximum number of
// key value entries to return. If unspecified, at most 100 entries will
// be returned.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesListCall) PageSize(pageSize int64) *OrganizationsEnvironmentsKeyvaluemapsEntriesListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": Page token. If
// provides, must be a valid key value entry returned from a previous
// call that can be used to retrieve the next page.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesListCall) PageToken(pageToken string) *OrganizationsEnvironmentsKeyvaluemapsEntriesListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesListCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsKeyvaluemapsEntriesListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesListCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsKeyvaluemapsEntriesListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesListCall) Context(ctx context.Context) *OrganizationsEnvironmentsKeyvaluemapsEntriesListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/entries")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.keyvaluemaps.entries.list" call.
// Exactly one of *GoogleCloudApigeeV1ListKeyValueEntriesResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListKeyValueEntriesResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListKeyValueEntriesResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListKeyValueEntriesResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists key value entries for key values maps scoped to an organization, environment, or API proxy. **Note**: Supported for Apigee hybrid 1.8.x and higher.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/keyvaluemaps/{keyvaluemapsId}/entries",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.keyvaluemaps.entries.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "pageSize": {
	//       "description": "Optional. Maximum number of key value entries to return. If unspecified, at most 100 entries will be returned.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Optional. Page token. If provides, must be a valid key value entry returned from a previous call that can be used to retrieve the next page.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Scope as indicated by the URI in which to list key value maps. Use **one** of the following structures in your request: * `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`. * `organizations/{organization}/environments/{environment}/keyvaluemaps/{keyvaluemap}` * `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/keyvaluemaps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/entries",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListKeyValueEntriesResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListKeyValueEntriesResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.environments.keyvaluemaps.entries.update":

type OrganizationsEnvironmentsKeyvaluemapsEntriesUpdateCall struct {
	s                                *Service
	name                             string
	googlecloudapigeev1keyvalueentry *GoogleCloudApigeeV1KeyValueEntry
	urlParams_                       gensupport.URLParams
	ctx_                             context.Context
	header_                          http.Header
}

// Update: Update key value entry scoped to an organization,
// environment, or API proxy for an existing key.
//
//   - name: Scope as indicated by the URI in which to create the key
//     value map entry. Use **one** of the following structures in your
//     request: *
//     `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`
//     . *
//     `organizations/{organization}/environments/{environment}/keyvaluemap
//     s/{keyvaluemap}` *
//     `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.
func (r *OrganizationsEnvironmentsKeyvaluemapsEntriesService) Update(name string, googlecloudapigeev1keyvalueentry *GoogleCloudApigeeV1KeyValueEntry) *OrganizationsEnvironmentsKeyvaluemapsEntriesUpdateCall {
	c := &OrganizationsEnvironmentsKeyvaluemapsEntriesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1keyvalueentry = googlecloudapigeev1keyvalueentry
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesUpdateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsKeyvaluemapsEntriesUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesUpdateCall) Context(ctx context.Context) *OrganizationsEnvironmentsKeyvaluemapsEntriesUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1keyvalueentry)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.keyvaluemaps.entries.update" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueEntry or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueEntry.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsKeyvaluemapsEntriesUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueEntry, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueEntry{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Update key value entry scoped to an organization, environment, or API proxy for an existing key.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/keyvaluemaps/{keyvaluemapsId}/entries/{entriesId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.environments.keyvaluemaps.entries.update",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Scope as indicated by the URI in which to create the key value map entry. Use **one** of the following structures in your request: * `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`. * `organizations/{organization}/environments/{environment}/keyvaluemaps/{keyvaluemap}` * `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/keyvaluemaps/[^/]+/entries/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.optimizedStats.get":

type OrganizationsEnvironmentsOptimizedStatsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Similar to GetStats except that the response is less verbose.
//
//   - name: Resource name for which the interactive query will be
//     executed. Use the following format in your request:
//     `organizations/{org}/environments/{env}/optimizedStats/{dimensions}`
//     Dimensions let you view metrics in meaningful groupings, such as
//     `apiproxy`, `target_host`. The value of `dimensions` should be a
//     comma-separated list as shown below:
//     `organizations/{org}/environments/{env}/optimizedStats/apiproxy,requ
//     est_verb`.
func (r *OrganizationsEnvironmentsOptimizedStatsService) Get(name string) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c := &OrganizationsEnvironmentsOptimizedStatsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Accuracy sets the optional parameter "accuracy": No longer used by
// Apigee. Supported for backwards compatibility.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) Accuracy(accuracy string) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.urlParams_.Set("accuracy", accuracy)
	return c
}

// AggTable sets the optional parameter "aggTable": Table name used to
// query custom aggregate tables. If this parameter is skipped, then
// Apigee will try to retrieve the data from fact tables which will be
// expensive.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) AggTable(aggTable string) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.urlParams_.Set("aggTable", aggTable)
	return c
}

// Filter sets the optional parameter "filter": Filter that enables you
// to drill-down on specific dimension values.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) Filter(filter string) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.urlParams_.Set("filter", filter)
	return c
}

// Limit sets the optional parameter "limit": Maximum number of result
// items to return. The default and maximum value that can be returned
// is 14400.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) Limit(limit string) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.urlParams_.Set("limit", limit)
	return c
}

// Offset sets the optional parameter "offset": Offset value. Use
// `offset` with `limit` to enable pagination of results. For example,
// to display results 11-20, set limit to `10` and offset to `10`.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) Offset(offset string) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.urlParams_.Set("offset", offset)
	return c
}

// Realtime sets the optional parameter "realtime": No longer used by
// Apigee. Supported for backwards compatibility.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) Realtime(realtime bool) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.urlParams_.Set("realtime", fmt.Sprint(realtime))
	return c
}

// Select sets the optional parameter "select": Required.
// Comma-separated list of metrics. For example:
// `sum(message_count),sum(error_count)`
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) Select(select_ string) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.urlParams_.Set("select", select_)
	return c
}

// Sonar sets the optional parameter "sonar": Routes the query to API
// Monitoring for the last hour.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) Sonar(sonar bool) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.urlParams_.Set("sonar", fmt.Sprint(sonar))
	return c
}

// Sort sets the optional parameter "sort": Flag that specifies whether
// the sort order should be ascending or descending. Valid values
// include `DESC` and `ASC`.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) Sort(sort string) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.urlParams_.Set("sort", sort)
	return c
}

// Sortby sets the optional parameter "sortby": Comma-separated list of
// columns to sort the final result.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) Sortby(sortby string) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.urlParams_.Set("sortby", sortby)
	return c
}

// TimeRange sets the optional parameter "timeRange": Required. Time
// interval for the interactive query. Time range is specified in GMT as
// `start~end`. For example: `04/15/2017 00:00~05/15/2017 23:59`
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) TimeRange(timeRange string) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.urlParams_.Set("timeRange", timeRange)
	return c
}

// TimeUnit sets the optional parameter "timeUnit": Granularity of
// metrics returned. Valid values include: `second`, `minute`, `hour`,
// `day`, `week`, or `month`.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) TimeUnit(timeUnit string) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.urlParams_.Set("timeUnit", timeUnit)
	return c
}

// Topk sets the optional parameter "topk": Top number of results to
// return. For example, to return the top 5 results, set `topk=5`.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) Topk(topk string) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.urlParams_.Set("topk", topk)
	return c
}

// TsAscending sets the optional parameter "tsAscending": Flag that
// specifies whether to list timestamps in ascending (`true`) or
// descending (`false`) order. Apigee recommends setting this value to
// `true` if you are using `sortby` with `sort=DESC`.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) TsAscending(tsAscending bool) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.urlParams_.Set("tsAscending", fmt.Sprint(tsAscending))
	return c
}

// Tzo sets the optional parameter "tzo": Timezone offset value.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) Tzo(tzo string) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.urlParams_.Set("tzo", tzo)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsOptimizedStatsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.optimizedStats.get" call.
// Exactly one of *GoogleCloudApigeeV1OptimizedStats or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1OptimizedStats.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsOptimizedStatsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1OptimizedStats, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1OptimizedStats{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Similar to GetStats except that the response is less verbose.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/optimizedStats/{optimizedStatsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.optimizedStats.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "accuracy": {
	//       "description": "No longer used by Apigee. Supported for backwards compatibility.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "aggTable": {
	//       "description": "Table name used to query custom aggregate tables. If this parameter is skipped, then Apigee will try to retrieve the data from fact tables which will be expensive.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "filter": {
	//       "description": "Filter that enables you to drill-down on specific dimension values.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "limit": {
	//       "description": "Maximum number of result items to return. The default and maximum value that can be returned is 14400.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "Required. Resource name for which the interactive query will be executed. Use the following format in your request: `organizations/{org}/environments/{env}/optimizedStats/{dimensions}` Dimensions let you view metrics in meaningful groupings, such as `apiproxy`, `target_host`. The value of `dimensions` should be a comma-separated list as shown below: `organizations/{org}/environments/{env}/optimizedStats/apiproxy,request_verb`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/optimizedStats/.*$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "offset": {
	//       "description": "Offset value. Use `offset` with `limit` to enable pagination of results. For example, to display results 11-20, set limit to `10` and offset to `10`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "realtime": {
	//       "description": "No longer used by Apigee. Supported for backwards compatibility.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "select": {
	//       "description": "Required. Comma-separated list of metrics. For example: `sum(message_count),sum(error_count)`",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "sonar": {
	//       "description": "Routes the query to API Monitoring for the last hour.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "sort": {
	//       "description": "Flag that specifies whether the sort order should be ascending or descending. Valid values include `DESC` and `ASC`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "sortby": {
	//       "description": "Comma-separated list of columns to sort the final result.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "timeRange": {
	//       "description": "Required. Time interval for the interactive query. Time range is specified in GMT as `start~end`. For example: `04/15/2017 00:00~05/15/2017 23:59`",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "timeUnit": {
	//       "description": "Granularity of metrics returned. Valid values include: `second`, `minute`, `hour`, `day`, `week`, or `month`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "topk": {
	//       "description": "Top number of results to return. For example, to return the top 5 results, set `topk=5`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "tsAscending": {
	//       "description": "Flag that specifies whether to list timestamps in ascending (`true`) or descending (`false`) order. Apigee recommends setting this value to `true` if you are using `sortby` with `sort=DESC`.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "tzo": {
	//       "description": "Timezone offset value.",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1OptimizedStats"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.queries.create":

type OrganizationsEnvironmentsQueriesCreateCall struct {
	s                        *Service
	parent                   string
	googlecloudapigeev1query *GoogleCloudApigeeV1Query
	urlParams_               gensupport.URLParams
	ctx_                     context.Context
	header_                  http.Header
}

// Create: Submit a query to be processed in the background. If the
// submission of the query succeeds, the API returns a 201 status and an
// ID that refer to the query. In addition to the HTTP status 201, the
// `state` of "enqueued" means that the request succeeded.
//
//   - parent: The parent resource name. Must be of the form
//     `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsQueriesService) Create(parent string, googlecloudapigeev1query *GoogleCloudApigeeV1Query) *OrganizationsEnvironmentsQueriesCreateCall {
	c := &OrganizationsEnvironmentsQueriesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1query = googlecloudapigeev1query
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsQueriesCreateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsQueriesCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsQueriesCreateCall) Context(ctx context.Context) *OrganizationsEnvironmentsQueriesCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsQueriesCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsQueriesCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1query)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/queries")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.queries.create" call.
// Exactly one of *GoogleCloudApigeeV1AsyncQuery or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1AsyncQuery.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsQueriesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AsyncQuery, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AsyncQuery{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Submit a query to be processed in the background. If the submission of the query succeeds, the API returns a 201 status and an ID that refer to the query. In addition to the HTTP status 201, the `state` of \"enqueued\" means that the request succeeded.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/queries",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.queries.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. The parent resource name. Must be of the form `organizations/{org}/environments/{env}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/queries",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Query"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AsyncQuery"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.queries.get":

type OrganizationsEnvironmentsQueriesGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Get query status If the query is still in progress, the `state`
// is set to "running" After the query has completed successfully,
// `state` is set to "completed"
//
//   - name: Name of the asynchronous query to get. Must be of the form
//     `organizations/{org}/environments/{env}/queries/{queryId}`.
func (r *OrganizationsEnvironmentsQueriesService) Get(name string) *OrganizationsEnvironmentsQueriesGetCall {
	c := &OrganizationsEnvironmentsQueriesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsQueriesGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsQueriesGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsQueriesGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsQueriesGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsQueriesGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsQueriesGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsQueriesGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsQueriesGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.queries.get" call.
// Exactly one of *GoogleCloudApigeeV1AsyncQuery or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1AsyncQuery.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsQueriesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AsyncQuery, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AsyncQuery{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Get query status If the query is still in progress, the `state` is set to \"running\" After the query has completed successfully, `state` is set to \"completed\"",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/queries/{queriesId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.queries.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the asynchronous query to get. Must be of the form `organizations/{org}/environments/{env}/queries/{queryId}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/queries/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AsyncQuery"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.queries.getResult":

type OrganizationsEnvironmentsQueriesGetResultCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetResult: After the query is completed, use this API to retrieve the
// results. If the request succeeds, and there is a non-zero result set,
// the result is downloaded to the client as a zipped JSON file. The
// name of the downloaded file will be: OfflineQueryResult-.zip Example:
// `OfflineQueryResult-9cfc0d85-0f30-46d6-ae6f-318d0cb961bd.zip`
//
//   - name: Name of the asynchronous query result to get. Must be of the
//     form
//     `organizations/{org}/environments/{env}/queries/{queryId}/result`.
func (r *OrganizationsEnvironmentsQueriesService) GetResult(name string) *OrganizationsEnvironmentsQueriesGetResultCall {
	c := &OrganizationsEnvironmentsQueriesGetResultCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsQueriesGetResultCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsQueriesGetResultCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsQueriesGetResultCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsQueriesGetResultCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsQueriesGetResultCall) Context(ctx context.Context) *OrganizationsEnvironmentsQueriesGetResultCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsQueriesGetResultCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsQueriesGetResultCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.queries.getResult" call.
// Exactly one of *GoogleApiHttpBody or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleApiHttpBody.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsQueriesGetResultCall) Do(opts ...googleapi.CallOption) (*GoogleApiHttpBody, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleApiHttpBody{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "After the query is completed, use this API to retrieve the results. If the request succeeds, and there is a non-zero result set, the result is downloaded to the client as a zipped JSON file. The name of the downloaded file will be: OfflineQueryResult-.zip Example: `OfflineQueryResult-9cfc0d85-0f30-46d6-ae6f-318d0cb961bd.zip`",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/queries/{queriesId}/result",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.queries.getResult",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the asynchronous query result to get. Must be of the form `organizations/{org}/environments/{env}/queries/{queryId}/result`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/queries/[^/]+/result$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleApiHttpBody"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.queries.getResulturl":

type OrganizationsEnvironmentsQueriesGetResulturlCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetResulturl: After the query is completed, use this API to retrieve
// the results. If the request succeeds, and there is a non-zero result
// set, the result is sent to the client as a list of urls to JSON
// files.
//
//   - name: Name of the asynchronous query result to get. Must be of the
//     form
//     `organizations/{org}/environments/{env}/queries/{queryId}/resulturl`
//     .
func (r *OrganizationsEnvironmentsQueriesService) GetResulturl(name string) *OrganizationsEnvironmentsQueriesGetResulturlCall {
	c := &OrganizationsEnvironmentsQueriesGetResulturlCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsQueriesGetResulturlCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsQueriesGetResulturlCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsQueriesGetResulturlCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsQueriesGetResulturlCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsQueriesGetResulturlCall) Context(ctx context.Context) *OrganizationsEnvironmentsQueriesGetResulturlCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsQueriesGetResulturlCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsQueriesGetResulturlCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.queries.getResulturl" call.
// Exactly one of *GoogleCloudApigeeV1GetAsyncQueryResultUrlResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1GetAsyncQueryResultUrlResponse.ServerResponse.Head
// er or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsQueriesGetResulturlCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1GetAsyncQueryResultUrlResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1GetAsyncQueryResultUrlResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "After the query is completed, use this API to retrieve the results. If the request succeeds, and there is a non-zero result set, the result is sent to the client as a list of urls to JSON files.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/queries/{queriesId}/resulturl",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.queries.getResulturl",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the asynchronous query result to get. Must be of the form `organizations/{org}/environments/{env}/queries/{queryId}/resulturl`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/queries/[^/]+/resulturl$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1GetAsyncQueryResultUrlResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.queries.list":

type OrganizationsEnvironmentsQueriesListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Return a list of Asynchronous Queries
//
//   - parent: The parent resource name. Must be of the form
//     `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsQueriesService) List(parent string) *OrganizationsEnvironmentsQueriesListCall {
	c := &OrganizationsEnvironmentsQueriesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Dataset sets the optional parameter "dataset": Filter response list
// by dataset. Example: `api`, `mint`
func (c *OrganizationsEnvironmentsQueriesListCall) Dataset(dataset string) *OrganizationsEnvironmentsQueriesListCall {
	c.urlParams_.Set("dataset", dataset)
	return c
}

// From sets the optional parameter "from": Filter response list by
// returning asynchronous queries that created after this date time.
// Time must be in ISO date-time format like '2011-12-03T10:15:30Z'.
func (c *OrganizationsEnvironmentsQueriesListCall) From(from string) *OrganizationsEnvironmentsQueriesListCall {
	c.urlParams_.Set("from", from)
	return c
}

// InclQueriesWithoutReport sets the optional parameter
// "inclQueriesWithoutReport": Flag to include asynchronous queries that
// don't have a report denifition.
func (c *OrganizationsEnvironmentsQueriesListCall) InclQueriesWithoutReport(inclQueriesWithoutReport string) *OrganizationsEnvironmentsQueriesListCall {
	c.urlParams_.Set("inclQueriesWithoutReport", inclQueriesWithoutReport)
	return c
}

// Status sets the optional parameter "status": Filter response list by
// asynchronous query status.
func (c *OrganizationsEnvironmentsQueriesListCall) Status(status string) *OrganizationsEnvironmentsQueriesListCall {
	c.urlParams_.Set("status", status)
	return c
}

// SubmittedBy sets the optional parameter "submittedBy": Filter
// response list by user who submitted queries.
func (c *OrganizationsEnvironmentsQueriesListCall) SubmittedBy(submittedBy string) *OrganizationsEnvironmentsQueriesListCall {
	c.urlParams_.Set("submittedBy", submittedBy)
	return c
}

// To sets the optional parameter "to": Filter response list by
// returning asynchronous queries that created before this date time.
// Time must be in ISO date-time format like '2011-12-03T10:16:30Z'.
func (c *OrganizationsEnvironmentsQueriesListCall) To(to string) *OrganizationsEnvironmentsQueriesListCall {
	c.urlParams_.Set("to", to)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsQueriesListCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsQueriesListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsQueriesListCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsQueriesListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsQueriesListCall) Context(ctx context.Context) *OrganizationsEnvironmentsQueriesListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsQueriesListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsQueriesListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/queries")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.queries.list" call.
// Exactly one of *GoogleCloudApigeeV1ListAsyncQueriesResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListAsyncQueriesResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsQueriesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListAsyncQueriesResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListAsyncQueriesResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Return a list of Asynchronous Queries",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/queries",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.queries.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "dataset": {
	//       "description": "Filter response list by dataset. Example: `api`, `mint`",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "from": {
	//       "description": "Filter response list by returning asynchronous queries that created after this date time. Time must be in ISO date-time format like '2011-12-03T10:15:30Z'.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "inclQueriesWithoutReport": {
	//       "description": "Flag to include asynchronous queries that don't have a report denifition.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. The parent resource name. Must be of the form `organizations/{org}/environments/{env}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "status": {
	//       "description": "Filter response list by asynchronous query status.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "submittedBy": {
	//       "description": "Filter response list by user who submitted queries.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "to": {
	//       "description": "Filter response list by returning asynchronous queries that created before this date time. Time must be in ISO date-time format like '2011-12-03T10:16:30Z'.",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/queries",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListAsyncQueriesResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.references.create":

type OrganizationsEnvironmentsReferencesCreateCall struct {
	s                            *Service
	parent                       string
	googlecloudapigeev1reference *GoogleCloudApigeeV1Reference
	urlParams_                   gensupport.URLParams
	ctx_                         context.Context
	header_                      http.Header
}

// Create: Creates a Reference in the specified environment.
//
//   - parent: The parent environment name under which the Reference will
//     be created. Must be of the form
//     `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsReferencesService) Create(parent string, googlecloudapigeev1reference *GoogleCloudApigeeV1Reference) *OrganizationsEnvironmentsReferencesCreateCall {
	c := &OrganizationsEnvironmentsReferencesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1reference = googlecloudapigeev1reference
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsReferencesCreateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsReferencesCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsReferencesCreateCall) Context(ctx context.Context) *OrganizationsEnvironmentsReferencesCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsReferencesCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsReferencesCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1reference)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/references")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.references.create" call.
// Exactly one of *GoogleCloudApigeeV1Reference or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Reference.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsReferencesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Reference, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Reference{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a Reference in the specified environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/references",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.references.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. The parent environment name under which the Reference will be created. Must be of the form `organizations/{org}/environments/{env}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/references",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Reference"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Reference"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.references.delete":

type OrganizationsEnvironmentsReferencesDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a Reference from an environment. Returns the deleted
// Reference resource.
//
//   - name: The name of the Reference to delete. Must be of the form
//     `organizations/{org}/environments/{env}/references/{ref}`.
func (r *OrganizationsEnvironmentsReferencesService) Delete(name string) *OrganizationsEnvironmentsReferencesDeleteCall {
	c := &OrganizationsEnvironmentsReferencesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsReferencesDeleteCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsReferencesDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsReferencesDeleteCall) Context(ctx context.Context) *OrganizationsEnvironmentsReferencesDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsReferencesDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsReferencesDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.references.delete" call.
// Exactly one of *GoogleCloudApigeeV1Reference or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Reference.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsReferencesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Reference, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Reference{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a Reference from an environment. Returns the deleted Reference resource.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/references/{referencesId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.environments.references.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the Reference to delete. Must be of the form `organizations/{org}/environments/{env}/references/{ref}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/references/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Reference"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.references.get":

type OrganizationsEnvironmentsReferencesGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets a Reference resource.
//
//   - name: The name of the Reference to get. Must be of the form
//     `organizations/{org}/environments/{env}/references/{ref}`.
func (r *OrganizationsEnvironmentsReferencesService) Get(name string) *OrganizationsEnvironmentsReferencesGetCall {
	c := &OrganizationsEnvironmentsReferencesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsReferencesGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsReferencesGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsReferencesGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsReferencesGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsReferencesGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsReferencesGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsReferencesGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsReferencesGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.references.get" call.
// Exactly one of *GoogleCloudApigeeV1Reference or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Reference.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsReferencesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Reference, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Reference{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets a Reference resource.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/references/{referencesId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.references.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the Reference to get. Must be of the form `organizations/{org}/environments/{env}/references/{ref}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/references/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Reference"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.references.update":

type OrganizationsEnvironmentsReferencesUpdateCall struct {
	s                            *Service
	name                         string
	googlecloudapigeev1reference *GoogleCloudApigeeV1Reference
	urlParams_                   gensupport.URLParams
	ctx_                         context.Context
	header_                      http.Header
}

// Update: Updates an existing Reference. Note that this operation has
// PUT semantics; it will replace the entirety of the existing Reference
// with the resource in the request body.
//
//   - name: The name of the Reference to update. Must be of the form
//     `organizations/{org}/environments/{env}/references/{ref}`.
func (r *OrganizationsEnvironmentsReferencesService) Update(name string, googlecloudapigeev1reference *GoogleCloudApigeeV1Reference) *OrganizationsEnvironmentsReferencesUpdateCall {
	c := &OrganizationsEnvironmentsReferencesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1reference = googlecloudapigeev1reference
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsReferencesUpdateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsReferencesUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsReferencesUpdateCall) Context(ctx context.Context) *OrganizationsEnvironmentsReferencesUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsReferencesUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsReferencesUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1reference)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.references.update" call.
// Exactly one of *GoogleCloudApigeeV1Reference or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Reference.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsReferencesUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Reference, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Reference{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates an existing Reference. Note that this operation has PUT semantics; it will replace the entirety of the existing Reference with the resource in the request body.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/references/{referencesId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.environments.references.update",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the Reference to update. Must be of the form `organizations/{org}/environments/{env}/references/{ref}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/references/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Reference"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Reference"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.resourcefiles.create":

type OrganizationsEnvironmentsResourcefilesCreateCall struct {
	s                 *Service
	parent            string
	googleapihttpbody *GoogleApiHttpBody
	urlParams_        gensupport.URLParams
	ctx_              context.Context
	header_           http.Header
}

// Create: Creates a resource file. Specify the `Content-Type` as
// `application/octet-stream` or `multipart/form-data`. For more
// information about resource files, see Resource files
// (https://cloud.google.com/apigee/docs/api-platform/develop/resource-files).
//
//   - parent: Name of the environment in which to create the resource
//     file in the following format:
//     `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsResourcefilesService) Create(parent string, googleapihttpbody *GoogleApiHttpBody) *OrganizationsEnvironmentsResourcefilesCreateCall {
	c := &OrganizationsEnvironmentsResourcefilesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googleapihttpbody = googleapihttpbody
	return c
}

// Name sets the optional parameter "name": Required. Name of the
// resource file. Must match the regular expression:
// [a-zA-Z0-9:/\\!@#$%^&{}\\ ()+\-=,.~'` ]{1,255}
func (c *OrganizationsEnvironmentsResourcefilesCreateCall) Name(name string) *OrganizationsEnvironmentsResourcefilesCreateCall {
	c.urlParams_.Set("name", name)
	return c
}

// Type sets the optional parameter "type": Required. Resource file
// type. {{ resource_file_type }}
func (c *OrganizationsEnvironmentsResourcefilesCreateCall) Type(type_ string) *OrganizationsEnvironmentsResourcefilesCreateCall {
	c.urlParams_.Set("type", type_)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsResourcefilesCreateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsResourcefilesCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsResourcefilesCreateCall) Context(ctx context.Context) *OrganizationsEnvironmentsResourcefilesCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsResourcefilesCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsResourcefilesCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleapihttpbody)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/resourcefiles")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.resourcefiles.create" call.
// Exactly one of *GoogleCloudApigeeV1ResourceFile or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1ResourceFile.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsResourcefilesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ResourceFile, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ResourceFile{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a resource file. Specify the `Content-Type` as `application/octet-stream` or `multipart/form-data`. For more information about resource files, see [Resource files](https://cloud.google.com/apigee/docs/api-platform/develop/resource-files).",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/resourcefiles",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.resourcefiles.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the resource file. Must match the regular expression: [a-zA-Z0-9:/\\\\!@#$%^\u0026{}\\[\\]()+\\-=,.~'` ]{1,255}",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the environment in which to create the resource file in the following format: `organizations/{org}/environments/{env}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "type": {
	//       "description": "Required. Resource file type. {{ resource_file_type }}",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/resourcefiles",
	//   "request": {
	//     "$ref": "GoogleApiHttpBody"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ResourceFile"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.resourcefiles.delete":

type OrganizationsEnvironmentsResourcefilesDeleteCall struct {
	s          *Service
	parent     string
	type_      string
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a resource file. For more information about resource
// files, see Resource files
// (https://cloud.google.com/apigee/docs/api-platform/develop/resource-files).
//
//   - name: ID of the resource file to delete. Must match the regular
//     expression: [a-zA-Z0-9:/\\!@#$%^&{}\\ ()+\-=,.~'` ]{1,255}.
//   - parent: Name of the environment in the following format:
//     `organizations/{org}/environments/{env}`.
//   - type: Resource file type. {{ resource_file_type }}.
func (r *OrganizationsEnvironmentsResourcefilesService) Delete(parent string, type_ string, name string) *OrganizationsEnvironmentsResourcefilesDeleteCall {
	c := &OrganizationsEnvironmentsResourcefilesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.type_ = type_
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsResourcefilesDeleteCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsResourcefilesDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsResourcefilesDeleteCall) Context(ctx context.Context) *OrganizationsEnvironmentsResourcefilesDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsResourcefilesDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsResourcefilesDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/resourcefiles/{type}/{name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
		"type":   c.type_,
		"name":   c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.resourcefiles.delete" call.
// Exactly one of *GoogleCloudApigeeV1ResourceFile or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1ResourceFile.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsResourcefilesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ResourceFile, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ResourceFile{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a resource file. For more information about resource files, see [Resource files](https://cloud.google.com/apigee/docs/api-platform/develop/resource-files).",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/resourcefiles/{type}/{name}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.environments.resourcefiles.delete",
	//   "parameterOrder": [
	//     "parent",
	//     "type",
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. ID of the resource file to delete. Must match the regular expression: [a-zA-Z0-9:/\\\\!@#$%^\u0026{}\\[\\]()+\\-=,.~'` ]{1,255}",
	//       "location": "path",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the environment in the following format: `organizations/{org}/environments/{env}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "type": {
	//       "description": "Required. Resource file type. {{ resource_file_type }}",
	//       "location": "path",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/resourcefiles/{type}/{name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ResourceFile"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.resourcefiles.get":

type OrganizationsEnvironmentsResourcefilesGetCall struct {
	s            *Service
	parent       string
	type_        string
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets the contents of a resource file. For more information about
// resource files, see Resource files
// (https://cloud.google.com/apigee/docs/api-platform/develop/resource-files).
//
//   - name: ID of the resource file. Must match the regular expression:
//     [a-zA-Z0-9:/\\!@#$%^&{}\\ ()+\-=,.~'` ]{1,255}.
//   - parent: Name of the environment in the following format:
//     `organizations/{org}/environments/{env}`.
//   - type: Resource file type. {{ resource_file_type }}.
func (r *OrganizationsEnvironmentsResourcefilesService) Get(parent string, type_ string, name string) *OrganizationsEnvironmentsResourcefilesGetCall {
	c := &OrganizationsEnvironmentsResourcefilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.type_ = type_
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsResourcefilesGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsResourcefilesGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsResourcefilesGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsResourcefilesGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsResourcefilesGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsResourcefilesGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsResourcefilesGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsResourcefilesGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/resourcefiles/{type}/{name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
		"type":   c.type_,
		"name":   c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.resourcefiles.get" call.
// Exactly one of *GoogleApiHttpBody or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleApiHttpBody.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsResourcefilesGetCall) Do(opts ...googleapi.CallOption) (*GoogleApiHttpBody, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleApiHttpBody{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the contents of a resource file. For more information about resource files, see [Resource files](https://cloud.google.com/apigee/docs/api-platform/develop/resource-files).",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/resourcefiles/{type}/{name}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.resourcefiles.get",
	//   "parameterOrder": [
	//     "parent",
	//     "type",
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. ID of the resource file. Must match the regular expression: [a-zA-Z0-9:/\\\\!@#$%^\u0026{}\\[\\]()+\\-=,.~'` ]{1,255}",
	//       "location": "path",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the environment in the following format: `organizations/{org}/environments/{env}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "type": {
	//       "description": "Required. Resource file type. {{ resource_file_type }}",
	//       "location": "path",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/resourcefiles/{type}/{name}",
	//   "response": {
	//     "$ref": "GoogleApiHttpBody"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.resourcefiles.list":

type OrganizationsEnvironmentsResourcefilesListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all resource files, optionally filtering by type. For
// more information about resource files, see Resource files
// (https://cloud.google.com/apigee/docs/api-platform/develop/resource-files).
//
//   - parent: Name of the environment in which to list resource files in
//     the following format: `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsResourcefilesService) List(parent string) *OrganizationsEnvironmentsResourcefilesListCall {
	c := &OrganizationsEnvironmentsResourcefilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Type sets the optional parameter "type": Type of resource files to
// list. {{ resource_file_type }}
func (c *OrganizationsEnvironmentsResourcefilesListCall) Type(type_ string) *OrganizationsEnvironmentsResourcefilesListCall {
	c.urlParams_.Set("type", type_)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsResourcefilesListCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsResourcefilesListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsResourcefilesListCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsResourcefilesListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsResourcefilesListCall) Context(ctx context.Context) *OrganizationsEnvironmentsResourcefilesListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsResourcefilesListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsResourcefilesListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/resourcefiles")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.resourcefiles.list" call.
// Exactly one of *GoogleCloudApigeeV1ListEnvironmentResourcesResponse
// or error will be non-nil. Any non-2xx status code is an error.
// Response headers are in either
// *GoogleCloudApigeeV1ListEnvironmentResourcesResponse.ServerResponse.He
// ader or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsResourcefilesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListEnvironmentResourcesResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListEnvironmentResourcesResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all resource files, optionally filtering by type. For more information about resource files, see [Resource files](https://cloud.google.com/apigee/docs/api-platform/develop/resource-files).",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/resourcefiles",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.resourcefiles.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the environment in which to list resource files in the following format: `organizations/{org}/environments/{env}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "type": {
	//       "description": "Optional. Type of resource files to list. {{ resource_file_type }}",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/resourcefiles",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListEnvironmentResourcesResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.resourcefiles.listEnvironmentResources":

type OrganizationsEnvironmentsResourcefilesListEnvironmentResourcesCall struct {
	s            *Service
	parent       string
	type_        string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// ListEnvironmentResources: Lists all resource files, optionally
// filtering by type. For more information about resource files, see
// Resource files
// (https://cloud.google.com/apigee/docs/api-platform/develop/resource-files).
//
//   - parent: Name of the environment in which to list resource files in
//     the following format: `organizations/{org}/environments/{env}`.
//   - type: Optional. Type of resource files to list. {{
//     resource_file_type }}.
func (r *OrganizationsEnvironmentsResourcefilesService) ListEnvironmentResources(parent string, type_ string) *OrganizationsEnvironmentsResourcefilesListEnvironmentResourcesCall {
	c := &OrganizationsEnvironmentsResourcefilesListEnvironmentResourcesCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.type_ = type_
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsResourcefilesListEnvironmentResourcesCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsResourcefilesListEnvironmentResourcesCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsResourcefilesListEnvironmentResourcesCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsResourcefilesListEnvironmentResourcesCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsResourcefilesListEnvironmentResourcesCall) Context(ctx context.Context) *OrganizationsEnvironmentsResourcefilesListEnvironmentResourcesCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsResourcefilesListEnvironmentResourcesCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsResourcefilesListEnvironmentResourcesCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/resourcefiles/{type}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
		"type":   c.type_,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.resourcefiles.listEnvironmentResources" call.
// Exactly one of *GoogleCloudApigeeV1ListEnvironmentResourcesResponse
// or error will be non-nil. Any non-2xx status code is an error.
// Response headers are in either
// *GoogleCloudApigeeV1ListEnvironmentResourcesResponse.ServerResponse.He
// ader or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsResourcefilesListEnvironmentResourcesCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListEnvironmentResourcesResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListEnvironmentResourcesResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all resource files, optionally filtering by type. For more information about resource files, see [Resource files](https://cloud.google.com/apigee/docs/api-platform/develop/resource-files).",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/resourcefiles/{type}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.resourcefiles.listEnvironmentResources",
	//   "parameterOrder": [
	//     "parent",
	//     "type"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the environment in which to list resource files in the following format: `organizations/{org}/environments/{env}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "type": {
	//       "description": "Optional. Type of resource files to list. {{ resource_file_type }}",
	//       "location": "path",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/resourcefiles/{type}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListEnvironmentResourcesResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.resourcefiles.update":

type OrganizationsEnvironmentsResourcefilesUpdateCall struct {
	s                 *Service
	parent            string
	type_             string
	name              string
	googleapihttpbody *GoogleApiHttpBody
	urlParams_        gensupport.URLParams
	ctx_              context.Context
	header_           http.Header
}

// Update: Updates a resource file. Specify the `Content-Type` as
// `application/octet-stream` or `multipart/form-data`. For more
// information about resource files, see Resource files
// (https://cloud.google.com/apigee/docs/api-platform/develop/resource-files).
//
//   - name: ID of the resource file to update. Must match the regular
//     expression: [a-zA-Z0-9:/\\!@#$%^&{}\\ ()+\-=,.~'` ]{1,255}.
//   - parent: Name of the environment in the following format:
//     `organizations/{org}/environments/{env}`.
//   - type: Resource file type. {{ resource_file_type }}.
func (r *OrganizationsEnvironmentsResourcefilesService) Update(parent string, type_ string, name string, googleapihttpbody *GoogleApiHttpBody) *OrganizationsEnvironmentsResourcefilesUpdateCall {
	c := &OrganizationsEnvironmentsResourcefilesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.type_ = type_
	c.name = name
	c.googleapihttpbody = googleapihttpbody
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsResourcefilesUpdateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsResourcefilesUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsResourcefilesUpdateCall) Context(ctx context.Context) *OrganizationsEnvironmentsResourcefilesUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsResourcefilesUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsResourcefilesUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleapihttpbody)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/resourcefiles/{type}/{name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
		"type":   c.type_,
		"name":   c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.resourcefiles.update" call.
// Exactly one of *GoogleCloudApigeeV1ResourceFile or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1ResourceFile.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsResourcefilesUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ResourceFile, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ResourceFile{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates a resource file. Specify the `Content-Type` as `application/octet-stream` or `multipart/form-data`. For more information about resource files, see [Resource files](https://cloud.google.com/apigee/docs/api-platform/develop/resource-files).",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/resourcefiles/{type}/{name}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.environments.resourcefiles.update",
	//   "parameterOrder": [
	//     "parent",
	//     "type",
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. ID of the resource file to update. Must match the regular expression: [a-zA-Z0-9:/\\\\!@#$%^\u0026{}\\[\\]()+\\-=,.~'` ]{1,255}",
	//       "location": "path",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the environment in the following format: `organizations/{org}/environments/{env}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "type": {
	//       "description": "Required. Resource file type. {{ resource_file_type }}",
	//       "location": "path",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/resourcefiles/{type}/{name}",
	//   "request": {
	//     "$ref": "GoogleApiHttpBody"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ResourceFile"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.securityActions.create":

type OrganizationsEnvironmentsSecurityActionsCreateCall struct {
	s                                 *Service
	parent                            string
	googlecloudapigeev1securityaction *GoogleCloudApigeeV1SecurityAction
	urlParams_                        gensupport.URLParams
	ctx_                              context.Context
	header_                           http.Header
}

// Create: CreateSecurityAction creates a SecurityAction.
//
//   - parent: The organization and environment that this SecurityAction
//     applies to. Format: organizations/{org}/environments/{env}.
func (r *OrganizationsEnvironmentsSecurityActionsService) Create(parent string, googlecloudapigeev1securityaction *GoogleCloudApigeeV1SecurityAction) *OrganizationsEnvironmentsSecurityActionsCreateCall {
	c := &OrganizationsEnvironmentsSecurityActionsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1securityaction = googlecloudapigeev1securityaction
	return c
}

// SecurityActionId sets the optional parameter "securityActionId":
// Required. The ID to use for the SecurityAction, which will become the
// final component of the action's resource name. This value should be
// 0-61 characters, and valid format is (^a-z
// ([a-z0-9-]{​0,61}[a-z0-9])?$).
func (c *OrganizationsEnvironmentsSecurityActionsCreateCall) SecurityActionId(securityActionId string) *OrganizationsEnvironmentsSecurityActionsCreateCall {
	c.urlParams_.Set("securityActionId", securityActionId)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSecurityActionsCreateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSecurityActionsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSecurityActionsCreateCall) Context(ctx context.Context) *OrganizationsEnvironmentsSecurityActionsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSecurityActionsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSecurityActionsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1securityaction)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/securityActions")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.securityActions.create" call.
// Exactly one of *GoogleCloudApigeeV1SecurityAction or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SecurityAction.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsSecurityActionsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityAction, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityAction{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "CreateSecurityAction creates a SecurityAction.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityActions",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.securityActions.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. The organization and environment that this SecurityAction applies to. Format: organizations/{org}/environments/{env}",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "securityActionId": {
	//       "description": "Required. The ID to use for the SecurityAction, which will become the final component of the action's resource name. This value should be 0-61 characters, and valid format is (^[a-z]([a-z0-9-]{​0,61}[a-z0-9])?$).",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/securityActions",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1SecurityAction"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityAction"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.securityActions.disable":

type OrganizationsEnvironmentsSecurityActionsDisableCall struct {
	s                                               *Service
	name                                            string
	googlecloudapigeev1disablesecurityactionrequest *GoogleCloudApigeeV1DisableSecurityActionRequest
	urlParams_                                      gensupport.URLParams
	ctx_                                            context.Context
	header_                                         http.Header
}

// Disable: Disable a SecurityAction. The `state` of the SecurityAction
// after disabling is `DISABLED`. `DisableSecurityAction` can be called
// on SecurityActions in the state `ENABLED`; SecurityActions in a
// different state (including `DISABLED`) return an error.
//
//   - name: The name of the SecurityAction to disable. Format:
//     organizations/{org}/environments/{env}/securityActions/{security_act
//     ion}.
func (r *OrganizationsEnvironmentsSecurityActionsService) Disable(name string, googlecloudapigeev1disablesecurityactionrequest *GoogleCloudApigeeV1DisableSecurityActionRequest) *OrganizationsEnvironmentsSecurityActionsDisableCall {
	c := &OrganizationsEnvironmentsSecurityActionsDisableCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1disablesecurityactionrequest = googlecloudapigeev1disablesecurityactionrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSecurityActionsDisableCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSecurityActionsDisableCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSecurityActionsDisableCall) Context(ctx context.Context) *OrganizationsEnvironmentsSecurityActionsDisableCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSecurityActionsDisableCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSecurityActionsDisableCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1disablesecurityactionrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:disable")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.securityActions.disable" call.
// Exactly one of *GoogleCloudApigeeV1SecurityAction or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SecurityAction.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsSecurityActionsDisableCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityAction, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityAction{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Disable a SecurityAction. The `state` of the SecurityAction after disabling is `DISABLED`. `DisableSecurityAction` can be called on SecurityActions in the state `ENABLED`; SecurityActions in a different state (including `DISABLED`) return an error.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityActions/{securityActionsId}:disable",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.securityActions.disable",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the SecurityAction to disable. Format: organizations/{org}/environments/{env}/securityActions/{security_action}",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/securityActions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}:disable",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1DisableSecurityActionRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityAction"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.securityActions.enable":

type OrganizationsEnvironmentsSecurityActionsEnableCall struct {
	s                                              *Service
	name                                           string
	googlecloudapigeev1enablesecurityactionrequest *GoogleCloudApigeeV1EnableSecurityActionRequest
	urlParams_                                     gensupport.URLParams
	ctx_                                           context.Context
	header_                                        http.Header
}

// Enable: Enable a SecurityAction. The `state` of the SecurityAction
// after enabling is `ENABLED`. `EnableSecurityAction` can be called on
// SecurityActions in the state `DISABLED`; SecurityActions in a
// different state (including `ENABLED) return an error.
//
//   - name: The name of the SecurityAction to enable. Format:
//     organizations/{org}/environments/{env}/securityActions/{security_act
//     ion}.
func (r *OrganizationsEnvironmentsSecurityActionsService) Enable(name string, googlecloudapigeev1enablesecurityactionrequest *GoogleCloudApigeeV1EnableSecurityActionRequest) *OrganizationsEnvironmentsSecurityActionsEnableCall {
	c := &OrganizationsEnvironmentsSecurityActionsEnableCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1enablesecurityactionrequest = googlecloudapigeev1enablesecurityactionrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSecurityActionsEnableCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSecurityActionsEnableCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSecurityActionsEnableCall) Context(ctx context.Context) *OrganizationsEnvironmentsSecurityActionsEnableCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSecurityActionsEnableCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSecurityActionsEnableCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1enablesecurityactionrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:enable")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.securityActions.enable" call.
// Exactly one of *GoogleCloudApigeeV1SecurityAction or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SecurityAction.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsSecurityActionsEnableCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityAction, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityAction{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Enable a SecurityAction. The `state` of the SecurityAction after enabling is `ENABLED`. `EnableSecurityAction` can be called on SecurityActions in the state `DISABLED`; SecurityActions in a different state (including `ENABLED) return an error.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityActions/{securityActionsId}:enable",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.securityActions.enable",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the SecurityAction to enable. Format: organizations/{org}/environments/{env}/securityActions/{security_action}",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/securityActions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}:enable",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1EnableSecurityActionRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityAction"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.securityActions.get":

type OrganizationsEnvironmentsSecurityActionsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Get a SecurityAction by name.
//
//   - name: The fully qualified name of the SecurityAction to retrieve.
//     Format:
//     organizations/{org}/environments/{env}/securityActions/{security_act
//     ion}.
func (r *OrganizationsEnvironmentsSecurityActionsService) Get(name string) *OrganizationsEnvironmentsSecurityActionsGetCall {
	c := &OrganizationsEnvironmentsSecurityActionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSecurityActionsGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSecurityActionsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsSecurityActionsGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsSecurityActionsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSecurityActionsGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsSecurityActionsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSecurityActionsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSecurityActionsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.securityActions.get" call.
// Exactly one of *GoogleCloudApigeeV1SecurityAction or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SecurityAction.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsSecurityActionsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityAction, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityAction{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Get a SecurityAction by name.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityActions/{securityActionsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.securityActions.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The fully qualified name of the SecurityAction to retrieve. Format: organizations/{org}/environments/{env}/securityActions/{security_action}",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/securityActions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityAction"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.securityActions.list":

type OrganizationsEnvironmentsSecurityActionsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Returns a list of SecurityActions. This returns both enabled
// and disabled actions.
//
//   - parent: The parent, which owns this collection of SecurityActions.
//     Format: organizations/{org}/environments/{env}.
func (r *OrganizationsEnvironmentsSecurityActionsService) List(parent string) *OrganizationsEnvironmentsSecurityActionsListCall {
	c := &OrganizationsEnvironmentsSecurityActionsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Filter sets the optional parameter "filter": The filter expression to
// filter List results. https://google.aip.dev/160. Allows for filtering
// over: state and api_proxies. E.g.: state = ACTIVE AND apiProxies:foo.
// Filtering by action is not supported
// https://github.com/aip-dev/google.aip.dev/issues/624
func (c *OrganizationsEnvironmentsSecurityActionsListCall) Filter(filter string) *OrganizationsEnvironmentsSecurityActionsListCall {
	c.urlParams_.Set("filter", filter)
	return c
}

// PageSize sets the optional parameter "pageSize": The maximum number
// of SecurityActions to return. If unspecified, at most 50
// SecurityActions will be returned. The maximum value is 1000; values
// above 1000 will be coerced to 1000.
func (c *OrganizationsEnvironmentsSecurityActionsListCall) PageSize(pageSize int64) *OrganizationsEnvironmentsSecurityActionsListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": A page token,
// received from a previous `ListSecurityActions` call. Provide this to
// retrieve the subsequent page. When paginating, all other parameters
// provided to `ListSecurityActions` must match the call that provided
// the page token.
func (c *OrganizationsEnvironmentsSecurityActionsListCall) PageToken(pageToken string) *OrganizationsEnvironmentsSecurityActionsListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSecurityActionsListCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSecurityActionsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsSecurityActionsListCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsSecurityActionsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSecurityActionsListCall) Context(ctx context.Context) *OrganizationsEnvironmentsSecurityActionsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSecurityActionsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSecurityActionsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/securityActions")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.securityActions.list" call.
// Exactly one of *GoogleCloudApigeeV1ListSecurityActionsResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListSecurityActionsResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsSecurityActionsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListSecurityActionsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListSecurityActionsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Returns a list of SecurityActions. This returns both enabled and disabled actions.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityActions",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.securityActions.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "filter": {
	//       "description": "The filter expression to filter List results. https://google.aip.dev/160. Allows for filtering over: state and api_proxies. E.g.: state = ACTIVE AND apiProxies:foo. Filtering by action is not supported https://github.com/aip-dev/google.aip.dev/issues/624",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "pageSize": {
	//       "description": "The maximum number of SecurityActions to return. If unspecified, at most 50 SecurityActions will be returned. The maximum value is 1000; values above 1000 will be coerced to 1000.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "A page token, received from a previous `ListSecurityActions` call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to `ListSecurityActions` must match the call that provided the page token.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. The parent, which owns this collection of SecurityActions. Format: organizations/{org}/environments/{env}",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/securityActions",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListSecurityActionsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsEnvironmentsSecurityActionsListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListSecurityActionsResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.environments.securityIncidents.batchUpdate":

type OrganizationsEnvironmentsSecurityIncidentsBatchUpdateCall struct {
	s                                                      *Service
	parent                                                 string
	googlecloudapigeev1batchupdatesecurityincidentsrequest *GoogleCloudApigeeV1BatchUpdateSecurityIncidentsRequest
	urlParams_                                             gensupport.URLParams
	ctx_                                                   context.Context
	header_                                                http.Header
}

// BatchUpdate: BatchUpdateSecurityIncident updates multiple existing
// security incidents.
//
//   - parent: Optional. The parent resource shared by all security
//     incidents being updated. If this is set, the parent field in the
//     UpdateSecurityIncidentRequest messages must either be empty or
//     match this field.
func (r *OrganizationsEnvironmentsSecurityIncidentsService) BatchUpdate(parent string, googlecloudapigeev1batchupdatesecurityincidentsrequest *GoogleCloudApigeeV1BatchUpdateSecurityIncidentsRequest) *OrganizationsEnvironmentsSecurityIncidentsBatchUpdateCall {
	c := &OrganizationsEnvironmentsSecurityIncidentsBatchUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1batchupdatesecurityincidentsrequest = googlecloudapigeev1batchupdatesecurityincidentsrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSecurityIncidentsBatchUpdateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSecurityIncidentsBatchUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSecurityIncidentsBatchUpdateCall) Context(ctx context.Context) *OrganizationsEnvironmentsSecurityIncidentsBatchUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSecurityIncidentsBatchUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSecurityIncidentsBatchUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1batchupdatesecurityincidentsrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/securityIncidents:batchUpdate")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.securityIncidents.batchUpdate" call.
// Exactly one of
// *GoogleCloudApigeeV1BatchUpdateSecurityIncidentsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1BatchUpdateSecurityIncidentsResponse.ServerRespons
// e.Header or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsSecurityIncidentsBatchUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1BatchUpdateSecurityIncidentsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1BatchUpdateSecurityIncidentsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "BatchUpdateSecurityIncident updates multiple existing security incidents.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityIncidents:batchUpdate",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.securityIncidents.batchUpdate",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Optional. The parent resource shared by all security incidents being updated. If this is set, the parent field in the UpdateSecurityIncidentRequest messages must either be empty or match this field.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/securityIncidents:batchUpdate",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1BatchUpdateSecurityIncidentsRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1BatchUpdateSecurityIncidentsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.securityIncidents.get":

type OrganizationsEnvironmentsSecurityIncidentsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: GetSecurityIncident gets the specified security incident.
// Returns NOT_FOUND if security incident is not present for the
// specified organization and environment.
//
//   - name: Security incident in the following format:
//     `organizations/{org}/environments/{environment}/securityIncidents/{i
//     ncident}'. Example:
//     organizations/testOrg/environments/testEnv/securityIncidents/1234-45
//     67-890-111.
func (r *OrganizationsEnvironmentsSecurityIncidentsService) Get(name string) *OrganizationsEnvironmentsSecurityIncidentsGetCall {
	c := &OrganizationsEnvironmentsSecurityIncidentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSecurityIncidentsGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSecurityIncidentsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsSecurityIncidentsGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsSecurityIncidentsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSecurityIncidentsGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsSecurityIncidentsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSecurityIncidentsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSecurityIncidentsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.securityIncidents.get" call.
// Exactly one of *GoogleCloudApigeeV1SecurityIncident or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SecurityIncident.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsSecurityIncidentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityIncident, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityIncident{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "GetSecurityIncident gets the specified security incident. Returns NOT_FOUND if security incident is not present for the specified organization and environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityIncidents/{securityIncidentsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.securityIncidents.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Security incident in the following format: `organizations/{org}/environments/{environment}/securityIncidents/{incident}'. Example: organizations/testOrg/environments/testEnv/securityIncidents/1234-4567-890-111",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/securityIncidents/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityIncident"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.securityIncidents.list":

type OrganizationsEnvironmentsSecurityIncidentsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: ListSecurityIncidents lists all the security incident
// associated with the environment.
//
//   - parent: For a specific organization, list of all the security
//     incidents. Format: `organizations/{org}/environments/{environment}`.
func (r *OrganizationsEnvironmentsSecurityIncidentsService) List(parent string) *OrganizationsEnvironmentsSecurityIncidentsListCall {
	c := &OrganizationsEnvironmentsSecurityIncidentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Filter sets the optional parameter "filter": The filter expression to
// be used to get the list of security incidents, where filtering can be
// done on API Proxies. Example: filter = "api_proxy = /",
// "first_detected_time >", "last_detected_time <"
func (c *OrganizationsEnvironmentsSecurityIncidentsListCall) Filter(filter string) *OrganizationsEnvironmentsSecurityIncidentsListCall {
	c.urlParams_.Set("filter", filter)
	return c
}

// PageSize sets the optional parameter "pageSize": The maximum number
// of incidents to return. The service may return fewer than this value.
// If unspecified, at most 50 incidents will be returned.
func (c *OrganizationsEnvironmentsSecurityIncidentsListCall) PageSize(pageSize int64) *OrganizationsEnvironmentsSecurityIncidentsListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": A page token,
// received from a previous `ListSecurityIncident` call. Provide this to
// retrieve the subsequent page.
func (c *OrganizationsEnvironmentsSecurityIncidentsListCall) PageToken(pageToken string) *OrganizationsEnvironmentsSecurityIncidentsListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSecurityIncidentsListCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSecurityIncidentsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsSecurityIncidentsListCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsSecurityIncidentsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSecurityIncidentsListCall) Context(ctx context.Context) *OrganizationsEnvironmentsSecurityIncidentsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSecurityIncidentsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSecurityIncidentsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/securityIncidents")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.securityIncidents.list" call.
// Exactly one of *GoogleCloudApigeeV1ListSecurityIncidentsResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListSecurityIncidentsResponse.ServerResponse.Heade
// r or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsSecurityIncidentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListSecurityIncidentsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListSecurityIncidentsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "ListSecurityIncidents lists all the security incident associated with the environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityIncidents",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.securityIncidents.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "filter": {
	//       "description": "The filter expression to be used to get the list of security incidents, where filtering can be done on API Proxies. Example: filter = \"api_proxy = /\", \"first_detected_time \u003e\", \"last_detected_time \u003c\"",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "pageSize": {
	//       "description": "Optional. The maximum number of incidents to return. The service may return fewer than this value. If unspecified, at most 50 incidents will be returned.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Optional. A page token, received from a previous `ListSecurityIncident` call. Provide this to retrieve the subsequent page.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. For a specific organization, list of all the security incidents. Format: `organizations/{org}/environments/{environment}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/securityIncidents",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListSecurityIncidentsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsEnvironmentsSecurityIncidentsListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListSecurityIncidentsResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.environments.securityIncidents.patch":

type OrganizationsEnvironmentsSecurityIncidentsPatchCall struct {
	s                                   *Service
	name                                string
	googlecloudapigeev1securityincident *GoogleCloudApigeeV1SecurityIncident
	urlParams_                          gensupport.URLParams
	ctx_                                context.Context
	header_                             http.Header
}

// Patch: UpdateSecurityIncidents updates an existing security incident.
//
//   - name: Immutable. Name of the security incident resource. Format:
//     organizations/{org}/environments/{environment}/securityIncidents/{in
//     cident} Example:
//     organizations/apigee-org/environments/dev/securityIncidents/1234-567
//     8-9101-1111.
func (r *OrganizationsEnvironmentsSecurityIncidentsService) Patch(name string, googlecloudapigeev1securityincident *GoogleCloudApigeeV1SecurityIncident) *OrganizationsEnvironmentsSecurityIncidentsPatchCall {
	c := &OrganizationsEnvironmentsSecurityIncidentsPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1securityincident = googlecloudapigeev1securityincident
	return c
}

// UpdateMask sets the optional parameter "updateMask": Required. The
// list of fields to update. Allowed fields are:
// LINT.IfChange(allowed_update_fields_comment) - observability
// LINT.ThenChange()
func (c *OrganizationsEnvironmentsSecurityIncidentsPatchCall) UpdateMask(updateMask string) *OrganizationsEnvironmentsSecurityIncidentsPatchCall {
	c.urlParams_.Set("updateMask", updateMask)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSecurityIncidentsPatchCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSecurityIncidentsPatchCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSecurityIncidentsPatchCall) Context(ctx context.Context) *OrganizationsEnvironmentsSecurityIncidentsPatchCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSecurityIncidentsPatchCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSecurityIncidentsPatchCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1securityincident)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PATCH", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.securityIncidents.patch" call.
// Exactly one of *GoogleCloudApigeeV1SecurityIncident or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SecurityIncident.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsSecurityIncidentsPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityIncident, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityIncident{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "UpdateSecurityIncidents updates an existing security incident.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityIncidents/{securityIncidentsId}",
	//   "httpMethod": "PATCH",
	//   "id": "apigee.organizations.environments.securityIncidents.patch",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Immutable. Name of the security incident resource. Format: organizations/{org}/environments/{environment}/securityIncidents/{incident} Example: organizations/apigee-org/environments/dev/securityIncidents/1234-5678-9101-1111",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/securityIncidents/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "updateMask": {
	//       "description": "Required. The list of fields to update. Allowed fields are: LINT.IfChange(allowed_update_fields_comment) - observability LINT.ThenChange()",
	//       "format": "google-fieldmask",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1SecurityIncident"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityIncident"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.securityReports.create":

type OrganizationsEnvironmentsSecurityReportsCreateCall struct {
	s                                      *Service
	parent                                 string
	googlecloudapigeev1securityreportquery *GoogleCloudApigeeV1SecurityReportQuery
	urlParams_                             gensupport.URLParams
	ctx_                                   context.Context
	header_                                http.Header
}

// Create: Submit a report request to be processed in the background. If
// the submission succeeds, the API returns a 200 status and an ID that
// refer to the report request. In addition to the HTTP status 200, the
// `state` of "enqueued" means that the request succeeded.
//
//   - parent: The parent resource name. Must be of the form
//     `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsSecurityReportsService) Create(parent string, googlecloudapigeev1securityreportquery *GoogleCloudApigeeV1SecurityReportQuery) *OrganizationsEnvironmentsSecurityReportsCreateCall {
	c := &OrganizationsEnvironmentsSecurityReportsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1securityreportquery = googlecloudapigeev1securityreportquery
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSecurityReportsCreateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSecurityReportsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSecurityReportsCreateCall) Context(ctx context.Context) *OrganizationsEnvironmentsSecurityReportsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSecurityReportsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSecurityReportsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1securityreportquery)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/securityReports")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.securityReports.create" call.
// Exactly one of *GoogleCloudApigeeV1SecurityReport or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SecurityReport.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsSecurityReportsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityReport, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityReport{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Submit a report request to be processed in the background. If the submission succeeds, the API returns a 200 status and an ID that refer to the report request. In addition to the HTTP status 200, the `state` of \"enqueued\" means that the request succeeded.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityReports",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.securityReports.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. The parent resource name. Must be of the form `organizations/{org}/environments/{env}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/securityReports",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1SecurityReportQuery"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityReport"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.securityReports.get":

type OrganizationsEnvironmentsSecurityReportsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Get security report status If the query is still in progress,
// the `state` is set to "running" After the query has completed
// successfully, `state` is set to "completed"
//
//   - name: Name of the security report to get. Must be of the form
//     `organizations/{org}/environments/{env}/securityReports/{reportId}`.
func (r *OrganizationsEnvironmentsSecurityReportsService) Get(name string) *OrganizationsEnvironmentsSecurityReportsGetCall {
	c := &OrganizationsEnvironmentsSecurityReportsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSecurityReportsGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSecurityReportsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsSecurityReportsGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsSecurityReportsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSecurityReportsGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsSecurityReportsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSecurityReportsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSecurityReportsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.securityReports.get" call.
// Exactly one of *GoogleCloudApigeeV1SecurityReport or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SecurityReport.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsSecurityReportsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityReport, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityReport{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Get security report status If the query is still in progress, the `state` is set to \"running\" After the query has completed successfully, `state` is set to \"completed\"",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityReports/{securityReportsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.securityReports.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the security report to get. Must be of the form `organizations/{org}/environments/{env}/securityReports/{reportId}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/securityReports/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityReport"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.securityReports.getResult":

type OrganizationsEnvironmentsSecurityReportsGetResultCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetResult: After the query is completed, use this API to retrieve the
// results as file. If the request succeeds, and there is a non-zero
// result set, the result is downloaded to the client as a zipped JSON
// file. The name of the downloaded file will be:
// OfflineQueryResult-.zip Example:
// `OfflineQueryResult-9cfc0d85-0f30-46d6-ae6f-318d0cb961bd.zip`
//
//   - name: Name of the security report result to get. Must be of the
//     form
//     `organizations/{org}/environments/{env}/securityReports/{reportId}/r
//     esult`.
func (r *OrganizationsEnvironmentsSecurityReportsService) GetResult(name string) *OrganizationsEnvironmentsSecurityReportsGetResultCall {
	c := &OrganizationsEnvironmentsSecurityReportsGetResultCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSecurityReportsGetResultCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSecurityReportsGetResultCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsSecurityReportsGetResultCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsSecurityReportsGetResultCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSecurityReportsGetResultCall) Context(ctx context.Context) *OrganizationsEnvironmentsSecurityReportsGetResultCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSecurityReportsGetResultCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSecurityReportsGetResultCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.securityReports.getResult" call.
// Exactly one of *GoogleApiHttpBody or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleApiHttpBody.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsSecurityReportsGetResultCall) Do(opts ...googleapi.CallOption) (*GoogleApiHttpBody, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleApiHttpBody{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "After the query is completed, use this API to retrieve the results as file. If the request succeeds, and there is a non-zero result set, the result is downloaded to the client as a zipped JSON file. The name of the downloaded file will be: OfflineQueryResult-.zip Example: `OfflineQueryResult-9cfc0d85-0f30-46d6-ae6f-318d0cb961bd.zip`",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityReports/{securityReportsId}/result",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.securityReports.getResult",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the security report result to get. Must be of the form `organizations/{org}/environments/{env}/securityReports/{reportId}/result`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/securityReports/[^/]+/result$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleApiHttpBody"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.securityReports.getResultView":

type OrganizationsEnvironmentsSecurityReportsGetResultViewCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetResultView: After the query is completed, use this API to view the
// query result when result size is small.
//
//   - name: Name of the security report result view to get. Must be of
//     the form
//     `organizations/{org}/environments/{env}/securityReports/{reportId}/r
//     esultView`.
func (r *OrganizationsEnvironmentsSecurityReportsService) GetResultView(name string) *OrganizationsEnvironmentsSecurityReportsGetResultViewCall {
	c := &OrganizationsEnvironmentsSecurityReportsGetResultViewCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSecurityReportsGetResultViewCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSecurityReportsGetResultViewCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsSecurityReportsGetResultViewCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsSecurityReportsGetResultViewCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSecurityReportsGetResultViewCall) Context(ctx context.Context) *OrganizationsEnvironmentsSecurityReportsGetResultViewCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSecurityReportsGetResultViewCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSecurityReportsGetResultViewCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.securityReports.getResultView" call.
// Exactly one of *GoogleCloudApigeeV1SecurityReportResultView or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1SecurityReportResultView.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsSecurityReportsGetResultViewCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityReportResultView, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityReportResultView{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "After the query is completed, use this API to view the query result when result size is small.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityReports/{securityReportsId}/resultView",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.securityReports.getResultView",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the security report result view to get. Must be of the form `organizations/{org}/environments/{env}/securityReports/{reportId}/resultView`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/securityReports/[^/]+/resultView$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityReportResultView"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.securityReports.list":

type OrganizationsEnvironmentsSecurityReportsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Return a list of Security Reports
//
//   - parent: The parent resource name. Must be of the form
//     `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsSecurityReportsService) List(parent string) *OrganizationsEnvironmentsSecurityReportsListCall {
	c := &OrganizationsEnvironmentsSecurityReportsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Dataset sets the optional parameter "dataset": Filter response list
// by dataset. Example: `api`, `mint`
func (c *OrganizationsEnvironmentsSecurityReportsListCall) Dataset(dataset string) *OrganizationsEnvironmentsSecurityReportsListCall {
	c.urlParams_.Set("dataset", dataset)
	return c
}

// From sets the optional parameter "from": Filter response list by
// returning security reports that created after this date time. Time
// must be in ISO date-time format like '2011-12-03T10:15:30Z'.
func (c *OrganizationsEnvironmentsSecurityReportsListCall) From(from string) *OrganizationsEnvironmentsSecurityReportsListCall {
	c.urlParams_.Set("from", from)
	return c
}

// PageSize sets the optional parameter "pageSize": The maximum number
// of security report to return in the list response.
func (c *OrganizationsEnvironmentsSecurityReportsListCall) PageSize(pageSize int64) *OrganizationsEnvironmentsSecurityReportsListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": Token returned
// from the previous list response to fetch the next page.
func (c *OrganizationsEnvironmentsSecurityReportsListCall) PageToken(pageToken string) *OrganizationsEnvironmentsSecurityReportsListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Status sets the optional parameter "status": Filter response list by
// security reports status.
func (c *OrganizationsEnvironmentsSecurityReportsListCall) Status(status string) *OrganizationsEnvironmentsSecurityReportsListCall {
	c.urlParams_.Set("status", status)
	return c
}

// SubmittedBy sets the optional parameter "submittedBy": Filter
// response list by user who submitted queries.
func (c *OrganizationsEnvironmentsSecurityReportsListCall) SubmittedBy(submittedBy string) *OrganizationsEnvironmentsSecurityReportsListCall {
	c.urlParams_.Set("submittedBy", submittedBy)
	return c
}

// To sets the optional parameter "to": Filter response list by
// returning security reports that created before this date time. Time
// must be in ISO date-time format like '2011-12-03T10:16:30Z'.
func (c *OrganizationsEnvironmentsSecurityReportsListCall) To(to string) *OrganizationsEnvironmentsSecurityReportsListCall {
	c.urlParams_.Set("to", to)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSecurityReportsListCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSecurityReportsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsSecurityReportsListCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsSecurityReportsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSecurityReportsListCall) Context(ctx context.Context) *OrganizationsEnvironmentsSecurityReportsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSecurityReportsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSecurityReportsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/securityReports")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.securityReports.list" call.
// Exactly one of *GoogleCloudApigeeV1ListSecurityReportsResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListSecurityReportsResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsSecurityReportsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListSecurityReportsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListSecurityReportsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Return a list of Security Reports",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityReports",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.securityReports.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "dataset": {
	//       "description": "Filter response list by dataset. Example: `api`, `mint`",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "from": {
	//       "description": "Filter response list by returning security reports that created after this date time. Time must be in ISO date-time format like '2011-12-03T10:15:30Z'.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "pageSize": {
	//       "description": "The maximum number of security report to return in the list response.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Token returned from the previous list response to fetch the next page.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. The parent resource name. Must be of the form `organizations/{org}/environments/{env}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "status": {
	//       "description": "Filter response list by security reports status.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "submittedBy": {
	//       "description": "Filter response list by user who submitted queries.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "to": {
	//       "description": "Filter response list by returning security reports that created before this date time. Time must be in ISO date-time format like '2011-12-03T10:16:30Z'.",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/securityReports",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListSecurityReportsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsEnvironmentsSecurityReportsListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListSecurityReportsResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.environments.securityStats.queryTabularStats":

type OrganizationsEnvironmentsSecurityStatsQueryTabularStatsCall struct {
	s                                           *Service
	orgenv                                      string
	googlecloudapigeev1querytabularstatsrequest *GoogleCloudApigeeV1QueryTabularStatsRequest
	urlParams_                                  gensupport.URLParams
	ctx_                                        context.Context
	header_                                     http.Header
}

// QueryTabularStats: Retrieve security statistics as tabular rows.
//
// - orgenv: Should be of the form organizations//environments/.
func (r *OrganizationsEnvironmentsSecurityStatsService) QueryTabularStats(orgenv string, googlecloudapigeev1querytabularstatsrequest *GoogleCloudApigeeV1QueryTabularStatsRequest) *OrganizationsEnvironmentsSecurityStatsQueryTabularStatsCall {
	c := &OrganizationsEnvironmentsSecurityStatsQueryTabularStatsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.orgenv = orgenv
	c.googlecloudapigeev1querytabularstatsrequest = googlecloudapigeev1querytabularstatsrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSecurityStatsQueryTabularStatsCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSecurityStatsQueryTabularStatsCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSecurityStatsQueryTabularStatsCall) Context(ctx context.Context) *OrganizationsEnvironmentsSecurityStatsQueryTabularStatsCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSecurityStatsQueryTabularStatsCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSecurityStatsQueryTabularStatsCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1querytabularstatsrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+orgenv}/securityStats:queryTabularStats")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"orgenv": c.orgenv,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.securityStats.queryTabularStats" call.
// Exactly one of *GoogleCloudApigeeV1QueryTabularStatsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1QueryTabularStatsResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsSecurityStatsQueryTabularStatsCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1QueryTabularStatsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1QueryTabularStatsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Retrieve security statistics as tabular rows.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityStats:queryTabularStats",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.securityStats.queryTabularStats",
	//   "parameterOrder": [
	//     "orgenv"
	//   ],
	//   "parameters": {
	//     "orgenv": {
	//       "description": "Required. Should be of the form organizations//environments/.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+orgenv}/securityStats:queryTabularStats",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1QueryTabularStatsRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1QueryTabularStatsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsEnvironmentsSecurityStatsQueryTabularStatsCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1QueryTabularStatsResponse) error) error {
	c.ctx_ = ctx
	defer func(pt string) { c.googlecloudapigeev1querytabularstatsrequest.PageToken = pt }(c.googlecloudapigeev1querytabularstatsrequest.PageToken) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.googlecloudapigeev1querytabularstatsrequest.PageToken = x.NextPageToken
	}
}

// method id "apigee.organizations.environments.securityStats.queryTimeSeriesStats":

type OrganizationsEnvironmentsSecurityStatsQueryTimeSeriesStatsCall struct {
	s                                              *Service
	orgenv                                         string
	googlecloudapigeev1querytimeseriesstatsrequest *GoogleCloudApigeeV1QueryTimeSeriesStatsRequest
	urlParams_                                     gensupport.URLParams
	ctx_                                           context.Context
	header_                                        http.Header
}

// QueryTimeSeriesStats: Retrieve security statistics as a collection of
// time series.
//
// - orgenv: Should be of the form organizations//environments/.
func (r *OrganizationsEnvironmentsSecurityStatsService) QueryTimeSeriesStats(orgenv string, googlecloudapigeev1querytimeseriesstatsrequest *GoogleCloudApigeeV1QueryTimeSeriesStatsRequest) *OrganizationsEnvironmentsSecurityStatsQueryTimeSeriesStatsCall {
	c := &OrganizationsEnvironmentsSecurityStatsQueryTimeSeriesStatsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.orgenv = orgenv
	c.googlecloudapigeev1querytimeseriesstatsrequest = googlecloudapigeev1querytimeseriesstatsrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSecurityStatsQueryTimeSeriesStatsCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSecurityStatsQueryTimeSeriesStatsCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSecurityStatsQueryTimeSeriesStatsCall) Context(ctx context.Context) *OrganizationsEnvironmentsSecurityStatsQueryTimeSeriesStatsCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSecurityStatsQueryTimeSeriesStatsCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSecurityStatsQueryTimeSeriesStatsCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1querytimeseriesstatsrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+orgenv}/securityStats:queryTimeSeriesStats")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"orgenv": c.orgenv,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.securityStats.queryTimeSeriesStats" call.
// Exactly one of *GoogleCloudApigeeV1QueryTimeSeriesStatsResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1QueryTimeSeriesStatsResponse.ServerResponse.Header
//
//	or (if a response was returned at all) in
//
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsSecurityStatsQueryTimeSeriesStatsCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1QueryTimeSeriesStatsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1QueryTimeSeriesStatsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Retrieve security statistics as a collection of time series.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/securityStats:queryTimeSeriesStats",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.securityStats.queryTimeSeriesStats",
	//   "parameterOrder": [
	//     "orgenv"
	//   ],
	//   "parameters": {
	//     "orgenv": {
	//       "description": "Required. Should be of the form organizations//environments/.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+orgenv}/securityStats:queryTimeSeriesStats",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1QueryTimeSeriesStatsRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1QueryTimeSeriesStatsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsEnvironmentsSecurityStatsQueryTimeSeriesStatsCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1QueryTimeSeriesStatsResponse) error) error {
	c.ctx_ = ctx
	defer func(pt string) { c.googlecloudapigeev1querytimeseriesstatsrequest.PageToken = pt }(c.googlecloudapigeev1querytimeseriesstatsrequest.PageToken) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.googlecloudapigeev1querytimeseriesstatsrequest.PageToken = x.NextPageToken
	}
}

// method id "apigee.organizations.environments.sharedflows.deployments.list":

type OrganizationsEnvironmentsSharedflowsDeploymentsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all deployments of a shared flow in an environment.
//
//   - parent: Name representing a shared flow in an environment in the
//     following format:
//     `organizations/{org}/environments/{env}/sharedflows/{sharedflow}`.
func (r *OrganizationsEnvironmentsSharedflowsDeploymentsService) List(parent string) *OrganizationsEnvironmentsSharedflowsDeploymentsListCall {
	c := &OrganizationsEnvironmentsSharedflowsDeploymentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSharedflowsDeploymentsListCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSharedflowsDeploymentsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsSharedflowsDeploymentsListCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsSharedflowsDeploymentsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSharedflowsDeploymentsListCall) Context(ctx context.Context) *OrganizationsEnvironmentsSharedflowsDeploymentsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSharedflowsDeploymentsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSharedflowsDeploymentsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/deployments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.sharedflows.deployments.list" call.
// Exactly one of *GoogleCloudApigeeV1ListDeploymentsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListDeploymentsResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsSharedflowsDeploymentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListDeploymentsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListDeploymentsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all deployments of a shared flow in an environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/sharedflows/{sharedflowsId}/deployments",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.sharedflows.deployments.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name representing a shared flow in an environment in the following format: `organizations/{org}/environments/{env}/sharedflows/{sharedflow}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/sharedflows/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/deployments",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListDeploymentsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.sharedflows.revisions.deploy":

type OrganizationsEnvironmentsSharedflowsRevisionsDeployCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Deploy: Deploys a revision of a shared flow. If another revision of
// the same shared flow is currently deployed, set the `override`
// parameter to `true` to have this revision replace the currently
// deployed revision. You cannot use a shared flow until it has been
// deployed to an environment. For a request path
// `organizations/{org}/environments/{env}/sharedflows/{sf}/revisions/{re
// v}/deployments`, two permissions are required: *
// `apigee.deployments.create` on the resource
// `organizations/{org}/environments/{env}` *
// `apigee.sharedflowrevisions.deploy` on the resource
// `organizations/{org}/sharedflows/{sf}/revisions/{rev}`
//
//   - name: Name of the shared flow revision to deploy in the following
//     format:
//     `organizations/{org}/environments/{env}/sharedflows/{sharedflow}/rev
//     isions/{rev}`.
func (r *OrganizationsEnvironmentsSharedflowsRevisionsService) Deploy(name string) *OrganizationsEnvironmentsSharedflowsRevisionsDeployCall {
	c := &OrganizationsEnvironmentsSharedflowsRevisionsDeployCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Override sets the optional parameter "override": Flag that specifies
// whether the new deployment replaces other deployed revisions of the
// shared flow in the environment. Set `override` to `true` to replace
// other deployed revisions. By default, `override` is `false` and the
// deployment is rejected if other revisions of the shared flow are
// deployed in the environment.
func (c *OrganizationsEnvironmentsSharedflowsRevisionsDeployCall) Override(override bool) *OrganizationsEnvironmentsSharedflowsRevisionsDeployCall {
	c.urlParams_.Set("override", fmt.Sprint(override))
	return c
}

// ServiceAccount sets the optional parameter "serviceAccount": Google
// Cloud IAM service account. The service account represents the
// identity of the deployed proxy, and determines what permissions it
// has. The format must be
// `{ACCOUNT_ID}@{PROJECT}.iam.gserviceaccount.com`.
func (c *OrganizationsEnvironmentsSharedflowsRevisionsDeployCall) ServiceAccount(serviceAccount string) *OrganizationsEnvironmentsSharedflowsRevisionsDeployCall {
	c.urlParams_.Set("serviceAccount", serviceAccount)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSharedflowsRevisionsDeployCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSharedflowsRevisionsDeployCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSharedflowsRevisionsDeployCall) Context(ctx context.Context) *OrganizationsEnvironmentsSharedflowsRevisionsDeployCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSharedflowsRevisionsDeployCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSharedflowsRevisionsDeployCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/deployments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.sharedflows.revisions.deploy" call.
// Exactly one of *GoogleCloudApigeeV1Deployment or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Deployment.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsSharedflowsRevisionsDeployCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Deployment, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Deployment{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deploys a revision of a shared flow. If another revision of the same shared flow is currently deployed, set the `override` parameter to `true` to have this revision replace the currently deployed revision. You cannot use a shared flow until it has been deployed to an environment. For a request path `organizations/{org}/environments/{env}/sharedflows/{sf}/revisions/{rev}/deployments`, two permissions are required: * `apigee.deployments.create` on the resource `organizations/{org}/environments/{env}` * `apigee.sharedflowrevisions.deploy` on the resource `organizations/{org}/sharedflows/{sf}/revisions/{rev}`",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/sharedflows/{sharedflowsId}/revisions/{revisionsId}/deployments",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.sharedflows.revisions.deploy",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the shared flow revision to deploy in the following format: `organizations/{org}/environments/{env}/sharedflows/{sharedflow}/revisions/{rev}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/sharedflows/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "override": {
	//       "description": "Flag that specifies whether the new deployment replaces other deployed revisions of the shared flow in the environment. Set `override` to `true` to replace other deployed revisions. By default, `override` is `false` and the deployment is rejected if other revisions of the shared flow are deployed in the environment.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "serviceAccount": {
	//       "description": "Google Cloud IAM service account. The service account represents the identity of the deployed proxy, and determines what permissions it has. The format must be `{ACCOUNT_ID}@{PROJECT}.iam.gserviceaccount.com`.",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}/deployments",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Deployment"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.sharedflows.revisions.getDeployments":

type OrganizationsEnvironmentsSharedflowsRevisionsGetDeploymentsCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetDeployments: Gets the deployment of a shared flow revision and
// actual state reported by runtime pods.
//
//   - name: Name representing a shared flow in an environment in the
//     following format:
//     `organizations/{org}/environments/{env}/sharedflows/{sharedflow}/rev
//     isions/{rev}`.
func (r *OrganizationsEnvironmentsSharedflowsRevisionsService) GetDeployments(name string) *OrganizationsEnvironmentsSharedflowsRevisionsGetDeploymentsCall {
	c := &OrganizationsEnvironmentsSharedflowsRevisionsGetDeploymentsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSharedflowsRevisionsGetDeploymentsCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSharedflowsRevisionsGetDeploymentsCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsSharedflowsRevisionsGetDeploymentsCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsSharedflowsRevisionsGetDeploymentsCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSharedflowsRevisionsGetDeploymentsCall) Context(ctx context.Context) *OrganizationsEnvironmentsSharedflowsRevisionsGetDeploymentsCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSharedflowsRevisionsGetDeploymentsCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSharedflowsRevisionsGetDeploymentsCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/deployments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.sharedflows.revisions.getDeployments" call.
// Exactly one of *GoogleCloudApigeeV1Deployment or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1Deployment.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsSharedflowsRevisionsGetDeploymentsCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Deployment, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Deployment{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the deployment of a shared flow revision and actual state reported by runtime pods.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/sharedflows/{sharedflowsId}/revisions/{revisionsId}/deployments",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.sharedflows.revisions.getDeployments",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name representing a shared flow in an environment in the following format: `organizations/{org}/environments/{env}/sharedflows/{sharedflow}/revisions/{rev}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/sharedflows/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}/deployments",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Deployment"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.sharedflows.revisions.undeploy":

type OrganizationsEnvironmentsSharedflowsRevisionsUndeployCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Undeploy: Undeploys a shared flow revision from an environment. For a
// request path
// `organizations/{org}/environments/{env}/sharedflows/{sf}/revisions/{re
// v}/deployments`, two permissions are required: *
// `apigee.deployments.delete` on the resource
// `organizations/{org}/environments/{env}` *
// `apigee.sharedflowrevisions.undeploy` on the resource
// `organizations/{org}/sharedflows/{sf}/revisions/{rev}`
//
//   - name: Name of the shared flow revision to undeploy in the following
//     format:
//     `organizations/{org}/environments/{env}/sharedflows/{sharedflow}/rev
//     isions/{rev}`.
func (r *OrganizationsEnvironmentsSharedflowsRevisionsService) Undeploy(name string) *OrganizationsEnvironmentsSharedflowsRevisionsUndeployCall {
	c := &OrganizationsEnvironmentsSharedflowsRevisionsUndeployCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsSharedflowsRevisionsUndeployCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsSharedflowsRevisionsUndeployCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsSharedflowsRevisionsUndeployCall) Context(ctx context.Context) *OrganizationsEnvironmentsSharedflowsRevisionsUndeployCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsSharedflowsRevisionsUndeployCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsSharedflowsRevisionsUndeployCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/deployments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.sharedflows.revisions.undeploy" call.
// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsSharedflowsRevisionsUndeployCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleProtobufEmpty{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Undeploys a shared flow revision from an environment. For a request path `organizations/{org}/environments/{env}/sharedflows/{sf}/revisions/{rev}/deployments`, two permissions are required: * `apigee.deployments.delete` on the resource `organizations/{org}/environments/{env}` * `apigee.sharedflowrevisions.undeploy` on the resource `organizations/{org}/sharedflows/{sf}/revisions/{rev}`",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/sharedflows/{sharedflowsId}/revisions/{revisionsId}/deployments",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.environments.sharedflows.revisions.undeploy",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the shared flow revision to undeploy in the following format: `organizations/{org}/environments/{env}/sharedflows/{sharedflow}/revisions/{rev}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/sharedflows/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}/deployments",
	//   "response": {
	//     "$ref": "GoogleProtobufEmpty"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.stats.get":

type OrganizationsEnvironmentsStatsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Retrieve metrics grouped by dimensions. The types of metrics you
// can retrieve include traffic, message counts, API call latency,
// response size, and cache hits and counts. Dimensions let you view
// metrics in meaningful groups. You can optionally pass dimensions as
// path parameters to the `stats` API. If dimensions are not specified,
// the metrics are computed on the entire set of data for the given time
// range.
//
//   - name: Resource name for which the interactive query will be
//     executed. Use the following format in your request:
//     `organizations/{org}/environments/{env}/stats/{dimensions}`
//     Dimensions let you view metrics in meaningful groupings, such as
//     `apiproxy` or `target_host`. The value of dimensions should be a
//     comma-separated list, as shown below:
//     `organizations/{org}/environments/{env}/stats/apiproxy,request_verb`.
func (r *OrganizationsEnvironmentsStatsService) Get(name string) *OrganizationsEnvironmentsStatsGetCall {
	c := &OrganizationsEnvironmentsStatsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Accuracy sets the optional parameter "accuracy": No longer used by
// Apigee. Supported for backwards compatibility.
func (c *OrganizationsEnvironmentsStatsGetCall) Accuracy(accuracy string) *OrganizationsEnvironmentsStatsGetCall {
	c.urlParams_.Set("accuracy", accuracy)
	return c
}

// AggTable sets the optional parameter "aggTable": Table name used to
// query custom aggregate tables. If this parameter is skipped, then
// Apigee will try to retrieve the data from fact tables which will be
// expensive.
func (c *OrganizationsEnvironmentsStatsGetCall) AggTable(aggTable string) *OrganizationsEnvironmentsStatsGetCall {
	c.urlParams_.Set("aggTable", aggTable)
	return c
}

// Filter sets the optional parameter "filter": Filter that enables you
// to drill down on specific dimension values.
func (c *OrganizationsEnvironmentsStatsGetCall) Filter(filter string) *OrganizationsEnvironmentsStatsGetCall {
	c.urlParams_.Set("filter", filter)
	return c
}

// Limit sets the optional parameter "limit": Maximum number of result
// items to return. The default and maximum value that can be returned
// is 14400.
func (c *OrganizationsEnvironmentsStatsGetCall) Limit(limit string) *OrganizationsEnvironmentsStatsGetCall {
	c.urlParams_.Set("limit", limit)
	return c
}

// Offset sets the optional parameter "offset": Offset value. Use
// `offset` with `limit` to enable pagination of results. For example,
// to display results 11-20, set limit to `10` and offset to `10`.
func (c *OrganizationsEnvironmentsStatsGetCall) Offset(offset string) *OrganizationsEnvironmentsStatsGetCall {
	c.urlParams_.Set("offset", offset)
	return c
}

// Realtime sets the optional parameter "realtime": No longer used by
// Apigee. Supported for backwards compatibility.
func (c *OrganizationsEnvironmentsStatsGetCall) Realtime(realtime bool) *OrganizationsEnvironmentsStatsGetCall {
	c.urlParams_.Set("realtime", fmt.Sprint(realtime))
	return c
}

// Select sets the optional parameter "select": Comma-separated list of
// metrics. For example: `sum(message_count),sum(error_count)`
func (c *OrganizationsEnvironmentsStatsGetCall) Select(select_ string) *OrganizationsEnvironmentsStatsGetCall {
	c.urlParams_.Set("select", select_)
	return c
}

// Sonar sets the optional parameter "sonar": Routes the query to API
// Monitoring for the last hour.
func (c *OrganizationsEnvironmentsStatsGetCall) Sonar(sonar bool) *OrganizationsEnvironmentsStatsGetCall {
	c.urlParams_.Set("sonar", fmt.Sprint(sonar))
	return c
}

// Sort sets the optional parameter "sort": Flag that specifies whether
// the sort order should be ascending or descending. Valid values
// include: `DESC` and `ASC`.
func (c *OrganizationsEnvironmentsStatsGetCall) Sort(sort string) *OrganizationsEnvironmentsStatsGetCall {
	c.urlParams_.Set("sort", sort)
	return c
}

// Sortby sets the optional parameter "sortby": Comma-separated list of
// columns to sort the final result.
func (c *OrganizationsEnvironmentsStatsGetCall) Sortby(sortby string) *OrganizationsEnvironmentsStatsGetCall {
	c.urlParams_.Set("sortby", sortby)
	return c
}

// TimeRange sets the optional parameter "timeRange": Time interval for
// the interactive query. Time range is specified in GMT as `start~end`.
// For example: `04/15/2017 00:00~05/15/2017 23:59`
func (c *OrganizationsEnvironmentsStatsGetCall) TimeRange(timeRange string) *OrganizationsEnvironmentsStatsGetCall {
	c.urlParams_.Set("timeRange", timeRange)
	return c
}

// TimeUnit sets the optional parameter "timeUnit": Granularity of
// metrics returned. Valid values include: `second`, `minute`, `hour`,
// `day`, `week`, or` month`.
func (c *OrganizationsEnvironmentsStatsGetCall) TimeUnit(timeUnit string) *OrganizationsEnvironmentsStatsGetCall {
	c.urlParams_.Set("timeUnit", timeUnit)
	return c
}

// Topk sets the optional parameter "topk": Top number of results to
// return. For example, to return the top 5 results, set `topk=5`.
func (c *OrganizationsEnvironmentsStatsGetCall) Topk(topk string) *OrganizationsEnvironmentsStatsGetCall {
	c.urlParams_.Set("topk", topk)
	return c
}

// TsAscending sets the optional parameter "tsAscending": Flag that
// specifies whether to list timestamps in ascending (`true`) or
// descending (`false`) order. Apigee recommends that you set this value
// to `true` if you are using `sortby` with `sort=DESC`.
func (c *OrganizationsEnvironmentsStatsGetCall) TsAscending(tsAscending bool) *OrganizationsEnvironmentsStatsGetCall {
	c.urlParams_.Set("tsAscending", fmt.Sprint(tsAscending))
	return c
}

// Tzo sets the optional parameter "tzo": Timezone offset value.
func (c *OrganizationsEnvironmentsStatsGetCall) Tzo(tzo string) *OrganizationsEnvironmentsStatsGetCall {
	c.urlParams_.Set("tzo", tzo)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsStatsGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsStatsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsStatsGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsStatsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsStatsGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsStatsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsStatsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsStatsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.stats.get" call.
// Exactly one of *GoogleCloudApigeeV1Stats or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1Stats.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsStatsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Stats, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Stats{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Retrieve metrics grouped by dimensions. The types of metrics you can retrieve include traffic, message counts, API call latency, response size, and cache hits and counts. Dimensions let you view metrics in meaningful groups. You can optionally pass dimensions as path parameters to the `stats` API. If dimensions are not specified, the metrics are computed on the entire set of data for the given time range.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/stats/{statsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.stats.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "accuracy": {
	//       "description": "No longer used by Apigee. Supported for backwards compatibility.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "aggTable": {
	//       "description": "Table name used to query custom aggregate tables. If this parameter is skipped, then Apigee will try to retrieve the data from fact tables which will be expensive.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "filter": {
	//       "description": "Filter that enables you to drill down on specific dimension values.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "limit": {
	//       "description": "Maximum number of result items to return. The default and maximum value that can be returned is 14400.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "Required. Resource name for which the interactive query will be executed. Use the following format in your request: `organizations/{org}/environments/{env}/stats/{dimensions}` Dimensions let you view metrics in meaningful groupings, such as `apiproxy` or `target_host`. The value of dimensions should be a comma-separated list, as shown below: `organizations/{org}/environments/{env}/stats/apiproxy,request_verb`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/stats/.*$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "offset": {
	//       "description": "Offset value. Use `offset` with `limit` to enable pagination of results. For example, to display results 11-20, set limit to `10` and offset to `10`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "realtime": {
	//       "description": "No longer used by Apigee. Supported for backwards compatibility.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "select": {
	//       "description": "Comma-separated list of metrics. For example: `sum(message_count),sum(error_count)`",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "sonar": {
	//       "description": "Routes the query to API Monitoring for the last hour.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "sort": {
	//       "description": "Flag that specifies whether the sort order should be ascending or descending. Valid values include: `DESC` and `ASC`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "sortby": {
	//       "description": "Comma-separated list of columns to sort the final result.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "timeRange": {
	//       "description": "Time interval for the interactive query. Time range is specified in GMT as `start~end`. For example: `04/15/2017 00:00~05/15/2017 23:59`",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "timeUnit": {
	//       "description": "Granularity of metrics returned. Valid values include: `second`, `minute`, `hour`, `day`, `week`, or` month`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "topk": {
	//       "description": "Top number of results to return. For example, to return the top 5 results, set `topk=5`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "tsAscending": {
	//       "description": "Flag that specifies whether to list timestamps in ascending (`true`) or descending (`false`) order. Apigee recommends that you set this value to `true` if you are using `sortby` with `sort=DESC`.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "tzo": {
	//       "description": "Timezone offset value.",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Stats"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.targetservers.create":

type OrganizationsEnvironmentsTargetserversCreateCall struct {
	s                               *Service
	parent                          string
	googlecloudapigeev1targetserver *GoogleCloudApigeeV1TargetServer
	urlParams_                      gensupport.URLParams
	ctx_                            context.Context
	header_                         http.Header
}

// Create: Creates a TargetServer in the specified environment.
//
//   - parent: The parent environment name under which the TargetServer
//     will be created. Must be of the form
//     `organizations/{org}/environments/{env}`.
func (r *OrganizationsEnvironmentsTargetserversService) Create(parent string, googlecloudapigeev1targetserver *GoogleCloudApigeeV1TargetServer) *OrganizationsEnvironmentsTargetserversCreateCall {
	c := &OrganizationsEnvironmentsTargetserversCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1targetserver = googlecloudapigeev1targetserver
	return c
}

// Name sets the optional parameter "name": The ID to give the
// TargetServer. This will overwrite the value in TargetServer.
func (c *OrganizationsEnvironmentsTargetserversCreateCall) Name(name string) *OrganizationsEnvironmentsTargetserversCreateCall {
	c.urlParams_.Set("name", name)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsTargetserversCreateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsTargetserversCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsTargetserversCreateCall) Context(ctx context.Context) *OrganizationsEnvironmentsTargetserversCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsTargetserversCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsTargetserversCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1targetserver)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/targetservers")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.targetservers.create" call.
// Exactly one of *GoogleCloudApigeeV1TargetServer or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1TargetServer.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsTargetserversCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1TargetServer, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1TargetServer{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a TargetServer in the specified environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/targetservers",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.targetservers.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Optional. The ID to give the TargetServer. This will overwrite the value in TargetServer.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. The parent environment name under which the TargetServer will be created. Must be of the form `organizations/{org}/environments/{env}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/targetservers",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1TargetServer"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1TargetServer"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.targetservers.delete":

type OrganizationsEnvironmentsTargetserversDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a TargetServer from an environment. Returns the
// deleted TargetServer resource.
//
//   - name: The name of the TargetServer to delete. Must be of the form
//     `organizations/{org}/environments/{env}/targetservers/{target_server
//     _id}`.
func (r *OrganizationsEnvironmentsTargetserversService) Delete(name string) *OrganizationsEnvironmentsTargetserversDeleteCall {
	c := &OrganizationsEnvironmentsTargetserversDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsTargetserversDeleteCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsTargetserversDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsTargetserversDeleteCall) Context(ctx context.Context) *OrganizationsEnvironmentsTargetserversDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsTargetserversDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsTargetserversDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.targetservers.delete" call.
// Exactly one of *GoogleCloudApigeeV1TargetServer or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1TargetServer.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsTargetserversDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1TargetServer, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1TargetServer{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a TargetServer from an environment. Returns the deleted TargetServer resource.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/targetservers/{targetserversId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.environments.targetservers.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the TargetServer to delete. Must be of the form `organizations/{org}/environments/{env}/targetservers/{target_server_id}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/targetservers/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1TargetServer"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.targetservers.get":

type OrganizationsEnvironmentsTargetserversGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets a TargetServer resource.
//
//   - name: The name of the TargetServer to get. Must be of the form
//     `organizations/{org}/environments/{env}/targetservers/{target_server
//     _id}`.
func (r *OrganizationsEnvironmentsTargetserversService) Get(name string) *OrganizationsEnvironmentsTargetserversGetCall {
	c := &OrganizationsEnvironmentsTargetserversGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsTargetserversGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsTargetserversGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsTargetserversGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsTargetserversGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsTargetserversGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsTargetserversGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsTargetserversGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsTargetserversGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.targetservers.get" call.
// Exactly one of *GoogleCloudApigeeV1TargetServer or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1TargetServer.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsTargetserversGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1TargetServer, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1TargetServer{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets a TargetServer resource.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/targetservers/{targetserversId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.targetservers.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the TargetServer to get. Must be of the form `organizations/{org}/environments/{env}/targetservers/{target_server_id}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/targetservers/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1TargetServer"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.targetservers.update":

type OrganizationsEnvironmentsTargetserversUpdateCall struct {
	s                               *Service
	name                            string
	googlecloudapigeev1targetserver *GoogleCloudApigeeV1TargetServer
	urlParams_                      gensupport.URLParams
	ctx_                            context.Context
	header_                         http.Header
}

// Update: Updates an existing TargetServer. Note that this operation
// has PUT semantics; it will replace the entirety of the existing
// TargetServer with the resource in the request body.
//
//   - name: The name of the TargetServer to replace. Must be of the form
//     `organizations/{org}/environments/{env}/targetservers/{target_server
//     _id}`.
func (r *OrganizationsEnvironmentsTargetserversService) Update(name string, googlecloudapigeev1targetserver *GoogleCloudApigeeV1TargetServer) *OrganizationsEnvironmentsTargetserversUpdateCall {
	c := &OrganizationsEnvironmentsTargetserversUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1targetserver = googlecloudapigeev1targetserver
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsTargetserversUpdateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsTargetserversUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsTargetserversUpdateCall) Context(ctx context.Context) *OrganizationsEnvironmentsTargetserversUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsTargetserversUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsTargetserversUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1targetserver)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.targetservers.update" call.
// Exactly one of *GoogleCloudApigeeV1TargetServer or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1TargetServer.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsTargetserversUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1TargetServer, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1TargetServer{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates an existing TargetServer. Note that this operation has PUT semantics; it will replace the entirety of the existing TargetServer with the resource in the request body.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/targetservers/{targetserversId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.environments.targetservers.update",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the TargetServer to replace. Must be of the form `organizations/{org}/environments/{env}/targetservers/{target_server_id}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/targetservers/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1TargetServer"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1TargetServer"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.traceConfig.overrides.create":

type OrganizationsEnvironmentsTraceConfigOverridesCreateCall struct {
	s                                      *Service
	parent                                 string
	googlecloudapigeev1traceconfigoverride *GoogleCloudApigeeV1TraceConfigOverride
	urlParams_                             gensupport.URLParams
	ctx_                                   context.Context
	header_                                http.Header
}

// Create: Creates a trace configuration override. The response contains
// a system-generated UUID, that can be used to view, update, or delete
// the configuration override. Use the List API to view the existing
// trace configuration overrides.
//
//   - parent: Parent resource of the trace configuration override. Use
//     the following structure in your request.
//     "organizations/*/environments/*/traceConfig".
func (r *OrganizationsEnvironmentsTraceConfigOverridesService) Create(parent string, googlecloudapigeev1traceconfigoverride *GoogleCloudApigeeV1TraceConfigOverride) *OrganizationsEnvironmentsTraceConfigOverridesCreateCall {
	c := &OrganizationsEnvironmentsTraceConfigOverridesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1traceconfigoverride = googlecloudapigeev1traceconfigoverride
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsTraceConfigOverridesCreateCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsTraceConfigOverridesCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsTraceConfigOverridesCreateCall) Context(ctx context.Context) *OrganizationsEnvironmentsTraceConfigOverridesCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsTraceConfigOverridesCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsTraceConfigOverridesCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1traceconfigoverride)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/overrides")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.traceConfig.overrides.create" call.
// Exactly one of *GoogleCloudApigeeV1TraceConfigOverride or error will
// be non-nil. Any non-2xx status code is an error. Response headers are
// in either
// *GoogleCloudApigeeV1TraceConfigOverride.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsTraceConfigOverridesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1TraceConfigOverride, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1TraceConfigOverride{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a trace configuration override. The response contains a system-generated UUID, that can be used to view, update, or delete the configuration override. Use the List API to view the existing trace configuration overrides.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/traceConfig/overrides",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.environments.traceConfig.overrides.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Parent resource of the trace configuration override. Use the following structure in your request. \"organizations/*/environments/*/traceConfig\".",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/traceConfig$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/overrides",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1TraceConfigOverride"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1TraceConfigOverride"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.traceConfig.overrides.delete":

type OrganizationsEnvironmentsTraceConfigOverridesDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a distributed trace configuration override.
//
//   - name: Name of the trace configuration override. Use the following
//     structure in your request:
//     "organizations/*/environments/*/traceConfig/overrides/*".
func (r *OrganizationsEnvironmentsTraceConfigOverridesService) Delete(name string) *OrganizationsEnvironmentsTraceConfigOverridesDeleteCall {
	c := &OrganizationsEnvironmentsTraceConfigOverridesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsTraceConfigOverridesDeleteCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsTraceConfigOverridesDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsTraceConfigOverridesDeleteCall) Context(ctx context.Context) *OrganizationsEnvironmentsTraceConfigOverridesDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsTraceConfigOverridesDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsTraceConfigOverridesDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.traceConfig.overrides.delete" call.
// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsTraceConfigOverridesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleProtobufEmpty{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a distributed trace configuration override.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/traceConfig/overrides/{overridesId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.environments.traceConfig.overrides.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the trace configuration override. Use the following structure in your request: \"organizations/*/environments/*/traceConfig/overrides/*\".",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/traceConfig/overrides/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleProtobufEmpty"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.traceConfig.overrides.get":

type OrganizationsEnvironmentsTraceConfigOverridesGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets a trace configuration override.
//
//   - name: Name of the trace configuration override. Use the following
//     structure in your request:
//     "organizations/*/environments/*/traceConfig/overrides/*".
func (r *OrganizationsEnvironmentsTraceConfigOverridesService) Get(name string) *OrganizationsEnvironmentsTraceConfigOverridesGetCall {
	c := &OrganizationsEnvironmentsTraceConfigOverridesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsTraceConfigOverridesGetCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsTraceConfigOverridesGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsTraceConfigOverridesGetCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsTraceConfigOverridesGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsTraceConfigOverridesGetCall) Context(ctx context.Context) *OrganizationsEnvironmentsTraceConfigOverridesGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsTraceConfigOverridesGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsTraceConfigOverridesGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.traceConfig.overrides.get" call.
// Exactly one of *GoogleCloudApigeeV1TraceConfigOverride or error will
// be non-nil. Any non-2xx status code is an error. Response headers are
// in either
// *GoogleCloudApigeeV1TraceConfigOverride.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsTraceConfigOverridesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1TraceConfigOverride, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1TraceConfigOverride{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets a trace configuration override.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/traceConfig/overrides/{overridesId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.traceConfig.overrides.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the trace configuration override. Use the following structure in your request: \"organizations/*/environments/*/traceConfig/overrides/*\".",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/traceConfig/overrides/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1TraceConfigOverride"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.environments.traceConfig.overrides.list":

type OrganizationsEnvironmentsTraceConfigOverridesListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all of the distributed trace configuration overrides in
// an environment.
//
//   - parent: Parent resource of the trace configuration override. Use
//     the following structure in your request:
//     "organizations/*/environments/*/traceConfig".
func (r *OrganizationsEnvironmentsTraceConfigOverridesService) List(parent string) *OrganizationsEnvironmentsTraceConfigOverridesListCall {
	c := &OrganizationsEnvironmentsTraceConfigOverridesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// PageSize sets the optional parameter "pageSize": Maximum number of
// trace configuration overrides to return. If not specified, the
// maximum number returned is 25. The maximum number cannot exceed 100.
func (c *OrganizationsEnvironmentsTraceConfigOverridesListCall) PageSize(pageSize int64) *OrganizationsEnvironmentsTraceConfigOverridesListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": A page token,
// returned from a previous `ListTraceConfigOverrides` call. Token value
// that can be used to retrieve the subsequent page. When paginating,
// all other parameters provided to `ListTraceConfigOverrides` must
// match those specified in the call to obtain the page token.
func (c *OrganizationsEnvironmentsTraceConfigOverridesListCall) PageToken(pageToken string) *OrganizationsEnvironmentsTraceConfigOverridesListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsTraceConfigOverridesListCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsTraceConfigOverridesListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsEnvironmentsTraceConfigOverridesListCall) IfNoneMatch(entityTag string) *OrganizationsEnvironmentsTraceConfigOverridesListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsTraceConfigOverridesListCall) Context(ctx context.Context) *OrganizationsEnvironmentsTraceConfigOverridesListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsTraceConfigOverridesListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsTraceConfigOverridesListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/overrides")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.traceConfig.overrides.list" call.
// Exactly one of *GoogleCloudApigeeV1ListTraceConfigOverridesResponse
// or error will be non-nil. Any non-2xx status code is an error.
// Response headers are in either
// *GoogleCloudApigeeV1ListTraceConfigOverridesResponse.ServerResponse.He
// ader or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsEnvironmentsTraceConfigOverridesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListTraceConfigOverridesResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListTraceConfigOverridesResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all of the distributed trace configuration overrides in an environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/traceConfig/overrides",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.environments.traceConfig.overrides.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "pageSize": {
	//       "description": "Maximum number of trace configuration overrides to return. If not specified, the maximum number returned is 25. The maximum number cannot exceed 100.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "A page token, returned from a previous `ListTraceConfigOverrides` call. Token value that can be used to retrieve the subsequent page. When paginating, all other parameters provided to `ListTraceConfigOverrides` must match those specified in the call to obtain the page token.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Parent resource of the trace configuration override. Use the following structure in your request: \"organizations/*/environments/*/traceConfig\".",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/traceConfig$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/overrides",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListTraceConfigOverridesResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsEnvironmentsTraceConfigOverridesListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListTraceConfigOverridesResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.environments.traceConfig.overrides.patch":

type OrganizationsEnvironmentsTraceConfigOverridesPatchCall struct {
	s                                      *Service
	name                                   string
	googlecloudapigeev1traceconfigoverride *GoogleCloudApigeeV1TraceConfigOverride
	urlParams_                             gensupport.URLParams
	ctx_                                   context.Context
	header_                                http.Header
}

// Patch: Updates a distributed trace configuration override. Note that
// the repeated fields have replace semantics when included in the field
// mask and that they will be overwritten by the value of the fields in
// the request body.
//
//   - name: Name of the trace configuration override. Use the following
//     structure in your request:
//     "organizations/*/environments/*/traceConfig/overrides/*".
func (r *OrganizationsEnvironmentsTraceConfigOverridesService) Patch(name string, googlecloudapigeev1traceconfigoverride *GoogleCloudApigeeV1TraceConfigOverride) *OrganizationsEnvironmentsTraceConfigOverridesPatchCall {
	c := &OrganizationsEnvironmentsTraceConfigOverridesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1traceconfigoverride = googlecloudapigeev1traceconfigoverride
	return c
}

// UpdateMask sets the optional parameter "updateMask": List of fields
// to be updated.
func (c *OrganizationsEnvironmentsTraceConfigOverridesPatchCall) UpdateMask(updateMask string) *OrganizationsEnvironmentsTraceConfigOverridesPatchCall {
	c.urlParams_.Set("updateMask", updateMask)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsEnvironmentsTraceConfigOverridesPatchCall) Fields(s ...googleapi.Field) *OrganizationsEnvironmentsTraceConfigOverridesPatchCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsEnvironmentsTraceConfigOverridesPatchCall) Context(ctx context.Context) *OrganizationsEnvironmentsTraceConfigOverridesPatchCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsEnvironmentsTraceConfigOverridesPatchCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsEnvironmentsTraceConfigOverridesPatchCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1traceconfigoverride)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PATCH", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.environments.traceConfig.overrides.patch" call.
// Exactly one of *GoogleCloudApigeeV1TraceConfigOverride or error will
// be non-nil. Any non-2xx status code is an error. Response headers are
// in either
// *GoogleCloudApigeeV1TraceConfigOverride.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsEnvironmentsTraceConfigOverridesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1TraceConfigOverride, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1TraceConfigOverride{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates a distributed trace configuration override. Note that the repeated fields have replace semantics when included in the field mask and that they will be overwritten by the value of the fields in the request body.",
	//   "flatPath": "v1/organizations/{organizationsId}/environments/{environmentsId}/traceConfig/overrides/{overridesId}",
	//   "httpMethod": "PATCH",
	//   "id": "apigee.organizations.environments.traceConfig.overrides.patch",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the trace configuration override. Use the following structure in your request: \"organizations/*/environments/*/traceConfig/overrides/*\".",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/environments/[^/]+/traceConfig/overrides/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "updateMask": {
	//       "description": "List of fields to be updated.",
	//       "format": "google-fieldmask",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1TraceConfigOverride"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1TraceConfigOverride"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.hostQueries.create":

type OrganizationsHostQueriesCreateCall struct {
	s                        *Service
	parent                   string
	googlecloudapigeev1query *GoogleCloudApigeeV1Query
	urlParams_               gensupport.URLParams
	ctx_                     context.Context
	header_                  http.Header
}

// Create: Submit a query at host level to be processed in the
// background. If the submission of the query succeeds, the API returns
// a 201 status and an ID that refer to the query. In addition to the
// HTTP status 201, the `state` of "enqueued" means that the request
// succeeded.
//
//   - parent: The parent resource name. Must be of the form
//     `organizations/{org}`.
func (r *OrganizationsHostQueriesService) Create(parent string, googlecloudapigeev1query *GoogleCloudApigeeV1Query) *OrganizationsHostQueriesCreateCall {
	c := &OrganizationsHostQueriesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1query = googlecloudapigeev1query
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsHostQueriesCreateCall) Fields(s ...googleapi.Field) *OrganizationsHostQueriesCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsHostQueriesCreateCall) Context(ctx context.Context) *OrganizationsHostQueriesCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsHostQueriesCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsHostQueriesCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1query)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/hostQueries")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.hostQueries.create" call.
// Exactly one of *GoogleCloudApigeeV1AsyncQuery or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1AsyncQuery.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsHostQueriesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AsyncQuery, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AsyncQuery{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Submit a query at host level to be processed in the background. If the submission of the query succeeds, the API returns a 201 status and an ID that refer to the query. In addition to the HTTP status 201, the `state` of \"enqueued\" means that the request succeeded.",
	//   "flatPath": "v1/organizations/{organizationsId}/hostQueries",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.hostQueries.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. The parent resource name. Must be of the form `organizations/{org}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/hostQueries",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Query"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AsyncQuery"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.hostQueries.get":

type OrganizationsHostQueriesGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Get status of a query submitted at host level. If the query is
// still in progress, the `state` is set to "running" After the query
// has completed successfully, `state` is set to "completed"
//
//   - name: Name of the asynchronous query to get. Must be of the form
//     `organizations/{org}/queries/{queryId}`.
func (r *OrganizationsHostQueriesService) Get(name string) *OrganizationsHostQueriesGetCall {
	c := &OrganizationsHostQueriesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsHostQueriesGetCall) Fields(s ...googleapi.Field) *OrganizationsHostQueriesGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsHostQueriesGetCall) IfNoneMatch(entityTag string) *OrganizationsHostQueriesGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsHostQueriesGetCall) Context(ctx context.Context) *OrganizationsHostQueriesGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsHostQueriesGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsHostQueriesGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.hostQueries.get" call.
// Exactly one of *GoogleCloudApigeeV1AsyncQuery or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1AsyncQuery.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsHostQueriesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AsyncQuery, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AsyncQuery{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Get status of a query submitted at host level. If the query is still in progress, the `state` is set to \"running\" After the query has completed successfully, `state` is set to \"completed\"",
	//   "flatPath": "v1/organizations/{organizationsId}/hostQueries/{hostQueriesId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.hostQueries.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the asynchronous query to get. Must be of the form `organizations/{org}/queries/{queryId}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/hostQueries/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AsyncQuery"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.hostQueries.getResult":

type OrganizationsHostQueriesGetResultCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetResult: After the query is completed, use this API to retrieve the
// results. If the request succeeds, and there is a non-zero result set,
// the result is downloaded to the client as a zipped JSON file. The
// name of the downloaded file will be: OfflineQueryResult-.zip Example:
// `OfflineQueryResult-9cfc0d85-0f30-46d6-ae6f-318d0cb961bd.zip`
//
//   - name: Name of the asynchronous query result to get. Must be of the
//     form `organizations/{org}/queries/{queryId}/result`.
func (r *OrganizationsHostQueriesService) GetResult(name string) *OrganizationsHostQueriesGetResultCall {
	c := &OrganizationsHostQueriesGetResultCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsHostQueriesGetResultCall) Fields(s ...googleapi.Field) *OrganizationsHostQueriesGetResultCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsHostQueriesGetResultCall) IfNoneMatch(entityTag string) *OrganizationsHostQueriesGetResultCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsHostQueriesGetResultCall) Context(ctx context.Context) *OrganizationsHostQueriesGetResultCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsHostQueriesGetResultCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsHostQueriesGetResultCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.hostQueries.getResult" call.
// Exactly one of *GoogleApiHttpBody or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleApiHttpBody.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsHostQueriesGetResultCall) Do(opts ...googleapi.CallOption) (*GoogleApiHttpBody, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleApiHttpBody{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "After the query is completed, use this API to retrieve the results. If the request succeeds, and there is a non-zero result set, the result is downloaded to the client as a zipped JSON file. The name of the downloaded file will be: OfflineQueryResult-.zip Example: `OfflineQueryResult-9cfc0d85-0f30-46d6-ae6f-318d0cb961bd.zip`",
	//   "flatPath": "v1/organizations/{organizationsId}/hostQueries/{hostQueriesId}/result",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.hostQueries.getResult",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the asynchronous query result to get. Must be of the form `organizations/{org}/queries/{queryId}/result`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/hostQueries/[^/]+/result$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleApiHttpBody"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.hostQueries.getResultView":

type OrganizationsHostQueriesGetResultViewCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetResultView:
//
//   - name: Name of the asynchronous query result view to get. Must be of
//     the form `organizations/{org}/queries/{queryId}/resultView`.
func (r *OrganizationsHostQueriesService) GetResultView(name string) *OrganizationsHostQueriesGetResultViewCall {
	c := &OrganizationsHostQueriesGetResultViewCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsHostQueriesGetResultViewCall) Fields(s ...googleapi.Field) *OrganizationsHostQueriesGetResultViewCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsHostQueriesGetResultViewCall) IfNoneMatch(entityTag string) *OrganizationsHostQueriesGetResultViewCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsHostQueriesGetResultViewCall) Context(ctx context.Context) *OrganizationsHostQueriesGetResultViewCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsHostQueriesGetResultViewCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsHostQueriesGetResultViewCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.hostQueries.getResultView" call.
// Exactly one of *GoogleCloudApigeeV1AsyncQueryResultView or error will
// be non-nil. Any non-2xx status code is an error. Response headers are
// in either
// *GoogleCloudApigeeV1AsyncQueryResultView.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsHostQueriesGetResultViewCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1AsyncQueryResultView, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1AsyncQueryResultView{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "",
	//   "flatPath": "v1/organizations/{organizationsId}/hostQueries/{hostQueriesId}/resultView",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.hostQueries.getResultView",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the asynchronous query result view to get. Must be of the form `organizations/{org}/queries/{queryId}/resultView`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/hostQueries/[^/]+/resultView$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1AsyncQueryResultView"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.hostQueries.list":

type OrganizationsHostQueriesListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Return a list of Asynchronous Queries at host level.
//
//   - parent: The parent resource name. Must be of the form
//     `organizations/{org}`.
func (r *OrganizationsHostQueriesService) List(parent string) *OrganizationsHostQueriesListCall {
	c := &OrganizationsHostQueriesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Dataset sets the optional parameter "dataset": Filter response list
// by dataset. Example: `api`, `mint`
func (c *OrganizationsHostQueriesListCall) Dataset(dataset string) *OrganizationsHostQueriesListCall {
	c.urlParams_.Set("dataset", dataset)
	return c
}

// EnvgroupHostname sets the optional parameter "envgroupHostname":
// Required. Filter response list by hostname.
func (c *OrganizationsHostQueriesListCall) EnvgroupHostname(envgroupHostname string) *OrganizationsHostQueriesListCall {
	c.urlParams_.Set("envgroupHostname", envgroupHostname)
	return c
}

// From sets the optional parameter "from": Filter response list by
// returning asynchronous queries that created after this date time.
// Time must be in ISO date-time format like '2011-12-03T10:15:30Z'.
func (c *OrganizationsHostQueriesListCall) From(from string) *OrganizationsHostQueriesListCall {
	c.urlParams_.Set("from", from)
	return c
}

// InclQueriesWithoutReport sets the optional parameter
// "inclQueriesWithoutReport": Flag to include asynchronous queries that
// don't have a report denifition.
func (c *OrganizationsHostQueriesListCall) InclQueriesWithoutReport(inclQueriesWithoutReport string) *OrganizationsHostQueriesListCall {
	c.urlParams_.Set("inclQueriesWithoutReport", inclQueriesWithoutReport)
	return c
}

// Status sets the optional parameter "status": Filter response list by
// asynchronous query status.
func (c *OrganizationsHostQueriesListCall) Status(status string) *OrganizationsHostQueriesListCall {
	c.urlParams_.Set("status", status)
	return c
}

// SubmittedBy sets the optional parameter "submittedBy": Filter
// response list by user who submitted queries.
func (c *OrganizationsHostQueriesListCall) SubmittedBy(submittedBy string) *OrganizationsHostQueriesListCall {
	c.urlParams_.Set("submittedBy", submittedBy)
	return c
}

// To sets the optional parameter "to": Filter response list by
// returning asynchronous queries that created before this date time.
// Time must be in ISO date-time format like '2011-12-03T10:16:30Z'.
func (c *OrganizationsHostQueriesListCall) To(to string) *OrganizationsHostQueriesListCall {
	c.urlParams_.Set("to", to)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsHostQueriesListCall) Fields(s ...googleapi.Field) *OrganizationsHostQueriesListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsHostQueriesListCall) IfNoneMatch(entityTag string) *OrganizationsHostQueriesListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsHostQueriesListCall) Context(ctx context.Context) *OrganizationsHostQueriesListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsHostQueriesListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsHostQueriesListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/hostQueries")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.hostQueries.list" call.
// Exactly one of *GoogleCloudApigeeV1ListAsyncQueriesResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListAsyncQueriesResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsHostQueriesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListAsyncQueriesResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListAsyncQueriesResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Return a list of Asynchronous Queries at host level.",
	//   "flatPath": "v1/organizations/{organizationsId}/hostQueries",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.hostQueries.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "dataset": {
	//       "description": "Filter response list by dataset. Example: `api`, `mint`",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "envgroupHostname": {
	//       "description": "Required. Filter response list by hostname.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "from": {
	//       "description": "Filter response list by returning asynchronous queries that created after this date time. Time must be in ISO date-time format like '2011-12-03T10:15:30Z'.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "inclQueriesWithoutReport": {
	//       "description": "Flag to include asynchronous queries that don't have a report denifition.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. The parent resource name. Must be of the form `organizations/{org}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "status": {
	//       "description": "Filter response list by asynchronous query status.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "submittedBy": {
	//       "description": "Filter response list by user who submitted queries.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "to": {
	//       "description": "Filter response list by returning asynchronous queries that created before this date time. Time must be in ISO date-time format like '2011-12-03T10:16:30Z'.",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/hostQueries",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListAsyncQueriesResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.hostSecurityReports.create":

type OrganizationsHostSecurityReportsCreateCall struct {
	s                                      *Service
	parent                                 string
	googlecloudapigeev1securityreportquery *GoogleCloudApigeeV1SecurityReportQuery
	urlParams_                             gensupport.URLParams
	ctx_                                   context.Context
	header_                                http.Header
}

// Create: Submit a query at host level to be processed in the
// background. If the submission of the query succeeds, the API returns
// a 201 status and an ID that refer to the query. In addition to the
// HTTP status 201, the `state` of "enqueued" means that the request
// succeeded.
//
//   - parent: The parent resource name. Must be of the form
//     `organizations/{org}`.
func (r *OrganizationsHostSecurityReportsService) Create(parent string, googlecloudapigeev1securityreportquery *GoogleCloudApigeeV1SecurityReportQuery) *OrganizationsHostSecurityReportsCreateCall {
	c := &OrganizationsHostSecurityReportsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1securityreportquery = googlecloudapigeev1securityreportquery
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsHostSecurityReportsCreateCall) Fields(s ...googleapi.Field) *OrganizationsHostSecurityReportsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsHostSecurityReportsCreateCall) Context(ctx context.Context) *OrganizationsHostSecurityReportsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsHostSecurityReportsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsHostSecurityReportsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1securityreportquery)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/hostSecurityReports")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.hostSecurityReports.create" call.
// Exactly one of *GoogleCloudApigeeV1SecurityReport or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SecurityReport.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsHostSecurityReportsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityReport, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityReport{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Submit a query at host level to be processed in the background. If the submission of the query succeeds, the API returns a 201 status and an ID that refer to the query. In addition to the HTTP status 201, the `state` of \"enqueued\" means that the request succeeded.",
	//   "flatPath": "v1/organizations/{organizationsId}/hostSecurityReports",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.hostSecurityReports.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. The parent resource name. Must be of the form `organizations/{org}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/hostSecurityReports",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1SecurityReportQuery"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityReport"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.hostSecurityReports.get":

type OrganizationsHostSecurityReportsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Get status of a query submitted at host level. If the query is
// still in progress, the `state` is set to "running" After the query
// has completed successfully, `state` is set to "completed"
//
//   - name: Name of the security report to get. Must be of the form
//     `organizations/{org}/securityReports/{reportId}`.
func (r *OrganizationsHostSecurityReportsService) Get(name string) *OrganizationsHostSecurityReportsGetCall {
	c := &OrganizationsHostSecurityReportsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsHostSecurityReportsGetCall) Fields(s ...googleapi.Field) *OrganizationsHostSecurityReportsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsHostSecurityReportsGetCall) IfNoneMatch(entityTag string) *OrganizationsHostSecurityReportsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsHostSecurityReportsGetCall) Context(ctx context.Context) *OrganizationsHostSecurityReportsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsHostSecurityReportsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsHostSecurityReportsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.hostSecurityReports.get" call.
// Exactly one of *GoogleCloudApigeeV1SecurityReport or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SecurityReport.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsHostSecurityReportsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityReport, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityReport{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Get status of a query submitted at host level. If the query is still in progress, the `state` is set to \"running\" After the query has completed successfully, `state` is set to \"completed\"",
	//   "flatPath": "v1/organizations/{organizationsId}/hostSecurityReports/{hostSecurityReportsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.hostSecurityReports.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the security report to get. Must be of the form `organizations/{org}/securityReports/{reportId}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/hostSecurityReports/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityReport"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.hostSecurityReports.getResult":

type OrganizationsHostSecurityReportsGetResultCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetResult: After the query is completed, use this API to retrieve the
// results. If the request succeeds, and there is a non-zero result set,
// the result is downloaded to the client as a zipped JSON file. The
// name of the downloaded file will be: OfflineQueryResult-.zip Example:
// `OfflineQueryResult-9cfc0d85-0f30-46d6-ae6f-318d0cb961bd.zip`
//
//   - name: Name of the security report result to get. Must be of the
//     form `organizations/{org}/securityReports/{reportId}/result`.
func (r *OrganizationsHostSecurityReportsService) GetResult(name string) *OrganizationsHostSecurityReportsGetResultCall {
	c := &OrganizationsHostSecurityReportsGetResultCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsHostSecurityReportsGetResultCall) Fields(s ...googleapi.Field) *OrganizationsHostSecurityReportsGetResultCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsHostSecurityReportsGetResultCall) IfNoneMatch(entityTag string) *OrganizationsHostSecurityReportsGetResultCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsHostSecurityReportsGetResultCall) Context(ctx context.Context) *OrganizationsHostSecurityReportsGetResultCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsHostSecurityReportsGetResultCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsHostSecurityReportsGetResultCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.hostSecurityReports.getResult" call.
// Exactly one of *GoogleApiHttpBody or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleApiHttpBody.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsHostSecurityReportsGetResultCall) Do(opts ...googleapi.CallOption) (*GoogleApiHttpBody, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleApiHttpBody{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "After the query is completed, use this API to retrieve the results. If the request succeeds, and there is a non-zero result set, the result is downloaded to the client as a zipped JSON file. The name of the downloaded file will be: OfflineQueryResult-.zip Example: `OfflineQueryResult-9cfc0d85-0f30-46d6-ae6f-318d0cb961bd.zip`",
	//   "flatPath": "v1/organizations/{organizationsId}/hostSecurityReports/{hostSecurityReportsId}/result",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.hostSecurityReports.getResult",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the security report result to get. Must be of the form `organizations/{org}/securityReports/{reportId}/result`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/hostSecurityReports/[^/]+/result$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleApiHttpBody"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.hostSecurityReports.getResultView":

type OrganizationsHostSecurityReportsGetResultViewCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetResultView: After the query is completed, use this API to view the
// query result when result size is small.
//
//   - name: Name of the security report result view to get. Must be of
//     the form
//     `organizations/{org}/securityReports/{reportId}/resultView`.
func (r *OrganizationsHostSecurityReportsService) GetResultView(name string) *OrganizationsHostSecurityReportsGetResultViewCall {
	c := &OrganizationsHostSecurityReportsGetResultViewCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsHostSecurityReportsGetResultViewCall) Fields(s ...googleapi.Field) *OrganizationsHostSecurityReportsGetResultViewCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsHostSecurityReportsGetResultViewCall) IfNoneMatch(entityTag string) *OrganizationsHostSecurityReportsGetResultViewCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsHostSecurityReportsGetResultViewCall) Context(ctx context.Context) *OrganizationsHostSecurityReportsGetResultViewCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsHostSecurityReportsGetResultViewCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsHostSecurityReportsGetResultViewCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.hostSecurityReports.getResultView" call.
// Exactly one of *GoogleCloudApigeeV1SecurityReportResultView or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1SecurityReportResultView.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsHostSecurityReportsGetResultViewCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityReportResultView, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityReportResultView{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "After the query is completed, use this API to view the query result when result size is small.",
	//   "flatPath": "v1/organizations/{organizationsId}/hostSecurityReports/{hostSecurityReportsId}/resultView",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.hostSecurityReports.getResultView",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the security report result view to get. Must be of the form `organizations/{org}/securityReports/{reportId}/resultView`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/hostSecurityReports/[^/]+/resultView$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityReportResultView"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.hostSecurityReports.list":

type OrganizationsHostSecurityReportsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Return a list of Security Reports at host level.
//
//   - parent: The parent resource name. Must be of the form
//     `organizations/{org}`.
func (r *OrganizationsHostSecurityReportsService) List(parent string) *OrganizationsHostSecurityReportsListCall {
	c := &OrganizationsHostSecurityReportsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Dataset sets the optional parameter "dataset": Filter response list
// by dataset. Example: `api`, `mint`
func (c *OrganizationsHostSecurityReportsListCall) Dataset(dataset string) *OrganizationsHostSecurityReportsListCall {
	c.urlParams_.Set("dataset", dataset)
	return c
}

// EnvgroupHostname sets the optional parameter "envgroupHostname":
// Required. Filter response list by hostname.
func (c *OrganizationsHostSecurityReportsListCall) EnvgroupHostname(envgroupHostname string) *OrganizationsHostSecurityReportsListCall {
	c.urlParams_.Set("envgroupHostname", envgroupHostname)
	return c
}

// From sets the optional parameter "from": Filter response list by
// returning security reports that created after this date time. Time
// must be in ISO date-time format like '2011-12-03T10:15:30Z'.
func (c *OrganizationsHostSecurityReportsListCall) From(from string) *OrganizationsHostSecurityReportsListCall {
	c.urlParams_.Set("from", from)
	return c
}

// PageSize sets the optional parameter "pageSize": The maximum number
// of security report to return in the list response.
func (c *OrganizationsHostSecurityReportsListCall) PageSize(pageSize int64) *OrganizationsHostSecurityReportsListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": Token returned
// from the previous list response to fetch the next page.
func (c *OrganizationsHostSecurityReportsListCall) PageToken(pageToken string) *OrganizationsHostSecurityReportsListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Status sets the optional parameter "status": Filter response list by
// security report status.
func (c *OrganizationsHostSecurityReportsListCall) Status(status string) *OrganizationsHostSecurityReportsListCall {
	c.urlParams_.Set("status", status)
	return c
}

// SubmittedBy sets the optional parameter "submittedBy": Filter
// response list by user who submitted queries.
func (c *OrganizationsHostSecurityReportsListCall) SubmittedBy(submittedBy string) *OrganizationsHostSecurityReportsListCall {
	c.urlParams_.Set("submittedBy", submittedBy)
	return c
}

// To sets the optional parameter "to": Filter response list by
// returning security reports that created before this date time. Time
// must be in ISO date-time format like '2011-12-03T10:16:30Z'.
func (c *OrganizationsHostSecurityReportsListCall) To(to string) *OrganizationsHostSecurityReportsListCall {
	c.urlParams_.Set("to", to)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsHostSecurityReportsListCall) Fields(s ...googleapi.Field) *OrganizationsHostSecurityReportsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsHostSecurityReportsListCall) IfNoneMatch(entityTag string) *OrganizationsHostSecurityReportsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsHostSecurityReportsListCall) Context(ctx context.Context) *OrganizationsHostSecurityReportsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsHostSecurityReportsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsHostSecurityReportsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/hostSecurityReports")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.hostSecurityReports.list" call.
// Exactly one of *GoogleCloudApigeeV1ListSecurityReportsResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListSecurityReportsResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsHostSecurityReportsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListSecurityReportsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListSecurityReportsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Return a list of Security Reports at host level.",
	//   "flatPath": "v1/organizations/{organizationsId}/hostSecurityReports",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.hostSecurityReports.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "dataset": {
	//       "description": "Filter response list by dataset. Example: `api`, `mint`",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "envgroupHostname": {
	//       "description": "Required. Filter response list by hostname.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "from": {
	//       "description": "Filter response list by returning security reports that created after this date time. Time must be in ISO date-time format like '2011-12-03T10:15:30Z'.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "pageSize": {
	//       "description": "The maximum number of security report to return in the list response.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Token returned from the previous list response to fetch the next page.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. The parent resource name. Must be of the form `organizations/{org}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "status": {
	//       "description": "Filter response list by security report status.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "submittedBy": {
	//       "description": "Filter response list by user who submitted queries.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "to": {
	//       "description": "Filter response list by returning security reports that created before this date time. Time must be in ISO date-time format like '2011-12-03T10:16:30Z'.",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/hostSecurityReports",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListSecurityReportsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsHostSecurityReportsListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListSecurityReportsResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.hostStats.get":

type OrganizationsHostStatsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Retrieve metrics grouped by dimensions in host level. The types
// of metrics you can retrieve include traffic, message counts, API call
// latency, response size, and cache hits and counts. Dimensions let you
// view metrics in meaningful groups. You can optionally pass dimensions
// as path parameters to the `stats` API. If dimensions are not
// specified, the metrics are computed on the entire set of data for the
// given time range.
//
//   - name: Resource name for which the interactive query will be
//     executed. Use the following format in your request:
//     `organizations/{org}/hostStats/{dimensions}` Dimensions let you
//     view metrics in meaningful groupings, such as `apiproxy`,
//     `target_host`. The value of dimensions should be a comma-separated
//     list as shown below
//     `organizations/{org}/hostStats/apiproxy,request_verb`.
func (r *OrganizationsHostStatsService) Get(name string) *OrganizationsHostStatsGetCall {
	c := &OrganizationsHostStatsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Accuracy sets the optional parameter "accuracy": No longer used by
// Apigee. Supported for backwards compatibility.
func (c *OrganizationsHostStatsGetCall) Accuracy(accuracy string) *OrganizationsHostStatsGetCall {
	c.urlParams_.Set("accuracy", accuracy)
	return c
}

// EnvgroupHostname sets the optional parameter "envgroupHostname":
// Required. Hostname for which the interactive query will be executed.
func (c *OrganizationsHostStatsGetCall) EnvgroupHostname(envgroupHostname string) *OrganizationsHostStatsGetCall {
	c.urlParams_.Set("envgroupHostname", envgroupHostname)
	return c
}

// Filter sets the optional parameter "filter": Flag that enables
// drill-down on specific dimension values.
func (c *OrganizationsHostStatsGetCall) Filter(filter string) *OrganizationsHostStatsGetCall {
	c.urlParams_.Set("filter", filter)
	return c
}

// Limit sets the optional parameter "limit": Maximum number of result
// items to return. The default and maximum value that can be returned
// is 14400.
func (c *OrganizationsHostStatsGetCall) Limit(limit string) *OrganizationsHostStatsGetCall {
	c.urlParams_.Set("limit", limit)
	return c
}

// Offset sets the optional parameter "offset": Offset value. Use
// `offset` with `limit` to enable pagination of results. For example,
// to display results 11-20, set limit to `10` and offset to `10`.
func (c *OrganizationsHostStatsGetCall) Offset(offset string) *OrganizationsHostStatsGetCall {
	c.urlParams_.Set("offset", offset)
	return c
}

// Realtime sets the optional parameter "realtime": No longer used by
// Apigee. Supported for backwards compatibility.
func (c *OrganizationsHostStatsGetCall) Realtime(realtime bool) *OrganizationsHostStatsGetCall {
	c.urlParams_.Set("realtime", fmt.Sprint(realtime))
	return c
}

// Select sets the optional parameter "select": Comma-separated list of
// metrics. For example: `sum(message_count),sum(error_count)`
func (c *OrganizationsHostStatsGetCall) Select(select_ string) *OrganizationsHostStatsGetCall {
	c.urlParams_.Set("select", select_)
	return c
}

// Sort sets the optional parameter "sort": Flag that specifies if the
// sort order should be ascending or descending. Valid values are `DESC`
// and `ASC`.
func (c *OrganizationsHostStatsGetCall) Sort(sort string) *OrganizationsHostStatsGetCall {
	c.urlParams_.Set("sort", sort)
	return c
}

// Sortby sets the optional parameter "sortby": Comma-separated list of
// columns to sort the final result.
func (c *OrganizationsHostStatsGetCall) Sortby(sortby string) *OrganizationsHostStatsGetCall {
	c.urlParams_.Set("sortby", sortby)
	return c
}

// TimeRange sets the optional parameter "timeRange": Time interval for
// the interactive query. Time range is specified in GMT as `start~end`.
// For example: `04/15/2017 00:00~05/15/2017 23:59`
func (c *OrganizationsHostStatsGetCall) TimeRange(timeRange string) *OrganizationsHostStatsGetCall {
	c.urlParams_.Set("timeRange", timeRange)
	return c
}

// TimeUnit sets the optional parameter "timeUnit": Granularity of
// metrics returned. Valid values include: `second`, `minute`, `hour`,
// `day`, `week`, or `month`.
func (c *OrganizationsHostStatsGetCall) TimeUnit(timeUnit string) *OrganizationsHostStatsGetCall {
	c.urlParams_.Set("timeUnit", timeUnit)
	return c
}

// Topk sets the optional parameter "topk": Top number of results to
// return. For example, to return the top 5 results, set `topk=5`.
func (c *OrganizationsHostStatsGetCall) Topk(topk string) *OrganizationsHostStatsGetCall {
	c.urlParams_.Set("topk", topk)
	return c
}

// TsAscending sets the optional parameter "tsAscending": Flag that
// specifies whether to list timestamps in ascending (`true`) or
// descending (`false`) order. Apigee recommends that you set this value
// to `true` if you are using `sortby` with `sort=DESC`.
func (c *OrganizationsHostStatsGetCall) TsAscending(tsAscending bool) *OrganizationsHostStatsGetCall {
	c.urlParams_.Set("tsAscending", fmt.Sprint(tsAscending))
	return c
}

// Tzo sets the optional parameter "tzo": Timezone offset value.
func (c *OrganizationsHostStatsGetCall) Tzo(tzo string) *OrganizationsHostStatsGetCall {
	c.urlParams_.Set("tzo", tzo)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsHostStatsGetCall) Fields(s ...googleapi.Field) *OrganizationsHostStatsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsHostStatsGetCall) IfNoneMatch(entityTag string) *OrganizationsHostStatsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsHostStatsGetCall) Context(ctx context.Context) *OrganizationsHostStatsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsHostStatsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsHostStatsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.hostStats.get" call.
// Exactly one of *GoogleCloudApigeeV1Stats or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1Stats.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsHostStatsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Stats, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Stats{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Retrieve metrics grouped by dimensions in host level. The types of metrics you can retrieve include traffic, message counts, API call latency, response size, and cache hits and counts. Dimensions let you view metrics in meaningful groups. You can optionally pass dimensions as path parameters to the `stats` API. If dimensions are not specified, the metrics are computed on the entire set of data for the given time range.",
	//   "flatPath": "v1/organizations/{organizationsId}/hostStats/{hostStatsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.hostStats.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "accuracy": {
	//       "description": "No longer used by Apigee. Supported for backwards compatibility.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "envgroupHostname": {
	//       "description": "Required. Hostname for which the interactive query will be executed.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "filter": {
	//       "description": "Flag that enables drill-down on specific dimension values.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "limit": {
	//       "description": "Maximum number of result items to return. The default and maximum value that can be returned is 14400.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "Required. Resource name for which the interactive query will be executed. Use the following format in your request: `organizations/{org}/hostStats/{dimensions}` Dimensions let you view metrics in meaningful groupings, such as `apiproxy`, `target_host`. The value of dimensions should be a comma-separated list as shown below `organizations/{org}/hostStats/apiproxy,request_verb`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/hostStats/.*$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "offset": {
	//       "description": "Offset value. Use `offset` with `limit` to enable pagination of results. For example, to display results 11-20, set limit to `10` and offset to `10`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "realtime": {
	//       "description": "No longer used by Apigee. Supported for backwards compatibility.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "select": {
	//       "description": "Comma-separated list of metrics. For example: `sum(message_count),sum(error_count)`",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "sort": {
	//       "description": "Flag that specifies if the sort order should be ascending or descending. Valid values are `DESC` and `ASC`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "sortby": {
	//       "description": "Comma-separated list of columns to sort the final result.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "timeRange": {
	//       "description": "Time interval for the interactive query. Time range is specified in GMT as `start~end`. For example: `04/15/2017 00:00~05/15/2017 23:59`",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "timeUnit": {
	//       "description": "Granularity of metrics returned. Valid values include: `second`, `minute`, `hour`, `day`, `week`, or `month`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "topk": {
	//       "description": "Top number of results to return. For example, to return the top 5 results, set `topk=5`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "tsAscending": {
	//       "description": "Flag that specifies whether to list timestamps in ascending (`true`) or descending (`false`) order. Apigee recommends that you set this value to `true` if you are using `sortby` with `sort=DESC`.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "tzo": {
	//       "description": "Timezone offset value.",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Stats"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.instances.create":

type OrganizationsInstancesCreateCall struct {
	s                           *Service
	parent                      string
	googlecloudapigeev1instance *GoogleCloudApigeeV1Instance
	urlParams_                  gensupport.URLParams
	ctx_                        context.Context
	header_                     http.Header
}

// Create: Creates an Apigee runtime instance. The instance is
// accessible from the authorized network configured on the
// organization. **Note:** Not supported for Apigee hybrid.
//
//   - parent: Name of the organization. Use the following structure in
//     your request: `organizations/{org}`.
func (r *OrganizationsInstancesService) Create(parent string, googlecloudapigeev1instance *GoogleCloudApigeeV1Instance) *OrganizationsInstancesCreateCall {
	c := &OrganizationsInstancesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1instance = googlecloudapigeev1instance
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsInstancesCreateCall) Fields(s ...googleapi.Field) *OrganizationsInstancesCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsInstancesCreateCall) Context(ctx context.Context) *OrganizationsInstancesCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsInstancesCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsInstancesCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1instance)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/instances")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.instances.create" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsInstancesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates an Apigee runtime instance. The instance is accessible from the authorized network configured on the organization. **Note:** Not supported for Apigee hybrid.",
	//   "flatPath": "v1/organizations/{organizationsId}/instances",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.instances.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the organization. Use the following structure in your request: `organizations/{org}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/instances",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Instance"
	//   },
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.instances.delete":

type OrganizationsInstancesDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an Apigee runtime instance. The instance stops
// serving requests and the runtime data is deleted. **Note:** Not
// supported for Apigee hybrid.
//
//   - name: Name of the instance. Use the following structure in your
//     request: `organizations/{org}/instances/{instance}`.
func (r *OrganizationsInstancesService) Delete(name string) *OrganizationsInstancesDeleteCall {
	c := &OrganizationsInstancesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsInstancesDeleteCall) Fields(s ...googleapi.Field) *OrganizationsInstancesDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsInstancesDeleteCall) Context(ctx context.Context) *OrganizationsInstancesDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsInstancesDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsInstancesDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.instances.delete" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsInstancesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an Apigee runtime instance. The instance stops serving requests and the runtime data is deleted. **Note:** Not supported for Apigee hybrid.",
	//   "flatPath": "v1/organizations/{organizationsId}/instances/{instancesId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.instances.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the instance. Use the following structure in your request: `organizations/{org}/instances/{instance}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/instances/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.instances.get":

type OrganizationsInstancesGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets the details for an Apigee runtime instance. **Note:** Not
// supported for Apigee hybrid.
//
//   - name: Name of the instance. Use the following structure in your
//     request: `organizations/{org}/instances/{instance}`.
func (r *OrganizationsInstancesService) Get(name string) *OrganizationsInstancesGetCall {
	c := &OrganizationsInstancesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsInstancesGetCall) Fields(s ...googleapi.Field) *OrganizationsInstancesGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsInstancesGetCall) IfNoneMatch(entityTag string) *OrganizationsInstancesGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsInstancesGetCall) Context(ctx context.Context) *OrganizationsInstancesGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsInstancesGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsInstancesGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.instances.get" call.
// Exactly one of *GoogleCloudApigeeV1Instance or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleCloudApigeeV1Instance.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsInstancesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1Instance, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1Instance{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the details for an Apigee runtime instance. **Note:** Not supported for Apigee hybrid.",
	//   "flatPath": "v1/organizations/{organizationsId}/instances/{instancesId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.instances.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the instance. Use the following structure in your request: `organizations/{org}/instances/{instance}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/instances/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1Instance"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.instances.list":

type OrganizationsInstancesListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all Apigee runtime instances for the organization.
// **Note:** Not supported for Apigee hybrid.
//
//   - parent: Name of the organization. Use the following structure in
//     your request: `organizations/{org}`.
func (r *OrganizationsInstancesService) List(parent string) *OrganizationsInstancesListCall {
	c := &OrganizationsInstancesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// PageSize sets the optional parameter "pageSize": Maximum number of
// instances to return. Defaults to 25.
func (c *OrganizationsInstancesListCall) PageSize(pageSize int64) *OrganizationsInstancesListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": Page token,
// returned from a previous ListInstances call, that you can use to
// retrieve the next page of content.
func (c *OrganizationsInstancesListCall) PageToken(pageToken string) *OrganizationsInstancesListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsInstancesListCall) Fields(s ...googleapi.Field) *OrganizationsInstancesListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsInstancesListCall) IfNoneMatch(entityTag string) *OrganizationsInstancesListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsInstancesListCall) Context(ctx context.Context) *OrganizationsInstancesListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsInstancesListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsInstancesListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/instances")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.instances.list" call.
// Exactly one of *GoogleCloudApigeeV1ListInstancesResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListInstancesResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsInstancesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListInstancesResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListInstancesResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all Apigee runtime instances for the organization. **Note:** Not supported for Apigee hybrid.",
	//   "flatPath": "v1/organizations/{organizationsId}/instances",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.instances.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "pageSize": {
	//       "description": "Maximum number of instances to return. Defaults to 25.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Page token, returned from a previous ListInstances call, that you can use to retrieve the next page of content.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the organization. Use the following structure in your request: `organizations/{org}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/instances",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListInstancesResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsInstancesListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListInstancesResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.instances.patch":

type OrganizationsInstancesPatchCall struct {
	s                           *Service
	name                        string
	googlecloudapigeev1instance *GoogleCloudApigeeV1Instance
	urlParams_                  gensupport.URLParams
	ctx_                        context.Context
	header_                     http.Header
}

// Patch: Updates an Apigee runtime instance. You can update the fields
// described in NodeConfig. No other fields will be updated. **Note:**
// Not supported for Apigee hybrid.
//
//   - name: Name of the instance. Use the following structure in your
//     request: `organizations/{org}/instances/{instance}`.
func (r *OrganizationsInstancesService) Patch(name string, googlecloudapigeev1instance *GoogleCloudApigeeV1Instance) *OrganizationsInstancesPatchCall {
	c := &OrganizationsInstancesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1instance = googlecloudapigeev1instance
	return c
}

// UpdateMask sets the optional parameter "updateMask": List of fields
// to be updated.
func (c *OrganizationsInstancesPatchCall) UpdateMask(updateMask string) *OrganizationsInstancesPatchCall {
	c.urlParams_.Set("updateMask", updateMask)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsInstancesPatchCall) Fields(s ...googleapi.Field) *OrganizationsInstancesPatchCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsInstancesPatchCall) Context(ctx context.Context) *OrganizationsInstancesPatchCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsInstancesPatchCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsInstancesPatchCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1instance)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PATCH", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.instances.patch" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsInstancesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates an Apigee runtime instance. You can update the fields described in NodeConfig. No other fields will be updated. **Note:** Not supported for Apigee hybrid.",
	//   "flatPath": "v1/organizations/{organizationsId}/instances/{instancesId}",
	//   "httpMethod": "PATCH",
	//   "id": "apigee.organizations.instances.patch",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the instance. Use the following structure in your request: `organizations/{org}/instances/{instance}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/instances/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "updateMask": {
	//       "description": "List of fields to be updated.",
	//       "format": "google-fieldmask",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1Instance"
	//   },
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.instances.reportStatus":

type OrganizationsInstancesReportStatusCall struct {
	s                                              *Service
	instance                                       string
	googlecloudapigeev1reportinstancestatusrequest *GoogleCloudApigeeV1ReportInstanceStatusRequest
	urlParams_                                     gensupport.URLParams
	ctx_                                           context.Context
	header_                                        http.Header
}

// ReportStatus: Reports the latest status for a runtime instance.
//
//   - instance: The name of the instance reporting this status. For SaaS
//     the request will be rejected if no instance exists under this name.
//     Format is organizations/{org}/instances/{instance}.
func (r *OrganizationsInstancesService) ReportStatus(instance string, googlecloudapigeev1reportinstancestatusrequest *GoogleCloudApigeeV1ReportInstanceStatusRequest) *OrganizationsInstancesReportStatusCall {
	c := &OrganizationsInstancesReportStatusCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.instance = instance
	c.googlecloudapigeev1reportinstancestatusrequest = googlecloudapigeev1reportinstancestatusrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsInstancesReportStatusCall) Fields(s ...googleapi.Field) *OrganizationsInstancesReportStatusCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsInstancesReportStatusCall) Context(ctx context.Context) *OrganizationsInstancesReportStatusCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsInstancesReportStatusCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsInstancesReportStatusCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1reportinstancestatusrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+instance}:reportStatus")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"instance": c.instance,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.instances.reportStatus" call.
// Exactly one of *GoogleCloudApigeeV1ReportInstanceStatusResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ReportInstanceStatusResponse.ServerResponse.Header
//
//	or (if a response was returned at all) in
//
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsInstancesReportStatusCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ReportInstanceStatusResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ReportInstanceStatusResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Reports the latest status for a runtime instance.",
	//   "flatPath": "v1/organizations/{organizationsId}/instances/{instancesId}:reportStatus",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.instances.reportStatus",
	//   "parameterOrder": [
	//     "instance"
	//   ],
	//   "parameters": {
	//     "instance": {
	//       "description": "The name of the instance reporting this status. For SaaS the request will be rejected if no instance exists under this name. Format is organizations/{org}/instances/{instance}",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/instances/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+instance}:reportStatus",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1ReportInstanceStatusRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ReportInstanceStatusResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.instances.attachments.create":

type OrganizationsInstancesAttachmentsCreateCall struct {
	s                                     *Service
	parent                                string
	googlecloudapigeev1instanceattachment *GoogleCloudApigeeV1InstanceAttachment
	urlParams_                            gensupport.URLParams
	ctx_                                  context.Context
	header_                               http.Header
}

// Create: Creates a new attachment of an environment to an instance.
// **Note:** Not supported for Apigee hybrid.
//
//   - parent: Name of the instance. Use the following structure in your
//     request: `organizations/{org}/instances/{instance}`.
func (r *OrganizationsInstancesAttachmentsService) Create(parent string, googlecloudapigeev1instanceattachment *GoogleCloudApigeeV1InstanceAttachment) *OrganizationsInstancesAttachmentsCreateCall {
	c := &OrganizationsInstancesAttachmentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1instanceattachment = googlecloudapigeev1instanceattachment
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsInstancesAttachmentsCreateCall) Fields(s ...googleapi.Field) *OrganizationsInstancesAttachmentsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsInstancesAttachmentsCreateCall) Context(ctx context.Context) *OrganizationsInstancesAttachmentsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsInstancesAttachmentsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsInstancesAttachmentsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1instanceattachment)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/attachments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.instances.attachments.create" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsInstancesAttachmentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a new attachment of an environment to an instance. **Note:** Not supported for Apigee hybrid.",
	//   "flatPath": "v1/organizations/{organizationsId}/instances/{instancesId}/attachments",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.instances.attachments.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the instance. Use the following structure in your request: `organizations/{org}/instances/{instance}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/instances/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/attachments",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1InstanceAttachment"
	//   },
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.instances.attachments.delete":

type OrganizationsInstancesAttachmentsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an attachment. **Note:** Not supported for Apigee
// hybrid.
//
//   - name: Name of the attachment. Use the following structure in your
//     request:
//     `organizations/{org}/instances/{instance}/attachments/{attachment}`.
func (r *OrganizationsInstancesAttachmentsService) Delete(name string) *OrganizationsInstancesAttachmentsDeleteCall {
	c := &OrganizationsInstancesAttachmentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsInstancesAttachmentsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsInstancesAttachmentsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsInstancesAttachmentsDeleteCall) Context(ctx context.Context) *OrganizationsInstancesAttachmentsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsInstancesAttachmentsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsInstancesAttachmentsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.instances.attachments.delete" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsInstancesAttachmentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an attachment. **Note:** Not supported for Apigee hybrid.",
	//   "flatPath": "v1/organizations/{organizationsId}/instances/{instancesId}/attachments/{attachmentsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.instances.attachments.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the attachment. Use the following structure in your request: `organizations/{org}/instances/{instance}/attachments/{attachment}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/instances/[^/]+/attachments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.instances.attachments.get":

type OrganizationsInstancesAttachmentsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets an attachment. **Note:** Not supported for Apigee hybrid.
//
//   - name: Name of the attachment. Use the following structure in your
//     request:
//     `organizations/{org}/instances/{instance}/attachments/{attachment}`.
func (r *OrganizationsInstancesAttachmentsService) Get(name string) *OrganizationsInstancesAttachmentsGetCall {
	c := &OrganizationsInstancesAttachmentsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsInstancesAttachmentsGetCall) Fields(s ...googleapi.Field) *OrganizationsInstancesAttachmentsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsInstancesAttachmentsGetCall) IfNoneMatch(entityTag string) *OrganizationsInstancesAttachmentsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsInstancesAttachmentsGetCall) Context(ctx context.Context) *OrganizationsInstancesAttachmentsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsInstancesAttachmentsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsInstancesAttachmentsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.instances.attachments.get" call.
// Exactly one of *GoogleCloudApigeeV1InstanceAttachment or error will
// be non-nil. Any non-2xx status code is an error. Response headers are
// in either
// *GoogleCloudApigeeV1InstanceAttachment.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsInstancesAttachmentsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1InstanceAttachment, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1InstanceAttachment{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets an attachment. **Note:** Not supported for Apigee hybrid.",
	//   "flatPath": "v1/organizations/{organizationsId}/instances/{instancesId}/attachments/{attachmentsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.instances.attachments.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the attachment. Use the following structure in your request: `organizations/{org}/instances/{instance}/attachments/{attachment}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/instances/[^/]+/attachments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1InstanceAttachment"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.instances.attachments.list":

type OrganizationsInstancesAttachmentsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all attachments to an instance. **Note:** Not supported
// for Apigee hybrid.
//
//   - parent: Name of the organization. Use the following structure in
//     your request: `organizations/{org}/instances/{instance}`.
func (r *OrganizationsInstancesAttachmentsService) List(parent string) *OrganizationsInstancesAttachmentsListCall {
	c := &OrganizationsInstancesAttachmentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// PageSize sets the optional parameter "pageSize": Maximum number of
// instance attachments to return. Defaults to 25.
func (c *OrganizationsInstancesAttachmentsListCall) PageSize(pageSize int64) *OrganizationsInstancesAttachmentsListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": Page token,
// returned by a previous ListInstanceAttachments call, that you can use
// to retrieve the next page of content.
func (c *OrganizationsInstancesAttachmentsListCall) PageToken(pageToken string) *OrganizationsInstancesAttachmentsListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsInstancesAttachmentsListCall) Fields(s ...googleapi.Field) *OrganizationsInstancesAttachmentsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsInstancesAttachmentsListCall) IfNoneMatch(entityTag string) *OrganizationsInstancesAttachmentsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsInstancesAttachmentsListCall) Context(ctx context.Context) *OrganizationsInstancesAttachmentsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsInstancesAttachmentsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsInstancesAttachmentsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/attachments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.instances.attachments.list" call.
// Exactly one of *GoogleCloudApigeeV1ListInstanceAttachmentsResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListInstanceAttachmentsResponse.ServerResponse.Hea
// der or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsInstancesAttachmentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListInstanceAttachmentsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListInstanceAttachmentsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all attachments to an instance. **Note:** Not supported for Apigee hybrid.",
	//   "flatPath": "v1/organizations/{organizationsId}/instances/{instancesId}/attachments",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.instances.attachments.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "pageSize": {
	//       "description": "Maximum number of instance attachments to return. Defaults to 25.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Page token, returned by a previous ListInstanceAttachments call, that you can use to retrieve the next page of content.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the organization. Use the following structure in your request: `organizations/{org}/instances/{instance}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/instances/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/attachments",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListInstanceAttachmentsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsInstancesAttachmentsListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListInstanceAttachmentsResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.instances.canaryevaluations.create":

type OrganizationsInstancesCanaryevaluationsCreateCall struct {
	s                                   *Service
	parent                              string
	googlecloudapigeev1canaryevaluation *GoogleCloudApigeeV1CanaryEvaluation
	urlParams_                          gensupport.URLParams
	ctx_                                context.Context
	header_                             http.Header
}

// Create: Creates a new canary evaluation for an organization.
//
//   - parent: Name of the organization. Use the following structure in
//     your request: `organizations/{org}/instances/{instance}`.
func (r *OrganizationsInstancesCanaryevaluationsService) Create(parent string, googlecloudapigeev1canaryevaluation *GoogleCloudApigeeV1CanaryEvaluation) *OrganizationsInstancesCanaryevaluationsCreateCall {
	c := &OrganizationsInstancesCanaryevaluationsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1canaryevaluation = googlecloudapigeev1canaryevaluation
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsInstancesCanaryevaluationsCreateCall) Fields(s ...googleapi.Field) *OrganizationsInstancesCanaryevaluationsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsInstancesCanaryevaluationsCreateCall) Context(ctx context.Context) *OrganizationsInstancesCanaryevaluationsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsInstancesCanaryevaluationsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsInstancesCanaryevaluationsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1canaryevaluation)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/canaryevaluations")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.instances.canaryevaluations.create" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsInstancesCanaryevaluationsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a new canary evaluation for an organization.",
	//   "flatPath": "v1/organizations/{organizationsId}/instances/{instancesId}/canaryevaluations",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.instances.canaryevaluations.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the organization. Use the following structure in your request: `organizations/{org}/instances/{instance}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/instances/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/canaryevaluations",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1CanaryEvaluation"
	//   },
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.instances.canaryevaluations.get":

type OrganizationsInstancesCanaryevaluationsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets a CanaryEvaluation for an organization.
//
//   - name: Name of the CanaryEvaluation. Use the following structure in
//     your request:
//     `organizations/{org}/instances/*/canaryevaluations/{evaluation}`.
func (r *OrganizationsInstancesCanaryevaluationsService) Get(name string) *OrganizationsInstancesCanaryevaluationsGetCall {
	c := &OrganizationsInstancesCanaryevaluationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsInstancesCanaryevaluationsGetCall) Fields(s ...googleapi.Field) *OrganizationsInstancesCanaryevaluationsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsInstancesCanaryevaluationsGetCall) IfNoneMatch(entityTag string) *OrganizationsInstancesCanaryevaluationsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsInstancesCanaryevaluationsGetCall) Context(ctx context.Context) *OrganizationsInstancesCanaryevaluationsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsInstancesCanaryevaluationsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsInstancesCanaryevaluationsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.instances.canaryevaluations.get" call.
// Exactly one of *GoogleCloudApigeeV1CanaryEvaluation or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1CanaryEvaluation.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsInstancesCanaryevaluationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1CanaryEvaluation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1CanaryEvaluation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets a CanaryEvaluation for an organization.",
	//   "flatPath": "v1/organizations/{organizationsId}/instances/{instancesId}/canaryevaluations/{canaryevaluationsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.instances.canaryevaluations.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the CanaryEvaluation. Use the following structure in your request: `organizations/{org}/instances/*/canaryevaluations/{evaluation}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/instances/[^/]+/canaryevaluations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1CanaryEvaluation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.instances.natAddresses.activate":

type OrganizationsInstancesNatAddressesActivateCall struct {
	s                                            *Service
	name                                         string
	googlecloudapigeev1activatenataddressrequest *GoogleCloudApigeeV1ActivateNatAddressRequest
	urlParams_                                   gensupport.URLParams
	ctx_                                         context.Context
	header_                                      http.Header
}

// Activate: Activates the NAT address. The Apigee instance can now use
// this for Internet egress traffic. **Note:** Not supported for Apigee
// hybrid.
//
//   - name: Name of the nat address. Use the following structure in your
//     request:
//     `organizations/{org}/instances/{instances}/natAddresses/{nataddress}
//     “.
func (r *OrganizationsInstancesNatAddressesService) Activate(name string, googlecloudapigeev1activatenataddressrequest *GoogleCloudApigeeV1ActivateNatAddressRequest) *OrganizationsInstancesNatAddressesActivateCall {
	c := &OrganizationsInstancesNatAddressesActivateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1activatenataddressrequest = googlecloudapigeev1activatenataddressrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsInstancesNatAddressesActivateCall) Fields(s ...googleapi.Field) *OrganizationsInstancesNatAddressesActivateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsInstancesNatAddressesActivateCall) Context(ctx context.Context) *OrganizationsInstancesNatAddressesActivateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsInstancesNatAddressesActivateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsInstancesNatAddressesActivateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1activatenataddressrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:activate")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.instances.natAddresses.activate" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsInstancesNatAddressesActivateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Activates the NAT address. The Apigee instance can now use this for Internet egress traffic. **Note:** Not supported for Apigee hybrid.",
	//   "flatPath": "v1/organizations/{organizationsId}/instances/{instancesId}/natAddresses/{natAddressesId}:activate",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.instances.natAddresses.activate",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the nat address. Use the following structure in your request: `organizations/{org}/instances/{instances}/natAddresses/{nataddress}``",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/instances/[^/]+/natAddresses/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}:activate",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1ActivateNatAddressRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.instances.natAddresses.create":

type OrganizationsInstancesNatAddressesCreateCall struct {
	s                             *Service
	parent                        string
	googlecloudapigeev1nataddress *GoogleCloudApigeeV1NatAddress
	urlParams_                    gensupport.URLParams
	ctx_                          context.Context
	header_                       http.Header
}

// Create: Creates a NAT address. The address is created in the RESERVED
// state and a static external IP address will be provisioned. At this
// time, the instance will not use this IP address for Internet egress
// traffic. The address can be activated for use once any required
// firewall IP whitelisting has been completed. **Note:** Not supported
// for Apigee hybrid.
//
//   - parent: Name of the instance. Use the following structure in your
//     request: `organizations/{org}/instances/{instance}`.
func (r *OrganizationsInstancesNatAddressesService) Create(parent string, googlecloudapigeev1nataddress *GoogleCloudApigeeV1NatAddress) *OrganizationsInstancesNatAddressesCreateCall {
	c := &OrganizationsInstancesNatAddressesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1nataddress = googlecloudapigeev1nataddress
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsInstancesNatAddressesCreateCall) Fields(s ...googleapi.Field) *OrganizationsInstancesNatAddressesCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsInstancesNatAddressesCreateCall) Context(ctx context.Context) *OrganizationsInstancesNatAddressesCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsInstancesNatAddressesCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsInstancesNatAddressesCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1nataddress)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/natAddresses")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.instances.natAddresses.create" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsInstancesNatAddressesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a NAT address. The address is created in the RESERVED state and a static external IP address will be provisioned. At this time, the instance will not use this IP address for Internet egress traffic. The address can be activated for use once any required firewall IP whitelisting has been completed. **Note:** Not supported for Apigee hybrid.",
	//   "flatPath": "v1/organizations/{organizationsId}/instances/{instancesId}/natAddresses",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.instances.natAddresses.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the instance. Use the following structure in your request: `organizations/{org}/instances/{instance}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/instances/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/natAddresses",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1NatAddress"
	//   },
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.instances.natAddresses.delete":

type OrganizationsInstancesNatAddressesDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes the NAT address. Connections that are actively using
// the address are drained before it is removed. **Note:** Not supported
// for Apigee hybrid.
//
//   - name: Name of the nat address. Use the following structure in your
//     request:
//     `organizations/{org}/instances/{instances}/natAddresses/{nataddress}
//     “.
func (r *OrganizationsInstancesNatAddressesService) Delete(name string) *OrganizationsInstancesNatAddressesDeleteCall {
	c := &OrganizationsInstancesNatAddressesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsInstancesNatAddressesDeleteCall) Fields(s ...googleapi.Field) *OrganizationsInstancesNatAddressesDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsInstancesNatAddressesDeleteCall) Context(ctx context.Context) *OrganizationsInstancesNatAddressesDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsInstancesNatAddressesDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsInstancesNatAddressesDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.instances.natAddresses.delete" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsInstancesNatAddressesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes the NAT address. Connections that are actively using the address are drained before it is removed. **Note:** Not supported for Apigee hybrid.",
	//   "flatPath": "v1/organizations/{organizationsId}/instances/{instancesId}/natAddresses/{natAddressesId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.instances.natAddresses.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the nat address. Use the following structure in your request: `organizations/{org}/instances/{instances}/natAddresses/{nataddress}``",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/instances/[^/]+/natAddresses/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.instances.natAddresses.get":

type OrganizationsInstancesNatAddressesGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets the details of a NAT address. **Note:** Not supported for
// Apigee hybrid.
//
//   - name: Name of the nat address. Use the following structure in your
//     request:
//     `organizations/{org}/instances/{instances}/natAddresses/{nataddress}
//     `.
func (r *OrganizationsInstancesNatAddressesService) Get(name string) *OrganizationsInstancesNatAddressesGetCall {
	c := &OrganizationsInstancesNatAddressesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsInstancesNatAddressesGetCall) Fields(s ...googleapi.Field) *OrganizationsInstancesNatAddressesGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsInstancesNatAddressesGetCall) IfNoneMatch(entityTag string) *OrganizationsInstancesNatAddressesGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsInstancesNatAddressesGetCall) Context(ctx context.Context) *OrganizationsInstancesNatAddressesGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsInstancesNatAddressesGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsInstancesNatAddressesGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.instances.natAddresses.get" call.
// Exactly one of *GoogleCloudApigeeV1NatAddress or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1NatAddress.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsInstancesNatAddressesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1NatAddress, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1NatAddress{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the details of a NAT address. **Note:** Not supported for Apigee hybrid.",
	//   "flatPath": "v1/organizations/{organizationsId}/instances/{instancesId}/natAddresses/{natAddressesId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.instances.natAddresses.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the nat address. Use the following structure in your request: `organizations/{org}/instances/{instances}/natAddresses/{nataddress}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/instances/[^/]+/natAddresses/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1NatAddress"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.instances.natAddresses.list":

type OrganizationsInstancesNatAddressesListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists the NAT addresses for an Apigee instance. **Note:** Not
// supported for Apigee hybrid.
//
//   - parent: Name of the instance. Use the following structure in your
//     request: `organizations/{org}/instances/{instance}`.
func (r *OrganizationsInstancesNatAddressesService) List(parent string) *OrganizationsInstancesNatAddressesListCall {
	c := &OrganizationsInstancesNatAddressesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// PageSize sets the optional parameter "pageSize": Maximum number of
// natAddresses to return. Defaults to 25.
func (c *OrganizationsInstancesNatAddressesListCall) PageSize(pageSize int64) *OrganizationsInstancesNatAddressesListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": Page token,
// returned from a previous ListNatAddresses call, that you can use to
// retrieve the next page of content.
func (c *OrganizationsInstancesNatAddressesListCall) PageToken(pageToken string) *OrganizationsInstancesNatAddressesListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsInstancesNatAddressesListCall) Fields(s ...googleapi.Field) *OrganizationsInstancesNatAddressesListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsInstancesNatAddressesListCall) IfNoneMatch(entityTag string) *OrganizationsInstancesNatAddressesListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsInstancesNatAddressesListCall) Context(ctx context.Context) *OrganizationsInstancesNatAddressesListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsInstancesNatAddressesListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsInstancesNatAddressesListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/natAddresses")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.instances.natAddresses.list" call.
// Exactly one of *GoogleCloudApigeeV1ListNatAddressesResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListNatAddressesResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsInstancesNatAddressesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListNatAddressesResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListNatAddressesResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists the NAT addresses for an Apigee instance. **Note:** Not supported for Apigee hybrid.",
	//   "flatPath": "v1/organizations/{organizationsId}/instances/{instancesId}/natAddresses",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.instances.natAddresses.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "pageSize": {
	//       "description": "Maximum number of natAddresses to return. Defaults to 25.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Page token, returned from a previous ListNatAddresses call, that you can use to retrieve the next page of content.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the instance. Use the following structure in your request: `organizations/{org}/instances/{instance}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/instances/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/natAddresses",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListNatAddressesResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsInstancesNatAddressesListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListNatAddressesResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.keyvaluemaps.create":

type OrganizationsKeyvaluemapsCreateCall struct {
	s                              *Service
	parent                         string
	googlecloudapigeev1keyvaluemap *GoogleCloudApigeeV1KeyValueMap
	urlParams_                     gensupport.URLParams
	ctx_                           context.Context
	header_                        http.Header
}

// Create: Creates a key value map in an organization.
//
//   - parent: Name of the organization in which to create the key value
//     map file. Use the following structure in your request:
//     `organizations/{org}`.
func (r *OrganizationsKeyvaluemapsService) Create(parent string, googlecloudapigeev1keyvaluemap *GoogleCloudApigeeV1KeyValueMap) *OrganizationsKeyvaluemapsCreateCall {
	c := &OrganizationsKeyvaluemapsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1keyvaluemap = googlecloudapigeev1keyvaluemap
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsKeyvaluemapsCreateCall) Fields(s ...googleapi.Field) *OrganizationsKeyvaluemapsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsKeyvaluemapsCreateCall) Context(ctx context.Context) *OrganizationsKeyvaluemapsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsKeyvaluemapsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsKeyvaluemapsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1keyvaluemap)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/keyvaluemaps")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.keyvaluemaps.create" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueMap or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueMap.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsKeyvaluemapsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueMap, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueMap{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a key value map in an organization.",
	//   "flatPath": "v1/organizations/{organizationsId}/keyvaluemaps",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.keyvaluemaps.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the organization in which to create the key value map file. Use the following structure in your request: `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/keyvaluemaps",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueMap"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueMap"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.keyvaluemaps.delete":

type OrganizationsKeyvaluemapsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a key value map from an organization.
//
//   - name: Name of the key value map. Use the following structure in
//     your request: `organizations/{org}/keyvaluemaps/{keyvaluemap}`.
func (r *OrganizationsKeyvaluemapsService) Delete(name string) *OrganizationsKeyvaluemapsDeleteCall {
	c := &OrganizationsKeyvaluemapsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsKeyvaluemapsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsKeyvaluemapsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsKeyvaluemapsDeleteCall) Context(ctx context.Context) *OrganizationsKeyvaluemapsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsKeyvaluemapsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsKeyvaluemapsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.keyvaluemaps.delete" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueMap or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueMap.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsKeyvaluemapsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueMap, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueMap{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a key value map from an organization.",
	//   "flatPath": "v1/organizations/{organizationsId}/keyvaluemaps/{keyvaluemapsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.keyvaluemaps.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the key value map. Use the following structure in your request: `organizations/{org}/keyvaluemaps/{keyvaluemap}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/keyvaluemaps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueMap"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.keyvaluemaps.entries.create":

type OrganizationsKeyvaluemapsEntriesCreateCall struct {
	s                                *Service
	parent                           string
	googlecloudapigeev1keyvalueentry *GoogleCloudApigeeV1KeyValueEntry
	urlParams_                       gensupport.URLParams
	ctx_                             context.Context
	header_                          http.Header
}

// Create: Creates key value entries in a key value map scoped to an
// organization, environment, or API proxy. **Note**: Supported for
// Apigee hybrid 1.8.x and higher.
//
//   - parent: Scope as indicated by the URI in which to create the key
//     value map entry. Use **one** of the following structures in your
//     request: *
//     `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`
//     . *
//     `organizations/{organization}/environments/{environment}/keyvaluemap
//     s/{keyvaluemap}` *
//     `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.
func (r *OrganizationsKeyvaluemapsEntriesService) Create(parent string, googlecloudapigeev1keyvalueentry *GoogleCloudApigeeV1KeyValueEntry) *OrganizationsKeyvaluemapsEntriesCreateCall {
	c := &OrganizationsKeyvaluemapsEntriesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1keyvalueentry = googlecloudapigeev1keyvalueentry
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsKeyvaluemapsEntriesCreateCall) Fields(s ...googleapi.Field) *OrganizationsKeyvaluemapsEntriesCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsKeyvaluemapsEntriesCreateCall) Context(ctx context.Context) *OrganizationsKeyvaluemapsEntriesCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsKeyvaluemapsEntriesCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsKeyvaluemapsEntriesCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1keyvalueentry)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/entries")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.keyvaluemaps.entries.create" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueEntry or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueEntry.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsKeyvaluemapsEntriesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueEntry, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueEntry{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates key value entries in a key value map scoped to an organization, environment, or API proxy. **Note**: Supported for Apigee hybrid 1.8.x and higher.",
	//   "flatPath": "v1/organizations/{organizationsId}/keyvaluemaps/{keyvaluemapsId}/entries",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.keyvaluemaps.entries.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Scope as indicated by the URI in which to create the key value map entry. Use **one** of the following structures in your request: * `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`. * `organizations/{organization}/environments/{environment}/keyvaluemaps/{keyvaluemap}` * `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/keyvaluemaps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/entries",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.keyvaluemaps.entries.delete":

type OrganizationsKeyvaluemapsEntriesDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a key value entry from a key value map scoped to an
// organization, environment, or API proxy. **Notes:** * After you
// delete the key value entry, the policy consuming the entry will
// continue to function with its cached values for a few minutes. This
// is expected behavior. * Supported for Apigee hybrid 1.8.x and higher.
//
//   - name: Scope as indicated by the URI in which to delete the key
//     value map entry. Use **one** of the following structures in your
//     request: *
//     `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}/
//     entries/{entry}`. *
//     `organizations/{organization}/environments/{environment}/keyvaluemap
//     s/{keyvaluemap}/entries/{entry}` *
//     `organizations/{organization}/keyvaluemaps/{keyvaluemap}/entries/{en
//     try}`.
func (r *OrganizationsKeyvaluemapsEntriesService) Delete(name string) *OrganizationsKeyvaluemapsEntriesDeleteCall {
	c := &OrganizationsKeyvaluemapsEntriesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsKeyvaluemapsEntriesDeleteCall) Fields(s ...googleapi.Field) *OrganizationsKeyvaluemapsEntriesDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsKeyvaluemapsEntriesDeleteCall) Context(ctx context.Context) *OrganizationsKeyvaluemapsEntriesDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsKeyvaluemapsEntriesDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsKeyvaluemapsEntriesDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.keyvaluemaps.entries.delete" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueEntry or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueEntry.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsKeyvaluemapsEntriesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueEntry, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueEntry{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a key value entry from a key value map scoped to an organization, environment, or API proxy. **Notes:** * After you delete the key value entry, the policy consuming the entry will continue to function with its cached values for a few minutes. This is expected behavior. * Supported for Apigee hybrid 1.8.x and higher.",
	//   "flatPath": "v1/organizations/{organizationsId}/keyvaluemaps/{keyvaluemapsId}/entries/{entriesId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.keyvaluemaps.entries.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Scope as indicated by the URI in which to delete the key value map entry. Use **one** of the following structures in your request: * `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}/entries/{entry}`. * `organizations/{organization}/environments/{environment}/keyvaluemaps/{keyvaluemap}/entries/{entry}` * `organizations/{organization}/keyvaluemaps/{keyvaluemap}/entries/{entry}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/keyvaluemaps/[^/]+/entries/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.keyvaluemaps.entries.get":

type OrganizationsKeyvaluemapsEntriesGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Get the key value entry value for a key value map scoped to an
// organization, environment, or API proxy. **Note**: Supported for
// Apigee hybrid 1.8.x and higher.
//
//   - name: Scope as indicated by the URI in which to fetch the key value
//     map entry/value. Use **one** of the following structures in your
//     request: *
//     `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}/
//     entries/{entry}`. *
//     `organizations/{organization}/environments/{environment}/keyvaluemap
//     s/{keyvaluemap}/entries/{entry}` *
//     `organizations/{organization}/keyvaluemaps/{keyvaluemap}/entries/{en
//     try}`.
func (r *OrganizationsKeyvaluemapsEntriesService) Get(name string) *OrganizationsKeyvaluemapsEntriesGetCall {
	c := &OrganizationsKeyvaluemapsEntriesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsKeyvaluemapsEntriesGetCall) Fields(s ...googleapi.Field) *OrganizationsKeyvaluemapsEntriesGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsKeyvaluemapsEntriesGetCall) IfNoneMatch(entityTag string) *OrganizationsKeyvaluemapsEntriesGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsKeyvaluemapsEntriesGetCall) Context(ctx context.Context) *OrganizationsKeyvaluemapsEntriesGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsKeyvaluemapsEntriesGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsKeyvaluemapsEntriesGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.keyvaluemaps.entries.get" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueEntry or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueEntry.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsKeyvaluemapsEntriesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueEntry, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueEntry{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Get the key value entry value for a key value map scoped to an organization, environment, or API proxy. **Note**: Supported for Apigee hybrid 1.8.x and higher.",
	//   "flatPath": "v1/organizations/{organizationsId}/keyvaluemaps/{keyvaluemapsId}/entries/{entriesId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.keyvaluemaps.entries.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Scope as indicated by the URI in which to fetch the key value map entry/value. Use **one** of the following structures in your request: * `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}/entries/{entry}`. * `organizations/{organization}/environments/{environment}/keyvaluemaps/{keyvaluemap}/entries/{entry}` * `organizations/{organization}/keyvaluemaps/{keyvaluemap}/entries/{entry}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/keyvaluemaps/[^/]+/entries/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.keyvaluemaps.entries.list":

type OrganizationsKeyvaluemapsEntriesListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists key value entries for key values maps scoped to an
// organization, environment, or API proxy. **Note**: Supported for
// Apigee hybrid 1.8.x and higher.
//
//   - parent: Scope as indicated by the URI in which to list key value
//     maps. Use **one** of the following structures in your request: *
//     `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`
//     . *
//     `organizations/{organization}/environments/{environment}/keyvaluemap
//     s/{keyvaluemap}` *
//     `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.
func (r *OrganizationsKeyvaluemapsEntriesService) List(parent string) *OrganizationsKeyvaluemapsEntriesListCall {
	c := &OrganizationsKeyvaluemapsEntriesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// PageSize sets the optional parameter "pageSize": Maximum number of
// key value entries to return. If unspecified, at most 100 entries will
// be returned.
func (c *OrganizationsKeyvaluemapsEntriesListCall) PageSize(pageSize int64) *OrganizationsKeyvaluemapsEntriesListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": Page token. If
// provides, must be a valid key value entry returned from a previous
// call that can be used to retrieve the next page.
func (c *OrganizationsKeyvaluemapsEntriesListCall) PageToken(pageToken string) *OrganizationsKeyvaluemapsEntriesListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsKeyvaluemapsEntriesListCall) Fields(s ...googleapi.Field) *OrganizationsKeyvaluemapsEntriesListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsKeyvaluemapsEntriesListCall) IfNoneMatch(entityTag string) *OrganizationsKeyvaluemapsEntriesListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsKeyvaluemapsEntriesListCall) Context(ctx context.Context) *OrganizationsKeyvaluemapsEntriesListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsKeyvaluemapsEntriesListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsKeyvaluemapsEntriesListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/entries")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.keyvaluemaps.entries.list" call.
// Exactly one of *GoogleCloudApigeeV1ListKeyValueEntriesResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListKeyValueEntriesResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsKeyvaluemapsEntriesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListKeyValueEntriesResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListKeyValueEntriesResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists key value entries for key values maps scoped to an organization, environment, or API proxy. **Note**: Supported for Apigee hybrid 1.8.x and higher.",
	//   "flatPath": "v1/organizations/{organizationsId}/keyvaluemaps/{keyvaluemapsId}/entries",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.keyvaluemaps.entries.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "pageSize": {
	//       "description": "Optional. Maximum number of key value entries to return. If unspecified, at most 100 entries will be returned.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Optional. Page token. If provides, must be a valid key value entry returned from a previous call that can be used to retrieve the next page.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Scope as indicated by the URI in which to list key value maps. Use **one** of the following structures in your request: * `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`. * `organizations/{organization}/environments/{environment}/keyvaluemaps/{keyvaluemap}` * `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/keyvaluemaps/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/entries",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListKeyValueEntriesResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsKeyvaluemapsEntriesListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListKeyValueEntriesResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.keyvaluemaps.entries.update":

type OrganizationsKeyvaluemapsEntriesUpdateCall struct {
	s                                *Service
	name                             string
	googlecloudapigeev1keyvalueentry *GoogleCloudApigeeV1KeyValueEntry
	urlParams_                       gensupport.URLParams
	ctx_                             context.Context
	header_                          http.Header
}

// Update: Update key value entry scoped to an organization,
// environment, or API proxy for an existing key.
//
//   - name: Scope as indicated by the URI in which to create the key
//     value map entry. Use **one** of the following structures in your
//     request: *
//     `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`
//     . *
//     `organizations/{organization}/environments/{environment}/keyvaluemap
//     s/{keyvaluemap}` *
//     `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.
func (r *OrganizationsKeyvaluemapsEntriesService) Update(name string, googlecloudapigeev1keyvalueentry *GoogleCloudApigeeV1KeyValueEntry) *OrganizationsKeyvaluemapsEntriesUpdateCall {
	c := &OrganizationsKeyvaluemapsEntriesUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1keyvalueentry = googlecloudapigeev1keyvalueentry
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsKeyvaluemapsEntriesUpdateCall) Fields(s ...googleapi.Field) *OrganizationsKeyvaluemapsEntriesUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsKeyvaluemapsEntriesUpdateCall) Context(ctx context.Context) *OrganizationsKeyvaluemapsEntriesUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsKeyvaluemapsEntriesUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsKeyvaluemapsEntriesUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1keyvalueentry)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.keyvaluemaps.entries.update" call.
// Exactly one of *GoogleCloudApigeeV1KeyValueEntry or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1KeyValueEntry.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsKeyvaluemapsEntriesUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1KeyValueEntry, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1KeyValueEntry{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Update key value entry scoped to an organization, environment, or API proxy for an existing key.",
	//   "flatPath": "v1/organizations/{organizationsId}/keyvaluemaps/{keyvaluemapsId}/entries/{entriesId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.keyvaluemaps.entries.update",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Scope as indicated by the URI in which to create the key value map entry. Use **one** of the following structures in your request: * `organizations/{organization}/apis/{api}/keyvaluemaps/{keyvaluemap}`. * `organizations/{organization}/environments/{environment}/keyvaluemaps/{keyvaluemap}` * `organizations/{organization}/keyvaluemaps/{keyvaluemap}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/keyvaluemaps/[^/]+/entries/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1KeyValueEntry"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.operations.get":

type OrganizationsOperationsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets the latest state of a long-running operation. Clients can
// use this method to poll the operation result at intervals as
// recommended by the API service.
//
// - name: The name of the operation resource.
func (r *OrganizationsOperationsService) Get(name string) *OrganizationsOperationsGetCall {
	c := &OrganizationsOperationsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsOperationsGetCall) Fields(s ...googleapi.Field) *OrganizationsOperationsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsOperationsGetCall) IfNoneMatch(entityTag string) *OrganizationsOperationsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsOperationsGetCall) Context(ctx context.Context) *OrganizationsOperationsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsOperationsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsOperationsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.operations.get" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsOperationsGetCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the latest state of a long-running operation. Clients can use this method to poll the operation result at intervals as recommended by the API service.",
	//   "flatPath": "v1/organizations/{organizationsId}/operations/{operationsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.operations.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "The name of the operation resource.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/operations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.operations.list":

type OrganizationsOperationsListCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists operations that match the specified filter in the
// request. If the server doesn't support this method, it returns
// `UNIMPLEMENTED`.
//
// - name: The name of the operation's parent resource.
func (r *OrganizationsOperationsService) List(name string) *OrganizationsOperationsListCall {
	c := &OrganizationsOperationsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Filter sets the optional parameter "filter": The standard list
// filter.
func (c *OrganizationsOperationsListCall) Filter(filter string) *OrganizationsOperationsListCall {
	c.urlParams_.Set("filter", filter)
	return c
}

// PageSize sets the optional parameter "pageSize": The standard list
// page size.
func (c *OrganizationsOperationsListCall) PageSize(pageSize int64) *OrganizationsOperationsListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": The standard list
// page token.
func (c *OrganizationsOperationsListCall) PageToken(pageToken string) *OrganizationsOperationsListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsOperationsListCall) Fields(s ...googleapi.Field) *OrganizationsOperationsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsOperationsListCall) IfNoneMatch(entityTag string) *OrganizationsOperationsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsOperationsListCall) Context(ctx context.Context) *OrganizationsOperationsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsOperationsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsOperationsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}/operations")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.operations.list" call.
// Exactly one of *GoogleLongrunningListOperationsResponse or error will
// be non-nil. Any non-2xx status code is an error. Response headers are
// in either
// *GoogleLongrunningListOperationsResponse.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsOperationsListCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningListOperationsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningListOperationsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists operations that match the specified filter in the request. If the server doesn't support this method, it returns `UNIMPLEMENTED`.",
	//   "flatPath": "v1/organizations/{organizationsId}/operations",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.operations.list",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "filter": {
	//       "description": "The standard list filter.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "The name of the operation's parent resource.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "pageSize": {
	//       "description": "The standard list page size.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "The standard list page token.",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}/operations",
	//   "response": {
	//     "$ref": "GoogleLongrunningListOperationsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsOperationsListCall) Pages(ctx context.Context, f func(*GoogleLongrunningListOperationsResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.optimizedHostStats.get":

type OrganizationsOptimizedHostStatsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Similar to GetHostStats except that the response is less
// verbose.
//
//   - name: Resource name for which the interactive query will be
//     executed. Use the following format in your request:
//     `organizations/{organization_id}/optimizedHostStats/{dimensions}`
//     Dimensions let you view metrics in meaningful groupings, such as
//     `apiproxy`, `target_host`. The value of dimensions should be a
//     comma-separated list as shown below:
//     `organizations/{org}/optimizedHostStats/apiproxy,request_verb`.
func (r *OrganizationsOptimizedHostStatsService) Get(name string) *OrganizationsOptimizedHostStatsGetCall {
	c := &OrganizationsOptimizedHostStatsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Accuracy sets the optional parameter "accuracy": No longer used by
// Apigee. Supported for backwards compatibility.
func (c *OrganizationsOptimizedHostStatsGetCall) Accuracy(accuracy string) *OrganizationsOptimizedHostStatsGetCall {
	c.urlParams_.Set("accuracy", accuracy)
	return c
}

// EnvgroupHostname sets the optional parameter "envgroupHostname":
// Required. Hostname for which the interactive query will be executed.
func (c *OrganizationsOptimizedHostStatsGetCall) EnvgroupHostname(envgroupHostname string) *OrganizationsOptimizedHostStatsGetCall {
	c.urlParams_.Set("envgroupHostname", envgroupHostname)
	return c
}

// Filter sets the optional parameter "filter": Filter that enables you
// to drill-down on specific dimension values.
func (c *OrganizationsOptimizedHostStatsGetCall) Filter(filter string) *OrganizationsOptimizedHostStatsGetCall {
	c.urlParams_.Set("filter", filter)
	return c
}

// Limit sets the optional parameter "limit": Maximum number of result
// items to return. The default and maximum value that can be returned
// is 14400.
func (c *OrganizationsOptimizedHostStatsGetCall) Limit(limit string) *OrganizationsOptimizedHostStatsGetCall {
	c.urlParams_.Set("limit", limit)
	return c
}

// Offset sets the optional parameter "offset": Offset value. Use
// `offset` with `limit` to enable pagination of results. For example,
// to display results 11-20, set limit to `10` and offset to `10`.
func (c *OrganizationsOptimizedHostStatsGetCall) Offset(offset string) *OrganizationsOptimizedHostStatsGetCall {
	c.urlParams_.Set("offset", offset)
	return c
}

// Realtime sets the optional parameter "realtime": No longer used by
// Apigee. Supported for backwards compatibility.
func (c *OrganizationsOptimizedHostStatsGetCall) Realtime(realtime bool) *OrganizationsOptimizedHostStatsGetCall {
	c.urlParams_.Set("realtime", fmt.Sprint(realtime))
	return c
}

// Select sets the optional parameter "select": Required.
// Comma-separated list of metrics. For example:
// `sum(message_count),sum(error_count)`
func (c *OrganizationsOptimizedHostStatsGetCall) Select(select_ string) *OrganizationsOptimizedHostStatsGetCall {
	c.urlParams_.Set("select", select_)
	return c
}

// Sort sets the optional parameter "sort": Flag that specifies whether
// the sort order should be ascending or descending. Valid values
// include `DESC` and `ASC`.
func (c *OrganizationsOptimizedHostStatsGetCall) Sort(sort string) *OrganizationsOptimizedHostStatsGetCall {
	c.urlParams_.Set("sort", sort)
	return c
}

// Sortby sets the optional parameter "sortby": Comma-separated list of
// columns used to sort the final result.
func (c *OrganizationsOptimizedHostStatsGetCall) Sortby(sortby string) *OrganizationsOptimizedHostStatsGetCall {
	c.urlParams_.Set("sortby", sortby)
	return c
}

// TimeRange sets the optional parameter "timeRange": Required. Time
// interval for the interactive query. Time range is specified in GMT as
// `start~end`. For example: `04/15/2017 00:00~05/15/2017 23:59`.
func (c *OrganizationsOptimizedHostStatsGetCall) TimeRange(timeRange string) *OrganizationsOptimizedHostStatsGetCall {
	c.urlParams_.Set("timeRange", timeRange)
	return c
}

// TimeUnit sets the optional parameter "timeUnit": Granularity of
// metrics returned. Valid values include: `second`, `minute`, `hour`,
// `day`, `week`, or `month`.
func (c *OrganizationsOptimizedHostStatsGetCall) TimeUnit(timeUnit string) *OrganizationsOptimizedHostStatsGetCall {
	c.urlParams_.Set("timeUnit", timeUnit)
	return c
}

// Topk sets the optional parameter "topk": Top number of results to
// return. For example, to return the top 5 results, set `topk=5`.
func (c *OrganizationsOptimizedHostStatsGetCall) Topk(topk string) *OrganizationsOptimizedHostStatsGetCall {
	c.urlParams_.Set("topk", topk)
	return c
}

// TsAscending sets the optional parameter "tsAscending": Flag that
// specifies whether to list timestamps in ascending (`true`) or
// descending (`false`) order. Apigee recommends that you set this value
// to `true` if you are using `sortby` with `sort=DESC`.
func (c *OrganizationsOptimizedHostStatsGetCall) TsAscending(tsAscending bool) *OrganizationsOptimizedHostStatsGetCall {
	c.urlParams_.Set("tsAscending", fmt.Sprint(tsAscending))
	return c
}

// Tzo sets the optional parameter "tzo": Timezone offset value.
func (c *OrganizationsOptimizedHostStatsGetCall) Tzo(tzo string) *OrganizationsOptimizedHostStatsGetCall {
	c.urlParams_.Set("tzo", tzo)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsOptimizedHostStatsGetCall) Fields(s ...googleapi.Field) *OrganizationsOptimizedHostStatsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsOptimizedHostStatsGetCall) IfNoneMatch(entityTag string) *OrganizationsOptimizedHostStatsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsOptimizedHostStatsGetCall) Context(ctx context.Context) *OrganizationsOptimizedHostStatsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsOptimizedHostStatsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsOptimizedHostStatsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.optimizedHostStats.get" call.
// Exactly one of *GoogleCloudApigeeV1OptimizedStats or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1OptimizedStats.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsOptimizedHostStatsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1OptimizedStats, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1OptimizedStats{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Similar to GetHostStats except that the response is less verbose.",
	//   "flatPath": "v1/organizations/{organizationsId}/optimizedHostStats/{optimizedHostStatsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.optimizedHostStats.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "accuracy": {
	//       "description": "No longer used by Apigee. Supported for backwards compatibility.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "envgroupHostname": {
	//       "description": "Required. Hostname for which the interactive query will be executed.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "filter": {
	//       "description": "Filter that enables you to drill-down on specific dimension values.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "limit": {
	//       "description": "Maximum number of result items to return. The default and maximum value that can be returned is 14400.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "Required. Resource name for which the interactive query will be executed. Use the following format in your request: `organizations/{organization_id}/optimizedHostStats/{dimensions}` Dimensions let you view metrics in meaningful groupings, such as `apiproxy`, `target_host`. The value of dimensions should be a comma-separated list as shown below: `organizations/{org}/optimizedHostStats/apiproxy,request_verb`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/optimizedHostStats/.*$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "offset": {
	//       "description": "Offset value. Use `offset` with `limit` to enable pagination of results. For example, to display results 11-20, set limit to `10` and offset to `10`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "realtime": {
	//       "description": "No longer used by Apigee. Supported for backwards compatibility.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "select": {
	//       "description": "Required. Comma-separated list of metrics. For example: `sum(message_count),sum(error_count)`",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "sort": {
	//       "description": "Flag that specifies whether the sort order should be ascending or descending. Valid values include `DESC` and `ASC`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "sortby": {
	//       "description": "Comma-separated list of columns used to sort the final result.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "timeRange": {
	//       "description": "Required. Time interval for the interactive query. Time range is specified in GMT as `start~end`. For example: `04/15/2017 00:00~05/15/2017 23:59`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "timeUnit": {
	//       "description": "Granularity of metrics returned. Valid values include: `second`, `minute`, `hour`, `day`, `week`, or `month`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "topk": {
	//       "description": "Top number of results to return. For example, to return the top 5 results, set `topk=5`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "tsAscending": {
	//       "description": "Flag that specifies whether to list timestamps in ascending (`true`) or descending (`false`) order. Apigee recommends that you set this value to `true` if you are using `sortby` with `sort=DESC`.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "tzo": {
	//       "description": "Timezone offset value.",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1OptimizedStats"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.reports.create":

type OrganizationsReportsCreateCall struct {
	s                               *Service
	parent                          string
	googlecloudapigeev1customreport *GoogleCloudApigeeV1CustomReport
	urlParams_                      gensupport.URLParams
	ctx_                            context.Context
	header_                         http.Header
}

// Create: Creates a Custom Report for an Organization. A Custom Report
// provides Apigee Customers to create custom dashboards in addition to
// the standard dashboards which are provided. The Custom Report in its
// simplest form contains specifications about metrics, dimensions and
// filters. It is important to note that the custom report by itself
// does not provide an executable entity. The Edge UI converts the
// custom report definition into an analytics query and displays the
// result in a chart.
//
//   - parent: The parent organization name under which the Custom Report
//     will be created. Must be of the form:
//     `organizations/{organization_id}/reports`.
func (r *OrganizationsReportsService) Create(parent string, googlecloudapigeev1customreport *GoogleCloudApigeeV1CustomReport) *OrganizationsReportsCreateCall {
	c := &OrganizationsReportsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1customreport = googlecloudapigeev1customreport
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsReportsCreateCall) Fields(s ...googleapi.Field) *OrganizationsReportsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsReportsCreateCall) Context(ctx context.Context) *OrganizationsReportsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsReportsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsReportsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1customreport)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/reports")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.reports.create" call.
// Exactly one of *GoogleCloudApigeeV1CustomReport or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1CustomReport.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsReportsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1CustomReport, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1CustomReport{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a Custom Report for an Organization. A Custom Report provides Apigee Customers to create custom dashboards in addition to the standard dashboards which are provided. The Custom Report in its simplest form contains specifications about metrics, dimensions and filters. It is important to note that the custom report by itself does not provide an executable entity. The Edge UI converts the custom report definition into an analytics query and displays the result in a chart.",
	//   "flatPath": "v1/organizations/{organizationsId}/reports",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.reports.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. The parent organization name under which the Custom Report will be created. Must be of the form: `organizations/{organization_id}/reports`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/reports",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1CustomReport"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1CustomReport"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.reports.delete":

type OrganizationsReportsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an existing custom report definition
//
//   - name: Custom Report name of the form:
//     `organizations/{organization_id}/reports/{report_name}`.
func (r *OrganizationsReportsService) Delete(name string) *OrganizationsReportsDeleteCall {
	c := &OrganizationsReportsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsReportsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsReportsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsReportsDeleteCall) Context(ctx context.Context) *OrganizationsReportsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsReportsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsReportsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.reports.delete" call.
// Exactly one of *GoogleCloudApigeeV1DeleteCustomReportResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1DeleteCustomReportResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsReportsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeleteCustomReportResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeleteCustomReportResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an existing custom report definition",
	//   "flatPath": "v1/organizations/{organizationsId}/reports/{reportsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.reports.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Custom Report name of the form: `organizations/{organization_id}/reports/{report_name}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/reports/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeleteCustomReportResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.reports.get":

type OrganizationsReportsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Retrieve a custom report definition.
//
//   - name: Custom Report name of the form:
//     `organizations/{organization_id}/reports/{report_name}`.
func (r *OrganizationsReportsService) Get(name string) *OrganizationsReportsGetCall {
	c := &OrganizationsReportsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsReportsGetCall) Fields(s ...googleapi.Field) *OrganizationsReportsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsReportsGetCall) IfNoneMatch(entityTag string) *OrganizationsReportsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsReportsGetCall) Context(ctx context.Context) *OrganizationsReportsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsReportsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsReportsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.reports.get" call.
// Exactly one of *GoogleCloudApigeeV1CustomReport or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1CustomReport.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsReportsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1CustomReport, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1CustomReport{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Retrieve a custom report definition.",
	//   "flatPath": "v1/organizations/{organizationsId}/reports/{reportsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.reports.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Custom Report name of the form: `organizations/{organization_id}/reports/{report_name}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/reports/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1CustomReport"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.reports.list":

type OrganizationsReportsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Return a list of Custom Reports
//
//   - parent: The parent organization name under which the API product
//     will be listed `organizations/{organization_id}/reports`.
func (r *OrganizationsReportsService) List(parent string) *OrganizationsReportsListCall {
	c := &OrganizationsReportsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Expand sets the optional parameter "expand": Set to 'true' to get
// expanded details about each custom report.
func (c *OrganizationsReportsListCall) Expand(expand bool) *OrganizationsReportsListCall {
	c.urlParams_.Set("expand", fmt.Sprint(expand))
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsReportsListCall) Fields(s ...googleapi.Field) *OrganizationsReportsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsReportsListCall) IfNoneMatch(entityTag string) *OrganizationsReportsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsReportsListCall) Context(ctx context.Context) *OrganizationsReportsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsReportsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsReportsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/reports")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.reports.list" call.
// Exactly one of *GoogleCloudApigeeV1ListCustomReportsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListCustomReportsResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsReportsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListCustomReportsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListCustomReportsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Return a list of Custom Reports",
	//   "flatPath": "v1/organizations/{organizationsId}/reports",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.reports.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "expand": {
	//       "description": "Set to 'true' to get expanded details about each custom report.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "parent": {
	//       "description": "Required. The parent organization name under which the API product will be listed `organizations/{organization_id}/reports`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/reports",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListCustomReportsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.reports.update":

type OrganizationsReportsUpdateCall struct {
	s                               *Service
	name                            string
	googlecloudapigeev1customreport *GoogleCloudApigeeV1CustomReport
	urlParams_                      gensupport.URLParams
	ctx_                            context.Context
	header_                         http.Header
}

// Update: Update an existing custom report definition
//
//   - name: Custom Report name of the form:
//     `organizations/{organization_id}/reports/{report_name}`.
func (r *OrganizationsReportsService) Update(name string, googlecloudapigeev1customreport *GoogleCloudApigeeV1CustomReport) *OrganizationsReportsUpdateCall {
	c := &OrganizationsReportsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1customreport = googlecloudapigeev1customreport
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsReportsUpdateCall) Fields(s ...googleapi.Field) *OrganizationsReportsUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsReportsUpdateCall) Context(ctx context.Context) *OrganizationsReportsUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsReportsUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsReportsUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1customreport)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.reports.update" call.
// Exactly one of *GoogleCloudApigeeV1CustomReport or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1CustomReport.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsReportsUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1CustomReport, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1CustomReport{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Update an existing custom report definition",
	//   "flatPath": "v1/organizations/{organizationsId}/reports/{reportsId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.reports.update",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Custom Report name of the form: `organizations/{organization_id}/reports/{report_name}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/reports/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1CustomReport"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1CustomReport"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.securityProfiles.create":

type OrganizationsSecurityProfilesCreateCall struct {
	s                                  *Service
	parent                             string
	googlecloudapigeev1securityprofile *GoogleCloudApigeeV1SecurityProfile
	urlParams_                         gensupport.URLParams
	ctx_                               context.Context
	header_                            http.Header
}

// Create: CreateSecurityProfile create a new custom security profile.
//
// - parent: Name of organization. Format: organizations/{org}.
func (r *OrganizationsSecurityProfilesService) Create(parent string, googlecloudapigeev1securityprofile *GoogleCloudApigeeV1SecurityProfile) *OrganizationsSecurityProfilesCreateCall {
	c := &OrganizationsSecurityProfilesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1securityprofile = googlecloudapigeev1securityprofile
	return c
}

// SecurityProfileId sets the optional parameter "securityProfileId":
// Required. The ID to use for the SecurityProfile, which will become
// the final component of the action's resource name. This value should
// be 1-63 characters and validated by "(^a-z
// ([a-z0-9-]{0,61}[a-z0-9])?$)".
func (c *OrganizationsSecurityProfilesCreateCall) SecurityProfileId(securityProfileId string) *OrganizationsSecurityProfilesCreateCall {
	c.urlParams_.Set("securityProfileId", securityProfileId)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSecurityProfilesCreateCall) Fields(s ...googleapi.Field) *OrganizationsSecurityProfilesCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSecurityProfilesCreateCall) Context(ctx context.Context) *OrganizationsSecurityProfilesCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSecurityProfilesCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSecurityProfilesCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1securityprofile)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/securityProfiles")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.securityProfiles.create" call.
// Exactly one of *GoogleCloudApigeeV1SecurityProfile or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SecurityProfile.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSecurityProfilesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityProfile, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityProfile{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "CreateSecurityProfile create a new custom security profile.",
	//   "flatPath": "v1/organizations/{organizationsId}/securityProfiles",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.securityProfiles.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of organization. Format: organizations/{org}",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "securityProfileId": {
	//       "description": "Required. The ID to use for the SecurityProfile, which will become the final component of the action's resource name. This value should be 1-63 characters and validated by \"(^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$)\".",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/securityProfiles",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1SecurityProfile"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityProfile"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.securityProfiles.delete":

type OrganizationsSecurityProfilesDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: DeleteSecurityProfile delete a profile with all its
// revisions.
//
//   - name: Name of profile. Format:
//     organizations/{org}/securityProfiles/{profile}.
func (r *OrganizationsSecurityProfilesService) Delete(name string) *OrganizationsSecurityProfilesDeleteCall {
	c := &OrganizationsSecurityProfilesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSecurityProfilesDeleteCall) Fields(s ...googleapi.Field) *OrganizationsSecurityProfilesDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSecurityProfilesDeleteCall) Context(ctx context.Context) *OrganizationsSecurityProfilesDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSecurityProfilesDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSecurityProfilesDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.securityProfiles.delete" call.
// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsSecurityProfilesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleProtobufEmpty{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "DeleteSecurityProfile delete a profile with all its revisions.",
	//   "flatPath": "v1/organizations/{organizationsId}/securityProfiles/{securityProfilesId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.securityProfiles.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of profile. Format: organizations/{org}/securityProfiles/{profile}",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/securityProfiles/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleProtobufEmpty"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.securityProfiles.get":

type OrganizationsSecurityProfilesGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: GetSecurityProfile gets the specified security profile. Returns
// NOT_FOUND if security profile is not present for the specified
// organization.
//
//   - name: Security profile in the following format:
//     `organizations/{org}/securityProfiles/{profile}'. Profile may
//     optionally contain revision ID. If revision ID is not provided, the
//     response will contain latest revision by default. Example:
//     organizations/testOrg/securityProfiles/testProfile@5.
func (r *OrganizationsSecurityProfilesService) Get(name string) *OrganizationsSecurityProfilesGetCall {
	c := &OrganizationsSecurityProfilesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSecurityProfilesGetCall) Fields(s ...googleapi.Field) *OrganizationsSecurityProfilesGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsSecurityProfilesGetCall) IfNoneMatch(entityTag string) *OrganizationsSecurityProfilesGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSecurityProfilesGetCall) Context(ctx context.Context) *OrganizationsSecurityProfilesGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSecurityProfilesGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSecurityProfilesGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.securityProfiles.get" call.
// Exactly one of *GoogleCloudApigeeV1SecurityProfile or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SecurityProfile.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSecurityProfilesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityProfile, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityProfile{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "GetSecurityProfile gets the specified security profile. Returns NOT_FOUND if security profile is not present for the specified organization.",
	//   "flatPath": "v1/organizations/{organizationsId}/securityProfiles/{securityProfilesId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.securityProfiles.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Security profile in the following format: `organizations/{org}/securityProfiles/{profile}'. Profile may optionally contain revision ID. If revision ID is not provided, the response will contain latest revision by default. Example: organizations/testOrg/securityProfiles/testProfile@5",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/securityProfiles/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityProfile"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.securityProfiles.list":

type OrganizationsSecurityProfilesListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: ListSecurityProfiles lists all the security profiles associated
// with the org including attached and unattached profiles.
//
//   - parent: For a specific organization, list of all the security
//     profiles. Format: `organizations/{org}`.
func (r *OrganizationsSecurityProfilesService) List(parent string) *OrganizationsSecurityProfilesListCall {
	c := &OrganizationsSecurityProfilesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// PageSize sets the optional parameter "pageSize": The maximum number
// of profiles to return. The service may return fewer than this value.
// If unspecified, at most 50 profiles will be returned.
func (c *OrganizationsSecurityProfilesListCall) PageSize(pageSize int64) *OrganizationsSecurityProfilesListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": A page token,
// received from a previous `ListSecurityProfiles` call. Provide this to
// retrieve the subsequent page.
func (c *OrganizationsSecurityProfilesListCall) PageToken(pageToken string) *OrganizationsSecurityProfilesListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSecurityProfilesListCall) Fields(s ...googleapi.Field) *OrganizationsSecurityProfilesListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsSecurityProfilesListCall) IfNoneMatch(entityTag string) *OrganizationsSecurityProfilesListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSecurityProfilesListCall) Context(ctx context.Context) *OrganizationsSecurityProfilesListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSecurityProfilesListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSecurityProfilesListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/securityProfiles")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.securityProfiles.list" call.
// Exactly one of *GoogleCloudApigeeV1ListSecurityProfilesResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListSecurityProfilesResponse.ServerResponse.Header
//
//	or (if a response was returned at all) in
//
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSecurityProfilesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListSecurityProfilesResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListSecurityProfilesResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "ListSecurityProfiles lists all the security profiles associated with the org including attached and unattached profiles.",
	//   "flatPath": "v1/organizations/{organizationsId}/securityProfiles",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.securityProfiles.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "pageSize": {
	//       "description": "The maximum number of profiles to return. The service may return fewer than this value. If unspecified, at most 50 profiles will be returned.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "A page token, received from a previous `ListSecurityProfiles` call. Provide this to retrieve the subsequent page.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. For a specific organization, list of all the security profiles. Format: `organizations/{org}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/securityProfiles",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListSecurityProfilesResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsSecurityProfilesListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListSecurityProfilesResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.securityProfiles.listRevisions":

type OrganizationsSecurityProfilesListRevisionsCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// ListRevisions: ListSecurityProfileRevisions lists all the revisions
// of the security profile.
//
//   - name: For a specific profile, list all the revisions. Format:
//     `organizations/{org}/securityProfiles/{profile}`.
func (r *OrganizationsSecurityProfilesService) ListRevisions(name string) *OrganizationsSecurityProfilesListRevisionsCall {
	c := &OrganizationsSecurityProfilesListRevisionsCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// PageSize sets the optional parameter "pageSize": The maximum number
// of profile revisions to return. The service may return fewer than
// this value. If unspecified, at most 50 revisions will be returned.
func (c *OrganizationsSecurityProfilesListRevisionsCall) PageSize(pageSize int64) *OrganizationsSecurityProfilesListRevisionsCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": A page token,
// received from a previous `ListSecurityProfileRevisions` call. Provide
// this to retrieve the subsequent page.
func (c *OrganizationsSecurityProfilesListRevisionsCall) PageToken(pageToken string) *OrganizationsSecurityProfilesListRevisionsCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSecurityProfilesListRevisionsCall) Fields(s ...googleapi.Field) *OrganizationsSecurityProfilesListRevisionsCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsSecurityProfilesListRevisionsCall) IfNoneMatch(entityTag string) *OrganizationsSecurityProfilesListRevisionsCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSecurityProfilesListRevisionsCall) Context(ctx context.Context) *OrganizationsSecurityProfilesListRevisionsCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSecurityProfilesListRevisionsCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSecurityProfilesListRevisionsCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}:listRevisions")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.securityProfiles.listRevisions" call.
// Exactly one of
// *GoogleCloudApigeeV1ListSecurityProfileRevisionsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListSecurityProfileRevisionsResponse.ServerRespons
// e.Header or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSecurityProfilesListRevisionsCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListSecurityProfileRevisionsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListSecurityProfileRevisionsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "ListSecurityProfileRevisions lists all the revisions of the security profile.",
	//   "flatPath": "v1/organizations/{organizationsId}/securityProfiles/{securityProfilesId}:listRevisions",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.securityProfiles.listRevisions",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. For a specific profile, list all the revisions. Format: `organizations/{org}/securityProfiles/{profile}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/securityProfiles/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "pageSize": {
	//       "description": "The maximum number of profile revisions to return. The service may return fewer than this value. If unspecified, at most 50 revisions will be returned.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "A page token, received from a previous `ListSecurityProfileRevisions` call. Provide this to retrieve the subsequent page.",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}:listRevisions",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListSecurityProfileRevisionsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsSecurityProfilesListRevisionsCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListSecurityProfileRevisionsResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.securityProfiles.patch":

type OrganizationsSecurityProfilesPatchCall struct {
	s                                  *Service
	name                               string
	googlecloudapigeev1securityprofile *GoogleCloudApigeeV1SecurityProfile
	urlParams_                         gensupport.URLParams
	ctx_                               context.Context
	header_                            http.Header
}

// Patch: UpdateSecurityProfile update the metadata of security profile.
//
//   - name: Immutable. Name of the security profile resource. Format:
//     organizations/{org}/securityProfiles/{profile}.
func (r *OrganizationsSecurityProfilesService) Patch(name string, googlecloudapigeev1securityprofile *GoogleCloudApigeeV1SecurityProfile) *OrganizationsSecurityProfilesPatchCall {
	c := &OrganizationsSecurityProfilesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1securityprofile = googlecloudapigeev1securityprofile
	return c
}

// UpdateMask sets the optional parameter "updateMask": Required. The
// list of fields to update.
func (c *OrganizationsSecurityProfilesPatchCall) UpdateMask(updateMask string) *OrganizationsSecurityProfilesPatchCall {
	c.urlParams_.Set("updateMask", updateMask)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSecurityProfilesPatchCall) Fields(s ...googleapi.Field) *OrganizationsSecurityProfilesPatchCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSecurityProfilesPatchCall) Context(ctx context.Context) *OrganizationsSecurityProfilesPatchCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSecurityProfilesPatchCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSecurityProfilesPatchCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1securityprofile)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PATCH", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.securityProfiles.patch" call.
// Exactly one of *GoogleCloudApigeeV1SecurityProfile or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SecurityProfile.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSecurityProfilesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityProfile, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityProfile{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "UpdateSecurityProfile update the metadata of security profile.",
	//   "flatPath": "v1/organizations/{organizationsId}/securityProfiles/{securityProfilesId}",
	//   "httpMethod": "PATCH",
	//   "id": "apigee.organizations.securityProfiles.patch",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Immutable. Name of the security profile resource. Format: organizations/{org}/securityProfiles/{profile}",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/securityProfiles/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "updateMask": {
	//       "description": "Required. The list of fields to update.",
	//       "format": "google-fieldmask",
	//       "location": "query",
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1SecurityProfile"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityProfile"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.securityProfiles.environments.computeEnvironmentScores":

type OrganizationsSecurityProfilesEnvironmentsComputeEnvironmentScoresCall struct {
	s                                                  *Service
	profileEnvironment                                 string
	googlecloudapigeev1computeenvironmentscoresrequest *GoogleCloudApigeeV1ComputeEnvironmentScoresRequest
	urlParams_                                         gensupport.URLParams
	ctx_                                               context.Context
	header_                                            http.Header
}

// ComputeEnvironmentScores: ComputeEnvironmentScores calculates scores
// for requested time range for the specified security profile and
// environment.
//
//   - profileEnvironment: Name of organization and environment and
//     profile id for which score needs to be computed. Format:
//     organizations/{org}/securityProfiles/{profile}/environments/{env}.
func (r *OrganizationsSecurityProfilesEnvironmentsService) ComputeEnvironmentScores(profileEnvironment string, googlecloudapigeev1computeenvironmentscoresrequest *GoogleCloudApigeeV1ComputeEnvironmentScoresRequest) *OrganizationsSecurityProfilesEnvironmentsComputeEnvironmentScoresCall {
	c := &OrganizationsSecurityProfilesEnvironmentsComputeEnvironmentScoresCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.profileEnvironment = profileEnvironment
	c.googlecloudapigeev1computeenvironmentscoresrequest = googlecloudapigeev1computeenvironmentscoresrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSecurityProfilesEnvironmentsComputeEnvironmentScoresCall) Fields(s ...googleapi.Field) *OrganizationsSecurityProfilesEnvironmentsComputeEnvironmentScoresCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSecurityProfilesEnvironmentsComputeEnvironmentScoresCall) Context(ctx context.Context) *OrganizationsSecurityProfilesEnvironmentsComputeEnvironmentScoresCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSecurityProfilesEnvironmentsComputeEnvironmentScoresCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSecurityProfilesEnvironmentsComputeEnvironmentScoresCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1computeenvironmentscoresrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+profileEnvironment}:computeEnvironmentScores")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"profileEnvironment": c.profileEnvironment,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.securityProfiles.environments.computeEnvironmentScores" call.
// Exactly one of *GoogleCloudApigeeV1ComputeEnvironmentScoresResponse
// or error will be non-nil. Any non-2xx status code is an error.
// Response headers are in either
// *GoogleCloudApigeeV1ComputeEnvironmentScoresResponse.ServerResponse.He
// ader or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSecurityProfilesEnvironmentsComputeEnvironmentScoresCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ComputeEnvironmentScoresResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ComputeEnvironmentScoresResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "ComputeEnvironmentScores calculates scores for requested time range for the specified security profile and environment.",
	//   "flatPath": "v1/organizations/{organizationsId}/securityProfiles/{securityProfilesId}/environments/{environmentsId}:computeEnvironmentScores",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.securityProfiles.environments.computeEnvironmentScores",
	//   "parameterOrder": [
	//     "profileEnvironment"
	//   ],
	//   "parameters": {
	//     "profileEnvironment": {
	//       "description": "Required. Name of organization and environment and profile id for which score needs to be computed. Format: organizations/{org}/securityProfiles/{profile}/environments/{env}",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/securityProfiles/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+profileEnvironment}:computeEnvironmentScores",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1ComputeEnvironmentScoresRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ComputeEnvironmentScoresResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsSecurityProfilesEnvironmentsComputeEnvironmentScoresCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ComputeEnvironmentScoresResponse) error) error {
	c.ctx_ = ctx
	defer func(pt string) { c.googlecloudapigeev1computeenvironmentscoresrequest.PageToken = pt }(c.googlecloudapigeev1computeenvironmentscoresrequest.PageToken) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.googlecloudapigeev1computeenvironmentscoresrequest.PageToken = x.NextPageToken
	}
}

// method id "apigee.organizations.securityProfiles.environments.create":

type OrganizationsSecurityProfilesEnvironmentsCreateCall struct {
	s                                                        *Service
	parent                                                   string
	googlecloudapigeev1securityprofileenvironmentassociation *GoogleCloudApigeeV1SecurityProfileEnvironmentAssociation
	urlParams_                                               gensupport.URLParams
	ctx_                                                     context.Context
	header_                                                  http.Header
}

// Create: CreateSecurityProfileEnvironmentAssociation creates profile
// environment association i.e. attaches environment to security
// profile.
//
//   - parent: Name of organization and security profile ID. Format:
//     organizations/{org}/securityProfiles/{profile}.
func (r *OrganizationsSecurityProfilesEnvironmentsService) Create(parent string, googlecloudapigeev1securityprofileenvironmentassociation *GoogleCloudApigeeV1SecurityProfileEnvironmentAssociation) *OrganizationsSecurityProfilesEnvironmentsCreateCall {
	c := &OrganizationsSecurityProfilesEnvironmentsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1securityprofileenvironmentassociation = googlecloudapigeev1securityprofileenvironmentassociation
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSecurityProfilesEnvironmentsCreateCall) Fields(s ...googleapi.Field) *OrganizationsSecurityProfilesEnvironmentsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSecurityProfilesEnvironmentsCreateCall) Context(ctx context.Context) *OrganizationsSecurityProfilesEnvironmentsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSecurityProfilesEnvironmentsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSecurityProfilesEnvironmentsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1securityprofileenvironmentassociation)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/environments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.securityProfiles.environments.create" call.
// Exactly one of
// *GoogleCloudApigeeV1SecurityProfileEnvironmentAssociation or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1SecurityProfileEnvironmentAssociation.ServerRespon
// se.Header or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSecurityProfilesEnvironmentsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SecurityProfileEnvironmentAssociation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SecurityProfileEnvironmentAssociation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "CreateSecurityProfileEnvironmentAssociation creates profile environment association i.e. attaches environment to security profile.",
	//   "flatPath": "v1/organizations/{organizationsId}/securityProfiles/{securityProfilesId}/environments",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.securityProfiles.environments.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of organization and security profile ID. Format: organizations/{org}/securityProfiles/{profile}",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/securityProfiles/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/environments",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1SecurityProfileEnvironmentAssociation"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SecurityProfileEnvironmentAssociation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.securityProfiles.environments.delete":

type OrganizationsSecurityProfilesEnvironmentsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: DeleteSecurityProfileEnvironmentAssociation removes profile
// environment association i.e. detaches environment from security
// profile.
//
//   - name: The name of the environment attachment to delete. Format:
//     organizations/{org}/securityProfiles/{profile}/environments/{env}.
func (r *OrganizationsSecurityProfilesEnvironmentsService) Delete(name string) *OrganizationsSecurityProfilesEnvironmentsDeleteCall {
	c := &OrganizationsSecurityProfilesEnvironmentsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSecurityProfilesEnvironmentsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsSecurityProfilesEnvironmentsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSecurityProfilesEnvironmentsDeleteCall) Context(ctx context.Context) *OrganizationsSecurityProfilesEnvironmentsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSecurityProfilesEnvironmentsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSecurityProfilesEnvironmentsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.securityProfiles.environments.delete" call.
// Exactly one of *GoogleProtobufEmpty or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleProtobufEmpty.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsSecurityProfilesEnvironmentsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleProtobufEmpty, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleProtobufEmpty{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "DeleteSecurityProfileEnvironmentAssociation removes profile environment association i.e. detaches environment from security profile.",
	//   "flatPath": "v1/organizations/{organizationsId}/securityProfiles/{securityProfilesId}/environments/{environmentsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.securityProfiles.environments.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the environment attachment to delete. Format: organizations/{org}/securityProfiles/{profile}/environments/{env}",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/securityProfiles/[^/]+/environments/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleProtobufEmpty"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sharedflows.create":

type OrganizationsSharedflowsCreateCall struct {
	s                 *Service
	parent            string
	googleapihttpbody *GoogleApiHttpBody
	urlParams_        gensupport.URLParams
	ctx_              context.Context
	header_           http.Header
}

// Create: Uploads a ZIP-formatted shared flow configuration bundle to
// an organization. If the shared flow already exists, this creates a
// new revision of it. If the shared flow does not exist, this creates
// it. Once imported, the shared flow revision must be deployed before
// it can be accessed at runtime. The size limit of a shared flow bundle
// is 15 MB.
//
//   - parent: The name of the parent organization under which to create
//     the shared flow. Must be of the form:
//     `organizations/{organization_id}`.
func (r *OrganizationsSharedflowsService) Create(parent string, googleapihttpbody *GoogleApiHttpBody) *OrganizationsSharedflowsCreateCall {
	c := &OrganizationsSharedflowsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googleapihttpbody = googleapihttpbody
	return c
}

// Action sets the optional parameter "action": Required. Must be set to
// either `import` or `validate`.
func (c *OrganizationsSharedflowsCreateCall) Action(action string) *OrganizationsSharedflowsCreateCall {
	c.urlParams_.Set("action", action)
	return c
}

// Name sets the optional parameter "name": Required. The name to give
// the shared flow
func (c *OrganizationsSharedflowsCreateCall) Name(name string) *OrganizationsSharedflowsCreateCall {
	c.urlParams_.Set("name", name)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSharedflowsCreateCall) Fields(s ...googleapi.Field) *OrganizationsSharedflowsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSharedflowsCreateCall) Context(ctx context.Context) *OrganizationsSharedflowsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSharedflowsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSharedflowsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleapihttpbody)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/sharedflows")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sharedflows.create" call.
// Exactly one of *GoogleCloudApigeeV1SharedFlowRevision or error will
// be non-nil. Any non-2xx status code is an error. Response headers are
// in either
// *GoogleCloudApigeeV1SharedFlowRevision.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsSharedflowsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SharedFlowRevision, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SharedFlowRevision{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Uploads a ZIP-formatted shared flow configuration bundle to an organization. If the shared flow already exists, this creates a new revision of it. If the shared flow does not exist, this creates it. Once imported, the shared flow revision must be deployed before it can be accessed at runtime. The size limit of a shared flow bundle is 15 MB.",
	//   "flatPath": "v1/organizations/{organizationsId}/sharedflows",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.sharedflows.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "action": {
	//       "description": "Required. Must be set to either `import` or `validate`.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "Required. The name to give the shared flow",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. The name of the parent organization under which to create the shared flow. Must be of the form: `organizations/{organization_id}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/sharedflows",
	//   "request": {
	//     "$ref": "GoogleApiHttpBody"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SharedFlowRevision"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sharedflows.delete":

type OrganizationsSharedflowsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a shared flow and all it's revisions. The shared flow
// must be undeployed before you can delete it.
//
//   - name: shared flow name of the form:
//     `organizations/{organization_id}/sharedflows/{shared_flow_id}`.
func (r *OrganizationsSharedflowsService) Delete(name string) *OrganizationsSharedflowsDeleteCall {
	c := &OrganizationsSharedflowsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSharedflowsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsSharedflowsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSharedflowsDeleteCall) Context(ctx context.Context) *OrganizationsSharedflowsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSharedflowsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSharedflowsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sharedflows.delete" call.
// Exactly one of *GoogleCloudApigeeV1SharedFlow or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SharedFlow.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsSharedflowsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SharedFlow, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SharedFlow{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a shared flow and all it's revisions. The shared flow must be undeployed before you can delete it.",
	//   "flatPath": "v1/organizations/{organizationsId}/sharedflows/{sharedflowsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.sharedflows.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. shared flow name of the form: `organizations/{organization_id}/sharedflows/{shared_flow_id}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sharedflows/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SharedFlow"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sharedflows.get":

type OrganizationsSharedflowsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets a shared flow by name, including a list of its revisions.
//
//   - name: The name of the shared flow to get. Must be of the form:
//     `organizations/{organization_id}/sharedflows/{shared_flow_id}`.
func (r *OrganizationsSharedflowsService) Get(name string) *OrganizationsSharedflowsGetCall {
	c := &OrganizationsSharedflowsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSharedflowsGetCall) Fields(s ...googleapi.Field) *OrganizationsSharedflowsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsSharedflowsGetCall) IfNoneMatch(entityTag string) *OrganizationsSharedflowsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSharedflowsGetCall) Context(ctx context.Context) *OrganizationsSharedflowsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSharedflowsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSharedflowsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sharedflows.get" call.
// Exactly one of *GoogleCloudApigeeV1SharedFlow or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1SharedFlow.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsSharedflowsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SharedFlow, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SharedFlow{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets a shared flow by name, including a list of its revisions.",
	//   "flatPath": "v1/organizations/{organizationsId}/sharedflows/{sharedflowsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.sharedflows.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the shared flow to get. Must be of the form: `organizations/{organization_id}/sharedflows/{shared_flow_id}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sharedflows/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SharedFlow"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sharedflows.list":

type OrganizationsSharedflowsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all shared flows in the organization.
//
//   - parent: The name of the parent organization under which to get
//     shared flows. Must be of the form:
//     `organizations/{organization_id}`.
func (r *OrganizationsSharedflowsService) List(parent string) *OrganizationsSharedflowsListCall {
	c := &OrganizationsSharedflowsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// IncludeMetaData sets the optional parameter "includeMetaData":
// Indicates whether to include shared flow metadata in the response.
func (c *OrganizationsSharedflowsListCall) IncludeMetaData(includeMetaData bool) *OrganizationsSharedflowsListCall {
	c.urlParams_.Set("includeMetaData", fmt.Sprint(includeMetaData))
	return c
}

// IncludeRevisions sets the optional parameter "includeRevisions":
// Indicates whether to include a list of revisions in the response.
func (c *OrganizationsSharedflowsListCall) IncludeRevisions(includeRevisions bool) *OrganizationsSharedflowsListCall {
	c.urlParams_.Set("includeRevisions", fmt.Sprint(includeRevisions))
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSharedflowsListCall) Fields(s ...googleapi.Field) *OrganizationsSharedflowsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsSharedflowsListCall) IfNoneMatch(entityTag string) *OrganizationsSharedflowsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSharedflowsListCall) Context(ctx context.Context) *OrganizationsSharedflowsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSharedflowsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSharedflowsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/sharedflows")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sharedflows.list" call.
// Exactly one of *GoogleCloudApigeeV1ListSharedFlowsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListSharedFlowsResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSharedflowsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListSharedFlowsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListSharedFlowsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all shared flows in the organization.",
	//   "flatPath": "v1/organizations/{organizationsId}/sharedflows",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.sharedflows.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "includeMetaData": {
	//       "description": "Indicates whether to include shared flow metadata in the response.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "includeRevisions": {
	//       "description": "Indicates whether to include a list of revisions in the response.",
	//       "location": "query",
	//       "type": "boolean"
	//     },
	//     "parent": {
	//       "description": "Required. The name of the parent organization under which to get shared flows. Must be of the form: `organizations/{organization_id}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/sharedflows",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListSharedFlowsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sharedflows.deployments.list":

type OrganizationsSharedflowsDeploymentsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all deployments of a shared flow.
//
//   - parent: Name of the shared flow for which to return deployment
//     information in the following format:
//     `organizations/{org}/sharedflows/{sharedflow}`.
func (r *OrganizationsSharedflowsDeploymentsService) List(parent string) *OrganizationsSharedflowsDeploymentsListCall {
	c := &OrganizationsSharedflowsDeploymentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSharedflowsDeploymentsListCall) Fields(s ...googleapi.Field) *OrganizationsSharedflowsDeploymentsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsSharedflowsDeploymentsListCall) IfNoneMatch(entityTag string) *OrganizationsSharedflowsDeploymentsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSharedflowsDeploymentsListCall) Context(ctx context.Context) *OrganizationsSharedflowsDeploymentsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSharedflowsDeploymentsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSharedflowsDeploymentsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/deployments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sharedflows.deployments.list" call.
// Exactly one of *GoogleCloudApigeeV1ListDeploymentsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListDeploymentsResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSharedflowsDeploymentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListDeploymentsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListDeploymentsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all deployments of a shared flow.",
	//   "flatPath": "v1/organizations/{organizationsId}/sharedflows/{sharedflowsId}/deployments",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.sharedflows.deployments.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the shared flow for which to return deployment information in the following format: `organizations/{org}/sharedflows/{sharedflow}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sharedflows/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/deployments",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListDeploymentsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sharedflows.revisions.delete":

type OrganizationsSharedflowsRevisionsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a shared flow and all associated policies, resources,
// and revisions. You must undeploy the shared flow before deleting it.
//
//   - name: The name of the shared flow revision to delete. Must be of
//     the form:
//     `organizations/{organization_id}/sharedflows/{shared_flow_id}/revisi
//     ons/{revision_id}`.
func (r *OrganizationsSharedflowsRevisionsService) Delete(name string) *OrganizationsSharedflowsRevisionsDeleteCall {
	c := &OrganizationsSharedflowsRevisionsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSharedflowsRevisionsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsSharedflowsRevisionsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSharedflowsRevisionsDeleteCall) Context(ctx context.Context) *OrganizationsSharedflowsRevisionsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSharedflowsRevisionsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSharedflowsRevisionsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sharedflows.revisions.delete" call.
// Exactly one of *GoogleCloudApigeeV1SharedFlowRevision or error will
// be non-nil. Any non-2xx status code is an error. Response headers are
// in either
// *GoogleCloudApigeeV1SharedFlowRevision.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsSharedflowsRevisionsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SharedFlowRevision, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SharedFlowRevision{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a shared flow and all associated policies, resources, and revisions. You must undeploy the shared flow before deleting it.",
	//   "flatPath": "v1/organizations/{organizationsId}/sharedflows/{sharedflowsId}/revisions/{revisionsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.sharedflows.revisions.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the shared flow revision to delete. Must be of the form: `organizations/{organization_id}/sharedflows/{shared_flow_id}/revisions/{revision_id}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sharedflows/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SharedFlowRevision"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sharedflows.revisions.get":

type OrganizationsSharedflowsRevisionsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets a revision of a shared flow. To download the shared flow
// configuration bundle for the specified revision as a zip file, set
// the `format` query parameter to `bundle`. If you are using curl,
// specify `-o filename.zip` to save the output to a file; otherwise, it
// displays to `stdout`. Then, develop the shared flow configuration
// locally and upload the updated sharedFlow configuration revision, as
// described in updateSharedFlowRevision (updateSharedFlowRevision).
//
//   - name: The name of the shared flow revision to get. Must be of the
//     form:
//     `organizations/{organization_id}/sharedflows/{shared_flow_id}/revisi
//     ons/{revision_id}`.
func (r *OrganizationsSharedflowsRevisionsService) Get(name string) *OrganizationsSharedflowsRevisionsGetCall {
	c := &OrganizationsSharedflowsRevisionsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Format sets the optional parameter "format": Specify `bundle` to
// export the contents of the shared flow bundle. Otherwise, the bundle
// metadata is returned.
func (c *OrganizationsSharedflowsRevisionsGetCall) Format(format string) *OrganizationsSharedflowsRevisionsGetCall {
	c.urlParams_.Set("format", format)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSharedflowsRevisionsGetCall) Fields(s ...googleapi.Field) *OrganizationsSharedflowsRevisionsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsSharedflowsRevisionsGetCall) IfNoneMatch(entityTag string) *OrganizationsSharedflowsRevisionsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSharedflowsRevisionsGetCall) Context(ctx context.Context) *OrganizationsSharedflowsRevisionsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSharedflowsRevisionsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSharedflowsRevisionsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sharedflows.revisions.get" call.
// Exactly one of *GoogleApiHttpBody or error will be non-nil. Any
// non-2xx status code is an error. Response headers are in either
// *GoogleApiHttpBody.ServerResponse.Header or (if a response was
// returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsSharedflowsRevisionsGetCall) Do(opts ...googleapi.CallOption) (*GoogleApiHttpBody, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleApiHttpBody{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets a revision of a shared flow. To download the shared flow configuration bundle for the specified revision as a zip file, set the `format` query parameter to `bundle`. If you are using curl, specify `-o filename.zip` to save the output to a file; otherwise, it displays to `stdout`. Then, develop the shared flow configuration locally and upload the updated sharedFlow configuration revision, as described in [updateSharedFlowRevision](updateSharedFlowRevision).",
	//   "flatPath": "v1/organizations/{organizationsId}/sharedflows/{sharedflowsId}/revisions/{revisionsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.sharedflows.revisions.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "format": {
	//       "description": "Specify `bundle` to export the contents of the shared flow bundle. Otherwise, the bundle metadata is returned.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "name": {
	//       "description": "Required. The name of the shared flow revision to get. Must be of the form: `organizations/{organization_id}/sharedflows/{shared_flow_id}/revisions/{revision_id}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sharedflows/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleApiHttpBody"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sharedflows.revisions.updateSharedFlowRevision":

type OrganizationsSharedflowsRevisionsUpdateSharedFlowRevisionCall struct {
	s                 *Service
	name              string
	googleapihttpbody *GoogleApiHttpBody
	urlParams_        gensupport.URLParams
	ctx_              context.Context
	header_           http.Header
}

// UpdateSharedFlowRevision: Updates a shared flow revision. This
// operation is only allowed on revisions which have never been
// deployed. After deployment a revision becomes immutable, even if it
// becomes undeployed. The payload is a ZIP-formatted shared flow.
// Content type must be either multipart/form-data or
// application/octet-stream.
//
//   - name: The name of the shared flow revision to update. Must be of
//     the form:
//     `organizations/{organization_id}/sharedflows/{shared_flow_id}/revisi
//     ons/{revision_id}`.
func (r *OrganizationsSharedflowsRevisionsService) UpdateSharedFlowRevision(name string, googleapihttpbody *GoogleApiHttpBody) *OrganizationsSharedflowsRevisionsUpdateSharedFlowRevisionCall {
	c := &OrganizationsSharedflowsRevisionsUpdateSharedFlowRevisionCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googleapihttpbody = googleapihttpbody
	return c
}

// Validate sets the optional parameter "validate": Ignored. All uploads
// are validated regardless of the value of this field. It is kept for
// compatibility with existing APIs. Must be `true` or `false` if
// provided.
func (c *OrganizationsSharedflowsRevisionsUpdateSharedFlowRevisionCall) Validate(validate bool) *OrganizationsSharedflowsRevisionsUpdateSharedFlowRevisionCall {
	c.urlParams_.Set("validate", fmt.Sprint(validate))
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSharedflowsRevisionsUpdateSharedFlowRevisionCall) Fields(s ...googleapi.Field) *OrganizationsSharedflowsRevisionsUpdateSharedFlowRevisionCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSharedflowsRevisionsUpdateSharedFlowRevisionCall) Context(ctx context.Context) *OrganizationsSharedflowsRevisionsUpdateSharedFlowRevisionCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSharedflowsRevisionsUpdateSharedFlowRevisionCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSharedflowsRevisionsUpdateSharedFlowRevisionCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googleapihttpbody)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sharedflows.revisions.updateSharedFlowRevision" call.
// Exactly one of *GoogleCloudApigeeV1SharedFlowRevision or error will
// be non-nil. Any non-2xx status code is an error. Response headers are
// in either
// *GoogleCloudApigeeV1SharedFlowRevision.ServerResponse.Header or (if a
// response was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsSharedflowsRevisionsUpdateSharedFlowRevisionCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1SharedFlowRevision, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1SharedFlowRevision{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates a shared flow revision. This operation is only allowed on revisions which have never been deployed. After deployment a revision becomes immutable, even if it becomes undeployed. The payload is a ZIP-formatted shared flow. Content type must be either multipart/form-data or application/octet-stream.",
	//   "flatPath": "v1/organizations/{organizationsId}/sharedflows/{sharedflowsId}/revisions/{revisionsId}",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.sharedflows.revisions.updateSharedFlowRevision",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. The name of the shared flow revision to update. Must be of the form: `organizations/{organization_id}/sharedflows/{shared_flow_id}/revisions/{revision_id}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sharedflows/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     },
	//     "validate": {
	//       "description": "Ignored. All uploads are validated regardless of the value of this field. It is kept for compatibility with existing APIs. Must be `true` or `false` if provided.",
	//       "location": "query",
	//       "type": "boolean"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleApiHttpBody"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1SharedFlowRevision"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sharedflows.revisions.deployments.list":

type OrganizationsSharedflowsRevisionsDeploymentsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Lists all deployments of a shared flow revision.
//
//   - parent: Name of the API proxy revision for which to return
//     deployment information in the following format:
//     `organizations/{org}/sharedflows/{sharedflow}/revisions/{rev}`.
func (r *OrganizationsSharedflowsRevisionsDeploymentsService) List(parent string) *OrganizationsSharedflowsRevisionsDeploymentsListCall {
	c := &OrganizationsSharedflowsRevisionsDeploymentsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSharedflowsRevisionsDeploymentsListCall) Fields(s ...googleapi.Field) *OrganizationsSharedflowsRevisionsDeploymentsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsSharedflowsRevisionsDeploymentsListCall) IfNoneMatch(entityTag string) *OrganizationsSharedflowsRevisionsDeploymentsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSharedflowsRevisionsDeploymentsListCall) Context(ctx context.Context) *OrganizationsSharedflowsRevisionsDeploymentsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSharedflowsRevisionsDeploymentsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSharedflowsRevisionsDeploymentsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/deployments")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sharedflows.revisions.deployments.list" call.
// Exactly one of *GoogleCloudApigeeV1ListDeploymentsResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListDeploymentsResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSharedflowsRevisionsDeploymentsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListDeploymentsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListDeploymentsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Lists all deployments of a shared flow revision.",
	//   "flatPath": "v1/organizations/{organizationsId}/sharedflows/{sharedflowsId}/revisions/{revisionsId}/deployments",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.sharedflows.revisions.deployments.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the API proxy revision for which to return deployment information in the following format: `organizations/{org}/sharedflows/{sharedflow}/revisions/{rev}`.",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sharedflows/[^/]+/revisions/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/deployments",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListDeploymentsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sites.apicategories.create":

type OrganizationsSitesApicategoriesCreateCall struct {
	s                              *Service
	parent                         string
	googlecloudapigeev1apicategory *GoogleCloudApigeeV1ApiCategory
	urlParams_                     gensupport.URLParams
	ctx_                           context.Context
	header_                        http.Header
}

// Create: Creates a new API category.
//
//   - parent: Name of the portal. Use the following structure in your
//     request: `organizations/{org}/sites/{site}`.
func (r *OrganizationsSitesApicategoriesService) Create(parent string, googlecloudapigeev1apicategory *GoogleCloudApigeeV1ApiCategory) *OrganizationsSitesApicategoriesCreateCall {
	c := &OrganizationsSitesApicategoriesCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1apicategory = googlecloudapigeev1apicategory
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSitesApicategoriesCreateCall) Fields(s ...googleapi.Field) *OrganizationsSitesApicategoriesCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSitesApicategoriesCreateCall) Context(ctx context.Context) *OrganizationsSitesApicategoriesCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSitesApicategoriesCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSitesApicategoriesCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1apicategory)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/apicategories")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sites.apicategories.create" call.
// Exactly one of *GoogleCloudApigeeV1ApiCategoryResponse or error will
// be non-nil. Any non-2xx status code is an error. Response headers are
// in either
// *GoogleCloudApigeeV1ApiCategoryResponse.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsSitesApicategoriesCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiCategoryResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiCategoryResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a new API category.",
	//   "flatPath": "v1/organizations/{organizationsId}/sites/{sitesId}/apicategories",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.sites.apicategories.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the portal. Use the following structure in your request: `organizations/{org}/sites/{site}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sites/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/apicategories",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1ApiCategory"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiCategoryResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sites.apicategories.delete":

type OrganizationsSitesApicategoriesDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes an API category.
//
//   - name: Name of the category. Use the following structure in your
//     request:
//     `organizations/{org}/sites/{site}/apicategories/{apicategory}`.
func (r *OrganizationsSitesApicategoriesService) Delete(name string) *OrganizationsSitesApicategoriesDeleteCall {
	c := &OrganizationsSitesApicategoriesDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSitesApicategoriesDeleteCall) Fields(s ...googleapi.Field) *OrganizationsSitesApicategoriesDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSitesApicategoriesDeleteCall) Context(ctx context.Context) *OrganizationsSitesApicategoriesDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSitesApicategoriesDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSitesApicategoriesDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sites.apicategories.delete" call.
// Exactly one of *GoogleCloudApigeeV1DeleteResponse or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DeleteResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSitesApicategoriesDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeleteResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeleteResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes an API category.",
	//   "flatPath": "v1/organizations/{organizationsId}/sites/{sitesId}/apicategories/{apicategoriesId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.sites.apicategories.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the category. Use the following structure in your request: `organizations/{org}/sites/{site}/apicategories/{apicategory}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sites/[^/]+/apicategories/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeleteResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sites.apicategories.get":

type OrganizationsSitesApicategoriesGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets an API category.
//
//   - name: Name of the category. Use the following structure in your
//     request:
//     `organizations/{org}/sites/{site}/apicategories/{apicategory}`.
func (r *OrganizationsSitesApicategoriesService) Get(name string) *OrganizationsSitesApicategoriesGetCall {
	c := &OrganizationsSitesApicategoriesGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSitesApicategoriesGetCall) Fields(s ...googleapi.Field) *OrganizationsSitesApicategoriesGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsSitesApicategoriesGetCall) IfNoneMatch(entityTag string) *OrganizationsSitesApicategoriesGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSitesApicategoriesGetCall) Context(ctx context.Context) *OrganizationsSitesApicategoriesGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSitesApicategoriesGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSitesApicategoriesGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sites.apicategories.get" call.
// Exactly one of *GoogleCloudApigeeV1ApiCategoryResponse or error will
// be non-nil. Any non-2xx status code is an error. Response headers are
// in either
// *GoogleCloudApigeeV1ApiCategoryResponse.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsSitesApicategoriesGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiCategoryResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiCategoryResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets an API category.",
	//   "flatPath": "v1/organizations/{organizationsId}/sites/{sitesId}/apicategories/{apicategoriesId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.sites.apicategories.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the category. Use the following structure in your request: `organizations/{org}/sites/{site}/apicategories/{apicategory}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sites/[^/]+/apicategories/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiCategoryResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sites.apicategories.list":

type OrganizationsSitesApicategoriesListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Returns the API categories associated with a portal.
//
//   - parent: Name of the portal. Use the following structure in your
//     request: `organizations/{org}/sites/{site}`.
func (r *OrganizationsSitesApicategoriesService) List(parent string) *OrganizationsSitesApicategoriesListCall {
	c := &OrganizationsSitesApicategoriesListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSitesApicategoriesListCall) Fields(s ...googleapi.Field) *OrganizationsSitesApicategoriesListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsSitesApicategoriesListCall) IfNoneMatch(entityTag string) *OrganizationsSitesApicategoriesListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSitesApicategoriesListCall) Context(ctx context.Context) *OrganizationsSitesApicategoriesListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSitesApicategoriesListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSitesApicategoriesListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/apicategories")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sites.apicategories.list" call.
// Exactly one of *GoogleCloudApigeeV1ListApiCategoriesResponse or error
// will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ListApiCategoriesResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSitesApicategoriesListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListApiCategoriesResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListApiCategoriesResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Returns the API categories associated with a portal.",
	//   "flatPath": "v1/organizations/{organizationsId}/sites/{sitesId}/apicategories",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.sites.apicategories.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the portal. Use the following structure in your request: `organizations/{org}/sites/{site}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sites/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/apicategories",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListApiCategoriesResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sites.apicategories.patch":

type OrganizationsSitesApicategoriesPatchCall struct {
	s                              *Service
	name                           string
	googlecloudapigeev1apicategory *GoogleCloudApigeeV1ApiCategory
	urlParams_                     gensupport.URLParams
	ctx_                           context.Context
	header_                        http.Header
}

// Patch: Updates an API category.
//
//   - name: Name of the category. Use the following structure in your
//     request:
//     `organizations/{org}/sites/{site}/apicategories/{apicategory}`.
func (r *OrganizationsSitesApicategoriesService) Patch(name string, googlecloudapigeev1apicategory *GoogleCloudApigeeV1ApiCategory) *OrganizationsSitesApicategoriesPatchCall {
	c := &OrganizationsSitesApicategoriesPatchCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1apicategory = googlecloudapigeev1apicategory
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSitesApicategoriesPatchCall) Fields(s ...googleapi.Field) *OrganizationsSitesApicategoriesPatchCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSitesApicategoriesPatchCall) Context(ctx context.Context) *OrganizationsSitesApicategoriesPatchCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSitesApicategoriesPatchCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSitesApicategoriesPatchCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1apicategory)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PATCH", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sites.apicategories.patch" call.
// Exactly one of *GoogleCloudApigeeV1ApiCategoryResponse or error will
// be non-nil. Any non-2xx status code is an error. Response headers are
// in either
// *GoogleCloudApigeeV1ApiCategoryResponse.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsSitesApicategoriesPatchCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiCategoryResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiCategoryResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates an API category.",
	//   "flatPath": "v1/organizations/{organizationsId}/sites/{sitesId}/apicategories/{apicategoriesId}",
	//   "httpMethod": "PATCH",
	//   "id": "apigee.organizations.sites.apicategories.patch",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the category. Use the following structure in your request: `organizations/{org}/sites/{site}/apicategories/{apicategory}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sites/[^/]+/apicategories/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1ApiCategory"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiCategoryResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sites.apidocs.create":

type OrganizationsSitesApidocsCreateCall struct {
	s                         *Service
	parent                    string
	googlecloudapigeev1apidoc *GoogleCloudApigeeV1ApiDoc
	urlParams_                gensupport.URLParams
	ctx_                      context.Context
	header_                   http.Header
}

// Create: Creates a new catalog item.
//
//   - parent: Name of the portal. Use the following structure in your
//     request: `organizations/{org}/sites/{site}`.
func (r *OrganizationsSitesApidocsService) Create(parent string, googlecloudapigeev1apidoc *GoogleCloudApigeeV1ApiDoc) *OrganizationsSitesApidocsCreateCall {
	c := &OrganizationsSitesApidocsCreateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	c.googlecloudapigeev1apidoc = googlecloudapigeev1apidoc
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSitesApidocsCreateCall) Fields(s ...googleapi.Field) *OrganizationsSitesApidocsCreateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSitesApidocsCreateCall) Context(ctx context.Context) *OrganizationsSitesApidocsCreateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSitesApidocsCreateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSitesApidocsCreateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1apidoc)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/apidocs")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sites.apidocs.create" call.
// Exactly one of *GoogleCloudApigeeV1ApiDocResponse or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1ApiDocResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSitesApidocsCreateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiDocResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiDocResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Creates a new catalog item.",
	//   "flatPath": "v1/organizations/{organizationsId}/sites/{sitesId}/apidocs",
	//   "httpMethod": "POST",
	//   "id": "apigee.organizations.sites.apidocs.create",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "parent": {
	//       "description": "Required. Name of the portal. Use the following structure in your request: `organizations/{org}/sites/{site}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sites/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/apidocs",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1ApiDoc"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiDocResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sites.apidocs.delete":

type OrganizationsSitesApidocsDeleteCall struct {
	s          *Service
	name       string
	urlParams_ gensupport.URLParams
	ctx_       context.Context
	header_    http.Header
}

// Delete: Deletes a catalog item.
//
//   - name: Name of the catalog item. Use the following structure in your
//     request: `organizations/{org}/sites/{site}/apidocs/{apidoc}`.
func (r *OrganizationsSitesApidocsService) Delete(name string) *OrganizationsSitesApidocsDeleteCall {
	c := &OrganizationsSitesApidocsDeleteCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSitesApidocsDeleteCall) Fields(s ...googleapi.Field) *OrganizationsSitesApidocsDeleteCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSitesApidocsDeleteCall) Context(ctx context.Context) *OrganizationsSitesApidocsDeleteCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSitesApidocsDeleteCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSitesApidocsDeleteCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("DELETE", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sites.apidocs.delete" call.
// Exactly one of *GoogleCloudApigeeV1DeleteResponse or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1DeleteResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSitesApidocsDeleteCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1DeleteResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1DeleteResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Deletes a catalog item.",
	//   "flatPath": "v1/organizations/{organizationsId}/sites/{sitesId}/apidocs/{apidocsId}",
	//   "httpMethod": "DELETE",
	//   "id": "apigee.organizations.sites.apidocs.delete",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the catalog item. Use the following structure in your request: `organizations/{org}/sites/{site}/apidocs/{apidoc}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sites/[^/]+/apidocs/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1DeleteResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sites.apidocs.get":

type OrganizationsSitesApidocsGetCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// Get: Gets a catalog item.
//
//   - name: Name of the catalog item. Use the following structure in your
//     request: `organizations/{org}/sites/{site}/apidocs/{apidoc}`.
func (r *OrganizationsSitesApidocsService) Get(name string) *OrganizationsSitesApidocsGetCall {
	c := &OrganizationsSitesApidocsGetCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSitesApidocsGetCall) Fields(s ...googleapi.Field) *OrganizationsSitesApidocsGetCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsSitesApidocsGetCall) IfNoneMatch(entityTag string) *OrganizationsSitesApidocsGetCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSitesApidocsGetCall) Context(ctx context.Context) *OrganizationsSitesApidocsGetCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSitesApidocsGetCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSitesApidocsGetCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sites.apidocs.get" call.
// Exactly one of *GoogleCloudApigeeV1ApiDocResponse or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1ApiDocResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSitesApidocsGetCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiDocResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiDocResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets a catalog item.",
	//   "flatPath": "v1/organizations/{organizationsId}/sites/{sitesId}/apidocs/{apidocsId}",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.sites.apidocs.get",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the catalog item. Use the following structure in your request: `organizations/{org}/sites/{site}/apidocs/{apidoc}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sites/[^/]+/apidocs/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiDocResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sites.apidocs.getDocumentation":

type OrganizationsSitesApidocsGetDocumentationCall struct {
	s            *Service
	name         string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// GetDocumentation: Gets the documentation for the specified catalog
// item.
//
//   - name: Resource name of the catalog item documentation. Use the
//     following structure in your request:
//     `organizations/{org}/sites/{site}/apidocs/{apidoc}/documentation`.
func (r *OrganizationsSitesApidocsService) GetDocumentation(name string) *OrganizationsSitesApidocsGetDocumentationCall {
	c := &OrganizationsSitesApidocsGetDocumentationCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSitesApidocsGetDocumentationCall) Fields(s ...googleapi.Field) *OrganizationsSitesApidocsGetDocumentationCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsSitesApidocsGetDocumentationCall) IfNoneMatch(entityTag string) *OrganizationsSitesApidocsGetDocumentationCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSitesApidocsGetDocumentationCall) Context(ctx context.Context) *OrganizationsSitesApidocsGetDocumentationCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSitesApidocsGetDocumentationCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSitesApidocsGetDocumentationCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sites.apidocs.getDocumentation" call.
// Exactly one of *GoogleCloudApigeeV1ApiDocDocumentationResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ApiDocDocumentationResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSitesApidocsGetDocumentationCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiDocDocumentationResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiDocDocumentationResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Gets the documentation for the specified catalog item.",
	//   "flatPath": "v1/organizations/{organizationsId}/sites/{sitesId}/apidocs/{apidocsId}/documentation",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.sites.apidocs.getDocumentation",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Resource name of the catalog item documentation. Use the following structure in your request: `organizations/{org}/sites/{site}/apidocs/{apidoc}/documentation`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sites/[^/]+/apidocs/[^/]+/documentation$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiDocDocumentationResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sites.apidocs.list":

type OrganizationsSitesApidocsListCall struct {
	s            *Service
	parent       string
	urlParams_   gensupport.URLParams
	ifNoneMatch_ string
	ctx_         context.Context
	header_      http.Header
}

// List: Returns the catalog items associated with a portal.
//
//   - parent: Name of the portal. Use the following structure in your
//     request: `organizations/{org}/sites/{site}`.
func (r *OrganizationsSitesApidocsService) List(parent string) *OrganizationsSitesApidocsListCall {
	c := &OrganizationsSitesApidocsListCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.parent = parent
	return c
}

// PageSize sets the optional parameter "pageSize": The maximum number
// of items to return. The service may return fewer than this value. If
// unspecified, at most 25 books will be returned. The maximum value is
// 100; values above 100 will be coerced to 100.
func (c *OrganizationsSitesApidocsListCall) PageSize(pageSize int64) *OrganizationsSitesApidocsListCall {
	c.urlParams_.Set("pageSize", fmt.Sprint(pageSize))
	return c
}

// PageToken sets the optional parameter "pageToken": A page token,
// received from a previous `ListApiDocs` call. Provide this to retrieve
// the subsequent page.
func (c *OrganizationsSitesApidocsListCall) PageToken(pageToken string) *OrganizationsSitesApidocsListCall {
	c.urlParams_.Set("pageToken", pageToken)
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSitesApidocsListCall) Fields(s ...googleapi.Field) *OrganizationsSitesApidocsListCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// IfNoneMatch sets the optional parameter which makes the operation
// fail if the object's ETag matches the given value. This is useful for
// getting updates only after the object has changed since the last
// request. Use googleapi.IsNotModified to check whether the response
// error from Do is the result of In-None-Match.
func (c *OrganizationsSitesApidocsListCall) IfNoneMatch(entityTag string) *OrganizationsSitesApidocsListCall {
	c.ifNoneMatch_ = entityTag
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSitesApidocsListCall) Context(ctx context.Context) *OrganizationsSitesApidocsListCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSitesApidocsListCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSitesApidocsListCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	if c.ifNoneMatch_ != "" {
		reqHeaders.Set("If-None-Match", c.ifNoneMatch_)
	}
	var body io.Reader = nil
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+parent}/apidocs")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("GET", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"parent": c.parent,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sites.apidocs.list" call.
// Exactly one of *GoogleCloudApigeeV1ListApiDocsResponse or error will
// be non-nil. Any non-2xx status code is an error. Response headers are
// in either
// *GoogleCloudApigeeV1ListApiDocsResponse.ServerResponse.Header or (if
// a response was returned at all) in error.(*googleapi.Error).Header.
// Use googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *OrganizationsSitesApidocsListCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ListApiDocsResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ListApiDocsResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Returns the catalog items associated with a portal.",
	//   "flatPath": "v1/organizations/{organizationsId}/sites/{sitesId}/apidocs",
	//   "httpMethod": "GET",
	//   "id": "apigee.organizations.sites.apidocs.list",
	//   "parameterOrder": [
	//     "parent"
	//   ],
	//   "parameters": {
	//     "pageSize": {
	//       "description": "Optional. The maximum number of items to return. The service may return fewer than this value. If unspecified, at most 25 books will be returned. The maximum value is 100; values above 100 will be coerced to 100.",
	//       "format": "int32",
	//       "location": "query",
	//       "type": "integer"
	//     },
	//     "pageToken": {
	//       "description": "Optional. A page token, received from a previous `ListApiDocs` call. Provide this to retrieve the subsequent page.",
	//       "location": "query",
	//       "type": "string"
	//     },
	//     "parent": {
	//       "description": "Required. Name of the portal. Use the following structure in your request: `organizations/{org}/sites/{site}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sites/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+parent}/apidocs",
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ListApiDocsResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// Pages invokes f for each page of results.
// A non-nil error returned from f will halt the iteration.
// The provided context supersedes any context provided to the Context method.
func (c *OrganizationsSitesApidocsListCall) Pages(ctx context.Context, f func(*GoogleCloudApigeeV1ListApiDocsResponse) error) error {
	c.ctx_ = ctx
	defer c.PageToken(c.urlParams_.Get("pageToken")) // reset paging to original point
	for {
		x, err := c.Do()
		if err != nil {
			return err
		}
		if err := f(x); err != nil {
			return err
		}
		if x.NextPageToken == "" {
			return nil
		}
		c.PageToken(x.NextPageToken)
	}
}

// method id "apigee.organizations.sites.apidocs.update":

type OrganizationsSitesApidocsUpdateCall struct {
	s                         *Service
	name                      string
	googlecloudapigeev1apidoc *GoogleCloudApigeeV1ApiDoc
	urlParams_                gensupport.URLParams
	ctx_                      context.Context
	header_                   http.Header
}

// Update: Updates a catalog item.
//
//   - name: Name of the catalog item. Use the following structure in your
//     request: `organizations/{org}/sites/{site}/apidocs/{apidoc}`.
func (r *OrganizationsSitesApidocsService) Update(name string, googlecloudapigeev1apidoc *GoogleCloudApigeeV1ApiDoc) *OrganizationsSitesApidocsUpdateCall {
	c := &OrganizationsSitesApidocsUpdateCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1apidoc = googlecloudapigeev1apidoc
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSitesApidocsUpdateCall) Fields(s ...googleapi.Field) *OrganizationsSitesApidocsUpdateCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSitesApidocsUpdateCall) Context(ctx context.Context) *OrganizationsSitesApidocsUpdateCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSitesApidocsUpdateCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSitesApidocsUpdateCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1apidoc)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PUT", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sites.apidocs.update" call.
// Exactly one of *GoogleCloudApigeeV1ApiDocResponse or error will be
// non-nil. Any non-2xx status code is an error. Response headers are in
// either *GoogleCloudApigeeV1ApiDocResponse.ServerResponse.Header or
// (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSitesApidocsUpdateCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiDocResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiDocResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates a catalog item.",
	//   "flatPath": "v1/organizations/{organizationsId}/sites/{sitesId}/apidocs/{apidocsId}",
	//   "httpMethod": "PUT",
	//   "id": "apigee.organizations.sites.apidocs.update",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Name of the catalog item. Use the following structure in your request: `organizations/{org}/sites/{site}/apidocs/{apidoc}`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sites/[^/]+/apidocs/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1ApiDoc"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiDocResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.organizations.sites.apidocs.updateDocumentation":

type OrganizationsSitesApidocsUpdateDocumentationCall struct {
	s                                      *Service
	name                                   string
	googlecloudapigeev1apidocdocumentation *GoogleCloudApigeeV1ApiDocDocumentation
	urlParams_                             gensupport.URLParams
	ctx_                                   context.Context
	header_                                http.Header
}

// UpdateDocumentation: Updates the documentation for the specified
// catalog item. Note that the documentation file contents will not be
// populated in the return message.
//
//   - name: Resource name of the catalog item documentation. Use the
//     following structure in your request:
//     `organizations/{org}/sites/{site}/apidocs/{apidoc}/documentation`.
func (r *OrganizationsSitesApidocsService) UpdateDocumentation(name string, googlecloudapigeev1apidocdocumentation *GoogleCloudApigeeV1ApiDocDocumentation) *OrganizationsSitesApidocsUpdateDocumentationCall {
	c := &OrganizationsSitesApidocsUpdateDocumentationCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.name = name
	c.googlecloudapigeev1apidocdocumentation = googlecloudapigeev1apidocdocumentation
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *OrganizationsSitesApidocsUpdateDocumentationCall) Fields(s ...googleapi.Field) *OrganizationsSitesApidocsUpdateDocumentationCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *OrganizationsSitesApidocsUpdateDocumentationCall) Context(ctx context.Context) *OrganizationsSitesApidocsUpdateDocumentationCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *OrganizationsSitesApidocsUpdateDocumentationCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *OrganizationsSitesApidocsUpdateDocumentationCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1apidocdocumentation)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+name}")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("PATCH", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"name": c.name,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.organizations.sites.apidocs.updateDocumentation" call.
// Exactly one of *GoogleCloudApigeeV1ApiDocDocumentationResponse or
// error will be non-nil. Any non-2xx status code is an error. Response
// headers are in either
// *GoogleCloudApigeeV1ApiDocDocumentationResponse.ServerResponse.Header
// or (if a response was returned at all) in
// error.(*googleapi.Error).Header. Use googleapi.IsNotModified to check
// whether the returned error was because http.StatusNotModified was
// returned.
func (c *OrganizationsSitesApidocsUpdateDocumentationCall) Do(opts ...googleapi.CallOption) (*GoogleCloudApigeeV1ApiDocDocumentationResponse, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleCloudApigeeV1ApiDocDocumentationResponse{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Updates the documentation for the specified catalog item. Note that the documentation file contents will not be populated in the return message.",
	//   "flatPath": "v1/organizations/{organizationsId}/sites/{sitesId}/apidocs/{apidocsId}/documentation",
	//   "httpMethod": "PATCH",
	//   "id": "apigee.organizations.sites.apidocs.updateDocumentation",
	//   "parameterOrder": [
	//     "name"
	//   ],
	//   "parameters": {
	//     "name": {
	//       "description": "Required. Resource name of the catalog item documentation. Use the following structure in your request: `organizations/{org}/sites/{site}/apidocs/{apidoc}/documentation`",
	//       "location": "path",
	//       "pattern": "^organizations/[^/]+/sites/[^/]+/apidocs/[^/]+/documentation$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+name}",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1ApiDocDocumentation"
	//   },
	//   "response": {
	//     "$ref": "GoogleCloudApigeeV1ApiDocDocumentationResponse"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}

// method id "apigee.projects.provisionOrganization":

type ProjectsProvisionOrganizationCall struct {
	s                                               *Service
	project                                         string
	googlecloudapigeev1provisionorganizationrequest *GoogleCloudApigeeV1ProvisionOrganizationRequest
	urlParams_                                      gensupport.URLParams
	ctx_                                            context.Context
	header_                                         http.Header
}

// ProvisionOrganization: Provisions a new Apigee organization with a
// functioning runtime. This is the standard way to create trial
// organizations for a free Apigee trial.
//
//   - project: Name of the GCP project with which to associate the Apigee
//     organization.
func (r *ProjectsService) ProvisionOrganization(project string, googlecloudapigeev1provisionorganizationrequest *GoogleCloudApigeeV1ProvisionOrganizationRequest) *ProjectsProvisionOrganizationCall {
	c := &ProjectsProvisionOrganizationCall{s: r.s, urlParams_: make(gensupport.URLParams)}
	c.project = project
	c.googlecloudapigeev1provisionorganizationrequest = googlecloudapigeev1provisionorganizationrequest
	return c
}

// Fields allows partial responses to be retrieved. See
// https://developers.google.com/gdata/docs/2.0/basics#PartialResponse
// for more information.
func (c *ProjectsProvisionOrganizationCall) Fields(s ...googleapi.Field) *ProjectsProvisionOrganizationCall {
	c.urlParams_.Set("fields", googleapi.CombineFields(s))
	return c
}

// Context sets the context to be used in this call's Do method. Any
// pending HTTP request will be aborted if the provided context is
// canceled.
func (c *ProjectsProvisionOrganizationCall) Context(ctx context.Context) *ProjectsProvisionOrganizationCall {
	c.ctx_ = ctx
	return c
}

// Header returns an http.Header that can be modified by the caller to
// add HTTP headers to the request.
func (c *ProjectsProvisionOrganizationCall) Header() http.Header {
	if c.header_ == nil {
		c.header_ = make(http.Header)
	}
	return c.header_
}

func (c *ProjectsProvisionOrganizationCall) doRequest(alt string) (*http.Response, error) {
	reqHeaders := make(http.Header)
	reqHeaders.Set("x-goog-api-client", "gl-go/"+gensupport.GoVersion()+" gdcl/"+internal.Version)
	for k, v := range c.header_ {
		reqHeaders[k] = v
	}
	reqHeaders.Set("User-Agent", c.s.userAgent())
	var body io.Reader = nil
	body, err := googleapi.WithoutDataWrapper.JSONReader(c.googlecloudapigeev1provisionorganizationrequest)
	if err != nil {
		return nil, err
	}
	reqHeaders.Set("Content-Type", "application/json")
	c.urlParams_.Set("alt", alt)
	c.urlParams_.Set("prettyPrint", "false")
	urls := googleapi.ResolveRelative(c.s.BasePath, "v1/{+project}:provisionOrganization")
	urls += "?" + c.urlParams_.Encode()
	req, err := http.NewRequest("POST", urls, body)
	if err != nil {
		return nil, err
	}
	req.Header = reqHeaders
	googleapi.Expand(req.URL, map[string]string{
		"project": c.project,
	})
	return gensupport.SendRequest(c.ctx_, c.s.client, req)
}

// Do executes the "apigee.projects.provisionOrganization" call.
// Exactly one of *GoogleLongrunningOperation or error will be non-nil.
// Any non-2xx status code is an error. Response headers are in either
// *GoogleLongrunningOperation.ServerResponse.Header or (if a response
// was returned at all) in error.(*googleapi.Error).Header. Use
// googleapi.IsNotModified to check whether the returned error was
// because http.StatusNotModified was returned.
func (c *ProjectsProvisionOrganizationCall) Do(opts ...googleapi.CallOption) (*GoogleLongrunningOperation, error) {
	gensupport.SetOptions(c.urlParams_, opts...)
	res, err := c.doRequest("json")
	if res != nil && res.StatusCode == http.StatusNotModified {
		if res.Body != nil {
			res.Body.Close()
		}
		return nil, gensupport.WrapError(&googleapi.Error{
			Code:   res.StatusCode,
			Header: res.Header,
		})
	}
	if err != nil {
		return nil, err
	}
	defer googleapi.CloseBody(res)
	if err := googleapi.CheckResponse(res); err != nil {
		return nil, gensupport.WrapError(err)
	}
	ret := &GoogleLongrunningOperation{
		ServerResponse: googleapi.ServerResponse{
			Header:         res.Header,
			HTTPStatusCode: res.StatusCode,
		},
	}
	target := &ret
	if err := gensupport.DecodeResponse(target, res); err != nil {
		return nil, err
	}
	return ret, nil
	// {
	//   "description": "Provisions a new Apigee organization with a functioning runtime. This is the standard way to create trial organizations for a free Apigee trial.",
	//   "flatPath": "v1/projects/{projectsId}:provisionOrganization",
	//   "httpMethod": "POST",
	//   "id": "apigee.projects.provisionOrganization",
	//   "parameterOrder": [
	//     "project"
	//   ],
	//   "parameters": {
	//     "project": {
	//       "description": "Required. Name of the GCP project with which to associate the Apigee organization.",
	//       "location": "path",
	//       "pattern": "^projects/[^/]+$",
	//       "required": true,
	//       "type": "string"
	//     }
	//   },
	//   "path": "v1/{+project}:provisionOrganization",
	//   "request": {
	//     "$ref": "GoogleCloudApigeeV1ProvisionOrganizationRequest"
	//   },
	//   "response": {
	//     "$ref": "GoogleLongrunningOperation"
	//   },
	//   "scopes": [
	//     "https://www.googleapis.com/auth/cloud-platform"
	//   ]
	// }

}
