primary_connect_client 0.8.0 → 1.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (180) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +25 -0
  3. data/README.md +74 -20
  4. data/docs/Address.md +32 -0
  5. data/docs/CodedValue.md +22 -0
  6. data/docs/DefaultApi.md +637 -0
  7. data/docs/Demographics.md +52 -0
  8. data/docs/Device.md +30 -0
  9. data/docs/Dosage.md +30 -0
  10. data/docs/Error.md +18 -0
  11. data/docs/Event.md +26 -0
  12. data/docs/Events.md +18 -0
  13. data/docs/Identifier.md +20 -0
  14. data/docs/Location.md +28 -0
  15. data/docs/Medication.md +22 -0
  16. data/docs/MedicationAdministration.md +32 -0
  17. data/docs/Meta.md +34 -0
  18. data/docs/MetaDestinations.md +22 -0
  19. data/docs/MetaMessage.md +20 -0
  20. data/docs/MetaSource.md +20 -0
  21. data/docs/MetaTransmission.md +18 -0
  22. data/docs/Name.md +22 -0
  23. data/docs/Order.md +26 -0
  24. data/docs/OrderIds.md +18 -0
  25. data/docs/OrderOrder.md +62 -0
  26. data/docs/OrderOrderClinicalInfo.md +26 -0
  27. data/docs/OrderOrderDiagnoses.md +22 -0
  28. data/docs/OrderOrderOrderingFacility.md +22 -0
  29. data/docs/OrderOrderSpecimen.md +22 -0
  30. data/docs/OrderWithEventErrors.md +20 -0
  31. data/docs/Orders.md +18 -0
  32. data/docs/OrdersOrders.md +22 -0
  33. data/docs/Patient.md +24 -0
  34. data/docs/PatientContacts.md +28 -0
  35. data/docs/PatientDemographics.md +52 -0
  36. data/docs/PhoneNumber.md +20 -0
  37. data/docs/Provider.md +32 -0
  38. data/docs/Result.md +52 -0
  39. data/docs/ResultIds.md +18 -0
  40. data/docs/ResultReferenceRange.md +22 -0
  41. data/docs/ResultReport.md +22 -0
  42. data/docs/ResultSpecimen.md +22 -0
  43. data/docs/Results.md +20 -0
  44. data/docs/Specimen.md +22 -0
  45. data/docs/Subject.md +49 -0
  46. data/docs/SubjectOneOf.md +18 -0
  47. data/docs/SubjectOneOf1.md +18 -0
  48. data/docs/V2Device.md +30 -0
  49. data/docs/V2Dosage.md +30 -0
  50. data/docs/V2Medication.md +22 -0
  51. data/docs/V2MedicationAdministration.md +32 -0
  52. data/docs/Visit.md +36 -0
  53. data/docs/VisitCompany.md +24 -0
  54. data/docs/VisitGuarantor.md +40 -0
  55. data/docs/VisitGuarantorEmployer.md +22 -0
  56. data/docs/VisitInsurances.md +40 -0
  57. data/docs/VisitInsured.md +30 -0
  58. data/docs/VisitPlan.md +22 -0
  59. data/git_push.sh +5 -6
  60. data/lib/primary_connect_client/api/default_api.rb +207 -67
  61. data/lib/primary_connect_client/api_client.rb +5 -6
  62. data/lib/primary_connect_client/api_error.rb +1 -1
  63. data/lib/primary_connect_client/configuration.rb +3 -2
  64. data/lib/primary_connect_client/models/address.rb +281 -0
  65. data/lib/primary_connect_client/models/coded_value.rb +238 -0
  66. data/lib/primary_connect_client/models/demographics.rb +466 -0
  67. data/lib/primary_connect_client/models/device.rb +276 -0
  68. data/lib/primary_connect_client/models/dosage.rb +275 -0
  69. data/lib/primary_connect_client/models/error.rb +218 -0
  70. data/lib/primary_connect_client/models/event.rb +254 -0
  71. data/lib/primary_connect_client/models/events.rb +221 -0
  72. data/lib/primary_connect_client/models/identifier.rb +228 -0
  73. data/lib/primary_connect_client/models/location.rb +264 -0
  74. data/lib/primary_connect_client/models/medication.rb +238 -0
  75. data/lib/primary_connect_client/models/medication_administration.rb +286 -0
  76. data/lib/primary_connect_client/models/meta.rb +327 -0
  77. data/lib/primary_connect_client/models/meta_destinations.rb +242 -0
  78. data/lib/primary_connect_client/models/meta_message.rb +227 -0
  79. data/lib/primary_connect_client/models/meta_source.rb +227 -0
  80. data/lib/primary_connect_client/models/meta_transmission.rb +218 -0
  81. data/lib/primary_connect_client/models/name.rb +237 -0
  82. data/lib/primary_connect_client/models/order.rb +255 -0
  83. data/lib/primary_connect_client/models/order_ids.rb +221 -0
  84. data/lib/primary_connect_client/models/order_order.rb +518 -0
  85. data/lib/primary_connect_client/models/order_order_clinical_info.rb +260 -0
  86. data/lib/primary_connect_client/models/order_order_diagnoses.rb +272 -0
  87. data/lib/primary_connect_client/models/order_order_ordering_facility.rb +239 -0
  88. data/lib/primary_connect_client/models/order_order_specimen.rb +239 -0
  89. data/lib/primary_connect_client/models/order_with_event_errors.rb +229 -0
  90. data/lib/primary_connect_client/models/orders.rb +221 -0
  91. data/lib/primary_connect_client/models/orders_orders.rb +236 -0
  92. data/lib/primary_connect_client/models/patient.rb +253 -0
  93. data/lib/primary_connect_client/models/patient_contacts.rb +305 -0
  94. data/lib/primary_connect_client/models/patient_demographics.rb +466 -0
  95. data/lib/primary_connect_client/models/phone_number.rb +262 -0
  96. data/lib/primary_connect_client/models/provider.rb +288 -0
  97. data/lib/primary_connect_client/models/result.rb +443 -0
  98. data/lib/primary_connect_client/models/result_ids.rb +221 -0
  99. data/lib/primary_connect_client/models/result_reference_range.rb +240 -0
  100. data/lib/primary_connect_client/models/result_report.rb +240 -0
  101. data/lib/primary_connect_client/models/result_specimen.rb +239 -0
  102. data/lib/primary_connect_client/models/results.rb +230 -0
  103. data/lib/primary_connect_client/models/specimen.rb +239 -0
  104. data/lib/primary_connect_client/models/subject.rb +105 -0
  105. data/lib/primary_connect_client/models/subject_one_of.rb +218 -0
  106. data/lib/primary_connect_client/models/subject_one_of1.rb +218 -0
  107. data/lib/primary_connect_client/models/v2_device.rb +276 -0
  108. data/lib/primary_connect_client/models/v2_dosage.rb +275 -0
  109. data/lib/primary_connect_client/models/v2_medication.rb +238 -0
  110. data/lib/primary_connect_client/models/v2_medication_administration.rb +286 -0
  111. data/lib/primary_connect_client/models/visit.rb +306 -0
  112. data/lib/primary_connect_client/models/visit_company.rb +248 -0
  113. data/lib/primary_connect_client/models/visit_guarantor.rb +358 -0
  114. data/lib/primary_connect_client/models/visit_guarantor_employer.rb +238 -0
  115. data/lib/primary_connect_client/models/visit_insurances.rb +386 -0
  116. data/lib/primary_connect_client/models/visit_insured.rb +322 -0
  117. data/lib/primary_connect_client/models/visit_plan.rb +238 -0
  118. data/lib/primary_connect_client/version.rb +12 -2
  119. data/lib/primary_connect_client.rb +56 -3
  120. data/primary_connect_client.gemspec +8 -5
  121. data/spec/api/default_api_spec.rb +56 -41
  122. data/spec/api_client_spec.rb +3 -3
  123. data/spec/configuration_spec.rb +1 -1
  124. data/spec/models/address_spec.rb +76 -0
  125. data/spec/models/coded_value_spec.rb +46 -0
  126. data/spec/models/demographics_spec.rb +168 -0
  127. data/spec/models/device_spec.rb +70 -0
  128. data/spec/models/dosage_spec.rb +70 -0
  129. data/spec/models/error_spec.rb +34 -0
  130. data/spec/models/event_spec.rb +58 -0
  131. data/spec/models/events_spec.rb +34 -0
  132. data/spec/models/identifier_spec.rb +40 -0
  133. data/spec/models/location_spec.rb +64 -0
  134. data/spec/models/medication_administration_spec.rb +76 -0
  135. data/spec/models/medication_spec.rb +46 -0
  136. data/spec/models/meta_destinations_spec.rb +46 -0
  137. data/spec/models/meta_message_spec.rb +40 -0
  138. data/spec/models/meta_source_spec.rb +40 -0
  139. data/spec/models/meta_spec.rb +86 -0
  140. data/spec/models/meta_transmission_spec.rb +34 -0
  141. data/spec/models/name_spec.rb +46 -0
  142. data/spec/models/order_ids_spec.rb +34 -0
  143. data/spec/models/order_order_clinical_info_spec.rb +58 -0
  144. data/spec/models/order_order_diagnoses_spec.rb +50 -0
  145. data/spec/models/order_order_ordering_facility_spec.rb +46 -0
  146. data/spec/models/order_order_spec.rb +182 -0
  147. data/spec/models/order_order_specimen_spec.rb +46 -0
  148. data/spec/models/order_spec.rb +58 -0
  149. data/spec/models/order_with_event_errors_spec.rb +40 -0
  150. data/spec/models/orders_orders_spec.rb +46 -0
  151. data/spec/models/orders_spec.rb +34 -0
  152. data/spec/models/patient_contacts_spec.rb +68 -0
  153. data/spec/models/patient_demographics_spec.rb +168 -0
  154. data/spec/models/patient_spec.rb +52 -0
  155. data/spec/models/phone_number_spec.rb +44 -0
  156. data/spec/models/provider_spec.rb +76 -0
  157. data/spec/models/result_ids_spec.rb +34 -0
  158. data/spec/models/result_reference_range_spec.rb +46 -0
  159. data/spec/models/result_report_spec.rb +46 -0
  160. data/spec/models/result_spec.rb +148 -0
  161. data/spec/models/result_specimen_spec.rb +46 -0
  162. data/spec/models/results_spec.rb +40 -0
  163. data/spec/models/specimen_spec.rb +46 -0
  164. data/spec/models/subject_one_of1_spec.rb +34 -0
  165. data/spec/models/subject_one_of_spec.rb +34 -0
  166. data/spec/models/subject_spec.rb +31 -0
  167. data/spec/models/v2_device_spec.rb +70 -0
  168. data/spec/models/v2_dosage_spec.rb +70 -0
  169. data/spec/models/v2_medication_administration_spec.rb +76 -0
  170. data/spec/models/v2_medication_spec.rb +46 -0
  171. data/spec/models/visit_company_spec.rb +52 -0
  172. data/spec/models/visit_guarantor_employer_spec.rb +46 -0
  173. data/spec/models/visit_guarantor_spec.rb +104 -0
  174. data/spec/models/visit_insurances_spec.rb +112 -0
  175. data/spec/models/visit_insured_spec.rb +78 -0
  176. data/spec/models/visit_plan_spec.rb +46 -0
  177. data/spec/models/visit_spec.rb +88 -0
  178. data/spec/spec_helper.rb +1 -1
  179. metadata +228 -7
  180. data/Gemfile.lock +0 -74
@@ -0,0 +1,637 @@
1
+ # PrimaryConnectClient::DefaultApi
2
+
3
+ All URIs are relative to *https://connect.primary.health*
4
+
5
+ | Method | HTTP request | Description |
6
+ | ------ | ------------ | ----------- |
7
+ | [**cancel_order**](DefaultApi.md#cancel_order) | **DELETE** /api/v1/orders/{id} | cancel order |
8
+ | [**create_order**](DefaultApi.md#create_order) | **POST** /api/v1/orders | create order |
9
+ | [**create_result**](DefaultApi.md#create_result) | **POST** /api/v1/orders/{order_id}/results | create result |
10
+ | [**get_lab_report**](DefaultApi.md#get_lab_report) | **GET** /api/v1/results/{result_id}/lab_report | show lab report |
11
+ | [**get_order**](DefaultApi.md#get_order) | **GET** /api/v1/orders/{id} | show order |
12
+ | [**list_events**](DefaultApi.md#list_events) | **GET** /api/v1/events | list events |
13
+ | [**list_orders**](DefaultApi.md#list_orders) | **GET** /api/v1/orders | list orders |
14
+ | [**list_results**](DefaultApi.md#list_results) | **GET** /api/v1/orders/{order_id}/results | list results |
15
+ | [**update_order**](DefaultApi.md#update_order) | **PUT** /api/v1/orders/{id} | update order |
16
+
17
+
18
+ ## cancel_order
19
+
20
+ > cancel_order(id)
21
+
22
+ cancel order
23
+
24
+ ### Examples
25
+
26
+ ```ruby
27
+ require 'time'
28
+ require 'primary_connect_client'
29
+ # setup authorization
30
+ PrimaryConnectClient.configure do |config|
31
+ # Configure Bearer authorization: bearer_auth
32
+ config.access_token = 'YOUR_BEARER_TOKEN'
33
+ end
34
+
35
+ api_instance = PrimaryConnectClient::DefaultApi.new
36
+ id = '01FGD44Q6MVCG2VNSMC4ZMOTQM' # String | Order ID
37
+
38
+ begin
39
+ # cancel order
40
+ api_instance.cancel_order(id)
41
+ rescue PrimaryConnectClient::ApiError => e
42
+ puts "Error when calling DefaultApi->cancel_order: #{e}"
43
+ end
44
+ ```
45
+
46
+ #### Using the cancel_order_with_http_info variant
47
+
48
+ This returns an Array which contains the response data (`nil` in this case), status code and headers.
49
+
50
+ > <Array(nil, Integer, Hash)> cancel_order_with_http_info(id)
51
+
52
+ ```ruby
53
+ begin
54
+ # cancel order
55
+ data, status_code, headers = api_instance.cancel_order_with_http_info(id)
56
+ p status_code # => 2xx
57
+ p headers # => { ... }
58
+ p data # => nil
59
+ rescue PrimaryConnectClient::ApiError => e
60
+ puts "Error when calling DefaultApi->cancel_order_with_http_info: #{e}"
61
+ end
62
+ ```
63
+
64
+ ### Parameters
65
+
66
+ | Name | Type | Description | Notes |
67
+ | ---- | ---- | ----------- | ----- |
68
+ | **id** | **String** | Order ID | |
69
+
70
+ ### Return type
71
+
72
+ nil (empty response body)
73
+
74
+ ### Authorization
75
+
76
+ [bearer_auth](../README.md#bearer_auth)
77
+
78
+ ### HTTP request headers
79
+
80
+ - **Content-Type**: Not defined
81
+ - **Accept**: application/json
82
+
83
+
84
+ ## create_order
85
+
86
+ > <OrderIds> create_order(opts)
87
+
88
+ create order
89
+
90
+ ### Examples
91
+
92
+ ```ruby
93
+ require 'time'
94
+ require 'primary_connect_client'
95
+ # setup authorization
96
+ PrimaryConnectClient.configure do |config|
97
+ # Configure Bearer authorization: bearer_auth
98
+ config.access_token = 'YOUR_BEARER_TOKEN'
99
+ end
100
+
101
+ api_instance = PrimaryConnectClient::DefaultApi.new
102
+ opts = {
103
+ order: PrimaryConnectClient::Order.new # Order |
104
+ }
105
+
106
+ begin
107
+ # create order
108
+ result = api_instance.create_order(opts)
109
+ p result
110
+ rescue PrimaryConnectClient::ApiError => e
111
+ puts "Error when calling DefaultApi->create_order: #{e}"
112
+ end
113
+ ```
114
+
115
+ #### Using the create_order_with_http_info variant
116
+
117
+ This returns an Array which contains the response data, status code and headers.
118
+
119
+ > <Array(<OrderIds>, Integer, Hash)> create_order_with_http_info(opts)
120
+
121
+ ```ruby
122
+ begin
123
+ # create order
124
+ data, status_code, headers = api_instance.create_order_with_http_info(opts)
125
+ p status_code # => 2xx
126
+ p headers # => { ... }
127
+ p data # => <OrderIds>
128
+ rescue PrimaryConnectClient::ApiError => e
129
+ puts "Error when calling DefaultApi->create_order_with_http_info: #{e}"
130
+ end
131
+ ```
132
+
133
+ ### Parameters
134
+
135
+ | Name | Type | Description | Notes |
136
+ | ---- | ---- | ----------- | ----- |
137
+ | **order** | [**Order**](Order.md) | | [optional] |
138
+
139
+ ### Return type
140
+
141
+ [**OrderIds**](OrderIds.md)
142
+
143
+ ### Authorization
144
+
145
+ [bearer_auth](../README.md#bearer_auth)
146
+
147
+ ### HTTP request headers
148
+
149
+ - **Content-Type**: application/json
150
+ - **Accept**: application/json
151
+
152
+
153
+ ## create_result
154
+
155
+ > <ResultIds> create_result(order_id, opts)
156
+
157
+ create result
158
+
159
+ ### Examples
160
+
161
+ ```ruby
162
+ require 'time'
163
+ require 'primary_connect_client'
164
+ # setup authorization
165
+ PrimaryConnectClient.configure do |config|
166
+ # Configure Bearer authorization: bearer_auth
167
+ config.access_token = 'YOUR_BEARER_TOKEN'
168
+ end
169
+
170
+ api_instance = PrimaryConnectClient::DefaultApi.new
171
+ order_id = '01FGD44Q6MVCG2VNSMCVX5ZCT6' # String | Order id
172
+ opts = {
173
+ results: PrimaryConnectClient::Results.new # Results |
174
+ }
175
+
176
+ begin
177
+ # create result
178
+ result = api_instance.create_result(order_id, opts)
179
+ p result
180
+ rescue PrimaryConnectClient::ApiError => e
181
+ puts "Error when calling DefaultApi->create_result: #{e}"
182
+ end
183
+ ```
184
+
185
+ #### Using the create_result_with_http_info variant
186
+
187
+ This returns an Array which contains the response data, status code and headers.
188
+
189
+ > <Array(<ResultIds>, Integer, Hash)> create_result_with_http_info(order_id, opts)
190
+
191
+ ```ruby
192
+ begin
193
+ # create result
194
+ data, status_code, headers = api_instance.create_result_with_http_info(order_id, opts)
195
+ p status_code # => 2xx
196
+ p headers # => { ... }
197
+ p data # => <ResultIds>
198
+ rescue PrimaryConnectClient::ApiError => e
199
+ puts "Error when calling DefaultApi->create_result_with_http_info: #{e}"
200
+ end
201
+ ```
202
+
203
+ ### Parameters
204
+
205
+ | Name | Type | Description | Notes |
206
+ | ---- | ---- | ----------- | ----- |
207
+ | **order_id** | **String** | Order id | |
208
+ | **results** | [**Results**](Results.md) | | [optional] |
209
+
210
+ ### Return type
211
+
212
+ [**ResultIds**](ResultIds.md)
213
+
214
+ ### Authorization
215
+
216
+ [bearer_auth](../README.md#bearer_auth)
217
+
218
+ ### HTTP request headers
219
+
220
+ - **Content-Type**: application/json
221
+ - **Accept**: application/json
222
+
223
+
224
+ ## get_lab_report
225
+
226
+ > get_lab_report(result_id)
227
+
228
+ show lab report
229
+
230
+ ### Examples
231
+
232
+ ```ruby
233
+ require 'time'
234
+ require 'primary_connect_client'
235
+ # setup authorization
236
+ PrimaryConnectClient.configure do |config|
237
+ # Configure Bearer authorization: bearer_auth
238
+ config.access_token = 'YOUR_BEARER_TOKEN'
239
+ end
240
+
241
+ api_instance = PrimaryConnectClient::DefaultApi.new
242
+ result_id = '01FGD44Q6MVCG2VNSMC4ZMOTQM' # String | Result id
243
+
244
+ begin
245
+ # show lab report
246
+ api_instance.get_lab_report(result_id)
247
+ rescue PrimaryConnectClient::ApiError => e
248
+ puts "Error when calling DefaultApi->get_lab_report: #{e}"
249
+ end
250
+ ```
251
+
252
+ #### Using the get_lab_report_with_http_info variant
253
+
254
+ This returns an Array which contains the response data (`nil` in this case), status code and headers.
255
+
256
+ > <Array(nil, Integer, Hash)> get_lab_report_with_http_info(result_id)
257
+
258
+ ```ruby
259
+ begin
260
+ # show lab report
261
+ data, status_code, headers = api_instance.get_lab_report_with_http_info(result_id)
262
+ p status_code # => 2xx
263
+ p headers # => { ... }
264
+ p data # => nil
265
+ rescue PrimaryConnectClient::ApiError => e
266
+ puts "Error when calling DefaultApi->get_lab_report_with_http_info: #{e}"
267
+ end
268
+ ```
269
+
270
+ ### Parameters
271
+
272
+ | Name | Type | Description | Notes |
273
+ | ---- | ---- | ----------- | ----- |
274
+ | **result_id** | **String** | Result id | |
275
+
276
+ ### Return type
277
+
278
+ nil (empty response body)
279
+
280
+ ### Authorization
281
+
282
+ [bearer_auth](../README.md#bearer_auth)
283
+
284
+ ### HTTP request headers
285
+
286
+ - **Content-Type**: Not defined
287
+ - **Accept**: application/json
288
+
289
+
290
+ ## get_order
291
+
292
+ > <OrderWithEventErrors> get_order(id)
293
+
294
+ show order
295
+
296
+ ### Examples
297
+
298
+ ```ruby
299
+ require 'time'
300
+ require 'primary_connect_client'
301
+ # setup authorization
302
+ PrimaryConnectClient.configure do |config|
303
+ # Configure Bearer authorization: bearer_auth
304
+ config.access_token = 'YOUR_BEARER_TOKEN'
305
+ end
306
+
307
+ api_instance = PrimaryConnectClient::DefaultApi.new
308
+ id = '01FGD44Q6MVCG2VNSMC4ZMOTQM' # String | Order ID
309
+
310
+ begin
311
+ # show order
312
+ result = api_instance.get_order(id)
313
+ p result
314
+ rescue PrimaryConnectClient::ApiError => e
315
+ puts "Error when calling DefaultApi->get_order: #{e}"
316
+ end
317
+ ```
318
+
319
+ #### Using the get_order_with_http_info variant
320
+
321
+ This returns an Array which contains the response data, status code and headers.
322
+
323
+ > <Array(<OrderWithEventErrors>, Integer, Hash)> get_order_with_http_info(id)
324
+
325
+ ```ruby
326
+ begin
327
+ # show order
328
+ data, status_code, headers = api_instance.get_order_with_http_info(id)
329
+ p status_code # => 2xx
330
+ p headers # => { ... }
331
+ p data # => <OrderWithEventErrors>
332
+ rescue PrimaryConnectClient::ApiError => e
333
+ puts "Error when calling DefaultApi->get_order_with_http_info: #{e}"
334
+ end
335
+ ```
336
+
337
+ ### Parameters
338
+
339
+ | Name | Type | Description | Notes |
340
+ | ---- | ---- | ----------- | ----- |
341
+ | **id** | **String** | Order ID | |
342
+
343
+ ### Return type
344
+
345
+ [**OrderWithEventErrors**](OrderWithEventErrors.md)
346
+
347
+ ### Authorization
348
+
349
+ [bearer_auth](../README.md#bearer_auth)
350
+
351
+ ### HTTP request headers
352
+
353
+ - **Content-Type**: Not defined
354
+ - **Accept**: application/json
355
+
356
+
357
+ ## list_events
358
+
359
+ > <Events> list_events(opts)
360
+
361
+ list events
362
+
363
+ ### Examples
364
+
365
+ ```ruby
366
+ require 'time'
367
+ require 'primary_connect_client'
368
+ # setup authorization
369
+ PrimaryConnectClient.configure do |config|
370
+ # Configure Bearer authorization: bearer_auth
371
+ config.access_token = 'YOUR_BEARER_TOKEN'
372
+ end
373
+
374
+ api_instance = PrimaryConnectClient::DefaultApi.new
375
+ opts = {
376
+ last_event_id: '01FGD30NTPNNZE9MKGMWZGHGTZ', # String | Paginate events with event id. 26 character, sortable id.
377
+ event_types: 'OrderCreated,OrderComplete' # String | Filter event_types, comma delimited. [OrderComplete, OrderCreated, OrderError, OrderResulted, OrderUpdated, ResultError, SpecimenReceived]
378
+ }
379
+
380
+ begin
381
+ # list events
382
+ result = api_instance.list_events(opts)
383
+ p result
384
+ rescue PrimaryConnectClient::ApiError => e
385
+ puts "Error when calling DefaultApi->list_events: #{e}"
386
+ end
387
+ ```
388
+
389
+ #### Using the list_events_with_http_info variant
390
+
391
+ This returns an Array which contains the response data, status code and headers.
392
+
393
+ > <Array(<Events>, Integer, Hash)> list_events_with_http_info(opts)
394
+
395
+ ```ruby
396
+ begin
397
+ # list events
398
+ data, status_code, headers = api_instance.list_events_with_http_info(opts)
399
+ p status_code # => 2xx
400
+ p headers # => { ... }
401
+ p data # => <Events>
402
+ rescue PrimaryConnectClient::ApiError => e
403
+ puts "Error when calling DefaultApi->list_events_with_http_info: #{e}"
404
+ end
405
+ ```
406
+
407
+ ### Parameters
408
+
409
+ | Name | Type | Description | Notes |
410
+ | ---- | ---- | ----------- | ----- |
411
+ | **last_event_id** | **String** | Paginate events with event id. 26 character, sortable id. | [optional] |
412
+ | **event_types** | **String** | Filter event_types, comma delimited. [OrderComplete, OrderCreated, OrderError, OrderResulted, OrderUpdated, ResultError, SpecimenReceived] | [optional] |
413
+
414
+ ### Return type
415
+
416
+ [**Events**](Events.md)
417
+
418
+ ### Authorization
419
+
420
+ [bearer_auth](../README.md#bearer_auth)
421
+
422
+ ### HTTP request headers
423
+
424
+ - **Content-Type**: Not defined
425
+ - **Accept**: application/json
426
+
427
+
428
+ ## list_orders
429
+
430
+ > <Orders> list_orders(opts)
431
+
432
+ list orders
433
+
434
+ ### Examples
435
+
436
+ ```ruby
437
+ require 'time'
438
+ require 'primary_connect_client'
439
+ # setup authorization
440
+ PrimaryConnectClient.configure do |config|
441
+ # Configure Bearer authorization: bearer_auth
442
+ config.access_token = 'YOUR_BEARER_TOKEN'
443
+ end
444
+
445
+ api_instance = PrimaryConnectClient::DefaultApi.new
446
+ opts = {
447
+ last_order_id: '01FGD30NTPNNZE9MKGMWZGHGTZ', # String | Paginate orders with order id. 26 character, sortable id.
448
+ state: 'new,resulted', # String | Filter orders by state, comma delimited.[new, updated, delivered, processing, resulted, errored, canceled, unprocessable]
449
+ specimen_id: 'PB1234567' # String | Find an order by specimen/accession id. If found, will redirect to show order endpoint.
450
+ }
451
+
452
+ begin
453
+ # list orders
454
+ result = api_instance.list_orders(opts)
455
+ p result
456
+ rescue PrimaryConnectClient::ApiError => e
457
+ puts "Error when calling DefaultApi->list_orders: #{e}"
458
+ end
459
+ ```
460
+
461
+ #### Using the list_orders_with_http_info variant
462
+
463
+ This returns an Array which contains the response data, status code and headers.
464
+
465
+ > <Array(<Orders>, Integer, Hash)> list_orders_with_http_info(opts)
466
+
467
+ ```ruby
468
+ begin
469
+ # list orders
470
+ data, status_code, headers = api_instance.list_orders_with_http_info(opts)
471
+ p status_code # => 2xx
472
+ p headers # => { ... }
473
+ p data # => <Orders>
474
+ rescue PrimaryConnectClient::ApiError => e
475
+ puts "Error when calling DefaultApi->list_orders_with_http_info: #{e}"
476
+ end
477
+ ```
478
+
479
+ ### Parameters
480
+
481
+ | Name | Type | Description | Notes |
482
+ | ---- | ---- | ----------- | ----- |
483
+ | **last_order_id** | **String** | Paginate orders with order id. 26 character, sortable id. | [optional] |
484
+ | **state** | **String** | Filter orders by state, comma delimited.[new, updated, delivered, processing, resulted, errored, canceled, unprocessable] | [optional] |
485
+ | **specimen_id** | **String** | Find an order by specimen/accession id. If found, will redirect to show order endpoint. | [optional] |
486
+
487
+ ### Return type
488
+
489
+ [**Orders**](Orders.md)
490
+
491
+ ### Authorization
492
+
493
+ [bearer_auth](../README.md#bearer_auth)
494
+
495
+ ### HTTP request headers
496
+
497
+ - **Content-Type**: Not defined
498
+ - **Accept**: application/json
499
+
500
+
501
+ ## list_results
502
+
503
+ > <Results> list_results(order_id)
504
+
505
+ list results
506
+
507
+ ### Examples
508
+
509
+ ```ruby
510
+ require 'time'
511
+ require 'primary_connect_client'
512
+ # setup authorization
513
+ PrimaryConnectClient.configure do |config|
514
+ # Configure Bearer authorization: bearer_auth
515
+ config.access_token = 'YOUR_BEARER_TOKEN'
516
+ end
517
+
518
+ api_instance = PrimaryConnectClient::DefaultApi.new
519
+ order_id = '01FGD44Q6MVCG2VNSMCVX5ZCT6' # String | Order id
520
+
521
+ begin
522
+ # list results
523
+ result = api_instance.list_results(order_id)
524
+ p result
525
+ rescue PrimaryConnectClient::ApiError => e
526
+ puts "Error when calling DefaultApi->list_results: #{e}"
527
+ end
528
+ ```
529
+
530
+ #### Using the list_results_with_http_info variant
531
+
532
+ This returns an Array which contains the response data, status code and headers.
533
+
534
+ > <Array(<Results>, Integer, Hash)> list_results_with_http_info(order_id)
535
+
536
+ ```ruby
537
+ begin
538
+ # list results
539
+ data, status_code, headers = api_instance.list_results_with_http_info(order_id)
540
+ p status_code # => 2xx
541
+ p headers # => { ... }
542
+ p data # => <Results>
543
+ rescue PrimaryConnectClient::ApiError => e
544
+ puts "Error when calling DefaultApi->list_results_with_http_info: #{e}"
545
+ end
546
+ ```
547
+
548
+ ### Parameters
549
+
550
+ | Name | Type | Description | Notes |
551
+ | ---- | ---- | ----------- | ----- |
552
+ | **order_id** | **String** | Order id | |
553
+
554
+ ### Return type
555
+
556
+ [**Results**](Results.md)
557
+
558
+ ### Authorization
559
+
560
+ [bearer_auth](../README.md#bearer_auth)
561
+
562
+ ### HTTP request headers
563
+
564
+ - **Content-Type**: Not defined
565
+ - **Accept**: application/json
566
+
567
+
568
+ ## update_order
569
+
570
+ > <OrderIds> update_order(id, opts)
571
+
572
+ update order
573
+
574
+ ### Examples
575
+
576
+ ```ruby
577
+ require 'time'
578
+ require 'primary_connect_client'
579
+ # setup authorization
580
+ PrimaryConnectClient.configure do |config|
581
+ # Configure Bearer authorization: bearer_auth
582
+ config.access_token = 'YOUR_BEARER_TOKEN'
583
+ end
584
+
585
+ api_instance = PrimaryConnectClient::DefaultApi.new
586
+ id = '01FGD44Q6MVCG2VNSMC4ZMOTQM' # String | Order ID
587
+ opts = {
588
+ order: PrimaryConnectClient::Order.new # Order |
589
+ }
590
+
591
+ begin
592
+ # update order
593
+ result = api_instance.update_order(id, opts)
594
+ p result
595
+ rescue PrimaryConnectClient::ApiError => e
596
+ puts "Error when calling DefaultApi->update_order: #{e}"
597
+ end
598
+ ```
599
+
600
+ #### Using the update_order_with_http_info variant
601
+
602
+ This returns an Array which contains the response data, status code and headers.
603
+
604
+ > <Array(<OrderIds>, Integer, Hash)> update_order_with_http_info(id, opts)
605
+
606
+ ```ruby
607
+ begin
608
+ # update order
609
+ data, status_code, headers = api_instance.update_order_with_http_info(id, opts)
610
+ p status_code # => 2xx
611
+ p headers # => { ... }
612
+ p data # => <OrderIds>
613
+ rescue PrimaryConnectClient::ApiError => e
614
+ puts "Error when calling DefaultApi->update_order_with_http_info: #{e}"
615
+ end
616
+ ```
617
+
618
+ ### Parameters
619
+
620
+ | Name | Type | Description | Notes |
621
+ | ---- | ---- | ----------- | ----- |
622
+ | **id** | **String** | Order ID | |
623
+ | **order** | [**Order**](Order.md) | | [optional] |
624
+
625
+ ### Return type
626
+
627
+ [**OrderIds**](OrderIds.md)
628
+
629
+ ### Authorization
630
+
631
+ [bearer_auth](../README.md#bearer_auth)
632
+
633
+ ### HTTP request headers
634
+
635
+ - **Content-Type**: application/json
636
+ - **Accept**: application/json
637
+
@@ -0,0 +1,52 @@
1
+ # PrimaryConnectClient::Demographics
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **name** | [**Name**](Name.md) | | [optional] |
8
+ | **dob** | **String** | | [optional] |
9
+ | **ssn** | **String** | | [optional] |
10
+ | **sex** | **String** | | [optional] |
11
+ | **gender** | **String** | | [optional] |
12
+ | **sexual_orientation** | **String** | | [optional] |
13
+ | **races** | **Array&lt;String&gt;** | | [optional] |
14
+ | **race_details** | **Array&lt;String&gt;** | | [optional] |
15
+ | **ethnicity** | **String** | | [optional] |
16
+ | **ethnicity_detail** | **Array&lt;String&gt;** | | [optional] |
17
+ | **marital_status** | **String** | | [optional] |
18
+ | **is_deceased** | **Boolean** | | [optional] |
19
+ | **death_date_time** | **Time** | ISO 8601 | [optional] |
20
+ | **phone_numbers** | [**Array&lt;PhoneNumber&gt;**](PhoneNumber.md) | | [optional] |
21
+ | **email_addresses** | **Array&lt;String&gt;** | | [optional] |
22
+ | **language_code** | **String** | | [optional] |
23
+ | **citizenships** | **Array&lt;String&gt;** | | [optional] |
24
+ | **address** | [**Address**](Address.md) | | [optional] |
25
+
26
+ ## Example
27
+
28
+ ```ruby
29
+ require 'primary_connect_client'
30
+
31
+ instance = PrimaryConnectClient::Demographics.new(
32
+ name: null,
33
+ dob: 1992-07-23,
34
+ ssn: null,
35
+ sex: null,
36
+ gender: null,
37
+ sexual_orientation: null,
38
+ races: null,
39
+ race_details: null,
40
+ ethnicity: null,
41
+ ethnicity_detail: null,
42
+ marital_status: null,
43
+ is_deceased: null,
44
+ death_date_time: null,
45
+ phone_numbers: null,
46
+ email_addresses: null,
47
+ language_code: en,
48
+ citizenships: null,
49
+ address: null
50
+ )
51
+ ```
52
+
data/docs/Device.md ADDED
@@ -0,0 +1,30 @@
1
+ # PrimaryConnectClient::Device
2
+
3
+ ## Properties
4
+
5
+ | Name | Type | Description | Notes |
6
+ | ---- | ---- | ----------- | ----- |
7
+ | **device_id** | [**Array&lt;Identifier&gt;**](Identifier.md) | Identifier used to identify the device | [optional] |
8
+ | **manufacturer** | **String** | | [optional] |
9
+ | **model_number** | **String** | | [optional] |
10
+ | **serial_number** | **String** | | [optional] |
11
+ | **address** | [**Address**](Address.md) | | [optional] |
12
+ | **location** | [**Location**](Location.md) | | [optional] |
13
+ | **config** | **Object** | Arbitrary key/value pairs for Device specific use | [optional] |
14
+
15
+ ## Example
16
+
17
+ ```ruby
18
+ require 'primary_connect_client'
19
+
20
+ instance = PrimaryConnectClient::Device.new(
21
+ device_id: null,
22
+ manufacturer: null,
23
+ model_number: null,
24
+ serial_number: null,
25
+ address: null,
26
+ location: null,
27
+ config: {&quot;key1&quot;:&quot;value1&quot;,&quot;key2&quot;:&quot;value2&quot;}
28
+ )
29
+ ```
30
+