Class: Plivo::Resources::Token

Inherits:
Base::Resource show all
Defined in:
lib/plivo/resources/token.rb

Constant Summary

Constants included from Utils

Utils::TYPE_WHITELIST

Instance Attribute Summary

Attributes inherited from Base::Resource

#id

Instance Method Summary collapse

Methods included from Utils

GetSortedQueryParamString?, compute_signatureV3?, expected_type?, expected_value?, generate_url?, getMapFromQueryString?, is_one_among_string_url?, multi_valid_param?, raise_invalid_request, valid_account?, valid_date_format?, valid_mainaccount?, valid_multiple_destination_integers?, valid_multiple_destination_nos?, valid_param?, valid_range?, valid_signature?, valid_signatureV3?, valid_subaccount?, valid_url?

Constructor Details

#initialize(client, options = nil) ⇒ Token

Returns a new instance of Token.



6
7
8
9
10
# File 'lib/plivo/resources/token.rb', line 6

def initialize(client, options = nil)
  @_name = 'JWT/Token'
  super
  @_is_voice_request = true
end

Instance Method Details

#to_sObject



11
12
13
14
15
16
# File 'lib/plivo/resources/token.rb', line 11

def to_s
  {
    api_id: @api_id,
    token: @token
  }.to_s
end