Class: Telnyx::Models::AI::ConversationFlow

Inherits:
Internal::Type::BaseModel show all
Defined in:
lib/telnyx/models/ai/conversation_flow.rb,
sig/telnyx/models/ai/conversation_flow.rbs

Defined Under Namespace

Modules: Node

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(nodes:, start_node_id:, edges: nil) ⇒ Object

Conversation flow as returned by the API.

Parameters:



# File 'lib/telnyx/models/ai/conversation_flow.rb', line 25

Instance Attribute Details

#edgesArray<Telnyx::Models::AI::FlowEdge>?

Directed transitions between nodes.

Returns:



23
# File 'lib/telnyx/models/ai/conversation_flow.rb', line 23

optional :edges, -> { Telnyx::Internal::Type::ArrayOf[Telnyx::AI::FlowEdge] }

#nodesArray<Telnyx::Models::AI::FlowNode, Telnyx::Models::AI::ToolNode, Telnyx::Models::AI::SpeakNode>

All nodes in the flow.

Parameters:

  • value (::Array[Telnyx::Models::AI::ConversationFlow::node])

Returns:



11
# File 'lib/telnyx/models/ai/conversation_flow.rb', line 11

required :nodes, -> { Telnyx::Internal::Type::ArrayOf[union: Telnyx::AI::ConversationFlow::Node] }

#start_node_idString

ID of the node where the conversation begins.

Parameters:

  • value (String)

Returns:

  • (String)


17
# File 'lib/telnyx/models/ai/conversation_flow.rb', line 17

required :start_node_id, String

Instance Method Details

#to_hash{

Returns:

  • ({)


28
# File 'sig/telnyx/models/ai/conversation_flow.rbs', line 28

def to_hash: -> {