mirah-ruby 0.1.0 → 0.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/mirah.rb +3 -0
- data/lib/mirah/base_input_object.rb +1 -1
- data/lib/mirah/base_object.rb +1 -1
- data/lib/mirah/data/appointment.rb +16 -2
- data/lib/mirah/data/invitation.rb +30 -0
- data/lib/mirah/data/patient.rb +1 -1
- data/lib/mirah/graphql/fragments.rb +10 -0
- data/lib/mirah/inputs/appointment_input.rb +2 -2
- data/lib/mirah/inputs/patient_input.rb +1 -1
- data/lib/mirah/serializers.rb +29 -6
- data/lib/mirah/version.rb +1 -1
- data/schema.json +689 -24
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 84889ff31445ea17565ffab2d6d20539e6ee29330d6b2c7962ac0909a45f6c14
|
4
|
+
data.tar.gz: 8269903ad8c33be8de855d28ee9c8369cc6c3347abc84695df04fa0530558c48
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2d6ff8c5c1f39d9d994909bd29f9a47c51a8d497961076f1baf0ecf9ce39eca15039f062e183bd3a5699e37676210f994b594afe6dd0ed3ca7637a6dfcaf0606
|
7
|
+
data.tar.gz: 7315d6bf30af466e82a1375ad3545f83913a03495442ef3a959ba2f0035fe3e309ec99e73cbb562cdcf68e51c4b1ae19a1e8f39b58c16e5ba343ccf698a59384
|
data/lib/mirah.rb
CHANGED
@@ -16,6 +16,9 @@ require 'mirah/collection'
|
|
16
16
|
require 'mirah/push_result'
|
17
17
|
require 'mirah/graphql'
|
18
18
|
|
19
|
+
# Invitation is used by appointment and so needs to be loaded first.
|
20
|
+
require 'mirah/data/invitation'
|
21
|
+
|
19
22
|
Dir[File.dirname(__FILE__) + '/mirah/data/**/*.rb'].sort.each do |file|
|
20
23
|
require file
|
21
24
|
end
|
data/lib/mirah/base_object.rb
CHANGED
@@ -36,7 +36,7 @@ module Mirah
|
|
36
36
|
end
|
37
37
|
|
38
38
|
# @private
|
39
|
-
def self.attribute(name, serializer: Serializers::ScalarSerializer, target: name, path: nil)
|
39
|
+
def self.attribute(name, serializer: Serializers::ScalarSerializer.new, target: name, path: nil)
|
40
40
|
attributes.push(
|
41
41
|
{
|
42
42
|
name: name,
|
@@ -23,11 +23,11 @@ module Mirah
|
|
23
23
|
|
24
24
|
# @!attribute [r] start_date
|
25
25
|
# @return [Date] The appointment start date
|
26
|
-
attribute :start_date, serializer: Serializers::DateTimeSerializer
|
26
|
+
attribute :start_date, serializer: Serializers::DateTimeSerializer.new
|
27
27
|
|
28
28
|
# @!attribute [r] end_date
|
29
29
|
# @return [Date] The appointment end date
|
30
|
-
attribute :end_date, serializer: Serializers::DateTimeSerializer
|
30
|
+
attribute :end_date, serializer: Serializers::DateTimeSerializer.new
|
31
31
|
|
32
32
|
# @!attribute [r] minutes_duration
|
33
33
|
# @return [Integer] The legnth of this appointment in minutes
|
@@ -60,6 +60,20 @@ module Mirah
|
|
60
60
|
# @!attribute [r] external_organization_id
|
61
61
|
# @return [string] Your system identifier for the organization this appointment is with
|
62
62
|
attribute :external_organization_id, path: %w[organization], target: 'externalId'
|
63
|
+
|
64
|
+
# @!attribute [r] encounter_id
|
65
|
+
# @return [string] The internal mirah id of the patient
|
66
|
+
attribute :encounter_id, path: %w[measurementEncounter], target: 'id'
|
67
|
+
|
68
|
+
# @!attribute [r] invitations
|
69
|
+
# @return [Array<Invitation>] An array of invitations for measurements associated with this appointment.
|
70
|
+
attribute :invitations, path: %w[measurementEncounter], target: 'measurementInvitations',
|
71
|
+
serializer: Serializers::NestedObjectSerializer.new(Invitation)
|
72
|
+
|
73
|
+
# Whether this appointment has a Mirah measurement encounter associated with it.
|
74
|
+
def measured?
|
75
|
+
!!encounter_id
|
76
|
+
end
|
63
77
|
end
|
64
78
|
end
|
65
79
|
end
|
@@ -0,0 +1,30 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module Mirah
|
4
|
+
module Data
|
5
|
+
# Invitations represent the Mirah system's intent for a given person to take an assessment during a given time
|
6
|
+
# period as part of a given measurement. It tracks when the user can take it and the notifications associated with
|
7
|
+
# such an invitation.
|
8
|
+
class Invitation < BaseObject
|
9
|
+
# @!attribute [r] id
|
10
|
+
# @return [string] The internal Mirah identifier
|
11
|
+
attribute :id
|
12
|
+
|
13
|
+
# @!attribute [r] phase
|
14
|
+
# @return ["BEFORE", "DURING", "AFTER"] The phase this invitation should be taken as part of.
|
15
|
+
attribute :phase
|
16
|
+
|
17
|
+
# @!attribute [r] status
|
18
|
+
# @return ["FUTURE","NEW","SCHEDULED","SENT","BEGUN","COMPLETE","LOCKED_OUT"] The status of the invitation.
|
19
|
+
attribute :status
|
20
|
+
|
21
|
+
# @!attribute [r] notification_status
|
22
|
+
# @return ["SENT", "SCHEDULED", "FORBIDDEN", "MISSING_DETAILS", "NOT_NEEDED"] The status of the invitation.
|
23
|
+
attribute :notification_status
|
24
|
+
|
25
|
+
# @!attribute [r] last_notification_date
|
26
|
+
# @return [Date] The date the latest notification was sent at
|
27
|
+
attribute :last_notification_date, serializer: Serializers::DateTimeSerializer.new
|
28
|
+
end
|
29
|
+
end
|
30
|
+
end
|
data/lib/mirah/data/patient.rb
CHANGED
@@ -23,7 +23,7 @@ module Mirah
|
|
23
23
|
|
24
24
|
# @!attribute [r] birth_date
|
25
25
|
# @return [Date] The patient's date of birth.
|
26
|
-
attribute :birth_date, serializer: Serializers::DateSerializer
|
26
|
+
attribute :birth_date, serializer: Serializers::DateSerializer.new
|
27
27
|
|
28
28
|
# @!attribute [r] gender
|
29
29
|
# @return [string] The patient's gender
|
@@ -10,11 +10,11 @@ module Mirah
|
|
10
10
|
|
11
11
|
# @!attribute [r] start_date
|
12
12
|
# @return (see Mirah::Data::Appointment#start_date)
|
13
|
-
input :start_date, required: false, serializer: Serializers::DateTimeSerializer
|
13
|
+
input :start_date, required: false, serializer: Serializers::DateTimeSerializer.new
|
14
14
|
|
15
15
|
# @!attribute [r] end_date
|
16
16
|
# @return (see Mirah::Data::Appointment#end_date)
|
17
|
-
input :end_date, required: false, serializer: Serializers::DateTimeSerializer
|
17
|
+
input :end_date, required: false, serializer: Serializers::DateTimeSerializer.new
|
18
18
|
|
19
19
|
# @!attribute [r] minutes_duration
|
20
20
|
# @return (see Mirah::Data::Appointment#minutes_duration)
|
@@ -18,7 +18,7 @@ module Mirah
|
|
18
18
|
|
19
19
|
# @!attribute [r] birth_date
|
20
20
|
# @return (see Mirah::Data::Patient#birth_date)
|
21
|
-
input :birth_date, required: false, serializer: Serializers::DateSerializer
|
21
|
+
input :birth_date, required: false, serializer: Serializers::DateSerializer.new
|
22
22
|
|
23
23
|
# @!attribute [r] gender
|
24
24
|
# @return (see Mirah::Data::Patient#gender)
|
data/lib/mirah/serializers.rb
CHANGED
@@ -11,22 +11,22 @@ module Mirah
|
|
11
11
|
# A standard serializer which just passes through the value as defined. This is used for basic JSON types
|
12
12
|
# which have already been serialized correctly.
|
13
13
|
class ScalarSerializer
|
14
|
-
def
|
14
|
+
def serialize(value)
|
15
15
|
value
|
16
16
|
end
|
17
17
|
|
18
|
-
def
|
18
|
+
def deserialize(value)
|
19
19
|
value
|
20
20
|
end
|
21
21
|
end
|
22
22
|
|
23
23
|
# Serialize types for a date in ISO 8601 format.
|
24
24
|
class DateSerializer
|
25
|
-
def
|
25
|
+
def serialize(value)
|
26
26
|
Date.parse(value.to_s).iso8601 if value
|
27
27
|
end
|
28
28
|
|
29
|
-
def
|
29
|
+
def deserialize(value)
|
30
30
|
Date.iso8601(value) if value
|
31
31
|
rescue ArgumentError, TypeError
|
32
32
|
# Invalid input
|
@@ -36,11 +36,11 @@ module Mirah
|
|
36
36
|
|
37
37
|
# Serialize types for a date time in ISO 8601 format.
|
38
38
|
class DateTimeSerializer
|
39
|
-
def
|
39
|
+
def serialize(value)
|
40
40
|
value&.iso8601
|
41
41
|
end
|
42
42
|
|
43
|
-
def
|
43
|
+
def deserialize(value)
|
44
44
|
case value
|
45
45
|
when DateTime
|
46
46
|
value
|
@@ -53,5 +53,28 @@ module Mirah
|
|
53
53
|
nil
|
54
54
|
end
|
55
55
|
end
|
56
|
+
|
57
|
+
# Serialize subobjects using their standard serializer
|
58
|
+
class NestedObjectSerializer
|
59
|
+
def initialize(subclass)
|
60
|
+
@subclass = subclass
|
61
|
+
end
|
62
|
+
|
63
|
+
def serialize(value)
|
64
|
+
if value.is_a? Array
|
65
|
+
value.map(&:to_graphql_hash)
|
66
|
+
else
|
67
|
+
value.to_graphql_hash
|
68
|
+
end
|
69
|
+
end
|
70
|
+
|
71
|
+
def deserialize(value)
|
72
|
+
if value.is_a? Array
|
73
|
+
value.map { |item| @subclass.from_graphql_hash(item) }
|
74
|
+
else
|
75
|
+
@subclass.from_graphql_hash(value)
|
76
|
+
end
|
77
|
+
end
|
78
|
+
end
|
56
79
|
end
|
57
80
|
end
|
data/lib/mirah/version.rb
CHANGED
data/schema.json
CHANGED
@@ -114,6 +114,20 @@
|
|
114
114
|
"isDeprecated": false,
|
115
115
|
"deprecationReason": null
|
116
116
|
},
|
117
|
+
{
|
118
|
+
"name": "measurementEncounter",
|
119
|
+
"description": "The measurement encounter this appointment is associated with",
|
120
|
+
"args": [
|
121
|
+
|
122
|
+
],
|
123
|
+
"type": {
|
124
|
+
"kind": "OBJECT",
|
125
|
+
"name": "Encounter",
|
126
|
+
"ofType": null
|
127
|
+
},
|
128
|
+
"isDeprecated": false,
|
129
|
+
"deprecationReason": null
|
130
|
+
},
|
117
131
|
{
|
118
132
|
"name": "minutesDuration",
|
119
133
|
"description": "The duration of this appointment in minutes.",
|
@@ -538,7 +552,7 @@
|
|
538
552
|
"name": null,
|
539
553
|
"ofType": {
|
540
554
|
"kind": "SCALAR",
|
541
|
-
"name": "
|
555
|
+
"name": "Uuid",
|
542
556
|
"ofType": null
|
543
557
|
}
|
544
558
|
}
|
@@ -556,7 +570,7 @@
|
|
556
570
|
"name": null,
|
557
571
|
"ofType": {
|
558
572
|
"kind": "SCALAR",
|
559
|
-
"name": "
|
573
|
+
"name": "Uuid",
|
560
574
|
"ofType": null
|
561
575
|
}
|
562
576
|
}
|
@@ -2288,6 +2302,32 @@
|
|
2288
2302
|
"isDeprecated": false,
|
2289
2303
|
"deprecationReason": null
|
2290
2304
|
},
|
2305
|
+
{
|
2306
|
+
"name": "measurementInvitations",
|
2307
|
+
"description": "Each Mirah measurement encounter can made up of multiple invitations for responses from different respondents\nat different times.\n",
|
2308
|
+
"args": [
|
2309
|
+
|
2310
|
+
],
|
2311
|
+
"type": {
|
2312
|
+
"kind": "NON_NULL",
|
2313
|
+
"name": null,
|
2314
|
+
"ofType": {
|
2315
|
+
"kind": "LIST",
|
2316
|
+
"name": null,
|
2317
|
+
"ofType": {
|
2318
|
+
"kind": "NON_NULL",
|
2319
|
+
"name": null,
|
2320
|
+
"ofType": {
|
2321
|
+
"kind": "OBJECT",
|
2322
|
+
"name": "MeasurementInvitation",
|
2323
|
+
"ofType": null
|
2324
|
+
}
|
2325
|
+
}
|
2326
|
+
}
|
2327
|
+
},
|
2328
|
+
"isDeprecated": false,
|
2329
|
+
"deprecationReason": null
|
2330
|
+
},
|
2291
2331
|
{
|
2292
2332
|
"name": "mirahStatus",
|
2293
2333
|
"description": "The internal status of this encounter. This does not have a 1:1 correspondence with the FHIR encounter status as there are multiple different failure statuses, for example the patient canceling their appointment may lead to the measurement opportunity being closed, while the practitioner not viewing an active feedback report leads to another.",
|
@@ -2741,8 +2781,366 @@
|
|
2741
2781
|
"deprecationReason": null
|
2742
2782
|
},
|
2743
2783
|
{
|
2744
|
-
"name": "value",
|
2745
|
-
"description": "The value assigned by the system of record",
|
2784
|
+
"name": "value",
|
2785
|
+
"description": "The value assigned by the system of record",
|
2786
|
+
"args": [
|
2787
|
+
|
2788
|
+
],
|
2789
|
+
"type": {
|
2790
|
+
"kind": "NON_NULL",
|
2791
|
+
"name": null,
|
2792
|
+
"ofType": {
|
2793
|
+
"kind": "SCALAR",
|
2794
|
+
"name": "String",
|
2795
|
+
"ofType": null
|
2796
|
+
}
|
2797
|
+
},
|
2798
|
+
"isDeprecated": false,
|
2799
|
+
"deprecationReason": null
|
2800
|
+
}
|
2801
|
+
],
|
2802
|
+
"inputFields": null,
|
2803
|
+
"interfaces": [
|
2804
|
+
|
2805
|
+
],
|
2806
|
+
"enumValues": null,
|
2807
|
+
"possibleTypes": null
|
2808
|
+
},
|
2809
|
+
{
|
2810
|
+
"kind": "ENUM",
|
2811
|
+
"name": "ImportResult",
|
2812
|
+
"description": "Displays the status of the attempt to create or update a row in the system",
|
2813
|
+
"fields": null,
|
2814
|
+
"inputFields": null,
|
2815
|
+
"interfaces": null,
|
2816
|
+
"enumValues": [
|
2817
|
+
{
|
2818
|
+
"name": "CREATED",
|
2819
|
+
"description": "A new row was created",
|
2820
|
+
"isDeprecated": false,
|
2821
|
+
"deprecationReason": null
|
2822
|
+
},
|
2823
|
+
{
|
2824
|
+
"name": "UPDATED",
|
2825
|
+
"description": "A an existing row was updated",
|
2826
|
+
"isDeprecated": false,
|
2827
|
+
"deprecationReason": null
|
2828
|
+
},
|
2829
|
+
{
|
2830
|
+
"name": "SKIPPED",
|
2831
|
+
"description": "The row was understood but the system decided not to process it",
|
2832
|
+
"isDeprecated": false,
|
2833
|
+
"deprecationReason": null
|
2834
|
+
},
|
2835
|
+
{
|
2836
|
+
"name": "ERROR",
|
2837
|
+
"description": "There was an error when processing the row",
|
2838
|
+
"isDeprecated": false,
|
2839
|
+
"deprecationReason": null
|
2840
|
+
}
|
2841
|
+
],
|
2842
|
+
"possibleTypes": null
|
2843
|
+
},
|
2844
|
+
{
|
2845
|
+
"kind": "SCALAR",
|
2846
|
+
"name": "Int",
|
2847
|
+
"description": "Represents non-fractional signed whole numeric values. Int can represent values between -(2^31) and 2^31 - 1.",
|
2848
|
+
"fields": null,
|
2849
|
+
"inputFields": null,
|
2850
|
+
"interfaces": null,
|
2851
|
+
"enumValues": null,
|
2852
|
+
"possibleTypes": null
|
2853
|
+
},
|
2854
|
+
{
|
2855
|
+
"kind": "OBJECT",
|
2856
|
+
"name": "MeasurementInvitation",
|
2857
|
+
"description": "Measurement Invitations represent a non-FHIR object that shows when we expect to gather measurement information\nfrom a given participant.\n",
|
2858
|
+
"fields": [
|
2859
|
+
{
|
2860
|
+
"name": "closesAt",
|
2861
|
+
"description": "When this invitation closes for feedback. No responses will be allowed after this date.",
|
2862
|
+
"args": [
|
2863
|
+
|
2864
|
+
],
|
2865
|
+
"type": {
|
2866
|
+
"kind": "SCALAR",
|
2867
|
+
"name": "ISO8601DateTime",
|
2868
|
+
"ofType": null
|
2869
|
+
},
|
2870
|
+
"isDeprecated": false,
|
2871
|
+
"deprecationReason": null
|
2872
|
+
},
|
2873
|
+
{
|
2874
|
+
"name": "encounter",
|
2875
|
+
"description": "The measurement encounter this invitation is part of",
|
2876
|
+
"args": [
|
2877
|
+
|
2878
|
+
],
|
2879
|
+
"type": {
|
2880
|
+
"kind": "NON_NULL",
|
2881
|
+
"name": null,
|
2882
|
+
"ofType": {
|
2883
|
+
"kind": "OBJECT",
|
2884
|
+
"name": "Encounter",
|
2885
|
+
"ofType": null
|
2886
|
+
}
|
2887
|
+
},
|
2888
|
+
"isDeprecated": false,
|
2889
|
+
"deprecationReason": null
|
2890
|
+
},
|
2891
|
+
{
|
2892
|
+
"name": "globalId",
|
2893
|
+
"description": null,
|
2894
|
+
"args": [
|
2895
|
+
|
2896
|
+
],
|
2897
|
+
"type": {
|
2898
|
+
"kind": "NON_NULL",
|
2899
|
+
"name": null,
|
2900
|
+
"ofType": {
|
2901
|
+
"kind": "SCALAR",
|
2902
|
+
"name": "ID",
|
2903
|
+
"ofType": null
|
2904
|
+
}
|
2905
|
+
},
|
2906
|
+
"isDeprecated": false,
|
2907
|
+
"deprecationReason": null
|
2908
|
+
},
|
2909
|
+
{
|
2910
|
+
"name": "id",
|
2911
|
+
"description": null,
|
2912
|
+
"args": [
|
2913
|
+
|
2914
|
+
],
|
2915
|
+
"type": {
|
2916
|
+
"kind": "NON_NULL",
|
2917
|
+
"name": null,
|
2918
|
+
"ofType": {
|
2919
|
+
"kind": "SCALAR",
|
2920
|
+
"name": "ID",
|
2921
|
+
"ofType": null
|
2922
|
+
}
|
2923
|
+
},
|
2924
|
+
"isDeprecated": false,
|
2925
|
+
"deprecationReason": null
|
2926
|
+
},
|
2927
|
+
{
|
2928
|
+
"name": "lastNotificationDate",
|
2929
|
+
"description": "The date of the last notification to be sent.",
|
2930
|
+
"args": [
|
2931
|
+
|
2932
|
+
],
|
2933
|
+
"type": {
|
2934
|
+
"kind": "SCALAR",
|
2935
|
+
"name": "ISO8601DateTime",
|
2936
|
+
"ofType": null
|
2937
|
+
},
|
2938
|
+
"isDeprecated": false,
|
2939
|
+
"deprecationReason": null
|
2940
|
+
},
|
2941
|
+
{
|
2942
|
+
"name": "notificationStatus",
|
2943
|
+
"description": "The status of the notifications on this invitation",
|
2944
|
+
"args": [
|
2945
|
+
|
2946
|
+
],
|
2947
|
+
"type": {
|
2948
|
+
"kind": "NON_NULL",
|
2949
|
+
"name": null,
|
2950
|
+
"ofType": {
|
2951
|
+
"kind": "ENUM",
|
2952
|
+
"name": "MeasurementInvitationNotificationStatus",
|
2953
|
+
"ofType": null
|
2954
|
+
}
|
2955
|
+
},
|
2956
|
+
"isDeprecated": false,
|
2957
|
+
"deprecationReason": null
|
2958
|
+
},
|
2959
|
+
{
|
2960
|
+
"name": "opensAt",
|
2961
|
+
"description": "When this invitation opens for feedback. No responses will be allowed before this date.",
|
2962
|
+
"args": [
|
2963
|
+
|
2964
|
+
],
|
2965
|
+
"type": {
|
2966
|
+
"kind": "SCALAR",
|
2967
|
+
"name": "ISO8601DateTime",
|
2968
|
+
"ofType": null
|
2969
|
+
},
|
2970
|
+
"isDeprecated": false,
|
2971
|
+
"deprecationReason": null
|
2972
|
+
},
|
2973
|
+
{
|
2974
|
+
"name": "phase",
|
2975
|
+
"description": "The phase of measurement this invitation is part of",
|
2976
|
+
"args": [
|
2977
|
+
|
2978
|
+
],
|
2979
|
+
"type": {
|
2980
|
+
"kind": "NON_NULL",
|
2981
|
+
"name": null,
|
2982
|
+
"ofType": {
|
2983
|
+
"kind": "ENUM",
|
2984
|
+
"name": "MeasurementInvitationPhase",
|
2985
|
+
"ofType": null
|
2986
|
+
}
|
2987
|
+
},
|
2988
|
+
"isDeprecated": false,
|
2989
|
+
"deprecationReason": null
|
2990
|
+
},
|
2991
|
+
{
|
2992
|
+
"name": "status",
|
2993
|
+
"description": "The status of this invitation",
|
2994
|
+
"args": [
|
2995
|
+
|
2996
|
+
],
|
2997
|
+
"type": {
|
2998
|
+
"kind": "NON_NULL",
|
2999
|
+
"name": null,
|
3000
|
+
"ofType": {
|
3001
|
+
"kind": "ENUM",
|
3002
|
+
"name": "MeasurementInvitationStatus",
|
3003
|
+
"ofType": null
|
3004
|
+
}
|
3005
|
+
},
|
3006
|
+
"isDeprecated": false,
|
3007
|
+
"deprecationReason": null
|
3008
|
+
}
|
3009
|
+
],
|
3010
|
+
"inputFields": null,
|
3011
|
+
"interfaces": [
|
3012
|
+
|
3013
|
+
],
|
3014
|
+
"enumValues": null,
|
3015
|
+
"possibleTypes": null
|
3016
|
+
},
|
3017
|
+
{
|
3018
|
+
"kind": "OBJECT",
|
3019
|
+
"name": "MeasurementInvitationConnection",
|
3020
|
+
"description": "The connection type for MeasurementInvitation.",
|
3021
|
+
"fields": [
|
3022
|
+
{
|
3023
|
+
"name": "edges",
|
3024
|
+
"description": "A list of edges.",
|
3025
|
+
"args": [
|
3026
|
+
|
3027
|
+
],
|
3028
|
+
"type": {
|
3029
|
+
"kind": "NON_NULL",
|
3030
|
+
"name": null,
|
3031
|
+
"ofType": {
|
3032
|
+
"kind": "LIST",
|
3033
|
+
"name": null,
|
3034
|
+
"ofType": {
|
3035
|
+
"kind": "NON_NULL",
|
3036
|
+
"name": null,
|
3037
|
+
"ofType": {
|
3038
|
+
"kind": "OBJECT",
|
3039
|
+
"name": "MeasurementInvitationEdge",
|
3040
|
+
"ofType": null
|
3041
|
+
}
|
3042
|
+
}
|
3043
|
+
}
|
3044
|
+
},
|
3045
|
+
"isDeprecated": false,
|
3046
|
+
"deprecationReason": null
|
3047
|
+
},
|
3048
|
+
{
|
3049
|
+
"name": "nodes",
|
3050
|
+
"description": "A list of nodes.",
|
3051
|
+
"args": [
|
3052
|
+
|
3053
|
+
],
|
3054
|
+
"type": {
|
3055
|
+
"kind": "NON_NULL",
|
3056
|
+
"name": null,
|
3057
|
+
"ofType": {
|
3058
|
+
"kind": "LIST",
|
3059
|
+
"name": null,
|
3060
|
+
"ofType": {
|
3061
|
+
"kind": "NON_NULL",
|
3062
|
+
"name": null,
|
3063
|
+
"ofType": {
|
3064
|
+
"kind": "OBJECT",
|
3065
|
+
"name": "MeasurementInvitation",
|
3066
|
+
"ofType": null
|
3067
|
+
}
|
3068
|
+
}
|
3069
|
+
}
|
3070
|
+
},
|
3071
|
+
"isDeprecated": false,
|
3072
|
+
"deprecationReason": null
|
3073
|
+
},
|
3074
|
+
{
|
3075
|
+
"name": "pageInfo",
|
3076
|
+
"description": "Information to aid in pagination.",
|
3077
|
+
"args": [
|
3078
|
+
|
3079
|
+
],
|
3080
|
+
"type": {
|
3081
|
+
"kind": "NON_NULL",
|
3082
|
+
"name": null,
|
3083
|
+
"ofType": {
|
3084
|
+
"kind": "OBJECT",
|
3085
|
+
"name": "PageInfo",
|
3086
|
+
"ofType": null
|
3087
|
+
}
|
3088
|
+
},
|
3089
|
+
"isDeprecated": false,
|
3090
|
+
"deprecationReason": null
|
3091
|
+
},
|
3092
|
+
{
|
3093
|
+
"name": "totalCount",
|
3094
|
+
"description": null,
|
3095
|
+
"args": [
|
3096
|
+
|
3097
|
+
],
|
3098
|
+
"type": {
|
3099
|
+
"kind": "NON_NULL",
|
3100
|
+
"name": null,
|
3101
|
+
"ofType": {
|
3102
|
+
"kind": "SCALAR",
|
3103
|
+
"name": "Int",
|
3104
|
+
"ofType": null
|
3105
|
+
}
|
3106
|
+
},
|
3107
|
+
"isDeprecated": false,
|
3108
|
+
"deprecationReason": null
|
3109
|
+
}
|
3110
|
+
],
|
3111
|
+
"inputFields": null,
|
3112
|
+
"interfaces": [
|
3113
|
+
|
3114
|
+
],
|
3115
|
+
"enumValues": null,
|
3116
|
+
"possibleTypes": null
|
3117
|
+
},
|
3118
|
+
{
|
3119
|
+
"kind": "OBJECT",
|
3120
|
+
"name": "MeasurementInvitationEdge",
|
3121
|
+
"description": "An edge in a connection.",
|
3122
|
+
"fields": [
|
3123
|
+
{
|
3124
|
+
"name": "cursor",
|
3125
|
+
"description": "A cursor for use in pagination.",
|
3126
|
+
"args": [
|
3127
|
+
|
3128
|
+
],
|
3129
|
+
"type": {
|
3130
|
+
"kind": "NON_NULL",
|
3131
|
+
"name": null,
|
3132
|
+
"ofType": {
|
3133
|
+
"kind": "SCALAR",
|
3134
|
+
"name": "String",
|
3135
|
+
"ofType": null
|
3136
|
+
}
|
3137
|
+
},
|
3138
|
+
"isDeprecated": false,
|
3139
|
+
"deprecationReason": null
|
3140
|
+
},
|
3141
|
+
{
|
3142
|
+
"name": "node",
|
3143
|
+
"description": "The item at the end of the edge.",
|
2746
3144
|
"args": [
|
2747
3145
|
|
2748
3146
|
],
|
@@ -2750,8 +3148,8 @@
|
|
2750
3148
|
"kind": "NON_NULL",
|
2751
3149
|
"name": null,
|
2752
3150
|
"ofType": {
|
2753
|
-
"kind": "
|
2754
|
-
"name": "
|
3151
|
+
"kind": "OBJECT",
|
3152
|
+
"name": "MeasurementInvitation",
|
2755
3153
|
"ofType": null
|
2756
3154
|
}
|
2757
3155
|
},
|
@@ -2768,33 +3166,39 @@
|
|
2768
3166
|
},
|
2769
3167
|
{
|
2770
3168
|
"kind": "ENUM",
|
2771
|
-
"name": "
|
2772
|
-
"description": "
|
3169
|
+
"name": "MeasurementInvitationNotificationStatus",
|
3170
|
+
"description": "The status of notifications for an invitation.\n",
|
2773
3171
|
"fields": null,
|
2774
3172
|
"inputFields": null,
|
2775
3173
|
"interfaces": null,
|
2776
3174
|
"enumValues": [
|
2777
3175
|
{
|
2778
|
-
"name": "
|
2779
|
-
"description": "
|
3176
|
+
"name": "SENT",
|
3177
|
+
"description": "Notifications have been sent",
|
2780
3178
|
"isDeprecated": false,
|
2781
3179
|
"deprecationReason": null
|
2782
3180
|
},
|
2783
3181
|
{
|
2784
|
-
"name": "
|
2785
|
-
"description": "
|
3182
|
+
"name": "SCHEDULED",
|
3183
|
+
"description": "Notifications will be sent and are scheduled",
|
2786
3184
|
"isDeprecated": false,
|
2787
3185
|
"deprecationReason": null
|
2788
3186
|
},
|
2789
3187
|
{
|
2790
|
-
"name": "
|
2791
|
-
"description": "The
|
3188
|
+
"name": "FORBIDDEN",
|
3189
|
+
"description": "The respondent has turned off notifications and none will be sent",
|
2792
3190
|
"isDeprecated": false,
|
2793
3191
|
"deprecationReason": null
|
2794
3192
|
},
|
2795
3193
|
{
|
2796
|
-
"name": "
|
2797
|
-
"description": "There
|
3194
|
+
"name": "MISSING_DETAILS",
|
3195
|
+
"description": "There are insufficient contact details to send notifications",
|
3196
|
+
"isDeprecated": false,
|
3197
|
+
"deprecationReason": null
|
3198
|
+
},
|
3199
|
+
{
|
3200
|
+
"name": "NOT_NEEDED",
|
3201
|
+
"description": "No notifications were required for this invitation.",
|
2798
3202
|
"isDeprecated": false,
|
2799
3203
|
"deprecationReason": null
|
2800
3204
|
}
|
@@ -2802,13 +3206,108 @@
|
|
2802
3206
|
"possibleTypes": null
|
2803
3207
|
},
|
2804
3208
|
{
|
2805
|
-
"kind": "
|
2806
|
-
"name": "
|
2807
|
-
"description": "
|
3209
|
+
"kind": "ENUM",
|
3210
|
+
"name": "MeasurementInvitationPhase",
|
3211
|
+
"description": "The phase of a measurement, i.e. before, during or after the target date.\n",
|
2808
3212
|
"fields": null,
|
2809
3213
|
"inputFields": null,
|
2810
3214
|
"interfaces": null,
|
2811
|
-
"enumValues":
|
3215
|
+
"enumValues": [
|
3216
|
+
{
|
3217
|
+
"name": "BEFORE",
|
3218
|
+
"description": "Before the target date",
|
3219
|
+
"isDeprecated": false,
|
3220
|
+
"deprecationReason": null
|
3221
|
+
},
|
3222
|
+
{
|
3223
|
+
"name": "DURING",
|
3224
|
+
"description": "During the target date",
|
3225
|
+
"isDeprecated": false,
|
3226
|
+
"deprecationReason": null
|
3227
|
+
},
|
3228
|
+
{
|
3229
|
+
"name": "AFTER",
|
3230
|
+
"description": "After the target date",
|
3231
|
+
"isDeprecated": false,
|
3232
|
+
"deprecationReason": null
|
3233
|
+
}
|
3234
|
+
],
|
3235
|
+
"possibleTypes": null
|
3236
|
+
},
|
3237
|
+
{
|
3238
|
+
"kind": "ENUM",
|
3239
|
+
"name": "MeasurementInvitationSortParameter",
|
3240
|
+
"description": null,
|
3241
|
+
"fields": null,
|
3242
|
+
"inputFields": null,
|
3243
|
+
"interfaces": null,
|
3244
|
+
"enumValues": [
|
3245
|
+
{
|
3246
|
+
"name": "ID",
|
3247
|
+
"description": "Id",
|
3248
|
+
"isDeprecated": false,
|
3249
|
+
"deprecationReason": null
|
3250
|
+
}
|
3251
|
+
],
|
3252
|
+
"possibleTypes": null
|
3253
|
+
},
|
3254
|
+
{
|
3255
|
+
"kind": "ENUM",
|
3256
|
+
"name": "MeasurementInvitationStatus",
|
3257
|
+
"description": "The status of an invitation to measurement. This is not a standard FHIR resource but instead forms part of\nMirah's custom measurement system.\n",
|
3258
|
+
"fields": null,
|
3259
|
+
"inputFields": null,
|
3260
|
+
"interfaces": null,
|
3261
|
+
"enumValues": [
|
3262
|
+
{
|
3263
|
+
"name": "FUTURE",
|
3264
|
+
"description": "The invitation is for the future and cannot be used yet",
|
3265
|
+
"isDeprecated": false,
|
3266
|
+
"deprecationReason": null
|
3267
|
+
},
|
3268
|
+
{
|
3269
|
+
"name": "NEW",
|
3270
|
+
"description": "The invitation is open but is not configured to send any notifications",
|
3271
|
+
"isDeprecated": false,
|
3272
|
+
"deprecationReason": null
|
3273
|
+
},
|
3274
|
+
{
|
3275
|
+
"name": "SCHEDULED",
|
3276
|
+
"description": "The invitation is open for feedback and notifications are scheduled",
|
3277
|
+
"isDeprecated": false,
|
3278
|
+
"deprecationReason": null
|
3279
|
+
},
|
3280
|
+
{
|
3281
|
+
"name": "SENT",
|
3282
|
+
"description": "The invitation is open for feedback and notification have been sent",
|
3283
|
+
"isDeprecated": false,
|
3284
|
+
"deprecationReason": null
|
3285
|
+
},
|
3286
|
+
{
|
3287
|
+
"name": "BEGUN",
|
3288
|
+
"description": "The invitation has been started by the participant",
|
3289
|
+
"isDeprecated": false,
|
3290
|
+
"deprecationReason": null
|
3291
|
+
},
|
3292
|
+
{
|
3293
|
+
"name": "COMPLETE",
|
3294
|
+
"description": "The invitation has been completed by the participant",
|
3295
|
+
"isDeprecated": false,
|
3296
|
+
"deprecationReason": null
|
3297
|
+
},
|
3298
|
+
{
|
3299
|
+
"name": "LOCKED_OUT",
|
3300
|
+
"description": "The invitation has been locked due to failed login attempts.",
|
3301
|
+
"isDeprecated": false,
|
3302
|
+
"deprecationReason": null
|
3303
|
+
},
|
3304
|
+
{
|
3305
|
+
"name": "EXPIRED",
|
3306
|
+
"description": "The invitation was not started and has expired",
|
3307
|
+
"isDeprecated": false,
|
3308
|
+
"deprecationReason": null
|
3309
|
+
}
|
3310
|
+
],
|
2812
3311
|
"possibleTypes": null
|
2813
3312
|
},
|
2814
3313
|
{
|
@@ -4011,7 +4510,7 @@
|
|
4011
4510
|
"name": null,
|
4012
4511
|
"ofType": {
|
4013
4512
|
"kind": "SCALAR",
|
4014
|
-
"name": "
|
4513
|
+
"name": "Uuid",
|
4015
4514
|
"ofType": null
|
4016
4515
|
}
|
4017
4516
|
}
|
@@ -4029,7 +4528,7 @@
|
|
4029
4528
|
"name": null,
|
4030
4529
|
"ofType": {
|
4031
4530
|
"kind": "SCALAR",
|
4032
|
-
"name": "
|
4531
|
+
"name": "Uuid",
|
4033
4532
|
"ofType": null
|
4034
4533
|
}
|
4035
4534
|
}
|
@@ -5624,7 +6123,7 @@
|
|
5624
6123
|
"name": null,
|
5625
6124
|
"ofType": {
|
5626
6125
|
"kind": "SCALAR",
|
5627
|
-
"name": "
|
6126
|
+
"name": "Uuid",
|
5628
6127
|
"ofType": null
|
5629
6128
|
}
|
5630
6129
|
}
|
@@ -5642,7 +6141,7 @@
|
|
5642
6141
|
"name": null,
|
5643
6142
|
"ofType": {
|
5644
6143
|
"kind": "SCALAR",
|
5645
|
-
"name": "
|
6144
|
+
"name": "Uuid",
|
5646
6145
|
"ofType": null
|
5647
6146
|
}
|
5648
6147
|
}
|
@@ -5678,6 +6177,162 @@
|
|
5678
6177
|
"isDeprecated": false,
|
5679
6178
|
"deprecationReason": null
|
5680
6179
|
},
|
6180
|
+
{
|
6181
|
+
"name": "measurementInvitation",
|
6182
|
+
"description": "Find a measurement_invitation by ID",
|
6183
|
+
"args": [
|
6184
|
+
{
|
6185
|
+
"name": "id",
|
6186
|
+
"description": null,
|
6187
|
+
"type": {
|
6188
|
+
"kind": "NON_NULL",
|
6189
|
+
"name": null,
|
6190
|
+
"ofType": {
|
6191
|
+
"kind": "SCALAR",
|
6192
|
+
"name": "ID",
|
6193
|
+
"ofType": null
|
6194
|
+
}
|
6195
|
+
},
|
6196
|
+
"defaultValue": null
|
6197
|
+
}
|
6198
|
+
],
|
6199
|
+
"type": {
|
6200
|
+
"kind": "OBJECT",
|
6201
|
+
"name": "MeasurementInvitation",
|
6202
|
+
"ofType": null
|
6203
|
+
},
|
6204
|
+
"isDeprecated": false,
|
6205
|
+
"deprecationReason": null
|
6206
|
+
},
|
6207
|
+
{
|
6208
|
+
"name": "measurementInvitations",
|
6209
|
+
"description": "List measurement_invitation objects",
|
6210
|
+
"args": [
|
6211
|
+
{
|
6212
|
+
"name": "after",
|
6213
|
+
"description": "Returns the elements in the list that come after the specified cursor.",
|
6214
|
+
"type": {
|
6215
|
+
"kind": "SCALAR",
|
6216
|
+
"name": "String",
|
6217
|
+
"ofType": null
|
6218
|
+
},
|
6219
|
+
"defaultValue": null
|
6220
|
+
},
|
6221
|
+
{
|
6222
|
+
"name": "before",
|
6223
|
+
"description": "Returns the elements in the list that come before the specified cursor.",
|
6224
|
+
"type": {
|
6225
|
+
"kind": "SCALAR",
|
6226
|
+
"name": "String",
|
6227
|
+
"ofType": null
|
6228
|
+
},
|
6229
|
+
"defaultValue": null
|
6230
|
+
},
|
6231
|
+
{
|
6232
|
+
"name": "first",
|
6233
|
+
"description": "Returns the first _n_ elements from the list.",
|
6234
|
+
"type": {
|
6235
|
+
"kind": "SCALAR",
|
6236
|
+
"name": "Int",
|
6237
|
+
"ofType": null
|
6238
|
+
},
|
6239
|
+
"defaultValue": null
|
6240
|
+
},
|
6241
|
+
{
|
6242
|
+
"name": "last",
|
6243
|
+
"description": "Returns the last _n_ elements from the list.",
|
6244
|
+
"type": {
|
6245
|
+
"kind": "SCALAR",
|
6246
|
+
"name": "Int",
|
6247
|
+
"ofType": null
|
6248
|
+
},
|
6249
|
+
"defaultValue": null
|
6250
|
+
},
|
6251
|
+
{
|
6252
|
+
"name": "sortBy",
|
6253
|
+
"description": null,
|
6254
|
+
"type": {
|
6255
|
+
"kind": "ENUM",
|
6256
|
+
"name": "MeasurementInvitationSortParameter",
|
6257
|
+
"ofType": null
|
6258
|
+
},
|
6259
|
+
"defaultValue": null
|
6260
|
+
},
|
6261
|
+
{
|
6262
|
+
"name": "sortDirection",
|
6263
|
+
"description": null,
|
6264
|
+
"type": {
|
6265
|
+
"kind": "ENUM",
|
6266
|
+
"name": "SortDirection",
|
6267
|
+
"ofType": null
|
6268
|
+
},
|
6269
|
+
"defaultValue": null
|
6270
|
+
},
|
6271
|
+
{
|
6272
|
+
"name": "encounterId",
|
6273
|
+
"description": "The id of the encounter",
|
6274
|
+
"type": {
|
6275
|
+
"kind": "LIST",
|
6276
|
+
"name": null,
|
6277
|
+
"ofType": {
|
6278
|
+
"kind": "NON_NULL",
|
6279
|
+
"name": null,
|
6280
|
+
"ofType": {
|
6281
|
+
"kind": "SCALAR",
|
6282
|
+
"name": "Uuid",
|
6283
|
+
"ofType": null
|
6284
|
+
}
|
6285
|
+
}
|
6286
|
+
},
|
6287
|
+
"defaultValue": null
|
6288
|
+
},
|
6289
|
+
{
|
6290
|
+
"name": "status",
|
6291
|
+
"description": "The status of the notifications",
|
6292
|
+
"type": {
|
6293
|
+
"kind": "LIST",
|
6294
|
+
"name": null,
|
6295
|
+
"ofType": {
|
6296
|
+
"kind": "NON_NULL",
|
6297
|
+
"name": null,
|
6298
|
+
"ofType": {
|
6299
|
+
"kind": "ENUM",
|
6300
|
+
"name": "MeasurementInvitationNotificationStatus",
|
6301
|
+
"ofType": null
|
6302
|
+
}
|
6303
|
+
}
|
6304
|
+
},
|
6305
|
+
"defaultValue": null
|
6306
|
+
},
|
6307
|
+
{
|
6308
|
+
"name": "opensAt",
|
6309
|
+
"description": "Filter by measurement open date.",
|
6310
|
+
"type": {
|
6311
|
+
"kind": "INPUT_OBJECT",
|
6312
|
+
"name": "DateRangeInput",
|
6313
|
+
"ofType": null
|
6314
|
+
},
|
6315
|
+
"defaultValue": null
|
6316
|
+
},
|
6317
|
+
{
|
6318
|
+
"name": "closesAt",
|
6319
|
+
"description": "Filter by measurement end date.",
|
6320
|
+
"type": {
|
6321
|
+
"kind": "INPUT_OBJECT",
|
6322
|
+
"name": "DateRangeInput",
|
6323
|
+
"ofType": null
|
6324
|
+
},
|
6325
|
+
"defaultValue": null
|
6326
|
+
}
|
6327
|
+
],
|
6328
|
+
"type": {
|
6329
|
+
"kind": "OBJECT",
|
6330
|
+
"name": "MeasurementInvitationConnection",
|
6331
|
+
"ofType": null
|
6332
|
+
},
|
6333
|
+
"isDeprecated": false,
|
6334
|
+
"deprecationReason": null
|
6335
|
+
},
|
5681
6336
|
{
|
5682
6337
|
"name": "observation",
|
5683
6338
|
"description": "Find a observation by ID",
|
@@ -7942,6 +8597,16 @@
|
|
7942
8597
|
"enumValues": null,
|
7943
8598
|
"possibleTypes": null
|
7944
8599
|
},
|
8600
|
+
{
|
8601
|
+
"kind": "SCALAR",
|
8602
|
+
"name": "Uuid",
|
8603
|
+
"description": "A unique object identifier as defined by https://www.ietf.org/rfc/rfc4122.txt",
|
8604
|
+
"fields": null,
|
8605
|
+
"inputFields": null,
|
8606
|
+
"interfaces": null,
|
8607
|
+
"enumValues": null,
|
8608
|
+
"possibleTypes": null
|
8609
|
+
},
|
7945
8610
|
{
|
7946
8611
|
"kind": "OBJECT",
|
7947
8612
|
"name": "__Directive",
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: mirah-ruby
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ben Jones
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: exe
|
11
11
|
cert_chain: []
|
12
|
-
date: 2020-06-
|
12
|
+
date: 2020-06-16 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activesupport
|
@@ -166,6 +166,7 @@ files:
|
|
166
166
|
- lib/mirah/client.rb
|
167
167
|
- lib/mirah/collection.rb
|
168
168
|
- lib/mirah/data/appointment.rb
|
169
|
+
- lib/mirah/data/invitation.rb
|
169
170
|
- lib/mirah/data/organization.rb
|
170
171
|
- lib/mirah/data/page_info.rb
|
171
172
|
- lib/mirah/data/patient.rb
|
@@ -213,8 +214,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
213
214
|
- !ruby/object:Gem::Version
|
214
215
|
version: '0'
|
215
216
|
requirements: []
|
216
|
-
|
217
|
-
rubygems_version: 2.7.10
|
217
|
+
rubygems_version: 3.1.2
|
218
218
|
signing_key:
|
219
219
|
specification_version: 4
|
220
220
|
summary: Connect to your data on Mirah.
|