luma 0.0.7 → 0.0.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: '00429d3b54d9cda59b281b0446ff7585008fcc498f2199f0fce23855c2582cc6'
4
- data.tar.gz: 1c15d031ecf8b95be3d2fa97082ef6e6f72ba0d090351ad5c8fae594764a6312
3
+ metadata.gz: 154f08ce7d11575161ae8c86c50e69caa8194a205562e94d340591bfaa6dd906
4
+ data.tar.gz: 2e29bfa638c795d4708e449ca8fbfc93a6ed23d9eed67c075687bd4b6eee158c
5
5
  SHA512:
6
- metadata.gz: b50ab8b8b32e94a2d10d5782b01935781613af96aeae2e6efd5c1211f6cfbe5528d92fb134aa0248c5131ca59a9ae485f855d28f7eb102469f66b39c1f98a1ed
7
- data.tar.gz: 3353c539d5e508a10af4f8807620935d07db0432f9382ef0355a135f9dc9ba1ffbd073179da644efcb69fcf15a0b5ff4914d59f86f009321708754b71143e6f0
6
+ metadata.gz: f8d86c0863c92155c7e4700ab0cc827a4b4b10e1a6985f158427db84144f971e1764696616d0f5416d2bed915b53e8f881a7751aae1e20cc46c835b685b852ca
7
+ data.tar.gz: 8f12b4d72357213e5db9e6f5c110abccced32403344541d57bf1edf2288d188143e0060a7183cbe26a4cb3ffb2c3bf1babe3443cdf58eb981266030425a9f7b4
data/CHANGELOG.md CHANGED
@@ -4,6 +4,13 @@ All notable changes to this project will be documented in this file.
4
4
  The format is based on [Keep a Changelog](http://keepachangelog.com/en/1.0.0/)
5
5
  and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.html).
6
6
 
7
+ ## [0.0.8] - 2021-11-02
8
+
9
+ ### Added
10
+
11
+ - Add API access for creating an appointment (POST)
12
+ - Add Appointment model for use in creating appointment payload
13
+
7
14
  ## [0.0.7] - 2021-10-25
8
15
 
9
16
  ### Added
@@ -49,6 +56,7 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
49
56
 
50
57
  - Initial Create
51
58
 
59
+ [0.0.8]: https://github.com/WeInfuse/luma/compare/v0.0.7...v0.0.8
52
60
  [0.0.7]: https://github.com/WeInfuse/luma/compare/v0.0.6...v0.0.7
53
61
  [0.0.6]: https://github.com/WeInfuse/luma/compare/v0.0.5...v0.0.6
54
62
  [0.0.5]: https://github.com/WeInfuse/luma/compare/v0.0.4...v0.0.5
data/README.md CHANGED
@@ -76,6 +76,21 @@ body = Luma::Models::Patient.new(first_name: 'Ruby',
76
76
  Luma::Patient.new.create_patient(body: body)
77
77
  ```
78
78
 
79
+ ### Create Appointment
80
+ ```ruby
81
+ body = Luma::Models::Appointment.new(
82
+ appt_date: '2019-06-18T15:45:00.000Z',
83
+ appt_duration: '60',
84
+ appt_status: 'Unconfirmed',
85
+ patient_id: '12345',
86
+ provider_id: '23456',
87
+ facility_id: '34567',
88
+ appt_type_id: '45678',
89
+ )
90
+
91
+ Luma::Appointment.new.create_appointment(body: body)
92
+ ```
93
+
79
94
  ## Development
80
95
 
81
96
  ### Prep
@@ -0,0 +1,14 @@
1
+ module Luma
2
+ class Appointment < Connection
3
+ APPOINTMENT_ENDPOINT = '/api/appointments'.freeze
4
+
5
+ base_uri 'https://api.lumahealth.io/'.freeze
6
+
7
+ def create_appointment(endpoint: APPOINTMENT_ENDPOINT, body: nil, headers: {}, auth: true, verb: :post, debug_output: $stdout)
8
+ @body = body
9
+ self.add_headers_and_body if auth
10
+
11
+ self.class.send(verb.to_s, endpoint, body: @body, headers: @headers)
12
+ end
13
+ end
14
+ end
@@ -0,0 +1,17 @@
1
+ module Luma
2
+ module Models
3
+ class Appointment < Hashie::Trash
4
+ include Hashie::Extensions::IgnoreUndeclared
5
+ include Hashie::Extensions::IndifferentAccess
6
+
7
+ property :date, from: :appt_date, required: false
8
+ property :duration, from: :appt_duration, required: false
9
+ property :status, from: :appt_status, required: false
10
+ property :patient, from: :patient_id, required: false
11
+ property :provider, from: :provider_id, required: false
12
+ property :facility, from: :facility_id, required: false
13
+ property :type, from: :appt_type_id, required: false
14
+
15
+ end
16
+ end
17
+ end
data/lib/luma/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Luma
2
- VERSION = '0.0.7'.freeze
2
+ VERSION = '0.0.8'.freeze
3
3
  end
data/lib/luma.rb CHANGED
@@ -11,6 +11,8 @@ require 'luma/patient'
11
11
  require 'luma/models/contact'
12
12
  require 'luma/models/date_of_birth'
13
13
  require 'luma/models/patient'
14
+ require 'luma/appointment'
15
+ require 'luma/models/appointment'
14
16
 
15
17
  module Luma
16
18
  class Configuration
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: luma
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.7
4
+ version: 0.0.8
5
5
  platform: ruby
6
6
  authors:
7
7
  - Angela Rodriguez
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2021-10-25 00:00:00.000000000 Z
11
+ date: 2021-11-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: httparty
@@ -155,11 +155,13 @@ files:
155
155
  - README.md
156
156
  - Rakefile
157
157
  - lib/luma.rb
158
+ - lib/luma/appointment.rb
158
159
  - lib/luma/appointment_type.rb
159
160
  - lib/luma/authentication.rb
160
161
  - lib/luma/connection.rb
161
162
  - lib/luma/facilities.rb
162
163
  - lib/luma/luma_exception.rb
164
+ - lib/luma/models/appointment.rb
163
165
  - lib/luma/models/contact.rb
164
166
  - lib/luma/models/date_of_birth.rb
165
167
  - lib/luma/models/patient.rb
@@ -187,7 +189,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
187
189
  - !ruby/object:Gem::Version
188
190
  version: '0'
189
191
  requirements: []
190
- rubygems_version: 3.1.4
192
+ rubygems_version: 3.0.3
191
193
  signing_key:
192
194
  specification_version: 4
193
195
  summary: Ruby wrapper for the Luma Health API