Reference documentation and code samples for the Connect Gateway V1beta1 API class Google::Cloud::GkeConnect::Gateway::V1beta1::GatewayControl::Rest::Client.
REST client for the GatewayControl service.
GatewayControl is the control plane API for Connect Gateway.
# Modify the configuration for all GatewayControl clients::Google::Cloud::GkeConnect::Gateway::V1beta1::GatewayControl::Rest::Client.configuredo|config|config.timeout=10.0end
The configuration is set to the derived mode, meaning that values can be changed,
but structural changes (adding new fields, etc.) are not allowed. Structural changes
should be made on Client.configure.
See Configuration
for a description of the configuration fields.
Pass arguments to generate_credentials via keyword arguments. Note that at
least one keyword argument is required. To specify no parameters, or to keep all
the default parameter values, pass an empty Hash as a request object (see above).
Parameters
name (::String) — Required. The Fleet membership resource.
force_use_agent (::Boolean) — Optional. Whether to force the use of Connect Agent-based transport.
This will return a configuration that uses Connect Agent as the underlying
transport mechanism for cluster types that would otherwise have used a
different transport. Requires that Connect Agent be installed on the
cluster. Setting this field to false is equivalent to not setting it.
version (::String) — Optional. The Connect Gateway version to be used in the resulting
configuration.
Leave this field blank to let the server choose the version (recommended).
kubernetes_namespace (::String) — Optional. The namespace to use in the kubeconfig context.
If this field is specified, the server will set the namespace field in
kubeconfig context. If not specified, the namespace field is omitted.
(::Google::Cloud::Error) — if the REST call is aborted.
Example
Basic example
require"google/cloud/gke_connect/gateway/v1beta1"# Create a client object. The client can be reused for multiple calls.client=Google::Cloud::GkeConnect::Gateway::V1beta1::GatewayControl::Rest::Client.new# Create a request. To set request fields, pass in keyword arguments.request=Google::Cloud::GkeConnect::Gateway::V1beta1::GenerateCredentialsRequest.new# Call the generate_credentials method.result=client.generate_credentialsrequest# The returned object is of type Google::Cloud::GkeConnect::Gateway::V1beta1::GenerateCredentialsResponse.presult
# Create a client using the default configurationclient=::Google::Cloud::GkeConnect::Gateway::V1beta1::GatewayControl::Rest::Client.new# Create a client using a custom configurationclient=::Google::Cloud::GkeConnect::Gateway::V1beta1::GatewayControl::Rest::Client.newdo|config|config.timeout=10.0end
#logger
deflogger()->Logger
The logger used for request/response debug logging.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-09-09 UTC."],[],[],null,["# Connect Gateway V1beta1 API - Class Google::Cloud::GkeConnect::Gateway::V1beta1::GatewayControl::Rest::Client (v0.10.0)\n\nVersion latestkeyboard_arrow_down\n\n- [0.10.0 (latest)](/ruby/docs/reference/google-cloud-gke_connect-gateway-v1beta1/latest/Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client)\n- [0.9.1](/ruby/docs/reference/google-cloud-gke_connect-gateway-v1beta1/0.9.1/Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client)\n- [0.8.0](/ruby/docs/reference/google-cloud-gke_connect-gateway-v1beta1/0.8.0/Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client)\n- [0.7.1](/ruby/docs/reference/google-cloud-gke_connect-gateway-v1beta1/0.7.1/Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client)\n- [0.6.0](/ruby/docs/reference/google-cloud-gke_connect-gateway-v1beta1/0.6.0/Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client)\n- [0.5.2](/ruby/docs/reference/google-cloud-gke_connect-gateway-v1beta1/0.5.2/Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client)\n- [0.4.0](/ruby/docs/reference/google-cloud-gke_connect-gateway-v1beta1/0.4.0/Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client)\n- [0.3.0](/ruby/docs/reference/google-cloud-gke_connect-gateway-v1beta1/0.3.0/Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client)\n- [0.2.0](/ruby/docs/reference/google-cloud-gke_connect-gateway-v1beta1/0.2.0/Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client)\n- [0.1.5](/ruby/docs/reference/google-cloud-gke_connect-gateway-v1beta1/0.1.5/Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client) \nReference documentation and code samples for the Connect Gateway V1beta1 API class Google::Cloud::GkeConnect::Gateway::V1beta1::GatewayControl::Rest::Client.\n\nREST client for the GatewayControl service.\n\n\n\u003cbr /\u003e\n\nGatewayControl is the control plane API for Connect Gateway. \n\nInherits\n--------\n\n- Object\n\nMethods\n-------\n\n### .configure\n\n def self.configure() { |config| ... } -\u003e Client::Configuration\n\nConfigure the GatewayControl Client class.\n\n\n\u003cbr /\u003e\n\nSee [Configuration](/ruby/docs/reference/google-cloud-gke_connect-gateway-v1beta1/latest/Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client-Configuration \"Google::Cloud::GkeConnect::Gateway::V1beta1::GatewayControl::Rest::Client::Configuration (class)\")\nfor a description of the configuration fields. \n**Yields**\n\n- (config) --- Configure the Client client. \n**Yield Parameter**\n\n- **config** ([Client::Configuration](./Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client-Configuration)) \n**Returns**\n\n- ([Client::Configuration](./Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client-Configuration))\n**Example** \n\n```ruby\n# Modify the configuration for all GatewayControl clients\n::Google::Cloud::GkeConnect::Gateway::V1beta1::GatewayControl::Rest::Client.configure do |config|\n config.timeout = 10.0\nend\n```\n\n### #configure\n\n def configure() { |config| ... } -\u003e Client::Configuration\n\nConfigure the GatewayControl Client instance.\n\n\nThe configuration is set to the derived mode, meaning that values can be changed,\nbut structural changes (adding new fields, etc.) are not allowed. Structural changes\nshould be made on [Client.configure](/ruby/docs/reference/google-cloud-gke_connect-gateway-v1beta1/latest/Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client#Google__Cloud__GkeConnect__Gateway__V1beta1__GatewayControl__Rest__Client_configure_class_ \"Google::Cloud::GkeConnect::Gateway::V1beta1::GatewayControl::Rest::Client.configure (method)\").\n\n\u003cbr /\u003e\n\nSee [Configuration](/ruby/docs/reference/google-cloud-gke_connect-gateway-v1beta1/latest/Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client-Configuration \"Google::Cloud::GkeConnect::Gateway::V1beta1::GatewayControl::Rest::Client::Configuration (class)\")\nfor a description of the configuration fields. \n**Yields**\n\n- (config) --- Configure the Client client. \n**Yield Parameter**\n\n- **config** ([Client::Configuration](./Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client-Configuration)) \n**Returns**\n\n- ([Client::Configuration](./Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client-Configuration))\n\n### #generate_credentials\n\n def generate_credentials(request, options = nil) -\u003e ::Google::Cloud::GkeConnect::Gateway::V1beta1::GenerateCredentialsResponse\n def generate_credentials(name: nil, force_use_agent: nil, version: nil, kubernetes_namespace: nil, operating_system: nil) -\u003e ::Google::Cloud::GkeConnect::Gateway::V1beta1::GenerateCredentialsResponse\n\nGenerateCredentials provides connection information that allows a user to\naccess the specified membership using Connect Gateway. \n**Overloads** \n\n def generate_credentials(request, options = nil) -\u003e ::Google::Cloud::GkeConnect::Gateway::V1beta1::GenerateCredentialsResponse\n\nPass arguments to `generate_credentials` via a request object, either of type [Google::Cloud::GkeConnect::Gateway::V1beta1::GenerateCredentialsRequest](/ruby/docs/reference/google-cloud-gke_connect-gateway-v1beta1/latest/Google-Cloud-GkeConnect-Gateway-V1beta1-GenerateCredentialsRequest \"Google::Cloud::GkeConnect::Gateway::V1beta1::GenerateCredentialsRequest (class)\") or an equivalent Hash. \n**Parameters**\n\n- **request** ([::Google::Cloud::GkeConnect::Gateway::V1beta1::GenerateCredentialsRequest](./Google-Cloud-GkeConnect-Gateway-V1beta1-GenerateCredentialsRequest), ::Hash) --- A request object representing the call parameters. Required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash.\n- **options** (::Gapic::CallOptions, ::Hash) --- Overrides the default settings for this call, e.g, timeout, retries etc. Optional. \n\n def generate_credentials(name: nil, force_use_agent: nil, version: nil, kubernetes_namespace: nil, operating_system: nil) -\u003e ::Google::Cloud::GkeConnect::Gateway::V1beta1::GenerateCredentialsResponse\n\nPass arguments to `generate_credentials` via keyword arguments. Note that at least one keyword argument is required. To specify no parameters, or to keep all the default parameter values, pass an empty Hash as a request object (see above). \n**Parameters**\n\n- **name** (::String) --- Required. The Fleet membership resource.\n- **force_use_agent** (::Boolean) --- Optional. Whether to force the use of Connect Agent-based transport.\n\n\n This will return a configuration that uses Connect Agent as the underlying\n transport mechanism for cluster types that would otherwise have used a\n different transport. Requires that Connect Agent be installed on the\n cluster. Setting this field to false is equivalent to not setting it.\n- **version** (::String) --- Optional. The Connect Gateway version to be used in the resulting configuration.\n\n\n Leave this field blank to let the server choose the version (recommended).\n- **kubernetes_namespace** (::String) --- Optional. The namespace to use in the kubeconfig context.\n\n\n If this field is specified, the server will set the `namespace` field in\n kubeconfig context. If not specified, the `namespace` field is omitted.\n- **operating_system** ([::Google::Cloud::GkeConnect::Gateway::V1beta1::GenerateCredentialsRequest::OperatingSystem](./Google-Cloud-GkeConnect-Gateway-V1beta1-GenerateCredentialsRequest-OperatingSystem)) --- Optional. The operating system where the kubeconfig will be used. \n**Yields**\n\n- (result, operation) --- Access the result along with the TransportOperation object \n**Yield Parameters**\n\n- **result** ([::Google::Cloud::GkeConnect::Gateway::V1beta1::GenerateCredentialsResponse](./Google-Cloud-GkeConnect-Gateway-V1beta1-GenerateCredentialsResponse))\n- **operation** (::Gapic::Rest::TransportOperation) \n**Returns**\n\n- ([::Google::Cloud::GkeConnect::Gateway::V1beta1::GenerateCredentialsResponse](./Google-Cloud-GkeConnect-Gateway-V1beta1-GenerateCredentialsResponse)) \n**Raises**\n\n- (::Google::Cloud::Error) --- if the REST call is aborted.\n**Example**\n\nBasic example \n\n```ruby\nrequire \"google/cloud/gke_connect/gateway/v1beta1\"\n\n# Create a client object. The client can be reused for multiple calls.\nclient = Google::Cloud::GkeConnect::Gateway::V1beta1::GatewayControl::Rest::Client.new\n\n# Create a request. To set request fields, pass in keyword arguments.\nrequest = Google::Cloud::GkeConnect::Gateway::V1beta1::GenerateCredentialsRequest.new\n\n# Call the generate_credentials method.\nresult = client.generate_credentials request\n\n# The returned object is of type Google::Cloud::GkeConnect::Gateway::V1beta1::GenerateCredentialsResponse.\np result\n```\n\n### #initialize\n\n def initialize() { |config| ... } -\u003e Client\n\nCreate a new GatewayControl REST client object. \n**Yields**\n\n- (config) --- Configure the GatewayControl client. \n**Yield Parameter**\n\n- **config** ([Client::Configuration](./Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client-Configuration)) \n**Returns**\n\n- ([Client](./Google-Cloud-GkeConnect-Gateway-V1beta1-GatewayControl-Rest-Client)) --- a new instance of Client\n**Example** \n\n```ruby\n# Create a client using the default configuration\nclient = ::Google::Cloud::GkeConnect::Gateway::V1beta1::GatewayControl::Rest::Client.new\n\n# Create a client using a custom configuration\nclient = ::Google::Cloud::GkeConnect::Gateway::V1beta1::GatewayControl::Rest::Client.new do |config|\n config.timeout = 10.0\nend\n```\n\n### #logger\n\n def logger() -\u003e Logger\n\nThe logger used for request/response debug logging. \n**Returns**\n\n- (Logger)\n\n### #universe_domain\n\n def universe_domain() -\u003e String\n\nThe effective universe domain \n**Returns**\n\n- (String)"]]