sageone_sdk 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (198) hide show
  1. checksums.yaml +7 -0
  2. data/.gitignore +15 -0
  3. data/.rspec +2 -0
  4. data/.travis.yml +15 -0
  5. data/Fudgefile +27 -0
  6. data/Gemfile +12 -0
  7. data/Guardfile +33 -0
  8. data/LICENSE +22 -0
  9. data/README.md +57 -0
  10. data/Rakefile +10 -0
  11. data/fudge_settings.yml +5 -0
  12. data/lib/sageone_sdk.rb +16 -0
  13. data/lib/sageone_sdk/authentication.rb +8 -0
  14. data/lib/sageone_sdk/client.rb +117 -0
  15. data/lib/sageone_sdk/client/account_types.rb +19 -0
  16. data/lib/sageone_sdk/client/bank_accounts.rb +18 -0
  17. data/lib/sageone_sdk/client/chart_of_accounts.rb +21 -0
  18. data/lib/sageone_sdk/client/contact_types.rb +20 -0
  19. data/lib/sageone_sdk/client/contacts.rb +82 -0
  20. data/lib/sageone_sdk/client/countries.rb +18 -0
  21. data/lib/sageone_sdk/client/expenditures.rb +26 -0
  22. data/lib/sageone_sdk/client/expense_methods.rb +19 -0
  23. data/lib/sageone_sdk/client/expense_types.rb +19 -0
  24. data/lib/sageone_sdk/client/financial_settings.rb +23 -0
  25. data/lib/sageone_sdk/client/income_methods.rb +19 -0
  26. data/lib/sageone_sdk/client/income_types.rb +19 -0
  27. data/lib/sageone_sdk/client/incomes.rb +51 -0
  28. data/lib/sageone_sdk/client/journals.rb +27 -0
  29. data/lib/sageone_sdk/client/ledger_accounts.rb +52 -0
  30. data/lib/sageone_sdk/client/payment_statuses.rb +18 -0
  31. data/lib/sageone_sdk/client/period_types.rb +19 -0
  32. data/lib/sageone_sdk/client/products.rb +50 -0
  33. data/lib/sageone_sdk/client/purchase_invoices.rb +61 -0
  34. data/lib/sageone_sdk/client/sales_invoices.rb +65 -0
  35. data/lib/sageone_sdk/client/services.rb +48 -0
  36. data/lib/sageone_sdk/client/tax_rates.rb +18 -0
  37. data/lib/sageone_sdk/client/transactions.rb +13 -0
  38. data/lib/sageone_sdk/configurable.rb +43 -0
  39. data/lib/sageone_sdk/default.rb +47 -0
  40. data/lib/sageone_sdk/middleware.rb +6 -0
  41. data/lib/sageone_sdk/middleware/sdata_parser.rb +29 -0
  42. data/lib/sageone_sdk/middleware/signature.rb +26 -0
  43. data/lib/sageone_sdk/sdata_error_response.rb +36 -0
  44. data/lib/sageone_sdk/sdata_response.rb +58 -0
  45. data/lib/sageone_sdk/signature.rb +115 -0
  46. data/lib/sageone_sdk/version.rb +3 -0
  47. data/sageone_sdk.gemspec +37 -0
  48. data/spec/cassettes/SageoneSdk_Client_AccountTypes/account_types/_id/returns_a_specific_account_type.json +1 -0
  49. data/spec/cassettes/SageoneSdk_Client_AccountTypes/account_types/allows_pagination.json +1 -0
  50. data/spec/cassettes/SageoneSdk_Client_AccountTypes/account_types/returns_all_account_types.json +1 -0
  51. data/spec/cassettes/SageoneSdk_Client_BankAccounts/bank_accounts/_id/returns_a_specific_bank_account.json +1 -0
  52. data/spec/cassettes/SageoneSdk_Client_BankAccounts/bank_accounts/allows_pagination.json +1 -0
  53. data/spec/cassettes/SageoneSdk_Client_BankAccounts/bank_accounts/returns_all_bank_accounts.json +1 -0
  54. data/spec/cassettes/SageoneSdk_Client_ChartOfAccounts/chart_of_accounts_structure/returns_the_chart_of_accounts_structure.json +1 -0
  55. data/spec/cassettes/SageoneSdk_Client_ChartOfAccounts/chart_of_accounts_templates/returns_the_chart_of_accounts_templates.json +1 -0
  56. data/spec/cassettes/SageoneSdk_Client_ContactTypes/contact_types/_id/returns_a_specific_contact_type.json +1 -0
  57. data/spec/cassettes/SageoneSdk_Client_ContactTypes/contact_types/allows_pagination.json +1 -0
  58. data/spec/cassettes/SageoneSdk_Client_ContactTypes/contact_types/returns_all_contact_types.json +1 -0
  59. data/spec/cassettes/SageoneSdk_Client_Contacts/contacts/_id/returns_a_specific_contact.json +1 -0
  60. data/spec/cassettes/SageoneSdk_Client_Contacts/contacts/allows_pagination.json +1 -0
  61. data/spec/cassettes/SageoneSdk_Client_Contacts/contacts/returns_all_contacts.json +1 -0
  62. data/spec/cassettes/SageoneSdk_Client_Contacts/create_contacts/creates_a_new_contact.json +1 -0
  63. data/spec/cassettes/SageoneSdk_Client_Contacts/create_contacts/on_error/responds_with_an_appropriate_error_message.json +1 -0
  64. data/spec/cassettes/SageoneSdk_Client_Contacts/delete_a_contact/deletes_the_contact.json +1 -0
  65. data/spec/cassettes/SageoneSdk_Client_Contacts/update_a_contact/updates_the_given_contact.json +1 -0
  66. data/spec/cassettes/SageoneSdk_Client_Countries/countries/_id/returns_a_specific_account_type.json +1 -0
  67. data/spec/cassettes/SageoneSdk_Client_Countries/countries/allows_pagination.json +1 -0
  68. data/spec/cassettes/SageoneSdk_Client_Countries/countries/returns_all_countries.json +1 -0
  69. data/spec/cassettes/SageoneSdk_Client_Expenditures/create_expenditures/creates_a_new_expenditure.json +1 -0
  70. data/spec/cassettes/SageoneSdk_Client_Expenditures/create_expenditures/on_error/responds_with_an_appropriate_error_message.json +1 -0
  71. data/spec/cassettes/SageoneSdk_Client_Expenditures/delete_an_expenditure/deletes_the_expenditure.json +1 -0
  72. data/spec/cassettes/SageoneSdk_Client_Expenditures/expenditures/_id/returns_a_specific_expenditure.json +1 -0
  73. data/spec/cassettes/SageoneSdk_Client_Expenditures/expenditures/allows_pagination.json +1 -0
  74. data/spec/cassettes/SageoneSdk_Client_Expenditures/expenditures/returns_all_expenditures.json +1 -0
  75. data/spec/cassettes/SageoneSdk_Client_Expenditures/update_an_expenditure/updates_the_given_expenditure.json +1 -0
  76. data/spec/cassettes/SageoneSdk_Client_ExpenseMethods/expense_methods/_id/returns_a_specific_contact_type.json +1 -0
  77. data/spec/cassettes/SageoneSdk_Client_ExpenseMethods/expense_methods/returns_all_expense_methods.json +1 -0
  78. data/spec/cassettes/SageoneSdk_Client_ExpenseMethods/income_methods/_id/returns_a_specific_contact_type.json +1 -0
  79. data/spec/cassettes/SageoneSdk_Client_ExpenseMethods/income_methods/allows_pagination.json +1 -0
  80. data/spec/cassettes/SageoneSdk_Client_ExpenseMethods/income_methods/returns_all_income_methods.json +1 -0
  81. data/spec/cassettes/SageoneSdk_Client_ExpenseTypes/expense_types/_id/returns_a_specific_contact_type.json +1 -0
  82. data/spec/cassettes/SageoneSdk_Client_ExpenseTypes/expense_types/allows_pagination.json +1 -0
  83. data/spec/cassettes/SageoneSdk_Client_ExpenseTypes/expense_types/returns_all_expense_types.json +1 -0
  84. data/spec/cassettes/SageoneSdk_Client_FinancialSettings/financial_settings/returns_the_financial_settings.json +1 -0
  85. data/spec/cassettes/SageoneSdk_Client_FinancialSettings/update_financial_settings/updates_the_financial_settings.json +1 -0
  86. data/spec/cassettes/SageoneSdk_Client_IncomeMethods/income_methods/_id/returns_a_specific_contact_type.json +1 -0
  87. data/spec/cassettes/SageoneSdk_Client_IncomeMethods/income_methods/returns_all_income_methods.json +1 -0
  88. data/spec/cassettes/SageoneSdk_Client_IncomeTypes/income_types/_id/returns_a_specific_contact_type.json +1 -0
  89. data/spec/cassettes/SageoneSdk_Client_IncomeTypes/income_types/allows_pagination.json +1 -0
  90. data/spec/cassettes/SageoneSdk_Client_IncomeTypes/income_types/returns_all_income_types.json +1 -0
  91. data/spec/cassettes/SageoneSdk_Client_Incomes/create_incomes/creates_a_new_income.json +1 -0
  92. data/spec/cassettes/SageoneSdk_Client_Incomes/create_incomes/on_error/responds_with_an_appropriate_error_message.json +1 -0
  93. data/spec/cassettes/SageoneSdk_Client_Incomes/delete_an_income/deletes_the_income.json +1 -0
  94. data/spec/cassettes/SageoneSdk_Client_Incomes/incomes/_id/returns_a_specific_income.json +1 -0
  95. data/spec/cassettes/SageoneSdk_Client_Incomes/incomes/allows_pagination.json +1 -0
  96. data/spec/cassettes/SageoneSdk_Client_Incomes/incomes/returns_all_incomes.json +1 -0
  97. data/spec/cassettes/SageoneSdk_Client_Incomes/update_an_income/updates_the_given_income.json +1 -0
  98. data/spec/cassettes/SageoneSdk_Client_Journals/journals/creates_a_journal.json +1 -0
  99. data/spec/cassettes/SageoneSdk_Client_Journals/journals/on_error/responds_with_an_appropriate_error_message.json +1 -0
  100. data/spec/cassettes/SageoneSdk_Client_LedgerAccounts/create_a_ledger_account/creates_a_new_ledger_account.json +1 -0
  101. data/spec/cassettes/SageoneSdk_Client_LedgerAccounts/create_a_ledger_account/on_error/responds_with_an_appropriate_error_message.json +1 -0
  102. data/spec/cassettes/SageoneSdk_Client_LedgerAccounts/ledger_account_balances/does_not_return_ledger_accounts_with_a_zero_balance.json +1 -0
  103. data/spec/cassettes/SageoneSdk_Client_LedgerAccounts/ledger_account_balances/returns_ledger_accounts_with_a_balance.json +1 -0
  104. data/spec/cassettes/SageoneSdk_Client_LedgerAccounts/ledger_accounts/_id/returns_a_specific_ledger_account.json +1 -0
  105. data/spec/cassettes/SageoneSdk_Client_LedgerAccounts/ledger_accounts/allows_pagination.json +1 -0
  106. data/spec/cassettes/SageoneSdk_Client_LedgerAccounts/ledger_accounts/returns_all_ledger_accounts.json +1 -0
  107. data/spec/cassettes/SageoneSdk_Client_PaymentStatuses/payment_statuses/_id/returns_a_specific_contact_type.json +1 -0
  108. data/spec/cassettes/SageoneSdk_Client_PaymentStatuses/payment_statuses/allows_pagination.json +1 -0
  109. data/spec/cassettes/SageoneSdk_Client_PaymentStatuses/payment_statuses/returns_all_payment_statuses.json +1 -0
  110. data/spec/cassettes/SageoneSdk_Client_PeriodTypes/period_types/_id/returns_a_specific_contact_type.json +1 -0
  111. data/spec/cassettes/SageoneSdk_Client_PeriodTypes/period_types/allows_pagination.json +1 -0
  112. data/spec/cassettes/SageoneSdk_Client_PeriodTypes/period_types/returns_all_period_types.json +1 -0
  113. data/spec/cassettes/SageoneSdk_Client_Products/create_products/creates_a_new_product.json +1 -0
  114. data/spec/cassettes/SageoneSdk_Client_Products/create_products/on_error/responds_with_an_appropriate_error_message.json +1 -0
  115. data/spec/cassettes/SageoneSdk_Client_Products/delete_a_product/deletes_the_product.json +1 -0
  116. data/spec/cassettes/SageoneSdk_Client_Products/products/_id/returns_a_specific_product.json +1 -0
  117. data/spec/cassettes/SageoneSdk_Client_Products/products/allows_pagination.json +1 -0
  118. data/spec/cassettes/SageoneSdk_Client_Products/products/returns_all_products.json +1 -0
  119. data/spec/cassettes/SageoneSdk_Client_Products/update_a_product/updates_the_given_product.json +1 -0
  120. data/spec/cassettes/SageoneSdk_Client_PurchaseInvoices/create_purchase_invoices/creates_a_new_purchase_invoice.json +1 -0
  121. data/spec/cassettes/SageoneSdk_Client_PurchaseInvoices/create_purchase_invoices/on_error/responds_with_an_appropriate_error_message.json +1 -0
  122. data/spec/cassettes/SageoneSdk_Client_PurchaseInvoices/delete_a_purchase_invoice/deletes_the_purchase_invoice.json +1 -0
  123. data/spec/cassettes/SageoneSdk_Client_PurchaseInvoices/purchase_invoices/_id/returns_a_specific_purchase_invoice.json +1 -0
  124. data/spec/cassettes/SageoneSdk_Client_PurchaseInvoices/purchase_invoices/allows_pagination.json +1 -0
  125. data/spec/cassettes/SageoneSdk_Client_PurchaseInvoices/purchase_invoices/returns_all_purchase_invoices.json +1 -0
  126. data/spec/cassettes/SageoneSdk_Client_PurchaseInvoices/update_a_purchase_invoice/updates_the_given_purchase_invoice.json +1 -0
  127. data/spec/cassettes/SageoneSdk_Client_SalesInvoices/create_sales_invoices/creates_a_new_sales_invoice.json +1 -0
  128. data/spec/cassettes/SageoneSdk_Client_SalesInvoices/create_sales_invoices/on_error/responds_with_an_appropriate_error_message.json +1 -0
  129. data/spec/cassettes/SageoneSdk_Client_SalesInvoices/delete_a_sales_invoice/deletes_the_sales_invoice.json +1 -0
  130. data/spec/cassettes/SageoneSdk_Client_SalesInvoices/sales_invoices/_id/returns_a_specific_sales_invoice.json +1 -0
  131. data/spec/cassettes/SageoneSdk_Client_SalesInvoices/sales_invoices/allows_pagination.json +1 -0
  132. data/spec/cassettes/SageoneSdk_Client_SalesInvoices/sales_invoices/returns_all_sales_invoices.json +1 -0
  133. data/spec/cassettes/SageoneSdk_Client_SalesInvoices/update_a_sales_invoice/updates_the_given_sales_invoice.json +1 -0
  134. data/spec/cassettes/SageoneSdk_Client_Services/create_services/creates_a_new_service.json +1 -0
  135. data/spec/cassettes/SageoneSdk_Client_Services/create_services/on_error/responds_with_an_appropriate_error_message.json +1 -0
  136. data/spec/cassettes/SageoneSdk_Client_Services/delete_a_service/deletes_the_service.json +1 -0
  137. data/spec/cassettes/SageoneSdk_Client_Services/services/_id/returns_a_specific_service.json +1 -0
  138. data/spec/cassettes/SageoneSdk_Client_Services/services/allows_pagination.json +1 -0
  139. data/spec/cassettes/SageoneSdk_Client_Services/services/returns_all_services.json +1 -0
  140. data/spec/cassettes/SageoneSdk_Client_Services/update_a_service/updates_the_given_service.json +1 -0
  141. data/spec/cassettes/SageoneSdk_Client_TaxRates/tax_rates/_id/returns_a_specific_contact_type.json +1 -0
  142. data/spec/cassettes/SageoneSdk_Client_TaxRates/tax_rates/allows_pagination.json +1 -0
  143. data/spec/cassettes/SageoneSdk_Client_TaxRates/tax_rates/returns_all_tax_rates.json +1 -0
  144. data/spec/cassettes/SageoneSdk_Client_Transactions/transactions/returns_all_transactions.json +1 -0
  145. data/spec/cassettes/account_types_index.json +1 -0
  146. data/spec/cassettes/bank_accounts_index.json +1 -0
  147. data/spec/cassettes/contact_types_index.json +1 -0
  148. data/spec/cassettes/contacts_index.json +1 -0
  149. data/spec/cassettes/countries_index.json +1 -0
  150. data/spec/cassettes/customer_create.json +1 -0
  151. data/spec/cassettes/customers_index.json +1 -0
  152. data/spec/cassettes/expenditure_create.json +1 -0
  153. data/spec/cassettes/expenditures_index.json +1 -0
  154. data/spec/cassettes/expense_methods_index.json +1 -0
  155. data/spec/cassettes/expense_types_index.json +1 -0
  156. data/spec/cassettes/income_create.json +1 -0
  157. data/spec/cassettes/income_methods_index.json +1 -0
  158. data/spec/cassettes/income_types_index.json +1 -0
  159. data/spec/cassettes/incomes_index.json +1 -0
  160. data/spec/cassettes/ledger_accounts_index.json +1 -0
  161. data/spec/cassettes/payment_statuses_index.json +1 -0
  162. data/spec/cassettes/period_types_index.json +1 -0
  163. data/spec/cassettes/product_create.json +1 -0
  164. data/spec/cassettes/products_index.json +1 -0
  165. data/spec/cassettes/purchase_invoice_create.json +1 -0
  166. data/spec/cassettes/purchase_invoices_index.json +1 -0
  167. data/spec/cassettes/sales_invoice_create.json +1 -0
  168. data/spec/cassettes/sales_invoices_index.json +1 -0
  169. data/spec/cassettes/service_create.json +1 -0
  170. data/spec/cassettes/services_index.json +1 -0
  171. data/spec/cassettes/suppliers_index.json +1 -0
  172. data/spec/cassettes/tax_rates_index.json +1 -0
  173. data/spec/sageone_sdk/client/account_types_spec.rb +29 -0
  174. data/spec/sageone_sdk/client/bank_accounts_spec.rb +34 -0
  175. data/spec/sageone_sdk/client/chart_of_accounts_spec.rb +23 -0
  176. data/spec/sageone_sdk/client/contact_types_spec.rb +29 -0
  177. data/spec/sageone_sdk/client/contacts_spec.rb +75 -0
  178. data/spec/sageone_sdk/client/countries_spec.rb +29 -0
  179. data/spec/sageone_sdk/client/expenditures_spec.rb +113 -0
  180. data/spec/sageone_sdk/client/expense_methods_spec.rb +29 -0
  181. data/spec/sageone_sdk/client/expense_types_spec.rb +29 -0
  182. data/spec/sageone_sdk/client/financial_settings_spec.rb +23 -0
  183. data/spec/sageone_sdk/client/income_methods_spec.rb +29 -0
  184. data/spec/sageone_sdk/client/income_types_spec.rb +29 -0
  185. data/spec/sageone_sdk/client/incomes_spec.rb +114 -0
  186. data/spec/sageone_sdk/client/journals_spec.rb +39 -0
  187. data/spec/sageone_sdk/client/ledger_accounts_spec.rb +65 -0
  188. data/spec/sageone_sdk/client/payment_statuses_spec.rb +29 -0
  189. data/spec/sageone_sdk/client/period_types_spec.rb +29 -0
  190. data/spec/sageone_sdk/client/products_spec.rb +75 -0
  191. data/spec/sageone_sdk/client/purchase_invoices_spec.rb +124 -0
  192. data/spec/sageone_sdk/client/sales_invoices_spec.rb +126 -0
  193. data/spec/sageone_sdk/client/services_spec.rb +75 -0
  194. data/spec/sageone_sdk/client/tax_rates_spec.rb +29 -0
  195. data/spec/sageone_sdk/client/transactions_spec.rb +16 -0
  196. data/spec/sageone_sdk_spec.rb +19 -0
  197. data/spec/spec_helper.rb +40 -0
  198. metadata +601 -0
@@ -0,0 +1,115 @@
1
+ require 'base64'
2
+ require 'openssl'
3
+ require 'cgi'
4
+
5
+ module SageoneSdk
6
+ # Signature
7
+ class Signature
8
+ attr_reader :http_method, :nonce
9
+
10
+ # Constructor
11
+ def initialize(http_method, url, request_body, nonce, secret, token)
12
+ @http_method = http_method.to_s.upcase
13
+ @url = URI(url)
14
+ @request_body = request_body.to_s
15
+ @nonce = nonce
16
+ @secret = secret
17
+ @token = token
18
+ end
19
+
20
+ def self.generate_nonce
21
+ SecureRandom.hex
22
+ end
23
+
24
+ # Set the base URL
25
+ def base_url
26
+ base_array = []
27
+ base_array << @url.scheme
28
+ base_array << "://"
29
+ base_array << @url.host
30
+ base_array << ":#{@url.port}" if @url.port != @url.default_port
31
+ base_array << @url.path
32
+
33
+ base_array.join
34
+ end
35
+
36
+ # Request query params
37
+ def query_params
38
+ get_params_hash(@url.query)
39
+ end
40
+
41
+ # Request body params
42
+ def body_params
43
+ get_params_hash(@request_body)
44
+ end
45
+
46
+ # Generate the request params from the request query and body params
47
+ def request_params
48
+ request_hash = query_params.merge(body_params).sort
49
+ request_array = []
50
+
51
+ request_hash.each do |key, value|
52
+ request_array << "#{key}=#{value}"
53
+ end
54
+
55
+ request_array.join('&')
56
+ end
57
+
58
+ # Generate the base signature string
59
+ def signature_base_string
60
+ s = @http_method.dup
61
+ s << '&'
62
+ s << percent_encode(base_url)
63
+ s << '&'
64
+ s << percent_encode(request_params.to_s)
65
+ s << '&'
66
+ s << percent_encode(nonce.to_s)
67
+
68
+ s
69
+ end
70
+
71
+ # Generate the signing key
72
+ def signing_key
73
+ s = percent_encode(@secret)
74
+ s << '&'
75
+ s << percent_encode(@token)
76
+
77
+ s
78
+ end
79
+
80
+ # Generates the signature
81
+ def to_s
82
+ s = Base64.encode64(OpenSSL::HMAC.digest(OpenSSL::Digest.new('sha1'), signing_key, signature_base_string))
83
+
84
+ s
85
+ end
86
+
87
+ private
88
+
89
+ # Generates a hash from a params string
90
+ def get_params_hash(params)
91
+ params_hash = {}
92
+
93
+ if !params.nil? and !params.empty?
94
+ params = percent_decode(params)
95
+ params.split('&').each do |param|
96
+ param_pair = param.split('=')
97
+ params_hash[percent_encode(param_pair[0])] = percent_encode(param_pair[1])
98
+ end
99
+ end
100
+
101
+ params_hash
102
+ end
103
+
104
+ # Percent encodes special characters in a string
105
+ def percent_encode(str)
106
+ # Replaced deprecated URI.escape with CGI.escape
107
+ # CGI.escape replaces spaces with "+", so we also need to substitute them with "%20"
108
+ CGI.escape(str).gsub("+", "%20")
109
+ end
110
+
111
+ def percent_decode(str)
112
+ CGI.unescape(str).gsub("%20", "+")
113
+ end
114
+ end
115
+ end
@@ -0,0 +1,3 @@
1
+ module SageoneSdk
2
+ VERSION = "0.0.1"
3
+ end
@@ -0,0 +1,37 @@
1
+ # coding: utf-8
2
+ lib = File.expand_path('../lib', __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require 'sageone_sdk/version'
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "sageone_sdk"
8
+ spec.version = SageoneSdk::VERSION
9
+ spec.authors = ["Sage UK Ltd"]
10
+ spec.email = ["support@sageone.com"]
11
+ spec.summary = "SDK for Sage One API."
12
+ spec.description = "Provides Ruby methods for accessing the Sage One API endpoints."
13
+ spec.homepage = "https://developers.sageone.com/"
14
+ spec.license = "MIT"
15
+
16
+ spec.files = `git ls-files -z`.split("\x0")
17
+ spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
18
+ spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
19
+ spec.require_paths = ["lib"]
20
+
21
+ spec.add_dependency 'sawyer', '~> 0.5.3'
22
+ spec.add_dependency 'faraday_middleware', "~> 0.9.1"
23
+ spec.add_dependency 'hashie'
24
+ spec.add_dependency 'yard'
25
+ spec.add_dependency "activesupport", "~> 4.0.4"
26
+
27
+ spec.add_development_dependency "bundler", "~> 1.7"
28
+ spec.add_development_dependency 'cane'
29
+ spec.add_development_dependency 'flay'
30
+ spec.add_development_dependency 'flog'
31
+ spec.add_development_dependency 'fudge'
32
+ spec.add_development_dependency 'guard-rspec'
33
+ spec.add_development_dependency 'rake'
34
+ spec.add_development_dependency 'rspec'
35
+ spec.add_development_dependency 'simplecov'
36
+ spec.add_development_dependency 'yard'
37
+ end
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/account_types/1","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["ef4c77c003b86cf80a3dc477bb89f872"],"X-Signature":["3695C19Hq6ZNAq0u6X2jr/jDsiU="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 15:43:17 GMT"],"Etag":["\"4d16a1d5a1d11f74b24e848e0be4763e\""],"Server":["openresty"],"Set-Cookie":["_session_id=85907f0a93ea7181e5778b032b9fd3e0; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["abb7e318a4673977a57c8f61a37254a1"],"X-Runtime":["0.013060"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["53"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":1,\"name\":\"Current\",\"$key\":1}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 15:43:17 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/account_types?$itemsPerPage=2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["ca3af9db6bdfd38c897213f8062d4790"],"X-Signature":["enjwJuExiG2M91kOcMjOQefsfZw="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 15:43:17 GMT"],"Etag":["\"cd2d1a8f38ad1f654e2c831f71f8465d\""],"Server":["openresty"],"Set-Cookie":["_session_id=36f279be58871d782efd4ffbe999fcdd; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["5e8ce6efc4ecbc00693f2b8f4fcb19d8"],"X-Runtime":["0.026670"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["174"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":6,\"$startIndex\":0,\"$itemsPerPage\":6,\"$resources\":[{\"id\":1,\"name\":\"Current\",\"$key\":1},{\"id\":2,\"name\":\"Savings\",\"$key\":2},{\"id\":3,\"name\":\"Credit Card\",\"$key\":3},{\"id\":5,\"name\":\"Cash in Hand\",\"$key\":5},{\"id\":6,\"name\":\"Loan\",\"$key\":6},{\"id\":7,\"name\":\"Other\",\"$key\":7}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 15:43:16 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/account_types","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["af260ef29a4f243f7b07d741f523c8f0"],"X-Signature":["jyoGmiLhIZ+hQsNHe9iF5TGo4g0="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 15:43:17 GMT"],"Etag":["\"d7620f20d15a8152c97187f688eb8afa\""],"Server":["openresty"],"Set-Cookie":["_session_id=7a38e03c670df9dd41ebb7d7c3ee0524; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["ab3ae7df49a24fe01e7e57fe7885039e"],"X-Runtime":["0.027121"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["176"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":6,\"$startIndex\":0,\"$itemsPerPage\":20,\"$resources\":[{\"id\":1,\"name\":\"Current\",\"$key\":1},{\"id\":2,\"name\":\"Savings\",\"$key\":2},{\"id\":3,\"name\":\"Credit Card\",\"$key\":3},{\"id\":5,\"name\":\"Cash in Hand\",\"$key\":5},{\"id\":6,\"name\":\"Loan\",\"$key\":6},{\"id\":7,\"name\":\"Other\",\"$key\":7}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 15:43:16 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/bank_accounts/245","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["2dbc20dcf82f7d816b0071948c66cee7"],"X-Signature":["kJ86TfzaaUwXzwTYtMzhHjG6Vrs="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 11:48:59 GMT"],"Etag":["\"fb8678d2eef64f2b6852fb4f857d7e96\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["6f81323aa82d702c864a0e1586b06183"],"X-Runtime":["0.031509"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["159"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":245,\"account_name\":\"Current\",\"account_number\":\"\",\"sort_code\":\"\",\"telephone\":\"\",\"email\":\"\",\"address\":{\"$key\":null},\"account_type\":{\"id\":1,\"$key\":1},\"ledger_account\":{\"id\":7696,\"$key\":7696},\"balance\":\"198.0\",\"$key\":245}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 11:48:59 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/bank_accounts?$itemsPerPage=2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["98075fbcc3bb83b4c9e4f59647d6bf3e"],"X-Signature":["rEZovB3H8Ze6QQUm85CE81QX05Y="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 15:47:26 GMT"],"Etag":["\"2afa5902cae0f438430ead2fbd2dd602\""],"Server":["openresty"],"Set-Cookie":["_session_id=97e2239846fcdb814c4c89c1469f8e3e; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["c8729c395833a2852edaef7f564b291d"],"X-Runtime":["0.079716"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["275"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":2,\"$startIndex\":0,\"$itemsPerPage\":2,\"$resources\":[{\"id\":15,\"account_name\":\"Current\",\"account_number\":\"\",\"sort_code\":\"\",\"telephone\":\"\",\"email\":\"\",\"address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":27},\"account_type\":{\"id\":1,\"$key\":1},\"ledger_account\":{\"id\":479,\"$key\":479},\"balance\":\"0.0\",\"$key\":15},{\"id\":16,\"account_name\":\"Cash in Hand\",\"account_number\":\"\",\"sort_code\":\"\",\"telephone\":\"\",\"email\":\"\",\"address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":28},\"account_type\":{\"id\":5,\"$key\":5},\"ledger_account\":{\"id\":480,\"$key\":480},\"balance\":\"0.0\",\"$key\":16}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 15:47:25 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/bank_accounts","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["9d6e5b464bb326ddf8a80b95e4d33a1f"],"X-Signature":["26iYEThNK2IU3IAMkVjnW1Iii0s="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 15:47:26 GMT"],"Etag":["\"b3dc23f5c15f43621ded0652856d5059\""],"Server":["openresty"],"Set-Cookie":["_session_id=db2423b24b80db4881a40a3efeebbaa1; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["2b132134a14ec79f911a0324dd09edea"],"X-Runtime":["0.111242"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["277"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":2,\"$startIndex\":0,\"$itemsPerPage\":20,\"$resources\":[{\"id\":15,\"account_name\":\"Current\",\"account_number\":\"\",\"sort_code\":\"\",\"telephone\":\"\",\"email\":\"\",\"address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":27},\"account_type\":{\"id\":1,\"$key\":1},\"ledger_account\":{\"id\":479,\"$key\":479},\"balance\":\"0.0\",\"$key\":15},{\"id\":16,\"account_name\":\"Cash in Hand\",\"account_number\":\"\",\"sort_code\":\"\",\"telephone\":\"\",\"email\":\"\",\"address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":28},\"account_type\":{\"id\":5,\"$key\":5},\"ledger_account\":{\"id\":480,\"$key\":480},\"balance\":\"0.0\",\"$key\":16}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 15:47:25 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/coa_structure","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["sageone_sdk Ruby Gem 0.0.1"],"Authorization":["Bearer bc8b0400db3b8f625a47518e4d4e6b37afd36bca"],"X-Nonce":["5a9eb8319f8fc42b3a8e8f8258ee64b8"],"X-Signature":["hDQ5Wu1/1szo8BmCRrGhsjCSBpA="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Cf-Ray":["2561a009f0552963-DUB"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Thu, 17 Dec 2015 09:33:12 GMT"],"Etag":["\"3a7554be7b59701c33259485c4debef3\""],"Server":["openresty"],"Set-Cookie":["__cfduid=d00394783bab244afb54033b53b768bf41450344792; expires=Fri, 16-Dec-16 09:33:12 GMT; path=/; domain=.sageone.com; HttpOnly","_session_id=0d08a42edb108a9a5acea4ce71619b19; path=/; expires=Thu, 17-Dec-2015 10:33:12 GMT; secure; HttpOnly"],"Status":["200 OK"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Frame-Options":["SAMEORIGIN"],"X-Rack-Cache":["miss"],"X-Request-Id":["6a8a308f2ca8509574ffb782f174e323"],"X-Runtime":["0.171054"],"X-Server":["uk-production-extra-r3-24 (production)","uk-production-modproxy-144"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["2377"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"last_updated\":\"2015-12-17T08:14:34Z\",\"template\":{\"id\":2,\"sage_one_accounts_product\":\"Accounting\",\"name\":\"Small Business\",\"country\":{\"id\":218,\"name\":\"United Kingdom\",\"$key\":218},\"$key\":2},\"ledger_accounts\":[{\"id\":5167016,\"included_in_chart\":true,\"ledger_name\":\"Current\",\"name\":\"Current\",\"nominal_code\":1200,\"last_updated\":\"2015-12-05T14:12:46Z\",\"tax_code\":{\"$key\":null},\"category\":{\"id\":9,\"name\":\"Bank\",\"$key\":9},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":5167016},{\"id\":5167017,\"included_in_chart\":true,\"ledger_name\":\"Cash in Hand\",\"name\":\"Cash in Hand\",\"nominal_code\":1210,\"last_updated\":\"2015-12-05T14:12:46Z\",\"tax_code\":{\"$key\":null},\"category\":{\"id\":9,\"name\":\"Bank\",\"$key\":9},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":5167017},{\"id\":5167018,\"included_in_chart\":true,\"ledger_name\":\"Assets - Cost\",\"name\":\"Assets - Cost\",\"nominal_code\":1,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":5167018},{\"id\":5167019,\"included_in_chart\":true,\"ledger_name\":\"Office equipment and IT - Cost\",\"name\":\"Office equipment and IT - Cost\",\"nominal_code\":30,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":5167019},{\"id\":5167020,\"included_in_chart\":true,\"ledger_name\":\"Office equipment and IT - Accumulated Depreciation\",\"name\":\"Office equipment and IT - Accumulated Depreciation\",\"nominal_code\":31,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":5167020},{\"id\":5167021,\"included_in_chart\":true,\"ledger_name\":\"Fixtures and fittings - Cost\",\"name\":\"Fixtures and fittings - Cost\",\"nominal_code\":40,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":5167021},{\"id\":5167022,\"included_in_chart\":true,\"ledger_name\":\"Fixtures and fittings - Accumulated Depreciation\",\"name\":\"Fixtures and fittings - Accumulated Depreciation\",\"nominal_code\":41,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":5167022},{\"id\":5167023,\"included_in_chart\":true,\"ledger_name\":\"Motor Vehicles - Cost\",\"name\":\"Motor Vehicles - Cost\",\"nominal_code\":50,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":5167023},{\"id\":5167024,\"included_in_chart\":true,\"ledger_name\":\"Motor Vehicles - Accumulated Depreciation\",\"name\":\"Motor Vehicles - Accumulated Depreciation\",\"nominal_code\":51,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":5167024},{\"id\":5167025,\"included_in_chart\":true,\"ledger_name\":\"Stock\",\"name\":\"Stock\",\"nominal_code\":1000,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":6,\"name\":\"Current Assets\",\"$key\":6},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":5167025},{\"id\":5167026,\"included_in_chart\":true,\"ledger_name\":\"Trade Debtors\",\"name\":\"Trade Debtors\",\"nominal_code\":1100,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":6,\"name\":\"Current Assets\",\"$key\":6},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":5167026},{\"id\":5167027,\"included_in_chart\":true,\"ledger_name\":\"Provision for doubtful debtors\",\"name\":\"Provision for doubtful debtors\",\"nominal_code\":1101,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":6,\"name\":\"Current Assets\",\"$key\":6},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":5167027},{\"id\":5167028,\"included_in_chart\":true,\"ledger_name\":\"Prepayments\",\"name\":\"Prepayments\",\"nominal_code\":1110,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":6,\"name\":\"Current Assets\",\"$key\":6},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":5167028},{\"id\":5167029,\"included_in_chart\":true,\"ledger_name\":\"Trade Creditors\",\"name\":\"Trade Creditors\",\"nominal_code\":2100,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":5167029},{\"id\":5167030,\"included_in_chart\":true,\"ledger_name\":\"Accruals\",\"name\":\"Accruals\",\"nominal_code\":2101,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":5167030},{\"id\":5167031,\"included_in_chart\":true,\"ledger_name\":\"Corporation Tax Liability\",\"name\":\"Corporation Tax Liability\",\"nominal_code\":2150,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":5167031},{\"id\":5167032,\"included_in_chart\":true,\"ledger_name\":\"VAT on Sales\",\"name\":\"VAT on Sales\",\"nominal_code\":2200,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":5167032},{\"id\":5167033,\"included_in_chart\":true,\"ledger_name\":\"VAT on Purchases\",\"name\":\"VAT on Purchases\",\"nominal_code\":2201,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":5167033},{\"id\":5167034,\"included_in_chart\":true,\"ledger_name\":\"VAT Liability\",\"name\":\"VAT Liability\",\"nominal_code\":2202,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":5167034},{\"id\":5167035,\"included_in_chart\":true,\"ledger_name\":\"VAT Allocations \u0026 Adjustments\",\"name\":\"VAT Allocations \u0026 Adjustments\",\"nominal_code\":2203,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":5167035},{\"id\":5167036,\"included_in_chart\":true,\"ledger_name\":\"VAT on Sales - Holding Account\",\"name\":\"VAT on Sales - Holding Account\",\"nominal_code\":2205,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":5167036},{\"id\":5167037,\"included_in_chart\":true,\"ledger_name\":\"VAT on Purchases - Holding Account\",\"name\":\"VAT on Purchases - Holding Account\",\"nominal_code\":2206,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":5167037},{\"id\":5167038,\"included_in_chart\":true,\"ledger_name\":\"PAYE\",\"name\":\"PAYE\",\"nominal_code\":2210,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":5167038},{\"id\":5167039,\"included_in_chart\":true,\"ledger_name\":\"Other taxes to pay to HMRC\",\"name\":\"Other taxes to pay to HMRC\",\"nominal_code\":2211,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":5167039},{\"id\":5167040,\"included_in_chart\":true,\"ledger_name\":\"Student Loan\",\"name\":\"Student Loan\",\"nominal_code\":2214,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":5167040},{\"id\":5167041,\"included_in_chart\":true,\"ledger_name\":\"Attachments\",\"name\":\"Attachments\",\"nominal_code\":2215,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":5167041},{\"id\":5167042,\"included_in_chart\":true,\"ledger_name\":\"Net Wages\",\"name\":\"Net Wages\",\"nominal_code\":2220,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":5167042},{\"id\":5167043,\"included_in_chart\":true,\"ledger_name\":\"Pension\",\"name\":\"Pension\",\"nominal_code\":2230,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":5167043},{\"id\":5167044,\"included_in_chart\":true,\"ledger_name\":\"Share capital\",\"name\":\"Share capital\",\"nominal_code\":3000,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":12,\"name\":\"Equity\",\"$key\":12},\"category_group\":{\"id\":5,\"name\":\"Capital\",\"$key\":5},\"$key\":5167044},{\"id\":5167045,\"included_in_chart\":true,\"ledger_name\":\"Profit and Loss Account\",\"name\":\"Profit and Loss Account\",\"nominal_code\":3100,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":12,\"name\":\"Equity\",\"$key\":12},\"category_group\":{\"id\":5,\"name\":\"Capital\",\"$key\":5},\"$key\":5167045},{\"id\":5167046,\"included_in_chart\":true,\"ledger_name\":\"Capital introduced\",\"name\":\"Capital introduced\",\"nominal_code\":3200,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":12,\"name\":\"Equity\",\"$key\":12},\"category_group\":{\"id\":5,\"name\":\"Capital\",\"$key\":5},\"$key\":5167046},{\"id\":5167047,\"included_in_chart\":true,\"ledger_name\":\"Drawings - equity\",\"name\":\"Drawings - equity\",\"nominal_code\":3260,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":12,\"name\":\"Equity\",\"$key\":12},\"category_group\":{\"id\":5,\"name\":\"Capital\",\"$key\":5},\"$key\":5167047},{\"id\":5167048,\"included_in_chart\":true,\"ledger_name\":\"Sales Type A\",\"name\":\"Sales Type A\",\"nominal_code\":4000,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":1,\"name\":\"Sales\",\"$key\":1},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":5167048},{\"id\":5167049,\"included_in_chart\":true,\"ledger_name\":\"Sales Discounts\",\"name\":\"Sales Discounts\",\"nominal_code\":4009,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":1,\"name\":\"Sales\",\"$key\":1},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":5167049},{\"id\":5167050,\"included_in_chart\":true,\"ledger_name\":\"Sale of Assets\",\"name\":\"Sale of Assets\",\"nominal_code\":4200,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":2,\"name\":\"Other Income\",\"$key\":2},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":5167050},{\"id\":5167051,\"included_in_chart\":true,\"ledger_name\":\"Late Payment Charges\",\"name\":\"Late Payment Charges\",\"nominal_code\":4400,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":2,\"name\":\"Other Income\",\"$key\":2},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":5167051},{\"id\":5167052,\"included_in_chart\":true,\"ledger_name\":\"Other income\",\"name\":\"Other income\",\"nominal_code\":4900,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":2,\"name\":\"Other Income\",\"$key\":2},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":5167052},{\"id\":5167053,\"included_in_chart\":true,\"ledger_name\":\"Carriage on Sales\",\"name\":\"Carriage on Sales\",\"nominal_code\":4905,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":1,\"name\":\"Sales\",\"$key\":1},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":5167053},{\"id\":5167054,\"included_in_chart\":true,\"ledger_name\":\"Cost of sales - goods\",\"name\":\"Cost of sales - goods\",\"nominal_code\":5000,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":3,\"name\":\"Direct Expenses\",\"$key\":3},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167054},{\"id\":5167055,\"included_in_chart\":true,\"ledger_name\":\"Purchase Discounts\",\"name\":\"Purchase Discounts\",\"nominal_code\":5009,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":3,\"name\":\"Direct Expenses\",\"$key\":3},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167055},{\"id\":5167056,\"included_in_chart\":true,\"ledger_name\":\"Cost of sales - materials\",\"name\":\"Cost of sales - materials\",\"nominal_code\":5010,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":3,\"name\":\"Direct Expenses\",\"$key\":3},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167056},{\"id\":5167057,\"included_in_chart\":true,\"ledger_name\":\"Cost of sales - delivery\",\"name\":\"Cost of sales - delivery\",\"nominal_code\":5015,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":3,\"name\":\"Direct Expenses\",\"$key\":3},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167057},{\"id\":5167058,\"included_in_chart\":true,\"ledger_name\":\"Carriage on Purchases\",\"name\":\"Carriage on Purchases\",\"nominal_code\":5100,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":3,\"name\":\"Direct Expenses\",\"$key\":3},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167058},{\"id\":5167059,\"included_in_chart\":true,\"ledger_name\":\"Marketing\",\"name\":\"Marketing\",\"nominal_code\":6200,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167059},{\"id\":5167060,\"included_in_chart\":true,\"ledger_name\":\"Employee costs\",\"name\":\"Employee costs\",\"nominal_code\":7000,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167060},{\"id\":5167062,\"included_in_chart\":true,\"ledger_name\":\"Employers NI\",\"name\":\"Employers NI\",\"nominal_code\":7006,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167062},{\"id\":5167063,\"included_in_chart\":true,\"ledger_name\":\"Employer's Pension\",\"name\":\"Employer's Pension\",\"nominal_code\":7007,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167063},{\"id\":5167064,\"included_in_chart\":true,\"ledger_name\":\"Other Deductions\",\"name\":\"Other Deductions\",\"nominal_code\":7009,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167064},{\"id\":5167065,\"included_in_chart\":true,\"ledger_name\":\"Statutory Sick Pay\",\"name\":\"Statutory Sick Pay\",\"nominal_code\":7010,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167065},{\"id\":5167066,\"included_in_chart\":true,\"ledger_name\":\"Statutory Maternity Pay\",\"name\":\"Statutory Maternity Pay\",\"nominal_code\":7011,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167066},{\"id\":5167067,\"included_in_chart\":true,\"ledger_name\":\"Statutory Paternity Pay\",\"name\":\"Statutory Paternity Pay\",\"nominal_code\":7012,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167067},{\"id\":5167068,\"included_in_chart\":true,\"ledger_name\":\"Statutory Adoption Pay\",\"name\":\"Statutory Adoption Pay\",\"nominal_code\":7013,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167068},{\"id\":5167069,\"included_in_chart\":true,\"ledger_name\":\"Rent and rates\",\"name\":\"Rent and rates\",\"nominal_code\":7100,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167069},{\"id\":5167070,\"included_in_chart\":true,\"ledger_name\":\"Gas and electric\",\"name\":\"Gas and electric\",\"nominal_code\":7200,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":2,\"name\":\"Lower Rate\",\"$key\":2},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167070},{\"id\":5167071,\"included_in_chart\":true,\"ledger_name\":\"Motor Expenses\",\"name\":\"Motor Expenses\",\"nominal_code\":7300,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167071},{\"id\":5167072,\"included_in_chart\":true,\"ledger_name\":\"Travel and Entertainment\",\"name\":\"Travel and Entertainment\",\"nominal_code\":7400,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167072},{\"id\":5167073,\"included_in_chart\":true,\"ledger_name\":\"Office costs\",\"name\":\"Office costs\",\"nominal_code\":7500,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167073},{\"id\":5167074,\"included_in_chart\":true,\"ledger_name\":\"Legal and Professional\",\"name\":\"Legal and Professional\",\"nominal_code\":7600,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167074},{\"id\":5167075,\"included_in_chart\":true,\"ledger_name\":\"Insurance\",\"name\":\"Insurance\",\"nominal_code\":7610,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":4,\"name\":\"Exempt\",\"$key\":4},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167075},{\"id\":5167076,\"included_in_chart\":true,\"ledger_name\":\"Repairs and renewals\",\"name\":\"Repairs and renewals\",\"nominal_code\":7800,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167076},{\"id\":5167077,\"included_in_chart\":true,\"ledger_name\":\"Bank charges and interest\",\"name\":\"Bank charges and interest\",\"nominal_code\":7900,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":4,\"name\":\"Exempt\",\"$key\":4},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167077},{\"id\":5167078,\"included_in_chart\":true,\"ledger_name\":\"Depreciation\",\"name\":\"Depreciation\",\"nominal_code\":8000,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":5,\"name\":\"Depreciation\",\"$key\":5},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167078},{\"id\":5167079,\"included_in_chart\":true,\"ledger_name\":\"Bad Debts\",\"name\":\"Bad Debts\",\"nominal_code\":8100,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167079},{\"id\":5167080,\"included_in_chart\":true,\"ledger_name\":\"General Expenses\",\"name\":\"General Expenses\",\"nominal_code\":8200,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167080},{\"id\":5167081,\"included_in_chart\":true,\"ledger_name\":\"Exchange rate gain/(loss)\",\"name\":\"Exchange rate gain/(loss)\",\"nominal_code\":8211,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167081},{\"id\":5167082,\"included_in_chart\":true,\"ledger_name\":\"Dividend cost\",\"name\":\"Dividend cost\",\"nominal_code\":8900,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167082},{\"id\":5167083,\"included_in_chart\":true,\"ledger_name\":\"Opening Balances\",\"name\":\"Opening Balances Control Account\",\"nominal_code\":9998,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167083},{\"id\":5167084,\"included_in_chart\":true,\"ledger_name\":\"Suspense\",\"name\":\"Corrections\",\"nominal_code\":9999,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167084},{\"id\":5222740,\"included_in_chart\":true,\"ledger_name\":\"new name\",\"name\":\"disp name\",\"nominal_code\":9876,\"last_updated\":\"2015-12-09T13:48:31Z\",\"tax_code\":{\"$key\":null},\"category\":{\"id\":1,\"name\":\"Sales\",\"$key\":1},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":5222740},{\"id\":5236884,\"included_in_chart\":true,\"ledger_name\":\"Beans\",\"name\":\"Beanz\",\"nominal_code\":9988,\"last_updated\":\"2015-12-10T11:46:46Z\",\"tax_code\":{\"$key\":null},\"category\":{\"id\":1,\"name\":\"Sales\",\"$key\":1},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":5236884},{\"id\":5237682,\"included_in_chart\":false,\"ledger_name\":\"ewrg\",\"name\":\"gew\",\"nominal_code\":1235,\"last_updated\":\"2015-12-10T12:25:32Z\",\"tax_code\":{\"$key\":null},\"category\":{\"id\":1,\"name\":\"Sales\",\"$key\":1},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":5237682},{\"id\":5322307,\"included_in_chart\":true,\"ledger_name\":\"My new ledger account\",\"name\":\"My new ledger account\",\"nominal_code\":1234,\"last_updated\":\"2015-12-17T08:03:19Z\",\"tax_code\":{\"$key\":null},\"category\":{\"id\":1,\"name\":\"Sales\",\"$key\":1},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":5322307},{\"id\":5322380,\"included_in_chart\":true,\"ledger_name\":\"My new ledger account\",\"name\":\"My new ledger account\",\"nominal_code\":1237,\"last_updated\":\"2015-12-17T08:14:34Z\",\"tax_code\":{\"$key\":null},\"category\":{\"id\":1,\"name\":\"Sales\",\"$key\":1},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":5322380}],\"$key\":153540}"},"http_version":null},"recorded_at":"Thu, 17 Dec 2015 09:33:12 GMT"}],"recorded_with":"VCR 3.0.0"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/coa_templates","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["sageone_sdk Ruby Gem 0.0.1"],"Authorization":["Bearer bc8b0400db3b8f625a47518e4d4e6b37afd36bca"],"X-Nonce":["a77caa44749739fde7ab54be4850841b"],"X-Signature":["bWqJ8BtfKOVT0QWBmgdlDow2ekU="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Cf-Ray":["2561a007331e295d-DUB"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Thu, 17 Dec 2015 09:33:12 GMT"],"Etag":["\"fe6d6fea553c1a3b5ea57151c7eb5c04\""],"Server":["openresty"],"Set-Cookie":["__cfduid=dcea9e1a4559419911f017057957efeb21450344792; expires=Fri, 16-Dec-16 09:33:12 GMT; path=/; domain=.sageone.com; HttpOnly","_session_id=efdb6eab0ccc699494a8c74744000734; path=/; expires=Thu, 17-Dec-2015 10:33:12 GMT; secure; HttpOnly"],"Status":["200 OK"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Frame-Options":["SAMEORIGIN"],"X-Rack-Cache":["miss"],"X-Request-Id":["6fa8d11247977915492c6655f2b087b7"],"X-Runtime":["0.203912"],"X-Server":["uk-production-extra-r3-27 (production)","uk-production-modproxy-140"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["3537"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"[{\"id\":2,\"sage_one_accounts_product\":\"Accounting\",\"name\":\"Small Business\",\"country\":{\"id\":218,\"name\":\"United Kingdom\",\"$key\":218},\"coa_accounts\":[{\"id\":1,\"included_in_chart\":true,\"ledger_name\":\"Assets - Cost\",\"display_name\":\"Assets - Cost\",\"nominal_code\":1,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:12Z\",\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":1},{\"id\":9,\"included_in_chart\":true,\"ledger_name\":\"Office equipment and IT - Cost\",\"display_name\":\"Office equipment and IT - Cost\",\"nominal_code\":30,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:12Z\",\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":9},{\"id\":10,\"included_in_chart\":true,\"ledger_name\":\"Office equipment and IT - Accumulated Depreciation\",\"display_name\":\"Office equipment and IT - Accumulated Depreciation\",\"nominal_code\":31,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:12Z\",\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":10},{\"id\":11,\"included_in_chart\":true,\"ledger_name\":\"Fixtures and fittings - Cost\",\"display_name\":\"Fixtures and fittings - Cost\",\"nominal_code\":40,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:12Z\",\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":11},{\"id\":12,\"included_in_chart\":true,\"ledger_name\":\"Fixtures and fittings - Accumulated Depreciation\",\"display_name\":\"Fixtures and fittings - Accumulated Depreciation\",\"nominal_code\":41,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:12Z\",\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":12},{\"id\":13,\"included_in_chart\":true,\"ledger_name\":\"Motor Vehicles - Cost\",\"display_name\":\"Motor Vehicles - Cost\",\"nominal_code\":50,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:12Z\",\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":13},{\"id\":14,\"included_in_chart\":true,\"ledger_name\":\"Motor Vehicles - Accumulated Depreciation\",\"display_name\":\"Motor Vehicles - Accumulated Depreciation\",\"nominal_code\":51,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:12Z\",\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":14},{\"id\":15,\"included_in_chart\":true,\"ledger_name\":\"Stock\",\"display_name\":\"Stock\",\"nominal_code\":1000,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:12Z\",\"category\":{\"id\":6,\"name\":\"Current Assets\",\"$key\":6},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":15},{\"id\":16,\"included_in_chart\":true,\"ledger_name\":\"Trade Debtors\",\"display_name\":\"Trade Debtors\",\"nominal_code\":1100,\"control_name\":\"TRADE_DEBTORS\",\"last_updated\":\"2013-07-03T10:38:12Z\",\"category\":{\"id\":6,\"name\":\"Current Assets\",\"$key\":6},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":16},{\"id\":17,\"included_in_chart\":true,\"ledger_name\":\"Provision for doubtful debtors\",\"display_name\":\"Provision for doubtful debtors\",\"nominal_code\":1101,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:12Z\",\"category\":{\"id\":6,\"name\":\"Current Assets\",\"$key\":6},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":17},{\"id\":19,\"included_in_chart\":true,\"ledger_name\":\"Prepayments\",\"display_name\":\"Prepayments\",\"nominal_code\":1110,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:12Z\",\"category\":{\"id\":6,\"name\":\"Current Assets\",\"$key\":6},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":19},{\"id\":23,\"included_in_chart\":true,\"ledger_name\":\"Trade Creditors\",\"display_name\":\"Trade Creditors\",\"nominal_code\":2100,\"control_name\":\"TRADE_CREDITORS\",\"last_updated\":\"2013-07-03T10:38:12Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":23},{\"id\":24,\"included_in_chart\":true,\"ledger_name\":\"Accruals\",\"display_name\":\"Accruals\",\"nominal_code\":2101,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:12Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":24},{\"id\":29,\"included_in_chart\":true,\"ledger_name\":\"Corporation Tax Liability\",\"display_name\":\"Corporation Tax Liability\",\"nominal_code\":2150,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:12Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":29},{\"id\":28,\"included_in_chart\":true,\"ledger_name\":\"VAT on Sales\",\"display_name\":\"VAT on Sales\",\"nominal_code\":2200,\"control_name\":\"TAX_ON_SALES\",\"last_updated\":\"2013-07-03T10:38:12Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":28},{\"id\":27,\"included_in_chart\":true,\"ledger_name\":\"VAT on Purchases\",\"display_name\":\"VAT on Purchases\",\"nominal_code\":2201,\"control_name\":\"TAX_ON_PURCHASES\",\"last_updated\":\"2013-07-03T10:38:12Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":27},{\"id\":26,\"included_in_chart\":true,\"ledger_name\":\"VAT Liability\",\"display_name\":\"VAT Liability\",\"nominal_code\":2202,\"control_name\":\"TAX_LIABILITY\",\"last_updated\":\"2013-07-03T10:38:12Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":26},{\"id\":200,\"included_in_chart\":true,\"ledger_name\":\"VAT Allocations \u0026 Adjustments\",\"display_name\":\"VAT Allocations \u0026 Adjustments\",\"nominal_code\":2203,\"control_name\":\"TAX_ALLOCATIONS_AND_ADJUSTMENTS\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":200},{\"id\":65,\"included_in_chart\":true,\"ledger_name\":\"VAT on Sales - Holding Account\",\"display_name\":\"VAT on Sales - Holding Account\",\"nominal_code\":2205,\"control_name\":\"TAX_ON_SALES_HOLDING\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":65},{\"id\":66,\"included_in_chart\":true,\"ledger_name\":\"VAT on Purchases - Holding Account\",\"display_name\":\"VAT on Purchases - Holding Account\",\"nominal_code\":2206,\"control_name\":\"TAX_ON_PURCHASES_HOLDING\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":66},{\"id\":67,\"included_in_chart\":true,\"ledger_name\":\"PAYE\",\"display_name\":\"PAYE\",\"nominal_code\":2210,\"control_name\":\"PAYE\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":67},{\"id\":30,\"included_in_chart\":true,\"ledger_name\":\"Other taxes to pay to HMRC\",\"display_name\":\"Other taxes to pay to HMRC\",\"nominal_code\":2211,\"control_name\":\"NI\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":30},{\"id\":143,\"included_in_chart\":true,\"ledger_name\":\"Student Loan\",\"display_name\":\"Student Loan\",\"nominal_code\":2214,\"control_name\":\"STUDENT_LOAN\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":143},{\"id\":144,\"included_in_chart\":true,\"ledger_name\":\"Attachments\",\"display_name\":\"Attachments\",\"nominal_code\":2215,\"control_name\":\"ATTACHMENTS\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":144},{\"id\":68,\"included_in_chart\":true,\"ledger_name\":\"Net Wages\",\"display_name\":\"Net Wages\",\"nominal_code\":2220,\"control_name\":\"NET_WAGES\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":68},{\"id\":145,\"included_in_chart\":true,\"ledger_name\":\"Pension\",\"display_name\":\"Pension\",\"nominal_code\":2230,\"control_name\":\"PENSION\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":145},{\"id\":35,\"included_in_chart\":true,\"ledger_name\":\"Share capital\",\"display_name\":\"Share capital\",\"nominal_code\":3000,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":12,\"name\":\"Equity\",\"$key\":12},\"category_group\":{\"id\":5,\"name\":\"Capital\",\"$key\":5},\"$key\":35},{\"id\":36,\"included_in_chart\":true,\"ledger_name\":\"Profit and Loss Account\",\"display_name\":\"Profit and Loss Account\",\"nominal_code\":3100,\"control_name\":\"PROFIT_AND_LOSS\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":12,\"name\":\"Equity\",\"$key\":12},\"category_group\":{\"id\":5,\"name\":\"Capital\",\"$key\":5},\"$key\":36},{\"id\":37,\"included_in_chart\":true,\"ledger_name\":\"Capital introduced\",\"display_name\":\"Capital introduced\",\"nominal_code\":3200,\"control_name\":\"OWN_INVEST\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":12,\"name\":\"Equity\",\"$key\":12},\"category_group\":{\"id\":5,\"name\":\"Capital\",\"$key\":5},\"$key\":37},{\"id\":38,\"included_in_chart\":true,\"ledger_name\":\"Drawings - equity\",\"display_name\":\"Drawings - equity\",\"nominal_code\":3260,\"control_name\":\"DRAWINGS_EQUITY\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":12,\"name\":\"Equity\",\"$key\":12},\"category_group\":{\"id\":5,\"name\":\"Capital\",\"$key\":5},\"$key\":38},{\"id\":39,\"included_in_chart\":true,\"ledger_name\":\"Sales Type A\",\"display_name\":\"Sales Type A\",\"nominal_code\":4000,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":1,\"name\":\"Sales\",\"$key\":1},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":39},{\"id\":201,\"included_in_chart\":true,\"ledger_name\":\"Sales Discounts\",\"display_name\":\"Sales Discounts\",\"nominal_code\":4009,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":1,\"name\":\"Sales\",\"$key\":1},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":201},{\"id\":202,\"included_in_chart\":true,\"ledger_name\":\"Sale of Assets\",\"display_name\":\"Sale of Assets\",\"nominal_code\":4200,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":2,\"name\":\"Other Income\",\"$key\":2},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":202},{\"id\":203,\"included_in_chart\":true,\"ledger_name\":\"Late Payment Charges\",\"display_name\":\"Late Payment Charges\",\"nominal_code\":4400,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":2,\"name\":\"Other Income\",\"$key\":2},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":203},{\"id\":44,\"included_in_chart\":true,\"ledger_name\":\"Other income\",\"display_name\":\"Other income\",\"nominal_code\":4900,\"control_name\":\"OTHER_INCOME\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":2,\"name\":\"Other Income\",\"$key\":2},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":44},{\"id\":204,\"included_in_chart\":true,\"ledger_name\":\"Carriage on Sales\",\"display_name\":\"Carriage on Sales\",\"nominal_code\":4905,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":1,\"name\":\"Sales\",\"$key\":1},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":204},{\"id\":45,\"included_in_chart\":true,\"ledger_name\":\"Cost of sales - goods\",\"display_name\":\"Cost of sales - goods\",\"nominal_code\":5000,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":3,\"name\":\"Direct Expenses\",\"$key\":3},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":45},{\"id\":205,\"included_in_chart\":true,\"ledger_name\":\"Purchase Discounts\",\"display_name\":\"Purchase Discounts\",\"nominal_code\":5009,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":3,\"name\":\"Direct Expenses\",\"$key\":3},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":205},{\"id\":46,\"included_in_chart\":true,\"ledger_name\":\"Cost of sales - materials\",\"display_name\":\"Cost of sales - materials\",\"nominal_code\":5010,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":3,\"name\":\"Direct Expenses\",\"$key\":3},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":46},{\"id\":47,\"included_in_chart\":true,\"ledger_name\":\"Cost of sales - delivery\",\"display_name\":\"Cost of sales - delivery\",\"nominal_code\":5015,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":3,\"name\":\"Direct Expenses\",\"$key\":3},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":47},{\"id\":206,\"included_in_chart\":true,\"ledger_name\":\"Carriage on Purchases\",\"display_name\":\"Carriage on Purchases\",\"nominal_code\":5100,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":3,\"name\":\"Direct Expenses\",\"$key\":3},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":206},{\"id\":50,\"included_in_chart\":true,\"ledger_name\":\"Marketing\",\"display_name\":\"Marketing\",\"nominal_code\":6200,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":50},{\"id\":51,\"included_in_chart\":true,\"ledger_name\":\"Employee costs\",\"display_name\":\"Employee costs\",\"nominal_code\":7000,\"control_name\":\"EMPLOYEE_COSTS\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":51},{\"id\":69,\"included_in_chart\":true,\"ledger_name\":\"Employers NI\",\"display_name\":\"Employers NI\",\"nominal_code\":7006,\"control_name\":\"EMPLOYERS_NIC\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":69},{\"id\":146,\"included_in_chart\":true,\"ledger_name\":\"Employer's Pension\",\"display_name\":\"Employer's Pension\",\"nominal_code\":7007,\"control_name\":\"EMPLOYERS_PENSION\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":146},{\"id\":147,\"included_in_chart\":true,\"ledger_name\":\"Other Deductions\",\"display_name\":\"Other Deductions\",\"nominal_code\":7009,\"control_name\":\"OTHER_DEDUCTIONS\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":147},{\"id\":148,\"included_in_chart\":true,\"ledger_name\":\"Statutory Sick Pay\",\"display_name\":\"Statutory Sick Pay\",\"nominal_code\":7010,\"control_name\":\"STATUTORY_SICK_PAY\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":148},{\"id\":149,\"included_in_chart\":true,\"ledger_name\":\"Statutory Maternity Pay\",\"display_name\":\"Statutory Maternity Pay\",\"nominal_code\":7011,\"control_name\":\"STATUTORY_MATERNITY_PAY\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":149},{\"id\":150,\"included_in_chart\":true,\"ledger_name\":\"Statutory Paternity Pay\",\"display_name\":\"Statutory Paternity Pay\",\"nominal_code\":7012,\"control_name\":\"STATUTORY_PATERNITY_PAY\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":150},{\"id\":151,\"included_in_chart\":true,\"ledger_name\":\"Statutory Adoption Pay\",\"display_name\":\"Statutory Adoption Pay\",\"nominal_code\":7013,\"control_name\":\"STATUTORY_ADOPTION_PAY\",\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":151},{\"id\":52,\"included_in_chart\":true,\"ledger_name\":\"Rent and rates\",\"display_name\":\"Rent and rates\",\"nominal_code\":7100,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":52},{\"id\":53,\"included_in_chart\":true,\"ledger_name\":\"Gas and electric\",\"display_name\":\"Gas and electric\",\"nominal_code\":7200,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":53},{\"id\":54,\"included_in_chart\":true,\"ledger_name\":\"Motor Expenses\",\"display_name\":\"Motor Expenses\",\"nominal_code\":7300,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:13Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":54},{\"id\":55,\"included_in_chart\":true,\"ledger_name\":\"Travel and Entertainment\",\"display_name\":\"Travel and Entertainment\",\"nominal_code\":7400,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:14Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":55},{\"id\":71,\"included_in_chart\":true,\"ledger_name\":\"Office costs\",\"display_name\":\"Office costs\",\"nominal_code\":7500,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:14Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":71},{\"id\":56,\"included_in_chart\":true,\"ledger_name\":\"Legal and Professional\",\"display_name\":\"Legal and Professional\",\"nominal_code\":7600,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:14Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":56},{\"id\":57,\"included_in_chart\":true,\"ledger_name\":\"Insurance\",\"display_name\":\"Insurance\",\"nominal_code\":7610,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:14Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":57},{\"id\":70,\"included_in_chart\":true,\"ledger_name\":\"Repairs and renewals\",\"display_name\":\"Repairs and renewals\",\"nominal_code\":7800,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:14Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":70},{\"id\":58,\"included_in_chart\":true,\"ledger_name\":\"Bank charges and interest\",\"display_name\":\"Bank charges and interest\",\"nominal_code\":7900,\"control_name\":\"BANK_CHARGES_AND_INTEREST\",\"last_updated\":\"2013-07-03T10:38:14Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":58},{\"id\":59,\"included_in_chart\":true,\"ledger_name\":\"Depreciation\",\"display_name\":\"Depreciation\",\"nominal_code\":8000,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:14Z\",\"category\":{\"id\":5,\"name\":\"Depreciation\",\"$key\":5},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":59},{\"id\":60,\"included_in_chart\":true,\"ledger_name\":\"Bad Debts\",\"display_name\":\"Bad Debts\",\"nominal_code\":8100,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:14Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":60},{\"id\":61,\"included_in_chart\":true,\"ledger_name\":\"General Expenses\",\"display_name\":\"General Expenses\",\"nominal_code\":8200,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:14Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":61},{\"id\":62,\"included_in_chart\":true,\"ledger_name\":\"Exchange rate gain/(loss)\",\"display_name\":\"Exchange rate gain/(loss)\",\"nominal_code\":8211,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:14Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":62},{\"id\":48,\"included_in_chart\":true,\"ledger_name\":\"Dividend cost\",\"display_name\":\"Dividend cost\",\"nominal_code\":8900,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:14Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":48},{\"id\":207,\"included_in_chart\":true,\"ledger_name\":\"Opening Balances\",\"display_name\":\"Opening Balances Control Account\",\"nominal_code\":9998,\"control_name\":\"OPENING_BALANCES\",\"last_updated\":\"2013-07-03T10:38:14Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":207},{\"id\":63,\"included_in_chart\":true,\"ledger_name\":\"Suspense\",\"display_name\":\"Corrections\",\"nominal_code\":9999,\"control_name\":\"SUSPENSE_CORRECTIONS\",\"last_updated\":\"2013-07-03T10:38:14Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":63}],\"template_last_updated\":\"2013-07-03T10:38:17Z\",\"ledger_account_last_updated\":\"2013-07-03T10:38:14Z\",\"$key\":2},{\"id\":3,\"sage_one_accounts_product\":\"Accounting\",\"name\":\"Small Business (IE)\",\"country\":{\"id\":101,\"name\":\"Ireland\",\"$key\":101},\"coa_accounts\":[{\"id\":72,\"included_in_chart\":true,\"ledger_name\":\"Assets - Cost\",\"display_name\":\"Assets - Cost\",\"nominal_code\":1,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:14Z\",\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":72},{\"id\":80,\"included_in_chart\":true,\"ledger_name\":\"Office equipment and IT - Cost\",\"display_name\":\"Office equipment and IT - Cost\",\"nominal_code\":30,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:14Z\",\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":80},{\"id\":81,\"included_in_chart\":true,\"ledger_name\":\"Office equipment and IT - Accumulated Depreciation\",\"display_name\":\"Office equipment and IT - Accumulated Depreciation\",\"nominal_code\":31,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":81},{\"id\":82,\"included_in_chart\":true,\"ledger_name\":\"Fixtures and fittings - Cost\",\"display_name\":\"Fixtures and fittings - Cost\",\"nominal_code\":40,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":82},{\"id\":83,\"included_in_chart\":true,\"ledger_name\":\"Fixtures and fittings - Accumulated Depreciation\",\"display_name\":\"Fixtures and fittings - Accumulated Depreciation\",\"nominal_code\":41,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":83},{\"id\":84,\"included_in_chart\":true,\"ledger_name\":\"Motor Vehicles - Cost\",\"display_name\":\"Motor Vehicles - Cost\",\"nominal_code\":50,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":84},{\"id\":85,\"included_in_chart\":true,\"ledger_name\":\"Motor Vehicles - Accumulated Depreciation\",\"display_name\":\"Motor Vehicles - Accumulated Depreciation\",\"nominal_code\":51,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":85},{\"id\":86,\"included_in_chart\":true,\"ledger_name\":\"Stock\",\"display_name\":\"Stock\",\"nominal_code\":1000,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":6,\"name\":\"Current Assets\",\"$key\":6},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":86},{\"id\":88,\"included_in_chart\":true,\"ledger_name\":\"Provision for doubtful debtors\",\"display_name\":\"Provision for doubtful debtors\",\"nominal_code\":1101,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":6,\"name\":\"Current Assets\",\"$key\":6},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":88},{\"id\":90,\"included_in_chart\":true,\"ledger_name\":\"Prepayments\",\"display_name\":\"Prepayments\",\"nominal_code\":1110,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":6,\"name\":\"Current Assets\",\"$key\":6},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":90},{\"id\":95,\"included_in_chart\":true,\"ledger_name\":\"Accruals\",\"display_name\":\"Accruals\",\"nominal_code\":2101,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":95},{\"id\":100,\"included_in_chart\":true,\"ledger_name\":\"Corporation Tax Liability\",\"display_name\":\"Corporation Tax Liability\",\"nominal_code\":2150,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":100},{\"id\":106,\"included_in_chart\":true,\"ledger_name\":\"Share capital\",\"display_name\":\"Share capital\",\"nominal_code\":3000,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":12,\"name\":\"Equity\",\"$key\":12},\"category_group\":{\"id\":5,\"name\":\"Capital\",\"$key\":5},\"$key\":106},{\"id\":110,\"included_in_chart\":true,\"ledger_name\":\"Sales Type A\",\"display_name\":\"Sales Type A\",\"nominal_code\":4000,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":1,\"name\":\"Sales\",\"$key\":1},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":110},{\"id\":209,\"included_in_chart\":true,\"ledger_name\":\"Sales Discounts\",\"display_name\":\"Sales Discounts\",\"nominal_code\":4009,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":1,\"name\":\"Sales\",\"$key\":1},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":209},{\"id\":210,\"included_in_chart\":true,\"ledger_name\":\"Sale of Assets\",\"display_name\":\"Sale of Assets\",\"nominal_code\":4200,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":2,\"name\":\"Other Income\",\"$key\":2},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":210},{\"id\":211,\"included_in_chart\":true,\"ledger_name\":\"Late Payment Charges\",\"display_name\":\"Late Payment Charges\",\"nominal_code\":4400,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":2,\"name\":\"Other Income\",\"$key\":2},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":211},{\"id\":212,\"included_in_chart\":true,\"ledger_name\":\"Carriage on Sales\",\"display_name\":\"Carriage on Sales\",\"nominal_code\":4905,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":1,\"name\":\"Sales\",\"$key\":1},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":212},{\"id\":116,\"included_in_chart\":true,\"ledger_name\":\"Cost of sales - goods\",\"display_name\":\"Cost of sales - goods\",\"nominal_code\":5000,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":3,\"name\":\"Direct Expenses\",\"$key\":3},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":116},{\"id\":213,\"included_in_chart\":true,\"ledger_name\":\"Purchase Discounts\",\"display_name\":\"Purchase Discounts\",\"nominal_code\":5009,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":3,\"name\":\"Direct Expenses\",\"$key\":3},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":213},{\"id\":117,\"included_in_chart\":true,\"ledger_name\":\"Cost of sales - materials\",\"display_name\":\"Cost of sales - materials\",\"nominal_code\":5010,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":3,\"name\":\"Direct Expenses\",\"$key\":3},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":117},{\"id\":118,\"included_in_chart\":true,\"ledger_name\":\"Cost of sales - delivery\",\"display_name\":\"Cost of sales - delivery\",\"nominal_code\":5015,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":3,\"name\":\"Direct Expenses\",\"$key\":3},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":118},{\"id\":214,\"included_in_chart\":true,\"ledger_name\":\"Carriage on Purchases\",\"display_name\":\"Carriage on Purchases\",\"nominal_code\":5100,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":3,\"name\":\"Direct Expenses\",\"$key\":3},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":214},{\"id\":121,\"included_in_chart\":true,\"ledger_name\":\"Marketing\",\"display_name\":\"Marketing\",\"nominal_code\":6200,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":121},{\"id\":157,\"included_in_chart\":true,\"ledger_name\":\"Universal Social Charge\",\"display_name\":\"Universal Social Charge\",\"nominal_code\":2212,\"control_name\":\"UNIVERSAL_SOCIAL_CHARGE\",\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":157},{\"id\":123,\"included_in_chart\":true,\"ledger_name\":\"Rent and rates\",\"display_name\":\"Rent and rates\",\"nominal_code\":7100,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":123},{\"id\":124,\"included_in_chart\":true,\"ledger_name\":\"Gas and electric\",\"display_name\":\"Gas and electric\",\"nominal_code\":7200,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":124},{\"id\":125,\"included_in_chart\":true,\"ledger_name\":\"Motor Expenses\",\"display_name\":\"Motor Expenses\",\"nominal_code\":7300,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":125},{\"id\":126,\"included_in_chart\":true,\"ledger_name\":\"Travel and Entertainment\",\"display_name\":\"Travel and Entertainment\",\"nominal_code\":7400,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":126},{\"id\":142,\"included_in_chart\":true,\"ledger_name\":\"Office costs\",\"display_name\":\"Office costs\",\"nominal_code\":7500,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":142},{\"id\":127,\"included_in_chart\":true,\"ledger_name\":\"Legal and Professional\",\"display_name\":\"Legal and Professional\",\"nominal_code\":7600,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":127},{\"id\":128,\"included_in_chart\":true,\"ledger_name\":\"Insurance\",\"display_name\":\"Insurance\",\"nominal_code\":7610,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":128},{\"id\":141,\"included_in_chart\":true,\"ledger_name\":\"Repairs and renewals\",\"display_name\":\"Repairs and renewals\",\"nominal_code\":7800,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":141},{\"id\":130,\"included_in_chart\":true,\"ledger_name\":\"Depreciation\",\"display_name\":\"Depreciation\",\"nominal_code\":8000,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":5,\"name\":\"Depreciation\",\"$key\":5},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":130},{\"id\":131,\"included_in_chart\":true,\"ledger_name\":\"Bad Debts\",\"display_name\":\"Bad Debts\",\"nominal_code\":8100,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":131},{\"id\":132,\"included_in_chart\":true,\"ledger_name\":\"General Expenses\",\"display_name\":\"General Expenses\",\"nominal_code\":8200,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":132},{\"id\":133,\"included_in_chart\":true,\"ledger_name\":\"Exchange rate gain/(loss)\",\"display_name\":\"Exchange rate gain/(loss)\",\"nominal_code\":8211,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":133},{\"id\":119,\"included_in_chart\":true,\"ledger_name\":\"Dividend cost\",\"display_name\":\"Dividend cost\",\"nominal_code\":8900,\"control_name\":null,\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":119},{\"id\":153,\"included_in_chart\":true,\"ledger_name\":\"Attachments\",\"display_name\":\"Attachments\",\"nominal_code\":2215,\"control_name\":\"ATTACHMENTS\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":153},{\"id\":129,\"included_in_chart\":true,\"ledger_name\":\"Bank charges and interest\",\"display_name\":\"Bank charges and interest\",\"nominal_code\":7900,\"control_name\":\"BANK_CHARGES_AND_INTEREST\",\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":129},{\"id\":109,\"included_in_chart\":true,\"ledger_name\":\"Drawings - equity\",\"display_name\":\"Drawings - equity\",\"nominal_code\":3260,\"control_name\":\"DRAWINGS_EQUITY\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":12,\"name\":\"Equity\",\"$key\":12},\"category_group\":{\"id\":5,\"name\":\"Capital\",\"$key\":5},\"$key\":109},{\"id\":122,\"included_in_chart\":true,\"ledger_name\":\"Employee costs\",\"display_name\":\"Employee costs\",\"nominal_code\":7000,\"control_name\":\"EMPLOYEE_COSTS\",\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":122},{\"id\":140,\"included_in_chart\":true,\"ledger_name\":\"Employers PRSI\",\"display_name\":\"Employers PRSI\",\"nominal_code\":7006,\"control_name\":\"EMPLOYERS_NIC\",\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":140},{\"id\":155,\"included_in_chart\":true,\"ledger_name\":\"Employer's Pension\",\"display_name\":\"Employer's Pension\",\"nominal_code\":7007,\"control_name\":\"EMPLOYERS_PENSION\",\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":155},{\"id\":158,\"included_in_chart\":true,\"ledger_name\":\"Local Property Tax (LPT)\",\"display_name\":\"Local Property Tax (LPT)\",\"nominal_code\":2216,\"control_name\":\"LOCAL_PROPERTY_TAX\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":158},{\"id\":139,\"included_in_chart\":true,\"ledger_name\":\"Net Wages\",\"display_name\":\"Net Wages\",\"nominal_code\":2220,\"control_name\":\"NET_WAGES\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":139},{\"id\":101,\"included_in_chart\":true,\"ledger_name\":\"Other taxes to pay to Revenue\",\"display_name\":\"Other taxes to pay to Revenue\",\"nominal_code\":2211,\"control_name\":\"NI\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":101},{\"id\":215,\"included_in_chart\":true,\"ledger_name\":\"Opening Balances\",\"display_name\":\"Opening Balances Control Account\",\"nominal_code\":9998,\"control_name\":\"OPENING_BALANCES\",\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":215},{\"id\":156,\"included_in_chart\":true,\"ledger_name\":\"Other Deductions\",\"display_name\":\"Other Deductions\",\"nominal_code\":7009,\"control_name\":\"OTHER_DEDUCTIONS\",\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":156},{\"id\":115,\"included_in_chart\":true,\"ledger_name\":\"Other income\",\"display_name\":\"Other income\",\"nominal_code\":4900,\"control_name\":\"OTHER_INCOME\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":2,\"name\":\"Other Income\",\"$key\":2},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":115},{\"id\":108,\"included_in_chart\":true,\"ledger_name\":\"Capital introduced\",\"display_name\":\"Capital introduced\",\"nominal_code\":3200,\"control_name\":\"OWN_INVEST\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":12,\"name\":\"Equity\",\"$key\":12},\"category_group\":{\"id\":5,\"name\":\"Capital\",\"$key\":5},\"$key\":108},{\"id\":138,\"included_in_chart\":true,\"ledger_name\":\"PAYE and Social Welfare Costs\",\"display_name\":\"PAYE and Social Welfare Costs\",\"nominal_code\":2210,\"control_name\":\"PAYE\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":138},{\"id\":154,\"included_in_chart\":true,\"ledger_name\":\"Pension\",\"display_name\":\"Pension\",\"nominal_code\":2230,\"control_name\":\"PENSION\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":154},{\"id\":107,\"included_in_chart\":true,\"ledger_name\":\"Profit and Loss Account\",\"display_name\":\"Profit and Loss Account\",\"nominal_code\":3100,\"control_name\":\"PROFIT_AND_LOSS\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":12,\"name\":\"Equity\",\"$key\":12},\"category_group\":{\"id\":5,\"name\":\"Capital\",\"$key\":5},\"$key\":107},{\"id\":152,\"included_in_chart\":true,\"ledger_name\":\"Student Loan\",\"display_name\":\"Student Loan\",\"nominal_code\":2214,\"control_name\":\"STUDENT_LOAN\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":152},{\"id\":134,\"included_in_chart\":true,\"ledger_name\":\"Suspense\",\"display_name\":\"Corrections\",\"nominal_code\":9999,\"control_name\":\"SUSPENSE_CORRECTIONS\",\"last_updated\":\"2013-07-03T10:38:16Z\",\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":134},{\"id\":208,\"included_in_chart\":true,\"ledger_name\":\"VAT Allocations \u0026 Adjustments\",\"display_name\":\"VAT Allocations \u0026 Adjustments\",\"nominal_code\":2203,\"control_name\":\"TAX_ALLOCATIONS_AND_ADJUSTMENTS\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":208},{\"id\":97,\"included_in_chart\":true,\"ledger_name\":\"VAT Liability\",\"display_name\":\"VAT Liability\",\"nominal_code\":2202,\"control_name\":\"TAX_LIABILITY\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":97},{\"id\":98,\"included_in_chart\":true,\"ledger_name\":\"VAT on Purchases\",\"display_name\":\"VAT on Purchases\",\"nominal_code\":2201,\"control_name\":\"TAX_ON_PURCHASES\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":98},{\"id\":99,\"included_in_chart\":true,\"ledger_name\":\"VAT on Sales\",\"display_name\":\"VAT on Sales\",\"nominal_code\":2200,\"control_name\":\"TAX_ON_SALES\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":99},{\"id\":136,\"included_in_chart\":true,\"ledger_name\":\"VAT on Sales - Holding Account\",\"display_name\":\"VAT on Sales - Holding Account\",\"nominal_code\":2205,\"control_name\":\"TAX_ON_SALES_HOLDING\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":136},{\"id\":94,\"included_in_chart\":true,\"ledger_name\":\"Trade Creditors\",\"display_name\":\"Trade Creditors\",\"nominal_code\":2100,\"control_name\":\"TRADE_CREDITORS\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":10,\"name\":\"Current Liability\",\"$key\":10},\"category_group\":{\"id\":4,\"name\":\"Liability\",\"$key\":4},\"$key\":94},{\"id\":87,\"included_in_chart\":true,\"ledger_name\":\"Trade Debtors\",\"display_name\":\"Trade Debtors\",\"nominal_code\":1100,\"control_name\":\"TRADE_DEBTORS\",\"last_updated\":\"2013-07-03T10:38:15Z\",\"category\":{\"id\":6,\"name\":\"Current Assets\",\"$key\":6},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":87}],\"template_last_updated\":\"2013-07-03T10:38:20Z\",\"ledger_account_last_updated\":\"2013-07-03T10:38:16Z\",\"$key\":3}]"},"http_version":null},"recorded_at":"Thu, 17 Dec 2015 09:33:12 GMT"}],"recorded_with":"VCR 3.0.0"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/contact_types/1","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["92f64736ac6ae9abe5f86f7dcfe0199a"],"X-Signature":["UJdaWXe7My4OEWv6CPCWS4JZ9oo="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 15:51:06 GMT"],"Etag":["\"9819b698395256fbf31c6ebd15a4c7dc\""],"Server":["openresty"],"Set-Cookie":["_session_id=5276337bee176e7a4d1fb75df29a34bf; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["4b794c13e72b0ac611eb71e452632346"],"X-Runtime":["0.021395"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["54"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":1,\"name\":\"Customer\",\"$key\":1}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 15:51:05 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/contact_types?$itemsPerPage=2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["bc0fb8158f9b20bf8e8731b808e7a11c"],"X-Signature":["AmZrJPupn7RFXGg2NO+4t/VFG0A="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 15:51:05 GMT"],"Etag":["\"ff9319d5756601525044c306ab0caf16\""],"Server":["openresty"],"Set-Cookie":["_session_id=94f7f0ae6cbb50c04803cbcd92e8221c; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["7ef0c699a515edd5ec1e372536c2c97b"],"X-Runtime":["0.027914"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["173"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":6,\"$startIndex\":0,\"$itemsPerPage\":6,\"$resources\":[{\"id\":1,\"name\":\"Customer\",\"$key\":1},{\"id\":2,\"name\":\"Supplier\",\"$key\":2},{\"id\":3,\"name\":\"Bank\",\"$key\":3},{\"id\":4,\"name\":\"Accounts\",\"$key\":4},{\"id\":5,\"name\":\"Sales\",\"$key\":5},{\"id\":6,\"name\":\"Purchasing\",\"$key\":6}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 15:51:05 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/contact_types","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["2b664d68b8f0a1f50529cfdba529e0e8"],"X-Signature":["7HwGIpyDYwkzEdA+ryDYQ4waAgU="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 15:51:05 GMT"],"Etag":["\"b0da8e7e7f234e99643dc623e053466c\""],"Server":["openresty"],"Set-Cookie":["_session_id=d46295c3632b53b3d2b0bb7dee40f01d; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["c0d2eb8d7a2f43555ec9114700d0031a"],"X-Runtime":["0.025247"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["176"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":6,\"$startIndex\":0,\"$itemsPerPage\":20,\"$resources\":[{\"id\":1,\"name\":\"Customer\",\"$key\":1},{\"id\":2,\"name\":\"Supplier\",\"$key\":2},{\"id\":3,\"name\":\"Bank\",\"$key\":3},{\"id\":4,\"name\":\"Accounts\",\"$key\":4},{\"id\":5,\"name\":\"Sales\",\"$key\":5},{\"id\":6,\"name\":\"Purchasing\",\"$key\":6}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 15:51:05 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/contacts/51","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["fac6f401bcca87b12053f3e8b06f25a9"],"X-Signature":["qg5UbAVJwTqInLfT2i8yX5mVvNs="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 14:24:16 GMT"],"Etag":["\"65a15856346f2aac8cba037674892537\""],"Server":["openresty"],"Set-Cookie":["_session_id=8c960ac008f7e66b04892c47d8d3f19e; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["ed0fde9a0535e1b29a65252ee62846ff"],"X-Runtime":["0.046494"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["247"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":51,\"company_name\":\"CUST0-GB\",\"name\":\"Main Contact\",\"name_and_company_name\":\"CUST0-GB (Main Contact)\",\"contact_type\":{\"id\":1,\"name\":\"CUSTOMER\",\"scope\":1},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"id\":218,\"$key\":218},\"$key\":31},\"delivery_address\":{\"$key\":null},\"lock_version\":0,\"$key\":51}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 14:24:16 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/contacts?$itemsPerPage=2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["dd218ba0175cf4125e95073b670d13af"],"X-Signature":["P7ssIrtdhQimRKVmJZ3EqXCo2LE="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 15:26:07 GMT"],"Etag":["\"114fb2afed1838b672560dd6f1732700\""],"Server":["openresty"],"Set-Cookie":["_session_id=de1216515d89566b7da25bd363fe7192; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["400b4ef25e9f0ef06c8ff06c2b9a1d6c"],"X-Runtime":["0.128159"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["351"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":13,\"$startIndex\":0,\"$itemsPerPage\":2,\"$resources\":[{\"id\":51,\"company_name\":\"CUST0-GB\",\"name\":\"Bar\",\"name_and_company_name\":\"CUST0-GB (Bar)\",\"contact_type\":{\"id\":1,\"name\":\"CUSTOMER\",\"scope\":1},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"id\":218,\"$key\":218},\"$key\":31},\"delivery_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":197},\"lock_version\":3,\"$key\":51},{\"id\":53,\"company_name\":\"CUST1-IE\",\"name\":\"Main Contact\",\"name_and_company_name\":\"CUST1-IE (Main Contact)\",\"contact_type\":{\"id\":1,\"name\":\"CUSTOMER\",\"scope\":1},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"id\":101,\"$key\":101},\"$key\":32},\"delivery_address\":{\"$key\":null},\"lock_version\":0,\"$key\":53}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 15:26:07 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/contacts","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["313f889ee82f54c9cb65d5e4597ef0b3"],"X-Signature":["ggNT8JZKRIZJfEJFgK1t4b1O/zI="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 14:24:15 GMT"],"Etag":["\"de67cb14c505e874ff9e61e5be339275\""],"Server":["openresty"],"Set-Cookie":["_session_id=8de545586005d759f9ad072c385c170a; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["b0ee20af54a3b70229dfc89068f46b46"],"X-Runtime":["0.312543"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["597"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":12,\"$startIndex\":0,\"$itemsPerPage\":20,\"$resources\":[{\"id\":51,\"company_name\":\"CUST0-GB\",\"name\":\"Main Contact\",\"name_and_company_name\":\"CUST0-GB (Main Contact)\",\"contact_type\":{\"id\":1,\"name\":\"CUSTOMER\",\"scope\":1},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"id\":218,\"$key\":218},\"$key\":31},\"delivery_address\":{\"$key\":null},\"lock_version\":0,\"$key\":51},{\"id\":53,\"company_name\":\"CUST1-IE\",\"name\":\"Main Contact\",\"name_and_company_name\":\"CUST1-IE (Main Contact)\",\"contact_type\":{\"id\":1,\"name\":\"CUSTOMER\",\"scope\":1},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"id\":101,\"$key\":101},\"$key\":32},\"delivery_address\":{\"$key\":null},\"lock_version\":0,\"$key\":53},{\"id\":55,\"company_name\":\"CUST2-DE\",\"name\":\"Main Contact\",\"name_and_company_name\":\"CUST2-DE (Main Contact)\",\"contact_type\":{\"id\":1,\"name\":\"CUSTOMER\",\"scope\":1},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"id\":79,\"$key\":79},\"$key\":33},\"delivery_address\":{\"$key\":null},\"lock_version\":0,\"$key\":55},{\"id\":57,\"company_name\":\"CUST3-FR\",\"name\":\"Main Contact\",\"name_and_company_name\":\"CUST3-FR (Main Contact)\",\"contact_type\":{\"id\":1,\"name\":\"CUSTOMER\",\"scope\":1},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"id\":72,\"$key\":72},\"$key\":34},\"delivery_address\":{\"$key\":null},\"lock_version\":0,\"$key\":57},{\"id\":59,\"company_name\":\"CUST4-US\",\"name\":\"Main Contact\",\"name_and_company_name\":\"CUST4-US (Main Contact)\",\"contact_type\":{\"id\":1,\"name\":\"CUSTOMER\",\"scope\":1},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"id\":219,\"$key\":219},\"$key\":35},\"delivery_address\":{\"$key\":null},\"lock_version\":0,\"$key\":59},{\"id\":49,\"company_name\":\"HMRC Payments\",\"name\":\"Main Contact\",\"name_and_company_name\":\"HMRC Payments (Main Contact)\",\"contact_type\":{\"id\":2,\"name\":\"SUPPLIER\",\"scope\":2},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":30},\"delivery_address\":{\"$key\":null},\"lock_version\":0,\"$key\":49},{\"id\":47,\"company_name\":\"HMRC Reclaimed\",\"name\":\"Main Contact\",\"name_and_company_name\":\"HMRC Reclaimed (Main Contact)\",\"contact_type\":{\"id\":1,\"name\":\"CUSTOMER\",\"scope\":1},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":29},\"delivery_address\":{\"$key\":null},\"lock_version\":0,\"$key\":47},{\"id\":61,\"company_name\":\"SUPP0-GB\",\"name\":\"Main Contact\",\"name_and_company_name\":\"SUPP0-GB (Main Contact)\",\"contact_type\":{\"id\":2,\"name\":\"SUPPLIER\",\"scope\":2},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"id\":218,\"$key\":218},\"$key\":36},\"delivery_address\":{\"$key\":null},\"lock_version\":0,\"$key\":61},{\"id\":63,\"company_name\":\"SUPP1-IE\",\"name\":\"Main Contact\",\"name_and_company_name\":\"SUPP1-IE (Main Contact)\",\"contact_type\":{\"id\":2,\"name\":\"SUPPLIER\",\"scope\":2},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"id\":101,\"$key\":101},\"$key\":37},\"delivery_address\":{\"$key\":null},\"lock_version\":0,\"$key\":63},{\"id\":65,\"company_name\":\"SUPP2-DE\",\"name\":\"Main Contact\",\"name_and_company_name\":\"SUPP2-DE (Main Contact)\",\"contact_type\":{\"id\":2,\"name\":\"SUPPLIER\",\"scope\":2},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"id\":79,\"$key\":79},\"$key\":38},\"delivery_address\":{\"$key\":null},\"lock_version\":0,\"$key\":65},{\"id\":67,\"company_name\":\"SUPP3-FR\",\"name\":\"Main Contact\",\"name_and_company_name\":\"SUPP3-FR (Main Contact)\",\"contact_type\":{\"id\":2,\"name\":\"SUPPLIER\",\"scope\":2},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"id\":72,\"$key\":72},\"$key\":39},\"delivery_address\":{\"$key\":null},\"lock_version\":0,\"$key\":67},{\"id\":69,\"company_name\":\"SUPP4-US\",\"name\":\"Main Contact\",\"name_and_company_name\":\"SUPP4-US (Main Contact)\",\"contact_type\":{\"id\":2,\"name\":\"SUPPLIER\",\"scope\":2},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"id\":219,\"$key\":219},\"$key\":40},\"delivery_address\":{\"$key\":null},\"lock_version\":0,\"$key\":69}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 14:24:15 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/contacts","body":{"encoding":"UTF-8","string":"contact%5Bcontact_type_id%5D=1\u0026contact%5Bname%5D=Foo"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["9e042482b1117ccefcde0745a68d7da8"],"X-Signature":["QYAOWMZDptb24sVBLnmIyMOHrW8="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":201,"message":"Created"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 14:52:06 GMT"],"Etag":["\"478e4720a809aa131413a99110beec61\""],"Server":["openresty"],"Set-Cookie":["_session_id=6af4ac0088e87cb3a7bedcf4d0f78bf2; path=/; secure; HttpOnly"],"Status":["201"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["ce5697ec4cad2679110cabb786102eb6"],"X-Runtime":["0.410622"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["232"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":277,\"company_name\":\"Foo\",\"name\":\"Foo\",\"name_and_company_name\":\"Foo (Foo)\",\"contact_type\":{\"id\":1,\"name\":\"CUSTOMER\",\"scope\":1},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":195},\"delivery_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":196},\"lock_version\":2,\"$key\":277}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 14:52:05 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/contacts","body":{"encoding":"UTF-8","string":"contact%5Bcontact_type_id%5D=1"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["98ffa7592fb8733fa3d68060550a8e25"],"X-Signature":["mpRv/rxEe//nQQleqaNjFna6B+g="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":422,"message":"Unprocessable Entity"},"headers":{"Cache-Control":["no-cache"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 15:06:45 GMT"],"Server":["openresty"],"Set-Cookie":["_session_id=44cf771e13e9b51fc035269917a0549a; path=/; secure; HttpOnly"],"Status":["422"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["e25c3fd9c8f2296f16d5480429dbfa8f"],"X-Runtime":["0.079981"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["124"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$diagnoses\":[{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"This field is required.\",\"$source\":\"company\"}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 15:06:45 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"delete","uri":"https://api.sageone.com/accounts/v1/contacts/279","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["70cd3c64ef46c3ecdf006317b6ae4cd6"],"X-Signature":["u1nTz1+KbavJrhQL0sFZsdaR4xI="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 15:05:27 GMT"],"Etag":["\"e7ad9e49aac711eabc539c3c4d1fa4ae\""],"Server":["openresty"],"Set-Cookie":["_session_id=ce46f593fa0fbd622230009aa8ecae9a; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["d38cb20616b7fce347877d851cb98d9d"],"X-Runtime":["0.346671"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["232"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":279,\"company_name\":\"Foo\",\"name\":\"Foo\",\"name_and_company_name\":\"Foo (Foo)\",\"contact_type\":{\"id\":1,\"name\":\"CUSTOMER\",\"scope\":1},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":198},\"delivery_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":199},\"lock_version\":2,\"$key\":279}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 15:05:27 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"put","uri":"https://api.sageone.com/accounts/v1/contacts/51","body":{"encoding":"UTF-8","string":"contact%5Bname%5D=Bar"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["4f95ef46c092a4d32b24674c641b6e58"],"X-Signature":["jK3Uri0ZDeNH5gj+NofemAf1Kvk="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 14:59:06 GMT"],"Etag":["\"269c326a198b8d0977d7bf79d9d0e4a4\""],"Server":["openresty"],"Set-Cookie":["_session_id=d92ece4e1b99f44330171e9ff064e2ff; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["a0a008d08f92dd9dd400f56243abba5a"],"X-Runtime":["0.188242"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["247"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":51,\"company_name\":\"CUST0-GB\",\"name\":\"Bar\",\"name_and_company_name\":\"CUST0-GB (Bar)\",\"contact_type\":{\"id\":1,\"name\":\"CUSTOMER\",\"scope\":1},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"id\":218,\"$key\":218},\"$key\":31},\"delivery_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":197},\"lock_version\":3,\"$key\":51}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 14:59:05 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/countries/1","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["0329b6388dba092280593a3c44033e24"],"X-Signature":["xM85EfuZfEEzDHSZZIJQm4uQ8XI="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 15:53:28 GMT"],"Etag":["\"b2fe1764692eb5acb15e97406c7034d6\""],"Server":["openresty"],"Set-Cookie":["_session_id=27612e98ef7df9717b950f94e32e4814; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["97f623f45dc6d427279dcbb49573a2e8"],"X-Runtime":["0.013483"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["64"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":1,\"code\":\"AF\",\"name\":\"Afghanistan\",\"$key\":1}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 15:53:28 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/countries?$itemsPerPage=2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["aec5a4916fde043d1f1feb7ffeab942b"],"X-Signature":["EXZbCerA8IndyXwRH8FPP3yqAq0="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 15:53:16 GMT"],"Etag":["\"527d6336e92e3a6ceeb1ea71ab789c71\""],"Server":["openresty"],"Set-Cookie":["_session_id=0a93b19bb593406579bca6955d47d4f1; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["7ecf1227e647facc712f8e69cf723233"],"X-Runtime":["0.342861"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["2731"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":191,\"$startIndex\":0,\"$itemsPerPage\":191,\"$resources\":[{\"id\":1,\"code\":\"AF\",\"name\":\"Afghanistan\",\"$key\":1},{\"id\":2,\"code\":\"AL\",\"name\":\"Albania\",\"$key\":2},{\"id\":3,\"code\":\"DZ\",\"name\":\"Algeria\",\"$key\":3},{\"id\":5,\"code\":\"AD\",\"name\":\"Andorra\",\"$key\":5},{\"id\":6,\"code\":\"AO\",\"name\":\"Angola\",\"$key\":6},{\"id\":10,\"code\":\"AR\",\"name\":\"Argentina\",\"$key\":10},{\"id\":11,\"code\":\"AM\",\"name\":\"Armenia\",\"$key\":11},{\"id\":12,\"code\":\"AW\",\"name\":\"Aruba\",\"$key\":12},{\"id\":13,\"code\":\"AU\",\"name\":\"Australia\",\"$key\":13},{\"id\":14,\"code\":\"AT\",\"name\":\"Austria\",\"$key\":14},{\"id\":15,\"code\":\"AZ\",\"name\":\"Azerbaijan\",\"$key\":15},{\"id\":16,\"code\":\"BS\",\"name\":\"Bahamas\",\"$key\":16},{\"id\":17,\"code\":\"BH\",\"name\":\"Bahrain\",\"$key\":17},{\"id\":18,\"code\":\"BD\",\"name\":\"Bangladesh\",\"$key\":18},{\"id\":19,\"code\":\"BB\",\"name\":\"Barbados\",\"$key\":19},{\"id\":20,\"code\":\"BY\",\"name\":\"Belarus\",\"$key\":20},{\"id\":21,\"code\":\"BE\",\"name\":\"Belgium\",\"$key\":21},{\"id\":22,\"code\":\"BZ\",\"name\":\"Belize\",\"$key\":22},{\"id\":23,\"code\":\"BJ\",\"name\":\"Benin\",\"$key\":23},{\"id\":24,\"code\":\"BM\",\"name\":\"Bermuda\",\"$key\":24},{\"id\":25,\"code\":\"BT\",\"name\":\"Bhutan\",\"$key\":25},{\"id\":26,\"code\":\"BO\",\"name\":\"Bolivia\",\"$key\":26},{\"id\":27,\"code\":\"BA\",\"name\":\"Bosnia and Herzegovina\",\"$key\":27},{\"id\":28,\"code\":\"BW\",\"name\":\"Botswana\",\"$key\":28},{\"id\":30,\"code\":\"BR\",\"name\":\"Brazil\",\"$key\":30},{\"id\":32,\"code\":\"BN\",\"name\":\"Brunei Darussalam\",\"$key\":32},{\"id\":33,\"code\":\"BG\",\"name\":\"Bulgaria\",\"$key\":33},{\"id\":34,\"code\":\"BF\",\"name\":\"Burkina Faso\",\"$key\":34},{\"id\":35,\"code\":\"BI\",\"name\":\"Burundi\",\"$key\":35},{\"id\":36,\"code\":\"KH\",\"name\":\"Cambodia\",\"$key\":36},{\"id\":37,\"code\":\"CM\",\"name\":\"Cameroon\",\"$key\":37},{\"id\":38,\"code\":\"CA\",\"name\":\"Canada\",\"$key\":38},{\"id\":39,\"code\":\"CV\",\"name\":\"Cape Verde\",\"$key\":39},{\"id\":40,\"code\":\"KY\",\"name\":\"Cayman Islands\",\"$key\":40},{\"id\":41,\"code\":\"CF\",\"name\":\"Central African Republic\",\"$key\":41},{\"id\":42,\"code\":\"TD\",\"name\":\"Chad\",\"$key\":42},{\"id\":43,\"code\":\"CL\",\"name\":\"Chile\",\"$key\":43},{\"id\":44,\"code\":\"CN\",\"name\":\"China\",\"$key\":44},{\"id\":47,\"code\":\"CO\",\"name\":\"Colombia\",\"$key\":47},{\"id\":48,\"code\":\"KM\",\"name\":\"Comoros\",\"$key\":48},{\"id\":49,\"code\":\"CG\",\"name\":\"Congo\",\"$key\":49},{\"id\":51,\"code\":\"CR\",\"name\":\"Costa Rica\",\"$key\":51},{\"id\":52,\"code\":\"HR\",\"name\":\"Croatia\",\"$key\":52},{\"id\":53,\"code\":\"CU\",\"name\":\"Cuba\",\"$key\":53},{\"id\":54,\"code\":\"CY\",\"name\":\"Cyprus\",\"$key\":54},{\"id\":55,\"code\":\"CZ\",\"name\":\"Czech Republic\",\"$key\":55},{\"id\":56,\"code\":\"DK\",\"name\":\"Denmark\",\"$key\":56},{\"id\":57,\"code\":\"DJ\",\"name\":\"Djibouti\",\"$key\":57},{\"id\":58,\"code\":\"DM\",\"name\":\"Dominica\",\"$key\":58},{\"id\":59,\"code\":\"DO\",\"name\":\"Dominican Republic\",\"$key\":59},{\"id\":60,\"code\":\"TP\",\"name\":\"East Timor\",\"$key\":60},{\"id\":61,\"code\":\"EC\",\"name\":\"Ecuador\",\"$key\":61},{\"id\":62,\"code\":\"EG\",\"name\":\"Egypt\",\"$key\":62},{\"id\":63,\"code\":\"SV\",\"name\":\"El Salvador\",\"$key\":63},{\"id\":64,\"code\":\"GQ\",\"name\":\"Equatorial Guinea\",\"$key\":64},{\"id\":65,\"code\":\"ER\",\"name\":\"Eritrea\",\"$key\":65},{\"id\":66,\"code\":\"EE\",\"name\":\"Estonia\",\"$key\":66},{\"id\":67,\"code\":\"ET\",\"name\":\"Ethiopia\",\"$key\":67},{\"id\":70,\"code\":\"FJ\",\"name\":\"Fiji\",\"$key\":70},{\"id\":71,\"code\":\"FI\",\"name\":\"Finland\",\"$key\":71},{\"id\":72,\"code\":\"FR\",\"name\":\"France\",\"$key\":72},{\"id\":76,\"code\":\"GA\",\"name\":\"Gabon\",\"$key\":76},{\"id\":77,\"code\":\"GM\",\"name\":\"Gambia\",\"$key\":77},{\"id\":78,\"code\":\"GE\",\"name\":\"Georgia\",\"$key\":78},{\"id\":79,\"code\":\"DE\",\"name\":\"Germany\",\"$key\":79},{\"id\":80,\"code\":\"GH\",\"name\":\"Ghana\",\"$key\":80},{\"id\":81,\"code\":\"GI\",\"name\":\"Gibraltar\",\"$key\":81},{\"id\":82,\"code\":\"GR\",\"name\":\"Greece\",\"$key\":82},{\"id\":84,\"code\":\"GD\",\"name\":\"Grenada\",\"$key\":84},{\"id\":85,\"code\":\"GP\",\"name\":\"Guadaloupe\",\"$key\":85},{\"id\":86,\"code\":\"GU\",\"name\":\"Guam\",\"$key\":86},{\"id\":87,\"code\":\"GT\",\"name\":\"Guatemala\",\"$key\":87},{\"id\":88,\"code\":\"GN\",\"name\":\"Guinea\",\"$key\":88},{\"id\":90,\"code\":\"GY\",\"name\":\"Guyana\",\"$key\":90},{\"id\":91,\"code\":\"HT\",\"name\":\"Haiti\",\"$key\":91},{\"id\":93,\"code\":\"HN\",\"name\":\"Honduras\",\"$key\":93},{\"id\":94,\"code\":\"HK\",\"name\":\"Hong Kong\",\"$key\":94},{\"id\":95,\"code\":\"HU\",\"name\":\"Hungary\",\"$key\":95},{\"id\":96,\"code\":\"IS\",\"name\":\"Iceland\",\"$key\":96},{\"id\":97,\"code\":\"IN\",\"name\":\"India\",\"$key\":97},{\"id\":98,\"code\":\"ID\",\"name\":\"Indonesia\",\"$key\":98},{\"id\":99,\"code\":\"IR\",\"name\":\"Iran\",\"$key\":99},{\"id\":100,\"code\":\"IQ\",\"name\":\"Iraq\",\"$key\":100},{\"id\":101,\"code\":\"IE\",\"name\":\"Ireland\",\"$key\":101},{\"id\":102,\"code\":\"IL\",\"name\":\"Israel\",\"$key\":102},{\"id\":103,\"code\":\"IT\",\"name\":\"Italy\",\"$key\":103},{\"id\":104,\"code\":\"CI\",\"name\":\"Ivory Coast\",\"$key\":104},{\"id\":105,\"code\":\"JM\",\"name\":\"Jamaica\",\"$key\":105},{\"id\":106,\"code\":\"JP\",\"name\":\"Japan\",\"$key\":106},{\"id\":107,\"code\":\"JO\",\"name\":\"Jordan\",\"$key\":107},{\"id\":108,\"code\":\"KZ\",\"name\":\"Kazakhstan\",\"$key\":108},{\"id\":109,\"code\":\"KE\",\"name\":\"Kenya\",\"$key\":109},{\"id\":110,\"code\":\"KP\",\"name\":\"North Korea\",\"$key\":110},{\"id\":111,\"code\":\"KR\",\"name\":\"South Korea\",\"$key\":111},{\"id\":112,\"code\":\"KW\",\"name\":\"Kuwait\",\"$key\":112},{\"id\":113,\"code\":\"KG\",\"name\":\"Kyrgyzstan\",\"$key\":113},{\"id\":114,\"code\":\"LA\",\"name\":\"Laos\",\"$key\":114},{\"id\":115,\"code\":\"LV\",\"name\":\"Latvia\",\"$key\":115},{\"id\":116,\"code\":\"LN\",\"name\":\"Lebanon\",\"$key\":116},{\"id\":117,\"code\":\"LS\",\"name\":\"Lesotho\",\"$key\":117},{\"id\":118,\"code\":\"LR\",\"name\":\"Liberia\",\"$key\":118},{\"id\":119,\"code\":\"LY\",\"name\":\"Libya\",\"$key\":119},{\"id\":120,\"code\":\"LI\",\"name\":\"Liechtenstein\",\"$key\":120},{\"id\":121,\"code\":\"LT\",\"name\":\"Lithuania\",\"$key\":121},{\"id\":122,\"code\":\"LU\",\"name\":\"Luxembourg\",\"$key\":122},{\"id\":123,\"code\":\"MO\",\"name\":\"Macau\",\"$key\":123},{\"id\":124,\"code\":\"MK\",\"name\":\"Macedonia\",\"$key\":124},{\"id\":125,\"code\":\"MG\",\"name\":\"Madagascar\",\"$key\":125},{\"id\":126,\"code\":\"MW\",\"name\":\"Malawi\",\"$key\":126},{\"id\":127,\"code\":\"MY\",\"name\":\"Malaysia\",\"$key\":127},{\"id\":128,\"code\":\"MV\",\"name\":\"Maldives\",\"$key\":128},{\"id\":129,\"code\":\"ML\",\"name\":\"Mali\",\"$key\":129},{\"id\":130,\"code\":\"MT\",\"name\":\"Malta\",\"$key\":130},{\"id\":134,\"code\":\"MU\",\"name\":\"Mauritius\",\"$key\":134},{\"id\":136,\"code\":\"MX\",\"name\":\"Mexico\",\"$key\":136},{\"id\":138,\"code\":\"MD\",\"name\":\"Moldova\",\"$key\":138},{\"id\":139,\"code\":\"MC\",\"name\":\"Monaco\",\"$key\":139},{\"id\":140,\"code\":\"MN\",\"name\":\"Mongolia\",\"$key\":140},{\"id\":142,\"code\":\"MA\",\"name\":\"Morocco\",\"$key\":142},{\"id\":143,\"code\":\"MZ\",\"name\":\"Mozambique\",\"$key\":143},{\"id\":145,\"code\":\"NA\",\"name\":\"Namibia\",\"$key\":145},{\"id\":147,\"code\":\"NP\",\"name\":\"Nepal\",\"$key\":147},{\"id\":148,\"code\":\"NL\",\"name\":\"Netherlands\",\"$key\":148},{\"id\":149,\"code\":\"AN\",\"name\":\"Netherlands Antilles\",\"$key\":149},{\"id\":152,\"code\":\"NZ\",\"name\":\"New Zealand\",\"$key\":152},{\"id\":153,\"code\":\"NI\",\"name\":\"Nicaragua\",\"$key\":153},{\"id\":154,\"code\":\"NE\",\"name\":\"Niger\",\"$key\":154},{\"id\":155,\"code\":\"NG\",\"name\":\"Nigeria\",\"$key\":155},{\"id\":158,\"code\":\"NO\",\"name\":\"Norway\",\"$key\":158},{\"id\":159,\"code\":\"OM\",\"name\":\"Oman\",\"$key\":159},{\"id\":160,\"code\":\"PK\",\"name\":\"Pakistan\",\"$key\":160},{\"id\":162,\"code\":\"PA\",\"name\":\"Panama\",\"$key\":162},{\"id\":163,\"code\":\"PG\",\"name\":\"Papua New Guinea\",\"$key\":163},{\"id\":164,\"code\":\"PY\",\"name\":\"Paraguay\",\"$key\":164},{\"id\":165,\"code\":\"PE\",\"name\":\"Peru\",\"$key\":165},{\"id\":166,\"code\":\"PH\",\"name\":\"Philippines\",\"$key\":166},{\"id\":168,\"code\":\"PL\",\"name\":\"Poland\",\"$key\":168},{\"id\":169,\"code\":\"PT\",\"name\":\"Portugal\",\"$key\":169},{\"id\":170,\"code\":\"PR\",\"name\":\"Puerto Rico\",\"$key\":170},{\"id\":171,\"code\":\"QA\",\"name\":\"Qatar\",\"$key\":171},{\"id\":173,\"code\":\"RO\",\"name\":\"Romania\",\"$key\":173},{\"id\":174,\"code\":\"RU\",\"name\":\"Russia\",\"$key\":174},{\"id\":175,\"code\":\"RW\",\"name\":\"Rwanda\",\"$key\":175},{\"id\":178,\"code\":\"LC\",\"name\":\"St. Lucia\",\"$key\":178},{\"id\":181,\"code\":\"WS\",\"name\":\"Samoa\",\"$key\":181},{\"id\":182,\"code\":\"SM\",\"name\":\"San Marino\",\"$key\":182},{\"id\":183,\"code\":\"ST\",\"name\":\"Sao Tome and Principe\",\"$key\":183},{\"id\":184,\"code\":\"SA\",\"name\":\"Saudi Arabia\",\"$key\":184},{\"id\":185,\"code\":\"SN\",\"name\":\"Senegal\",\"$key\":185},{\"id\":186,\"code\":\"SC\",\"name\":\"Seychelles\",\"$key\":186},{\"id\":187,\"code\":\"SL\",\"name\":\"Sierra Leone\",\"$key\":187},{\"id\":188,\"code\":\"SG\",\"name\":\"Singapore\",\"$key\":188},{\"id\":189,\"code\":\"SK\",\"name\":\"Slovakia\",\"$key\":189},{\"id\":190,\"code\":\"SI\",\"name\":\"Slovenia\",\"$key\":190},{\"id\":191,\"code\":\"SB\",\"name\":\"Solomon Islands\",\"$key\":191},{\"id\":192,\"code\":\"SO\",\"name\":\"Somalia\",\"$key\":192},{\"id\":193,\"code\":\"ZA\",\"name\":\"South Africa\",\"$key\":193},{\"id\":194,\"code\":\"ES\",\"name\":\"Spain\",\"$key\":194},{\"id\":195,\"code\":\"LK\",\"name\":\"Sri Lanka\",\"$key\":195},{\"id\":196,\"code\":\"SD\",\"name\":\"Sudan\",\"$key\":196},{\"id\":197,\"code\":\"SR\",\"name\":\"Surinam\",\"$key\":197},{\"id\":199,\"code\":\"SZ\",\"name\":\"Swaziland\",\"$key\":199},{\"id\":200,\"code\":\"SE\",\"name\":\"Sweden\",\"$key\":200},{\"id\":201,\"code\":\"CH\",\"name\":\"Switzerland\",\"$key\":201},{\"id\":202,\"code\":\"SY\",\"name\":\"Syria\",\"$key\":202},{\"id\":203,\"code\":\"TW\",\"name\":\"Taiwan\",\"$key\":203},{\"id\":204,\"code\":\"TJ\",\"name\":\"Tajikistan\",\"$key\":204},{\"id\":205,\"code\":\"TZ\",\"name\":\"Tanzania\",\"$key\":205},{\"id\":206,\"code\":\"TH\",\"name\":\"Thailand\",\"$key\":206},{\"id\":207,\"code\":\"TG\",\"name\":\"Togo\",\"$key\":207},{\"id\":209,\"code\":\"TO\",\"name\":\"Tonga\",\"$key\":209},{\"id\":210,\"code\":\"TT\",\"name\":\"Trinidad and Tobago\",\"$key\":210},{\"id\":211,\"code\":\"TN\",\"name\":\"Tunisia\",\"$key\":211},{\"id\":212,\"code\":\"TR\",\"name\":\"Turkey\",\"$key\":212},{\"id\":215,\"code\":\"UG\",\"name\":\"Uganda\",\"$key\":215},{\"id\":216,\"code\":\"UA\",\"name\":\"Ukraine\",\"$key\":216},{\"id\":217,\"code\":\"AE\",\"name\":\"United Arab Emirates\",\"$key\":217},{\"id\":218,\"code\":\"GB\",\"name\":\"United Kingdom\",\"$key\":218},{\"id\":219,\"code\":\"US\",\"name\":\"United States\",\"$key\":219},{\"id\":221,\"code\":\"UY\",\"name\":\"Uruguay\",\"$key\":221},{\"id\":222,\"code\":\"UZ\",\"name\":\"Uzbekistan\",\"$key\":222},{\"id\":224,\"code\":\"VE\",\"name\":\"Venezuela\",\"$key\":224},{\"id\":225,\"code\":\"VN\",\"name\":\"Vietnam\",\"$key\":225},{\"id\":226,\"code\":\"VI\",\"name\":\"Virgin Islands U.S.\",\"$key\":226},{\"id\":228,\"code\":\"EH\",\"name\":\"Western Sahara\",\"$key\":228},{\"id\":229,\"code\":\"YE\",\"name\":\"Yemen\",\"$key\":229},{\"id\":231,\"code\":\"ZR\",\"name\":\"Zaire\",\"$key\":231},{\"id\":232,\"code\":\"ZM\",\"name\":\"Zambia\",\"$key\":232},{\"id\":233,\"code\":\"ZW\",\"name\":\"Zimbabwe\",\"$key\":233},{\"id\":234,\"code\":\"RS\",\"name\":\"Serbia\",\"$key\":234},{\"id\":235,\"code\":\"ME\",\"name\":\"Montenegro\",\"$key\":235}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 15:53:15 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/countries","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["394c1ab8a55775953460fbe79ce4a069"],"X-Signature":["1V6wceVvDY0pJcpVXIiEVkPcctI="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 15:53:15 GMT"],"Etag":["\"527d6336e92e3a6ceeb1ea71ab789c71\""],"Server":["openresty"],"Set-Cookie":["_session_id=233e4b5465924375e1ac35dd460bdac7; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["24f1de4f1b718f7543d2c0f4c33aa6dc"],"X-Runtime":["0.346955"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["2731"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":191,\"$startIndex\":0,\"$itemsPerPage\":191,\"$resources\":[{\"id\":1,\"code\":\"AF\",\"name\":\"Afghanistan\",\"$key\":1},{\"id\":2,\"code\":\"AL\",\"name\":\"Albania\",\"$key\":2},{\"id\":3,\"code\":\"DZ\",\"name\":\"Algeria\",\"$key\":3},{\"id\":5,\"code\":\"AD\",\"name\":\"Andorra\",\"$key\":5},{\"id\":6,\"code\":\"AO\",\"name\":\"Angola\",\"$key\":6},{\"id\":10,\"code\":\"AR\",\"name\":\"Argentina\",\"$key\":10},{\"id\":11,\"code\":\"AM\",\"name\":\"Armenia\",\"$key\":11},{\"id\":12,\"code\":\"AW\",\"name\":\"Aruba\",\"$key\":12},{\"id\":13,\"code\":\"AU\",\"name\":\"Australia\",\"$key\":13},{\"id\":14,\"code\":\"AT\",\"name\":\"Austria\",\"$key\":14},{\"id\":15,\"code\":\"AZ\",\"name\":\"Azerbaijan\",\"$key\":15},{\"id\":16,\"code\":\"BS\",\"name\":\"Bahamas\",\"$key\":16},{\"id\":17,\"code\":\"BH\",\"name\":\"Bahrain\",\"$key\":17},{\"id\":18,\"code\":\"BD\",\"name\":\"Bangladesh\",\"$key\":18},{\"id\":19,\"code\":\"BB\",\"name\":\"Barbados\",\"$key\":19},{\"id\":20,\"code\":\"BY\",\"name\":\"Belarus\",\"$key\":20},{\"id\":21,\"code\":\"BE\",\"name\":\"Belgium\",\"$key\":21},{\"id\":22,\"code\":\"BZ\",\"name\":\"Belize\",\"$key\":22},{\"id\":23,\"code\":\"BJ\",\"name\":\"Benin\",\"$key\":23},{\"id\":24,\"code\":\"BM\",\"name\":\"Bermuda\",\"$key\":24},{\"id\":25,\"code\":\"BT\",\"name\":\"Bhutan\",\"$key\":25},{\"id\":26,\"code\":\"BO\",\"name\":\"Bolivia\",\"$key\":26},{\"id\":27,\"code\":\"BA\",\"name\":\"Bosnia and Herzegovina\",\"$key\":27},{\"id\":28,\"code\":\"BW\",\"name\":\"Botswana\",\"$key\":28},{\"id\":30,\"code\":\"BR\",\"name\":\"Brazil\",\"$key\":30},{\"id\":32,\"code\":\"BN\",\"name\":\"Brunei Darussalam\",\"$key\":32},{\"id\":33,\"code\":\"BG\",\"name\":\"Bulgaria\",\"$key\":33},{\"id\":34,\"code\":\"BF\",\"name\":\"Burkina Faso\",\"$key\":34},{\"id\":35,\"code\":\"BI\",\"name\":\"Burundi\",\"$key\":35},{\"id\":36,\"code\":\"KH\",\"name\":\"Cambodia\",\"$key\":36},{\"id\":37,\"code\":\"CM\",\"name\":\"Cameroon\",\"$key\":37},{\"id\":38,\"code\":\"CA\",\"name\":\"Canada\",\"$key\":38},{\"id\":39,\"code\":\"CV\",\"name\":\"Cape Verde\",\"$key\":39},{\"id\":40,\"code\":\"KY\",\"name\":\"Cayman Islands\",\"$key\":40},{\"id\":41,\"code\":\"CF\",\"name\":\"Central African Republic\",\"$key\":41},{\"id\":42,\"code\":\"TD\",\"name\":\"Chad\",\"$key\":42},{\"id\":43,\"code\":\"CL\",\"name\":\"Chile\",\"$key\":43},{\"id\":44,\"code\":\"CN\",\"name\":\"China\",\"$key\":44},{\"id\":47,\"code\":\"CO\",\"name\":\"Colombia\",\"$key\":47},{\"id\":48,\"code\":\"KM\",\"name\":\"Comoros\",\"$key\":48},{\"id\":49,\"code\":\"CG\",\"name\":\"Congo\",\"$key\":49},{\"id\":51,\"code\":\"CR\",\"name\":\"Costa Rica\",\"$key\":51},{\"id\":52,\"code\":\"HR\",\"name\":\"Croatia\",\"$key\":52},{\"id\":53,\"code\":\"CU\",\"name\":\"Cuba\",\"$key\":53},{\"id\":54,\"code\":\"CY\",\"name\":\"Cyprus\",\"$key\":54},{\"id\":55,\"code\":\"CZ\",\"name\":\"Czech Republic\",\"$key\":55},{\"id\":56,\"code\":\"DK\",\"name\":\"Denmark\",\"$key\":56},{\"id\":57,\"code\":\"DJ\",\"name\":\"Djibouti\",\"$key\":57},{\"id\":58,\"code\":\"DM\",\"name\":\"Dominica\",\"$key\":58},{\"id\":59,\"code\":\"DO\",\"name\":\"Dominican Republic\",\"$key\":59},{\"id\":60,\"code\":\"TP\",\"name\":\"East Timor\",\"$key\":60},{\"id\":61,\"code\":\"EC\",\"name\":\"Ecuador\",\"$key\":61},{\"id\":62,\"code\":\"EG\",\"name\":\"Egypt\",\"$key\":62},{\"id\":63,\"code\":\"SV\",\"name\":\"El Salvador\",\"$key\":63},{\"id\":64,\"code\":\"GQ\",\"name\":\"Equatorial Guinea\",\"$key\":64},{\"id\":65,\"code\":\"ER\",\"name\":\"Eritrea\",\"$key\":65},{\"id\":66,\"code\":\"EE\",\"name\":\"Estonia\",\"$key\":66},{\"id\":67,\"code\":\"ET\",\"name\":\"Ethiopia\",\"$key\":67},{\"id\":70,\"code\":\"FJ\",\"name\":\"Fiji\",\"$key\":70},{\"id\":71,\"code\":\"FI\",\"name\":\"Finland\",\"$key\":71},{\"id\":72,\"code\":\"FR\",\"name\":\"France\",\"$key\":72},{\"id\":76,\"code\":\"GA\",\"name\":\"Gabon\",\"$key\":76},{\"id\":77,\"code\":\"GM\",\"name\":\"Gambia\",\"$key\":77},{\"id\":78,\"code\":\"GE\",\"name\":\"Georgia\",\"$key\":78},{\"id\":79,\"code\":\"DE\",\"name\":\"Germany\",\"$key\":79},{\"id\":80,\"code\":\"GH\",\"name\":\"Ghana\",\"$key\":80},{\"id\":81,\"code\":\"GI\",\"name\":\"Gibraltar\",\"$key\":81},{\"id\":82,\"code\":\"GR\",\"name\":\"Greece\",\"$key\":82},{\"id\":84,\"code\":\"GD\",\"name\":\"Grenada\",\"$key\":84},{\"id\":85,\"code\":\"GP\",\"name\":\"Guadaloupe\",\"$key\":85},{\"id\":86,\"code\":\"GU\",\"name\":\"Guam\",\"$key\":86},{\"id\":87,\"code\":\"GT\",\"name\":\"Guatemala\",\"$key\":87},{\"id\":88,\"code\":\"GN\",\"name\":\"Guinea\",\"$key\":88},{\"id\":90,\"code\":\"GY\",\"name\":\"Guyana\",\"$key\":90},{\"id\":91,\"code\":\"HT\",\"name\":\"Haiti\",\"$key\":91},{\"id\":93,\"code\":\"HN\",\"name\":\"Honduras\",\"$key\":93},{\"id\":94,\"code\":\"HK\",\"name\":\"Hong Kong\",\"$key\":94},{\"id\":95,\"code\":\"HU\",\"name\":\"Hungary\",\"$key\":95},{\"id\":96,\"code\":\"IS\",\"name\":\"Iceland\",\"$key\":96},{\"id\":97,\"code\":\"IN\",\"name\":\"India\",\"$key\":97},{\"id\":98,\"code\":\"ID\",\"name\":\"Indonesia\",\"$key\":98},{\"id\":99,\"code\":\"IR\",\"name\":\"Iran\",\"$key\":99},{\"id\":100,\"code\":\"IQ\",\"name\":\"Iraq\",\"$key\":100},{\"id\":101,\"code\":\"IE\",\"name\":\"Ireland\",\"$key\":101},{\"id\":102,\"code\":\"IL\",\"name\":\"Israel\",\"$key\":102},{\"id\":103,\"code\":\"IT\",\"name\":\"Italy\",\"$key\":103},{\"id\":104,\"code\":\"CI\",\"name\":\"Ivory Coast\",\"$key\":104},{\"id\":105,\"code\":\"JM\",\"name\":\"Jamaica\",\"$key\":105},{\"id\":106,\"code\":\"JP\",\"name\":\"Japan\",\"$key\":106},{\"id\":107,\"code\":\"JO\",\"name\":\"Jordan\",\"$key\":107},{\"id\":108,\"code\":\"KZ\",\"name\":\"Kazakhstan\",\"$key\":108},{\"id\":109,\"code\":\"KE\",\"name\":\"Kenya\",\"$key\":109},{\"id\":110,\"code\":\"KP\",\"name\":\"North Korea\",\"$key\":110},{\"id\":111,\"code\":\"KR\",\"name\":\"South Korea\",\"$key\":111},{\"id\":112,\"code\":\"KW\",\"name\":\"Kuwait\",\"$key\":112},{\"id\":113,\"code\":\"KG\",\"name\":\"Kyrgyzstan\",\"$key\":113},{\"id\":114,\"code\":\"LA\",\"name\":\"Laos\",\"$key\":114},{\"id\":115,\"code\":\"LV\",\"name\":\"Latvia\",\"$key\":115},{\"id\":116,\"code\":\"LN\",\"name\":\"Lebanon\",\"$key\":116},{\"id\":117,\"code\":\"LS\",\"name\":\"Lesotho\",\"$key\":117},{\"id\":118,\"code\":\"LR\",\"name\":\"Liberia\",\"$key\":118},{\"id\":119,\"code\":\"LY\",\"name\":\"Libya\",\"$key\":119},{\"id\":120,\"code\":\"LI\",\"name\":\"Liechtenstein\",\"$key\":120},{\"id\":121,\"code\":\"LT\",\"name\":\"Lithuania\",\"$key\":121},{\"id\":122,\"code\":\"LU\",\"name\":\"Luxembourg\",\"$key\":122},{\"id\":123,\"code\":\"MO\",\"name\":\"Macau\",\"$key\":123},{\"id\":124,\"code\":\"MK\",\"name\":\"Macedonia\",\"$key\":124},{\"id\":125,\"code\":\"MG\",\"name\":\"Madagascar\",\"$key\":125},{\"id\":126,\"code\":\"MW\",\"name\":\"Malawi\",\"$key\":126},{\"id\":127,\"code\":\"MY\",\"name\":\"Malaysia\",\"$key\":127},{\"id\":128,\"code\":\"MV\",\"name\":\"Maldives\",\"$key\":128},{\"id\":129,\"code\":\"ML\",\"name\":\"Mali\",\"$key\":129},{\"id\":130,\"code\":\"MT\",\"name\":\"Malta\",\"$key\":130},{\"id\":134,\"code\":\"MU\",\"name\":\"Mauritius\",\"$key\":134},{\"id\":136,\"code\":\"MX\",\"name\":\"Mexico\",\"$key\":136},{\"id\":138,\"code\":\"MD\",\"name\":\"Moldova\",\"$key\":138},{\"id\":139,\"code\":\"MC\",\"name\":\"Monaco\",\"$key\":139},{\"id\":140,\"code\":\"MN\",\"name\":\"Mongolia\",\"$key\":140},{\"id\":142,\"code\":\"MA\",\"name\":\"Morocco\",\"$key\":142},{\"id\":143,\"code\":\"MZ\",\"name\":\"Mozambique\",\"$key\":143},{\"id\":145,\"code\":\"NA\",\"name\":\"Namibia\",\"$key\":145},{\"id\":147,\"code\":\"NP\",\"name\":\"Nepal\",\"$key\":147},{\"id\":148,\"code\":\"NL\",\"name\":\"Netherlands\",\"$key\":148},{\"id\":149,\"code\":\"AN\",\"name\":\"Netherlands Antilles\",\"$key\":149},{\"id\":152,\"code\":\"NZ\",\"name\":\"New Zealand\",\"$key\":152},{\"id\":153,\"code\":\"NI\",\"name\":\"Nicaragua\",\"$key\":153},{\"id\":154,\"code\":\"NE\",\"name\":\"Niger\",\"$key\":154},{\"id\":155,\"code\":\"NG\",\"name\":\"Nigeria\",\"$key\":155},{\"id\":158,\"code\":\"NO\",\"name\":\"Norway\",\"$key\":158},{\"id\":159,\"code\":\"OM\",\"name\":\"Oman\",\"$key\":159},{\"id\":160,\"code\":\"PK\",\"name\":\"Pakistan\",\"$key\":160},{\"id\":162,\"code\":\"PA\",\"name\":\"Panama\",\"$key\":162},{\"id\":163,\"code\":\"PG\",\"name\":\"Papua New Guinea\",\"$key\":163},{\"id\":164,\"code\":\"PY\",\"name\":\"Paraguay\",\"$key\":164},{\"id\":165,\"code\":\"PE\",\"name\":\"Peru\",\"$key\":165},{\"id\":166,\"code\":\"PH\",\"name\":\"Philippines\",\"$key\":166},{\"id\":168,\"code\":\"PL\",\"name\":\"Poland\",\"$key\":168},{\"id\":169,\"code\":\"PT\",\"name\":\"Portugal\",\"$key\":169},{\"id\":170,\"code\":\"PR\",\"name\":\"Puerto Rico\",\"$key\":170},{\"id\":171,\"code\":\"QA\",\"name\":\"Qatar\",\"$key\":171},{\"id\":173,\"code\":\"RO\",\"name\":\"Romania\",\"$key\":173},{\"id\":174,\"code\":\"RU\",\"name\":\"Russia\",\"$key\":174},{\"id\":175,\"code\":\"RW\",\"name\":\"Rwanda\",\"$key\":175},{\"id\":178,\"code\":\"LC\",\"name\":\"St. Lucia\",\"$key\":178},{\"id\":181,\"code\":\"WS\",\"name\":\"Samoa\",\"$key\":181},{\"id\":182,\"code\":\"SM\",\"name\":\"San Marino\",\"$key\":182},{\"id\":183,\"code\":\"ST\",\"name\":\"Sao Tome and Principe\",\"$key\":183},{\"id\":184,\"code\":\"SA\",\"name\":\"Saudi Arabia\",\"$key\":184},{\"id\":185,\"code\":\"SN\",\"name\":\"Senegal\",\"$key\":185},{\"id\":186,\"code\":\"SC\",\"name\":\"Seychelles\",\"$key\":186},{\"id\":187,\"code\":\"SL\",\"name\":\"Sierra Leone\",\"$key\":187},{\"id\":188,\"code\":\"SG\",\"name\":\"Singapore\",\"$key\":188},{\"id\":189,\"code\":\"SK\",\"name\":\"Slovakia\",\"$key\":189},{\"id\":190,\"code\":\"SI\",\"name\":\"Slovenia\",\"$key\":190},{\"id\":191,\"code\":\"SB\",\"name\":\"Solomon Islands\",\"$key\":191},{\"id\":192,\"code\":\"SO\",\"name\":\"Somalia\",\"$key\":192},{\"id\":193,\"code\":\"ZA\",\"name\":\"South Africa\",\"$key\":193},{\"id\":194,\"code\":\"ES\",\"name\":\"Spain\",\"$key\":194},{\"id\":195,\"code\":\"LK\",\"name\":\"Sri Lanka\",\"$key\":195},{\"id\":196,\"code\":\"SD\",\"name\":\"Sudan\",\"$key\":196},{\"id\":197,\"code\":\"SR\",\"name\":\"Surinam\",\"$key\":197},{\"id\":199,\"code\":\"SZ\",\"name\":\"Swaziland\",\"$key\":199},{\"id\":200,\"code\":\"SE\",\"name\":\"Sweden\",\"$key\":200},{\"id\":201,\"code\":\"CH\",\"name\":\"Switzerland\",\"$key\":201},{\"id\":202,\"code\":\"SY\",\"name\":\"Syria\",\"$key\":202},{\"id\":203,\"code\":\"TW\",\"name\":\"Taiwan\",\"$key\":203},{\"id\":204,\"code\":\"TJ\",\"name\":\"Tajikistan\",\"$key\":204},{\"id\":205,\"code\":\"TZ\",\"name\":\"Tanzania\",\"$key\":205},{\"id\":206,\"code\":\"TH\",\"name\":\"Thailand\",\"$key\":206},{\"id\":207,\"code\":\"TG\",\"name\":\"Togo\",\"$key\":207},{\"id\":209,\"code\":\"TO\",\"name\":\"Tonga\",\"$key\":209},{\"id\":210,\"code\":\"TT\",\"name\":\"Trinidad and Tobago\",\"$key\":210},{\"id\":211,\"code\":\"TN\",\"name\":\"Tunisia\",\"$key\":211},{\"id\":212,\"code\":\"TR\",\"name\":\"Turkey\",\"$key\":212},{\"id\":215,\"code\":\"UG\",\"name\":\"Uganda\",\"$key\":215},{\"id\":216,\"code\":\"UA\",\"name\":\"Ukraine\",\"$key\":216},{\"id\":217,\"code\":\"AE\",\"name\":\"United Arab Emirates\",\"$key\":217},{\"id\":218,\"code\":\"GB\",\"name\":\"United Kingdom\",\"$key\":218},{\"id\":219,\"code\":\"US\",\"name\":\"United States\",\"$key\":219},{\"id\":221,\"code\":\"UY\",\"name\":\"Uruguay\",\"$key\":221},{\"id\":222,\"code\":\"UZ\",\"name\":\"Uzbekistan\",\"$key\":222},{\"id\":224,\"code\":\"VE\",\"name\":\"Venezuela\",\"$key\":224},{\"id\":225,\"code\":\"VN\",\"name\":\"Vietnam\",\"$key\":225},{\"id\":226,\"code\":\"VI\",\"name\":\"Virgin Islands U.S.\",\"$key\":226},{\"id\":228,\"code\":\"EH\",\"name\":\"Western Sahara\",\"$key\":228},{\"id\":229,\"code\":\"YE\",\"name\":\"Yemen\",\"$key\":229},{\"id\":231,\"code\":\"ZR\",\"name\":\"Zaire\",\"$key\":231},{\"id\":232,\"code\":\"ZM\",\"name\":\"Zambia\",\"$key\":232},{\"id\":233,\"code\":\"ZW\",\"name\":\"Zimbabwe\",\"$key\":233},{\"id\":234,\"code\":\"RS\",\"name\":\"Serbia\",\"$key\":234},{\"id\":235,\"code\":\"ME\",\"name\":\"Montenegro\",\"$key\":235}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 15:53:15 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/expenditures","body":{"encoding":"UTF-8","string":"expenditure%5Bamount%5D=58.0\u0026expenditure%5Bdate%5D=31%2F12%2F2014\u0026expenditure%5Bdestination_id%5D=7718\u0026expenditure%5Bpayment_method_id%5D=1\u0026expenditure%5Breference%5D=Foo\u0026expenditure%5Bsource_id%5D=7696\u0026expenditure%5Btax_amount%5D=2.9\u0026expenditure%5Btax_code_id%5D=2\u0026expenditure%5Btax_percentage_rate%5D=5.0"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["bdfbc556535409e3072cc774f24819ea"],"X-Signature":["7Eh5BfB3DR0bl6UNchYdlvFigvs="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":201,"message":"Created"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 11:29:39 GMT"],"Etag":["\"5d1e7ca3616cb00c1c7c021fca024485\""],"Server":["openresty"],"Status":["201"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["f6098d38d171467051268525d2f76de1"],"X-Runtime":["0.128698"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["238"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":2937,\"date\":\"31/12/2014\",\"invoice_date\":\"31/12/2014\",\"amount\":\"58.0\",\"tax_amount\":\"2.9\",\"gross_amount\":\"60.9\",\"tax_percentage_rate\":\"5.0\",\"tax_code\":{\"id\":2,\"$key\":2},\"tax_scheme_period_id\":117,\"reference\":\"Foo\",\"contact\":{\"$key\":null},\"source\":{\"id\":7696,\"$key\":7696},\"destination\":{\"id\":7718,\"$key\":7718},\"payment_method\":{\"id\":1,\"$key\":1},\"voided\":false,\"lock_version\":0,\"$key\":2937}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 11:29:39 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/expenditures","body":{"encoding":"UTF-8","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["46840ef996c548f7ca294c2429d82fae"],"X-Signature":["1EbnLf9KNd4rdC2wtfh6wtptgA8="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":422,"message":"Unprocessable Entity"},"headers":{"Cache-Control":["no-cache"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 11:29:39 GMT"],"Server":["openresty"],"Status":["422"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["59cf6a765bd60ed437253dddb045b41f"],"X-Runtime":["0.163966"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["222"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$diagnoses\":[{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"blank\",\"$source\":\"source\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"must be a bank ledger\",\"$source\":\"source\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"blank\",\"$source\":\"destination\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"should not be the same as source\",\"$source\":\"destination\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"must be a valid type of expense\",\"$source\":\"destination\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"invalid date\",\"$source\":\"date\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"blank\",\"$source\":\"amount\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"not a number\",\"$source\":\"amount\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"blank\",\"$source\":\"payment_method\"}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 11:29:39 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"delete","uri":"https://api.sageone.com/accounts/v1/expenditures/2938","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["bf514309168d2dcdda521478998bc4df"],"X-Signature":["gLuQC2gL33nbBBoeHkR5H55mBwI="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 11:32:57 GMT"],"Etag":["\"dca2ed96598c7256eea692dc90a82137\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["a061ae6b837ead1862618d90bad55dd0"],"X-Runtime":["0.104776"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["237"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":2938,\"date\":\"31/12/2014\",\"invoice_date\":\"31/12/2014\",\"amount\":\"58.0\",\"tax_amount\":\"2.9\",\"gross_amount\":\"60.9\",\"tax_percentage_rate\":\"5.0\",\"tax_code\":{\"id\":2,\"$key\":2},\"tax_scheme_period_id\":117,\"reference\":\"Foo\",\"contact\":{\"$key\":null},\"source\":{\"id\":7696,\"$key\":7696},\"destination\":{\"id\":7718,\"$key\":7718},\"payment_method\":{\"id\":1,\"$key\":1},\"voided\":true,\"lock_version\":1,\"$key\":2938}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 11:32:57 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/expenditures/2930","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["5233357d12a478fd0cb953b27169f1fb"],"X-Signature":["F6la2lqYZ6DjL11TW8Qflr7ZdqA="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 10:32:28 GMT"],"Etag":["\"9fd57146c186ce8c76bb8364ae019048\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["6a79b4f7957d241d4f3b3c3ab47f7c46"],"X-Runtime":["0.027023"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["246"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":2930,\"date\":\"31/12/2014\",\"invoice_date\":\"31/12/2014\",\"amount\":\"58.0\",\"tax_amount\":\"2.9\",\"gross_amount\":\"60.9\",\"tax_percentage_rate\":\"5.0\",\"tax_code\":{\"id\":2,\"$key\":2},\"tax_scheme_period_id\":117,\"reference\":\"Energy bill\",\"contact\":{\"$key\":null},\"source\":{\"id\":7696,\"$key\":7696},\"destination\":{\"id\":7718,\"$key\":7718},\"payment_method\":{\"id\":1,\"$key\":1},\"voided\":false,\"lock_version\":1,\"$key\":2930}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 10:32:28 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/expenditures?$itemsPerPage=2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["3b62a44b3cbfd0f47dd90a0a871edc83"],"X-Signature":["3iXq3RboWrzYUd4UD7q+doJWj4U="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 10:32:28 GMT"],"Etag":["\"f514bafae22288e9c81d61355bb40205\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["bdfc51f7926093f649c3bd0a1823871f"],"X-Runtime":["0.036021"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["326"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":2,\"$startIndex\":0,\"$itemsPerPage\":2,\"$resources\":[{\"id\":2930,\"date\":\"31/12/2014\",\"invoice_date\":\"31/12/2014\",\"amount\":\"58.0\",\"tax_amount\":\"2.9\",\"gross_amount\":\"60.9\",\"tax_percentage_rate\":\"5.0\",\"tax_code\":{\"id\":2,\"$key\":2},\"tax_scheme_period_id\":117,\"reference\":\"Energy bill\",\"contact\":{\"$key\":null},\"source\":{\"id\":7696,\"$key\":7696},\"destination\":{\"id\":7718,\"$key\":7718},\"payment_method\":{\"id\":1,\"$key\":1},\"voided\":false,\"lock_version\":1,\"$key\":2930},{\"id\":2931,\"date\":\"31/12/2014\",\"invoice_date\":\"31/12/2014\",\"amount\":\"34.0\",\"tax_amount\":\"1.7\",\"gross_amount\":\"35.7\",\"tax_percentage_rate\":\"5.0\",\"tax_code\":{\"id\":2,\"$key\":2},\"tax_scheme_period_id\":117,\"reference\":\"Gas bill\",\"contact\":{\"$key\":null},\"source\":{\"id\":7696,\"$key\":7696},\"destination\":{\"id\":7718,\"$key\":7718},\"payment_method\":{\"id\":1,\"$key\":1},\"voided\":false,\"lock_version\":0,\"$key\":2931}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 10:32:28 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/expenditures","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["1428608e00a193805e7acf61b7cecc7c"],"X-Signature":["sMDXF1ZwvntP5p9bSZsbKUrppUc="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 10:31:20 GMT"],"Etag":["\"194b1d1391be4faf36e5ec3a30a4f6ba\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["675e5931d0ae3b26e3c553020151fcad"],"X-Runtime":["0.035227"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["319"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":2,\"$startIndex\":0,\"$itemsPerPage\":20,\"$resources\":[{\"id\":2930,\"date\":\"31/12/2014\",\"invoice_date\":\"31/12/2014\",\"amount\":\"58.0\",\"tax_amount\":\"2.9\",\"gross_amount\":\"60.9\",\"tax_percentage_rate\":\"5.0\",\"tax_code\":{\"id\":2,\"$key\":2},\"tax_scheme_period_id\":117,\"reference\":\"\",\"contact\":{\"$key\":null},\"source\":{\"id\":7696,\"$key\":7696},\"destination\":{\"id\":7718,\"$key\":7718},\"payment_method\":{\"id\":1,\"$key\":1},\"voided\":false,\"lock_version\":0,\"$key\":2930},{\"id\":2931,\"date\":\"31/12/2014\",\"invoice_date\":\"31/12/2014\",\"amount\":\"34.0\",\"tax_amount\":\"1.7\",\"gross_amount\":\"35.7\",\"tax_percentage_rate\":\"5.0\",\"tax_code\":{\"id\":2,\"$key\":2},\"tax_scheme_period_id\":117,\"reference\":\"Gas bill\",\"contact\":{\"$key\":null},\"source\":{\"id\":7696,\"$key\":7696},\"destination\":{\"id\":7718,\"$key\":7718},\"payment_method\":{\"id\":1,\"$key\":1},\"voided\":false,\"lock_version\":0,\"$key\":2931}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 10:31:20 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"put","uri":"https://api.sageone.com/accounts/v1/expenditures/2930","body":{"encoding":"UTF-8","string":"expenditure%5Breference%5D=Bar"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["625496194b74147a990527938953f0bb"],"X-Signature":["AmKEAMaHasJMSBCJN+yLoyvYsqI="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 11:30:20 GMT"],"Etag":["\"10670db9a01cf43a66239a95455345dc\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["cd3bce82b1874c7af5022b79e5d7abb9"],"X-Runtime":["0.155915"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["238"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":2930,\"date\":\"31/12/2014\",\"invoice_date\":\"31/12/2014\",\"amount\":\"58.0\",\"tax_amount\":\"2.9\",\"gross_amount\":\"60.9\",\"tax_percentage_rate\":\"5.0\",\"tax_code\":{\"id\":2,\"$key\":2},\"tax_scheme_period_id\":117,\"reference\":\"Bar\",\"contact\":{\"$key\":null},\"source\":{\"id\":7696,\"$key\":7696},\"destination\":{\"id\":7718,\"$key\":7718},\"payment_method\":{\"id\":1,\"$key\":1},\"voided\":false,\"lock_version\":2,\"$key\":2930}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 11:30:20 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/expense_methods/1","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["7ff7493e7e22ab33907a62b667a3e3fe"],"X-Signature":["SUA8m9Fyl1usORQT59MCtz7oFX8="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 10:07:20 GMT"],"Etag":["\"4e14685cb766fba0a230c7f0fb79ae4e\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["49e6073a4626af5479a164b51a11c677"],"X-Runtime":["0.105016"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["65"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":1,\"name\":\"Bank Payment\",\"code\":\"BP\",\"$key\":1}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 10:07:20 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/expense_methods","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["da8cea5d5a5fbb0d96162de36dbd39bf"],"X-Signature":["KVcAtVFSLelbJiuB2tarhtwJGyo="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 10:04:46 GMT"],"Etag":["\"1a25be970faabf2be444159d52db9b51\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["399db9cb0f916becf2f25d0b966d0dbd"],"X-Runtime":["0.611895"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["160"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":3,\"$startIndex\":0,\"$itemsPerPage\":20,\"$resources\":[{\"id\":1,\"name\":\"Bank Payment\",\"code\":\"BP\",\"$key\":1},{\"id\":4,\"name\":\"Cash Payment\",\"code\":\"CP\",\"$key\":4},{\"id\":6,\"name\":\"Credit Card Payment\",\"code\":\"CCP\",\"$key\":6}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 10:04:46 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/income_methods/2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["194149473de008d00cb3dd409d9d53af"],"X-Signature":["LODGLXeShamqHV8AdpV1InlLh6c="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 10:12:54 GMT"],"Etag":["\"b86d52e86bbc63ba97699f0abceac51a\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["4cb368c4693c4792ce7cf0dadc0cfa77"],"X-Runtime":["0.022019"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["65"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":2,\"name\":\"Bank Receipt\",\"code\":\"BR\",\"$key\":2}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 10:12:54 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/income_methods?$itemsPerPage=2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["8932de2838159c95ab4038b5001f66b0"],"X-Signature":["YNG3Mc+u22bugu09kzhCdMhHY0A="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 10:10:12 GMT"],"Etag":["\"58288c6a00099b59c834d1bce14dc4d1\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["bccb6d6c78195412e2efc3b0b426eb54"],"X-Runtime":["0.103882"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["163"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":3,\"$startIndex\":0,\"$itemsPerPage\":3,\"$resources\":[{\"id\":2,\"name\":\"Bank Receipt\",\"code\":\"BR\",\"$key\":2},{\"id\":5,\"name\":\"Cash Receipt\",\"code\":\"CR\",\"$key\":5},{\"id\":10,\"name\":\"Cheque In Hand\",\"code\":\"CIH\",\"$key\":10}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 10:10:12 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/income_methods","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["36e9d3b9a773f1d4de5aef8152262fc4"],"X-Signature":["/ABI/oPRFSmvEsWI3aMBxycX138="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 10:10:12 GMT"],"Etag":["\"a697a23686f66812b5f185a93d0ae6dd\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["3ccb5b764bb108b80dd7cdebe4ff4f14"],"X-Runtime":["1.461627"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["164"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":3,\"$startIndex\":0,\"$itemsPerPage\":20,\"$resources\":[{\"id\":2,\"name\":\"Bank Receipt\",\"code\":\"BR\",\"$key\":2},{\"id\":5,\"name\":\"Cash Receipt\",\"code\":\"CR\",\"$key\":5},{\"id\":10,\"name\":\"Cheque In Hand\",\"code\":\"CIH\",\"$key\":10}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 10:10:12 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/expense_types/481","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["a6403339d7c37d058ca2e53b8e3afe68"],"X-Signature":["Z7q++nt+uVxjWKW8zTRQYsKQMs0="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:06:23 GMT"],"Etag":["\"bc4a074d58f1aaefcc033c6dc5c7f3de\""],"Server":["openresty"],"Set-Cookie":["_session_id=cc5f86985c89aeaa73768ead6084929c; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["4064e8f4afc841c09a8ea38ea29ad51e"],"X-Runtime":["0.024530"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["99"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":481,\"name\":\"Assets - Cost\",\"nominal_code\":1,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":481}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:06:22 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/expense_types?$itemsPerPage=2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["339c9a6fb5a7916cd4bf1fce4ac4f990"],"X-Signature":["493tqgzkohzzLgqxjISzy1qdcas="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:06:22 GMT"],"Etag":["\"7625a286fcd8b6d3f74fa71a322ee2b3\""],"Server":["openresty"],"Set-Cookie":["_session_id=4d766102a4feb8d80927a40f3686e8ff; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["b6b704daf38b499bf1fb1fb8bec40b8c"],"X-Runtime":["0.096959"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["571"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":19,\"$startIndex\":0,\"$itemsPerPage\":19,\"$resources\":[{\"id\":481,\"name\":\"Assets - Cost\",\"nominal_code\":1,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":481},{\"id\":498,\"name\":\"Cost of sales - goods\",\"nominal_code\":5000,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":498},{\"id\":499,\"name\":\"Cost of sales - materials\",\"nominal_code\":5010,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":499},{\"id\":500,\"name\":\"Cost of sales - delivery\",\"nominal_code\":5015,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":500},{\"id\":501,\"name\":\"Carriage on Purchases\",\"nominal_code\":5100,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":501},{\"id\":502,\"name\":\"Marketing\",\"nominal_code\":6200,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":502},{\"id\":503,\"name\":\"Rent and rates\",\"nominal_code\":7100,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":503},{\"id\":504,\"name\":\"Gas and electric\",\"nominal_code\":7200,\"tax_code\":{\"id\":2,\"name\":\"Lower Rate\",\"$key\":2},\"$key\":504},{\"id\":505,\"name\":\"Motor Expenses\",\"nominal_code\":7300,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":505},{\"id\":506,\"name\":\"Travel and Entertainment\",\"nominal_code\":7400,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":506},{\"id\":507,\"name\":\"Office costs\",\"nominal_code\":7500,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":507},{\"id\":508,\"name\":\"Legal and Professional\",\"nominal_code\":7600,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":508},{\"id\":509,\"name\":\"Insurance\",\"nominal_code\":7610,\"tax_code\":{\"id\":4,\"name\":\"Exempt\",\"$key\":4},\"$key\":509},{\"id\":510,\"name\":\"Repairs and renewals\",\"nominal_code\":7800,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":510},{\"id\":511,\"name\":\"Depreciation\",\"nominal_code\":8000,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":511},{\"id\":512,\"name\":\"Bad Debts\",\"nominal_code\":8100,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":512},{\"id\":513,\"name\":\"General Expenses\",\"nominal_code\":8200,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":513},{\"id\":514,\"name\":\"Exchange rate gain/(loss)\",\"nominal_code\":8211,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":514},{\"id\":515,\"name\":\"Dividend cost\",\"nominal_code\":8900,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":515}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:06:22 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/expense_types","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["1c8d766b107d09906a023fd14b123753"],"X-Signature":["pVAqoNLSHFrBjswS4NhmC4zpNI8="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:06:22 GMT"],"Etag":["\"8eb77da41a8504c99328a6f7f2f17395\""],"Server":["openresty"],"Set-Cookie":["_session_id=c9fda5aff5986cf2046c6d50fe8a3961; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["367b9f522f5f968d1bb8e13f7ebe62de"],"X-Runtime":["0.101134"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["572"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":19,\"$startIndex\":0,\"$itemsPerPage\":20,\"$resources\":[{\"id\":481,\"name\":\"Assets - Cost\",\"nominal_code\":1,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":481},{\"id\":498,\"name\":\"Cost of sales - goods\",\"nominal_code\":5000,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":498},{\"id\":499,\"name\":\"Cost of sales - materials\",\"nominal_code\":5010,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":499},{\"id\":500,\"name\":\"Cost of sales - delivery\",\"nominal_code\":5015,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":500},{\"id\":501,\"name\":\"Carriage on Purchases\",\"nominal_code\":5100,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":501},{\"id\":502,\"name\":\"Marketing\",\"nominal_code\":6200,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":502},{\"id\":503,\"name\":\"Rent and rates\",\"nominal_code\":7100,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":503},{\"id\":504,\"name\":\"Gas and electric\",\"nominal_code\":7200,\"tax_code\":{\"id\":2,\"name\":\"Lower Rate\",\"$key\":2},\"$key\":504},{\"id\":505,\"name\":\"Motor Expenses\",\"nominal_code\":7300,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":505},{\"id\":506,\"name\":\"Travel and Entertainment\",\"nominal_code\":7400,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":506},{\"id\":507,\"name\":\"Office costs\",\"nominal_code\":7500,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":507},{\"id\":508,\"name\":\"Legal and Professional\",\"nominal_code\":7600,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":508},{\"id\":509,\"name\":\"Insurance\",\"nominal_code\":7610,\"tax_code\":{\"id\":4,\"name\":\"Exempt\",\"$key\":4},\"$key\":509},{\"id\":510,\"name\":\"Repairs and renewals\",\"nominal_code\":7800,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":510},{\"id\":511,\"name\":\"Depreciation\",\"nominal_code\":8000,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":511},{\"id\":512,\"name\":\"Bad Debts\",\"nominal_code\":8100,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":512},{\"id\":513,\"name\":\"General Expenses\",\"nominal_code\":8200,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":513},{\"id\":514,\"name\":\"Exchange rate gain/(loss)\",\"nominal_code\":8211,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":514},{\"id\":515,\"name\":\"Dividend cost\",\"nominal_code\":8900,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":515}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:06:21 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/financial_settings","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["sageone_sdk Ruby Gem 0.0.1"],"Authorization":["Bearer bc8b0400db3b8f625a47518e4d4e6b37afd36bca"],"X-Nonce":["7133d9c49e730aee6967f99c137ee17b"],"X-Signature":["5IjzvBkWDpDN8LV9QR2vDA5SVuA="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Cf-Ray":["2561872212432987-DUB"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Thu, 17 Dec 2015 09:16:12 GMT"],"Etag":["\"e6dcfff2a2e0a71a2117e00147a576af\""],"Server":["openresty"],"Set-Cookie":["__cfduid=d12e42332e62790bd0609834fd364a7731450343772; expires=Fri, 16-Dec-16 09:16:12 GMT; path=/; domain=.sageone.com; HttpOnly","_session_id=ef004d9ef8b3080b53be4fac2bb3e9b3; path=/; expires=Thu, 17-Dec-2015 10:16:12 GMT; secure; HttpOnly"],"Status":["200 OK"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Frame-Options":["SAMEORIGIN"],"X-Rack-Cache":["miss"],"X-Request-Id":["6e85a30d5977dfc0c5a384881cb2ede9"],"X-Runtime":["0.021254"],"X-Server":["uk-production-extra-r3-27 (production)","uk-production-modproxy-144"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["198"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"last_updated\":\"2015-12-17T09:15:43Z\",\"year_end_date\":\"2016-11-03\",\"accounts_start_date\":null,\"year_end_lock_down\":null,\"tax_scheme\":{\"id\":3,\"name\":\"Not Registered\",\"$key\":3},\"tax_number\":\"\",\"tax_submission_frequency_type\":{\"$key\":null},\"tax_rate\":null,\"$key\":84093}"},"http_version":null},"recorded_at":"Thu, 17 Dec 2015 09:16:12 GMT"}],"recorded_with":"VCR 3.0.0"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"put","uri":"https://api.sageone.com/accounts/v1/financial_settings","body":{"encoding":"UTF-8","string":"financial_settings%5Byear_end_date%5D=2016-12-31"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["sageone_sdk Ruby Gem 0.0.1"],"Authorization":["Bearer bc8b0400db3b8f625a47518e4d4e6b37afd36bca"],"X-Nonce":["b3912824aa04c6321ff1152c28af54e0"],"X-Signature":["3Lllncd9GbvKmux+ZzVQgJQDh+I="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Cf-Ray":["25618723bd3a297b-DUB"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Thu, 17 Dec 2015 09:16:12 GMT"],"Etag":["\"38486469fa1670310264084e258841dd\""],"Server":["openresty"],"Set-Cookie":["__cfduid=d5692be23ef8a59804e1f4782ed98a8f01450343772; expires=Fri, 16-Dec-16 09:16:12 GMT; path=/; domain=.sageone.com; HttpOnly","_session_id=70b32e94831dd0f1b2730d33a687e20e; path=/; expires=Thu, 17-Dec-2015 10:16:12 GMT; secure; HttpOnly"],"Status":["200 OK"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Frame-Options":["SAMEORIGIN"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["bf4cc08d8783565207f4244c9a24b8e2"],"X-Runtime":["0.058000"],"X-Server":["uk-production-extra-r3-25 (production)","uk-production-modproxy-141"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["196"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"last_updated\":\"2015-12-17T09:16:12Z\",\"year_end_date\":\"2016-12-31\",\"accounts_start_date\":null,\"year_end_lock_down\":null,\"tax_scheme\":{\"id\":3,\"name\":\"Not Registered\",\"$key\":3},\"tax_number\":\"\",\"tax_submission_frequency_type\":{\"$key\":null},\"tax_rate\":null,\"$key\":84093}"},"http_version":null},"recorded_at":"Thu, 17 Dec 2015 09:16:12 GMT"}],"recorded_with":"VCR 3.0.0"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/income_methods/2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["4262e1b8247720f9e6516a19d3fd92af"],"X-Signature":["8CtCwwNiX/Ylx7N8ZbnxZsrJSaw="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 10:13:47 GMT"],"Etag":["\"b86d52e86bbc63ba97699f0abceac51a\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["d40926953f1db87afb84d16bfd865637"],"X-Runtime":["0.018934"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["65"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":2,\"name\":\"Bank Receipt\",\"code\":\"BR\",\"$key\":2}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 10:13:47 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/income_methods","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["2d9e0490e501bc3062afd10a27952fee"],"X-Signature":["Rf0YS19Z6+URSwXgsjAqkfKYM2Y="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 10:13:46 GMT"],"Etag":["\"a697a23686f66812b5f185a93d0ae6dd\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["86c9ec8551b4602e2db4350aa725fd29"],"X-Runtime":["0.020798"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["164"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":3,\"$startIndex\":0,\"$itemsPerPage\":20,\"$resources\":[{\"id\":2,\"name\":\"Bank Receipt\",\"code\":\"BR\",\"$key\":2},{\"id\":5,\"name\":\"Cash Receipt\",\"code\":\"CR\",\"$key\":5},{\"id\":10,\"name\":\"Cheque In Hand\",\"code\":\"CIH\",\"$key\":10}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 10:13:46 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/income_types/494","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["74c9b134db20bac4da5555ab8ea6f319"],"X-Signature":["bxn0QEGlxCe0l6wArLlkeVyNgy0="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:10:37 GMT"],"Etag":["\"5311179eae2be7a1034cb3a2858f2edb\""],"Server":["openresty"],"Set-Cookie":["_session_id=1fd54036606a8a360c4cbe072c4a176f; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["f639259c8c00a265d8f28c3c0cfe9b3c"],"X-Runtime":["0.024379"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["102"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":494,\"name\":\"Sales Type A\",\"nominal_code\":4000,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":494}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:10:36 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/income_types?$itemsPerPage=2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["19fecfd4d69294ec794ab8ec6240057c"],"X-Signature":["IrGvNWft9yMhNkAq6S3mw5yMlyk="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:10:36 GMT"],"Etag":["\"95b6c5aa26a0261dd70402dcd87e4065\""],"Server":["openresty"],"Set-Cookie":["_session_id=13c66a59b97c1698efe620b74d7d8785; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["225703298366b56b0d30345203ec0e3a"],"X-Runtime":["0.045341"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["261"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":5,\"$startIndex\":0,\"$itemsPerPage\":5,\"$resources\":[{\"id\":494,\"name\":\"Sales Type A\",\"nominal_code\":4000,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":494},{\"id\":495,\"name\":\"Sale of Assets\",\"nominal_code\":4200,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":495},{\"id\":496,\"name\":\"Late Payment Charges\",\"nominal_code\":4400,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":496},{\"id\":497,\"name\":\"Carriage on Sales\",\"nominal_code\":4905,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":497},{\"id\":526,\"name\":\"Other income\",\"nominal_code\":4900,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":526}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:10:36 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/income_types","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["1418a32dddd0f8815c01dc37a86d3edc"],"X-Signature":["HWgSOBjUOdc88xEwkZjtSXknKCc="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:10:36 GMT"],"Etag":["\"5a590d6c559e44283e30824a0f6d10cd\""],"Server":["openresty"],"Set-Cookie":["_session_id=65f9b15b969e3bd042bf2693262f4f22; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["c089c0a83d78b788b42d817b6b796e21"],"X-Runtime":["0.050656"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["264"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":5,\"$startIndex\":0,\"$itemsPerPage\":20,\"$resources\":[{\"id\":494,\"name\":\"Sales Type A\",\"nominal_code\":4000,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":494},{\"id\":495,\"name\":\"Sale of Assets\",\"nominal_code\":4200,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":495},{\"id\":496,\"name\":\"Late Payment Charges\",\"nominal_code\":4400,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":496},{\"id\":497,\"name\":\"Carriage on Sales\",\"nominal_code\":4905,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":497},{\"id\":526,\"name\":\"Other income\",\"nominal_code\":4900,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":526}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:10:36 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/incomes","body":{"encoding":"UTF-8","string":"income%5Bamount%5D=100\u0026income%5Bdate%5D=31%2F12%2F2014\u0026income%5Bdestination_id%5D=7696\u0026income%5Bpayment_method_id%5D=2\u0026income%5Breference%5D=Foo\u0026income%5Bsource_id%5D=7709\u0026income%5Btax_amount%5D=20\u0026income%5Btax_code_id%5D=2\u0026income%5Btax_percentage_rate%5D=5.0"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["25ae28bf45961f22f6223065772db5d8"],"X-Signature":["Bbp7SzoZjHCfpz/kDvREHD6ec/U="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":201,"message":"Created"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 11:45:29 GMT"],"Etag":["\"92c48c8cf3c2c7eae0480c36da13ec07\""],"Server":["openresty"],"Status":["201"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["545cf12ca2f0688e428c574803d4766e"],"X-Runtime":["0.130620"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["231"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":2943,\"date\":\"31/12/2014\",\"invoice_date\":\"31/12/2014\",\"amount\":\"100.0\",\"tax_amount\":\"20.0\",\"gross_amount\":\"120.0\",\"tax_percentage_rate\":\"5.0\",\"tax_code\":{\"id\":2,\"$key\":2},\"tax_scheme_period_id\":117,\"reference\":\"Foo\",\"contact\":{\"$key\":null},\"source\":{\"id\":7709,\"$key\":7709},\"destination\":{\"id\":7696,\"$key\":7696},\"payment_method\":{\"id\":2,\"$key\":2},\"voided\":false,\"lock_version\":0,\"$key\":2943}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 11:45:29 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/incomes","body":{"encoding":"UTF-8","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["c1f95b155786500124cb4f10d5466944"],"X-Signature":["QhEcujIA+fddW8lWYfqi4/ePRm4="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":422,"message":"Unprocessable Entity"},"headers":{"Cache-Control":["no-cache"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 11:45:30 GMT"],"Server":["openresty"],"Status":["422"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["a5e7050ceb97e22be303f3b0c97a34b8"],"X-Runtime":["0.165026"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["218"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$diagnoses\":[{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"blank\",\"$source\":\"source\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"must be a valid type of income\",\"$source\":\"source\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"blank\",\"$source\":\"destination\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"should not be the same as source\",\"$source\":\"destination\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"must be a bank ledger\",\"$source\":\"destination\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"invalid date\",\"$source\":\"date\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"blank\",\"$source\":\"amount\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"not a number\",\"$source\":\"amount\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"blank\",\"$source\":\"payment_method\"}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 11:45:30 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"delete","uri":"https://api.sageone.com/accounts/v1/incomes/2944","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["bd264590604fe8c023db52502a54a555"],"X-Signature":["SIw6PyWrDrnDs4ttoexSOz+tHEg="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 11:45:31 GMT"],"Etag":["\"11c7fb44a1451c90fccbb89c6d11deca\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["378aea81584d72709198f03d2158da79"],"X-Runtime":["0.197376"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["230"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":2944,\"date\":\"31/12/2014\",\"invoice_date\":\"31/12/2014\",\"amount\":\"100.0\",\"tax_amount\":\"20.0\",\"gross_amount\":\"120.0\",\"tax_percentage_rate\":\"5.0\",\"tax_code\":{\"id\":2,\"$key\":2},\"tax_scheme_period_id\":117,\"reference\":\"Foo\",\"contact\":{\"$key\":null},\"source\":{\"id\":7709,\"$key\":7709},\"destination\":{\"id\":7696,\"$key\":7696},\"payment_method\":{\"id\":2,\"$key\":2},\"voided\":true,\"lock_version\":1,\"$key\":2944}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 11:45:31 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/incomes/2939","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["8bfe145d5d5d8ed8b5d7b1ab54843d4e"],"X-Signature":["ISVeXX7Y499OcqwWSyo7sZk5kOA="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 11:40:28 GMT"],"Etag":["\"5b9298cff802028c3e82126b696add5b\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["77299aeba5d986d44c22b321e19b7d0c"],"X-Runtime":["0.026961"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["239"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":2939,\"date\":\"31/12/2014\",\"invoice_date\":\"31/12/2014\",\"amount\":\"100.0\",\"tax_amount\":\"20.0\",\"gross_amount\":\"120.0\",\"tax_percentage_rate\":\"20.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_scheme_period_id\":117,\"reference\":\"I12345\",\"contact\":{\"$key\":null},\"source\":{\"id\":7709,\"$key\":7709},\"destination\":{\"id\":7696,\"$key\":7696},\"payment_method\":{\"id\":2,\"$key\":2},\"voided\":false,\"lock_version\":0,\"$key\":2939}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 11:40:28 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/incomes?$itemsPerPage=2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["c629d6084c4431fd38835f5a1d774cd2"],"X-Signature":["1xs+rQaWRGY7oiQUOA4u/3u/r6k="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 11:38:59 GMT"],"Etag":["\"d8d895db3bc59d244a7b236c105fc1ae\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["5004095d888cb22715020b5f3936d68a"],"X-Runtime":["0.035230"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["309"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":2,\"$startIndex\":0,\"$itemsPerPage\":2,\"$resources\":[{\"id\":2939,\"date\":\"31/12/2014\",\"invoice_date\":\"31/12/2014\",\"amount\":\"100.0\",\"tax_amount\":\"20.0\",\"gross_amount\":\"120.0\",\"tax_percentage_rate\":\"20.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_scheme_period_id\":117,\"reference\":\"I12345\",\"contact\":{\"$key\":null},\"source\":{\"id\":7709,\"$key\":7709},\"destination\":{\"id\":7696,\"$key\":7696},\"payment_method\":{\"id\":2,\"$key\":2},\"voided\":false,\"lock_version\":0,\"$key\":2939},{\"id\":2940,\"date\":\"31/12/2014\",\"invoice_date\":\"31/12/2014\",\"amount\":\"150.0\",\"tax_amount\":\"30.0\",\"gross_amount\":\"180.0\",\"tax_percentage_rate\":\"20.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_scheme_period_id\":117,\"reference\":\"\",\"contact\":{\"$key\":null},\"source\":{\"id\":7709,\"$key\":7709},\"destination\":{\"id\":7696,\"$key\":7696},\"payment_method\":{\"id\":2,\"$key\":2},\"voided\":false,\"lock_version\":0,\"$key\":2940}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 11:38:59 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/incomes","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["358f5a667a11f943ecd63f119a5bde20"],"X-Signature":["mivtDbO6vFGSI1mLydaNF08h3c8="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 11:38:59 GMT"],"Etag":["\"1725c55fce7b3461ead9dcdab93c1e12\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["1d39f7e5b1a230d4d1206eb4077550e9"],"X-Runtime":["0.035611"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["310"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":2,\"$startIndex\":0,\"$itemsPerPage\":20,\"$resources\":[{\"id\":2939,\"date\":\"31/12/2014\",\"invoice_date\":\"31/12/2014\",\"amount\":\"100.0\",\"tax_amount\":\"20.0\",\"gross_amount\":\"120.0\",\"tax_percentage_rate\":\"20.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_scheme_period_id\":117,\"reference\":\"I12345\",\"contact\":{\"$key\":null},\"source\":{\"id\":7709,\"$key\":7709},\"destination\":{\"id\":7696,\"$key\":7696},\"payment_method\":{\"id\":2,\"$key\":2},\"voided\":false,\"lock_version\":0,\"$key\":2939},{\"id\":2940,\"date\":\"31/12/2014\",\"invoice_date\":\"31/12/2014\",\"amount\":\"150.0\",\"tax_amount\":\"30.0\",\"gross_amount\":\"180.0\",\"tax_percentage_rate\":\"20.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_scheme_period_id\":117,\"reference\":\"\",\"contact\":{\"$key\":null},\"source\":{\"id\":7709,\"$key\":7709},\"destination\":{\"id\":7696,\"$key\":7696},\"payment_method\":{\"id\":2,\"$key\":2},\"voided\":false,\"lock_version\":0,\"$key\":2940}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 11:38:59 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"put","uri":"https://api.sageone.com/accounts/v1/incomes/2939","body":{"encoding":"UTF-8","string":"income%5Breference%5D=Bar"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["0d5b3e2febe7e59be8eedafa8ff631ee"],"X-Signature":["Hz6TJvB49DIzCwobUxnD+y8gNvQ="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 11:40:28 GMT"],"Etag":["\"c203eef1a165a91d8660a3d03540951d\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["8af9fb77d62686ce2958c5524c2b0914"],"X-Runtime":["0.256527"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["234"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":2939,\"date\":\"31/12/2014\",\"invoice_date\":\"31/12/2014\",\"amount\":\"100.0\",\"tax_amount\":\"20.0\",\"gross_amount\":\"120.0\",\"tax_percentage_rate\":\"20.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_scheme_period_id\":117,\"reference\":\"Bar\",\"contact\":{\"$key\":null},\"source\":{\"id\":7709,\"$key\":7709},\"destination\":{\"id\":7696,\"$key\":7696},\"payment_method\":{\"id\":2,\"$key\":2},\"voided\":false,\"lock_version\":1,\"$key\":2939}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 11:40:28 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/journals","body":{"encoding":"UTF-8","string":"journal%5Bdate%5D=2016-01-01\u0026journal%5Bdescription%5D=description\u0026journal%5Bjournal_lines%5B0%5D%5Bcredit%5D%5D=50.0\u0026journal%5Bjournal_lines%5B0%5D%5Bdebit%5D%5D=0.0\u0026journal%5Bjournal_lines%5B0%5D%5Bdetails%5D%5D=detail\u0026journal%5Bjournal_lines%5B0%5D%5Bledger_account%5D%5Bnominal_code%5D%5D=1\u0026journal%5Bjournal_lines%5B1%5D%5Bcredit%5D%5D=0.0\u0026journal%5Bjournal_lines%5B1%5D%5Bdebit%5D%5D=50.0\u0026journal%5Bjournal_lines%5B1%5D%5Bdetails%5D%5D=detail\u0026journal%5Bjournal_lines%5B1%5D%5Bledger_account%5D%5Bnominal_code%5D%5D=9999\u0026journal%5Breference%5D=ref001"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["sageone_sdk Ruby Gem 0.0.1"],"Authorization":["Bearer 4c95aff8302a8b020e2343556d31669ef199a4d9"],"X-Nonce":["056e08f5d96f605dfc6f3e04af5c8c01"],"X-Signature":["gZvtG77gD8SDe2cRGLzidZMqw4Q="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":201,"message":"Created"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Cf-Ray":["2561bb7697d8295d-DUB"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Thu, 17 Dec 2015 09:51:56 GMT"],"Etag":["\"a68f10b555c8af6b4ccc950238521360\""],"Server":["openresty"],"Set-Cookie":["__cfduid=da3a985800ed12ac1ab85735eed9a73c31450345915; expires=Fri, 16-Dec-16 09:51:55 GMT; path=/; domain=.sageone.com; HttpOnly","_session_id=3878bcb11ba420dbc757c0764b2862ce; path=/; expires=Thu, 17-Dec-2015 10:51:56 GMT; secure; HttpOnly"],"Status":["201 Created"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Frame-Options":["SAMEORIGIN"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["73fcf5a363ba461780936a2bfe5c7ad2"],"X-Runtime":["0.203086"],"X-Server":["uk-production-extra-r3-25 (production)","uk-production-modproxy-140"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["211"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":341494,\"reference\":\"ref001\",\"description\":\"description\",\"date\":\"2016-01-01\",\"journal_lines\":[{\"id\":1196314,\"ledger_account\":{\"id\":5167018,\"nominal_code\":1,\"$key\":5167018},\"details\":\"detail\",\"credit\":\"50.0\",\"debit\":\"0.0\",\"$key\":1196314},{\"id\":1196315,\"ledger_account\":{\"id\":5167084,\"nominal_code\":9999,\"$key\":5167084},\"details\":\"detail\",\"credit\":\"0.0\",\"debit\":\"50.0\",\"$key\":1196315}],\"$key\":341494}"},"http_version":null},"recorded_at":"Thu, 17 Dec 2015 09:51:56 GMT"}],"recorded_with":"VCR 3.0.0"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/journals","body":{"encoding":"UTF-8","string":"journal%5Bfoo%5D=bar"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["sageone_sdk Ruby Gem 0.0.1"],"Authorization":["Bearer 4c95aff8302a8b020e2343556d31669ef199a4d9"],"X-Nonce":["fa443cd43cc8e118be22cabea4e09bba"],"X-Signature":["izH2vz5+kw/URLsLuyhdbKDKEuM="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":422,"message":"Unprocessable Entity"},"headers":{"Cache-Control":["no-cache"],"Cf-Ray":["2561bb79b0272999-DUB"],"Content-Type":["text/html; charset=UTF-8"],"Date":["Thu, 17 Dec 2015 09:51:56 GMT"],"Server":["openresty"],"Set-Cookie":["__cfduid=d778486de7af7b8cebf2e2ee957d830fc1450345916; expires=Fri, 16-Dec-16 09:51:56 GMT; path=/; domain=.sageone.com; HttpOnly","_session_id=2156f7e2c59f7b085dfd83a6580f6c34; path=/; expires=Thu, 17-Dec-2015 10:51:56 GMT; secure; HttpOnly"],"Status":["422 Unprocessable Entity"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Frame-Options":["SAMEORIGIN"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["fdcd30cfe8ebc713e9561d02517738e8"],"X-Runtime":["0.022647"],"X-Server":["uk-production-extra-r3-26 (production)","uk-production-modproxy-141"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["109"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$diagnoses\":[{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"invalid_date\",\"$source\":\"base\"}]}"},"http_version":null},"recorded_at":"Thu, 17 Dec 2015 09:51:56 GMT"}],"recorded_with":"VCR 3.0.0"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/ledger_accounts","body":{"encoding":"UTF-8","string":"ledger_account%5Bcategory_id%5D=1\u0026ledger_account%5Bdisplay_name%5D=My+new+ledger+account\u0026ledger_account%5Bincluded_in_chart%5D=true\u0026ledger_account%5Bledger_name%5D=My+new+ledger+account\u0026ledger_account%5Bnominal_code%5D=1237"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["sageone_sdk Ruby Gem 0.0.1"],"Authorization":["Bearer e147aa34aa43baf1b303dfe73c314757d054ff04"],"X-Nonce":["a0ca373ef0c720d90d1fd2b401553135"],"X-Signature":["nFSNDxOO8du5S2SxhFACt0JxBHI="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":201,"message":"Created"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Cf-Ray":["25612cd9964f297b-DUB"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Thu, 17 Dec 2015 08:14:34 GMT"],"Etag":["\"c9ce9dd70b5caec6d22f1eac03f7a68c\""],"Server":["openresty"],"Set-Cookie":["__cfduid=de26f6c76e678596e3cef4ea3c93a5a6e1450340074; expires=Fri, 16-Dec-16 08:14:34 GMT; path=/; domain=.sageone.com; HttpOnly","_session_id=bc4c29f0b7c572b578e0bbd9ba710c7d; path=/; expires=Thu, 17-Dec-2015 09:14:34 GMT; secure; HttpOnly"],"Status":["201 Created"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Frame-Options":["SAMEORIGIN"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["51bfd9f0e70385fa24d6b108d5d792ed"],"X-Runtime":["0.045390"],"X-Server":["uk-production-extra-r3-26 (production)","uk-production-modproxy-144"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["222"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":5322380,\"included_in_chart\":true,\"ledger_name\":\"My new ledger account\",\"name\":\"My new ledger account\",\"nominal_code\":1237,\"last_updated\":\"2015-12-17T08:14:34Z\",\"tax_code\":{\"$key\":null},\"category\":{\"id\":1,\"name\":\"Sales\",\"$key\":1},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"is_bank_account\":false,\"coa_account\":{\"$key\":null},\"$key\":5322380}"},"http_version":null},"recorded_at":"Thu, 17 Dec 2015 08:14:34 GMT"}],"recorded_with":"VCR 3.0.0"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/ledger_accounts","body":{"encoding":"UTF-8","string":"ledger_account%5Bfoo%5D=bar"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["sageone_sdk Ruby Gem 0.0.1"],"Authorization":["Bearer bc8b0400db3b8f625a47518e4d4e6b37afd36bca"],"X-Nonce":["1aed4747eed82ef15c751dfc55fff690"],"X-Signature":["rebtJFQUIuaoc1cIeQ6GlED7r3k="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":422,"message":"Unprocessable Entity"},"headers":{"Cache-Control":["no-cache"],"Cf-Ray":["2561645662892981-DUB"],"Content-Type":["text/html; charset=UTF-8"],"Date":["Thu, 17 Dec 2015 08:52:27 GMT"],"Server":["openresty"],"Set-Cookie":["__cfduid=da9012462ec39d4095c0a6c8e365e71761450342347; expires=Fri, 16-Dec-16 08:52:27 GMT; path=/; domain=.sageone.com; HttpOnly","_session_id=9829a9697b5754f6d70c35a0a52c6111; path=/; expires=Thu, 17-Dec-2015 09:52:27 GMT; secure; HttpOnly"],"Status":["422 Unprocessable Entity"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Frame-Options":["SAMEORIGIN"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["38a690f3cb1f7f67981217f243892190"],"X-Runtime":["0.050023"],"X-Server":["uk-production-extra-r3-25 (production)","uk-production-modproxy-142"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["179"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$diagnoses\":[{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"This field is required.\",\"$source\":\"ledger_account_type\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"This field is required.\",\"$source\":\"name\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"This field is required.\",\"$source\":\"display_name\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"This field is required.\",\"$source\":\"nominal_code\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"is not a number\",\"$source\":\"nominal_code\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"This field is required.\",\"$source\":\"ledger_account_type_id\"}]}"},"http_version":null},"recorded_at":"Thu, 17 Dec 2015 08:52:27 GMT"}],"recorded_with":"VCR 3.0.0"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/ledger_accounts/balances?from_date=2010-01-01\u0026to_date=2010-01-01","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["sageone_sdk Ruby Gem 0.0.1"],"Authorization":["Bearer e147aa34aa43baf1b303dfe73c314757d054ff04"],"X-Nonce":["0dff6ba4422b53abbe8c4a60638b9e48"],"X-Signature":["DCaAlFIeaRE+2K1E1ll3uSfuJSM="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Cf-Ray":["2560fae5fd052969-DUB"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Thu, 17 Dec 2015 07:40:28 GMT"],"Etag":["\"d751713988987e9331980363e24189ce\""],"Server":["openresty"],"Set-Cookie":["__cfduid=d5ad47c4aa3cbf7fcbd2f51a0774c69b81450338028; expires=Fri, 16-Dec-16 07:40:28 GMT; path=/; domain=.sageone.com; HttpOnly","_session_id=2e5c41f9444e7ce87bc9e2728ae37a6b; path=/; expires=Thu, 17-Dec-2015 08:40:28 GMT; secure; HttpOnly"],"Status":["200 OK"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Frame-Options":["SAMEORIGIN"],"X-Rack-Cache":["miss"],"X-Request-Id":["767cf16d324b5d5faf1b5e7e812b7e68"],"X-Runtime":["0.106923"],"X-Server":["uk-production-extra-r3-24 (production)","uk-production-modproxy-140"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["22"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"[]"},"http_version":null},"recorded_at":"Thu, 17 Dec 2015 07:40:28 GMT"}],"recorded_with":"VCR 3.0.0"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/ledger_accounts/balances?from_date=2015-01-01\u0026to_date=2016-01-01","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["sageone_sdk Ruby Gem 0.0.1"],"Authorization":["Bearer e147aa34aa43baf1b303dfe73c314757d054ff04"],"X-Nonce":["bb80a826414f0085c6d81ff043727b73"],"X-Signature":["jmUSLTLZKJ5r1qN2KGlEHGv02kU="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Cf-Ray":["2560fae2a93f2993-DUB"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Thu, 17 Dec 2015 07:40:28 GMT"],"Etag":["\"e5a5a75f2c36bfd54b4751155c4725f0\""],"Server":["openresty"],"Set-Cookie":["__cfduid=d0ba84824648e6c1b34bab18d0ddfecfd1450338027; expires=Fri, 16-Dec-16 07:40:27 GMT; path=/; domain=.sageone.com; HttpOnly","_session_id=7012a300d0ae2fedbe50d82002312d6a; path=/; expires=Thu, 17-Dec-2015 08:40:28 GMT; secure; HttpOnly"],"Status":["200 OK"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Frame-Options":["SAMEORIGIN"],"X-Rack-Cache":["miss"],"X-Request-Id":["346fa5d5df7aa693839621e4e4a231ce"],"X-Runtime":["0.208092"],"X-Server":["uk-production-extra-r3-26 (production)","uk-production-modproxy-141"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["648"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"[{\"ledger_account\":{\"id\":5167016,\"included_in_chart\":true,\"ledger_name\":\"Current\",\"name\":\"Current\",\"nominal_code\":1200,\"last_updated\":\"2015-12-05T14:12:46Z\",\"tax_code\":{\"$key\":null},\"category\":{\"id\":9,\"name\":\"Bank\",\"$key\":9},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":5167016},\"balance\":\"12575.0\",\"credit_or_debit\":\"credit\",\"credits\":\"12575.0\",\"debits\":\"0.0\",\"$key\":5167016},{\"ledger_account\":{\"id\":5167018,\"included_in_chart\":true,\"ledger_name\":\"Assets - Cost\",\"name\":\"Assets - Cost\",\"nominal_code\":1,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":5167018},\"balance\":\"450.0\",\"credit_or_debit\":\"debit\",\"credits\":\"50.0\",\"debits\":\"500.0\",\"$key\":5167018},{\"ledger_account\":{\"id\":5167026,\"included_in_chart\":true,\"ledger_name\":\"Trade Debtors\",\"name\":\"Trade Debtors\",\"nominal_code\":1100,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":6,\"name\":\"Current Assets\",\"$key\":6},\"category_group\":{\"id\":3,\"name\":\"Asset\",\"$key\":3},\"$key\":5167026},\"balance\":\"659847.05\",\"credit_or_debit\":\"debit\",\"credits\":\"296.91\",\"debits\":\"660143.96\",\"$key\":5167026},{\"ledger_account\":{\"id\":5167053,\"included_in_chart\":true,\"ledger_name\":\"Carriage on Sales\",\"name\":\"Carriage on Sales\",\"nominal_code\":4905,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":1,\"name\":\"Sales\",\"$key\":1},\"category_group\":{\"id\":1,\"name\":\"Income\",\"$key\":1},\"$key\":5167053},\"balance\":\"659847.05\",\"credit_or_debit\":\"credit\",\"credits\":\"660012.0\",\"debits\":\"164.95\",\"$key\":5167053},{\"ledger_account\":{\"id\":5167054,\"included_in_chart\":true,\"ledger_name\":\"Cost of sales - goods\",\"name\":\"Cost of sales - goods\",\"nominal_code\":5000,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"category\":{\"id\":3,\"name\":\"Direct Expenses\",\"$key\":3},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167054},\"balance\":\"12575.0\",\"credit_or_debit\":\"debit\",\"credits\":\"0.0\",\"debits\":\"12575.0\",\"$key\":5167054},{\"ledger_account\":{\"id\":5167078,\"included_in_chart\":true,\"ledger_name\":\"Depreciation\",\"name\":\"Depreciation\",\"nominal_code\":8000,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":5,\"name\":\"Depreciation\",\"$key\":5},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167078},\"balance\":\"500.0\",\"credit_or_debit\":\"credit\",\"credits\":\"500.0\",\"debits\":\"0.0\",\"$key\":5167078},{\"ledger_account\":{\"id\":5167084,\"included_in_chart\":true,\"ledger_name\":\"Suspense\",\"name\":\"Corrections\",\"nominal_code\":9999,\"last_updated\":\"2015-12-05T14:12:48Z\",\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"category\":{\"id\":4,\"name\":\"Overheads\",\"$key\":4},\"category_group\":{\"id\":2,\"name\":\"Expenditure\",\"$key\":2},\"$key\":5167084},\"balance\":\"50.0\",\"credit_or_debit\":\"debit\",\"credits\":\"0.0\",\"debits\":\"50.0\",\"$key\":5167084}]"},"http_version":null},"recorded_at":"Thu, 17 Dec 2015 07:40:28 GMT"}],"recorded_with":"VCR 3.0.0"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/ledger_accounts/7686","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["d173e55f52f91b951d9ccb2bbebcc124"],"X-Signature":["GW5iI+Fjnp+c7b/6qKWvQGrzumY="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 11:49:17 GMT"],"Etag":["\"48ab5784e043cfce44d4c1bde3fc0fd7\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["2656c17b7b126041d2e902873c2ad4ba"],"X-Runtime":["0.061587"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["298"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":7686,\"included_in_chart\":true,\"ledger_name\":\"Office equipment and IT - Cost\",\"name\":\"IT equipment cost\",\"nominal_code\":30,\"last_updated\":\"2014-12-31T10:03:43+00:00\",\"tax_code\":{\"id\":1,\"name\":\"STANDARD\",\"$key\":1},\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":7,\"name\":\"Asset\",\"$key\":7},\"is_bank_account\":false,\"coa_account\":{\"id\":9,\"included_in_chart\":true,\"ledger_name\":\"Office equipment and IT - Cost\",\"display_name\":\"IT equipment cost\",\"nominal_code\":30,\"control_name\":null,\"last_updated\":\"2010-06-29T14:52:41+01:00\",\"category\":{\"id\":7,\"name\":\"Fixed Assets\",\"$key\":7},\"category_group\":{\"id\":7,\"name\":\"Asset\",\"$key\":7},\"$key\":9},\"$key\":7686}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 11:49:17 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/ledger_accounts?$itemsPerPage=2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["5c4c4d2e2718d2d81ed301ca7b1f8061"],"X-Signature":["UvUODctqVo7Yy+yVHFbsPoB0UVA="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:14:47 GMT"],"Etag":["\"686b4da33dbd1851d2dd3b424e4f7399\""],"Server":["openresty"],"Set-Cookie":["_session_id=7751068d0c87d973bd48cda66534ca69; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["b7070b21aeab6a355b811e08cd6ff0b8"],"X-Runtime":["0.252761"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["1489"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":68,\"$startIndex\":0,\"$itemsPerPage\":68,\"$resources\":[{\"id\":479,\"name\":\"Current\",\"nominal_code\":1200,\"tax_code\":{\"$key\":null},\"$key\":479},{\"id\":480,\"name\":\"Cash in Hand\",\"nominal_code\":1210,\"tax_code\":{\"$key\":null},\"$key\":480},{\"id\":481,\"name\":\"Assets - Cost\",\"nominal_code\":1,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":481},{\"id\":482,\"name\":\"Office equipment and IT - Cost\",\"nominal_code\":30,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":482},{\"id\":483,\"name\":\"Office equipment and IT - Accumulated Depreciation\",\"nominal_code\":31,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":483},{\"id\":484,\"name\":\"Fixtures and fittings - Cost\",\"nominal_code\":40,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":484},{\"id\":485,\"name\":\"Fixtures and fittings - Accumulated Depreciation\",\"nominal_code\":41,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":485},{\"id\":486,\"name\":\"Motor Vehicles - Cost\",\"nominal_code\":50,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":486},{\"id\":487,\"name\":\"Motor Vehicles - Accumulated Depreciation\",\"nominal_code\":51,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":487},{\"id\":488,\"name\":\"Stock\",\"nominal_code\":1000,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":488},{\"id\":489,\"name\":\"Provision for doubtful debtors\",\"nominal_code\":1101,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":489},{\"id\":490,\"name\":\"Prepayments\",\"nominal_code\":1110,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":490},{\"id\":491,\"name\":\"Accruals\",\"nominal_code\":2101,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":491},{\"id\":492,\"name\":\"Corporation Tax Liability\",\"nominal_code\":2150,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":492},{\"id\":493,\"name\":\"Share capital\",\"nominal_code\":3000,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":493},{\"id\":494,\"name\":\"Sales Type A\",\"nominal_code\":4000,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":494},{\"id\":495,\"name\":\"Sale of Assets\",\"nominal_code\":4200,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":495},{\"id\":496,\"name\":\"Late Payment Charges\",\"nominal_code\":4400,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":496},{\"id\":497,\"name\":\"Carriage on Sales\",\"nominal_code\":4905,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":497},{\"id\":498,\"name\":\"Cost of sales - goods\",\"nominal_code\":5000,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":498},{\"id\":499,\"name\":\"Cost of sales - materials\",\"nominal_code\":5010,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":499},{\"id\":500,\"name\":\"Cost of sales - delivery\",\"nominal_code\":5015,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":500},{\"id\":501,\"name\":\"Carriage on Purchases\",\"nominal_code\":5100,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":501},{\"id\":502,\"name\":\"Marketing\",\"nominal_code\":6200,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":502},{\"id\":503,\"name\":\"Rent and rates\",\"nominal_code\":7100,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":503},{\"id\":504,\"name\":\"Gas and electric\",\"nominal_code\":7200,\"tax_code\":{\"id\":2,\"name\":\"Lower Rate\",\"$key\":2},\"$key\":504},{\"id\":505,\"name\":\"Motor Expenses\",\"nominal_code\":7300,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":505},{\"id\":506,\"name\":\"Travel and Entertainment\",\"nominal_code\":7400,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":506},{\"id\":507,\"name\":\"Office costs\",\"nominal_code\":7500,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":507},{\"id\":508,\"name\":\"Legal and Professional\",\"nominal_code\":7600,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":508},{\"id\":509,\"name\":\"Insurance\",\"nominal_code\":7610,\"tax_code\":{\"id\":4,\"name\":\"Exempt\",\"$key\":4},\"$key\":509},{\"id\":510,\"name\":\"Repairs and renewals\",\"nominal_code\":7800,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":510},{\"id\":511,\"name\":\"Depreciation\",\"nominal_code\":8000,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":511},{\"id\":512,\"name\":\"Bad Debts\",\"nominal_code\":8100,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":512},{\"id\":513,\"name\":\"General Expenses\",\"nominal_code\":8200,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":513},{\"id\":514,\"name\":\"Exchange rate gain/(loss)\",\"nominal_code\":8211,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":514},{\"id\":515,\"name\":\"Dividend cost\",\"nominal_code\":8900,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":515},{\"id\":516,\"name\":\"Attachments\",\"nominal_code\":2215,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":516},{\"id\":517,\"name\":\"Bank charges and interest\",\"nominal_code\":7900,\"tax_code\":{\"id\":4,\"name\":\"Exempt\",\"$key\":4},\"$key\":517},{\"id\":518,\"name\":\"Drawings - equity\",\"nominal_code\":3260,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":518},{\"id\":519,\"name\":\"Employee costs\",\"nominal_code\":7000,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":519},{\"id\":520,\"name\":\"Employers NI\",\"nominal_code\":7006,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":520},{\"id\":521,\"name\":\"Employers Pensions\",\"nominal_code\":7007,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":521},{\"id\":522,\"name\":\"Net Wages\",\"nominal_code\":2220,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":522},{\"id\":523,\"name\":\"Other taxes paid to HMRC\",\"nominal_code\":2211,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":523},{\"id\":524,\"name\":\"Opening Balances Control Account\",\"nominal_code\":9998,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":524},{\"id\":525,\"name\":\"Other Deductions\",\"nominal_code\":7009,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":525},{\"id\":526,\"name\":\"Other income\",\"nominal_code\":4900,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":526},{\"id\":527,\"name\":\"Capital introduced\",\"nominal_code\":3200,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":527},{\"id\":528,\"name\":\"PAYE\",\"nominal_code\":2210,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":528},{\"id\":529,\"name\":\"Pension\",\"nominal_code\":2230,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":529},{\"id\":530,\"name\":\"Profit and Loss Account\",\"nominal_code\":3100,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":530},{\"id\":531,\"name\":\"Purchase Discounts\",\"nominal_code\":5009,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":531},{\"id\":532,\"name\":\"Sales Discounts\",\"nominal_code\":4009,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":532},{\"id\":533,\"name\":\"Statutory Adoption Pay\",\"nominal_code\":7013,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":533},{\"id\":534,\"name\":\"Statutory Maternity Pay\",\"nominal_code\":7011,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":534},{\"id\":535,\"name\":\"Statutory Paternity Pay\",\"nominal_code\":7012,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":535},{\"id\":536,\"name\":\"Statutory Sick Pay\",\"nominal_code\":7010,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":536},{\"id\":537,\"name\":\"Student Loan\",\"nominal_code\":2214,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":537},{\"id\":538,\"name\":\"Corrections\",\"nominal_code\":9999,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":538},{\"id\":539,\"name\":\"VAT Allocations \u0026 Adjustments\",\"nominal_code\":2203,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":539},{\"id\":540,\"name\":\"VAT Liability\",\"nominal_code\":2202,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":540},{\"id\":541,\"name\":\"VAT on Purchases\",\"nominal_code\":2201,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":541},{\"id\":542,\"name\":\"VAT on Purchases - Holding Account\",\"nominal_code\":2206,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":542},{\"id\":543,\"name\":\"VAT on Sales\",\"nominal_code\":2200,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":543},{\"id\":544,\"name\":\"VAT on Sales - Holding Account\",\"nominal_code\":2205,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":544},{\"id\":545,\"name\":\"Trade Creditors\",\"nominal_code\":2100,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":545},{\"id\":546,\"name\":\"Trade Debtors\",\"nominal_code\":1100,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":546}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:14:47 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/ledger_accounts","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["cf5e12d79cdefb350eedb7c7b168b6e0"],"X-Signature":["r03nIAV/n+GKA1hhzkDt9P1nGCg="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:14:46 GMT"],"Etag":["\"686b4da33dbd1851d2dd3b424e4f7399\""],"Server":["openresty"],"Set-Cookie":["_session_id=fa8aaac8ca9b77b34adb7ea9a0902972; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["93e238f9217618cb9a7296e8ad18f51e"],"X-Runtime":["0.533238"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["1489"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":68,\"$startIndex\":0,\"$itemsPerPage\":68,\"$resources\":[{\"id\":479,\"name\":\"Current\",\"nominal_code\":1200,\"tax_code\":{\"$key\":null},\"$key\":479},{\"id\":480,\"name\":\"Cash in Hand\",\"nominal_code\":1210,\"tax_code\":{\"$key\":null},\"$key\":480},{\"id\":481,\"name\":\"Assets - Cost\",\"nominal_code\":1,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":481},{\"id\":482,\"name\":\"Office equipment and IT - Cost\",\"nominal_code\":30,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":482},{\"id\":483,\"name\":\"Office equipment and IT - Accumulated Depreciation\",\"nominal_code\":31,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":483},{\"id\":484,\"name\":\"Fixtures and fittings - Cost\",\"nominal_code\":40,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":484},{\"id\":485,\"name\":\"Fixtures and fittings - Accumulated Depreciation\",\"nominal_code\":41,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":485},{\"id\":486,\"name\":\"Motor Vehicles - Cost\",\"nominal_code\":50,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":486},{\"id\":487,\"name\":\"Motor Vehicles - Accumulated Depreciation\",\"nominal_code\":51,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":487},{\"id\":488,\"name\":\"Stock\",\"nominal_code\":1000,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":488},{\"id\":489,\"name\":\"Provision for doubtful debtors\",\"nominal_code\":1101,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":489},{\"id\":490,\"name\":\"Prepayments\",\"nominal_code\":1110,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":490},{\"id\":491,\"name\":\"Accruals\",\"nominal_code\":2101,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":491},{\"id\":492,\"name\":\"Corporation Tax Liability\",\"nominal_code\":2150,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":492},{\"id\":493,\"name\":\"Share capital\",\"nominal_code\":3000,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":493},{\"id\":494,\"name\":\"Sales Type A\",\"nominal_code\":4000,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":494},{\"id\":495,\"name\":\"Sale of Assets\",\"nominal_code\":4200,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":495},{\"id\":496,\"name\":\"Late Payment Charges\",\"nominal_code\":4400,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":496},{\"id\":497,\"name\":\"Carriage on Sales\",\"nominal_code\":4905,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":497},{\"id\":498,\"name\":\"Cost of sales - goods\",\"nominal_code\":5000,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":498},{\"id\":499,\"name\":\"Cost of sales - materials\",\"nominal_code\":5010,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":499},{\"id\":500,\"name\":\"Cost of sales - delivery\",\"nominal_code\":5015,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":500},{\"id\":501,\"name\":\"Carriage on Purchases\",\"nominal_code\":5100,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":501},{\"id\":502,\"name\":\"Marketing\",\"nominal_code\":6200,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":502},{\"id\":503,\"name\":\"Rent and rates\",\"nominal_code\":7100,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":503},{\"id\":504,\"name\":\"Gas and electric\",\"nominal_code\":7200,\"tax_code\":{\"id\":2,\"name\":\"Lower Rate\",\"$key\":2},\"$key\":504},{\"id\":505,\"name\":\"Motor Expenses\",\"nominal_code\":7300,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":505},{\"id\":506,\"name\":\"Travel and Entertainment\",\"nominal_code\":7400,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":506},{\"id\":507,\"name\":\"Office costs\",\"nominal_code\":7500,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":507},{\"id\":508,\"name\":\"Legal and Professional\",\"nominal_code\":7600,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":508},{\"id\":509,\"name\":\"Insurance\",\"nominal_code\":7610,\"tax_code\":{\"id\":4,\"name\":\"Exempt\",\"$key\":4},\"$key\":509},{\"id\":510,\"name\":\"Repairs and renewals\",\"nominal_code\":7800,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":510},{\"id\":511,\"name\":\"Depreciation\",\"nominal_code\":8000,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":511},{\"id\":512,\"name\":\"Bad Debts\",\"nominal_code\":8100,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":512},{\"id\":513,\"name\":\"General Expenses\",\"nominal_code\":8200,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":513},{\"id\":514,\"name\":\"Exchange rate gain/(loss)\",\"nominal_code\":8211,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":514},{\"id\":515,\"name\":\"Dividend cost\",\"nominal_code\":8900,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":515},{\"id\":516,\"name\":\"Attachments\",\"nominal_code\":2215,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":516},{\"id\":517,\"name\":\"Bank charges and interest\",\"nominal_code\":7900,\"tax_code\":{\"id\":4,\"name\":\"Exempt\",\"$key\":4},\"$key\":517},{\"id\":518,\"name\":\"Drawings - equity\",\"nominal_code\":3260,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":518},{\"id\":519,\"name\":\"Employee costs\",\"nominal_code\":7000,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":519},{\"id\":520,\"name\":\"Employers NI\",\"nominal_code\":7006,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":520},{\"id\":521,\"name\":\"Employers Pensions\",\"nominal_code\":7007,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":521},{\"id\":522,\"name\":\"Net Wages\",\"nominal_code\":2220,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":522},{\"id\":523,\"name\":\"Other taxes paid to HMRC\",\"nominal_code\":2211,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":523},{\"id\":524,\"name\":\"Opening Balances Control Account\",\"nominal_code\":9998,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":524},{\"id\":525,\"name\":\"Other Deductions\",\"nominal_code\":7009,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":525},{\"id\":526,\"name\":\"Other income\",\"nominal_code\":4900,\"tax_code\":{\"id\":1,\"name\":\"Standard\",\"$key\":1},\"$key\":526},{\"id\":527,\"name\":\"Capital introduced\",\"nominal_code\":3200,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":527},{\"id\":528,\"name\":\"PAYE\",\"nominal_code\":2210,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":528},{\"id\":529,\"name\":\"Pension\",\"nominal_code\":2230,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":529},{\"id\":530,\"name\":\"Profit and Loss Account\",\"nominal_code\":3100,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":530},{\"id\":531,\"name\":\"Purchase Discounts\",\"nominal_code\":5009,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":531},{\"id\":532,\"name\":\"Sales Discounts\",\"nominal_code\":4009,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":532},{\"id\":533,\"name\":\"Statutory Adoption Pay\",\"nominal_code\":7013,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":533},{\"id\":534,\"name\":\"Statutory Maternity Pay\",\"nominal_code\":7011,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":534},{\"id\":535,\"name\":\"Statutory Paternity Pay\",\"nominal_code\":7012,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":535},{\"id\":536,\"name\":\"Statutory Sick Pay\",\"nominal_code\":7010,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":536},{\"id\":537,\"name\":\"Student Loan\",\"nominal_code\":2214,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":537},{\"id\":538,\"name\":\"Corrections\",\"nominal_code\":9999,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":538},{\"id\":539,\"name\":\"VAT Allocations \u0026 Adjustments\",\"nominal_code\":2203,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":539},{\"id\":540,\"name\":\"VAT Liability\",\"nominal_code\":2202,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":540},{\"id\":541,\"name\":\"VAT on Purchases\",\"nominal_code\":2201,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":541},{\"id\":542,\"name\":\"VAT on Purchases - Holding Account\",\"nominal_code\":2206,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":542},{\"id\":543,\"name\":\"VAT on Sales\",\"nominal_code\":2200,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":543},{\"id\":544,\"name\":\"VAT on Sales - Holding Account\",\"nominal_code\":2205,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":544},{\"id\":545,\"name\":\"Trade Creditors\",\"nominal_code\":2100,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":545},{\"id\":546,\"name\":\"Trade Debtors\",\"nominal_code\":1100,\"tax_code\":{\"id\":5,\"name\":\"No VAT\",\"$key\":5},\"$key\":546}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:14:46 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/payment_statuses/1","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["939f0b2d0356d11e90f46fd565f350d4"],"X-Signature":["RLGuCCcHJoyWQKPQ87qr25JXPbo="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:17:21 GMT"],"Etag":["\"0ad0358dd1893f8f8d221af3c4666010\""],"Server":["openresty"],"Set-Cookie":["_session_id=c7787e17cabaa3b367a453b7dbce1683; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["6b3324d0675603065273efcda6be3a62"],"X-Runtime":["0.021849"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["50"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":1,\"name\":\"Unpaid\",\"$key\":1}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:17:20 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/payment_statuses?$itemsPerPage=2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["29e6b5f41a50103aab5cb9086893d792"],"X-Signature":["0D/KbyT3Y+bcu+xdxUw1kHj6408="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:17:20 GMT"],"Etag":["\"05652753acf2719406a11ebaa95efd59\""],"Server":["openresty"],"Set-Cookie":["_session_id=32e2448e3e7c116936023ae38875828a; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["54baacc9f598fc3a4db7f13b2391d227"],"X-Runtime":["0.023255"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["172"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":7,\"$startIndex\":0,\"$itemsPerPage\":7,\"$resources\":[{\"id\":1,\"name\":\"Unpaid\",\"$key\":1},{\"id\":2,\"name\":\"Part Paid\",\"$key\":2},{\"id\":3,\"name\":\"Paid\",\"$key\":3},{\"id\":4,\"name\":\"Void\",\"$key\":4},{\"id\":5,\"name\":\"Draft\",\"$key\":5},{\"id\":6,\"name\":\"Disputed\",\"$key\":6},{\"id\":7,\"name\":\"Declined\",\"$key\":7}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:17:20 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/payment_statuses","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["ec66dbcad80af0f454c0d7e5f28d1322"],"X-Signature":["QB8tblOycdCPVk9/0zVRfA7Bja4="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:17:20 GMT"],"Etag":["\"2bb297d864a1f7260a30c48d971958dc\""],"Server":["openresty"],"Set-Cookie":["_session_id=0e5b353c621741278e2f59696692c15d; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["6b1112d1cda878520456bc1cd4be763f"],"X-Runtime":["0.292751"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["174"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":7,\"$startIndex\":0,\"$itemsPerPage\":20,\"$resources\":[{\"id\":1,\"name\":\"Unpaid\",\"$key\":1},{\"id\":2,\"name\":\"Part Paid\",\"$key\":2},{\"id\":3,\"name\":\"Paid\",\"$key\":3},{\"id\":4,\"name\":\"Void\",\"$key\":4},{\"id\":5,\"name\":\"Draft\",\"$key\":5},{\"id\":6,\"name\":\"Disputed\",\"$key\":6},{\"id\":7,\"name\":\"Declined\",\"$key\":7}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:17:19 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/period_types/1","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["d44934a2da8f747c3dd0bb060cc9621a"],"X-Signature":["/5grxe+46fVbCumb9ircpRDUJEI="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:19:21 GMT"],"Etag":["\"460c088035070a9543e5e357b2c9ca15\""],"Server":["openresty"],"Set-Cookie":["_session_id=fabc353dfcf92a3433e7a6729eacb8ec; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["c8beefbadd71950792fdd2111bc1b6fb"],"X-Runtime":["0.021466"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["54"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":1,\"name\":\"Annually\",\"$key\":1}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:19:20 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/period_types?$itemsPerPage=2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["65784edef271eacde72b074aa48fb3e2"],"X-Signature":["nVJ+vvbJvYsPYzbu1yXms69Jomg="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:19:20 GMT"],"Etag":["\"86a2c77b9d246be5914851bc2811a136\""],"Server":["openresty"],"Set-Cookie":["_session_id=7469936e3b57141e9485159f68767881; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["8db9c32fa2636ce39be4996f25376657"],"X-Runtime":["0.024044"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["182"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":7,\"$startIndex\":0,\"$itemsPerPage\":7,\"$resources\":[{\"id\":1,\"name\":\"Annually\",\"$key\":1},{\"id\":2,\"name\":\"Daily\",\"$key\":2},{\"id\":3,\"name\":\"Hourly\",\"$key\":3},{\"id\":4,\"name\":\"Monthly\",\"$key\":4},{\"id\":5,\"name\":\"Quarterly\",\"$key\":5},{\"id\":6,\"name\":\"Weekly\",\"$key\":6},{\"id\":7,\"name\":\"Fixed Rate\",\"$key\":7}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:19:20 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/period_types","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["2fd53bb5108f66ab945d0346d71b33c5"],"X-Signature":["3tmx24KJbXG7En4qHtxV+F2a0TE="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:19:20 GMT"],"Etag":["\"5167f207f1d97a91188f2dfa9e5c9195\""],"Server":["openresty"],"Set-Cookie":["_session_id=b1d8e0b585f25f5f41f1a7db552f6f7e; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["535a6225a052303562b0f417b2008aa1"],"X-Runtime":["0.026894"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["185"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":7,\"$startIndex\":0,\"$itemsPerPage\":20,\"$resources\":[{\"id\":1,\"name\":\"Annually\",\"$key\":1},{\"id\":2,\"name\":\"Daily\",\"$key\":2},{\"id\":3,\"name\":\"Hourly\",\"$key\":3},{\"id\":4,\"name\":\"Monthly\",\"$key\":4},{\"id\":5,\"name\":\"Quarterly\",\"$key\":5},{\"id\":6,\"name\":\"Weekly\",\"$key\":6},{\"id\":7,\"name\":\"Fixed Rate\",\"$key\":7}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:19:20 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/products","body":{"encoding":"UTF-8","string":"product%5Bdescription%5D=Foo"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["1f8a064fc88035703d3238d43ae4b675"],"X-Signature":["x8JTw/gGwhbLSO+UZQdZoUkwIgY="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":201,"message":"Created"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:33:07 GMT"],"Etag":["\"17585866f3a7112168f30d7b3d722c5a\""],"Server":["openresty"],"Set-Cookie":["_session_id=ab1dfe58d2fa51c5a7514b377a23f7c7; path=/; secure; HttpOnly"],"Status":["201"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["070497f42c1a18829125df814d1773e4"],"X-Runtime":["0.083387"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["164"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":10,\"description\":\"Foo\",\"product_code\":\"\",\"extra_info\":\"\",\"sales_price\":\"0.0\",\"sales_price_includes_tax\":0,\"last_cost_price\":\"0.0\",\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":0,\"$key\":10}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:33:06 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/products","body":{"encoding":"UTF-8","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["4b9841f78ca976dd8e4e1610439091e0"],"X-Signature":["xcXl/KQcziLLUo9cotJqBrN/guo="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":422,"message":"Unprocessable Entity"},"headers":{"Cache-Control":["no-cache"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 10:15:37 GMT"],"Server":["openresty"],"Status":["422"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["3e616c560af016320badd079fa1985f4"],"X-Runtime":["0.143130"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["168"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$diagnoses\":[{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"blank\",\"$source\":\"description\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"/ Type of Sale is invalid\",\"$source\":\"ledger_account\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"must be a valid type of income\",\"$source\":\"ledger_account\"}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 10:15:37 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"delete","uri":"https://api.sageone.com/accounts/v1/products/11","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["d7e4e53d443a9991560781c5e4a7877f"],"X-Signature":["rzAxp/pGyzSx2aTfJ8FSaYoQcQI="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:33:08 GMT"],"Etag":["\"f09759a4ca60771290aed1e19cc8991b\""],"Server":["openresty"],"Set-Cookie":["_session_id=84b6fa17e8a22e84d74394d7075fed85; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["bccc58722955a9affe3c4aa63d0c7372"],"X-Runtime":["0.055058"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["164"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":11,\"description\":\"Foo\",\"product_code\":\"\",\"extra_info\":\"\",\"sales_price\":\"0.0\",\"sales_price_includes_tax\":0,\"last_cost_price\":\"0.0\",\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":0,\"$key\":11}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:33:07 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/products/7","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["246c69e96a6e42c7d2ff9023882b1ad1"],"X-Signature":["na/Covfs02jq3xP430gNBhKfDHQ="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:33:07 GMT"],"Etag":["\"5278ee012b29704cc9f576ff5db284a2\""],"Server":["openresty"],"Set-Cookie":["_session_id=008173e6d4b78ff63c341228626173ac; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["9e1e5b0260f7da94a5e8d1dd448940d6"],"X-Runtime":["0.046084"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["164"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":7,\"description\":\"Foo\",\"product_code\":\"\",\"extra_info\":\"\",\"sales_price\":\"0.0\",\"sales_price_includes_tax\":0,\"last_cost_price\":\"0.0\",\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":0,\"$key\":7}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:33:06 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/products?$itemsPerPage=2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["8b083d8ea2c4fa37f62c86e90b49dbc1"],"X-Signature":["4VBzMz73TLPr7xoEkAq6pZlwaCI="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:33:06 GMT"],"Etag":["\"b1c34d8991c909c5ed79fc179f2f11b9\""],"Server":["openresty"],"Set-Cookie":["_session_id=c2cfd42112e36c4a33272ec8c97ff203; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["8799015264cae12d72bebf6670515c35"],"X-Runtime":["0.072816"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["219"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":5,\"$startIndex\":0,\"$itemsPerPage\":2,\"$resources\":[{\"id\":7,\"description\":\"Foo\",\"product_code\":\"\",\"extra_info\":\"\",\"sales_price\":\"0.0\",\"sales_price_includes_tax\":0,\"last_cost_price\":\"0.0\",\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":0,\"$key\":7},{\"id\":8,\"description\":\"Foo\",\"product_code\":\"\",\"extra_info\":\"\",\"sales_price\":\"0.0\",\"sales_price_includes_tax\":0,\"last_cost_price\":\"0.0\",\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":0,\"$key\":8}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:33:05 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/products","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["ad083f5776998d885fbe646a1e4b4ebb"],"X-Signature":["bfwqigxtADZdL+x/fay8Cnc7ywg="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:33:06 GMT"],"Etag":["\"d1552a6205bb49ef2408979e7e1b14be\""],"Server":["openresty"],"Set-Cookie":["_session_id=f51e79a5bcc9d052003572196bddd329; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["475474b8fea62d323283b867d3b920b5"],"X-Runtime":["0.122915"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["265"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":5,\"$startIndex\":0,\"$itemsPerPage\":20,\"$resources\":[{\"id\":7,\"description\":\"Foo\",\"product_code\":\"\",\"extra_info\":\"\",\"sales_price\":\"0.0\",\"sales_price_includes_tax\":0,\"last_cost_price\":\"0.0\",\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":0,\"$key\":7},{\"id\":8,\"description\":\"Foo\",\"product_code\":\"\",\"extra_info\":\"\",\"sales_price\":\"0.0\",\"sales_price_includes_tax\":0,\"last_cost_price\":\"0.0\",\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":0,\"$key\":8},{\"id\":4,\"description\":\"Product 1\",\"product_code\":\"Bar\",\"extra_info\":\"\",\"sales_price\":\"0.0\",\"sales_price_includes_tax\":0,\"last_cost_price\":\"0.0\",\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":1,\"$key\":4},{\"id\":5,\"description\":\"Product 2\",\"product_code\":\"\",\"extra_info\":\"\",\"sales_price\":\"0.0\",\"sales_price_includes_tax\":0,\"last_cost_price\":\"0.0\",\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":0,\"$key\":5},{\"id\":6,\"description\":\"Product 3\",\"product_code\":\"\",\"extra_info\":\"\",\"sales_price\":\"0.0\",\"sales_price_includes_tax\":0,\"last_cost_price\":\"0.0\",\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":0,\"$key\":6}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:33:05 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"put","uri":"https://api.sageone.com/accounts/v1/products/7","body":{"encoding":"UTF-8","string":"product%5Bproduct_code%5D=Bar"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["a252bac7dc3d38f6ea44cc1972c556aa"],"X-Signature":["Biio+TD/BtQiW/OkSgevCb1MSSU="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:33:08 GMT"],"Etag":["\"4e496db49e3514594d7291a8bf07e78a\""],"Server":["openresty"],"Set-Cookie":["_session_id=1f53a33b570b3d1c04a9e605e70d8146; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["9fdf7b2b666aba259bca5a330c58c691"],"X-Runtime":["0.090077"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["168"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":7,\"description\":\"Foo\",\"product_code\":\"Bar\",\"extra_info\":\"\",\"sales_price\":\"0.0\",\"sales_price_includes_tax\":0,\"last_cost_price\":\"0.0\",\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":1,\"$key\":7}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:33:07 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/purchase_invoices","body":{"encoding":"UTF-8","string":"purchase_invoice%5Bcontact_id%5D=582\u0026purchase_invoice%5Bcontact_name%5D=Bar\u0026purchase_invoice%5Bdate%5D=31%2F12%2F2014\u0026purchase_invoice%5Bdue_date%5D=15%2F01%2F2015\u0026purchase_invoice%5Bline_items_attributes%5D%5B0%5D%5Bdescription%5D=A1\u0026purchase_invoice%5Bline_items_attributes%5D%5B0%5D%5Bledger_account_id%5D=7718\u0026purchase_invoice%5Bline_items_attributes%5D%5B0%5D%5Bquantity%5D=1\u0026purchase_invoice%5Bline_items_attributes%5D%5B0%5D%5Btax_code_id%5D=1\u0026purchase_invoice%5Bline_items_attributes%5D%5B0%5D%5Bunit_price%5D=10\u0026purchase_invoice%5Bline_items_attributes%5D%5B1%5D%5Bdescription%5D=B1\u0026purchase_invoice%5Bline_items_attributes%5D%5B1%5D%5Bledger_account_id%5D=7718\u0026purchase_invoice%5Bline_items_attributes%5D%5B1%5D%5Bquantity%5D=5\u0026purchase_invoice%5Bline_items_attributes%5D%5B1%5D%5Btax_code_id%5D=1\u0026purchase_invoice%5Bline_items_attributes%5D%5B1%5D%5Bunit_price%5D=9.99\u0026purchase_invoice%5Breference%5D=Foo"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["0199ae016143f8f1bf92cf5d738b3240"],"X-Signature":["jVUCwoFsgeGBVXHAui0qjyACraI="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":201,"message":"Created"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 14:53:17 GMT"],"Etag":["\"7a05e119506592e6ce7ccba2415379be\""],"Server":["openresty"],"Status":["201"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["c52785ecc4aeb79323249913e7f5490d"],"X-Runtime":["0.180365"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["421"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":1049,\"status\":{\"id\":1,\"$key\":1},\"due_date\":\"15/01/2015\",\"date\":\"31/12/2014\",\"void_reason\":null,\"outstanding_amount\":\"59.95\",\"total_net_amount\":\"59.95\",\"total_tax_amount\":\"0.0\",\"tax_scheme_period_id\":117,\"contact\":{\"id\":582,\"$key\":582},\"contact_name\":\"Bar\",\"main_address\":null,\"delivery_address\":null,\"delivery_address_same_as_main\":false,\"reference\":\"Foo\",\"notes\":null,\"terms_and_conditions\":null,\"lock_version\":0,\"line_items\":[{\"id\":181,\"description\":\"A1\",\"quantity\":\"1.0\",\"unit_price\":\"10.0\",\"net_amount\":\"10.0\",\"tax_amount\":\"0.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"0.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7718,\"$key\":7718},\"product_code\":null,\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":181},{\"id\":182,\"description\":\"B1\",\"quantity\":\"5.0\",\"unit_price\":\"9.99\",\"net_amount\":\"49.95\",\"tax_amount\":\"0.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"0.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7718,\"$key\":7718},\"product_code\":null,\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":182}],\"$key\":1049}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 14:53:17 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/purchase_invoices","body":{"encoding":"UTF-8","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["0488247773214310a0644ceb6284eb6b"],"X-Signature":["Z2wCfFaB5h6Jo3Hg0hArMZVeqPQ="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":422,"message":"Unprocessable Entity"},"headers":{"Cache-Control":["no-cache"],"Content-Type":["text/html; charset=UTF-8"],"Date":["Wed, 31 Dec 2014 14:53:17 GMT"],"Server":["openresty"],"Status":["422"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["ca79b62076fe63426d720f43557b9dbe"],"X-Runtime":["0.020970"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["108"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$diagnoses\":[{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"invalid date\",\"$source\":\"date\"}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 14:53:17 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"delete","uri":"https://api.sageone.com/accounts/v1/purchase_invoices/1050","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["f54903481c0ca199c3e0008076502ef7"],"X-Signature":["BIMhvjETQmK7g4iOmzIS9+OQeUk="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 14:55:47 GMT"],"Etag":["\"c97ac0120502535d8624ec10156fc625\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["c08c4f34812aeb6c88a8b89b83fe5c14"],"X-Runtime":["0.231690"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["388"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"purchase_invoice\":{\"artefact_number\":null,\"artefact_number_prefix\":null,\"business_id\":130,\"carriage\":\"0.0\",\"carriage_tax_code_id\":null,\"carriage_tax_rate_percentage\":\"0.0\",\"contact_id\":582,\"contact_name\":\"Bar\",\"created_at\":\"2014-12-31T14:55:47+00:00\",\"date\":\"2014-12-31\",\"delivery_address\":null,\"delivery_address_same_as_main\":false,\"due_date\":\"2015-01-15\",\"email_to\":null,\"id\":1050,\"is_opening_balance\":false,\"lock_version\":1,\"main_address\":null,\"notes\":null,\"outstanding_amount\":\"0.0\",\"pdf_file_id\":null,\"reference\":\"Foo\",\"status_id\":4,\"tax_scheme_period_id\":117,\"terms_and_conditions\":null,\"total_net_amount\":\"59.95\",\"total_tax_amount\":\"0.0\",\"updated_at\":\"2014-12-31T14:55:47+00:00\",\"void_reason\":\"no void reason supplied\",\"$key\":1050},\"$key\":1050}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 14:55:47 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/purchase_invoices/1049","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["896626be3c741df0d8c0685f68b5227a"],"X-Signature":["IwJ+rwFXtJMkkoAQl8tihGEsEws="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 14:55:03 GMT"],"Etag":["\"7a05e119506592e6ce7ccba2415379be\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["536e9af3931a74621603aeb2d262db97"],"X-Runtime":["0.034428"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["421"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":1049,\"status\":{\"id\":1,\"$key\":1},\"due_date\":\"15/01/2015\",\"date\":\"31/12/2014\",\"void_reason\":null,\"outstanding_amount\":\"59.95\",\"total_net_amount\":\"59.95\",\"total_tax_amount\":\"0.0\",\"tax_scheme_period_id\":117,\"contact\":{\"id\":582,\"$key\":582},\"contact_name\":\"Bar\",\"main_address\":null,\"delivery_address\":null,\"delivery_address_same_as_main\":false,\"reference\":\"Foo\",\"notes\":null,\"terms_and_conditions\":null,\"lock_version\":0,\"line_items\":[{\"id\":181,\"description\":\"A1\",\"quantity\":\"1.0\",\"unit_price\":\"10.0\",\"net_amount\":\"10.0\",\"tax_amount\":\"0.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"0.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7718,\"$key\":7718},\"product_code\":null,\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":181},{\"id\":182,\"description\":\"B1\",\"quantity\":\"5.0\",\"unit_price\":\"9.99\",\"net_amount\":\"49.95\",\"tax_amount\":\"0.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"0.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7718,\"$key\":7718},\"product_code\":null,\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":182}],\"$key\":1049}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 14:55:03 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/purchase_invoices?$itemsPerPage=2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["3fe978a64c7851a156f25043b8f439d5"],"X-Signature":["n8og0ccy48icW4/0PWApmLxiGS8="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 14:53:16 GMT"],"Etag":["\"4715779d6ab1b39f7fc528dc1dc5f7dd\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["2e85a5a5ee1b15db4ae16944f578f0b2"],"X-Runtime":["0.044305"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["515"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":2,\"$startIndex\":0,\"$itemsPerPage\":2,\"$resources\":[{\"id\":1048,\"status\":{\"id\":1,\"$key\":1},\"due_date\":\"30/01/2015\",\"date\":\"31/12/2014\",\"void_reason\":null,\"outstanding_amount\":\"500.0\",\"total_net_amount\":\"500.0\",\"total_tax_amount\":\"0.0\",\"tax_scheme_period_id\":117,\"contact\":{\"id\":582,\"$key\":582},\"contact_name\":\"Bar\",\"main_address\":null,\"delivery_address\":null,\"delivery_address_same_as_main\":false,\"reference\":\"\",\"notes\":\"\",\"terms_and_conditions\":null,\"lock_version\":0,\"line_items\":[{\"id\":180,\"description\":\"Bar\",\"quantity\":\"5.0\",\"unit_price\":\"100.0\",\"net_amount\":\"500.0\",\"tax_amount\":\"0.0\",\"tax_code\":{\"id\":4,\"$key\":4},\"tax_rate_percentage\":\"0.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7722,\"$key\":7722},\"product_code\":null,\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":180}],\"$key\":1048},{\"id\":1047,\"status\":{\"id\":1,\"$key\":1},\"due_date\":\"30/01/2015\",\"date\":\"31/12/2014\",\"void_reason\":null,\"outstanding_amount\":\"10.5\",\"total_net_amount\":\"10.0\",\"total_tax_amount\":\"0.5\",\"tax_scheme_period_id\":117,\"contact\":{\"id\":581,\"$key\":581},\"contact_name\":\"Foo\",\"main_address\":null,\"delivery_address\":null,\"delivery_address_same_as_main\":false,\"reference\":\"\",\"notes\":\"\",\"terms_and_conditions\":null,\"lock_version\":0,\"line_items\":[{\"id\":179,\"description\":\"Foo\",\"quantity\":\"1.0\",\"unit_price\":\"10.0\",\"net_amount\":\"10.0\",\"tax_amount\":\"0.5\",\"tax_code\":{\"id\":2,\"$key\":2},\"tax_rate_percentage\":\"5.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7718,\"$key\":7718},\"product_code\":null,\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":179}],\"$key\":1047}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 14:53:16 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/purchase_invoices","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["577c6052566e7647f6f96965a4ffe4f2"],"X-Signature":["yzrNiVxBoLcI1jBpt2Y9yV09n8E="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 14:53:16 GMT"],"Etag":["\"4a9ca60d7c3b6eb108040f313ccf3965\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["e7fd7844fe17a4c22b17594b2047e199"],"X-Runtime":["0.143572"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["516"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":2,\"$startIndex\":0,\"$itemsPerPage\":20,\"$resources\":[{\"id\":1048,\"status\":{\"id\":1,\"$key\":1},\"due_date\":\"30/01/2015\",\"date\":\"31/12/2014\",\"void_reason\":null,\"outstanding_amount\":\"500.0\",\"total_net_amount\":\"500.0\",\"total_tax_amount\":\"0.0\",\"tax_scheme_period_id\":117,\"contact\":{\"id\":582,\"$key\":582},\"contact_name\":\"Bar\",\"main_address\":null,\"delivery_address\":null,\"delivery_address_same_as_main\":false,\"reference\":\"\",\"notes\":\"\",\"terms_and_conditions\":null,\"lock_version\":0,\"line_items\":[{\"id\":180,\"description\":\"Bar\",\"quantity\":\"5.0\",\"unit_price\":\"100.0\",\"net_amount\":\"500.0\",\"tax_amount\":\"0.0\",\"tax_code\":{\"id\":4,\"$key\":4},\"tax_rate_percentage\":\"0.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7722,\"$key\":7722},\"product_code\":null,\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":180}],\"$key\":1048},{\"id\":1047,\"status\":{\"id\":1,\"$key\":1},\"due_date\":\"30/01/2015\",\"date\":\"31/12/2014\",\"void_reason\":null,\"outstanding_amount\":\"10.5\",\"total_net_amount\":\"10.0\",\"total_tax_amount\":\"0.5\",\"tax_scheme_period_id\":117,\"contact\":{\"id\":581,\"$key\":581},\"contact_name\":\"Foo\",\"main_address\":null,\"delivery_address\":null,\"delivery_address_same_as_main\":false,\"reference\":\"\",\"notes\":\"\",\"terms_and_conditions\":null,\"lock_version\":0,\"line_items\":[{\"id\":179,\"description\":\"Foo\",\"quantity\":\"1.0\",\"unit_price\":\"10.0\",\"net_amount\":\"10.0\",\"tax_amount\":\"0.5\",\"tax_code\":{\"id\":2,\"$key\":2},\"tax_rate_percentage\":\"5.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7718,\"$key\":7718},\"product_code\":null,\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":179}],\"$key\":1047}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 14:53:16 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"put","uri":"https://api.sageone.com/accounts/v1/purchase_invoices/1049","body":{"encoding":"UTF-8","string":"purchase_invoice%5Breference%5D=Bar"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["c6a6d19750526151cc8f7b04f2660122"],"X-Signature":["jkOPDnm2DHq4mtdJ9sbYVFXKOhU="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 14:55:03 GMT"],"Etag":["\"ccd7463b5f7cbef9e598b7d4ad455088\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["908b4f595dce5aa95fee30118b7e8a65"],"X-Runtime":["0.298030"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["417"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":1049,\"status\":{\"id\":1,\"$key\":1},\"due_date\":\"15/01/2015\",\"date\":\"31/12/2014\",\"void_reason\":null,\"outstanding_amount\":\"59.95\",\"total_net_amount\":\"59.95\",\"total_tax_amount\":\"0.0\",\"tax_scheme_period_id\":117,\"contact\":{\"id\":582,\"$key\":582},\"contact_name\":\"Bar\",\"main_address\":null,\"delivery_address\":null,\"delivery_address_same_as_main\":false,\"reference\":\"Bar\",\"notes\":null,\"terms_and_conditions\":null,\"lock_version\":1,\"line_items\":[{\"id\":181,\"description\":\"A1\",\"quantity\":\"1.0\",\"unit_price\":\"10.0\",\"net_amount\":\"10.0\",\"tax_amount\":\"0.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"0.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7718,\"$key\":7718},\"product_code\":null,\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":181},{\"id\":182,\"description\":\"B1\",\"quantity\":\"5.0\",\"unit_price\":\"9.99\",\"net_amount\":\"49.95\",\"tax_amount\":\"0.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"0.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7718,\"$key\":7718},\"product_code\":null,\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":182}],\"$key\":1049}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 14:55:03 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/contacts?contact_type_id=1","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["72b0429632b63402c5fdadd5f40c39d8"],"X-Signature":["thV1URoo+LlipVg/j8Nn5THL0rI="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 13:57:13 GMT"],"Etag":["\"e5689e568afa48a54a69c87b4f4fc459\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["854a67e849860f5550dff6d7fc3fc778"],"X-Runtime":["0.044786"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["372"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"[{\"id\":580,\"name\":\"Lorem\",\"company_name\":\"\",\"name_and_company_name\":\"Lorem\",\"contact_type\":{\"id\":1,\"$key\":1},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"lock_version\":0,\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":1225},\"delivery_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":1226},\"$key\":580},{\"id\":579,\"name\":\"Test\",\"company_name\":\"\",\"name_and_company_name\":\"Test\",\"contact_type\":{\"id\":1,\"$key\":1},\"email\":\"\",\"telephone\":\"\",\"mobile\":\"\",\"notes\":\"\",\"tax_reference\":\"\",\"lock_version\":0,\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":1223},\"delivery_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":1224},\"$key\":579},{\"id\":577,\"name\":\"\",\"company_name\":\"HMRC Payments\",\"name_and_company_name\":\"HMRC Payments\",\"contact_type\":{\"id\":2,\"$key\":2},\"email\":null,\"telephone\":null,\"mobile\":null,\"notes\":\"This contact is for recording HMRC payments for your VAT Return.\",\"tax_reference\":null,\"lock_version\":0,\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":1221},\"delivery_address\":{\"$key\":null},\"$key\":577},{\"id\":578,\"name\":\"\",\"company_name\":\"HMRC Reclaimed\",\"name_and_company_name\":\"HMRC Reclaimed\",\"contact_type\":{\"id\":1,\"$key\":1},\"email\":null,\"telephone\":null,\"mobile\":null,\"notes\":\"This contact is for recording HMRC payments for your VAT Return.\",\"tax_reference\":null,\"lock_version\":0,\"main_address\":{\"street_one\":\"\",\"street_two\":\"\",\"town\":\"\",\"county\":\"\",\"postcode\":\"\",\"country\":{\"$key\":null},\"$key\":1222},\"delivery_address\":{\"$key\":null},\"$key\":578}]"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 13:57:13 GMT"},{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/sales_invoices","body":{"encoding":"UTF-8","string":"sales_invoice%5Bcarriage_tax_code_id%5D=1\u0026sales_invoice%5Bcontact_id%5D=580\u0026sales_invoice%5Bcontact_name%5D=Lorem\u0026sales_invoice%5Bdate%5D=31%2F12%2F2014\u0026sales_invoice%5Bdue_date%5D=30%2F01%2F2015\u0026sales_invoice%5Bline_items_attributes%5D%5B0%5D%5Bdescription%5D=A1\u0026sales_invoice%5Bline_items_attributes%5D%5B0%5D%5Bledger_account_id%5D=7709\u0026sales_invoice%5Bline_items_attributes%5D%5B0%5D%5Bquantity%5D=1\u0026sales_invoice%5Bline_items_attributes%5D%5B0%5D%5Btax_code_id%5D=1\u0026sales_invoice%5Bline_items_attributes%5D%5B0%5D%5Bunit_price%5D=10\u0026sales_invoice%5Bline_items_attributes%5D%5B1%5D%5Bdescription%5D=B1\u0026sales_invoice%5Bline_items_attributes%5D%5B1%5D%5Bledger_account_id%5D=7709\u0026sales_invoice%5Bline_items_attributes%5D%5B1%5D%5Bquantity%5D=5\u0026sales_invoice%5Bline_items_attributes%5D%5B1%5D%5Btax_code_id%5D=1\u0026sales_invoice%5Bline_items_attributes%5D%5B1%5D%5Bunit_price%5D=9.99\u0026sales_invoice%5Bmain_address%5D=Main+Address\u0026sales_invoice%5Breference%5D=Foo"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["500201f3c505a41bed7e1d0f274fac19"],"X-Signature":["Hr0YNrLlTa8ELue083suSvGPCcM="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":201,"message":"Created"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 14:29:33 GMT"],"Etag":["\"b12694bf3bad486deec4bb5869d7b53b\""],"Server":["openresty"],"Status":["201"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["685713556442df5957be6882118158e2"],"X-Runtime":["0.200169"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["469"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":1042,\"invoice_number\":\"SI-10\",\"status\":{\"id\":1,\"$key\":1},\"due_date\":\"30/01/2015\",\"date\":\"31/12/2014\",\"void_reason\":null,\"outstanding_amount\":\"59.95\",\"total_net_amount\":\"59.95\",\"total_tax_amount\":\"0.0\",\"tax_scheme_period_id\":117,\"carriage\":\"0.0\",\"carriage_tax_code\":{\"id\":1,\"$key\":1},\"carriage_tax_rate_percentage\":\"0.0\",\"contact\":{\"id\":580,\"$key\":580},\"contact_name\":\"Lorem\",\"main_address\":\"Main Address\",\"delivery_address\":null,\"delivery_address_same_as_main\":false,\"reference\":\"Foo\",\"notes\":null,\"terms_and_conditions\":null,\"lock_version\":0,\"line_items\":[{\"id\":173,\"description\":\"A1\",\"quantity\":\"1.0\",\"unit_price\":\"10.0\",\"net_amount\":\"10.0\",\"tax_amount\":\"0.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"0.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7709,\"$key\":7709},\"product_code\":null,\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":173},{\"id\":174,\"description\":\"B1\",\"quantity\":\"5.0\",\"unit_price\":\"9.99\",\"net_amount\":\"49.95\",\"tax_amount\":\"0.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"0.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7709,\"$key\":7709},\"product_code\":null,\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":174}],\"$key\":1042}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 14:29:33 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/sales_invoices","body":{"encoding":"UTF-8","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["1c928c7507533171e7e54ccb76992415"],"X-Signature":["Ki0sRswacTCnFViHJMqh95vnGWw="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":422,"message":"Unprocessable Entity"},"headers":{"Cache-Control":["no-cache"],"Content-Type":["text/html; charset=UTF-8"],"Date":["Wed, 31 Dec 2014 14:53:17 GMT"],"Server":["openresty"],"Status":["422"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["ca79b62076fe63426d720f43557b9dbe"],"X-Runtime":["0.020970"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["108"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$diagnoses\":[{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"invalid date\",\"$source\":\"date\"}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 14:53:17 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"delete","uri":"https://api.sageone.com/accounts/v1/sales_invoices/1044","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["533b9ac1b8fabe5fff68bf233721e8fb"],"X-Signature":["scMiVJYzLeLd2uPQW5dxUzvwsN4="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 14:46:59 GMT"],"Etag":["\"bc2c03885c4d3fa66305fd0ce29e9b36\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["a379e5a4d5e1a69a3d90500a374dc692"],"X-Runtime":["0.137173"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["405"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"sales_invoice\":{\"artefact_number\":12,\"artefact_number_prefix\":\"SI-\",\"business_id\":130,\"carriage\":\"0.0\",\"carriage_tax_code_id\":1,\"carriage_tax_rate_percentage\":\"0.0\",\"contact_id\":580,\"contact_name\":\"Lorem\",\"created_at\":\"2014-12-31T14:46:47+00:00\",\"date\":\"2014-12-31\",\"delivery_address\":null,\"delivery_address_same_as_main\":false,\"due_date\":\"2015-01-15\",\"email_to\":null,\"id\":1044,\"is_opening_balance\":false,\"lock_version\":1,\"main_address\":\"Main Address\",\"notes\":null,\"outstanding_amount\":\"0.0\",\"pdf_file_id\":null,\"reference\":\"Foo\",\"status_id\":4,\"tax_scheme_period_id\":117,\"terms_and_conditions\":null,\"total_net_amount\":\"59.95\",\"total_tax_amount\":\"0.0\",\"updated_at\":\"2014-12-31T14:46:58+00:00\",\"void_reason\":\"no void reason supplied\",\"$key\":1044},\"$key\":1044}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 14:46:59 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/sales_invoices/1034","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["8a048cf44873e7228404012bfc7527ae"],"X-Signature":["lXsghaRRY94fbEDv7EkgQZ5mdmI="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 13:48:18 GMT"],"Etag":["\"b310b2ef14c5163b0072be67a7d05c45\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["acbafbfc82bbe45ec72fb6a70a94cfe3"],"X-Runtime":["0.036089"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["494"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":1034,\"invoice_number\":\"SI-2\",\"status\":{\"id\":1,\"$key\":1},\"due_date\":\"30/01/2015\",\"date\":\"31/12/2014\",\"void_reason\":null,\"outstanding_amount\":\"21.46\",\"total_net_amount\":\"17.88\",\"total_tax_amount\":\"3.58\",\"tax_scheme_period_id\":117,\"carriage\":\"0.0\",\"carriage_tax_code\":{\"id\":1,\"$key\":1},\"carriage_tax_rate_percentage\":\"20.0\",\"contact\":{\"id\":580,\"$key\":580},\"contact_name\":\"Lorem\",\"main_address\":\"Main Address\",\"delivery_address\":\"\",\"delivery_address_same_as_main\":false,\"reference\":\"\",\"notes\":\"\",\"terms_and_conditions\":\"\",\"lock_version\":0,\"line_items\":[{\"id\":158,\"description\":\"Baz\",\"quantity\":\"2.0\",\"unit_price\":\"3.99\",\"net_amount\":\"7.98\",\"tax_amount\":\"1.6\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"20.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7710,\"$key\":7710},\"product_code\":\"B2\",\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":158},{\"id\":159,\"description\":\"Qux\",\"quantity\":\"10.0\",\"unit_price\":\"0.99\",\"net_amount\":\"9.9\",\"tax_amount\":\"1.98\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"20.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7710,\"$key\":7710},\"product_code\":\"Q1\",\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":159}],\"$key\":1034}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 13:48:18 GMT"},{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/sales_invoices/1033","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["ca30dcb30d4db13b4b358869f00181f2"],"X-Signature":["NPk80IoqvhnryooSqBhW+UeQhVg="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 13:52:22 GMT"],"Etag":["\"e212b1f93acad9e33448b627ac9f27e5\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["29fab8717d1b859f78af1d2a3c919da0"],"X-Runtime":["0.038656"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["495"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":1033,\"invoice_number\":\"SI-1\",\"status\":{\"id\":1,\"$key\":1},\"due_date\":\"30/01/2015\",\"date\":\"31/12/2014\",\"void_reason\":null,\"outstanding_amount\":\"89.93\",\"total_net_amount\":\"74.94\",\"total_tax_amount\":\"14.99\",\"tax_scheme_period_id\":117,\"carriage\":\"0.0\",\"carriage_tax_code\":{\"id\":1,\"$key\":1},\"carriage_tax_rate_percentage\":\"20.0\",\"contact\":{\"id\":579,\"$key\":579},\"contact_name\":\"Test\",\"main_address\":\"Main Address\",\"delivery_address\":\"\",\"delivery_address_same_as_main\":false,\"reference\":\"Ref12345\",\"notes\":\"\",\"terms_and_conditions\":\"\",\"lock_version\":0,\"line_items\":[{\"id\":156,\"description\":\"Foo\",\"quantity\":\"1.0\",\"unit_price\":\"9.99\",\"net_amount\":\"9.99\",\"tax_amount\":\"2.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"20.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7710,\"$key\":7710},\"product_code\":\"F1\",\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":156},{\"id\":157,\"description\":\"Bar\",\"quantity\":\"5.0\",\"unit_price\":\"12.99\",\"net_amount\":\"64.95\",\"tax_amount\":\"12.99\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"20.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7710,\"$key\":7710},\"product_code\":\"B1\",\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":157}],\"$key\":1033}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 13:52:22 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/sales_invoices?$itemsPerPage=2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["dc0a7635d749f4e98e4be0f76a9eabde"],"X-Signature":["LllomEP+NJh2NR0M2YWq9e3ltUM="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 13:42:22 GMT"],"Etag":["\"2ccbe32c23f4286cafe97fd92c1c3d2c\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["75f2b95d39d4887a6f22503bb3e1518f"],"X-Runtime":["0.054873"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["654"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":2,\"$startIndex\":0,\"$itemsPerPage\":2,\"$resources\":[{\"id\":1034,\"invoice_number\":\"SI-2\",\"status\":{\"id\":1,\"$key\":1},\"due_date\":\"30/01/2015\",\"date\":\"31/12/2014\",\"void_reason\":null,\"outstanding_amount\":\"21.46\",\"total_net_amount\":\"17.88\",\"total_tax_amount\":\"3.58\",\"tax_scheme_period_id\":117,\"carriage\":\"0.0\",\"carriage_tax_code\":{\"id\":1,\"$key\":1},\"carriage_tax_rate_percentage\":\"20.0\",\"contact\":{\"id\":580,\"$key\":580},\"contact_name\":\"Lorem\",\"main_address\":\"Main Address\",\"delivery_address\":\"\",\"delivery_address_same_as_main\":false,\"reference\":\"\",\"notes\":\"\",\"terms_and_conditions\":\"\",\"lock_version\":0,\"line_items\":[{\"id\":158,\"description\":\"Baz\",\"quantity\":\"2.0\",\"unit_price\":\"3.99\",\"net_amount\":\"7.98\",\"tax_amount\":\"1.6\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"20.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7710,\"$key\":7710},\"product_code\":\"B2\",\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":158},{\"id\":159,\"description\":\"Qux\",\"quantity\":\"10.0\",\"unit_price\":\"0.99\",\"net_amount\":\"9.9\",\"tax_amount\":\"1.98\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"20.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7710,\"$key\":7710},\"product_code\":\"Q1\",\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":159}],\"$key\":1034},{\"id\":1033,\"invoice_number\":\"SI-1\",\"status\":{\"id\":1,\"$key\":1},\"due_date\":\"30/01/2015\",\"date\":\"31/12/2014\",\"void_reason\":null,\"outstanding_amount\":\"89.93\",\"total_net_amount\":\"74.94\",\"total_tax_amount\":\"14.99\",\"tax_scheme_period_id\":117,\"carriage\":\"0.0\",\"carriage_tax_code\":{\"id\":1,\"$key\":1},\"carriage_tax_rate_percentage\":\"20.0\",\"contact\":{\"id\":579,\"$key\":579},\"contact_name\":\"Test\",\"main_address\":\"Main Address\",\"delivery_address\":\"\",\"delivery_address_same_as_main\":false,\"reference\":\"Ref12345\",\"notes\":\"\",\"terms_and_conditions\":\"\",\"lock_version\":0,\"line_items\":[{\"id\":156,\"description\":\"Foo\",\"quantity\":\"1.0\",\"unit_price\":\"9.99\",\"net_amount\":\"9.99\",\"tax_amount\":\"2.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"20.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7710,\"$key\":7710},\"product_code\":\"F1\",\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":156},{\"id\":157,\"description\":\"Bar\",\"quantity\":\"5.0\",\"unit_price\":\"12.99\",\"net_amount\":\"64.95\",\"tax_amount\":\"12.99\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"20.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7710,\"$key\":7710},\"product_code\":\"B1\",\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":157}],\"$key\":1033}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 13:42:22 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/sales_invoices","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["412237c55b10f1207ad251be58b64c53"],"X-Signature":["qHTIlJZXTx22dbmI6ameLY+9D64="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 13:42:21 GMT"],"Etag":["\"ca6b6e18c96ea1d964ff5d85c8e9dbd4\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["bb4dc50804f9ae51d57116583024925e"],"X-Runtime":["0.154137"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["655"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":2,\"$startIndex\":0,\"$itemsPerPage\":20,\"$resources\":[{\"id\":1034,\"invoice_number\":\"SI-2\",\"status\":{\"id\":1,\"$key\":1},\"due_date\":\"30/01/2015\",\"date\":\"31/12/2014\",\"void_reason\":null,\"outstanding_amount\":\"21.46\",\"total_net_amount\":\"17.88\",\"total_tax_amount\":\"3.58\",\"tax_scheme_period_id\":117,\"carriage\":\"0.0\",\"carriage_tax_code\":{\"id\":1,\"$key\":1},\"carriage_tax_rate_percentage\":\"20.0\",\"contact\":{\"id\":580,\"$key\":580},\"contact_name\":\"Lorem\",\"main_address\":\"Main Address\",\"delivery_address\":\"\",\"delivery_address_same_as_main\":false,\"reference\":\"\",\"notes\":\"\",\"terms_and_conditions\":\"\",\"lock_version\":0,\"line_items\":[{\"id\":158,\"description\":\"Baz\",\"quantity\":\"2.0\",\"unit_price\":\"3.99\",\"net_amount\":\"7.98\",\"tax_amount\":\"1.6\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"20.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7710,\"$key\":7710},\"product_code\":\"B2\",\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":158},{\"id\":159,\"description\":\"Qux\",\"quantity\":\"10.0\",\"unit_price\":\"0.99\",\"net_amount\":\"9.9\",\"tax_amount\":\"1.98\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"20.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7710,\"$key\":7710},\"product_code\":\"Q1\",\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":159}],\"$key\":1034},{\"id\":1033,\"invoice_number\":\"SI-1\",\"status\":{\"id\":1,\"$key\":1},\"due_date\":\"30/01/2015\",\"date\":\"31/12/2014\",\"void_reason\":null,\"outstanding_amount\":\"89.93\",\"total_net_amount\":\"74.94\",\"total_tax_amount\":\"14.99\",\"tax_scheme_period_id\":117,\"carriage\":\"0.0\",\"carriage_tax_code\":{\"id\":1,\"$key\":1},\"carriage_tax_rate_percentage\":\"20.0\",\"contact\":{\"id\":579,\"$key\":579},\"contact_name\":\"Test\",\"main_address\":\"Main Address\",\"delivery_address\":\"\",\"delivery_address_same_as_main\":false,\"reference\":\"Ref12345\",\"notes\":\"\",\"terms_and_conditions\":\"\",\"lock_version\":0,\"line_items\":[{\"id\":156,\"description\":\"Foo\",\"quantity\":\"1.0\",\"unit_price\":\"9.99\",\"net_amount\":\"9.99\",\"tax_amount\":\"2.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"20.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7710,\"$key\":7710},\"product_code\":\"F1\",\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":156},{\"id\":157,\"description\":\"Bar\",\"quantity\":\"5.0\",\"unit_price\":\"12.99\",\"net_amount\":\"64.95\",\"tax_amount\":\"12.99\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"20.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7710,\"$key\":7710},\"product_code\":\"B1\",\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":157}],\"$key\":1033}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 13:42:21 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"put","uri":"https://api.sageone.com/accounts/v1/sales_invoices/1043","body":{"encoding":"UTF-8","string":"sales_invoice%5Breference%5D=Bar"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["3da846e0aac9758f122066c8ff2c1302"],"X-Signature":["KUwK/hZuM9A70DgjxQX7ietJASE="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 14:37:27 GMT"],"Etag":["\"16bbd781cba6ed211960f3b1787fbeec\""],"Server":["openresty"],"Status":["200"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["af0db95d35d574f999c4f6ef1c22a126"],"X-Runtime":["0.315918"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["470"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":1043,\"invoice_number\":\"SI-11\",\"status\":{\"id\":1,\"$key\":1},\"due_date\":\"30/01/2015\",\"date\":\"31/12/2014\",\"void_reason\":null,\"outstanding_amount\":\"59.95\",\"total_net_amount\":\"59.95\",\"total_tax_amount\":\"0.0\",\"tax_scheme_period_id\":117,\"carriage\":\"0.0\",\"carriage_tax_code\":{\"id\":1,\"$key\":1},\"carriage_tax_rate_percentage\":\"0.0\",\"contact\":{\"id\":580,\"$key\":580},\"contact_name\":\"Lorem\",\"main_address\":\"Main Address\",\"delivery_address\":null,\"delivery_address_same_as_main\":false,\"reference\":\"Bar\",\"notes\":null,\"terms_and_conditions\":null,\"lock_version\":1,\"line_items\":[{\"id\":175,\"description\":\"A1\",\"quantity\":\"1.0\",\"unit_price\":\"10.0\",\"net_amount\":\"10.0\",\"tax_amount\":\"0.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"0.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7709,\"$key\":7709},\"product_code\":null,\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":175},{\"id\":176,\"description\":\"B1\",\"quantity\":\"5.0\",\"unit_price\":\"9.99\",\"net_amount\":\"49.95\",\"tax_amount\":\"0.0\",\"tax_code\":{\"id\":1,\"$key\":1},\"tax_rate_percentage\":\"0.0\",\"unit_price_includes_tax\":false,\"ledger_account\":{\"id\":7709,\"$key\":7709},\"product_code\":null,\"product\":{\"$key\":null},\"service\":{\"$key\":null},\"lock_version\":0,\"$key\":176}],\"$key\":1043}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 14:37:27 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/services","body":{"encoding":"UTF-8","string":"service%5Bdescription%5D=Foo"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["c4dc4bdc7ca8b3a3d0e7532eaf13009d"],"X-Signature":["3jDku4KL+9xAeswLoOFSHVUJXIE="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":201,"message":"Created"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:35:27 GMT"],"Etag":["\"5fb48e59bf52ba1fe5dcae48f1162375\""],"Server":["openresty"],"Set-Cookie":["_session_id=52ece560c12fd1b55fab356c3354baa8; path=/; secure; HttpOnly"],"Status":["201"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["247fe9d4996175f6eceb2d77de077973"],"X-Runtime":["0.088930"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["157"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":8,\"description\":\"Foo\",\"extra_info\":\"\",\"period_rate_price\":\"0.0\",\"rate_includes_tax\":0,\"period_type\":{\"id\":1,\"$key\":1},\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":0,\"$key\":8}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:35:26 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"post","uri":"https://api.sageone.com/accounts/v1/services","body":{"encoding":"UTF-8","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["b01dc375a8cac1384a5cd3a2608501e2"],"X-Signature":["opyxCm1e21fqpgtgvEYOe0/Da6Y="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":422,"message":"Unprocessable Entity"},"headers":{"Cache-Control":["no-cache"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Wed, 31 Dec 2014 10:16:52 GMT"],"Server":["openresty"],"Status":["422"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["e3024fd5fb016f45724406844aad3973"],"X-Runtime":["0.127173"],"X-Server":["accounts.sageone.com (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["167"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$diagnoses\":[{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"/ Type of Sale is invalid\",\"$source\":\"ledger_account\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"must be a valid type of income\",\"$source\":\"ledger_account\"},{\"$severity\":\"error\",\"$dataCode\":\"ValidationError\",\"$message\":\"blank\",\"$source\":\"description\"}]}"},"http_version":null},"recorded_at":"Wed, 31 Dec 2014 10:16:52 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"delete","uri":"https://api.sageone.com/accounts/v1/services/9","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["21a4a361b13379d4dc58afad3076d05f"],"X-Signature":["hTnOlgtgGT7xFsQbcW734ArfGVY="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:35:28 GMT"],"Etag":["\"d61bce685838729b67f4668e28cb565d\""],"Server":["openresty"],"Set-Cookie":["_session_id=bae13ca2778e974eea78b1eef1d9d8a4; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["6ebd51d41b3de428e2ac4a503526ad32"],"X-Runtime":["0.058392"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["156"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":9,\"description\":\"Foo\",\"extra_info\":\"\",\"period_rate_price\":\"0.0\",\"rate_includes_tax\":0,\"period_type\":{\"id\":1,\"$key\":1},\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":0,\"$key\":9}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:35:27 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/services/4","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["b0b50af69d8d0cd92c93af95c1883f58"],"X-Signature":["wD3ffwLVyjHmptOTg0SihCdc26c="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:35:26 GMT"],"Etag":["\"90770455f279a4b18f9218c532c17610\""],"Server":["openresty"],"Set-Cookie":["_session_id=eee7a9a30aeb1ffff8ad24c8b5ee1e3e; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["24d5856c2d48176a80a994db6789f817"],"X-Runtime":["0.046950"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["156"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":4,\"description\":\"Foo\",\"extra_info\":\"\",\"period_rate_price\":\"0.0\",\"rate_includes_tax\":0,\"period_type\":{\"id\":1,\"$key\":1},\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":0,\"$key\":4}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:35:26 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/services?$itemsPerPage=2","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["914b725561596dff2c465406729bbe9b"],"X-Signature":["v0GdF6bsoGPn6qhYX88/py5Tnmg="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:35:26 GMT"],"Etag":["\"ec1b48859cc41fa5bd2ee3c6a45f6c0f\""],"Server":["openresty"],"Set-Cookie":["_session_id=73ef5740f565c481efe8e1148c69b5bc; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["2864a1fd5d33d87218059d35e4ede10f"],"X-Runtime":["0.074786"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["225"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":3,\"$startIndex\":0,\"$itemsPerPage\":2,\"$resources\":[{\"id\":4,\"description\":\"Foo\",\"extra_info\":\"\",\"period_rate_price\":\"0.0\",\"rate_includes_tax\":0,\"period_type\":{\"id\":1,\"$key\":1},\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":0,\"$key\":4},{\"id\":6,\"description\":\"Service 1\",\"extra_info\":\"\",\"period_rate_price\":\"0.0\",\"rate_includes_tax\":0,\"period_type\":{\"id\":1,\"$key\":1},\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":0,\"$key\":6}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:35:25 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/services","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["cfac074b23e1e54842807b873052cd94"],"X-Signature":["0nj/D68U84EbLmAdRBVn8dmV3p0="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:35:26 GMT"],"Etag":["\"46dc894cebc12638887e5be9c0fb12ad\""],"Server":["openresty"],"Set-Cookie":["_session_id=b43fedfc25917c4c0b8d47905a771304; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["1a593671f4c5297affa0b72b2bf5a3ef"],"X-Runtime":["0.090984"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["236"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$totalResults\":3,\"$startIndex\":0,\"$itemsPerPage\":20,\"$resources\":[{\"id\":4,\"description\":\"Foo\",\"extra_info\":\"\",\"period_rate_price\":\"0.0\",\"rate_includes_tax\":0,\"period_type\":{\"id\":1,\"$key\":1},\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":0,\"$key\":4},{\"id\":6,\"description\":\"Service 1\",\"extra_info\":\"\",\"period_rate_price\":\"0.0\",\"rate_includes_tax\":0,\"period_type\":{\"id\":1,\"$key\":1},\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":0,\"$key\":6},{\"id\":7,\"description\":\"Service 2\",\"extra_info\":\"\",\"period_rate_price\":\"0.0\",\"rate_includes_tax\":0,\"period_type\":{\"id\":1,\"$key\":1},\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":0,\"$key\":7}]}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:35:25 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"put","uri":"https://api.sageone.com/accounts/v1/services/4","body":{"encoding":"UTF-8","string":"service%5Bdescription%5D=Bar"},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["bce6dafbb815e7d51caf79fc36a71130"],"X-Signature":["l9+dVNBYpDGOoUhceB5Tvh9Sw2o="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["max-age=0, private, must-revalidate"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:37:03 GMT"],"Etag":["\"6528a5a542f568de8817172bebe95d5b\""],"Server":["openresty"],"Set-Cookie":["_session_id=84e27f6ec0447612f8be7c6758e5f855; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["invalidate, pass"],"X-Request-Id":["66425d39b4d3c10cb474ab9951899da2"],"X-Runtime":["0.086089"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["156"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":4,\"description\":\"Bar\",\"extra_info\":\"\",\"period_rate_price\":\"0.0\",\"rate_includes_tax\":0,\"period_type\":{\"id\":1,\"$key\":1},\"ledger_account\":{\"id\":494,\"$key\":494},\"tax_code\":{\"id\":1,\"$key\":1},\"lock_version\":2,\"$key\":4}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:37:02 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/tax_rates/1","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["1ed1a55c9c77b86cb95b9118b8ea447e"],"X-Signature":["FGuI2nBChbyRJS0cJAd4qd2OWs4="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":200,"message":"OK"},"headers":{"Cache-Control":["must-revalidate, private, max-age=0"],"Content-Type":["application/json;vnd.sage=sdata"],"Date":["Mon, 29 Sep 2014 16:21:27 GMT"],"Etag":["\"c54d28e94999fc59fe0799d31dcb7d26\""],"Server":["openresty"],"Set-Cookie":["_session_id=e16c4245249b942b746d0f2ef622b196; path=/; secure; HttpOnly"],"Status":["200"],"Strict-Transport-Security":["max-age=31536000"],"Vary":["Accept-Encoding"],"X-Rack-Cache":["miss"],"X-Request-Id":["758e436cf0beebe11f144ddc95e48cda"],"X-Runtime":["0.040198"],"X-Server":["ip-10-91-175-51 (uat)"],"X-Ua-Compatible":["IE=Edge,chrome=1"],"Content-Length":["84"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"id\":1,\"name\":\"Standard\",\"percentage\":\"20.0\",\"current\":true,\"$key\":1}"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:21:26 GMT"}],"recorded_with":"VCR 2.9.3"}
@@ -0,0 +1 @@
1
+ {"http_interactions":[{"request":{"method":"get","uri":"https://api.sageone.com/accounts/v1/tax_rates/%7B%22$itemsPerPage%22=%3E2%7D","body":{"encoding":"US-ASCII","string":""},"headers":{"Accept":["application/json"],"Content-Type":["application/x-www-form-urlencoded"],"User-Agent":["Sage One Ruby Gem 0.0.1"],"Authorization":["Bearer \u003CACCESS_TOKEN\u003E"],"X-Nonce":["61d1ea3913012346f55e08b0039791e6"],"X-Signature":["egXvcTC2vT6Yu0BrzfK6sz6usWA="],"Accept-Encoding":["gzip;q=1.0,deflate;q=0.6,identity;q=0.3"]}},"response":{"status":{"code":401,"message":"Unauthorized"},"headers":{"Content-Type":["application/json"],"Date":["Mon, 29 Sep 2014 16:21:16 GMT"],"Server":["openresty"],"Content-Length":["114"],"Connection":["keep-alive"]},"body":{"encoding":"UTF-8","string":"{\"$diagnoses\":[{\"$severity\":\"error\",\"$dataCode\":\"AuthorizationFailure\",\"$message\":\"Access Denied\",\"$source\":\"\"}]}\n"},"http_version":null},"recorded_at":"Mon, 29 Sep 2014 16:21:15 GMT"}],"recorded_with":"VCR 2.9.3"}