Class: Twilio::REST::Webhooks::V1::AuthProfileList::PostAuthProfile

Inherits:
Object
  • Object
show all
Defined in:
lib/twilio-ruby/rest/webhooks/v1/auth_profile.rb,
lib/twilio-ruby/rest/webhooks/v1/auth_profile.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(payload) ⇒ PostAuthProfile

Returns a new instance of PostAuthProfile.



47
48
49
50
51
52
53
54
55
56
57
58
# File 'lib/twilio-ruby/rest/webhooks/v1/auth_profile.rb', line 47

def initialize(payload)
        @type = payload["type"]
        @friendly_name = payload["friendly_name"]
        @token_url = payload["token_url"]
        @client_id = payload["client_id"]
        @client_secret = payload["client_secret"]
        @scope = payload["scope"]
        @audience = payload["audience"]
        @client_credentials_auth_method = payload["client_credentials_auth_method"]
        @username = payload["username"]
        @password = payload["password"]
end

Instance Attribute Details

#audience ⇒ Object

Parameters:

  • : (type) —

    [String] Authentication type

  • : (friendly_name) —

    [String] Human-readable name for identification (optional, defaults to blank)

  • : (token_url) —

    [String] OAuth2 token endpoint URL

  • : (client_id) —

    [String] OAuth2 client identifier

  • : (client_secret) —

    [String] OAuth2 client secret (never returned, stored securely as secret)

  • : (scope) —

    [String] OAuth2 scope to request

  • : (audience) —

    [String] OAuth2 audience parameter

  • : (client_credentials_auth_method) —

    [String] Client credentials authentication method (defaults to CLIENT_SECRET_POST)

  • : (username) —

    [String] Digest auth username

  • : (password) —

    [String] Digest auth password (never returned, stored securely as secret)



46
47
48
# File 'lib/twilio-ruby/rest/webhooks/v1/auth_profile.rb', line 46

def audience
  @audience
end

#client_credentials_auth_method ⇒ Object

Parameters:

  • : (type) —

    [String] Authentication type

  • : (friendly_name) —

    [String] Human-readable name for identification (optional, defaults to blank)

  • : (token_url) —

    [String] OAuth2 token endpoint URL

  • : (client_id) —

    [String] OAuth2 client identifier

  • : (client_secret) —

    [String] OAuth2 client secret (never returned, stored securely as secret)

  • : (scope) —

    [String] OAuth2 scope to request

  • : (audience) —

    [String] OAuth2 audience parameter

  • : (client_credentials_auth_method) —

    [String] Client credentials authentication method (defaults to CLIENT_SECRET_POST)

  • : (username) —

    [String] Digest auth username

  • : (password) —

    [String] Digest auth password (never returned, stored securely as secret)



46
47
48
# File 'lib/twilio-ruby/rest/webhooks/v1/auth_profile.rb', line 46

def client_credentials_auth_method
  @client_credentials_auth_method
end

#client_id ⇒ Object

Parameters:

  • : (type) —

    [String] Authentication type

  • : (friendly_name) —

    [String] Human-readable name for identification (optional, defaults to blank)

  • : (token_url) —

    [String] OAuth2 token endpoint URL

  • : (client_id) —

    [String] OAuth2 client identifier

  • : (client_secret) —

    [String] OAuth2 client secret (never returned, stored securely as secret)

  • : (scope) —

    [String] OAuth2 scope to request

  • : (audience) —

    [String] OAuth2 audience parameter

  • : (client_credentials_auth_method) —

    [String] Client credentials authentication method (defaults to CLIENT_SECRET_POST)

  • : (username) —

    [String] Digest auth username

  • : (password) —

    [String] Digest auth password (never returned, stored securely as secret)



46
47
48
# File 'lib/twilio-ruby/rest/webhooks/v1/auth_profile.rb', line 46

def client_id
  @client_id
end

#client_secret ⇒ Object

Parameters:

  • : (type) —

    [String] Authentication type

  • : (friendly_name) —

    [String] Human-readable name for identification (optional, defaults to blank)

  • : (token_url) —

    [String] OAuth2 token endpoint URL

  • : (client_id) —

    [String] OAuth2 client identifier

  • : (client_secret) —

    [String] OAuth2 client secret (never returned, stored securely as secret)

  • : (scope) —

    [String] OAuth2 scope to request

  • : (audience) —

    [String] OAuth2 audience parameter

  • : (client_credentials_auth_method) —

    [String] Client credentials authentication method (defaults to CLIENT_SECRET_POST)

  • : (username) —

    [String] Digest auth username

  • : (password) —

    [String] Digest auth password (never returned, stored securely as secret)



46
47
48
# File 'lib/twilio-ruby/rest/webhooks/v1/auth_profile.rb', line 46

def client_secret
  @client_secret
end

#friendly_name ⇒ Object

Parameters:

  • : (type) —

    [String] Authentication type

  • : (friendly_name) —

    [String] Human-readable name for identification (optional, defaults to blank)

  • : (token_url) —

    [String] OAuth2 token endpoint URL

  • : (client_id) —

    [String] OAuth2 client identifier

  • : (client_secret) —

    [String] OAuth2 client secret (never returned, stored securely as secret)

  • : (scope) —

    [String] OAuth2 scope to request

  • : (audience) —

    [String] OAuth2 audience parameter

  • : (client_credentials_auth_method) —

    [String] Client credentials authentication method (defaults to CLIENT_SECRET_POST)

  • : (username) —

    [String] Digest auth username

  • : (password) —

    [String] Digest auth password (never returned, stored securely as secret)



46
47
48
# File 'lib/twilio-ruby/rest/webhooks/v1/auth_profile.rb', line 46

def friendly_name
  @friendly_name
end

#password ⇒ Object

Parameters:

  • : (type) —

    [String] Authentication type

  • : (friendly_name) —

    [String] Human-readable name for identification (optional, defaults to blank)

  • : (token_url) —

    [String] OAuth2 token endpoint URL

  • : (client_id) —

    [String] OAuth2 client identifier

  • : (client_secret) —

    [String] OAuth2 client secret (never returned, stored securely as secret)

  • : (scope) —

    [String] OAuth2 scope to request

  • : (audience) —

    [String] OAuth2 audience parameter

  • : (client_credentials_auth_method) —

    [String] Client credentials authentication method (defaults to CLIENT_SECRET_POST)

  • : (username) —

    [String] Digest auth username

  • : (password) —

    [String] Digest auth password (never returned, stored securely as secret)



46
47
48
# File 'lib/twilio-ruby/rest/webhooks/v1/auth_profile.rb', line 46

def password
  @password
end

#scope ⇒ Object

Parameters:

  • : (type) —

    [String] Authentication type

  • : (friendly_name) —

    [String] Human-readable name for identification (optional, defaults to blank)

  • : (token_url) —

    [String] OAuth2 token endpoint URL

  • : (client_id) —

    [String] OAuth2 client identifier

  • : (client_secret) —

    [String] OAuth2 client secret (never returned, stored securely as secret)

  • : (scope) —

    [String] OAuth2 scope to request

  • : (audience) —

    [String] OAuth2 audience parameter

  • : (client_credentials_auth_method) —

    [String] Client credentials authentication method (defaults to CLIENT_SECRET_POST)

  • : (username) —

    [String] Digest auth username

  • : (password) —

    [String] Digest auth password (never returned, stored securely as secret)



46
47
48
# File 'lib/twilio-ruby/rest/webhooks/v1/auth_profile.rb', line 46

def scope
  @scope
end

#token_url ⇒ Object

Parameters:

  • : (type) —

    [String] Authentication type

  • : (friendly_name) —

    [String] Human-readable name for identification (optional, defaults to blank)

  • : (token_url) —

    [String] OAuth2 token endpoint URL

  • : (client_id) —

    [String] OAuth2 client identifier

  • : (client_secret) —

    [String] OAuth2 client secret (never returned, stored securely as secret)

  • : (scope) —

    [String] OAuth2 scope to request

  • : (audience) —

    [String] OAuth2 audience parameter

  • : (client_credentials_auth_method) —

    [String] Client credentials authentication method (defaults to CLIENT_SECRET_POST)

  • : (username) —

    [String] Digest auth username

  • : (password) —

    [String] Digest auth password (never returned, stored securely as secret)



46
47
48
# File 'lib/twilio-ruby/rest/webhooks/v1/auth_profile.rb', line 46

def token_url
  @token_url
end

#type ⇒ Object

Parameters:

  • : (type) —

    [String] Authentication type

  • : (friendly_name) —

    [String] Human-readable name for identification (optional, defaults to blank)

  • : (token_url) —

    [String] OAuth2 token endpoint URL

  • : (client_id) —

    [String] OAuth2 client identifier

  • : (client_secret) —

    [String] OAuth2 client secret (never returned, stored securely as secret)

  • : (scope) —

    [String] OAuth2 scope to request

  • : (audience) —

    [String] OAuth2 audience parameter

  • : (client_credentials_auth_method) —

    [String] Client credentials authentication method (defaults to CLIENT_SECRET_POST)

  • : (username) —

    [String] Digest auth username

  • : (password) —

    [String] Digest auth password (never returned, stored securely as secret)



46
47
48
# File 'lib/twilio-ruby/rest/webhooks/v1/auth_profile.rb', line 46

def type
  @type
end

#username ⇒ Object

Parameters:

  • : (type) —

    [String] Authentication type

  • : (friendly_name) —

    [String] Human-readable name for identification (optional, defaults to blank)

  • : (token_url) —

    [String] OAuth2 token endpoint URL

  • : (client_id) —

    [String] OAuth2 client identifier

  • : (client_secret) —

    [String] OAuth2 client secret (never returned, stored securely as secret)

  • : (scope) —

    [String] OAuth2 scope to request

  • : (audience) —

    [String] OAuth2 audience parameter

  • : (client_credentials_auth_method) —

    [String] Client credentials authentication method (defaults to CLIENT_SECRET_POST)

  • : (username) —

    [String] Digest auth username

  • : (password) —

    [String] Digest auth password (never returned, stored securely as secret)



46
47
48
# File 'lib/twilio-ruby/rest/webhooks/v1/auth_profile.rb', line 46

def username
  @username
end

Instance Method Details

#to_json(options = {}) ⇒ Object



59
60
61
62
63
64
65
66
67
68
69
70
71
72
# File 'lib/twilio-ruby/rest/webhooks/v1/auth_profile.rb', line 59

def to_json(options = {})
{
        "type": @type,
        "friendlyName": @friendly_name,
        "tokenUrl": @token_url,
        "clientId": @client_id,
        "clientSecret": @client_secret,
        "scope": @scope,
        "audience": @audience,
        "clientCredentialsAuthMethod": @client_credentials_auth_method,
        "username": @username,
        "password": @password,
}.to_json(options)
end