Class: ZiggeoAuthtokens

Inherits:
Object
  • Object
show all
Defined in:
lib/classes/ZiggeoAuthtokens.rb

Instance Method Summary collapse

Constructor Details

#initialize(application) ⇒ ZiggeoAuthtokens

Returns a new instance of ZiggeoAuthtokens.



3
4
5
# File 'lib/classes/ZiggeoAuthtokens.rb', line 3

def initialize(application)
  @application = application
end

Instance Method Details

#create(data = nil) ⇒ Object



19
20
21
# File 'lib/classes/ZiggeoAuthtokens.rb', line 19

def create(data = nil)
  return @application.connect.postJSON('/v1/authtokens/', data)
end

#delete(token_or_key) ⇒ Object



15
16
17
# File 'lib/classes/ZiggeoAuthtokens.rb', line 15

def delete(token_or_key)
  return @application.connect.delete('/v1/authtokens/' + token_or_key + '')
end

#get(token) ⇒ Object



7
8
9
# File 'lib/classes/ZiggeoAuthtokens.rb', line 7

def get(token)
  return @application.connect.getJSON('/v1/authtokens/' + token + '')
end

#update(token_or_key, data = nil) ⇒ Object



11
12
13
# File 'lib/classes/ZiggeoAuthtokens.rb', line 11

def update(token_or_key, data = nil)
  return @application.connect.postJSON('/v1/authtokens/' + token_or_key + '', data)
end