apimatic-tql-sdk 0.0.1 → 0.0.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (118) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +148 -197
  3. data/bin/console +4 -4
  4. data/lib/freight_financials_webhook_ingestion_api/api_helper.rb +10 -0
  5. data/lib/freight_financials_webhook_ingestion_api/apis/assignments_api.rb +41 -0
  6. data/lib/{tql_otr_factoring_data_exchange → freight_financials_webhook_ingestion_api}/apis/base_api.rb +60 -60
  7. data/lib/freight_financials_webhook_ingestion_api/apis/documents_api.rb +73 -0
  8. data/lib/freight_financials_webhook_ingestion_api/apis/freight_audit_api.rb +54 -0
  9. data/lib/freight_financials_webhook_ingestion_api/apis/invoices_api.rb +107 -0
  10. data/lib/freight_financials_webhook_ingestion_api/apis/loads_api.rb +72 -0
  11. data/lib/freight_financials_webhook_ingestion_api/apis/rating_api.rb +45 -0
  12. data/lib/{tql_otr_factoring_data_exchange → freight_financials_webhook_ingestion_api}/client.rb +83 -97
  13. data/lib/{tql_otr_factoring_data_exchange → freight_financials_webhook_ingestion_api}/configuration.rb +114 -126
  14. data/lib/{tql_otr_factoring_data_exchange → freight_financials_webhook_ingestion_api}/exceptions/api_exception.rb +21 -21
  15. data/lib/{tql_otr_factoring_data_exchange/exceptions/problem_details_error_exception.rb → freight_financials_webhook_ingestion_api/exceptions/problem_details_exception.rb} +51 -41
  16. data/lib/{tql_otr_factoring_data_exchange → freight_financials_webhook_ingestion_api}/http/api_response.rb +7 -7
  17. data/lib/freight_financials_webhook_ingestion_api/http/http_call_back.rb +10 -0
  18. data/lib/freight_financials_webhook_ingestion_api/http/http_method_enum.rb +10 -0
  19. data/lib/freight_financials_webhook_ingestion_api/http/http_request.rb +10 -0
  20. data/lib/freight_financials_webhook_ingestion_api/http/http_response.rb +10 -0
  21. data/lib/{tql_otr_factoring_data_exchange → freight_financials_webhook_ingestion_api}/http/proxy_settings.rb +6 -6
  22. data/lib/{tql_otr_factoring_data_exchange → freight_financials_webhook_ingestion_api}/logging/configuration/api_logging_configuration.rb +6 -6
  23. data/lib/{tql_otr_factoring_data_exchange → freight_financials_webhook_ingestion_api}/logging/sdk_logger.rb +6 -6
  24. data/lib/freight_financials_webhook_ingestion_api/models/address.rb +123 -0
  25. data/lib/freight_financials_webhook_ingestion_api/models/assignment_request.rb +94 -0
  26. data/lib/freight_financials_webhook_ingestion_api/models/assignment_response.rb +83 -0
  27. data/lib/{tql_otr_factoring_data_exchange/models/assignment_response.rb → freight_financials_webhook_ingestion_api/models/assignment_response_data.rb} +124 -126
  28. data/lib/{tql_otr_factoring_data_exchange → freight_financials_webhook_ingestion_api}/models/base_model.rb +110 -110
  29. data/lib/{tql_otr_factoring_data_exchange/models/carrier1.rb → freight_financials_webhook_ingestion_api/models/carrier.rb} +96 -98
  30. data/lib/freight_financials_webhook_ingestion_api/models/charge.rb +104 -0
  31. data/lib/freight_financials_webhook_ingestion_api/models/charge_code.rb +81 -0
  32. data/lib/freight_financials_webhook_ingestion_api/models/factoring_company.rb +81 -0
  33. data/lib/{tql_otr_factoring_data_exchange → freight_financials_webhook_ingestion_api}/models/invoice.rb +204 -223
  34. data/lib/{tql_otr_factoring_data_exchange/models/document.rb → freight_financials_webhook_ingestion_api/models/invoice_document.rb} +72 -86
  35. data/lib/{tql_otr_factoring_data_exchange/models/invoice_exception.rb → freight_financials_webhook_ingestion_api/models/invoice_issue.rb} +122 -136
  36. data/lib/freight_financials_webhook_ingestion_api/models/invoice_status_response.rb +83 -0
  37. data/lib/{tql_otr_factoring_data_exchange/models/invoice_status_response.rb → freight_financials_webhook_ingestion_api/models/invoice_status_response_data.rb} +185 -193
  38. data/lib/freight_financials_webhook_ingestion_api/models/line_item.rb +131 -0
  39. data/lib/freight_financials_webhook_ingestion_api/models/load_response.rb +83 -0
  40. data/lib/{tql_otr_factoring_data_exchange/models/load_detail.rb → freight_financials_webhook_ingestion_api/models/load_response_data.rb} +141 -140
  41. data/lib/{tql_otr_factoring_data_exchange/models/load.rb → freight_financials_webhook_ingestion_api/models/load_slim.rb} +97 -110
  42. data/lib/freight_financials_webhook_ingestion_api/models/navix_rate_charge.rb +116 -0
  43. data/lib/freight_financials_webhook_ingestion_api/models/navix_rate_customer.rb +64 -0
  44. data/lib/freight_financials_webhook_ingestion_api/models/navix_rate_line_item.rb +177 -0
  45. data/lib/freight_financials_webhook_ingestion_api/models/navix_rate_request.rb +208 -0
  46. data/lib/freight_financials_webhook_ingestion_api/models/navix_rate_requested_charge.rb +64 -0
  47. data/lib/freight_financials_webhook_ingestion_api/models/navix_rate_response.rb +112 -0
  48. data/lib/freight_financials_webhook_ingestion_api/models/navix_rate_stop.rb +107 -0
  49. data/lib/freight_financials_webhook_ingestion_api/models/navix_rate_vendor.rb +88 -0
  50. data/lib/freight_financials_webhook_ingestion_api/models/navix_webhook_event_type.rb +56 -0
  51. data/lib/freight_financials_webhook_ingestion_api/models/navix_webhook_request.rb +99 -0
  52. data/lib/freight_financials_webhook_ingestion_api/models/paged_response_of_invoice.rb +111 -0
  53. data/lib/{tql_otr_factoring_data_exchange → freight_financials_webhook_ingestion_api}/models/payment.rb +94 -108
  54. data/lib/freight_financials_webhook_ingestion_api/models/rating_charge_qualifier.rb +68 -0
  55. data/lib/freight_financials_webhook_ingestion_api/models/rating_response_format.rb +40 -0
  56. data/lib/freight_financials_webhook_ingestion_api/models/reference_number.rb +71 -0
  57. data/lib/{tql_otr_factoring_data_exchange/models/invoice_search_request.rb → freight_financials_webhook_ingestion_api/models/search_request.rb} +223 -242
  58. data/lib/freight_financials_webhook_ingestion_api/models/search_response.rb +83 -0
  59. data/lib/freight_financials_webhook_ingestion_api/models/stop.rb +81 -0
  60. data/lib/freight_financials_webhook_ingestion_api/models/submit_invoice_request.rb +228 -0
  61. data/lib/freight_financials_webhook_ingestion_api/models/submit_invoice_response.rb +83 -0
  62. data/lib/{tql_otr_factoring_data_exchange/models/submit_invoice_response.rb → freight_financials_webhook_ingestion_api/models/submit_invoice_response_data.rb} +105 -107
  63. data/lib/freight_financials_webhook_ingestion_api/models/upload_request.rb +128 -0
  64. data/lib/freight_financials_webhook_ingestion_api/models/upload_response.rb +83 -0
  65. data/lib/{tql_otr_factoring_data_exchange/models/document_upload_response.rb → freight_financials_webhook_ingestion_api/models/upload_response_data.rb} +117 -137
  66. data/lib/freight_financials_webhook_ingestion_api/utilities/date_time_helper.rb +11 -0
  67. data/lib/{tql_otr_factoring_data_exchange → freight_financials_webhook_ingestion_api}/utilities/file_wrapper.rb +17 -17
  68. data/lib/freight_financials_webhook_ingestion_api.rb +127 -0
  69. metadata +67 -74
  70. data/lib/tql_otr_factoring_data_exchange/api_helper.rb +0 -10
  71. data/lib/tql_otr_factoring_data_exchange/apis/assignments_api.rb +0 -45
  72. data/lib/tql_otr_factoring_data_exchange/apis/documents_api.rb +0 -82
  73. data/lib/tql_otr_factoring_data_exchange/apis/invoices_api.rb +0 -114
  74. data/lib/tql_otr_factoring_data_exchange/apis/loads_api.rb +0 -68
  75. data/lib/tql_otr_factoring_data_exchange/apis/oauth_authorization_api.rb +0 -44
  76. data/lib/tql_otr_factoring_data_exchange/exceptions/oauth_provider_exception.rb +0 -64
  77. data/lib/tql_otr_factoring_data_exchange/http/auth/oauth_2.rb +0 -156
  78. data/lib/tql_otr_factoring_data_exchange/http/http_call_back.rb +0 -10
  79. data/lib/tql_otr_factoring_data_exchange/http/http_method_enum.rb +0 -10
  80. data/lib/tql_otr_factoring_data_exchange/http/http_request.rb +0 -10
  81. data/lib/tql_otr_factoring_data_exchange/http/http_response.rb +0 -10
  82. data/lib/tql_otr_factoring_data_exchange/models/assignment_request.rb +0 -140
  83. data/lib/tql_otr_factoring_data_exchange/models/assignment_status.rb +0 -36
  84. data/lib/tql_otr_factoring_data_exchange/models/base64_document.rb +0 -118
  85. data/lib/tql_otr_factoring_data_exchange/models/base64_document_upload_request.rb +0 -107
  86. data/lib/tql_otr_factoring_data_exchange/models/carrier.rb +0 -98
  87. data/lib/tql_otr_factoring_data_exchange/models/carrier2.rb +0 -98
  88. data/lib/tql_otr_factoring_data_exchange/models/carrier_input.rb +0 -123
  89. data/lib/tql_otr_factoring_data_exchange/models/carrier_input1.rb +0 -123
  90. data/lib/tql_otr_factoring_data_exchange/models/charge_code.rb +0 -126
  91. data/lib/tql_otr_factoring_data_exchange/models/charge_code_origin.rb +0 -49
  92. data/lib/tql_otr_factoring_data_exchange/models/charge_input.rb +0 -146
  93. data/lib/tql_otr_factoring_data_exchange/models/document_type.rb +0 -288
  94. data/lib/tql_otr_factoring_data_exchange/models/document_upload_metadata.rb +0 -111
  95. data/lib/tql_otr_factoring_data_exchange/models/exception_severity.rb +0 -40
  96. data/lib/tql_otr_factoring_data_exchange/models/factoring_company_input.rb +0 -117
  97. data/lib/tql_otr_factoring_data_exchange/models/invoice_item_input.rb +0 -165
  98. data/lib/tql_otr_factoring_data_exchange/models/invoice_search_response.rb +0 -124
  99. data/lib/tql_otr_factoring_data_exchange/models/invoice_status.rb +0 -74
  100. data/lib/tql_otr_factoring_data_exchange/models/invoice_type.rb +0 -50
  101. data/lib/tql_otr_factoring_data_exchange/models/load_search_request.rb +0 -205
  102. data/lib/tql_otr_factoring_data_exchange/models/load_search_response.rb +0 -124
  103. data/lib/tql_otr_factoring_data_exchange/models/load_status.rb +0 -56
  104. data/lib/tql_otr_factoring_data_exchange/models/location.rb +0 -149
  105. data/lib/tql_otr_factoring_data_exchange/models/oauth_provider_error.rb +0 -62
  106. data/lib/tql_otr_factoring_data_exchange/models/oauth_scope.rb +0 -36
  107. data/lib/tql_otr_factoring_data_exchange/models/oauth_token.rb +0 -96
  108. data/lib/tql_otr_factoring_data_exchange/models/problem_details.rb +0 -96
  109. data/lib/tql_otr_factoring_data_exchange/models/reference_number_input.rb +0 -109
  110. data/lib/tql_otr_factoring_data_exchange/models/reference_type.rb +0 -90
  111. data/lib/tql_otr_factoring_data_exchange/models/status.rb +0 -44
  112. data/lib/tql_otr_factoring_data_exchange/models/stop_input.rb +0 -121
  113. data/lib/tql_otr_factoring_data_exchange/models/stop_type.rb +0 -62
  114. data/lib/tql_otr_factoring_data_exchange/models/submit_invoice_request.rb +0 -326
  115. data/lib/tql_otr_factoring_data_exchange/models/weight_unit.rb +0 -36
  116. data/lib/tql_otr_factoring_data_exchange/utilities/date_time_helper.rb +0 -11
  117. data/lib/tql_otr_factoring_data_exchange/utilities/union_type_lookup.rb +0 -29
  118. data/lib/tql_otr_factoring_data_exchange.rb +0 -107
@@ -1,326 +0,0 @@
1
- # tql_otr_factoring_data_exchange
2
- #
3
- # This file was automatically generated by
4
- # APIMATIC v3.0 ( https://www.apimatic.io ).
5
-
6
- module TqlOtrFactoringDataExchange
7
- # Factoring company invoice submitted against a TQL load. Documents should be
8
- # uploaded separately via `POST /api/documents`.
9
- class SubmitInvoiceRequest < BaseModel
10
- SKIP = Object.new
11
- private_constant :SKIP
12
-
13
- # Indicates the purpose of the invoice being submitted.
14
- # - **Invoice** — A standard carrier invoice for freight services
15
- # rendered on a load. This is the initial, primary billing
16
- # submitted by the factoring company on behalf of the carrier.
17
- # - **BalanceDue** — A follow-up invoice for the remaining balance
18
- # after a partial payment or short-pay on a previously submitted
19
- # invoice. Use this type when the original invoice was paid at
20
- # less than the full amount and the carrier is billing for the
21
- # difference.
22
- # - **Supplemental** — An additional invoice for charges that were
23
- # not included on the original invoice. Common examples include
24
- # detention charges, lumper fees, or other accessorials
25
- # discovered or finalized after the initial invoice was
26
- # submitted.
27
- # @return [InvoiceType]
28
- attr_accessor :type
29
-
30
- # The TQL load number this invoice is billed against. This is the load
31
- # identifier assigned by TQL and must match an existing load in the TQL
32
- # system.
33
- # @return [String]
34
- attr_accessor :load_number
35
-
36
- # The factoring company's invoice number for this shipment. This is the
37
- # primary identifier the factoring company uses to track this invoice.
38
- # @return [String]
39
- attr_accessor :invoice_number
40
-
41
- # The carrier's own invoice number, if different from the factoring
42
- # company's invoice number. Optional.
43
- # @return [String]
44
- attr_accessor :carrier_invoice_number
45
-
46
- # Carrier information for the invoiced shipment. At least one of `mcNumber`
47
- # or `dotNumber` must be provided.
48
- # @return [Object]
49
- attr_accessor :carrier
50
-
51
- # Identifies the factoring company that purchased (bought out) the carrier's
52
- # loads.
53
- # @return [FactoringCompanyInput]
54
- attr_accessor :factoring_company
55
-
56
- # Ordered list of stops for the invoiced shipment. Must include at least an
57
- # origin and a destination.
58
- # @return [Array[StopInput]]
59
- attr_accessor :stops
60
-
61
- # One or more carrier charge line items on this invoice.
62
- # @return [Array[ChargeInput]]
63
- attr_accessor :charges
64
-
65
- # Physical line items describing the freight being shipped. Each item
66
- # represents a distinct commodity or handling unit on the load — for
67
- # example, 4 pallets of paper towels at 2,310 lbs, freight class 100. Items
68
- # describe **what was moved**; charges describe **what you are billing**.
69
- # These are independent concepts — charges are not linked to specific items.
70
- # @return [Array[InvoiceItemInput]]
71
- attr_accessor :items
72
-
73
- # One or more reference numbers (PRO, PO, BOL, etc.) to cross-reference this
74
- # invoice with the TQL load.
75
- # @return [Array[ReferenceNumberInput]]
76
- attr_accessor :reference_numbers
77
-
78
- # Date the invoice was generated or sent by the factoring company. [ISO
79
- # 8601](https://www.iso.org/iso-8601-date-and-time-format.html) date format
80
- # (YYYY-MM-DD).
81
- # @return [Date]
82
- attr_accessor :invoice_date
83
-
84
- # Date by which the invoice should be paid, if known. [ISO
85
- # 8601](https://www.iso.org/iso-8601-date-and-time-format.html) date format
86
- # (YYYY-MM-DD).
87
- # @return [Date]
88
- attr_accessor :invoice_due_date
89
-
90
- # Invoice payment terms. Use `NetN` where N is the number of days until
91
- # payment is due (0–365), or `Prepaid` for invoices paid in advance.
92
- # @return [String]
93
- attr_accessor :payment_terms
94
-
95
- # A mapping from model property names to API property names.
96
- def self.names
97
- @_hash = {} if @_hash.nil?
98
- @_hash['type'] = 'type'
99
- @_hash['load_number'] = 'loadNumber'
100
- @_hash['invoice_number'] = 'invoiceNumber'
101
- @_hash['carrier_invoice_number'] = 'carrierInvoiceNumber'
102
- @_hash['carrier'] = 'carrier'
103
- @_hash['factoring_company'] = 'factoringCompany'
104
- @_hash['stops'] = 'stops'
105
- @_hash['charges'] = 'charges'
106
- @_hash['items'] = 'items'
107
- @_hash['reference_numbers'] = 'referenceNumbers'
108
- @_hash['invoice_date'] = 'invoiceDate'
109
- @_hash['invoice_due_date'] = 'invoiceDueDate'
110
- @_hash['payment_terms'] = 'paymentTerms'
111
- @_hash
112
- end
113
-
114
- # An array for optional fields
115
- def self.optionals
116
- %w[
117
- type
118
- carrier_invoice_number
119
- items
120
- invoice_due_date
121
- payment_terms
122
- ]
123
- end
124
-
125
- # An array for nullable fields
126
- def self.nullables
127
- %w[
128
- carrier_invoice_number
129
- items
130
- invoice_due_date
131
- payment_terms
132
- ]
133
- end
134
-
135
- def initialize(load_number:, invoice_number:, carrier:, factoring_company:,
136
- stops:, charges:, reference_numbers:, invoice_date:,
137
- type: InvoiceType::INVOICE, carrier_invoice_number: SKIP,
138
- items: SKIP, invoice_due_date: SKIP, payment_terms: SKIP,
139
- additional_properties: nil)
140
- # Add additional model properties to the instance
141
- additional_properties = {} if additional_properties.nil?
142
-
143
- @type = type unless type == SKIP
144
- @load_number = load_number
145
- @invoice_number = invoice_number
146
- @carrier_invoice_number = carrier_invoice_number unless carrier_invoice_number == SKIP
147
- @carrier = carrier
148
- @factoring_company = factoring_company
149
- @stops = stops
150
- @charges = charges
151
- @items = items unless items == SKIP
152
- @reference_numbers = reference_numbers
153
- @invoice_date = invoice_date
154
- @invoice_due_date = invoice_due_date unless invoice_due_date == SKIP
155
- @payment_terms = payment_terms unless payment_terms == SKIP
156
- @additional_properties = additional_properties
157
- end
158
-
159
- # Creates an instance of the object from a hash.
160
- def self.from_hash(hash)
161
- return nil unless hash
162
-
163
- # Extract variables from the hash.
164
- load_number = hash.key?('loadNumber') ? hash['loadNumber'] : nil
165
- invoice_number = hash.key?('invoiceNumber') ? hash['invoiceNumber'] : nil
166
- carrier = hash.key?('carrier') ? APIHelper.deserialize_union_type(
167
- UnionTypeLookUp.get(:CarrierInput2), hash['carrier']
168
- ) : nil
169
- factoring_company = FactoringCompanyInput.from_hash(hash['factoringCompany']) if
170
- hash['factoringCompany']
171
- # Parameter is an array, so we need to iterate through it
172
- stops = nil
173
- unless hash['stops'].nil?
174
- stops = []
175
- hash['stops'].each do |structure|
176
- stops << (StopInput.from_hash(structure) if structure)
177
- end
178
- end
179
-
180
- stops = nil unless hash.key?('stops')
181
- # Parameter is an array, so we need to iterate through it
182
- charges = nil
183
- unless hash['charges'].nil?
184
- charges = []
185
- hash['charges'].each do |structure|
186
- charges << (ChargeInput.from_hash(structure) if structure)
187
- end
188
- end
189
-
190
- charges = nil unless hash.key?('charges')
191
- # Parameter is an array, so we need to iterate through it
192
- reference_numbers = nil
193
- unless hash['referenceNumbers'].nil?
194
- reference_numbers = []
195
- hash['referenceNumbers'].each do |structure|
196
- reference_numbers << (ReferenceNumberInput.from_hash(structure) if structure)
197
- end
198
- end
199
-
200
- reference_numbers = nil unless hash.key?('referenceNumbers')
201
- invoice_date = hash.key?('invoiceDate') ? hash['invoiceDate'] : nil
202
- type = hash['type'] ||= InvoiceType::INVOICE
203
- carrier_invoice_number =
204
- hash.key?('carrierInvoiceNumber') ? hash['carrierInvoiceNumber'] : SKIP
205
- # Parameter is an array, so we need to iterate through it
206
- items = nil
207
- unless hash['items'].nil?
208
- items = []
209
- hash['items'].each do |structure|
210
- items << (InvoiceItemInput.from_hash(structure) if structure)
211
- end
212
- end
213
-
214
- items = SKIP unless hash.key?('items')
215
- invoice_due_date =
216
- hash.key?('invoiceDueDate') ? hash['invoiceDueDate'] : SKIP
217
- payment_terms = hash.key?('paymentTerms') ? hash['paymentTerms'] : SKIP
218
-
219
- # Create a new hash for additional properties, removing known properties.
220
- new_hash = hash.reject { |k, _| names.value?(k) }
221
-
222
- additional_properties = APIHelper.get_additional_properties(
223
- new_hash, proc { |value| value }
224
- )
225
-
226
- # Create object from extracted values.
227
- SubmitInvoiceRequest.new(load_number: load_number,
228
- invoice_number: invoice_number,
229
- carrier: carrier,
230
- factoring_company: factoring_company,
231
- stops: stops,
232
- charges: charges,
233
- reference_numbers: reference_numbers,
234
- invoice_date: invoice_date,
235
- type: type,
236
- carrier_invoice_number: carrier_invoice_number,
237
- items: items,
238
- invoice_due_date: invoice_due_date,
239
- payment_terms: payment_terms,
240
- additional_properties: additional_properties)
241
- end
242
-
243
- # Validates an instance of the object from a given value.
244
- # @param [SubmitInvoiceRequest | Hash] The value against the validation is performed.
245
- def self.validate(value)
246
- if value.instance_of? self
247
- return (
248
- APIHelper.valid_type?(value.load_number,
249
- ->(val) { val.instance_of? String }) and
250
- APIHelper.valid_type?(value.invoice_number,
251
- ->(val) { val.instance_of? String }) and
252
- UnionTypeLookUp.get(:CarrierInput2)
253
- .validate(value.carrier) and
254
- APIHelper.valid_type?(value.factoring_company,
255
- ->(val) { FactoringCompanyInput.validate(val) },
256
- is_model_hash: true) and
257
- APIHelper.valid_type?(value.stops,
258
- ->(val) { StopInput.validate(val) },
259
- is_model_hash: true,
260
- is_inner_model_hash: true) and
261
- APIHelper.valid_type?(value.charges,
262
- ->(val) { ChargeInput.validate(val) },
263
- is_model_hash: true,
264
- is_inner_model_hash: true) and
265
- APIHelper.valid_type?(value.reference_numbers,
266
- ->(val) { ReferenceNumberInput.validate(val) },
267
- is_model_hash: true,
268
- is_inner_model_hash: true) and
269
- APIHelper.valid_type?(value.invoice_date,
270
- ->(val) { val.instance_of? String })
271
- )
272
- end
273
-
274
- return false unless value.instance_of? Hash
275
-
276
- (
277
- APIHelper.valid_type?(value['loadNumber'],
278
- ->(val) { val.instance_of? String }) and
279
- APIHelper.valid_type?(value['invoiceNumber'],
280
- ->(val) { val.instance_of? String }) and
281
- UnionTypeLookUp.get(:CarrierInput2)
282
- .validate(value['carrier']) and
283
- APIHelper.valid_type?(value['factoringCompany'],
284
- ->(val) { FactoringCompanyInput.validate(val) },
285
- is_model_hash: true) and
286
- APIHelper.valid_type?(value['stops'],
287
- ->(val) { StopInput.validate(val) },
288
- is_model_hash: true,
289
- is_inner_model_hash: true) and
290
- APIHelper.valid_type?(value['charges'],
291
- ->(val) { ChargeInput.validate(val) },
292
- is_model_hash: true,
293
- is_inner_model_hash: true) and
294
- APIHelper.valid_type?(value['referenceNumbers'],
295
- ->(val) { ReferenceNumberInput.validate(val) },
296
- is_model_hash: true,
297
- is_inner_model_hash: true) and
298
- APIHelper.valid_type?(value['invoiceDate'],
299
- ->(val) { val.instance_of? String })
300
- )
301
- end
302
-
303
- # Provides a human-readable string representation of the object.
304
- def to_s
305
- class_name = self.class.name.split('::').last
306
- "<#{class_name} type: #{@type}, load_number: #{@load_number}, invoice_number:"\
307
- " #{@invoice_number}, carrier_invoice_number: #{@carrier_invoice_number}, carrier:"\
308
- " #{@carrier}, factoring_company: #{@factoring_company}, stops: #{@stops}, charges:"\
309
- " #{@charges}, items: #{@items}, reference_numbers: #{@reference_numbers}, invoice_date:"\
310
- " #{@invoice_date}, invoice_due_date: #{@invoice_due_date}, payment_terms:"\
311
- " #{@payment_terms}, additional_properties: #{@additional_properties}>"
312
- end
313
-
314
- # Provides a debugging-friendly string with detailed object information.
315
- def inspect
316
- class_name = self.class.name.split('::').last
317
- "<#{class_name} type: #{@type.inspect}, load_number: #{@load_number.inspect},"\
318
- " invoice_number: #{@invoice_number.inspect}, carrier_invoice_number:"\
319
- " #{@carrier_invoice_number.inspect}, carrier: #{@carrier.inspect}, factoring_company:"\
320
- " #{@factoring_company.inspect}, stops: #{@stops.inspect}, charges: #{@charges.inspect},"\
321
- " items: #{@items.inspect}, reference_numbers: #{@reference_numbers.inspect}, invoice_date:"\
322
- " #{@invoice_date.inspect}, invoice_due_date: #{@invoice_due_date.inspect}, payment_terms:"\
323
- " #{@payment_terms.inspect}, additional_properties: #{@additional_properties}>"
324
- end
325
- end
326
- end
@@ -1,36 +0,0 @@
1
- # tql_otr_factoring_data_exchange
2
- #
3
- # This file was automatically generated by
4
- # APIMATIC v3.0 ( https://www.apimatic.io ).
5
-
6
- module TqlOtrFactoringDataExchange
7
- # Unit of measure for `weight`. Typically LBS or KG.
8
- class WeightUnit
9
- WEIGHT_UNIT = [
10
- # TODO: Write general description for LBS
11
- LBS = 'LBS'.freeze,
12
-
13
- # TODO: Write general description for KG
14
- KG = 'KG'.freeze
15
- ].freeze
16
-
17
- def self.validate(value)
18
- return false if value.nil?
19
-
20
- WEIGHT_UNIT.include?(value)
21
- end
22
-
23
- def self.from_value(value, default_value = LBS)
24
- return default_value if value.nil?
25
-
26
- str = value.to_s.strip
27
-
28
- case str.downcase
29
- when 'lbs' then LBS
30
- when 'kg' then KG
31
- else
32
- default_value
33
- end
34
- end
35
- end
36
- end
@@ -1,11 +0,0 @@
1
- # tql_otr_factoring_data_exchange
2
- #
3
- # This file was automatically generated by
4
- # APIMATIC v3.0 ( https://www.apimatic.io ).
5
-
6
- require 'date'
7
- module TqlOtrFactoringDataExchange
8
- # A utility that supports dateTime conversion to different formats
9
- class DateTimeHelper < CoreLibrary::DateTimeHelper
10
- end
11
- end
@@ -1,29 +0,0 @@
1
- # tql_otr_factoring_data_exchange
2
- #
3
- # This file was automatically generated by
4
- # APIMATIC v3.0 ( https://www.apimatic.io ).
5
-
6
- module TqlOtrFactoringDataExchange
7
- # The `UnionTypeLookUp` class serves as a utility class for
8
- # storing and managing type combinator templates. It acts as a container for the templates
9
- # used in handling various oneof/anyof instances within the sdk.
10
- class UnionTypeLookUp
11
- include CoreLibrary
12
- # rubocop:disable Lint/RedundantCopDisableDirective, Style/HashSyntax, Layout/FirstArgumentIndentation
13
- def self.union_types
14
- {
15
- :CarrierInput2 => AnyOf.new(
16
- [
17
- LeafType.new(CarrierInput),
18
- LeafType.new(CarrierInput1)
19
- ]
20
- )
21
- }
22
- end
23
- # rubocop:enable Lint/RedundantCopDisableDirective, Style/HashSyntax, Layout/FirstArgumentIndentation
24
-
25
- def self.get(name)
26
- UnionTypeLookUp.union_types[name]
27
- end
28
- end
29
- end
@@ -1,107 +0,0 @@
1
- # tql_otr_factoring_data_exchange
2
- #
3
- # This file was automatically generated by
4
- # APIMATIC v3.0 ( https://www.apimatic.io ).
5
-
6
- require 'date'
7
- require 'json'
8
-
9
- require 'apimatic_core_interfaces'
10
- require 'apimatic_core'
11
- require 'apimatic_faraday_client_adapter'
12
-
13
- require_relative 'tql_otr_factoring_data_exchange/api_helper'
14
- require_relative 'tql_otr_factoring_data_exchange/client'
15
-
16
- # Utilities
17
- require_relative 'tql_otr_factoring_data_exchange/utilities/file_wrapper'
18
- require_relative 'tql_otr_factoring_data_exchange/utilities/date_time_helper'
19
- require_relative 'tql_otr_factoring_data_exchange/utilities/union_type_lookup'
20
-
21
- # Http
22
- require_relative 'tql_otr_factoring_data_exchange/http/api_response'
23
- require_relative 'tql_otr_factoring_data_exchange/http/http_call_back'
24
- require_relative 'tql_otr_factoring_data_exchange/http/http_method_enum'
25
- require_relative 'tql_otr_factoring_data_exchange/http/http_request'
26
- require_relative 'tql_otr_factoring_data_exchange/http/http_response'
27
- require_relative 'tql_otr_factoring_data_exchange/http/proxy_settings'
28
-
29
-
30
- # Logger
31
- require_relative 'tql_otr_factoring_data_exchange/logging/configuration/' \
32
- 'api_logging_configuration'
33
- require_relative 'tql_otr_factoring_data_exchange/logging/sdk_logger'
34
- require_relative 'tql_otr_factoring_data_exchange/http/auth/oauth_2'
35
-
36
- # Models
37
- require_relative 'tql_otr_factoring_data_exchange/models/base_model'
38
- require_relative 'tql_otr_factoring_data_exchange/models/charge_code'
39
- require_relative 'tql_otr_factoring_data_exchange/models/submit_invoice_request'
40
- require_relative 'tql_otr_factoring_data_exchange/models/' \
41
- 'submit_invoice_response'
42
- require_relative 'tql_otr_factoring_data_exchange/models/' \
43
- 'invoice_status_response'
44
- require_relative 'tql_otr_factoring_data_exchange/models/invoice_exception'
45
- require_relative 'tql_otr_factoring_data_exchange/models/invoice_search_request'
46
- require_relative 'tql_otr_factoring_data_exchange/models/' \
47
- 'invoice_search_response'
48
- require_relative 'tql_otr_factoring_data_exchange/models/invoice'
49
- require_relative 'tql_otr_factoring_data_exchange/models/charge_input'
50
- require_relative 'tql_otr_factoring_data_exchange/models/invoice_item_input'
51
- require_relative 'tql_otr_factoring_data_exchange/models/assignment_request'
52
- require_relative 'tql_otr_factoring_data_exchange/models/assignment_response'
53
- require_relative 'tql_otr_factoring_data_exchange/models/' \
54
- 'document_upload_metadata'
55
- require_relative 'tql_otr_factoring_data_exchange/models/' \
56
- 'document_upload_response'
57
- require_relative 'tql_otr_factoring_data_exchange/models/base64_document'
58
- require_relative 'tql_otr_factoring_data_exchange/models/' \
59
- 'base64_document_upload_request'
60
- require_relative 'tql_otr_factoring_data_exchange/models/load_detail'
61
- require_relative 'tql_otr_factoring_data_exchange/models/load_search_request'
62
- require_relative 'tql_otr_factoring_data_exchange/models/load_search_response'
63
- require_relative 'tql_otr_factoring_data_exchange/models/' \
64
- 'factoring_company_input'
65
- require_relative 'tql_otr_factoring_data_exchange/models/stop_input'
66
- require_relative 'tql_otr_factoring_data_exchange/models/reference_number_input'
67
- require_relative 'tql_otr_factoring_data_exchange/models/problem_details'
68
- require_relative 'tql_otr_factoring_data_exchange/models/carrier'
69
- require_relative 'tql_otr_factoring_data_exchange/models/carrier1'
70
- require_relative 'tql_otr_factoring_data_exchange/models/carrier2'
71
- require_relative 'tql_otr_factoring_data_exchange/models/carrier_input'
72
- require_relative 'tql_otr_factoring_data_exchange/models/carrier_input1'
73
- require_relative 'tql_otr_factoring_data_exchange/models/document'
74
- require_relative 'tql_otr_factoring_data_exchange/models/load'
75
- require_relative 'tql_otr_factoring_data_exchange/models/location'
76
- require_relative 'tql_otr_factoring_data_exchange/models/payment'
77
- require_relative 'tql_otr_factoring_data_exchange/models/oauth_token'
78
- require_relative 'tql_otr_factoring_data_exchange/models/load_status'
79
- require_relative 'tql_otr_factoring_data_exchange/models/stop_type'
80
- require_relative 'tql_otr_factoring_data_exchange/models/reference_type'
81
- require_relative 'tql_otr_factoring_data_exchange/models/charge_code_origin'
82
- require_relative 'tql_otr_factoring_data_exchange/models/document_type'
83
- require_relative 'tql_otr_factoring_data_exchange/models/invoice_status'
84
- require_relative 'tql_otr_factoring_data_exchange/models/exception_severity'
85
- require_relative 'tql_otr_factoring_data_exchange/models/invoice_type'
86
- require_relative 'tql_otr_factoring_data_exchange/models/assignment_status'
87
- require_relative 'tql_otr_factoring_data_exchange/models/status'
88
- require_relative 'tql_otr_factoring_data_exchange/models/weight_unit'
89
- require_relative 'tql_otr_factoring_data_exchange/models/oauth_provider_error'
90
- require_relative 'tql_otr_factoring_data_exchange/models/oauth_scope'
91
-
92
- # Exceptions
93
- require_relative 'tql_otr_factoring_data_exchange/exceptions/api_exception'
94
- require_relative 'tql_otr_factoring_data_exchange/exceptions/' \
95
- 'problem_details_error_exception'
96
- require_relative 'tql_otr_factoring_data_exchange/exceptions/' \
97
- 'oauth_provider_exception'
98
-
99
- require_relative 'tql_otr_factoring_data_exchange/configuration'
100
-
101
- # Controllers
102
- require_relative 'tql_otr_factoring_data_exchange/apis/base_api'
103
- require_relative 'tql_otr_factoring_data_exchange/apis/invoices_api'
104
- require_relative 'tql_otr_factoring_data_exchange/apis/documents_api'
105
- require_relative 'tql_otr_factoring_data_exchange/apis/assignments_api'
106
- require_relative 'tql_otr_factoring_data_exchange/apis/loads_api'
107
- require_relative 'tql_otr_factoring_data_exchange/apis/oauth_authorization_api'