Class: Twilio::REST::Messaging::V1::BrandRegistrationContext::BrandVettingContext

Inherits:
InstanceContext
  • Object
show all
Defined in:
lib/twilio-ruby/rest/messaging/v1/brand_registration/brand_vetting.rb

Overview

PLEASE NOTE that this class contains beta products that are subject to change. Use them with caution.

Instance Method Summary collapse

Constructor Details

#initialize(version, brand_sid, brand_vetting_sid) ⇒ BrandVettingContext

Initialize the BrandVettingContext

Parameters:

  • version (Version)

    Version that contains the resource

  • brand_sid (String)

    The SID of the Brand Registration resource of the vettings to read .

  • brand_vetting_sid (String)

    The Twilio SID of the third-party vetting record.


180
181
182
183
184
185
186
# File 'lib/twilio-ruby/rest/messaging/v1/brand_registration/brand_vetting.rb', line 180

def initialize(version, brand_sid, brand_vetting_sid)
  super(version)

  # Path Solution
  @solution = {brand_sid: brand_sid, brand_vetting_sid: brand_vetting_sid, }
  @uri = "/a2p/BrandRegistrations/#{@solution[:brand_sid]}/Vettings/#{@solution[:brand_vetting_sid]}"
end

Instance Method Details

#fetchBrandVettingInstance

Fetch the BrandVettingInstance

Returns:


191
192
193
194
195
196
197
198
199
200
# File 'lib/twilio-ruby/rest/messaging/v1/brand_registration/brand_vetting.rb', line 191

def fetch
  payload = @version.fetch('GET', @uri)

  BrandVettingInstance.new(
      @version,
      payload,
      brand_sid: @solution[:brand_sid],
      brand_vetting_sid: @solution[:brand_vetting_sid],
  )
end

#inspectObject

Provide a detailed, user friendly representation


211
212
213
214
# File 'lib/twilio-ruby/rest/messaging/v1/brand_registration/brand_vetting.rb', line 211

def inspect
  context = @solution.map {|k, v| "#{k}: #{v}"}.join(',')
  "#<Twilio.Messaging.V1.BrandVettingContext #{context}>"
end

#to_sObject

Provide a user friendly representation


204
205
206
207
# File 'lib/twilio-ruby/rest/messaging/v1/brand_registration/brand_vetting.rb', line 204

def to_s
  context = @solution.map {|k, v| "#{k}: #{v}"}.join(',')
  "#<Twilio.Messaging.V1.BrandVettingContext #{context}>"
end