Class: Sirportly::ApiToken

Inherits:
DataObject show all
Defined in:
lib/sirportly/data_objects/api_token.rb

Instance Attribute Summary

Attributes inherited from DataObject

#attributes, #client

Class Method Summary collapse

Methods inherited from DataObject

all, find, #initialize, #inspect, #method_missing

Constructor Details

This class inherits a constructor from Sirportly::DataObject

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class Sirportly::DataObject

Class Method Details

.create(client, params = {}) ⇒ Object

Creates a new api token and returns an object



6
7
8
9
10
11
12
# File 'lib/sirportly/data_objects/api_token.rb', line 6

def self.create(client, params = {})
  if req = client.request('api_tokens/create', params)
    self.new(client, req)
  else
    false
  end
end