merge_accounting_client 1.0.5 → 1.0.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (58) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +4 -4
  3. data/docs/AccountsApi.md +4 -0
  4. data/docs/BalanceSheetsApi.md +4 -0
  5. data/docs/CashFlowStatementsApi.md +4 -0
  6. data/docs/CompanyInfoApi.md +4 -0
  7. data/docs/ContactsApi.md +4 -0
  8. data/docs/CreditNotesApi.md +4 -0
  9. data/docs/ExpensesApi.md +4 -0
  10. data/docs/ForceResyncApi.md +1 -1
  11. data/docs/IncomeStatementsApi.md +4 -0
  12. data/docs/InvoicesApi.md +4 -0
  13. data/docs/ItemsApi.md +4 -0
  14. data/docs/JournalEntriesApi.md +4 -0
  15. data/docs/PaymentsApi.md +4 -0
  16. data/docs/PurchaseOrdersApi.md +4 -0
  17. data/docs/TaxRatesApi.md +4 -0
  18. data/docs/TrackingCategoriesApi.md +4 -0
  19. data/docs/TransactionsApi.md +4 -0
  20. data/docs/VendorCreditsApi.md +4 -0
  21. data/lib/merge_accounting_client/api/accounts_api.rb +14 -0
  22. data/lib/merge_accounting_client/api/balance_sheets_api.rb +14 -0
  23. data/lib/merge_accounting_client/api/cash_flow_statements_api.rb +14 -0
  24. data/lib/merge_accounting_client/api/company_info_api.rb +14 -0
  25. data/lib/merge_accounting_client/api/contacts_api.rb +14 -0
  26. data/lib/merge_accounting_client/api/credit_notes_api.rb +14 -0
  27. data/lib/merge_accounting_client/api/expenses_api.rb +14 -0
  28. data/lib/merge_accounting_client/api/force_resync_api.rb +2 -2
  29. data/lib/merge_accounting_client/api/income_statements_api.rb +14 -0
  30. data/lib/merge_accounting_client/api/invoices_api.rb +14 -0
  31. data/lib/merge_accounting_client/api/items_api.rb +14 -0
  32. data/lib/merge_accounting_client/api/journal_entries_api.rb +14 -0
  33. data/lib/merge_accounting_client/api/payments_api.rb +14 -0
  34. data/lib/merge_accounting_client/api/purchase_orders_api.rb +14 -0
  35. data/lib/merge_accounting_client/api/tax_rates_api.rb +14 -0
  36. data/lib/merge_accounting_client/api/tracking_categories_api.rb +14 -0
  37. data/lib/merge_accounting_client/api/transactions_api.rb +14 -0
  38. data/lib/merge_accounting_client/api/vendor_credits_api.rb +14 -0
  39. data/lib/merge_accounting_client/version.rb +1 -1
  40. data/spec/api/accounts_api_spec.rb +2 -0
  41. data/spec/api/balance_sheets_api_spec.rb +2 -0
  42. data/spec/api/cash_flow_statements_api_spec.rb +2 -0
  43. data/spec/api/company_info_api_spec.rb +2 -0
  44. data/spec/api/contacts_api_spec.rb +2 -0
  45. data/spec/api/credit_notes_api_spec.rb +2 -0
  46. data/spec/api/expenses_api_spec.rb +2 -0
  47. data/spec/api/force_resync_api_spec.rb +1 -1
  48. data/spec/api/income_statements_api_spec.rb +2 -0
  49. data/spec/api/invoices_api_spec.rb +2 -0
  50. data/spec/api/items_api_spec.rb +2 -0
  51. data/spec/api/journal_entries_api_spec.rb +2 -0
  52. data/spec/api/payments_api_spec.rb +2 -0
  53. data/spec/api/purchase_orders_api_spec.rb +2 -0
  54. data/spec/api/tax_rates_api_spec.rb +2 -0
  55. data/spec/api/tracking_categories_api_spec.rb +2 -0
  56. data/spec/api/transactions_api_spec.rb +2 -0
  57. data/spec/api/vendor_credits_api_spec.rb +2 -0
  58. metadata +2 -2
@@ -103,6 +103,7 @@ module MergeAccountingClient
103
103
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
104
104
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
105
105
  # @option opts [String] :cursor The pagination cursor value.
106
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
106
107
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
107
108
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
108
109
  # @option opts [Time] :issue_date_after If provided, will only return objects created after this datetime.
@@ -128,6 +129,7 @@ module MergeAccountingClient
128
129
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
129
130
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
130
131
  # @option opts [String] :cursor The pagination cursor value.
132
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
131
133
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
132
134
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
133
135
  # @option opts [Time] :issue_date_after If provided, will only return objects created after this datetime.
@@ -148,6 +150,10 @@ module MergeAccountingClient
148
150
  if @api_client.config.client_side_validation && x_account_token.nil?
149
151
  fail ArgumentError, "Missing the required parameter 'x_account_token' when calling InvoicesApi.invoices_list"
150
152
  end
153
+ allowable_values = ["company", "contact", "contact,company", "line_items", "line_items,company", "line_items,contact", "line_items,contact,company", "payments", "payments,company", "payments,contact", "payments,contact,company", "payments,line_items", "payments,line_items,company", "payments,line_items,contact", "payments,line_items,contact,company"]
154
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
155
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
156
+ end
151
157
  allowable_values = ["type"]
152
158
  if @api_client.config.client_side_validation && opts[:'remote_fields'] && !allowable_values.include?(opts[:'remote_fields'])
153
159
  fail ArgumentError, "invalid value for \"remote_fields\", must be one of #{allowable_values}"
@@ -170,6 +176,7 @@ module MergeAccountingClient
170
176
  query_params[:'created_after'] = opts[:'created_after'] if !opts[:'created_after'].nil?
171
177
  query_params[:'created_before'] = opts[:'created_before'] if !opts[:'created_before'].nil?
172
178
  query_params[:'cursor'] = opts[:'cursor'] if !opts[:'cursor'].nil?
179
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
173
180
  query_params[:'include_deleted_data'] = opts[:'include_deleted_data'] if !opts[:'include_deleted_data'].nil?
174
181
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
175
182
  query_params[:'issue_date_after'] = opts[:'issue_date_after'] if !opts[:'issue_date_after'].nil?
@@ -283,6 +290,7 @@ module MergeAccountingClient
283
290
  # @param x_account_token [String] Token identifying the end user.
284
291
  # @param id [String]
285
292
  # @param [Hash] opts the optional parameters
293
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
286
294
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
287
295
  # @option opts [String] :remote_fields Deprecated. Use show_enum_origins.
288
296
  # @option opts [String] :show_enum_origins Which fields should be returned in non-normalized form.
@@ -296,6 +304,7 @@ module MergeAccountingClient
296
304
  # @param x_account_token [String] Token identifying the end user.
297
305
  # @param id [String]
298
306
  # @param [Hash] opts the optional parameters
307
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
299
308
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
300
309
  # @option opts [String] :remote_fields Deprecated. Use show_enum_origins.
301
310
  # @option opts [String] :show_enum_origins Which fields should be returned in non-normalized form.
@@ -312,6 +321,10 @@ module MergeAccountingClient
312
321
  if @api_client.config.client_side_validation && id.nil?
313
322
  fail ArgumentError, "Missing the required parameter 'id' when calling InvoicesApi.invoices_retrieve"
314
323
  end
324
+ allowable_values = ["company", "contact", "contact,company", "line_items", "line_items,company", "line_items,contact", "line_items,contact,company", "payments", "payments,company", "payments,contact", "payments,contact,company", "payments,line_items", "payments,line_items,company", "payments,line_items,contact", "payments,line_items,contact,company"]
325
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
326
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
327
+ end
315
328
  allowable_values = ["type"]
316
329
  if @api_client.config.client_side_validation && opts[:'remote_fields'] && !allowable_values.include?(opts[:'remote_fields'])
317
330
  fail ArgumentError, "invalid value for \"remote_fields\", must be one of #{allowable_values}"
@@ -325,6 +338,7 @@ module MergeAccountingClient
325
338
 
326
339
  # query parameters
327
340
  query_params = opts[:query_params] || {}
341
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
328
342
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
329
343
  query_params[:'remote_fields'] = opts[:'remote_fields'] if !opts[:'remote_fields'].nil?
330
344
  query_params[:'show_enum_origins'] = opts[:'show_enum_origins'] if !opts[:'show_enum_origins'].nil?
@@ -26,6 +26,7 @@ module MergeAccountingClient
26
26
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
27
27
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
28
28
  # @option opts [String] :cursor The pagination cursor value.
29
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
29
30
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
30
31
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
31
32
  # @option opts [Time] :modified_after If provided, will only return objects modified after this datetime.
@@ -47,6 +48,7 @@ module MergeAccountingClient
47
48
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
48
49
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
49
50
  # @option opts [String] :cursor The pagination cursor value.
51
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
50
52
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
51
53
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
52
54
  # @option opts [Time] :modified_after If provided, will only return objects modified after this datetime.
@@ -64,6 +66,10 @@ module MergeAccountingClient
64
66
  if @api_client.config.client_side_validation && x_account_token.nil?
65
67
  fail ArgumentError, "Missing the required parameter 'x_account_token' when calling ItemsApi.items_list"
66
68
  end
69
+ allowable_values = ["company", "purchase_account", "purchase_account,company", "purchase_account,sales_account", "purchase_account,sales_account,company", "sales_account", "sales_account,company"]
70
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
71
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
72
+ end
67
73
  allowable_values = ["status"]
68
74
  if @api_client.config.client_side_validation && opts[:'remote_fields'] && !allowable_values.include?(opts[:'remote_fields'])
69
75
  fail ArgumentError, "invalid value for \"remote_fields\", must be one of #{allowable_values}"
@@ -81,6 +87,7 @@ module MergeAccountingClient
81
87
  query_params[:'created_after'] = opts[:'created_after'] if !opts[:'created_after'].nil?
82
88
  query_params[:'created_before'] = opts[:'created_before'] if !opts[:'created_before'].nil?
83
89
  query_params[:'cursor'] = opts[:'cursor'] if !opts[:'cursor'].nil?
90
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
84
91
  query_params[:'include_deleted_data'] = opts[:'include_deleted_data'] if !opts[:'include_deleted_data'].nil?
85
92
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
86
93
  query_params[:'modified_after'] = opts[:'modified_after'] if !opts[:'modified_after'].nil?
@@ -129,6 +136,7 @@ module MergeAccountingClient
129
136
  # @param x_account_token [String] Token identifying the end user.
130
137
  # @param id [String]
131
138
  # @param [Hash] opts the optional parameters
139
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
132
140
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
133
141
  # @option opts [String] :remote_fields Deprecated. Use show_enum_origins.
134
142
  # @option opts [String] :show_enum_origins Which fields should be returned in non-normalized form.
@@ -142,6 +150,7 @@ module MergeAccountingClient
142
150
  # @param x_account_token [String] Token identifying the end user.
143
151
  # @param id [String]
144
152
  # @param [Hash] opts the optional parameters
153
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
145
154
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
146
155
  # @option opts [String] :remote_fields Deprecated. Use show_enum_origins.
147
156
  # @option opts [String] :show_enum_origins Which fields should be returned in non-normalized form.
@@ -158,6 +167,10 @@ module MergeAccountingClient
158
167
  if @api_client.config.client_side_validation && id.nil?
159
168
  fail ArgumentError, "Missing the required parameter 'id' when calling ItemsApi.items_retrieve"
160
169
  end
170
+ allowable_values = ["company", "purchase_account", "purchase_account,company", "purchase_account,sales_account", "purchase_account,sales_account,company", "sales_account", "sales_account,company"]
171
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
172
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
173
+ end
161
174
  allowable_values = ["status"]
162
175
  if @api_client.config.client_side_validation && opts[:'remote_fields'] && !allowable_values.include?(opts[:'remote_fields'])
163
176
  fail ArgumentError, "invalid value for \"remote_fields\", must be one of #{allowable_values}"
@@ -171,6 +184,7 @@ module MergeAccountingClient
171
184
 
172
185
  # query parameters
173
186
  query_params = opts[:query_params] || {}
187
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
174
188
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
175
189
  query_params[:'remote_fields'] = opts[:'remote_fields'] if !opts[:'remote_fields'].nil?
176
190
  query_params[:'show_enum_origins'] = opts[:'show_enum_origins'] if !opts[:'show_enum_origins'].nil?
@@ -102,6 +102,7 @@ module MergeAccountingClient
102
102
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
103
103
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
104
104
  # @option opts [String] :cursor The pagination cursor value.
105
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
105
106
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
106
107
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
107
108
  # @option opts [Time] :modified_after If provided, will only return objects modified after this datetime.
@@ -123,6 +124,7 @@ module MergeAccountingClient
123
124
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
124
125
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
125
126
  # @option opts [String] :cursor The pagination cursor value.
127
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
126
128
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
127
129
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
128
130
  # @option opts [Time] :modified_after If provided, will only return objects modified after this datetime.
@@ -140,6 +142,10 @@ module MergeAccountingClient
140
142
  if @api_client.config.client_side_validation && x_account_token.nil?
141
143
  fail ArgumentError, "Missing the required parameter 'x_account_token' when calling JournalEntriesApi.journal_entries_list"
142
144
  end
145
+ allowable_values = ["company", "lines", "lines,company", "lines,payments", "lines,payments,company", "payments", "payments,company"]
146
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
147
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
148
+ end
143
149
  # resource path
144
150
  local_var_path = '/journal-entries'
145
151
 
@@ -149,6 +155,7 @@ module MergeAccountingClient
149
155
  query_params[:'created_after'] = opts[:'created_after'] if !opts[:'created_after'].nil?
150
156
  query_params[:'created_before'] = opts[:'created_before'] if !opts[:'created_before'].nil?
151
157
  query_params[:'cursor'] = opts[:'cursor'] if !opts[:'cursor'].nil?
158
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
152
159
  query_params[:'include_deleted_data'] = opts[:'include_deleted_data'] if !opts[:'include_deleted_data'].nil?
153
160
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
154
161
  query_params[:'modified_after'] = opts[:'modified_after'] if !opts[:'modified_after'].nil?
@@ -259,6 +266,7 @@ module MergeAccountingClient
259
266
  # @param x_account_token [String] Token identifying the end user.
260
267
  # @param id [String]
261
268
  # @param [Hash] opts the optional parameters
269
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
262
270
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
263
271
  # @return [JournalEntry]
264
272
  def journal_entries_retrieve(x_account_token, id, opts = {})
@@ -270,6 +278,7 @@ module MergeAccountingClient
270
278
  # @param x_account_token [String] Token identifying the end user.
271
279
  # @param id [String]
272
280
  # @param [Hash] opts the optional parameters
281
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
273
282
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
274
283
  # @return [Array<(JournalEntry, Integer, Hash)>] JournalEntry data, response status code and response headers
275
284
  def journal_entries_retrieve_with_http_info(x_account_token, id, opts = {})
@@ -284,11 +293,16 @@ module MergeAccountingClient
284
293
  if @api_client.config.client_side_validation && id.nil?
285
294
  fail ArgumentError, "Missing the required parameter 'id' when calling JournalEntriesApi.journal_entries_retrieve"
286
295
  end
296
+ allowable_values = ["company", "lines", "lines,company", "lines,payments", "lines,payments,company", "payments", "payments,company"]
297
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
298
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
299
+ end
287
300
  # resource path
288
301
  local_var_path = '/journal-entries/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
289
302
 
290
303
  # query parameters
291
304
  query_params = opts[:query_params] || {}
305
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
292
306
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
293
307
 
294
308
  # header parameters
@@ -104,6 +104,7 @@ module MergeAccountingClient
104
104
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
105
105
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
106
106
  # @option opts [String] :cursor The pagination cursor value.
107
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
107
108
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
108
109
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
109
110
  # @option opts [Time] :modified_after If provided, will only return objects modified after this datetime.
@@ -127,6 +128,7 @@ module MergeAccountingClient
127
128
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
128
129
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
129
130
  # @option opts [String] :cursor The pagination cursor value.
131
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
130
132
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
131
133
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
132
134
  # @option opts [Time] :modified_after If provided, will only return objects modified after this datetime.
@@ -144,6 +146,10 @@ module MergeAccountingClient
144
146
  if @api_client.config.client_side_validation && x_account_token.nil?
145
147
  fail ArgumentError, "Missing the required parameter 'x_account_token' when calling PaymentsApi.payments_list"
146
148
  end
149
+ allowable_values = ["account", "account,company", "company", "contact", "contact,account", "contact,account,company", "contact,company"]
150
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
151
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
152
+ end
147
153
  # resource path
148
154
  local_var_path = '/payments'
149
155
 
@@ -155,6 +161,7 @@ module MergeAccountingClient
155
161
  query_params[:'created_after'] = opts[:'created_after'] if !opts[:'created_after'].nil?
156
162
  query_params[:'created_before'] = opts[:'created_before'] if !opts[:'created_before'].nil?
157
163
  query_params[:'cursor'] = opts[:'cursor'] if !opts[:'cursor'].nil?
164
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
158
165
  query_params[:'include_deleted_data'] = opts[:'include_deleted_data'] if !opts[:'include_deleted_data'].nil?
159
166
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
160
167
  query_params[:'modified_after'] = opts[:'modified_after'] if !opts[:'modified_after'].nil?
@@ -265,6 +272,7 @@ module MergeAccountingClient
265
272
  # @param x_account_token [String] Token identifying the end user.
266
273
  # @param id [String]
267
274
  # @param [Hash] opts the optional parameters
275
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
268
276
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
269
277
  # @return [Payment]
270
278
  def payments_retrieve(x_account_token, id, opts = {})
@@ -276,6 +284,7 @@ module MergeAccountingClient
276
284
  # @param x_account_token [String] Token identifying the end user.
277
285
  # @param id [String]
278
286
  # @param [Hash] opts the optional parameters
287
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
279
288
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
280
289
  # @return [Array<(Payment, Integer, Hash)>] Payment data, response status code and response headers
281
290
  def payments_retrieve_with_http_info(x_account_token, id, opts = {})
@@ -290,11 +299,16 @@ module MergeAccountingClient
290
299
  if @api_client.config.client_side_validation && id.nil?
291
300
  fail ArgumentError, "Missing the required parameter 'id' when calling PaymentsApi.payments_retrieve"
292
301
  end
302
+ allowable_values = ["account", "account,company", "company", "contact", "contact,account", "contact,account,company", "contact,company"]
303
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
304
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
305
+ end
293
306
  # resource path
294
307
  local_var_path = '/payments/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
295
308
 
296
309
  # query parameters
297
310
  query_params = opts[:query_params] || {}
311
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
298
312
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
299
313
 
300
314
  # header parameters
@@ -102,6 +102,7 @@ module MergeAccountingClient
102
102
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
103
103
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
104
104
  # @option opts [String] :cursor The pagination cursor value.
105
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
105
106
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
106
107
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
107
108
  # @option opts [Time] :issue_date_after If provided, will only return objects created after this datetime.
@@ -125,6 +126,7 @@ module MergeAccountingClient
125
126
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
126
127
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
127
128
  # @option opts [String] :cursor The pagination cursor value.
129
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
128
130
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
129
131
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
130
132
  # @option opts [Time] :issue_date_after If provided, will only return objects created after this datetime.
@@ -144,6 +146,10 @@ module MergeAccountingClient
144
146
  if @api_client.config.client_side_validation && x_account_token.nil?
145
147
  fail ArgumentError, "Missing the required parameter 'x_account_token' when calling PurchaseOrdersApi.purchase_orders_list"
146
148
  end
149
+ allowable_values = ["company", "delivery_address", "delivery_address,company", "delivery_address,vendor", "delivery_address,vendor,company", "line_items", "line_items,company", "line_items,delivery_address", "line_items,delivery_address,company", "line_items,delivery_address,vendor", "line_items,delivery_address,vendor,company", "line_items,vendor", "line_items,vendor,company", "vendor", "vendor,company"]
150
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
151
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
152
+ end
147
153
  allowable_values = ["status"]
148
154
  if @api_client.config.client_side_validation && opts[:'remote_fields'] && !allowable_values.include?(opts[:'remote_fields'])
149
155
  fail ArgumentError, "invalid value for \"remote_fields\", must be one of #{allowable_values}"
@@ -161,6 +167,7 @@ module MergeAccountingClient
161
167
  query_params[:'created_after'] = opts[:'created_after'] if !opts[:'created_after'].nil?
162
168
  query_params[:'created_before'] = opts[:'created_before'] if !opts[:'created_before'].nil?
163
169
  query_params[:'cursor'] = opts[:'cursor'] if !opts[:'cursor'].nil?
170
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
164
171
  query_params[:'include_deleted_data'] = opts[:'include_deleted_data'] if !opts[:'include_deleted_data'].nil?
165
172
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
166
173
  query_params[:'issue_date_after'] = opts[:'issue_date_after'] if !opts[:'issue_date_after'].nil?
@@ -273,6 +280,7 @@ module MergeAccountingClient
273
280
  # @param x_account_token [String] Token identifying the end user.
274
281
  # @param id [String]
275
282
  # @param [Hash] opts the optional parameters
283
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
276
284
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
277
285
  # @option opts [String] :remote_fields Deprecated. Use show_enum_origins.
278
286
  # @option opts [String] :show_enum_origins Which fields should be returned in non-normalized form.
@@ -286,6 +294,7 @@ module MergeAccountingClient
286
294
  # @param x_account_token [String] Token identifying the end user.
287
295
  # @param id [String]
288
296
  # @param [Hash] opts the optional parameters
297
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
289
298
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
290
299
  # @option opts [String] :remote_fields Deprecated. Use show_enum_origins.
291
300
  # @option opts [String] :show_enum_origins Which fields should be returned in non-normalized form.
@@ -302,6 +311,10 @@ module MergeAccountingClient
302
311
  if @api_client.config.client_side_validation && id.nil?
303
312
  fail ArgumentError, "Missing the required parameter 'id' when calling PurchaseOrdersApi.purchase_orders_retrieve"
304
313
  end
314
+ allowable_values = ["company", "delivery_address", "delivery_address,company", "delivery_address,vendor", "delivery_address,vendor,company", "line_items", "line_items,company", "line_items,delivery_address", "line_items,delivery_address,company", "line_items,delivery_address,vendor", "line_items,delivery_address,vendor,company", "line_items,vendor", "line_items,vendor,company", "vendor", "vendor,company"]
315
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
316
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
317
+ end
305
318
  allowable_values = ["status"]
306
319
  if @api_client.config.client_side_validation && opts[:'remote_fields'] && !allowable_values.include?(opts[:'remote_fields'])
307
320
  fail ArgumentError, "invalid value for \"remote_fields\", must be one of #{allowable_values}"
@@ -315,6 +328,7 @@ module MergeAccountingClient
315
328
 
316
329
  # query parameters
317
330
  query_params = opts[:query_params] || {}
331
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
318
332
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
319
333
  query_params[:'remote_fields'] = opts[:'remote_fields'] if !opts[:'remote_fields'].nil?
320
334
  query_params[:'show_enum_origins'] = opts[:'show_enum_origins'] if !opts[:'show_enum_origins'].nil?
@@ -26,6 +26,7 @@ module MergeAccountingClient
26
26
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
27
27
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
28
28
  # @option opts [String] :cursor The pagination cursor value.
29
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
29
30
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
30
31
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
31
32
  # @option opts [Time] :modified_after If provided, will only return objects modified after this datetime.
@@ -45,6 +46,7 @@ module MergeAccountingClient
45
46
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
46
47
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
47
48
  # @option opts [String] :cursor The pagination cursor value.
49
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
48
50
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
49
51
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
50
52
  # @option opts [Time] :modified_after If provided, will only return objects modified after this datetime.
@@ -60,6 +62,10 @@ module MergeAccountingClient
60
62
  if @api_client.config.client_side_validation && x_account_token.nil?
61
63
  fail ArgumentError, "Missing the required parameter 'x_account_token' when calling TaxRatesApi.tax_rates_list"
62
64
  end
65
+ allowable_values = ["company"]
66
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
67
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
68
+ end
63
69
  # resource path
64
70
  local_var_path = '/tax-rates'
65
71
 
@@ -69,6 +75,7 @@ module MergeAccountingClient
69
75
  query_params[:'created_after'] = opts[:'created_after'] if !opts[:'created_after'].nil?
70
76
  query_params[:'created_before'] = opts[:'created_before'] if !opts[:'created_before'].nil?
71
77
  query_params[:'cursor'] = opts[:'cursor'] if !opts[:'cursor'].nil?
78
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
72
79
  query_params[:'include_deleted_data'] = opts[:'include_deleted_data'] if !opts[:'include_deleted_data'].nil?
73
80
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
74
81
  query_params[:'modified_after'] = opts[:'modified_after'] if !opts[:'modified_after'].nil?
@@ -115,6 +122,7 @@ module MergeAccountingClient
115
122
  # @param x_account_token [String] Token identifying the end user.
116
123
  # @param id [String]
117
124
  # @param [Hash] opts the optional parameters
125
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
118
126
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
119
127
  # @return [TaxRate]
120
128
  def tax_rates_retrieve(x_account_token, id, opts = {})
@@ -126,6 +134,7 @@ module MergeAccountingClient
126
134
  # @param x_account_token [String] Token identifying the end user.
127
135
  # @param id [String]
128
136
  # @param [Hash] opts the optional parameters
137
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
129
138
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
130
139
  # @return [Array<(TaxRate, Integer, Hash)>] TaxRate data, response status code and response headers
131
140
  def tax_rates_retrieve_with_http_info(x_account_token, id, opts = {})
@@ -140,11 +149,16 @@ module MergeAccountingClient
140
149
  if @api_client.config.client_side_validation && id.nil?
141
150
  fail ArgumentError, "Missing the required parameter 'id' when calling TaxRatesApi.tax_rates_retrieve"
142
151
  end
152
+ allowable_values = ["company"]
153
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
154
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
155
+ end
143
156
  # resource path
144
157
  local_var_path = '/tax-rates/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
145
158
 
146
159
  # query parameters
147
160
  query_params = opts[:query_params] || {}
161
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
148
162
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
149
163
 
150
164
  # header parameters
@@ -26,6 +26,7 @@ module MergeAccountingClient
26
26
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
27
27
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
28
28
  # @option opts [String] :cursor The pagination cursor value.
29
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
29
30
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
30
31
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
31
32
  # @option opts [Time] :modified_after If provided, will only return objects modified after this datetime.
@@ -47,6 +48,7 @@ module MergeAccountingClient
47
48
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
48
49
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
49
50
  # @option opts [String] :cursor The pagination cursor value.
51
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
50
52
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
51
53
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
52
54
  # @option opts [Time] :modified_after If provided, will only return objects modified after this datetime.
@@ -64,6 +66,10 @@ module MergeAccountingClient
64
66
  if @api_client.config.client_side_validation && x_account_token.nil?
65
67
  fail ArgumentError, "Missing the required parameter 'x_account_token' when calling TrackingCategoriesApi.tracking_categories_list"
66
68
  end
69
+ allowable_values = ["company"]
70
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
71
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
72
+ end
67
73
  allowable_values = ["status"]
68
74
  if @api_client.config.client_side_validation && opts[:'remote_fields'] && !allowable_values.include?(opts[:'remote_fields'])
69
75
  fail ArgumentError, "invalid value for \"remote_fields\", must be one of #{allowable_values}"
@@ -81,6 +87,7 @@ module MergeAccountingClient
81
87
  query_params[:'created_after'] = opts[:'created_after'] if !opts[:'created_after'].nil?
82
88
  query_params[:'created_before'] = opts[:'created_before'] if !opts[:'created_before'].nil?
83
89
  query_params[:'cursor'] = opts[:'cursor'] if !opts[:'cursor'].nil?
90
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
84
91
  query_params[:'include_deleted_data'] = opts[:'include_deleted_data'] if !opts[:'include_deleted_data'].nil?
85
92
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
86
93
  query_params[:'modified_after'] = opts[:'modified_after'] if !opts[:'modified_after'].nil?
@@ -129,6 +136,7 @@ module MergeAccountingClient
129
136
  # @param x_account_token [String] Token identifying the end user.
130
137
  # @param id [String]
131
138
  # @param [Hash] opts the optional parameters
139
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
132
140
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
133
141
  # @option opts [String] :remote_fields Deprecated. Use show_enum_origins.
134
142
  # @option opts [String] :show_enum_origins Which fields should be returned in non-normalized form.
@@ -142,6 +150,7 @@ module MergeAccountingClient
142
150
  # @param x_account_token [String] Token identifying the end user.
143
151
  # @param id [String]
144
152
  # @param [Hash] opts the optional parameters
153
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
145
154
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
146
155
  # @option opts [String] :remote_fields Deprecated. Use show_enum_origins.
147
156
  # @option opts [String] :show_enum_origins Which fields should be returned in non-normalized form.
@@ -158,6 +167,10 @@ module MergeAccountingClient
158
167
  if @api_client.config.client_side_validation && id.nil?
159
168
  fail ArgumentError, "Missing the required parameter 'id' when calling TrackingCategoriesApi.tracking_categories_retrieve"
160
169
  end
170
+ allowable_values = ["company"]
171
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
172
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
173
+ end
161
174
  allowable_values = ["status"]
162
175
  if @api_client.config.client_side_validation && opts[:'remote_fields'] && !allowable_values.include?(opts[:'remote_fields'])
163
176
  fail ArgumentError, "invalid value for \"remote_fields\", must be one of #{allowable_values}"
@@ -171,6 +184,7 @@ module MergeAccountingClient
171
184
 
172
185
  # query parameters
173
186
  query_params = opts[:query_params] || {}
187
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
174
188
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
175
189
  query_params[:'remote_fields'] = opts[:'remote_fields'] if !opts[:'remote_fields'].nil?
176
190
  query_params[:'show_enum_origins'] = opts[:'show_enum_origins'] if !opts[:'show_enum_origins'].nil?
@@ -26,6 +26,7 @@ module MergeAccountingClient
26
26
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
27
27
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
28
28
  # @option opts [String] :cursor The pagination cursor value.
29
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
29
30
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
30
31
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
31
32
  # @option opts [Time] :modified_after If provided, will only return objects modified after this datetime.
@@ -47,6 +48,7 @@ module MergeAccountingClient
47
48
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
48
49
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
49
50
  # @option opts [String] :cursor The pagination cursor value.
51
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
50
52
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
51
53
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
52
54
  # @option opts [Time] :modified_after If provided, will only return objects modified after this datetime.
@@ -64,6 +66,10 @@ module MergeAccountingClient
64
66
  if @api_client.config.client_side_validation && x_account_token.nil?
65
67
  fail ArgumentError, "Missing the required parameter 'x_account_token' when calling TransactionsApi.transactions_list"
66
68
  end
69
+ allowable_values = ["account", "contact", "contact,account", "line_items", "line_items,account", "line_items,contact", "line_items,contact,account"]
70
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
71
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
72
+ end
67
73
  # resource path
68
74
  local_var_path = '/transactions'
69
75
 
@@ -73,6 +79,7 @@ module MergeAccountingClient
73
79
  query_params[:'created_after'] = opts[:'created_after'] if !opts[:'created_after'].nil?
74
80
  query_params[:'created_before'] = opts[:'created_before'] if !opts[:'created_before'].nil?
75
81
  query_params[:'cursor'] = opts[:'cursor'] if !opts[:'cursor'].nil?
82
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
76
83
  query_params[:'include_deleted_data'] = opts[:'include_deleted_data'] if !opts[:'include_deleted_data'].nil?
77
84
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
78
85
  query_params[:'modified_after'] = opts[:'modified_after'] if !opts[:'modified_after'].nil?
@@ -121,6 +128,7 @@ module MergeAccountingClient
121
128
  # @param x_account_token [String] Token identifying the end user.
122
129
  # @param id [String]
123
130
  # @param [Hash] opts the optional parameters
131
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
124
132
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
125
133
  # @return [Transaction]
126
134
  def transactions_retrieve(x_account_token, id, opts = {})
@@ -132,6 +140,7 @@ module MergeAccountingClient
132
140
  # @param x_account_token [String] Token identifying the end user.
133
141
  # @param id [String]
134
142
  # @param [Hash] opts the optional parameters
143
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
135
144
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
136
145
  # @return [Array<(Transaction, Integer, Hash)>] Transaction data, response status code and response headers
137
146
  def transactions_retrieve_with_http_info(x_account_token, id, opts = {})
@@ -146,11 +155,16 @@ module MergeAccountingClient
146
155
  if @api_client.config.client_side_validation && id.nil?
147
156
  fail ArgumentError, "Missing the required parameter 'id' when calling TransactionsApi.transactions_retrieve"
148
157
  end
158
+ allowable_values = ["account", "contact", "contact,account", "line_items", "line_items,account", "line_items,contact", "line_items,contact,account"]
159
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
160
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
161
+ end
149
162
  # resource path
150
163
  local_var_path = '/transactions/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
151
164
 
152
165
  # query parameters
153
166
  query_params = opts[:query_params] || {}
167
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
154
168
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
155
169
 
156
170
  # header parameters
@@ -26,6 +26,7 @@ module MergeAccountingClient
26
26
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
27
27
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
28
28
  # @option opts [String] :cursor The pagination cursor value.
29
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
29
30
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
30
31
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
31
32
  # @option opts [Time] :modified_after If provided, will only return objects modified after this datetime.
@@ -47,6 +48,7 @@ module MergeAccountingClient
47
48
  # @option opts [Time] :created_after If provided, will only return objects created after this datetime.
48
49
  # @option opts [Time] :created_before If provided, will only return objects created before this datetime.
49
50
  # @option opts [String] :cursor The pagination cursor value.
51
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
50
52
  # @option opts [Boolean] :include_deleted_data Whether to include data that was marked as deleted by third party webhooks.
51
53
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
52
54
  # @option opts [Time] :modified_after If provided, will only return objects modified after this datetime.
@@ -64,6 +66,10 @@ module MergeAccountingClient
64
66
  if @api_client.config.client_side_validation && x_account_token.nil?
65
67
  fail ArgumentError, "Missing the required parameter 'x_account_token' when calling VendorCreditsApi.vendor_credits_list"
66
68
  end
69
+ allowable_values = ["company", "lines", "lines,company", "lines,vendor", "lines,vendor,company", "vendor", "vendor,company"]
70
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
71
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
72
+ end
67
73
  # resource path
68
74
  local_var_path = '/vendor-credits'
69
75
 
@@ -73,6 +79,7 @@ module MergeAccountingClient
73
79
  query_params[:'created_after'] = opts[:'created_after'] if !opts[:'created_after'].nil?
74
80
  query_params[:'created_before'] = opts[:'created_before'] if !opts[:'created_before'].nil?
75
81
  query_params[:'cursor'] = opts[:'cursor'] if !opts[:'cursor'].nil?
82
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
76
83
  query_params[:'include_deleted_data'] = opts[:'include_deleted_data'] if !opts[:'include_deleted_data'].nil?
77
84
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
78
85
  query_params[:'modified_after'] = opts[:'modified_after'] if !opts[:'modified_after'].nil?
@@ -121,6 +128,7 @@ module MergeAccountingClient
121
128
  # @param x_account_token [String] Token identifying the end user.
122
129
  # @param id [String]
123
130
  # @param [Hash] opts the optional parameters
131
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
124
132
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
125
133
  # @return [VendorCredit]
126
134
  def vendor_credits_retrieve(x_account_token, id, opts = {})
@@ -132,6 +140,7 @@ module MergeAccountingClient
132
140
  # @param x_account_token [String] Token identifying the end user.
133
141
  # @param id [String]
134
142
  # @param [Hash] opts the optional parameters
143
+ # @option opts [String] :expand Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
135
144
  # @option opts [Boolean] :include_remote_data Whether to include the original data Merge fetched from the third-party to produce these models.
136
145
  # @return [Array<(VendorCredit, Integer, Hash)>] VendorCredit data, response status code and response headers
137
146
  def vendor_credits_retrieve_with_http_info(x_account_token, id, opts = {})
@@ -146,11 +155,16 @@ module MergeAccountingClient
146
155
  if @api_client.config.client_side_validation && id.nil?
147
156
  fail ArgumentError, "Missing the required parameter 'id' when calling VendorCreditsApi.vendor_credits_retrieve"
148
157
  end
158
+ allowable_values = ["company", "lines", "lines,company", "lines,vendor", "lines,vendor,company", "vendor", "vendor,company"]
159
+ if @api_client.config.client_side_validation && opts[:'expand'] && !allowable_values.include?(opts[:'expand'])
160
+ fail ArgumentError, "invalid value for \"expand\", must be one of #{allowable_values}"
161
+ end
149
162
  # resource path
150
163
  local_var_path = '/vendor-credits/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
151
164
 
152
165
  # query parameters
153
166
  query_params = opts[:query_params] || {}
167
+ query_params[:'expand'] = opts[:'expand'] if !opts[:'expand'].nil?
154
168
  query_params[:'include_remote_data'] = opts[:'include_remote_data'] if !opts[:'include_remote_data'].nil?
155
169
 
156
170
  # header parameters