Class: IMHR::API

Inherits:
Object
  • Object
show all
Defined in:
lib/imhr/api.rb

Class Method Summary collapse

Class Method Details

.create(path, params) ⇒ Object



8
9
10
# File 'lib/imhr/api.rb', line 8

def create(path, params)
  access_token.post(api_path(path), body: params)
end

.delete(path) ⇒ Object



16
17
18
# File 'lib/imhr/api.rb', line 16

def delete(path)
  access_token.patch(path)
end

.get(path, params) ⇒ Object



4
5
6
# File 'lib/imhr/api.rb', line 4

def get(path, params)
  access_token.get(api_path(path), params: params)
end

.update(path, params) ⇒ Object



12
13
14
# File 'lib/imhr/api.rb', line 12

def update(path, params)
  access_token.patch(api_path(path), body: params)
end