Module: Anthropic::Models::Beta::BetaManagedAgentsWebFetchURLSourceUserInput

Extended by:
Internal::Type::Union
Defined in:
lib/anthropic/models/beta/beta_managed_agents_web_fetch_url_source_user_input.rb,
sig/anthropic/models/beta/beta_managed_agents_web_fetch_url_source_user_input.rbs

Overview

Whether URLs in the text of user messages may be fetched.

Defined Under Namespace

Modules: Type

Class Method Summary collapse

Methods included from Internal::Type::Union

==, ===, coerce, derefed_variants, dump, hash, inspect, to_sorbet_type

Methods included from Internal::Util::SorbetRuntimeSupport

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

Methods included from Internal::Type::Converter

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

Class Method Details

.new(type:) ⇒ Anthropic::Beta::BetaManagedAgentsWebFetchURLSourceAll .new(type:) ⇒ Anthropic::Beta::BetaManagedAgentsWebFetchURLSourceNone .new(type:) ⇒ Anthropic::Models::Beta::beta_managed_agents_web_fetch_url_source_user_input

Creates a new instance of the variant class whose type matches the given value, passing the remaining arguments to its constructor.

Overloads:

  • .new(type:) ⇒ Anthropic::Beta::BetaManagedAgentsWebFetchURLSourceAll

    Parameters:

    • type: (:all, "all")

    Returns:

    • (Anthropic::Beta::BetaManagedAgentsWebFetchURLSourceAll)
  • .new(type:) ⇒ Anthropic::Beta::BetaManagedAgentsWebFetchURLSourceNone

    Parameters:

    • type: (:none, "none")

    Returns:

    • (Anthropic::Beta::BetaManagedAgentsWebFetchURLSourceNone)
  • .new(type:) ⇒ Anthropic::Models::Beta::beta_managed_agents_web_fetch_url_source_user_input

    Parameters:

    • type: (Anthropic::Models::Beta::BetaManagedAgentsWebFetchURLSourceUserInput::type_, String)

    Returns:

    • (Anthropic::Models::Beta::beta_managed_agents_web_fetch_url_source_user_input)

Parameters:

Returns:

Raises:

  • (ArgumentError)


40
41
42
43
44
45
46
47
48
49
# File 'lib/anthropic/models/beta/beta_managed_agents_web_fetch_url_source_user_input.rb', line 40

def self.new(type:, **args)
  case type.to_sym
  when :all
    Anthropic::Beta::BetaManagedAgentsWebFetchURLSourceAll.new(**args)
  when :none
    Anthropic::Beta::BetaManagedAgentsWebFetchURLSourceNone.new(**args)
  else
    raise ArgumentError, "unknown type: #{type}"
  end
end

.values ⇒ Array<Symbol>

Returns:

  • (Array<Symbol>)


# File 'lib/anthropic/models/beta/beta_managed_agents_web_fetch_url_source_user_input.rb', line 24

.variants ⇒ Array(Anthropic::Models::Beta::BetaManagedAgentsWebFetchURLSourceAll, Anthropic::Models::Beta::BetaManagedAgentsWebFetchURLSourceNone)



# File 'lib/anthropic/models/beta/beta_managed_agents_web_fetch_url_source_user_input.rb', line 28