// SetAuthorizationScopes sets the AuthorizationScopes field's value.
968285
func (s *PutMethodInput) SetAuthorizationScopes(v []*string) *PutMethodInput {
	s.AuthorizationScopes = v
	return s
}
407492
func (s *Service) SetAuthorizationStatus(ctx context.Context, id platform.ID, status platform.Status) error {
	op := OpPrefix + platform.OpSetAuthorizationStatus
	a, err := s.FindAuthorizationByID(ctx, id)
	if err != nil {
		return &platform.Error{
			Err: err,
			Op:  op,
		}
	}

	switch status {
	case platform.Active, platform.Inactive:
	default:
		return &platform.Error{
			Code: platform.EInvalid,
			Msg:  "unknown authorization status",
			Op:   op,
		}
	}

	if a.Status == status {
		return nil
	}

	a.Status = status
	return s.PutAuthorization(ctx, a)
}
811272
func (s *ListGroupCertificateAuthoritiesOutput) SetGroupCertificateAuthorities(v []*GroupCertificateAuthorityProperties) *ListGroupCertificateAuthoritiesOutput {
	s.GroupCertificateAuthorities = v
	return s
}
465656
func (s *CreateRouteOutput) SetAuthorizationScopes(v []*string) *CreateRouteOutput {
	s.AuthorizationScopes = v
	return s
}
45773
func (s *AuthorizationService) SetAuthorizationStatus(ctx context.Context, id platform.ID, status platform.Status) (err error) {
	defer func() {
		if err != nil {
			s.Logger.Info("error updating authorization", zap.Error(err))
		}
	}()

	return s.AuthorizationService.SetAuthorizationStatus(ctx, id, status)
}
1356839
func (s *CreateRouteInput) SetAuthorizationScopes(v []*string) *CreateRouteInput {
	s.AuthorizationScopes = v
	return s
}
37966
func (s *HttpDataSourceConfig) SetAuthorizationConfig(v *AuthorizationConfig) *HttpDataSourceConfig {
	s.AuthorizationConfig = v
	return s
}
1134168
func (s *Route) SetAuthorizerId(v string) *Route {
	s.AuthorizerId = &v
	return s
}
711267
func (s *CreateRouteOutput) SetAuthorizationType(v string) *CreateRouteOutput {
	s.AuthorizationType = &v
	return s
}
435967
func SetAuthorizer(ctx context.Context, a platform.Authorizer) context.Context {
	return context.WithValue(ctx, authorizerCtxKey, a)
}
316169
func (s *CreateAuthorizerOutput) SetAuthorizerId(v string) *CreateAuthorizerOutput {
	s.AuthorizerId = &v
	return s
}
222055
func (s *ListWebsiteCertificateAuthoritiesOutput) SetWebsiteCertificateAuthorities(v []*WebsiteCaSummary) *ListWebsiteCertificateAuthoritiesOutput {
	s.WebsiteCertificateAuthorities = v
	return s
}
267910
func (s *AuthorizationService) SetAuthorizationStatus(ctx context.Context, id platform.ID, status platform.Status) error {
	u, err := newURL(s.Addr, authorizationIDPath(id))
	if err != nil {
		return err
	}

	b, err := json.Marshal(setAuthorizationStatusRequest{
		Status: status,
	})
	if err != nil {
		return err
	}

	req, err := http.NewRequest("PATCH", u.String(), bytes.NewReader(b))
	if err != nil {
		return err
	}

	req.Header.Set("Content-Type", "application/json")
	SetToken(s.Token, req)

	hc := newClient(u.Scheme, s.InsecureSkipVerify)

	resp, err := hc.Do(req)
	if err != nil {
		return err
	}

	if err := CheckError(resp, true); err != nil {
		return err
	}

	return nil
}
1038240
func (s *GetRouteOutput) SetAuthorizerId(v string) *GetRouteOutput {
	s.AuthorizerId = &v
	return s
}
560463
func (s *TestInvokeAuthorizerInput) SetAuthorizerId(v string) *TestInvokeAuthorizerInput {
	s.AuthorizerId = &v
	return s
}
1077522
func (s *GetAuthorizerOutput) SetAuthorizerId(v string) *GetAuthorizerOutput {
	s.AuthorizerId = &v
	return s
}
802114
func (s *UpdateRouteInput) SetAuthorizerId(v string) *UpdateRouteInput {
	s.AuthorizerId = &v
	return s
}