Class: Stagehand::Models::ModelConfig::VertexModelConfigObject::Auth

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/stagehand/models/model_config.rb,
sig/stagehand/models/model_config.rbs

Overview

See Also:

  • Stagehand::Models::ModelConfig::VertexModelConfigObject#auth

Defined Under Namespace

Modules: Scopes Classes: Credentials

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Internal::Type::BaseModel

==, #==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, inspect, #inspect, known_fields, optional, recursively_to_h, required, #to_h, #to_json, #to_s, to_sorbet_type, #to_yaml

Methods included from Internal::Type::Converter

#coerce, coerce, #dump, dump, inspect, #inspect, meta_info, new_coerce_state, type_info

Methods included from Internal::Util::SorbetRuntimeSupport

#const_missing, #define_sorbet_constant!, #sorbet_constant_defined?, #to_sorbet_type, to_sorbet_type

Constructor Details

#initialize(credentials:, project_id: nil, scopes: nil, universe_domain: nil, type: :googleServiceAccount) ⇒ Object

Vertex provider authentication configuration

Parameters:

  • credentials (Stagehand::Models::ModelConfig::VertexModelConfigObject::Auth::Credentials) —

    Google Cloud service account credentials

  • project_id (String) (defaults to: nil) —

    Google Cloud project ID used by google-auth-library

  • scopes (String, Array<String>) (defaults to: nil) —

    Google auth scopes for the desired API request

  • universe_domain (String) (defaults to: nil) —

    Google Cloud universe domain

  • type (Symbol, :googleServiceAccount) (defaults to: :googleServiceAccount) —

    Use inline Google Cloud service account credentials for provider authentication



# File 'lib/stagehand/models/model_config.rb', line 104

Instance Attribute Details

#credentials ⇒ Stagehand::Models::ModelConfig::VertexModelConfigObject::Auth::Credentials

Google Cloud service account credentials

Parameters:

  • value (Stagehand::ModelConfig::VertexModelConfigObject::Auth::Credentials)

Returns:



78
# File 'lib/stagehand/models/model_config.rb', line 78

required :credentials, -> { Stagehand::ModelConfig::VertexModelConfigObject::Auth::Credentials }

#project_id ⇒ String?

Google Cloud project ID used by google-auth-library

Parameters:

  • (String)

Returns:

  • (String, nil)


90
# File 'lib/stagehand/models/model_config.rb', line 90

optional :project_id, String, api_name: :projectId

#scopes ⇒ String, ...

Google auth scopes for the desired API request

Returns:

  • (String, Array<String>, nil)


96
# File 'lib/stagehand/models/model_config.rb', line 96

optional :scopes, union: -> { Stagehand::ModelConfig::VertexModelConfigObject::Auth::Scopes }

#type ⇒ Symbol, :googleServiceAccount

Use inline Google Cloud service account credentials for provider authentication

Parameters:

  • value (:googleServiceAccount)

Returns:

  • (Symbol, :googleServiceAccount)


84
# File 'lib/stagehand/models/model_config.rb', line 84

required :type, const: :googleServiceAccount

#universe_domain ⇒ String?

Google Cloud universe domain

Parameters:

  • (String)

Returns:

  • (String, nil)


102
# File 'lib/stagehand/models/model_config.rb', line 102

optional :universe_domain, String, api_name: :universeDomain

Class Method Details

.values ⇒ Array<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/stagehand/models/model_config.rb', line 195

Instance Method Details

#to_hash ⇒ {

Returns:

  • ({)


98
# File 'sig/stagehand/models/model_config.rbs', line 98

def to_hash: -> {