primary_connect_client 1.4.0 → 1.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/README.md +8 -4
- data/docs/DefaultApi.md +133 -0
- data/docs/Ids.md +18 -0
- data/docs/Measurement.md +22 -0
- data/docs/OrderOrder.md +2 -0
- data/lib/primary_connect_client/api/default_api.rb +116 -0
- data/lib/primary_connect_client/models/ids.rb +221 -0
- data/lib/primary_connect_client/models/measurement.rb +240 -0
- data/lib/primary_connect_client/models/order_order.rb +13 -1
- data/lib/primary_connect_client/version.rb +1 -1
- data/lib/primary_connect_client.rb +2 -0
- data/primary_connect_client.gemspec +1 -0
- data/spec/api/default_api_spec.rb +21 -0
- data/spec/models/ids_spec.rb +34 -0
- data/spec/models/measurement_spec.rb +46 -0
- data/spec/models/order_order_spec.rb +6 -0
- metadata +39 -11
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 2fba2c726308c0fd123e99a5d2ceca4efc2f9dc09d9b572809e7a44480efd46a
|
4
|
+
data.tar.gz: 162b1b9fad3431aaa2d20cc0610aac70982cb781c9a1527fceb8cfd686e07ded
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 925c18ed682db7211dec940a87cff4ece2f31ac66e91f3e74ef00acd8223fcba7e04c69378d6a8ebb6c59e10b2f6dfd74943d9c5b3e9ef7e3b32fd323f4794da
|
7
|
+
data.tar.gz: bdeb83007e34eac9b0fa1c72f9ece5b9b1f550e5040feaf28bb7e0944cd2b4ca3e4936477bcb9e5002679dcb479d85022ef1f04bb2d141df286b8afae2095faf
|
data/CHANGELOG.md
CHANGED
data/README.md
CHANGED
@@ -7,7 +7,7 @@ Client Library to interface with Primary Connect
|
|
7
7
|
This SDK is automatically generated by the [OpenAPI Generator](https://openapi-generator.tech) project:
|
8
8
|
|
9
9
|
- API version: v1
|
10
|
-
- Package version: 1.
|
10
|
+
- Package version: 1.5.0
|
11
11
|
- Build package: org.openapitools.codegen.languages.RubyClientCodegen
|
12
12
|
|
13
13
|
## Installation
|
@@ -23,16 +23,16 @@ gem build primary_connect_client.gemspec
|
|
23
23
|
Then either install the gem locally:
|
24
24
|
|
25
25
|
```shell
|
26
|
-
gem install ./primary_connect_client-1.
|
26
|
+
gem install ./primary_connect_client-1.5.0.gem
|
27
27
|
```
|
28
28
|
|
29
|
-
(for development, run `gem install --dev ./primary_connect_client-1.
|
29
|
+
(for development, run `gem install --dev ./primary_connect_client-1.5.0.gem` to install the development dependencies)
|
30
30
|
|
31
31
|
or publish the gem to a gem hosting service, e.g. [RubyGems](https://rubygems.org/).
|
32
32
|
|
33
33
|
Finally add this to the Gemfile:
|
34
34
|
|
35
|
-
gem 'primary_connect_client', '~> 1.
|
35
|
+
gem 'primary_connect_client', '~> 1.5.0'
|
36
36
|
|
37
37
|
### Install from Git
|
38
38
|
|
@@ -86,9 +86,11 @@ Class | Method | HTTP request | Description
|
|
86
86
|
*PrimaryConnectClient::DefaultApi* | [**accession_order**](docs/DefaultApi.md#accession_order) | **PUT** /api/v1/orders/{id}/accession | accession order by ULID
|
87
87
|
*PrimaryConnectClient::DefaultApi* | [**accession_order_by_specimen_id**](docs/DefaultApi.md#accession_order_by_specimen_id) | **PUT** /api/v1/orders/accession | accession order by Specimen ID
|
88
88
|
*PrimaryConnectClient::DefaultApi* | [**cancel_order**](docs/DefaultApi.md#cancel_order) | **DELETE** /api/v1/orders/{id} | cancel order
|
89
|
+
*PrimaryConnectClient::DefaultApi* | [**create_measurement**](docs/DefaultApi.md#create_measurement) | **POST** /api/v1/measurements | create Measurement
|
89
90
|
*PrimaryConnectClient::DefaultApi* | [**create_order**](docs/DefaultApi.md#create_order) | **POST** /api/v1/orders | create order
|
90
91
|
*PrimaryConnectClient::DefaultApi* | [**create_result**](docs/DefaultApi.md#create_result) | **POST** /api/v1/orders/{order_id}/results | create result
|
91
92
|
*PrimaryConnectClient::DefaultApi* | [**get_lab_report**](docs/DefaultApi.md#get_lab_report) | **GET** /api/v1/results/{result_id}/lab_report | show lab report
|
93
|
+
*PrimaryConnectClient::DefaultApi* | [**get_measurement**](docs/DefaultApi.md#get_measurement) | **GET** /api/v1/measurements/{id} | show measurement
|
92
94
|
*PrimaryConnectClient::DefaultApi* | [**get_order**](docs/DefaultApi.md#get_order) | **GET** /api/v1/orders/{id} | show order
|
93
95
|
*PrimaryConnectClient::DefaultApi* | [**list_events**](docs/DefaultApi.md#list_events) | **GET** /api/v1/events | list events
|
94
96
|
*PrimaryConnectClient::DefaultApi* | [**list_orders**](docs/DefaultApi.md#list_orders) | **GET** /api/v1/orders | list orders
|
@@ -109,7 +111,9 @@ Class | Method | HTTP request | Description
|
|
109
111
|
- [PrimaryConnectClient::Event](docs/Event.md)
|
110
112
|
- [PrimaryConnectClient::Events](docs/Events.md)
|
111
113
|
- [PrimaryConnectClient::Identifier](docs/Identifier.md)
|
114
|
+
- [PrimaryConnectClient::Ids](docs/Ids.md)
|
112
115
|
- [PrimaryConnectClient::Location](docs/Location.md)
|
116
|
+
- [PrimaryConnectClient::Measurement](docs/Measurement.md)
|
113
117
|
- [PrimaryConnectClient::Medication](docs/Medication.md)
|
114
118
|
- [PrimaryConnectClient::MedicationAdministration](docs/MedicationAdministration.md)
|
115
119
|
- [PrimaryConnectClient::Meta](docs/Meta.md)
|
data/docs/DefaultApi.md
CHANGED
@@ -7,9 +7,11 @@ All URIs are relative to *https://connect.primary.health*
|
|
7
7
|
| [**accession_order**](DefaultApi.md#accession_order) | **PUT** /api/v1/orders/{id}/accession | accession order by ULID |
|
8
8
|
| [**accession_order_by_specimen_id**](DefaultApi.md#accession_order_by_specimen_id) | **PUT** /api/v1/orders/accession | accession order by Specimen ID |
|
9
9
|
| [**cancel_order**](DefaultApi.md#cancel_order) | **DELETE** /api/v1/orders/{id} | cancel order |
|
10
|
+
| [**create_measurement**](DefaultApi.md#create_measurement) | **POST** /api/v1/measurements | create Measurement |
|
10
11
|
| [**create_order**](DefaultApi.md#create_order) | **POST** /api/v1/orders | create order |
|
11
12
|
| [**create_result**](DefaultApi.md#create_result) | **POST** /api/v1/orders/{order_id}/results | create result |
|
12
13
|
| [**get_lab_report**](DefaultApi.md#get_lab_report) | **GET** /api/v1/results/{result_id}/lab_report | show lab report |
|
14
|
+
| [**get_measurement**](DefaultApi.md#get_measurement) | **GET** /api/v1/measurements/{id} | show measurement |
|
13
15
|
| [**get_order**](DefaultApi.md#get_order) | **GET** /api/v1/orders/{id} | show order |
|
14
16
|
| [**list_events**](DefaultApi.md#list_events) | **GET** /api/v1/events | list events |
|
15
17
|
| [**list_orders**](DefaultApi.md#list_orders) | **GET** /api/v1/orders | list orders |
|
@@ -223,6 +225,70 @@ nil (empty response body)
|
|
223
225
|
- **Accept**: application/json
|
224
226
|
|
225
227
|
|
228
|
+
## create_measurement
|
229
|
+
|
230
|
+
> <Ids> create_measurement
|
231
|
+
|
232
|
+
create Measurement
|
233
|
+
|
234
|
+
### Examples
|
235
|
+
|
236
|
+
```ruby
|
237
|
+
require 'time'
|
238
|
+
require 'primary_connect_client'
|
239
|
+
# setup authorization
|
240
|
+
PrimaryConnectClient.configure do |config|
|
241
|
+
# Configure Bearer authorization: bearer_auth
|
242
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
243
|
+
end
|
244
|
+
|
245
|
+
api_instance = PrimaryConnectClient::DefaultApi.new
|
246
|
+
|
247
|
+
begin
|
248
|
+
# create Measurement
|
249
|
+
result = api_instance.create_measurement
|
250
|
+
p result
|
251
|
+
rescue PrimaryConnectClient::ApiError => e
|
252
|
+
puts "Error when calling DefaultApi->create_measurement: #{e}"
|
253
|
+
end
|
254
|
+
```
|
255
|
+
|
256
|
+
#### Using the create_measurement_with_http_info variant
|
257
|
+
|
258
|
+
This returns an Array which contains the response data, status code and headers.
|
259
|
+
|
260
|
+
> <Array(<Ids>, Integer, Hash)> create_measurement_with_http_info
|
261
|
+
|
262
|
+
```ruby
|
263
|
+
begin
|
264
|
+
# create Measurement
|
265
|
+
data, status_code, headers = api_instance.create_measurement_with_http_info
|
266
|
+
p status_code # => 2xx
|
267
|
+
p headers # => { ... }
|
268
|
+
p data # => <Ids>
|
269
|
+
rescue PrimaryConnectClient::ApiError => e
|
270
|
+
puts "Error when calling DefaultApi->create_measurement_with_http_info: #{e}"
|
271
|
+
end
|
272
|
+
```
|
273
|
+
|
274
|
+
### Parameters
|
275
|
+
|
276
|
+
This endpoint does not need any parameter.
|
277
|
+
|
278
|
+
### Return type
|
279
|
+
|
280
|
+
[**Ids**](Ids.md)
|
281
|
+
|
282
|
+
### Authorization
|
283
|
+
|
284
|
+
[bearer_auth](../README.md#bearer_auth)
|
285
|
+
|
286
|
+
### HTTP request headers
|
287
|
+
|
288
|
+
- **Content-Type**: Not defined
|
289
|
+
- **Accept**: application/json
|
290
|
+
|
291
|
+
|
226
292
|
## create_order
|
227
293
|
|
228
294
|
> <OrderIds> create_order(opts)
|
@@ -429,6 +495,73 @@ nil (empty response body)
|
|
429
495
|
- **Accept**: application/json
|
430
496
|
|
431
497
|
|
498
|
+
## get_measurement
|
499
|
+
|
500
|
+
> <Measurement> get_measurement(id)
|
501
|
+
|
502
|
+
show measurement
|
503
|
+
|
504
|
+
### Examples
|
505
|
+
|
506
|
+
```ruby
|
507
|
+
require 'time'
|
508
|
+
require 'primary_connect_client'
|
509
|
+
# setup authorization
|
510
|
+
PrimaryConnectClient.configure do |config|
|
511
|
+
# Configure Bearer authorization: bearer_auth
|
512
|
+
config.access_token = 'YOUR_BEARER_TOKEN'
|
513
|
+
end
|
514
|
+
|
515
|
+
api_instance = PrimaryConnectClient::DefaultApi.new
|
516
|
+
id = '01FGD44Q6MVCG2VNSMC4ZMOTQM' # String | Measurement ID
|
517
|
+
|
518
|
+
begin
|
519
|
+
# show measurement
|
520
|
+
result = api_instance.get_measurement(id)
|
521
|
+
p result
|
522
|
+
rescue PrimaryConnectClient::ApiError => e
|
523
|
+
puts "Error when calling DefaultApi->get_measurement: #{e}"
|
524
|
+
end
|
525
|
+
```
|
526
|
+
|
527
|
+
#### Using the get_measurement_with_http_info variant
|
528
|
+
|
529
|
+
This returns an Array which contains the response data, status code and headers.
|
530
|
+
|
531
|
+
> <Array(<Measurement>, Integer, Hash)> get_measurement_with_http_info(id)
|
532
|
+
|
533
|
+
```ruby
|
534
|
+
begin
|
535
|
+
# show measurement
|
536
|
+
data, status_code, headers = api_instance.get_measurement_with_http_info(id)
|
537
|
+
p status_code # => 2xx
|
538
|
+
p headers # => { ... }
|
539
|
+
p data # => <Measurement>
|
540
|
+
rescue PrimaryConnectClient::ApiError => e
|
541
|
+
puts "Error when calling DefaultApi->get_measurement_with_http_info: #{e}"
|
542
|
+
end
|
543
|
+
```
|
544
|
+
|
545
|
+
### Parameters
|
546
|
+
|
547
|
+
| Name | Type | Description | Notes |
|
548
|
+
| ---- | ---- | ----------- | ----- |
|
549
|
+
| **id** | **String** | Measurement ID | |
|
550
|
+
|
551
|
+
### Return type
|
552
|
+
|
553
|
+
[**Measurement**](Measurement.md)
|
554
|
+
|
555
|
+
### Authorization
|
556
|
+
|
557
|
+
[bearer_auth](../README.md#bearer_auth)
|
558
|
+
|
559
|
+
### HTTP request headers
|
560
|
+
|
561
|
+
- **Content-Type**: Not defined
|
562
|
+
- **Accept**: application/json
|
563
|
+
|
564
|
+
|
432
565
|
## get_order
|
433
566
|
|
434
567
|
> <OrderWithEventErrors> get_order(id)
|
data/docs/Ids.md
ADDED
@@ -0,0 +1,18 @@
|
|
1
|
+
# PrimaryConnectClient::Ids
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **ids** | **Array<String>** | List of IDs | [optional] |
|
8
|
+
|
9
|
+
## Example
|
10
|
+
|
11
|
+
```ruby
|
12
|
+
require 'primary_connect_client'
|
13
|
+
|
14
|
+
instance = PrimaryConnectClient::Ids.new(
|
15
|
+
ids: null
|
16
|
+
)
|
17
|
+
```
|
18
|
+
|
data/docs/Measurement.md
ADDED
@@ -0,0 +1,22 @@
|
|
1
|
+
# PrimaryConnectClient::Measurement
|
2
|
+
|
3
|
+
## Properties
|
4
|
+
|
5
|
+
| Name | Type | Description | Notes |
|
6
|
+
| ---- | ---- | ----------- | ----- |
|
7
|
+
| **meta** | [**Meta**](Meta.md) | | [optional] |
|
8
|
+
| **subject** | [**Subject**](Subject.md) | | [optional] |
|
9
|
+
| **metrics** | [**Array<Result>**](Result.md) | List of result components | [optional] |
|
10
|
+
|
11
|
+
## Example
|
12
|
+
|
13
|
+
```ruby
|
14
|
+
require 'primary_connect_client'
|
15
|
+
|
16
|
+
instance = PrimaryConnectClient::Measurement.new(
|
17
|
+
meta: null,
|
18
|
+
subject: null,
|
19
|
+
metrics: null
|
20
|
+
)
|
21
|
+
```
|
22
|
+
|
data/docs/OrderOrder.md
CHANGED
@@ -16,6 +16,7 @@
|
|
16
16
|
| **specimen** | [**Specimen**](Specimen.md) | | [optional] |
|
17
17
|
| **medication_administrations** | [**Array<MedicationAdministration>**](MedicationAdministration.md) | Array of medications administered to the subject | [optional] |
|
18
18
|
| **procedure** | [**CodedValue**](CodedValue.md) | | [optional] |
|
19
|
+
| **procedures** | [**Array<CodedValues>**](CodedValues.md) | Array of Procedures ordered | [optional] |
|
19
20
|
| **ordering_provider** | [**Provider**](Provider.md) | | [optional] |
|
20
21
|
| **result_copy_providers** | [**Array<Provider>**](Provider.md) | Array of providers to be copied on the results | [optional] |
|
21
22
|
| **ordering_facility** | [**OrderOrderOrderingFacility**](OrderOrderOrderingFacility.md) | | [optional] |
|
@@ -47,6 +48,7 @@ instance = PrimaryConnectClient::OrderOrder.new(
|
|
47
48
|
specimen: null,
|
48
49
|
medication_administrations: null,
|
49
50
|
procedure: null,
|
51
|
+
procedures: null,
|
50
52
|
ordering_provider: null,
|
51
53
|
result_copy_providers: null,
|
52
54
|
ordering_facility: null,
|
@@ -213,6 +213,61 @@ module PrimaryConnectClient
|
|
213
213
|
return data, status_code, headers
|
214
214
|
end
|
215
215
|
|
216
|
+
# create Measurement
|
217
|
+
# @param [Hash] opts the optional parameters
|
218
|
+
# @return [Ids]
|
219
|
+
def create_measurement(opts = {})
|
220
|
+
data, _status_code, _headers = create_measurement_with_http_info(opts)
|
221
|
+
data
|
222
|
+
end
|
223
|
+
|
224
|
+
# create Measurement
|
225
|
+
# @param [Hash] opts the optional parameters
|
226
|
+
# @return [Array<(Ids, Integer, Hash)>] Ids data, response status code and response headers
|
227
|
+
def create_measurement_with_http_info(opts = {})
|
228
|
+
if @api_client.config.debugging
|
229
|
+
@api_client.config.logger.debug 'Calling API: DefaultApi.create_measurement ...'
|
230
|
+
end
|
231
|
+
# resource path
|
232
|
+
local_var_path = '/api/v1/measurements'
|
233
|
+
|
234
|
+
# query parameters
|
235
|
+
query_params = opts[:query_params] || {}
|
236
|
+
|
237
|
+
# header parameters
|
238
|
+
header_params = opts[:header_params] || {}
|
239
|
+
# HTTP header 'Accept' (if needed)
|
240
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
241
|
+
|
242
|
+
# form parameters
|
243
|
+
form_params = opts[:form_params] || {}
|
244
|
+
|
245
|
+
# http body (model)
|
246
|
+
post_body = opts[:debug_body]
|
247
|
+
|
248
|
+
# return_type
|
249
|
+
return_type = opts[:debug_return_type] || 'Ids'
|
250
|
+
|
251
|
+
# auth_names
|
252
|
+
auth_names = opts[:debug_auth_names] || ['bearer_auth']
|
253
|
+
|
254
|
+
new_options = opts.merge(
|
255
|
+
:operation => :"DefaultApi.create_measurement",
|
256
|
+
:header_params => header_params,
|
257
|
+
:query_params => query_params,
|
258
|
+
:form_params => form_params,
|
259
|
+
:body => post_body,
|
260
|
+
:auth_names => auth_names,
|
261
|
+
:return_type => return_type
|
262
|
+
)
|
263
|
+
|
264
|
+
data, status_code, headers = @api_client.call_api(:POST, local_var_path, new_options)
|
265
|
+
if @api_client.config.debugging
|
266
|
+
@api_client.config.logger.debug "API called: DefaultApi#create_measurement\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
267
|
+
end
|
268
|
+
return data, status_code, headers
|
269
|
+
end
|
270
|
+
|
216
271
|
# create order
|
217
272
|
# @param [Hash] opts the optional parameters
|
218
273
|
# @option opts [Order] :order
|
@@ -404,6 +459,67 @@ module PrimaryConnectClient
|
|
404
459
|
return data, status_code, headers
|
405
460
|
end
|
406
461
|
|
462
|
+
# show measurement
|
463
|
+
# @param id [String] Measurement ID
|
464
|
+
# @param [Hash] opts the optional parameters
|
465
|
+
# @return [Measurement]
|
466
|
+
def get_measurement(id, opts = {})
|
467
|
+
data, _status_code, _headers = get_measurement_with_http_info(id, opts)
|
468
|
+
data
|
469
|
+
end
|
470
|
+
|
471
|
+
# show measurement
|
472
|
+
# @param id [String] Measurement ID
|
473
|
+
# @param [Hash] opts the optional parameters
|
474
|
+
# @return [Array<(Measurement, Integer, Hash)>] Measurement data, response status code and response headers
|
475
|
+
def get_measurement_with_http_info(id, opts = {})
|
476
|
+
if @api_client.config.debugging
|
477
|
+
@api_client.config.logger.debug 'Calling API: DefaultApi.get_measurement ...'
|
478
|
+
end
|
479
|
+
# verify the required parameter 'id' is set
|
480
|
+
if @api_client.config.client_side_validation && id.nil?
|
481
|
+
fail ArgumentError, "Missing the required parameter 'id' when calling DefaultApi.get_measurement"
|
482
|
+
end
|
483
|
+
# resource path
|
484
|
+
local_var_path = '/api/v1/measurements/{id}'.sub('{' + 'id' + '}', CGI.escape(id.to_s))
|
485
|
+
|
486
|
+
# query parameters
|
487
|
+
query_params = opts[:query_params] || {}
|
488
|
+
|
489
|
+
# header parameters
|
490
|
+
header_params = opts[:header_params] || {}
|
491
|
+
# HTTP header 'Accept' (if needed)
|
492
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
493
|
+
|
494
|
+
# form parameters
|
495
|
+
form_params = opts[:form_params] || {}
|
496
|
+
|
497
|
+
# http body (model)
|
498
|
+
post_body = opts[:debug_body]
|
499
|
+
|
500
|
+
# return_type
|
501
|
+
return_type = opts[:debug_return_type] || 'Measurement'
|
502
|
+
|
503
|
+
# auth_names
|
504
|
+
auth_names = opts[:debug_auth_names] || ['bearer_auth']
|
505
|
+
|
506
|
+
new_options = opts.merge(
|
507
|
+
:operation => :"DefaultApi.get_measurement",
|
508
|
+
:header_params => header_params,
|
509
|
+
:query_params => query_params,
|
510
|
+
:form_params => form_params,
|
511
|
+
:body => post_body,
|
512
|
+
:auth_names => auth_names,
|
513
|
+
:return_type => return_type
|
514
|
+
)
|
515
|
+
|
516
|
+
data, status_code, headers = @api_client.call_api(:GET, local_var_path, new_options)
|
517
|
+
if @api_client.config.debugging
|
518
|
+
@api_client.config.logger.debug "API called: DefaultApi#get_measurement\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
519
|
+
end
|
520
|
+
return data, status_code, headers
|
521
|
+
end
|
522
|
+
|
407
523
|
# show order
|
408
524
|
# @param id [String] Order ID
|
409
525
|
# @param [Hash] opts the optional parameters
|
@@ -0,0 +1,221 @@
|
|
1
|
+
=begin
|
2
|
+
#Primary Connect API V1
|
3
|
+
|
4
|
+
#Client Library to interface with Primary Connect
|
5
|
+
|
6
|
+
The version of the OpenAPI document: v1
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 5.3.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module PrimaryConnectClient
|
17
|
+
class Ids
|
18
|
+
# List of IDs
|
19
|
+
attr_accessor :ids
|
20
|
+
|
21
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
22
|
+
def self.attribute_map
|
23
|
+
{
|
24
|
+
:'ids' => :'ids'
|
25
|
+
}
|
26
|
+
end
|
27
|
+
|
28
|
+
# Returns all the JSON keys this model knows about
|
29
|
+
def self.acceptable_attributes
|
30
|
+
attribute_map.values
|
31
|
+
end
|
32
|
+
|
33
|
+
# Attribute type mapping.
|
34
|
+
def self.openapi_types
|
35
|
+
{
|
36
|
+
:'ids' => :'Array<String>'
|
37
|
+
}
|
38
|
+
end
|
39
|
+
|
40
|
+
# List of attributes with nullable: true
|
41
|
+
def self.openapi_nullable
|
42
|
+
Set.new([
|
43
|
+
])
|
44
|
+
end
|
45
|
+
|
46
|
+
# Initializes the object
|
47
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
48
|
+
def initialize(attributes = {})
|
49
|
+
if (!attributes.is_a?(Hash))
|
50
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `PrimaryConnectClient::Ids` initialize method"
|
51
|
+
end
|
52
|
+
|
53
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
54
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
55
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
56
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `PrimaryConnectClient::Ids`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
57
|
+
end
|
58
|
+
h[k.to_sym] = v
|
59
|
+
}
|
60
|
+
|
61
|
+
if attributes.key?(:'ids')
|
62
|
+
if (value = attributes[:'ids']).is_a?(Array)
|
63
|
+
self.ids = value
|
64
|
+
end
|
65
|
+
end
|
66
|
+
end
|
67
|
+
|
68
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
69
|
+
# @return Array for valid properties with the reasons
|
70
|
+
def list_invalid_properties
|
71
|
+
invalid_properties = Array.new
|
72
|
+
invalid_properties
|
73
|
+
end
|
74
|
+
|
75
|
+
# Check to see if the all the properties in the model are valid
|
76
|
+
# @return true if the model is valid
|
77
|
+
def valid?
|
78
|
+
true
|
79
|
+
end
|
80
|
+
|
81
|
+
# Checks equality by comparing each attribute.
|
82
|
+
# @param [Object] Object to be compared
|
83
|
+
def ==(o)
|
84
|
+
return true if self.equal?(o)
|
85
|
+
self.class == o.class &&
|
86
|
+
ids == o.ids
|
87
|
+
end
|
88
|
+
|
89
|
+
# @see the `==` method
|
90
|
+
# @param [Object] Object to be compared
|
91
|
+
def eql?(o)
|
92
|
+
self == o
|
93
|
+
end
|
94
|
+
|
95
|
+
# Calculates hash code according to all attributes.
|
96
|
+
# @return [Integer] Hash code
|
97
|
+
def hash
|
98
|
+
[ids].hash
|
99
|
+
end
|
100
|
+
|
101
|
+
# Builds the object from hash
|
102
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
103
|
+
# @return [Object] Returns the model itself
|
104
|
+
def self.build_from_hash(attributes)
|
105
|
+
new.build_from_hash(attributes)
|
106
|
+
end
|
107
|
+
|
108
|
+
# Builds the object from hash
|
109
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
110
|
+
# @return [Object] Returns the model itself
|
111
|
+
def build_from_hash(attributes)
|
112
|
+
return nil unless attributes.is_a?(Hash)
|
113
|
+
self.class.openapi_types.each_pair do |key, type|
|
114
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
115
|
+
self.send("#{key}=", nil)
|
116
|
+
elsif type =~ /\AArray<(.*)>/i
|
117
|
+
# check to ensure the input is an array given that the attribute
|
118
|
+
# is documented as an array but the input is not
|
119
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
120
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
121
|
+
end
|
122
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
123
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
124
|
+
end
|
125
|
+
end
|
126
|
+
|
127
|
+
self
|
128
|
+
end
|
129
|
+
|
130
|
+
# Deserializes the data based on type
|
131
|
+
# @param string type Data type
|
132
|
+
# @param string value Value to be deserialized
|
133
|
+
# @return [Object] Deserialized data
|
134
|
+
def _deserialize(type, value)
|
135
|
+
case type.to_sym
|
136
|
+
when :Time
|
137
|
+
Time.parse(value)
|
138
|
+
when :Date
|
139
|
+
Date.parse(value)
|
140
|
+
when :String
|
141
|
+
value.to_s
|
142
|
+
when :Integer
|
143
|
+
value.to_i
|
144
|
+
when :Float
|
145
|
+
value.to_f
|
146
|
+
when :Boolean
|
147
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
148
|
+
true
|
149
|
+
else
|
150
|
+
false
|
151
|
+
end
|
152
|
+
when :Object
|
153
|
+
# generic object (usually a Hash), return directly
|
154
|
+
value
|
155
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
156
|
+
inner_type = Regexp.last_match[:inner_type]
|
157
|
+
value.map { |v| _deserialize(inner_type, v) }
|
158
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
159
|
+
k_type = Regexp.last_match[:k_type]
|
160
|
+
v_type = Regexp.last_match[:v_type]
|
161
|
+
{}.tap do |hash|
|
162
|
+
value.each do |k, v|
|
163
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
164
|
+
end
|
165
|
+
end
|
166
|
+
else # model
|
167
|
+
# models (e.g. Pet) or oneOf
|
168
|
+
klass = PrimaryConnectClient.const_get(type)
|
169
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
170
|
+
end
|
171
|
+
end
|
172
|
+
|
173
|
+
# Returns the string representation of the object
|
174
|
+
# @return [String] String presentation of the object
|
175
|
+
def to_s
|
176
|
+
to_hash.to_s
|
177
|
+
end
|
178
|
+
|
179
|
+
# to_body is an alias to to_hash (backward compatibility)
|
180
|
+
# @return [Hash] Returns the object in the form of hash
|
181
|
+
def to_body
|
182
|
+
to_hash
|
183
|
+
end
|
184
|
+
|
185
|
+
# Returns the object in the form of hash
|
186
|
+
# @return [Hash] Returns the object in the form of hash
|
187
|
+
def to_hash
|
188
|
+
hash = {}
|
189
|
+
self.class.attribute_map.each_pair do |attr, param|
|
190
|
+
value = self.send(attr)
|
191
|
+
if value.nil?
|
192
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
193
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
194
|
+
end
|
195
|
+
|
196
|
+
hash[param] = _to_hash(value)
|
197
|
+
end
|
198
|
+
hash
|
199
|
+
end
|
200
|
+
|
201
|
+
# Outputs non-array value in the form of hash
|
202
|
+
# For object, use to_hash. Otherwise, just return the value
|
203
|
+
# @param [Object] value Any valid value
|
204
|
+
# @return [Hash] Returns the value in the form of hash
|
205
|
+
def _to_hash(value)
|
206
|
+
if value.is_a?(Array)
|
207
|
+
value.compact.map { |v| _to_hash(v) }
|
208
|
+
elsif value.is_a?(Hash)
|
209
|
+
{}.tap do |hash|
|
210
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
211
|
+
end
|
212
|
+
elsif value.respond_to? :to_hash
|
213
|
+
value.to_hash
|
214
|
+
else
|
215
|
+
value
|
216
|
+
end
|
217
|
+
end
|
218
|
+
|
219
|
+
end
|
220
|
+
|
221
|
+
end
|
@@ -0,0 +1,240 @@
|
|
1
|
+
=begin
|
2
|
+
#Primary Connect API V1
|
3
|
+
|
4
|
+
#Client Library to interface with Primary Connect
|
5
|
+
|
6
|
+
The version of the OpenAPI document: v1
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 5.3.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
require 'time'
|
15
|
+
|
16
|
+
module PrimaryConnectClient
|
17
|
+
class Measurement
|
18
|
+
attr_accessor :meta
|
19
|
+
|
20
|
+
attr_accessor :subject
|
21
|
+
|
22
|
+
# List of result components
|
23
|
+
attr_accessor :metrics
|
24
|
+
|
25
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
26
|
+
def self.attribute_map
|
27
|
+
{
|
28
|
+
:'meta' => :'meta',
|
29
|
+
:'subject' => :'subject',
|
30
|
+
:'metrics' => :'metrics'
|
31
|
+
}
|
32
|
+
end
|
33
|
+
|
34
|
+
# Returns all the JSON keys this model knows about
|
35
|
+
def self.acceptable_attributes
|
36
|
+
attribute_map.values
|
37
|
+
end
|
38
|
+
|
39
|
+
# Attribute type mapping.
|
40
|
+
def self.openapi_types
|
41
|
+
{
|
42
|
+
:'meta' => :'Meta',
|
43
|
+
:'subject' => :'Subject',
|
44
|
+
:'metrics' => :'Array<Result>'
|
45
|
+
}
|
46
|
+
end
|
47
|
+
|
48
|
+
# List of attributes with nullable: true
|
49
|
+
def self.openapi_nullable
|
50
|
+
Set.new([
|
51
|
+
:'subject',
|
52
|
+
])
|
53
|
+
end
|
54
|
+
|
55
|
+
# Initializes the object
|
56
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
57
|
+
def initialize(attributes = {})
|
58
|
+
if (!attributes.is_a?(Hash))
|
59
|
+
fail ArgumentError, "The input argument (attributes) must be a hash in `PrimaryConnectClient::Measurement` initialize method"
|
60
|
+
end
|
61
|
+
|
62
|
+
# check to see if the attribute exists and convert string to symbol for hash key
|
63
|
+
attributes = attributes.each_with_object({}) { |(k, v), h|
|
64
|
+
if (!self.class.attribute_map.key?(k.to_sym))
|
65
|
+
fail ArgumentError, "`#{k}` is not a valid attribute in `PrimaryConnectClient::Measurement`. Please check the name to make sure it's valid. List of attributes: " + self.class.attribute_map.keys.inspect
|
66
|
+
end
|
67
|
+
h[k.to_sym] = v
|
68
|
+
}
|
69
|
+
|
70
|
+
if attributes.key?(:'meta')
|
71
|
+
self.meta = attributes[:'meta']
|
72
|
+
end
|
73
|
+
|
74
|
+
if attributes.key?(:'subject')
|
75
|
+
self.subject = attributes[:'subject']
|
76
|
+
end
|
77
|
+
|
78
|
+
if attributes.key?(:'metrics')
|
79
|
+
if (value = attributes[:'metrics']).is_a?(Array)
|
80
|
+
self.metrics = value
|
81
|
+
end
|
82
|
+
end
|
83
|
+
end
|
84
|
+
|
85
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
86
|
+
# @return Array for valid properties with the reasons
|
87
|
+
def list_invalid_properties
|
88
|
+
invalid_properties = Array.new
|
89
|
+
invalid_properties
|
90
|
+
end
|
91
|
+
|
92
|
+
# Check to see if the all the properties in the model are valid
|
93
|
+
# @return true if the model is valid
|
94
|
+
def valid?
|
95
|
+
true
|
96
|
+
end
|
97
|
+
|
98
|
+
# Checks equality by comparing each attribute.
|
99
|
+
# @param [Object] Object to be compared
|
100
|
+
def ==(o)
|
101
|
+
return true if self.equal?(o)
|
102
|
+
self.class == o.class &&
|
103
|
+
meta == o.meta &&
|
104
|
+
subject == o.subject &&
|
105
|
+
metrics == o.metrics
|
106
|
+
end
|
107
|
+
|
108
|
+
# @see the `==` method
|
109
|
+
# @param [Object] Object to be compared
|
110
|
+
def eql?(o)
|
111
|
+
self == o
|
112
|
+
end
|
113
|
+
|
114
|
+
# Calculates hash code according to all attributes.
|
115
|
+
# @return [Integer] Hash code
|
116
|
+
def hash
|
117
|
+
[meta, subject, metrics].hash
|
118
|
+
end
|
119
|
+
|
120
|
+
# Builds the object from hash
|
121
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
122
|
+
# @return [Object] Returns the model itself
|
123
|
+
def self.build_from_hash(attributes)
|
124
|
+
new.build_from_hash(attributes)
|
125
|
+
end
|
126
|
+
|
127
|
+
# Builds the object from hash
|
128
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
129
|
+
# @return [Object] Returns the model itself
|
130
|
+
def build_from_hash(attributes)
|
131
|
+
return nil unless attributes.is_a?(Hash)
|
132
|
+
self.class.openapi_types.each_pair do |key, type|
|
133
|
+
if attributes[self.class.attribute_map[key]].nil? && self.class.openapi_nullable.include?(key)
|
134
|
+
self.send("#{key}=", nil)
|
135
|
+
elsif type =~ /\AArray<(.*)>/i
|
136
|
+
# check to ensure the input is an array given that the attribute
|
137
|
+
# is documented as an array but the input is not
|
138
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
139
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
140
|
+
end
|
141
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
142
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
143
|
+
end
|
144
|
+
end
|
145
|
+
|
146
|
+
self
|
147
|
+
end
|
148
|
+
|
149
|
+
# Deserializes the data based on type
|
150
|
+
# @param string type Data type
|
151
|
+
# @param string value Value to be deserialized
|
152
|
+
# @return [Object] Deserialized data
|
153
|
+
def _deserialize(type, value)
|
154
|
+
case type.to_sym
|
155
|
+
when :Time
|
156
|
+
Time.parse(value)
|
157
|
+
when :Date
|
158
|
+
Date.parse(value)
|
159
|
+
when :String
|
160
|
+
value.to_s
|
161
|
+
when :Integer
|
162
|
+
value.to_i
|
163
|
+
when :Float
|
164
|
+
value.to_f
|
165
|
+
when :Boolean
|
166
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
167
|
+
true
|
168
|
+
else
|
169
|
+
false
|
170
|
+
end
|
171
|
+
when :Object
|
172
|
+
# generic object (usually a Hash), return directly
|
173
|
+
value
|
174
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
175
|
+
inner_type = Regexp.last_match[:inner_type]
|
176
|
+
value.map { |v| _deserialize(inner_type, v) }
|
177
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
178
|
+
k_type = Regexp.last_match[:k_type]
|
179
|
+
v_type = Regexp.last_match[:v_type]
|
180
|
+
{}.tap do |hash|
|
181
|
+
value.each do |k, v|
|
182
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
183
|
+
end
|
184
|
+
end
|
185
|
+
else # model
|
186
|
+
# models (e.g. Pet) or oneOf
|
187
|
+
klass = PrimaryConnectClient.const_get(type)
|
188
|
+
klass.respond_to?(:openapi_one_of) ? klass.build(value) : klass.build_from_hash(value)
|
189
|
+
end
|
190
|
+
end
|
191
|
+
|
192
|
+
# Returns the string representation of the object
|
193
|
+
# @return [String] String presentation of the object
|
194
|
+
def to_s
|
195
|
+
to_hash.to_s
|
196
|
+
end
|
197
|
+
|
198
|
+
# to_body is an alias to to_hash (backward compatibility)
|
199
|
+
# @return [Hash] Returns the object in the form of hash
|
200
|
+
def to_body
|
201
|
+
to_hash
|
202
|
+
end
|
203
|
+
|
204
|
+
# Returns the object in the form of hash
|
205
|
+
# @return [Hash] Returns the object in the form of hash
|
206
|
+
def to_hash
|
207
|
+
hash = {}
|
208
|
+
self.class.attribute_map.each_pair do |attr, param|
|
209
|
+
value = self.send(attr)
|
210
|
+
if value.nil?
|
211
|
+
is_nullable = self.class.openapi_nullable.include?(attr)
|
212
|
+
next if !is_nullable || (is_nullable && !instance_variable_defined?(:"@#{attr}"))
|
213
|
+
end
|
214
|
+
|
215
|
+
hash[param] = _to_hash(value)
|
216
|
+
end
|
217
|
+
hash
|
218
|
+
end
|
219
|
+
|
220
|
+
# Outputs non-array value in the form of hash
|
221
|
+
# For object, use to_hash. Otherwise, just return the value
|
222
|
+
# @param [Object] value Any valid value
|
223
|
+
# @return [Hash] Returns the value in the form of hash
|
224
|
+
def _to_hash(value)
|
225
|
+
if value.is_a?(Array)
|
226
|
+
value.compact.map { |v| _to_hash(v) }
|
227
|
+
elsif value.is_a?(Hash)
|
228
|
+
{}.tap do |hash|
|
229
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
230
|
+
end
|
231
|
+
elsif value.respond_to? :to_hash
|
232
|
+
value.to_hash
|
233
|
+
else
|
234
|
+
value
|
235
|
+
end
|
236
|
+
end
|
237
|
+
|
238
|
+
end
|
239
|
+
|
240
|
+
end
|
@@ -49,6 +49,9 @@ module PrimaryConnectClient
|
|
49
49
|
|
50
50
|
attr_accessor :procedure
|
51
51
|
|
52
|
+
# Array of Procedures ordered
|
53
|
+
attr_accessor :procedures
|
54
|
+
|
52
55
|
attr_accessor :ordering_provider
|
53
56
|
|
54
57
|
# Array of providers to be copied on the results
|
@@ -119,6 +122,7 @@ module PrimaryConnectClient
|
|
119
122
|
:'specimen' => :'specimen',
|
120
123
|
:'medication_administrations' => :'medicationAdministrations',
|
121
124
|
:'procedure' => :'procedure',
|
125
|
+
:'procedures' => :'procedures',
|
122
126
|
:'ordering_provider' => :'orderingProvider',
|
123
127
|
:'result_copy_providers' => :'resultCopyProviders',
|
124
128
|
:'ordering_facility' => :'orderingFacility',
|
@@ -154,6 +158,7 @@ module PrimaryConnectClient
|
|
154
158
|
:'specimen' => :'Specimen',
|
155
159
|
:'medication_administrations' => :'Array<MedicationAdministration>',
|
156
160
|
:'procedure' => :'CodedValue',
|
161
|
+
:'procedures' => :'Array<CodedValues>',
|
157
162
|
:'ordering_provider' => :'Provider',
|
158
163
|
:'result_copy_providers' => :'Array<Provider>',
|
159
164
|
:'ordering_facility' => :'OrderOrderOrderingFacility',
|
@@ -240,6 +245,12 @@ module PrimaryConnectClient
|
|
240
245
|
self.procedure = attributes[:'procedure']
|
241
246
|
end
|
242
247
|
|
248
|
+
if attributes.key?(:'procedures')
|
249
|
+
if (value = attributes[:'procedures']).is_a?(Array)
|
250
|
+
self.procedures = value
|
251
|
+
end
|
252
|
+
end
|
253
|
+
|
243
254
|
if attributes.key?(:'ordering_provider')
|
244
255
|
self.ordering_provider = attributes[:'ordering_provider']
|
245
256
|
end
|
@@ -379,6 +390,7 @@ module PrimaryConnectClient
|
|
379
390
|
specimen == o.specimen &&
|
380
391
|
medication_administrations == o.medication_administrations &&
|
381
392
|
procedure == o.procedure &&
|
393
|
+
procedures == o.procedures &&
|
382
394
|
ordering_provider == o.ordering_provider &&
|
383
395
|
result_copy_providers == o.result_copy_providers &&
|
384
396
|
ordering_facility == o.ordering_facility &&
|
@@ -402,7 +414,7 @@ module PrimaryConnectClient
|
|
402
414
|
# Calculates hash code according to all attributes.
|
403
415
|
# @return [Integer] Hash code
|
404
416
|
def hash
|
405
|
-
[id, application_order_id, status, transaction_date_time, collection_date_time, collection_start_date_time, completion_date_time, accession_date_time, expiration_date, specimen, medication_administrations, procedure, ordering_provider, result_copy_providers, ordering_facility, priority, diagnoses, clinical_comments, notes, clinical_info, results_status, response_flag, external_ids, results].hash
|
417
|
+
[id, application_order_id, status, transaction_date_time, collection_date_time, collection_start_date_time, completion_date_time, accession_date_time, expiration_date, specimen, medication_administrations, procedure, procedures, ordering_provider, result_copy_providers, ordering_facility, priority, diagnoses, clinical_comments, notes, clinical_info, results_status, response_flag, external_ids, results].hash
|
406
418
|
end
|
407
419
|
|
408
420
|
# Builds the object from hash
|
@@ -28,7 +28,9 @@ require 'primary_connect_client/models/error'
|
|
28
28
|
require 'primary_connect_client/models/event'
|
29
29
|
require 'primary_connect_client/models/events'
|
30
30
|
require 'primary_connect_client/models/identifier'
|
31
|
+
require 'primary_connect_client/models/ids'
|
31
32
|
require 'primary_connect_client/models/location'
|
33
|
+
require 'primary_connect_client/models/measurement'
|
32
34
|
require 'primary_connect_client/models/medication'
|
33
35
|
require 'primary_connect_client/models/medication_administration'
|
34
36
|
require 'primary_connect_client/models/meta'
|
@@ -28,6 +28,7 @@ Gem::Specification.new do |s|
|
|
28
28
|
s.required_ruby_version = ">= 2.4"
|
29
29
|
|
30
30
|
s.add_runtime_dependency 'typhoeus', '~> 1.0', '>= 1.0.1'
|
31
|
+
s.add_runtime_dependency 'primary_connect_proto', '~> 0.17.0', '>= 0.17.0'
|
31
32
|
|
32
33
|
s.add_development_dependency 'rspec', '~> 3.6', '>= 3.6.0'
|
33
34
|
|
@@ -67,6 +67,16 @@ describe 'DefaultApi' do
|
|
67
67
|
end
|
68
68
|
end
|
69
69
|
|
70
|
+
# unit tests for create_measurement
|
71
|
+
# create Measurement
|
72
|
+
# @param [Hash] opts the optional parameters
|
73
|
+
# @return [Ids]
|
74
|
+
describe 'create_measurement test' do
|
75
|
+
it 'should work' do
|
76
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
77
|
+
end
|
78
|
+
end
|
79
|
+
|
70
80
|
# unit tests for create_order
|
71
81
|
# create order
|
72
82
|
# @param [Hash] opts the optional parameters
|
@@ -101,6 +111,17 @@ describe 'DefaultApi' do
|
|
101
111
|
end
|
102
112
|
end
|
103
113
|
|
114
|
+
# unit tests for get_measurement
|
115
|
+
# show measurement
|
116
|
+
# @param id Measurement ID
|
117
|
+
# @param [Hash] opts the optional parameters
|
118
|
+
# @return [Measurement]
|
119
|
+
describe 'get_measurement test' do
|
120
|
+
it 'should work' do
|
121
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
122
|
+
end
|
123
|
+
end
|
124
|
+
|
104
125
|
# unit tests for get_order
|
105
126
|
# show order
|
106
127
|
# @param id Order ID
|
@@ -0,0 +1,34 @@
|
|
1
|
+
=begin
|
2
|
+
#Primary Connect API V1
|
3
|
+
|
4
|
+
#Client Library to interface with Primary Connect
|
5
|
+
|
6
|
+
The version of the OpenAPI document: v1
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 5.3.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
require 'date'
|
16
|
+
|
17
|
+
# Unit tests for PrimaryConnectClient::Ids
|
18
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
19
|
+
# Please update as you see appropriate
|
20
|
+
describe PrimaryConnectClient::Ids do
|
21
|
+
let(:instance) { PrimaryConnectClient::Ids.new }
|
22
|
+
|
23
|
+
describe 'test an instance of Ids' do
|
24
|
+
it 'should create an instance of Ids' do
|
25
|
+
expect(instance).to be_instance_of(PrimaryConnectClient::Ids)
|
26
|
+
end
|
27
|
+
end
|
28
|
+
describe 'test attribute "ids"' do
|
29
|
+
it 'should work' do
|
30
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
31
|
+
end
|
32
|
+
end
|
33
|
+
|
34
|
+
end
|
@@ -0,0 +1,46 @@
|
|
1
|
+
=begin
|
2
|
+
#Primary Connect API V1
|
3
|
+
|
4
|
+
#Client Library to interface with Primary Connect
|
5
|
+
|
6
|
+
The version of the OpenAPI document: v1
|
7
|
+
|
8
|
+
Generated by: https://openapi-generator.tech
|
9
|
+
OpenAPI Generator version: 5.3.0
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'spec_helper'
|
14
|
+
require 'json'
|
15
|
+
require 'date'
|
16
|
+
|
17
|
+
# Unit tests for PrimaryConnectClient::Measurement
|
18
|
+
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
19
|
+
# Please update as you see appropriate
|
20
|
+
describe PrimaryConnectClient::Measurement do
|
21
|
+
let(:instance) { PrimaryConnectClient::Measurement.new }
|
22
|
+
|
23
|
+
describe 'test an instance of Measurement' do
|
24
|
+
it 'should create an instance of Measurement' do
|
25
|
+
expect(instance).to be_instance_of(PrimaryConnectClient::Measurement)
|
26
|
+
end
|
27
|
+
end
|
28
|
+
describe 'test attribute "meta"' do
|
29
|
+
it 'should work' do
|
30
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
31
|
+
end
|
32
|
+
end
|
33
|
+
|
34
|
+
describe 'test attribute "subject"' do
|
35
|
+
it 'should work' do
|
36
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
37
|
+
end
|
38
|
+
end
|
39
|
+
|
40
|
+
describe 'test attribute "metrics"' do
|
41
|
+
it 'should work' do
|
42
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
43
|
+
end
|
44
|
+
end
|
45
|
+
|
46
|
+
end
|
@@ -101,6 +101,12 @@ describe PrimaryConnectClient::OrderOrder do
|
|
101
101
|
end
|
102
102
|
end
|
103
103
|
|
104
|
+
describe 'test attribute "procedures"' do
|
105
|
+
it 'should work' do
|
106
|
+
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
107
|
+
end
|
108
|
+
end
|
109
|
+
|
104
110
|
describe 'test attribute "ordering_provider"' do
|
105
111
|
it 'should work' do
|
106
112
|
# assertion here. ref: https://www.relishapp.com/rspec/rspec-expectations/docs/built-in-matchers
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: primary_connect_client
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.5.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- OpenAPI-Generator
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2022-
|
11
|
+
date: 2022-12-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: typhoeus
|
@@ -31,25 +31,45 @@ dependencies:
|
|
31
31
|
- !ruby/object:Gem::Version
|
32
32
|
version: 1.0.1
|
33
33
|
- !ruby/object:Gem::Dependency
|
34
|
-
name:
|
34
|
+
name: primary_connect_proto
|
35
35
|
requirement: !ruby/object:Gem::Requirement
|
36
36
|
requirements:
|
37
|
+
- - "~>"
|
38
|
+
- !ruby/object:Gem::Version
|
39
|
+
version: 0.17.0
|
37
40
|
- - ">="
|
38
41
|
- !ruby/object:Gem::Version
|
39
|
-
version:
|
42
|
+
version: 0.17.0
|
43
|
+
type: :runtime
|
44
|
+
prerelease: false
|
45
|
+
version_requirements: !ruby/object:Gem::Requirement
|
46
|
+
requirements:
|
47
|
+
- - "~>"
|
48
|
+
- !ruby/object:Gem::Version
|
49
|
+
version: 0.17.0
|
50
|
+
- - ">="
|
51
|
+
- !ruby/object:Gem::Version
|
52
|
+
version: 0.17.0
|
53
|
+
- !ruby/object:Gem::Dependency
|
54
|
+
name: rspec
|
55
|
+
requirement: !ruby/object:Gem::Requirement
|
56
|
+
requirements:
|
40
57
|
- - "~>"
|
41
58
|
- !ruby/object:Gem::Version
|
42
59
|
version: '3.6'
|
60
|
+
- - ">="
|
61
|
+
- !ruby/object:Gem::Version
|
62
|
+
version: 3.6.0
|
43
63
|
type: :development
|
44
64
|
prerelease: false
|
45
65
|
version_requirements: !ruby/object:Gem::Requirement
|
46
66
|
requirements:
|
47
|
-
- - ">="
|
48
|
-
- !ruby/object:Gem::Version
|
49
|
-
version: 3.6.0
|
50
67
|
- - "~>"
|
51
68
|
- !ruby/object:Gem::Version
|
52
69
|
version: '3.6'
|
70
|
+
- - ">="
|
71
|
+
- !ruby/object:Gem::Version
|
72
|
+
version: 3.6.0
|
53
73
|
description: Client Library to interface with Primary Connect
|
54
74
|
email:
|
55
75
|
- ''
|
@@ -73,7 +93,9 @@ files:
|
|
73
93
|
- docs/Event.md
|
74
94
|
- docs/Events.md
|
75
95
|
- docs/Identifier.md
|
96
|
+
- docs/Ids.md
|
76
97
|
- docs/Location.md
|
98
|
+
- docs/Measurement.md
|
77
99
|
- docs/Medication.md
|
78
100
|
- docs/MedicationAdministration.md
|
79
101
|
- docs/Meta.md
|
@@ -135,7 +157,9 @@ files:
|
|
135
157
|
- lib/primary_connect_client/models/event.rb
|
136
158
|
- lib/primary_connect_client/models/events.rb
|
137
159
|
- lib/primary_connect_client/models/identifier.rb
|
160
|
+
- lib/primary_connect_client/models/ids.rb
|
138
161
|
- lib/primary_connect_client/models/location.rb
|
162
|
+
- lib/primary_connect_client/models/measurement.rb
|
139
163
|
- lib/primary_connect_client/models/medication.rb
|
140
164
|
- lib/primary_connect_client/models/medication_administration.rb
|
141
165
|
- lib/primary_connect_client/models/meta.rb
|
@@ -196,7 +220,9 @@ files:
|
|
196
220
|
- spec/models/event_spec.rb
|
197
221
|
- spec/models/events_spec.rb
|
198
222
|
- spec/models/identifier_spec.rb
|
223
|
+
- spec/models/ids_spec.rb
|
199
224
|
- spec/models/location_spec.rb
|
225
|
+
- spec/models/measurement_spec.rb
|
200
226
|
- spec/models/medication_administration_spec.rb
|
201
227
|
- spec/models/medication_spec.rb
|
202
228
|
- spec/models/meta_destinations_spec.rb
|
@@ -247,7 +273,7 @@ homepage: https://openapi-generator.tech
|
|
247
273
|
licenses:
|
248
274
|
- Unlicense
|
249
275
|
metadata: {}
|
250
|
-
post_install_message:
|
276
|
+
post_install_message:
|
251
277
|
rdoc_options: []
|
252
278
|
require_paths:
|
253
279
|
- lib
|
@@ -262,8 +288,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
262
288
|
- !ruby/object:Gem::Version
|
263
289
|
version: '0'
|
264
290
|
requirements: []
|
265
|
-
rubygems_version: 3.
|
266
|
-
signing_key:
|
291
|
+
rubygems_version: 3.2.15
|
292
|
+
signing_key:
|
267
293
|
specification_version: 4
|
268
294
|
summary: Primary Connect API V1 Ruby Gem
|
269
295
|
test_files:
|
@@ -285,6 +311,7 @@ test_files:
|
|
285
311
|
- spec/models/identifier_spec.rb
|
286
312
|
- spec/models/patient_contacts_spec.rb
|
287
313
|
- spec/models/device_spec.rb
|
314
|
+
- spec/models/ids_spec.rb
|
288
315
|
- spec/models/order_ids_spec.rb
|
289
316
|
- spec/models/visit_guarantor_spec.rb
|
290
317
|
- spec/models/v2_dosage_spec.rb
|
@@ -296,6 +323,7 @@ test_files:
|
|
296
323
|
- spec/models/visit_company_spec.rb
|
297
324
|
- spec/models/subject_spec.rb
|
298
325
|
- spec/models/v2_medication_spec.rb
|
326
|
+
- spec/models/measurement_spec.rb
|
299
327
|
- spec/models/medication_spec.rb
|
300
328
|
- spec/models/visit_plan_spec.rb
|
301
329
|
- spec/models/phone_number_spec.rb
|