Class: Twilio::REST::Serverless

Inherits:
Domain
  • Object
show all
Defined in:
lib/twilio-ruby/rest/serverless.rb,
lib/twilio-ruby/rest/serverless/v1.rb,
lib/twilio-ruby/rest/serverless/v1/service.rb,
lib/twilio-ruby/rest/serverless/v1/service/asset.rb,
lib/twilio-ruby/rest/serverless/v1/service/build.rb,
lib/twilio-ruby/rest/serverless/v1/service/function.rb,
lib/twilio-ruby/rest/serverless/v1/service/environment.rb,
lib/twilio-ruby/rest/serverless/v1/service/environment/log.rb,
lib/twilio-ruby/rest/serverless/v1/service/build/build_status.rb,
lib/twilio-ruby/rest/serverless/v1/service/asset/asset_version.rb,
lib/twilio-ruby/rest/serverless/v1/service/environment/variable.rb,
lib/twilio-ruby/rest/serverless/v1/service/environment/deployment.rb,
lib/twilio-ruby/rest/serverless/v1/service/function/function_version.rb,
lib/twilio-ruby/rest/serverless/v1/service/function/function_version/function_version_content.rb

Defined Under Namespace

Classes: V1

Instance Attribute Summary

Attributes inherited from Domain

#client

Instance Method Summary collapse

Methods inherited from Domain

#absolute_url, #request

Constructor Details

#initialize(twilio) ⇒ Serverless

Initialize the Serverless Domain


14
15
16
17
18
19
20
21
22
23
# File 'lib/twilio-ruby/rest/serverless.rb', line 14

def initialize(twilio)
  super

  @base_url = 'https://serverless.twilio.com'
  @host = 'serverless.twilio.com'
  @port = 443

  # Versions
  @v1 = nil
end

Instance Method Details

#services(sid = :unset) ⇒ Twilio::REST::Serverless::V1::ServiceInstance, Twilio::REST::Serverless::V1::ServiceList

Parameters:

  • sid (String) (defaults to: :unset)

    The unique string that we created to identify the Service resource.

Returns:


36
37
38
# File 'lib/twilio-ruby/rest/serverless.rb', line 36

def services(sid=:unset)
  self.v1.services(sid)
end

#to_sObject

Provide a user friendly representation


42
43
44
# File 'lib/twilio-ruby/rest/serverless.rb', line 42

def to_s
  '#<Twilio::REST::Serverless>'
end

#v1Object

Version v1 of serverless


27
28
29
# File 'lib/twilio-ruby/rest/serverless.rb', line 27

def v1
  @v1 ||= V1.new self
end