Class: Twilio::REST::Trusthub::V1::TrustProductsContext::TrustProductsChannelEndpointAssignmentContext
- Inherits:
-
InstanceContext
- Object
- InstanceContext
- Twilio::REST::Trusthub::V1::TrustProductsContext::TrustProductsChannelEndpointAssignmentContext
- Defined in:
- lib/twilio-ruby/rest/trusthub/v1/trust_products/trust_products_channel_endpoint_assignment.rb
Instance Method Summary collapse
-
#delete ⇒ Boolean
Delete the TrustProductsChannelEndpointAssignmentInstance.
-
#delete_with_metadata ⇒ Boolean
Delete the TrustProductsChannelEndpointAssignmentInstanceMetadata.
-
#fetch ⇒ TrustProductsChannelEndpointAssignmentInstance
Fetch the TrustProductsChannelEndpointAssignmentInstance.
-
#fetch_with_metadata ⇒ TrustProductsChannelEndpointAssignmentInstance
Fetch the TrustProductsChannelEndpointAssignmentInstanceMetadata.
-
#initialize(version, trust_product_sid, sid) ⇒ TrustProductsChannelEndpointAssignmentContext
constructor
Initialize the TrustProductsChannelEndpointAssignmentContext.
-
#inspect ⇒ Object
Provide a detailed, user friendly representation.
-
#to_s ⇒ Object
Provide a user friendly representation.
Constructor Details
#initialize(version, trust_product_sid, sid) ⇒ TrustProductsChannelEndpointAssignmentContext
Initialize the TrustProductsChannelEndpointAssignmentContext
250 251 252 253 254 255 256 257 258 259 |
# File 'lib/twilio-ruby/rest/trusthub/v1/trust_products/trust_products_channel_endpoint_assignment.rb', line 250 def initialize(version, trust_product_sid, sid) super(version) # Path Solution @solution = { trust_product_sid: trust_product_sid, sid: sid, } @uri = "/TrustProducts/#{@solution[:trust_product_sid]}/ChannelEndpointAssignments/#{@solution[:sid]}" end |
Instance Method Details
#delete ⇒ Boolean
Delete the TrustProductsChannelEndpointAssignmentInstance
263 264 265 266 267 268 269 270 271 |
# File 'lib/twilio-ruby/rest/trusthub/v1/trust_products/trust_products_channel_endpoint_assignment.rb', line 263 def delete headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', }) @version.delete('DELETE', @uri, headers: headers) end |
#delete_with_metadata ⇒ Boolean
Delete the TrustProductsChannelEndpointAssignmentInstanceMetadata
276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 |
# File 'lib/twilio-ruby/rest/trusthub/v1/trust_products/trust_products_channel_endpoint_assignment.rb', line 276 def headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', }) response = @version.('DELETE', @uri, headers: headers) trustProductsChannelEndpointAssignment_instance = TrustProductsChannelEndpointAssignmentInstance.new( @version, response.body, account_sid: @solution[:account_sid], sid: @solution[:sid], ) TrustProductsChannelEndpointAssignmentInstanceMetadata.new(@version, trustProductsChannelEndpointAssignment_instance, response.headers, response.status_code) end |
#fetch ⇒ TrustProductsChannelEndpointAssignmentInstance
Fetch the TrustProductsChannelEndpointAssignmentInstance
295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 |
# File 'lib/twilio-ruby/rest/trusthub/v1/trust_products/trust_products_channel_endpoint_assignment.rb', line 295 def fetch headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', }) payload = @version.fetch('GET', @uri, headers: headers) TrustProductsChannelEndpointAssignmentInstance.new( @version, payload, trust_product_sid: @solution[:trust_product_sid], sid: @solution[:sid], ) end |
#fetch_with_metadata ⇒ TrustProductsChannelEndpointAssignmentInstance
Fetch the TrustProductsChannelEndpointAssignmentInstanceMetadata
315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 |
# File 'lib/twilio-ruby/rest/trusthub/v1/trust_products/trust_products_channel_endpoint_assignment.rb', line 315 def headers = Twilio::Values.of({'Content-Type' => 'application/x-www-form-urlencoded', }) response = @version.('GET', @uri, headers: headers) trust_products_channel_endpoint_assignment_instance = TrustProductsChannelEndpointAssignmentInstance.new( @version, response.body, trust_product_sid: @solution[:trust_product_sid], sid: @solution[:sid], ) TrustProductsChannelEndpointAssignmentInstanceMetadata.new( @version, trust_products_channel_endpoint_assignment_instance, response.headers, response.status_code ) end |
#inspect ⇒ Object
Provide a detailed, user friendly representation
348 349 350 351 |
# File 'lib/twilio-ruby/rest/trusthub/v1/trust_products/trust_products_channel_endpoint_assignment.rb', line 348 def inspect context = @solution.map{|k, v| "#{k}: #{v}"}.join(',') "#<Twilio.Trusthub.V1.TrustProductsChannelEndpointAssignmentContext #{context}>" end |
#to_s ⇒ Object
Provide a user friendly representation
341 342 343 344 |
# File 'lib/twilio-ruby/rest/trusthub/v1/trust_products/trust_products_channel_endpoint_assignment.rb', line 341 def to_s context = @solution.map{|k, v| "#{k}: #{v}"}.join(',') "#<Twilio.Trusthub.V1.TrustProductsChannelEndpointAssignmentContext #{context}>" end |