Class: Anthropic::Models::WebFetchTool20250910

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/anthropic/models/web_fetch_tool_20250910.rb

Defined Under Namespace

Modules: AllowedCaller

Instance Attribute Summary collapse

Method Summary

Methods inherited from Internal::Type::BaseModel

#==, ==, #[], coerce, #deconstruct_keys, #deep_to_h, dump, fields, hash, #hash, inherited, #initialize, 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

This class inherits a constructor from Anthropic::Internal::Type::BaseModel

Instance Attribute Details

#allowed_callersArray<Symbol, Anthropic::Models::WebFetchTool20250910::AllowedCaller>?

Returns:



22
23
# File 'lib/anthropic/models/web_fetch_tool_20250910.rb', line 22

optional :allowed_callers,
-> { Anthropic::Internal::Type::ArrayOf[enum: Anthropic::WebFetchTool20250910::AllowedCaller] }

#allowed_domainsArray<String>?

List of domains to allow fetching from

Returns:



29
# File 'lib/anthropic/models/web_fetch_tool_20250910.rb', line 29

optional :allowed_domains, Anthropic::Internal::Type::ArrayOf[String], nil?: true

#blocked_domainsArray<String>?

List of domains to block fetching from

Returns:



35
# File 'lib/anthropic/models/web_fetch_tool_20250910.rb', line 35

optional :blocked_domains, Anthropic::Internal::Type::ArrayOf[String], nil?: true

#cache_controlAnthropic::Models::CacheControlEphemeral?

Create a cache control breakpoint at this content block.

Returns:



41
# File 'lib/anthropic/models/web_fetch_tool_20250910.rb', line 41

optional :cache_control, -> { Anthropic::CacheControlEphemeral }, nil?: true

#citationsAnthropic::Models::CitationsConfigParam?

Citations configuration for fetched documents. Citations are disabled by default.

Returns:



48
# File 'lib/anthropic/models/web_fetch_tool_20250910.rb', line 48

optional :citations, -> { Anthropic::CitationsConfigParam }, nil?: true

#defer_loadingBoolean?

If true, tool will not be included in initial system prompt. Only loaded when returned via tool_reference from tool search.

Returns:



55
# File 'lib/anthropic/models/web_fetch_tool_20250910.rb', line 55

optional :defer_loading, Anthropic::Internal::Type::Boolean

#max_content_tokensInteger?

Maximum number of tokens used by including web page text content in the context. The limit is approximate and does not apply to binary content such as PDFs.

Returns:



62
# File 'lib/anthropic/models/web_fetch_tool_20250910.rb', line 62

optional :max_content_tokens, Integer, nil?: true

#max_usesInteger?

Maximum number of times the tool can be used in the API request.

Returns:



68
# File 'lib/anthropic/models/web_fetch_tool_20250910.rb', line 68

optional :max_uses, Integer, nil?: true

#nameSymbol, :web_fetch

Name of the tool.

This is how the tool will be called by the model and in tool_use blocks.

Returns:



12
# File 'lib/anthropic/models/web_fetch_tool_20250910.rb', line 12

required :name, const: :web_fetch

#strictBoolean?

When true, guarantees schema validation on tool names and inputs

Returns:



74
# File 'lib/anthropic/models/web_fetch_tool_20250910.rb', line 74

optional :strict, Anthropic::Internal::Type::Boolean

#typeSymbol, :web_fetch_20250910

Returns:



17
# File 'lib/anthropic/models/web_fetch_tool_20250910.rb', line 17

required :type, const: :web_fetch_20250910