Class: BandwidthIris::ImportTnOrders

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

Class Method Summary collapse

Methods included from ClientWrapper

wrap_client_arg

Methods included from ApiItem

#[], #[]=, #initialize, #to_data

Class Method Details

.create_import_tn_order(client, import_tn_order) ⇒ Object



26
27
28
29
# File 'lib/bandwidth-iris/import_tn_orders.rb', line 26

def self.create_import_tn_order(client, import_tn_order)
  data = client.make_request(:post, client.("#{IMPORT_TN_ORDERS_PATH}"), {:import_tn_order => import_tn_order})
  return data
end

.delete_loa_file(client, order_id, file_id) ⇒ Object



54
55
56
# File 'lib/bandwidth-iris/import_tn_orders.rb', line 54

def self.delete_loa_file(client, order_id, file_id)
  client.make_request(:delete, client.("#{IMPORT_TN_ORDERS_PATH}/#{order_id}/#{LOAS_PATH}/#{file_id}"))
end

.delete_loa_file_metadata(client, order_id, file_id) ⇒ Object



70
71
72
# File 'lib/bandwidth-iris/import_tn_orders.rb', line 70

def self.(client, order_id, file_id)
  client.make_request(:delete, client.("#{IMPORT_TN_ORDERS_PATH}/#{order_id}/#{LOAS_PATH}/#{file_id}/metadata"))
end

.download_loa_file(client, order_id, file_id) ⇒ Object



43
44
45
46
# File 'lib/bandwidth-iris/import_tn_orders.rb', line 43

def self.download_loa_file(client, order_id, file_id)
  data = client.make_request_file_download(:get, client.("#{IMPORT_TN_ORDERS_PATH}/#{order_id}/#{LOAS_PATH}/#{file_id}"))
  return data
end

.get_import_tn_order(client, order_id) ⇒ Object



14
15
16
17
# File 'lib/bandwidth-iris/import_tn_orders.rb', line 14

def self.get_import_tn_order(client, order_id)
  data = client.make_request(:get, client.("#{IMPORT_TN_ORDERS_PATH}/#{order_id}"))
  return data
end

.get_import_tn_order_history(client, order_id) ⇒ Object



20
21
22
23
# File 'lib/bandwidth-iris/import_tn_orders.rb', line 20

def self.get_import_tn_order_history(client, order_id)
  data = client.make_request(:get, client.("#{IMPORT_TN_ORDERS_PATH}/#{order_id}/history"))
  return data
end

.get_import_tn_orders(client, query = nil) ⇒ Object



8
9
10
11
# File 'lib/bandwidth-iris/import_tn_orders.rb', line 8

def self.get_import_tn_orders(client, query = nil)
  data = client.make_request(:get, client.(IMPORT_TN_ORDERS_PATH), query)
  return data
end

.get_loa_file_metadata(client, order_id, file_id) ⇒ Object



59
60
61
62
# File 'lib/bandwidth-iris/import_tn_orders.rb', line 59

def self.(client, order_id, file_id)
  data = client.make_request(:get, client.("#{IMPORT_TN_ORDERS_PATH}/#{order_id}/#{LOAS_PATH}/#{file_id}/metadata"))
  return data
end

.get_loa_files(client, order_id) ⇒ Object



32
33
34
35
# File 'lib/bandwidth-iris/import_tn_orders.rb', line 32

def self.get_loa_files(client, order_id)
  data = client.make_request(:get, client.("#{IMPORT_TN_ORDERS_PATH}/#{order_id}/#{LOAS_PATH}"))
  return data
end

.replace_loa_file(client, order_id, file_id, file_contents, mime_type) ⇒ Object



49
50
51
# File 'lib/bandwidth-iris/import_tn_orders.rb', line 49

def self.replace_loa_file(client, order_id, file_id, file_contents, mime_type)
  data = client.make_request_file_upload(:put, client.("#{IMPORT_TN_ORDERS_PATH}/#{order_id}/#{LOAS_PATH}/#{file_id}"), file_contents, mime_type)
end

.update_loa_file_metadata(client, order_id, file_id, file_metadata) ⇒ Object



65
66
67
# File 'lib/bandwidth-iris/import_tn_orders.rb', line 65

def self.(client, order_id, file_id, )
  client.make_request(:put, client.("#{IMPORT_TN_ORDERS_PATH}/#{order_id}/#{LOAS_PATH}/#{file_id}/metadata"), {:file_meta_data => })
end

.upload_loa_file(client, order_id, file_contents, mime_type) ⇒ Object



38
39
40
# File 'lib/bandwidth-iris/import_tn_orders.rb', line 38

def self.upload_loa_file(client, order_id, file_contents, mime_type)
  client.make_request_file_upload(:post, client.("#{IMPORT_TN_ORDERS_PATH}/#{order_id}/#{LOAS_PATH}"), file_contents, mime_type)
end