Packages
google_api_container
0.0.1
0.57.0
0.56.0
0.55.1
0.55.0
0.54.0
0.53.0
0.52.0
0.51.0
0.50.0
0.49.0
0.48.0
0.47.0
0.46.1
0.46.0
0.45.0
0.44.0
0.43.0
0.42.1
0.42.0
0.41.0
0.40.0
0.39.1
0.39.0
0.38.0
0.37.0
0.36.0
0.35.0
0.34.0
0.33.0
0.32.3
0.32.2
0.32.1
0.32.0
0.31.0
0.30.0
0.29.0
0.28.0
0.27.0
0.26.0
0.25.1
0.25.0
0.24.0
0.23.0
0.22.0
0.21.1
0.21.0
0.20.0
0.19.0
0.18.1
0.18.0
0.17.0
0.16.0
0.15.0
0.14.0
0.13.0
0.12.3
0.12.2
0.12.1
0.12.0
0.11.0
0.10.0
0.9.0
0.8.0
0.7.0
0.6.0
0.5.0
0.2.0
0.1.0
0.0.1
Kubernetes Engine API client library. Builds and manages container-based applications, powered by the open source Kubernetes technology.
Current section
Files
Jump to
Current section
Files
lib/google_api/container/v1/api/projects.ex
# Copyright 2017 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
# NOTE: This class is auto generated by the swagger code generator program.
# https://github.com/swagger-api/swagger-codegen.git
# Do not edit the class manually.
defmodule GoogleApi.Container.V1.Api.Projects do
@moduledoc """
API calls for all endpoints tagged `Projects`.
"""
alias GoogleApi.Container.V1.Connection
import GoogleApi.Container.V1.RequestBuilder
@doc """
Sets the addons of a specific cluster.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster to upgrade.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (SetAddonsConfigRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_addons(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_addons(connection, project_id, zone, cluster_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/addons", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Completes master IP rotation.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://developers.google.com/console/help/new/#projectnumber).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (CompleteIpRotationRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_complete_ip_rotation(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_complete_ip_rotation(connection, project_id, zone, cluster_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:completeIpRotation", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Creates a cluster, consisting of the specified number and type of Google Compute Engine instances. By default, the cluster is created in the project's [default network](/compute/docs/networks-and-firewalls#networks). One firewall is added for the cluster. After cluster creation, the cluster creates routes for each node to allow the containers on that node to communicate with all other instances in the cluster. Finally, an entry is added to the project's global metadata indicating which CIDR range is being used by the cluster.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (CreateClusterRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_create(Tesla.Env.client, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_create(connection, project_id, zone, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Deletes the cluster, including the Kubernetes endpoint and all worker nodes. Firewalls and routes that were configured during cluster creation are also deleted. Other Google Compute Engine resources that might be in use by the cluster (e.g. load balancer resources) will not be deleted if they weren't present at the initial create time.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster to delete.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_delete(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_delete(connection, project_id, zone, cluster_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query
}
%{}
|> method(:delete)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Gets the details of a specific cluster.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster to retrieve.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
## Returns
{:ok, %GoogleApi.Container.V1.Model.Cluster{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_get(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Cluster.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_get(connection, project_id, zone, cluster_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query
}
%{}
|> method(:get)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Cluster{})
end
@doc """
Enables or disables the ABAC authorization mechanism on a cluster.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster to update.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (SetLegacyAbacRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_legacy_abac(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_legacy_abac(connection, project_id, zone, cluster_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/legacyAbac", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Lists all clusters owned by a project in either the specified zone or all zones.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides, or \"-\" for all zones.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
## Returns
{:ok, %GoogleApi.Container.V1.Model.ListClustersResponse{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_list(Tesla.Env.client, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.ListClustersResponse.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_list(connection, project_id, zone, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query
}
%{}
|> method(:get)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.ListClustersResponse{})
end
@doc """
Sets the locations of a specific cluster.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster to upgrade.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (SetLocationsRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_locations(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_locations(connection, project_id, zone, cluster_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/locations", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Sets the logging service of a specific cluster.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster to upgrade.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (SetLoggingServiceRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_logging(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_logging(connection, project_id, zone, cluster_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/logging", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Updates the master of a specific cluster.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster to upgrade.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (UpdateMasterRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_master(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_master(connection, project_id, zone, cluster_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/master", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Sets the monitoring service of a specific cluster.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster to upgrade.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (SetMonitoringServiceRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_monitoring(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_monitoring(connection, project_id, zone, cluster_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/monitoring", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Sets the autoscaling settings of a specific node pool.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster to upgrade.
- node_pool_id (String): The name of the node pool to upgrade.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (SetNodePoolAutoscalingRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_node_pools_autoscaling(Tesla.Env.client, String.t, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_node_pools_autoscaling(connection, project_id, zone, cluster_id, node_pool_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}/autoscaling", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id),
"nodePoolId" => URI.encode_www_form(node_pool_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Creates a node pool for a cluster.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://developers.google.com/console/help/new/#projectnumber).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (CreateNodePoolRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_node_pools_create(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_node_pools_create(connection, project_id, zone, cluster_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Deletes a node pool from a cluster.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://developers.google.com/console/help/new/#projectnumber).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster.
- node_pool_id (String): The name of the node pool to delete.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_node_pools_delete(Tesla.Env.client, String.t, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_node_pools_delete(connection, project_id, zone, cluster_id, node_pool_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query
}
%{}
|> method(:delete)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id),
"nodePoolId" => URI.encode_www_form(node_pool_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Retrieves the node pool requested.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://developers.google.com/console/help/new/#projectnumber).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster.
- node_pool_id (String): The name of the node pool.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
## Returns
{:ok, %GoogleApi.Container.V1.Model.NodePool{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_node_pools_get(Tesla.Env.client, String.t, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.NodePool.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_node_pools_get(connection, project_id, zone, cluster_id, node_pool_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query
}
%{}
|> method(:get)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id),
"nodePoolId" => URI.encode_www_form(node_pool_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.NodePool{})
end
@doc """
Lists the node pools for a cluster.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://developers.google.com/console/help/new/#projectnumber).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
## Returns
{:ok, %GoogleApi.Container.V1.Model.ListNodePoolsResponse{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_node_pools_list(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.ListNodePoolsResponse.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_node_pools_list(connection, project_id, zone, cluster_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query
}
%{}
|> method(:get)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.ListNodePoolsResponse{})
end
@doc """
Roll back the previously Aborted or Failed NodePool upgrade. This will be an no-op if the last upgrade successfully completed.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster to rollback.
- node_pool_id (String): The name of the node pool to rollback.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (RollbackNodePoolUpgradeRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_node_pools_rollback(Tesla.Env.client, String.t, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_node_pools_rollback(connection, project_id, zone, cluster_id, node_pool_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}:rollback", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id),
"nodePoolId" => URI.encode_www_form(node_pool_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Sets the NodeManagement options for a node pool.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster to update.
- node_pool_id (String): The name of the node pool to update.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (SetNodePoolManagementRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_node_pools_set_management(Tesla.Env.client, String.t, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_node_pools_set_management(connection, project_id, zone, cluster_id, node_pool_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}/setManagement", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id),
"nodePoolId" => URI.encode_www_form(node_pool_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Sets the size of a specific node pool.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster to update.
- node_pool_id (String): The name of the node pool to update.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (SetNodePoolSizeRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_node_pools_set_size(Tesla.Env.client, String.t, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_node_pools_set_size(connection, project_id, zone, cluster_id, node_pool_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}/setSize", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id),
"nodePoolId" => URI.encode_www_form(node_pool_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Updates the version and/or image type of a specific node pool.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster to upgrade.
- node_pool_id (String): The name of the node pool to upgrade.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (UpdateNodePoolRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_node_pools_update(Tesla.Env.client, String.t, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_node_pools_update(connection, project_id, zone, cluster_id, node_pool_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/nodePools/{nodePoolId}/update", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id),
"nodePoolId" => URI.encode_www_form(node_pool_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Sets labels on a cluster.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://developers.google.com/console/help/new/#projectnumber).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (SetLabelsRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_resource_labels(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_resource_labels(connection, project_id, zone, cluster_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}/resourceLabels", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Used to set master auth materials. Currently supports :- Changing the admin password of a specific cluster. This can be either via password generation or explicitly set the password.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster to upgrade.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (SetMasterAuthRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_set_master_auth(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_set_master_auth(connection, project_id, zone, cluster_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:setMasterAuth", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Enables/Disables Network Policy for a cluster.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://developers.google.com/console/help/new/#projectnumber).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (SetNetworkPolicyRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_set_network_policy(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_set_network_policy(connection, project_id, zone, cluster_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:setNetworkPolicy", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Start master IP rotation.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://developers.google.com/console/help/new/#projectnumber).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (StartIpRotationRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_start_ip_rotation(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_start_ip_rotation(connection, project_id, zone, cluster_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}:startIpRotation", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Updates the settings of a specific cluster.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- cluster_id (String): The name of the cluster to upgrade.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (UpdateClusterRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_clusters_update(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_clusters_update(connection, project_id, zone, cluster_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:put)
|> url("/v1/projects/{projectId}/zones/{zone}/clusters/{clusterId}", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"clusterId" => URI.encode_www_form(cluster_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Returns configuration info about the Container Engine service.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) to return operations for.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
## Returns
{:ok, %GoogleApi.Container.V1.Model.ServerConfig{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_get_serverconfig(Tesla.Env.client, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.ServerConfig.t} | {:error, Tesla.Env.t}
def container_projects_zones_get_serverconfig(connection, project_id, zone, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query
}
%{}
|> method(:get)
|> url("/v1/projects/{projectId}/zones/{zone}/serverconfig", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.ServerConfig{})
end
@doc """
Cancels the specified operation.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the operation resides.
- operation_id (String): The server-assigned `name` of the operation.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
- :body (CancelOperationRequest):
## Returns
{:ok, %GoogleApi.Container.V1.Model.Empty{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_operations_cancel(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Empty.t} | {:error, Tesla.Env.t}
def container_projects_zones_operations_cancel(connection, project_id, zone, operation_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query,
:"body" => :body
}
%{}
|> method(:post)
|> url("/v1/projects/{projectId}/zones/{zone}/operations/{operationId}:cancel", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"operationId" => URI.encode_www_form(operation_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Empty{})
end
@doc """
Gets the specified operation.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) in which the cluster resides.
- operation_id (String): The server-assigned `name` of the operation.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
## Returns
{:ok, %GoogleApi.Container.V1.Model.Operation{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_operations_get(Tesla.Env.client, String.t, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.Operation.t} | {:error, Tesla.Env.t}
def container_projects_zones_operations_get(connection, project_id, zone, operation_id, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query
}
%{}
|> method(:get)
|> url("/v1/projects/{projectId}/zones/{zone}/operations/{operationId}", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone),
"operationId" => URI.encode_www_form(operation_id)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.Operation{})
end
@doc """
Lists all operations in a project in a specific zone or all zones.
## Parameters
- connection (GoogleApi.Container.V1.Connection): Connection to server
- project_id (String): The Google Developers Console [project ID or project number](https://support.google.com/cloud/answer/6158840).
- zone (String): The name of the Google Compute Engine [zone](/compute/docs/zones#available) to return operations for, or `-` for all zones.
- opts (KeywordList): [optional] Optional parameters
- :upload_protocol (String): Upload protocol for media (e.g. \"raw\", \"multipart\").
- :pretty_print (Boolean): Returns response with indentations and line breaks.
- :fields (String): Selector specifying which fields to include in a partial response.
- :upload_type (String): Legacy upload protocol for media (e.g. \"media\", \"multipart\").
- :__/xgafv (String): V1 error format.
- :callback (String): JSONP
- :alt (String): Data format for response.
- :key (String): API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
- :access_token (String): OAuth access token.
- :quota_user (String): Available to use for quota purposes for server-side applications. Can be any arbitrary string assigned to a user, but should not exceed 40 characters.
- :pp (Boolean): Pretty-print response.
- :bearer_token (String): OAuth bearer token.
- :oauth_token (String): OAuth 2.0 token for the current user.
## Returns
{:ok, %GoogleApi.Container.V1.Model.ListOperationsResponse{}} on success
{:error, info} on failure
"""
@spec container_projects_zones_operations_list(Tesla.Env.client, String.t, String.t, keyword()) :: {:ok, GoogleApi.Container.V1.Model.ListOperationsResponse.t} | {:error, Tesla.Env.t}
def container_projects_zones_operations_list(connection, project_id, zone, opts \\ []) do
optional_params = %{
:"upload_protocol" => :query,
:"prettyPrint" => :query,
:"fields" => :query,
:"uploadType" => :query,
:"$.xgafv" => :query,
:"callback" => :query,
:"alt" => :query,
:"key" => :query,
:"access_token" => :query,
:"quotaUser" => :query,
:"pp" => :query,
:"bearer_token" => :query,
:"oauth_token" => :query
}
%{}
|> method(:get)
|> url("/v1/projects/{projectId}/zones/{zone}/operations", %{
"projectId" => URI.encode_www_form(project_id),
"zone" => URI.encode_www_form(zone)
})
|> add_optional_params(optional_params, opts)
|> Enum.into([])
|> (&Connection.request(connection, &1)).()
|> decode(%GoogleApi.Container.V1.Model.ListOperationsResponse{})
end
end