Class: Twilio::REST::Preview::Understand::AssistantContext::AssistantFallbackActionsInstance
- Inherits:
-
InstanceResource
- Object
- InstanceResource
- Twilio::REST::Preview::Understand::AssistantContext::AssistantFallbackActionsInstance
- Defined in:
- lib/twilio-ruby/rest/preview/understand/assistant/assistant_fallback_actions.rb
Instance Method Summary collapse
- #account_sid ⇒ String
- #assistant_sid ⇒ String
-
#context ⇒ AssistantFallbackActionsContext
Generate an instance context for the instance, the context is capable of performing various actions.
- #data ⇒ Hash
-
#fetch ⇒ AssistantFallbackActionsInstance
Fetch the AssistantFallbackActionsInstance.
-
#initialize(version, payload, assistant_sid: nil) ⇒ AssistantFallbackActionsInstance
constructor
Initialize the AssistantFallbackActionsInstance.
-
#inspect ⇒ Object
Provide a detailed, user friendly representation.
-
#to_s ⇒ Object
Provide a user friendly representation.
-
#update(fallback_actions: :unset) ⇒ AssistantFallbackActionsInstance
Update the AssistantFallbackActionsInstance.
- #url ⇒ String
Constructor Details
#initialize(version, payload, assistant_sid: nil) ⇒ AssistantFallbackActionsInstance
Initialize the AssistantFallbackActionsInstance
148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 |
# File 'lib/twilio-ruby/rest/preview/understand/assistant/assistant_fallback_actions.rb', line 148 def initialize(version, payload , assistant_sid: nil) super(version) # Marshaled Properties @properties = { 'account_sid' => payload['account_sid'], 'assistant_sid' => payload['assistant_sid'], 'url' => payload['url'], 'data' => payload['data'], } # Context @instance_context = nil @params = { 'assistant_sid' => assistant_sid || @properties['assistant_sid'] , } end |
Instance Method Details
#account_sid ⇒ String
177 178 179 |
# File 'lib/twilio-ruby/rest/preview/understand/assistant/assistant_fallback_actions.rb', line 177 def account_sid @properties['account_sid'] end |
#assistant_sid ⇒ String
183 184 185 |
# File 'lib/twilio-ruby/rest/preview/understand/assistant/assistant_fallback_actions.rb', line 183 def assistant_sid @properties['assistant_sid'] end |
#context ⇒ AssistantFallbackActionsContext
Generate an instance context for the instance, the context is capable of performing various actions. All instance actions are proxied to the context
168 169 170 171 172 173 |
# File 'lib/twilio-ruby/rest/preview/understand/assistant/assistant_fallback_actions.rb', line 168 def context unless @instance_context @instance_context = AssistantFallbackActionsContext.new(@version , @params['assistant_sid']) end @instance_context end |
#data ⇒ Hash
195 196 197 |
# File 'lib/twilio-ruby/rest/preview/understand/assistant/assistant_fallback_actions.rb', line 195 def data @properties['data'] end |
#fetch ⇒ AssistantFallbackActionsInstance
Fetch the AssistantFallbackActionsInstance
202 203 204 205 |
# File 'lib/twilio-ruby/rest/preview/understand/assistant/assistant_fallback_actions.rb', line 202 def fetch context.fetch end |
#inspect ⇒ Object
Provide a detailed, user friendly representation
229 230 231 232 |
# File 'lib/twilio-ruby/rest/preview/understand/assistant/assistant_fallback_actions.rb', line 229 def inspect values = @properties.map{|k, v| "#{k}: #{v}"}.join(" ") "<Twilio.Preview.Understand.AssistantFallbackActionsInstance #{values}>" end |
#to_s ⇒ Object
Provide a user friendly representation
222 223 224 225 |
# File 'lib/twilio-ruby/rest/preview/understand/assistant/assistant_fallback_actions.rb', line 222 def to_s values = @params.map{|k, v| "#{k}: #{v}"}.join(" ") "<Twilio.Preview.Understand.AssistantFallbackActionsInstance #{values}>" end |
#update(fallback_actions: :unset) ⇒ AssistantFallbackActionsInstance
Update the AssistantFallbackActionsInstance
211 212 213 214 215 216 217 218 |
# File 'lib/twilio-ruby/rest/preview/understand/assistant/assistant_fallback_actions.rb', line 211 def update( fallback_actions: :unset ) context.update( fallback_actions: fallback_actions, ) end |
#url ⇒ String
189 190 191 |
# File 'lib/twilio-ruby/rest/preview/understand/assistant/assistant_fallback_actions.rb', line 189 def url @properties['url'] end |