Class: Anthropic::Models::Beta::MemoryStores::BetaManagedAgentsMemoryPreconditionFailedErrorObject

Inherits:
Internal::Type::BaseModel
  • Object
show all
Defined in:
lib/anthropic/models/beta/memory_stores/beta_managed_agents_memory_precondition_failed_error_object.rb,
sig/anthropic/models/beta/memory_stores/beta_managed_agents_memory_precondition_failed_error_object.rbs

Instance Attribute 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(message: nil, type: :memory_precondition_failed_error) ⇒ BetaManagedAgentsMemoryPreconditionFailedErrorObject

The error returned with HTTP status 409 when a request's precondition doesn't hold for the memory's current state, such as precondition on an update or expected_content_sha256 on a delete.

The error doesn't include the memory's current state. Retrieve the memory to see its current content and content_sha256 before you retry.

See the memory guide to learn more about safe content edits with content hash preconditions.

Parameters:

  • message (String) (defaults to: nil)
  • type (Symbol, :memory_precondition_failed_error) (defaults to: :memory_precondition_failed_error)
  • message: (String) (defaults to: nil)
  • type: (:memory_precondition_failed_error) (defaults to: :memory_precondition_failed_error)


# File 'lib/anthropic/models/beta/memory_stores/beta_managed_agents_memory_precondition_failed_error_object.rb', line 18

Instance Attribute Details

#message ⇒ String?

Parameters:

  • (String)

Returns:

  • (String, nil)


16
# File 'lib/anthropic/models/beta/memory_stores/beta_managed_agents_memory_precondition_failed_error_object.rb', line 16

optional :message, String

#type ⇒ Symbol, :memory_precondition_failed_error

Parameters:

  • value (:memory_precondition_failed_error)

Returns:

  • (Symbol, :memory_precondition_failed_error)


11
# File 'lib/anthropic/models/beta/memory_stores/beta_managed_agents_memory_precondition_failed_error_object.rb', line 11

required :type, const: :memory_precondition_failed_error

Instance Method Details

#to_hash ⇒ { type: :memory_precondition_failed_error, message: String }

Returns:

  • ({ type: :memory_precondition_failed_error, message: String })


20
21
22
23
# File 'sig/anthropic/models/beta/memory_stores/beta_managed_agents_memory_precondition_failed_error_object.rbs', line 20

def to_hash: -> {
  type: :memory_precondition_failed_error,
  message: String
}