Class: BandwidthIris::Lidb

Inherits:
Object
  • Object
show all
Extended by:
ClientWrapper
Defined in:
lib/bandwidth-iris/lidb.rb

Class Method Summary collapse

Methods included from ClientWrapper

wrap_client_arg

Class Method Details

.create(client, item) ⇒ Object



17
18
19
20
21
# File 'lib/bandwidth-iris/lidb.rb', line 17

def self.create(client, item)
  location = client.make_request(:post, client.(LIDB_PATH), {:lidb_order => item})[1][:location]
  id = Client.get_id_from_location_header(location)
  self.get(client, id)
end

.get(client, id) ⇒ Object



12
13
14
# File 'lib/bandwidth-iris/lidb.rb', line 12

def self.get(client, id)
  client.make_request(:get, "#{client.(LIDB_PATH)}/#{id}")[0]
end

.list(client, query = nil) ⇒ Object



7
8
9
# File 'lib/bandwidth-iris/lidb.rb', line 7

def self.list(client, query = nil)
  client.make_request(:get, client.(LIDB_PATH), query)[0]
end