Portal bug fixes and features update (#7600)
[openemr.git] / swagger / openemr-api.yaml
blob1f83fdf643092833983edad4c680bd5598e8aac4
1 openapi: 3.0.0
2 info:
3   title: 'OpenEMR API'
4   version: 7.0.3
5 servers:
6   -
7     url: /apis/default/
8 paths:
9   /api/facility:
10     get:
11       tags:
12         - standard
13       description: 'Returns a single facility.'
14       parameters:
15         -
16           name: name
17           in: query
18           description: 'The name for the facility.'
19           required: false
20           schema:
21             type: string
22         -
23           name: facility_npi
24           in: query
25           description: 'The facility_npi for the facility.'
26           required: false
27           schema:
28             type: string
29         -
30           name: phone
31           in: query
32           description: 'The phone for the facility.'
33           required: false
34           schema:
35             type: string
36         -
37           name: fax
38           in: query
39           description: 'The fax for the facility.'
40           required: false
41           schema:
42             type: string
43         -
44           name: street
45           in: query
46           description: 'The street for the facility.'
47           required: false
48           schema:
49             type: string
50         -
51           name: city
52           in: query
53           description: 'The city for the facility.'
54           required: false
55           schema:
56             type: string
57         -
58           name: state
59           in: query
60           description: 'The state for the facility.'
61           required: false
62           schema:
63             type: string
64         -
65           name: postal_code
66           in: query
67           description: 'The postal_code for the facility.'
68           required: false
69           schema:
70             type: string
71         -
72           name: country_code
73           in: query
74           description: 'The country_code for the facility.'
75           required: false
76           schema:
77             type: string
78         -
79           name: federal_ein
80           in: query
81           description: 'The federal_ein for the facility.'
82           required: false
83           schema:
84             type: string
85         -
86           name: website
87           in: query
88           description: 'The website for the facility.'
89           required: false
90           schema:
91             type: string
92         -
93           name: email
94           in: query
95           description: 'The email for the facility.'
96           required: false
97           schema:
98             type: string
99         -
100           name: domain_identifier
101           in: query
102           description: 'The domain_identifier for the facility.'
103           required: false
104           schema:
105             type: string
106         -
107           name: facility_taxonomy
108           in: query
109           description: 'The facility_taxonomy for the facility.'
110           required: false
111           schema:
112             type: string
113         -
114           name: facility_code
115           in: query
116           description: 'The facility_code for the facility.'
117           required: false
118           schema:
119             type: string
120         -
121           name: billing_location
122           in: query
123           description: 'The billing_location setting for the facility.'
124           required: false
125           schema:
126             type: string
127         -
128           name: accepts_assignment
129           in: query
130           description: 'The accepts_assignment setting for the facility.'
131           required: false
132           schema:
133             type: string
134         -
135           name: oid
136           in: query
137           description: 'The oid for the facility.'
138           required: false
139           schema:
140             type: string
141         -
142           name: service_location
143           in: query
144           description: 'The service_location setting for the facility.'
145           required: false
146           schema:
147             type: string
148       responses:
149         '200':
150           $ref: '#/components/responses/standard'
151         '400':
152           $ref: '#/components/responses/badrequest'
153         '401':
154           $ref: '#/components/responses/unauthorized'
155       security:
156         -
157           openemr_auth: []
158     post:
159       tags:
160         - standard
161       description: 'Creates a facility in the system'
162       requestBody:
163         required: true
164         content:
165           application/json:
166             schema:
167               required:
168                 - name
169                 - facility_npi
170               properties:
171                 name:
172                   description: 'The name for the facility.'
173                   type: string
174                 facility_npi:
175                   description: 'The facility_npi for the facility.'
176                   type: string
177                 phone:
178                   description: 'The phone for the facility.'
179                   type: string
180                 fax:
181                   description: 'The fax for the facility.'
182                   type: string
183                 street:
184                   description: 'The street for the facility.'
185                   type: string
186                 city:
187                   description: 'The city for the facility.'
188                   type: string
189                 state:
190                   description: 'The state for the facility.'
191                   type: string
192                 postal_code:
193                   description: 'The postal_code for the facility.'
194                   type: string
195                 country_code:
196                   description: 'The country_code for the facility.'
197                   type: string
198                 federal_ein:
199                   description: 'The federal_ein for the facility.'
200                   type: string
201                 website:
202                   description: 'The website for the facility.'
203                   type: string
204                 email:
205                   description: 'The email for the facility.'
206                   type: string
207                 domain_identifier:
208                   description: 'The domain_identifier for the facility.'
209                   type: string
210                 facility_taxonomy:
211                   description: 'The facility_taxonomy for the facility.'
212                   type: string
213                 facility_code:
214                   description: 'The facility_code for the facility.'
215                   type: string
216                 billing_location:
217                   description: 'The billing_location setting for the facility.'
218                   type: string
219                 accepts_assignment:
220                   description: 'The accepts_assignment setting for the facility.'
221                   type: string
222                 oid:
223                   description: 'The oid for the facility.'
224                   type: string
225                 service_location:
226                   description: 'The service_location setting for the facility.'
227                   type: string
228               type: object
229               example:
230                 name: Aquaria
231                 facility_npi: '123456789123'
232                 phone: 808-606-3030
233                 fax: 808-606-3031
234                 street: '1337 Bit Shifter Ln'
235                 city: 'San Lorenzo'
236                 state: ZZ
237                 postal_code: '54321'
238                 country_code: US
239                 federal_ein: '4343434'
240                 website: 'https://example.com'
241                 email: foo@bar.com
242                 domain_identifier: ''
243                 facility_taxonomy: ''
244                 facility_code: ''
245                 billing_location: '1'
246                 accepts_assignment: '1'
247                 oid: ''
248                 service_location: '1'
249       responses:
250         '200':
251           $ref: '#/components/responses/standard'
252         '400':
253           $ref: '#/components/responses/badrequest'
254         '401':
255           $ref: '#/components/responses/unauthorized'
256       security:
257         -
258           openemr_auth: []
259   '/api/facility/{fuuid}':
260     get:
261       tags:
262         - standard
263       description: 'Returns a single facility.'
264       parameters:
265         -
266           name: fuuid
267           in: path
268           description: 'The uuid for the facility.'
269           required: true
270           schema:
271             type: string
272       responses:
273         '200':
274           $ref: '#/components/responses/standard'
275         '400':
276           $ref: '#/components/responses/badrequest'
277         '401':
278           $ref: '#/components/responses/unauthorized'
279       security:
280         -
281           openemr_auth: []
282     put:
283       tags:
284         - standard
285       description: 'Updates a facility in the system'
286       parameters:
287         -
288           name: fuuid
289           in: path
290           description: 'The uuid for the facility.'
291           required: true
292           schema:
293             type: string
294       requestBody:
295         required: true
296         content:
297           application/json:
298             schema:
299               properties:
300                 name:
301                   description: 'The name for the facility.'
302                   type: string
303                 facility_npi:
304                   description: 'The facility_npi for the facility.'
305                   type: string
306                 phone:
307                   description: 'The phone for the facility.'
308                   type: string
309                 fax:
310                   description: 'The fax for the facility.'
311                   type: string
312                 street:
313                   description: 'The street for the facility.'
314                   type: string
315                 city:
316                   description: 'The city for the facility.'
317                   type: string
318                 state:
319                   description: 'The state for the facility.'
320                   type: string
321                 postal_code:
322                   description: 'The postal_code for the facility.'
323                   type: string
324                 country_code:
325                   description: 'The country_code for the facility.'
326                   type: string
327                 federal_ein:
328                   description: 'The federal_ein for the facility.'
329                   type: string
330                 website:
331                   description: 'The website for the facility.'
332                   type: string
333                 email:
334                   description: 'The email for the facility.'
335                   type: string
336                 domain_identifier:
337                   description: 'The domain_identifier for the facility.'
338                   type: string
339                 facility_taxonomy:
340                   description: 'The facility_taxonomy for the facility.'
341                   type: string
342                 facility_code:
343                   description: 'The facility_code for the facility.'
344                   type: string
345                 billing_location:
346                   description: 'The billing_location setting for the facility.'
347                   type: string
348                 accepts_assignment:
349                   description: 'The accepts_assignment setting for the facility.'
350                   type: string
351                 oid:
352                   description: 'The oid for the facility.'
353                   type: string
354                 service_location:
355                   description: 'The service_location setting for the facility.'
356                   type: string
357               type: object
358               example:
359                 name: Aquaria
360                 facility_npi: '123456789123'
361                 phone: 808-606-3030
362                 fax: 808-606-3031
363                 street: '1337 Bit Shifter Ln'
364                 city: 'San Lorenzo'
365                 state: ZZ
366                 postal_code: '54321'
367                 country_code: US
368                 federal_ein: '4343434'
369                 website: 'https://example.com'
370                 email: foo@bar.com
371                 domain_identifier: ''
372                 facility_taxonomy: ''
373                 facility_code: ''
374                 billing_location: '1'
375                 accepts_assignment: '1'
376                 oid: ''
377                 service_location: '1'
378       responses:
379         '200':
380           $ref: '#/components/responses/standard'
381         '400':
382           $ref: '#/components/responses/badrequest'
383         '401':
384           $ref: '#/components/responses/unauthorized'
385       security:
386         -
387           openemr_auth: []
388   /api/patient:
389     get:
390       tags:
391         - standard
392       description: 'Retrieves a list of patients'
393       parameters:
394         -
395           $ref: '#/components/parameters/_sort'
396         -
397           name: fname
398           in: query
399           description: 'The first name for the patient.'
400           required: false
401           schema:
402             type: string
403         -
404           name: lname
405           in: query
406           description: 'The last name for the patient.'
407           required: false
408           schema:
409             type: string
410         -
411           name: ss
412           in: query
413           description: 'The social security number for the patient.'
414           required: false
415           schema:
416             type: string
417         -
418           name: street
419           in: query
420           description: 'The street for the patient.'
421           required: false
422           schema:
423             type: string
424         -
425           name: postal_code
426           in: query
427           description: 'The postal code for the patient.'
428           required: false
429           schema:
430             type: string
431         -
432           name: city
433           in: query
434           description: 'The city for the patient.'
435           required: false
436           schema:
437             type: string
438         -
439           name: state
440           in: query
441           description: 'The state for the patient.'
442           required: false
443           schema:
444             type: string
445         -
446           name: phone_home
447           in: query
448           description: 'The home phone for the patient.'
449           required: false
450           schema:
451             type: string
452         -
453           name: phone_biz
454           in: query
455           description: 'The business phone for the patient.'
456           required: false
457           schema:
458             type: string
459         -
460           name: phone_cell
461           in: query
462           description: 'The cell phone for the patient.'
463           required: false
464           schema:
465             type: string
466         -
467           name: postal_contact
468           in: query
469           description: 'The postal_contact for the patient.'
470           required: false
471           schema:
472             type: string
473         -
474           name: sex
475           in: query
476           description: 'The gender for the patient.'
477           required: false
478           schema:
479             type: string
480         -
481           name: country_code
482           in: query
483           description: 'The country code for the patient.'
484           required: false
485           schema:
486             type: string
487         -
488           name: email
489           in: query
490           description: 'The email for the patient.'
491           required: false
492           schema:
493             type: string
494         -
495           name: DOB
496           in: query
497           description: 'The DOB for the patient.'
498           required: false
499           schema:
500             type: string
501         -
502           name: date
503           in: query
504           description: 'The date this patient resource was last modified.'
505           required: false
506           schema:
507             type: string
508         -
509           name: _offset
510           in: query
511           description: 'The number of records to offset from this index in the search result.'
512           required: false
513           schema:
514             type: integer
515         -
516           name: _limit
517           in: query
518           description: 'The maximum number of resources to return in the result set. 0 means unlimited.'
519           required: false
520           schema:
521             type: integer
522             maximum: 200
523             minimum: 0
524       responses:
525         '200':
526           $ref: '#/components/responses/standard'
527         '400':
528           $ref: '#/components/responses/badrequest'
529         '401':
530           $ref: '#/components/responses/unauthorized'
531       security:
532         -
533           openemr_auth: []
534     post:
535       tags:
536         - standard
537       description: 'Creates a new patient'
538       requestBody:
539         required: true
540         content:
541           application/json:
542             schema:
543               $ref: '#/components/schemas/api_patient_request'
544       responses:
545         '200':
546           description: 'Standard response'
547           content:
548             application/json:
549               schema:
550                 properties:
551                   validationErrors: { description: 'Validation errors.', type: array, items: { type: object } }
552                   internalErrors: { description: 'Internal errors.', type: array, items: { type: object } }
553                   data: { description: 'Returned data.', type: array, items: { properties: { pid: { description: 'patient pid', type: integer } }, type: object } }
554                 type: object
555                 example:
556                   validationErrors: []
557                   error_description: []
558                   data: { pid: 1 }
559         '401':
560           $ref: '#/components/responses/unauthorized'
561       security:
562         -
563           openemr_auth: []
564   '/api/patient/{puuid}':
565     get:
566       tags:
567         - standard
568       description: 'Retrieves a single patient by their uuid'
569       parameters:
570         -
571           name: puuid
572           in: path
573           description: 'The uuid for the patient.'
574           required: true
575           schema:
576             type: string
577       responses:
578         '200':
579           description: 'Standard response'
580           content:
581             application/json:
582               schema:
583                 $ref: '#/components/schemas/api_patient_response'
584         '401':
585           $ref: '#/components/responses/unauthorized'
586       security:
587         -
588           openemr_auth: []
589     put:
590       tags:
591         - standard
592       description: 'Updates a patient'
593       parameters:
594         -
595           name: puuid
596           in: path
597           description: 'The uuid for the patient.'
598           required: true
599           schema:
600             type: string
601       requestBody:
602         required: true
603         content:
604           application/json:
605             schema:
606               $ref: '#/components/schemas/api_patient_request'
607       responses:
608         '200':
609           description: 'Standard response'
610           content:
611             application/json:
612               schema:
613                 $ref: '#/components/schemas/api_patient_response'
614         '401':
615           $ref: '#/components/responses/unauthorized'
616       security:
617         -
618           openemr_auth: []
619   '/api/patient/{puuid}/encounter':
620     get:
621       tags:
622         - standard
623       description: 'Retrieves a list of encounters for a single patient'
624       parameters:
625         -
626           name: puuid
627           in: path
628           description: 'The uuid for the patient.'
629           required: true
630           schema:
631             type: string
632       responses:
633         '200':
634           $ref: '#/components/responses/standard'
635         '400':
636           $ref: '#/components/responses/badrequest'
637         '401':
638           $ref: '#/components/responses/unauthorized'
639       security:
640         -
641           openemr_auth: []
642     post:
643       tags:
644         - standard
645       description: 'Creates a new encounter'
646       parameters:
647         -
648           name: puuid
649           in: path
650           description: 'The uuid for the patient.'
651           required: true
652           schema:
653             type: string
654       requestBody:
655         required: true
656         content:
657           application/json:
658             schema:
659               $ref: '#/components/schemas/api_encounter_request'
660       responses:
661         '200':
662           description: 'Standard response'
663           content:
664             application/json:
665               schema:
666                 properties:
667                   validationErrors: { description: 'Validation errors.', type: array, items: { type: object } }
668                   internalErrors: { description: 'Internal errors.', type: array, items: { type: object } }
669                   data: { description: 'Returned data.', type: array, items: { properties: { encounter: { description: 'encounter id', type: integer }, uuid: { description: 'encounter uuid', type: string } }, type: object } }
670                 type: object
671                 example:
672                   validationErrors: []
673                   error_description: []
674                   data: { encounter: 1, uuid: 90c196f2-51cc-4655-8858-3a80aebff3ef }
675         '401':
676           $ref: '#/components/responses/unauthorized'
677       security:
678         -
679           openemr_auth: []
680   '/api/patient/{puuid}/encounter/{euuid}':
681     get:
682       tags:
683         - standard
684       description: 'Retrieves a single encounter for a patient'
685       parameters:
686         -
687           name: puuid
688           in: path
689           description: 'The uuid for the patient.'
690           required: true
691           schema:
692             type: string
693         -
694           name: euuid
695           in: path
696           description: 'The uuid for the encounter.'
697           required: true
698           schema:
699             type: string
700       responses:
701         '200':
702           description: 'Standard response'
703           content:
704             application/json:
705               schema:
706                 $ref: '#/components/schemas/api_encounter_response'
707         '401':
708           $ref: '#/components/responses/unauthorized'
709       security:
710         -
711           openemr_auth: []
712     put:
713       tags:
714         - standard
715       description: 'Modify a encounter'
716       parameters:
717         -
718           name: puuid
719           in: path
720           description: 'The uuid for the patient.'
721           required: true
722           schema:
723             type: string
724         -
725           name: euuid
726           in: path
727           description: 'The uuid for the encounter.'
728           required: true
729           schema:
730             type: string
731       requestBody:
732         required: true
733         content:
734           application/json:
735             schema:
736               $ref: '#/components/schemas/api_encounter_request'
737       responses:
738         '200':
739           description: 'Standard response'
740           content:
741             application/json:
742               schema:
743                 $ref: '#/components/schemas/api_encounter_response'
744         '401':
745           $ref: '#/components/responses/unauthorized'
746       security:
747         -
748           openemr_auth: []
749   '/api/patient/{pid}/encounter/{eid}/soap_note':
750     get:
751       tags:
752         - standard
753       description: 'Retrieves soap notes from an encounter for a patient'
754       parameters:
755         -
756           name: pid
757           in: path
758           description: 'The pid for the patient.'
759           required: true
760           schema:
761             type: string
762         -
763           name: eid
764           in: path
765           description: 'The id for the encounter.'
766           required: true
767           schema:
768             type: string
769       responses:
770         '200':
771           $ref: '#/components/responses/standard'
772         '400':
773           $ref: '#/components/responses/badrequest'
774         '401':
775           $ref: '#/components/responses/unauthorized'
776       security:
777         -
778           openemr_auth: []
779     post:
780       tags:
781         - standard
782       description: 'Submits a new soap note'
783       parameters:
784         -
785           name: pid
786           in: path
787           description: 'The id for the patient.'
788           required: true
789           schema:
790             type: string
791         -
792           name: eid
793           in: path
794           description: 'The id for the encounter.'
795           required: true
796           schema:
797             type: string
798       requestBody:
799         required: true
800         content:
801           application/json:
802             schema:
803               $ref: '#/components/schemas/api_soap_note_request'
804       responses:
805         '200':
806           $ref: '#/components/responses/standard'
807         '400':
808           $ref: '#/components/responses/badrequest'
809         '401':
810           $ref: '#/components/responses/unauthorized'
811       security:
812         -
813           openemr_auth: []
814   '/api/patient/{pid}/encounter/{eid}/vital':
815     get:
816       tags:
817         - standard
818       description: 'Retrieves all vitals from an encounter for a patient'
819       parameters:
820         -
821           name: pid
822           in: path
823           description: 'The pid for the patient.'
824           required: true
825           schema:
826             type: string
827         -
828           name: eid
829           in: path
830           description: 'The id for the encounter.'
831           required: true
832           schema:
833             type: string
834       responses:
835         '200':
836           $ref: '#/components/responses/standard'
837         '400':
838           $ref: '#/components/responses/badrequest'
839         '401':
840           $ref: '#/components/responses/unauthorized'
841       security:
842         -
843           openemr_auth: []
844     post:
845       tags:
846         - standard
847       description: 'Submits a new vitals form'
848       parameters:
849         -
850           name: pid
851           in: path
852           description: 'The id for the patient.'
853           required: true
854           schema:
855             type: string
856         -
857           name: eid
858           in: path
859           description: 'The id for the encounter.'
860           required: true
861           schema:
862             type: string
863       requestBody:
864         required: true
865         content:
866           application/json:
867             schema:
868               $ref: '#/components/schemas/api_vital_request'
869       responses:
870         '200':
871           $ref: '#/components/responses/standard'
872         '400':
873           $ref: '#/components/responses/badrequest'
874         '401':
875           $ref: '#/components/responses/unauthorized'
876       security:
877         -
878           openemr_auth: []
879   '/api/patient/{pid}/encounter/{eid}/vital/{vid}':
880     get:
881       tags:
882         - standard
883       description: 'Retrieves a vitals form from an encounter for a patient'
884       parameters:
885         -
886           name: pid
887           in: path
888           description: 'The pid for the patient.'
889           required: true
890           schema:
891             type: string
892         -
893           name: eid
894           in: path
895           description: 'The id for the encounter.'
896           required: true
897           schema:
898             type: string
899         -
900           name: vid
901           in: path
902           description: 'The id for the vitals form.'
903           required: true
904           schema:
905             type: string
906       responses:
907         '200':
908           $ref: '#/components/responses/standard'
909         '400':
910           $ref: '#/components/responses/badrequest'
911         '401':
912           $ref: '#/components/responses/unauthorized'
913       security:
914         -
915           openemr_auth: []
916     put:
917       tags:
918         - standard
919       description: 'Edit a vitals form'
920       parameters:
921         -
922           name: pid
923           in: path
924           description: 'The id for the patient.'
925           required: true
926           schema:
927             type: string
928         -
929           name: eid
930           in: path
931           description: 'The id for the encounter.'
932           required: true
933           schema:
934             type: string
935         -
936           name: vid
937           in: path
938           description: 'The id for the vitalss form.'
939           required: true
940           schema:
941             type: string
942       requestBody:
943         required: true
944         content:
945           application/json:
946             schema:
947               $ref: '#/components/schemas/api_vital_request'
948       responses:
949         '200':
950           $ref: '#/components/responses/standard'
951         '400':
952           $ref: '#/components/responses/badrequest'
953         '401':
954           $ref: '#/components/responses/unauthorized'
955       security:
956         -
957           openemr_auth: []
958   '/api/patient/{pid}/encounter/{eid}/soap_note/{sid}':
959     get:
960       tags:
961         - standard
962       description: 'Retrieves a soap note from an encounter for a patient'
963       parameters:
964         -
965           name: pid
966           in: path
967           description: 'The pid for the patient.'
968           required: true
969           schema:
970             type: string
971         -
972           name: eid
973           in: path
974           description: 'The id for the encounter.'
975           required: true
976           schema:
977             type: string
978         -
979           name: sid
980           in: path
981           description: 'The id for the soap note.'
982           required: true
983           schema:
984             type: string
985       responses:
986         '200':
987           $ref: '#/components/responses/standard'
988         '400':
989           $ref: '#/components/responses/badrequest'
990         '401':
991           $ref: '#/components/responses/unauthorized'
992       security:
993         -
994           openemr_auth: []
995     put:
996       tags:
997         - standard
998       description: 'Edit a soap note'
999       parameters:
1000         -
1001           name: pid
1002           in: path
1003           description: 'The id for the patient.'
1004           required: true
1005           schema:
1006             type: string
1007         -
1008           name: eid
1009           in: path
1010           description: 'The id for the encounter.'
1011           required: true
1012           schema:
1013             type: string
1014         -
1015           name: sid
1016           in: path
1017           description: 'The id for the soap noted.'
1018           required: true
1019           schema:
1020             type: string
1021       requestBody:
1022         required: true
1023         content:
1024           application/json:
1025             schema:
1026               $ref: '#/components/schemas/api_soap_note_request'
1027       responses:
1028         '200':
1029           $ref: '#/components/responses/standard'
1030         '400':
1031           $ref: '#/components/responses/badrequest'
1032         '401':
1033           $ref: '#/components/responses/unauthorized'
1034       security:
1035         -
1036           openemr_auth: []
1037   /api/practitioner:
1038     get:
1039       tags:
1040         - standard
1041       description: 'Retrieves a list of practitioners'
1042       parameters:
1043         -
1044           name: title
1045           in: query
1046           description: 'The title for the practitioner.'
1047           required: false
1048           schema:
1049             type: string
1050         -
1051           name: fname
1052           in: query
1053           description: 'The first name for the practitioner.'
1054           required: false
1055           schema:
1056             type: string
1057         -
1058           name: lname
1059           in: query
1060           description: 'The last name for the practitioner.'
1061           required: false
1062           schema:
1063             type: string
1064         -
1065           name: mname
1066           in: query
1067           description: 'The middle name for the practitioner.'
1068           required: false
1069           schema:
1070             type: string
1071         -
1072           name: federaltaxid
1073           in: query
1074           description: 'The federal tax id for the practitioner.'
1075           required: false
1076           schema:
1077             type: string
1078         -
1079           name: federaldrugid
1080           in: query
1081           description: 'The federal drug id for the practitioner.'
1082           required: false
1083           schema:
1084             type: string
1085         -
1086           name: upin
1087           in: query
1088           description: 'The upin for the practitioner.'
1089           required: false
1090           schema:
1091             type: string
1092         -
1093           name: facility_id
1094           in: query
1095           description: 'The facility id for the practitioner.'
1096           required: false
1097           schema:
1098             type: string
1099         -
1100           name: facility
1101           in: query
1102           description: 'The facility for the practitioner.'
1103           required: false
1104           schema:
1105             type: string
1106         -
1107           name: npi
1108           in: query
1109           description: 'The npi for the practitioner.'
1110           required: false
1111           schema:
1112             type: string
1113         -
1114           name: email
1115           in: query
1116           description: 'The email for the practitioner.'
1117           required: false
1118           schema:
1119             type: string
1120         -
1121           name: specialty
1122           in: query
1123           description: 'The specialty for the practitioner.'
1124           required: false
1125           schema:
1126             type: string
1127         -
1128           name: billname
1129           in: query
1130           description: 'The billname for the practitioner.'
1131           required: false
1132           schema:
1133             type: string
1134         -
1135           name: url
1136           in: query
1137           description: 'The url for the practitioner.'
1138           required: false
1139           schema:
1140             type: string
1141         -
1142           name: assistant
1143           in: query
1144           description: 'The assistant for the practitioner.'
1145           required: false
1146           schema:
1147             type: string
1148         -
1149           name: organization
1150           in: query
1151           description: 'The organization for the practitioner.'
1152           required: false
1153           schema:
1154             type: string
1155         -
1156           name: valedictory
1157           in: query
1158           description: 'The valedictory for the practitioner.'
1159           required: false
1160           schema:
1161             type: string
1162         -
1163           name: street
1164           in: query
1165           description: 'The street for the practitioner.'
1166           required: false
1167           schema:
1168             type: string
1169         -
1170           name: streetb
1171           in: query
1172           description: 'The street (line 2) for the practitioner.'
1173           required: false
1174           schema:
1175             type: string
1176         -
1177           name: city
1178           in: query
1179           description: 'The city for the practitioner.'
1180           required: false
1181           schema:
1182             type: string
1183         -
1184           name: state
1185           in: query
1186           description: 'The state for the practitioner.'
1187           required: false
1188           schema:
1189             type: string
1190         -
1191           name: zip
1192           in: query
1193           description: 'The zip for the practitioner.'
1194           required: false
1195           schema:
1196             type: string
1197         -
1198           name: phone
1199           in: query
1200           description: 'The phone for the practitioner.'
1201           required: false
1202           schema:
1203             type: string
1204         -
1205           name: fax
1206           in: query
1207           description: 'The fax for the practitioner.'
1208           required: false
1209           schema:
1210             type: string
1211         -
1212           name: phonew1
1213           in: query
1214           description: 'The phonew1 for the practitioner.'
1215           required: false
1216           schema:
1217             type: string
1218         -
1219           name: phonecell
1220           in: query
1221           description: 'The phonecell for the practitioner.'
1222           required: false
1223           schema:
1224             type: string
1225         -
1226           name: notes
1227           in: query
1228           description: 'The notes for the practitioner.'
1229           required: false
1230           schema:
1231             type: string
1232         -
1233           name: state_license_number2
1234           in: query
1235           description: 'The state license number for the practitioner.'
1236           required: false
1237           schema:
1238             type: string
1239         -
1240           name: username
1241           in: query
1242           description: 'The username for the practitioner.'
1243           required: false
1244           schema:
1245             type: string
1246       responses:
1247         '200':
1248           $ref: '#/components/responses/standard'
1249         '400':
1250           $ref: '#/components/responses/badrequest'
1251         '401':
1252           $ref: '#/components/responses/unauthorized'
1253       security:
1254         -
1255           openemr_auth: []
1256     post:
1257       tags:
1258         - standard
1259       description: 'Submits a new practitioner'
1260       requestBody:
1261         required: true
1262         content:
1263           application/json:
1264             schema:
1265               required:
1266                 - fname
1267                 - lname
1268                 - npi
1269               properties:
1270                 title:
1271                   description: 'The title for the practitioner.'
1272                   type: string
1273                 fname:
1274                   description: 'The first name for the practitioner.'
1275                   type: string
1276                 mname:
1277                   description: 'The middle name for the practitioner.'
1278                   type: string
1279                 lname:
1280                   description: 'The last name for the practitioner.'
1281                   type: string
1282                 federaltaxid:
1283                   description: 'The federal tax id for the practitioner.'
1284                   type: string
1285                 federaldrugid:
1286                   description: 'The federal drug id for the practitioner.'
1287                   type: string
1288                 upin:
1289                   description: 'The upin for the practitioner.'
1290                   type: string
1291                 facility_id:
1292                   description: 'The facility_id for the practitioner.'
1293                   type: string
1294                 facility:
1295                   description: 'The facility name for the practitioner.'
1296                   type: string
1297                 npi:
1298                   description: 'The npi for the practitioner.'
1299                   type: string
1300                 email:
1301                   description: 'The email for the practitioner.'
1302                   type: string
1303                 specialty:
1304                   description: 'The specialty for the practitioner.'
1305                   type: string
1306                 billname:
1307                   description: 'The billname for the practitioner.'
1308                   type: string
1309                 url:
1310                   description: 'The url for the practitioner.'
1311                   type: string
1312                 assistant:
1313                   description: 'The assistant for the practitioner.'
1314                   type: string
1315                 valedictory:
1316                   description: 'The valedictory for the practitioner.'
1317                   type: string
1318                 street:
1319                   description: 'The street address for the practitioner.'
1320                   type: string
1321                 streetb:
1322                   description: 'The streetb address for the practitioner.'
1323                   type: string
1324                 city:
1325                   description: 'The city for the practitioner.'
1326                   type: string
1327                 state:
1328                   description: 'The state for the practitioner.'
1329                   type: string
1330                 zip:
1331                   description: 'The zip for the practitioner.'
1332                   type: string
1333                 phone:
1334                   description: 'The phone for the practitioner.'
1335                   type: string
1336                 fax:
1337                   description: 'The fax for the practitioner.'
1338                   type: string
1339                 phonew1:
1340                   description: 'The phonew1 for the practitioner.'
1341                   type: string
1342                 phonecell:
1343                   description: 'The phonecell for the practitioner.'
1344                   type: string
1345                 notes:
1346                   description: 'The notes for the practitioner.'
1347                   type: string
1348                 state_license_number:
1349                   description: 'The state license number for the practitioner.'
1350                   type: string
1351                 username:
1352                   description: 'The username for the practitioner.'
1353                   type: string
1354               type: object
1355               example:
1356                 title: Mrs.
1357                 fname: Eduardo
1358                 mname: Kathy
1359                 lname: Perez
1360                 federaltaxid: ''
1361                 federaldrugid: ''
1362                 upin: ''
1363                 facility_id: '3'
1364                 facility: 'Your Clinic Name Here'
1365                 npi: '12345678901'
1366                 email: info@pennfirm.com
1367                 specialty: ''
1368                 billname: null
1369                 url: null
1370                 assistant: null
1371                 organization: null
1372                 valedictory: null
1373                 street: '789 Third Avenue'
1374                 streetb: '123 Cannaut Street'
1375                 city: 'San Diego'
1376                 state: CA
1377                 zip: '90210'
1378                 phone: '(619) 555-9827'
1379                 fax: null
1380                 phonew1: '(619) 555-7822'
1381                 phonecell: '(619) 555-7821'
1382                 notes: null
1383                 state_license_number: '123456'
1384                 username: eduardoperez
1385       responses:
1386         '200':
1387           description: 'Standard response'
1388           content:
1389             application/json:
1390               schema:
1391                 properties:
1392                   validationErrors: { description: 'Validation errors.', type: array, items: { type: object } }
1393                   internalErrors: { description: 'Internal errors.', type: array, items: { type: object } }
1394                   data: { description: 'Returned data.', type: array, items: { properties: { id: { description: 'practitioner id', type: integer }, uuid: { description: 'practitioner uuid', type: string } }, type: object } }
1395                 type: object
1396                 example:
1397                   validationErrors: []
1398                   error_description: []
1399                   data: { id: 7, uuid: 90d453fb-0248-4c0d-9575-d99d02b169f5 }
1400         '401':
1401           $ref: '#/components/responses/unauthorized'
1402       security:
1403         -
1404           openemr_auth: []
1405   '/api/practitioner/{pruuid}':
1406     get:
1407       tags:
1408         - standard
1409       description: 'Retrieves a single practitioner by their uuid'
1410       parameters:
1411         -
1412           name: pruuid
1413           in: path
1414           description: 'The uuid for the practitioner.'
1415           required: true
1416           schema:
1417             type: string
1418       responses:
1419         '200':
1420           $ref: '#/components/responses/standard'
1421         '400':
1422           $ref: '#/components/responses/badrequest'
1423         '401':
1424           $ref: '#/components/responses/unauthorized'
1425       security:
1426         -
1427           openemr_auth: []
1428     put:
1429       tags:
1430         - standard
1431       description: 'Edit a practitioner'
1432       parameters:
1433         -
1434           name: pruuid
1435           in: path
1436           description: 'The uuid for the practitioner.'
1437           required: true
1438           schema:
1439             type: string
1440       requestBody:
1441         required: true
1442         content:
1443           application/json:
1444             schema:
1445               properties:
1446                 title:
1447                   description: 'The title for the practitioner.'
1448                   type: string
1449                 fname:
1450                   description: 'The first name for the practitioner.'
1451                   type: string
1452                 mname:
1453                   description: 'The middle name for the practitioner.'
1454                   type: string
1455                 lname:
1456                   description: 'The last name for the practitioner.'
1457                   type: string
1458                 federaltaxid:
1459                   description: 'The federal tax id for the practitioner.'
1460                   type: string
1461                 federaldrugid:
1462                   description: 'The federal drug id for the practitioner.'
1463                   type: string
1464                 upin:
1465                   description: 'The upin for the practitioner.'
1466                   type: string
1467                 facility_id:
1468                   description: 'The facility_id for the practitioner.'
1469                   type: string
1470                 facility:
1471                   description: 'The facility name for the practitioner.'
1472                   type: string
1473                 npi:
1474                   description: 'The npi for the practitioner.'
1475                   type: string
1476                 email:
1477                   description: 'The email for the practitioner.'
1478                   type: string
1479                 specialty:
1480                   description: 'The specialty for the practitioner.'
1481                   type: string
1482                 billname:
1483                   description: 'The billname for the practitioner.'
1484                   type: string
1485                 url:
1486                   description: 'The url for the practitioner.'
1487                   type: string
1488                 assistant:
1489                   description: 'The assistant for the practitioner.'
1490                   type: string
1491                 valedictory:
1492                   description: 'The valedictory for the practitioner.'
1493                   type: string
1494                 street:
1495                   description: 'The street address for the practitioner.'
1496                   type: string
1497                 streetb:
1498                   description: 'The streetb address for the practitioner.'
1499                   type: string
1500                 city:
1501                   description: 'The city for the practitioner.'
1502                   type: string
1503                 state:
1504                   description: 'The state for the practitioner.'
1505                   type: string
1506                 zip:
1507                   description: 'The zip for the practitioner.'
1508                   type: string
1509                 phone:
1510                   description: 'The phone for the practitioner.'
1511                   type: string
1512                 fax:
1513                   description: 'The fax for the practitioner.'
1514                   type: string
1515                 phonew1:
1516                   description: 'The phonew1 for the practitioner.'
1517                   type: string
1518                 phonecell:
1519                   description: 'The phonecell for the practitioner.'
1520                   type: string
1521                 notes:
1522                   description: 'The notes for the practitioner.'
1523                   type: string
1524                 state_license_number:
1525                   description: 'The state license number for the practitioner.'
1526                   type: string
1527                 username:
1528                   description: 'The username for the practitioner.'
1529                   type: string
1530               type: object
1531               example:
1532                 title: Mr
1533                 fname: Baz
1534                 mname: ''
1535                 lname: Bop
1536                 street: '456 Tree Lane'
1537                 zip: '08642'
1538                 city: FooTown
1539                 state: FL
1540                 phone: 123-456-7890
1541       responses:
1542         '200':
1543           description: 'Standard response'
1544           content:
1545             application/json:
1546               schema:
1547                 properties:
1548                   validationErrors: { description: 'Validation errors.', type: array, items: { type: object } }
1549                   internalErrors: { description: 'Internal errors.', type: array, items: { type: object } }
1550                   data: { description: 'Returned data.', type: array, items: { properties: { id: { description: 'practitioner id', type: string }, uuid: { description: 'practitioner uuid', type: string }, title: { description: 'practitioner title', type: string }, fname: { description: 'practitioner fname', type: string }, lname: { description: 'practitioner lname', type: string }, mname: { description: 'practitioner mname', type: string }, federaltaxid: { description: 'practitioner federaltaxid', type: string }, federaldrugid: { description: 'practitioner federaldrugid', type: string }, upin: { description: 'practitioner upin', type: string }, facility_id: { description: 'practitioner facility_id', type: string }, facility: { description: 'practitioner facility', type: string }, npi: { description: 'practitioner npi', type: string }, email: { description: 'practitioner email', type: string }, active: { description: 'practitioner active setting', type: string }, specialty: { description: 'practitioner specialty', type: string }, billname: { description: 'practitioner billname', type: string }, url: { description: 'practitioner url', type: string }, assistant: { description: 'practitioner assistant', type: string }, organization: { description: 'practitioner organization', type: string }, valedictory: { description: 'practitioner valedictory', type: string }, street: { description: 'practitioner street', type: string }, streetb: { description: 'practitioner streetb', type: string }, city: { description: 'practitioner city', type: string }, state: { description: 'practitioner state', type: string }, zip: { description: 'practitioner zip', type: string }, phone: { description: 'practitioner phone', type: string }, fax: { description: fax, type: string }, phonew1: { description: 'practitioner phonew1', type: string }, phonecell: { description: 'practitioner phonecell', type: string }, notes: { description: 'practitioner notes', type: string }, state_license_number: { description: 'practitioner state license number', type: string }, abook_title: { description: 'practitioner abook title', type: string }, physician_title: { description: 'practitioner physician title', type: string }, physician_code: { description: 'practitioner physician code', type: string } }, type: object } }
1551                 type: object
1552                 example:
1553                   validationErrors: []
1554                   error_description: []
1555                   data: { id: 7, uuid: 90d453fb-0248-4c0d-9575-d99d02b169f5, title: Mr, fname: Baz, lname: Bop, mname: '', federaltaxid: '', federaldrugid: '', upin: '', facility_id: '3', facility: 'Your Clinic Name Here', npi: '0123456789', email: info@pennfirm.com, active: '1', specialty: '', billname: '', url: '', assistant: '', organization: '', valedictory: '', street: '456 Tree Lane', streetb: '123 Cannaut Street', city: FooTown, state: FL, zip: '08642', phone: 123-456-7890, fax: '', phonew1: '(619) 555-7822', phonecell: '(619) 555-7821', notes: '', state_license_number: '123456', abook_title: null, physician_title: null, physician_code: null }
1556         '401':
1557           $ref: '#/components/responses/unauthorized'
1558       security:
1559         -
1560           openemr_auth: []
1561   /api/medical_problem:
1562     get:
1563       tags:
1564         - standard
1565       description: 'Retrieves a list of medical problems'
1566       parameters:
1567         -
1568           name: puuid
1569           in: query
1570           description: 'The uuid for the patient.'
1571           required: false
1572           schema:
1573             type: string
1574         -
1575           name: condition_uuid
1576           in: query
1577           description: 'The uuid for the medical problem.'
1578           required: false
1579           schema:
1580             type: string
1581         -
1582           name: title
1583           in: query
1584           description: 'The title for the medical problem.'
1585           required: false
1586           schema:
1587             type: string
1588         -
1589           name: begdate
1590           in: query
1591           description: 'The start date for the medical problem.'
1592           required: false
1593           schema:
1594             type: string
1595         -
1596           name: enddate
1597           in: query
1598           description: 'The end date for the medical problem.'
1599           required: false
1600           schema:
1601             type: string
1602         -
1603           name: diagnosis
1604           in: query
1605           description: 'The diagnosis for the medical problem.'
1606           required: false
1607           schema:
1608             type: string
1609       responses:
1610         '200':
1611           $ref: '#/components/responses/standard'
1612         '400':
1613           $ref: '#/components/responses/badrequest'
1614         '401':
1615           $ref: '#/components/responses/unauthorized'
1616       security:
1617         -
1618           openemr_auth: []
1619   '/api/medical_problem/{muuid}':
1620     get:
1621       tags:
1622         - standard
1623       description: 'Retrieves a single medical problem by their uuid'
1624       parameters:
1625         -
1626           name: muuid
1627           in: path
1628           description: 'The uuid for the medical problem.'
1629           required: true
1630           schema:
1631             type: string
1632       responses:
1633         '200':
1634           $ref: '#/components/responses/standard'
1635         '400':
1636           $ref: '#/components/responses/badrequest'
1637         '401':
1638           $ref: '#/components/responses/unauthorized'
1639       security:
1640         -
1641           openemr_auth: []
1642   '/api/patient/{puuid}/medical_problem':
1643     get:
1644       tags:
1645         - standard
1646       description: 'Retrieves all medical problems for a patient'
1647       parameters:
1648         -
1649           name: puuid
1650           in: path
1651           description: 'The uuid for the patient.'
1652           required: true
1653           schema:
1654             type: string
1655       responses:
1656         '200':
1657           $ref: '#/components/responses/standard'
1658         '400':
1659           $ref: '#/components/responses/badrequest'
1660         '401':
1661           $ref: '#/components/responses/unauthorized'
1662       security:
1663         -
1664           openemr_auth: []
1665     post:
1666       tags:
1667         - standard
1668       description: 'Submits a new medical problem'
1669       parameters:
1670         -
1671           name: puuid
1672           in: path
1673           description: 'The uuid for the patient.'
1674           required: true
1675           schema:
1676             type: string
1677       requestBody:
1678         required: true
1679         content:
1680           application/json:
1681             schema:
1682               $ref: '#/components/schemas/api_medical_problem_request'
1683       responses:
1684         '200':
1685           $ref: '#/components/responses/standard'
1686         '400':
1687           $ref: '#/components/responses/badrequest'
1688         '401':
1689           $ref: '#/components/responses/unauthorized'
1690       security:
1691         -
1692           openemr_auth: []
1693   '/api/patient/{puuid}/medical_problem/{muuid}':
1694     get:
1695       tags:
1696         - standard
1697       description: 'Retrieves a medical problem for a patient'
1698       parameters:
1699         -
1700           name: puuid
1701           in: path
1702           description: 'The uuid for the patient.'
1703           required: true
1704           schema:
1705             type: string
1706         -
1707           name: muuid
1708           in: path
1709           description: 'The uuid for the medical problem.'
1710           required: true
1711           schema:
1712             type: string
1713       responses:
1714         '200':
1715           $ref: '#/components/responses/standard'
1716         '400':
1717           $ref: '#/components/responses/badrequest'
1718         '401':
1719           $ref: '#/components/responses/unauthorized'
1720       security:
1721         -
1722           openemr_auth: []
1723     put:
1724       tags:
1725         - standard
1726       description: 'Edit a medical problem'
1727       parameters:
1728         -
1729           name: puuid
1730           in: path
1731           description: 'The uuid for the patient.'
1732           required: true
1733           schema:
1734             type: string
1735         -
1736           name: muuid
1737           in: path
1738           description: 'The uuid for the medical problem.'
1739           required: true
1740           schema:
1741             type: string
1742       requestBody:
1743         required: true
1744         content:
1745           application/json:
1746             schema:
1747               $ref: '#/components/schemas/api_medical_problem_request'
1748       responses:
1749         '200':
1750           $ref: '#/components/responses/standard'
1751         '400':
1752           $ref: '#/components/responses/badrequest'
1753         '401':
1754           $ref: '#/components/responses/unauthorized'
1755       security:
1756         -
1757           openemr_auth: []
1758     delete:
1759       tags:
1760         - standard
1761       description: 'Delete a medical problem'
1762       parameters:
1763         -
1764           name: puuid
1765           in: path
1766           description: 'The uuid for the patient.'
1767           required: true
1768           schema:
1769             type: string
1770         -
1771           name: muuid
1772           in: path
1773           description: 'The uuid for the medical problem.'
1774           required: true
1775           schema:
1776             type: string
1777       responses:
1778         '200':
1779           $ref: '#/components/responses/standard'
1780         '400':
1781           $ref: '#/components/responses/badrequest'
1782         '401':
1783           $ref: '#/components/responses/unauthorized'
1784       security:
1785         -
1786           openemr_auth: []
1787   /api/allergy:
1788     get:
1789       tags:
1790         - standard
1791       description: 'Retrieves a list of allergies'
1792       parameters:
1793         -
1794           name: lists.pid
1795           in: query
1796           description: 'The uuid for the patient.'
1797           required: false
1798           schema:
1799             type: string
1800         -
1801           name: lists.id
1802           in: query
1803           description: 'The uuid for the allergy.'
1804           required: false
1805           schema:
1806             type: string
1807         -
1808           name: title
1809           in: query
1810           description: 'The title for the allergy.'
1811           required: false
1812           schema:
1813             type: string
1814         -
1815           name: begdate
1816           in: query
1817           description: 'The start date for the allergy.'
1818           required: false
1819           schema:
1820             type: string
1821         -
1822           name: enddate
1823           in: query
1824           description: 'The end date for the allergy.'
1825           required: false
1826           schema:
1827             type: string
1828         -
1829           name: diagnosis
1830           in: query
1831           description: 'The diagnosis for the allergy.'
1832           required: false
1833           schema:
1834             type: string
1835       responses:
1836         '200':
1837           $ref: '#/components/responses/standard'
1838         '400':
1839           $ref: '#/components/responses/badrequest'
1840         '401':
1841           $ref: '#/components/responses/unauthorized'
1842       security:
1843         -
1844           openemr_auth: []
1845   '/api/allergy/{auuid}':
1846     get:
1847       tags:
1848         - standard
1849       description: 'Retrieves a single allergy by their uuid'
1850       parameters:
1851         -
1852           name: auuid
1853           in: path
1854           description: 'The uuid for the allergy.'
1855           required: true
1856           schema:
1857             type: string
1858       responses:
1859         '200':
1860           $ref: '#/components/responses/standard'
1861         '400':
1862           $ref: '#/components/responses/badrequest'
1863         '401':
1864           $ref: '#/components/responses/unauthorized'
1865       security:
1866         -
1867           openemr_auth: []
1868   '/api/patient/{puuid}/allergy':
1869     get:
1870       tags:
1871         - standard
1872       description: 'Retrieves all allergies for a patient'
1873       parameters:
1874         -
1875           name: puuid
1876           in: path
1877           description: 'The uuid for the patient.'
1878           required: true
1879           schema:
1880             type: string
1881       responses:
1882         '200':
1883           $ref: '#/components/responses/standard'
1884         '400':
1885           $ref: '#/components/responses/badrequest'
1886         '401':
1887           $ref: '#/components/responses/unauthorized'
1888       security:
1889         -
1890           openemr_auth: []
1891     post:
1892       tags:
1893         - standard
1894       description: 'Submits a new allergy'
1895       parameters:
1896         -
1897           name: puuid
1898           in: path
1899           description: 'The uuid for the patient.'
1900           required: true
1901           schema:
1902             type: string
1903       requestBody:
1904         required: true
1905         content:
1906           application/json:
1907             schema:
1908               $ref: '#/components/schemas/api_allergy_request'
1909       responses:
1910         '200':
1911           $ref: '#/components/responses/standard'
1912         '400':
1913           $ref: '#/components/responses/badrequest'
1914         '401':
1915           $ref: '#/components/responses/unauthorized'
1916       security:
1917         -
1918           openemr_auth: []
1919   '/api/patient/{puuid}/allergy/{auuid}':
1920     get:
1921       tags:
1922         - standard
1923       description: 'Retrieves a allergy for a patient'
1924       parameters:
1925         -
1926           name: puuid
1927           in: path
1928           description: 'The uuid for the patient.'
1929           required: true
1930           schema:
1931             type: string
1932         -
1933           name: auuid
1934           in: path
1935           description: 'The uuid for the allergy.'
1936           required: true
1937           schema:
1938             type: string
1939       responses:
1940         '200':
1941           $ref: '#/components/responses/standard'
1942         '400':
1943           $ref: '#/components/responses/badrequest'
1944         '401':
1945           $ref: '#/components/responses/unauthorized'
1946       security:
1947         -
1948           openemr_auth: []
1949     put:
1950       tags:
1951         - standard
1952       description: 'Edit a allergy'
1953       parameters:
1954         -
1955           name: puuid
1956           in: path
1957           description: 'The uuid for the patient.'
1958           required: true
1959           schema:
1960             type: string
1961         -
1962           name: auuid
1963           in: path
1964           description: 'The uuid for the allergy.'
1965           required: true
1966           schema:
1967             type: string
1968       requestBody:
1969         required: true
1970         content:
1971           application/json:
1972             schema:
1973               $ref: '#/components/schemas/api_allergy_request'
1974       responses:
1975         '200':
1976           $ref: '#/components/responses/standard'
1977         '400':
1978           $ref: '#/components/responses/badrequest'
1979         '401':
1980           $ref: '#/components/responses/unauthorized'
1981       security:
1982         -
1983           openemr_auth: []
1984     delete:
1985       tags:
1986         - standard
1987       description: 'Delete a medical problem'
1988       parameters:
1989         -
1990           name: puuid
1991           in: path
1992           description: 'The uuid for the patient.'
1993           required: true
1994           schema:
1995             type: string
1996         -
1997           name: auuid
1998           in: path
1999           description: 'The uuid for the allergy.'
2000           required: true
2001           schema:
2002             type: string
2003       responses:
2004         '200':
2005           $ref: '#/components/responses/standard'
2006         '400':
2007           $ref: '#/components/responses/badrequest'
2008         '401':
2009           $ref: '#/components/responses/unauthorized'
2010       security:
2011         -
2012           openemr_auth: []
2013   '/api/patient/{pid}/medication':
2014     get:
2015       tags:
2016         - standard
2017       description: 'Retrieves all medications for a patient'
2018       parameters:
2019         -
2020           name: pid
2021           in: path
2022           description: 'The pid for the patient.'
2023           required: true
2024           schema:
2025             type: string
2026       responses:
2027         '200':
2028           $ref: '#/components/responses/standard'
2029         '400':
2030           $ref: '#/components/responses/badrequest'
2031         '401':
2032           $ref: '#/components/responses/unauthorized'
2033       security:
2034         -
2035           openemr_auth: []
2036     post:
2037       tags:
2038         - standard
2039       description: 'Submits a new medication'
2040       parameters:
2041         -
2042           name: pid
2043           in: path
2044           description: 'The pid for the patient.'
2045           required: true
2046           schema:
2047             type: string
2048       requestBody:
2049         required: true
2050         content:
2051           application/json:
2052             schema:
2053               $ref: '#/components/schemas/api_medication_request'
2054       responses:
2055         '200':
2056           $ref: '#/components/responses/standard'
2057         '400':
2058           $ref: '#/components/responses/badrequest'
2059         '401':
2060           $ref: '#/components/responses/unauthorized'
2061       security:
2062         -
2063           openemr_auth: []
2064   '/api/patient/{pid}/medication/{mid}':
2065     get:
2066       tags:
2067         - standard
2068       description: 'Retrieves a medication for a patient'
2069       parameters:
2070         -
2071           name: pid
2072           in: path
2073           description: 'The id for the patient.'
2074           required: true
2075           schema:
2076             type: string
2077         -
2078           name: mid
2079           in: path
2080           description: 'The id for the medication.'
2081           required: true
2082           schema:
2083             type: string
2084       responses:
2085         '200':
2086           $ref: '#/components/responses/standard'
2087         '400':
2088           $ref: '#/components/responses/badrequest'
2089         '401':
2090           $ref: '#/components/responses/unauthorized'
2091       security:
2092         -
2093           openemr_auth: []
2094     put:
2095       tags:
2096         - standard
2097       description: 'Edit a medication'
2098       parameters:
2099         -
2100           name: pid
2101           in: path
2102           description: 'The pid for the patient.'
2103           required: true
2104           schema:
2105             type: string
2106         -
2107           name: mid
2108           in: path
2109           description: 'The id for the medication.'
2110           required: true
2111           schema:
2112             type: string
2113       requestBody:
2114         required: true
2115         content:
2116           application/json:
2117             schema:
2118               $ref: '#/components/schemas/api_medication_request'
2119       responses:
2120         '200':
2121           $ref: '#/components/responses/standard'
2122         '400':
2123           $ref: '#/components/responses/badrequest'
2124         '401':
2125           $ref: '#/components/responses/unauthorized'
2126       security:
2127         -
2128           openemr_auth: []
2129     delete:
2130       tags:
2131         - standard
2132       description: 'Delete a medication'
2133       parameters:
2134         -
2135           name: pid
2136           in: path
2137           description: 'The id for the patient.'
2138           required: true
2139           schema:
2140             type: string
2141         -
2142           name: mid
2143           in: path
2144           description: 'The id for the medication.'
2145           required: true
2146           schema:
2147             type: string
2148       responses:
2149         '200':
2150           $ref: '#/components/responses/standard'
2151         '400':
2152           $ref: '#/components/responses/badrequest'
2153         '401':
2154           $ref: '#/components/responses/unauthorized'
2155       security:
2156         -
2157           openemr_auth: []
2158   '/api/patient/{pid}/surgery':
2159     get:
2160       tags:
2161         - standard
2162       description: 'Retrieves all surgeries for a patient'
2163       parameters:
2164         -
2165           name: pid
2166           in: path
2167           description: 'The pid for the patient.'
2168           required: true
2169           schema:
2170             type: string
2171       responses:
2172         '200':
2173           $ref: '#/components/responses/standard'
2174         '400':
2175           $ref: '#/components/responses/badrequest'
2176         '401':
2177           $ref: '#/components/responses/unauthorized'
2178       security:
2179         -
2180           openemr_auth: []
2181     post:
2182       tags:
2183         - standard
2184       description: 'Submits a new surgery'
2185       parameters:
2186         -
2187           name: pid
2188           in: path
2189           description: 'The pid for the patient.'
2190           required: true
2191           schema:
2192             type: string
2193       requestBody:
2194         required: true
2195         content:
2196           application/json:
2197             schema:
2198               $ref: '#/components/schemas/api_surgery_request'
2199       responses:
2200         '200':
2201           $ref: '#/components/responses/standard'
2202         '400':
2203           $ref: '#/components/responses/badrequest'
2204         '401':
2205           $ref: '#/components/responses/unauthorized'
2206       security:
2207         -
2208           openemr_auth: []
2209   '/api/patient/{pid}/surgery/{sid}':
2210     get:
2211       tags:
2212         - standard
2213       description: 'Retrieves a surgery for a patient'
2214       parameters:
2215         -
2216           name: pid
2217           in: path
2218           description: 'The id for the patient.'
2219           required: true
2220           schema:
2221             type: string
2222         -
2223           name: sid
2224           in: path
2225           description: 'The id for the surgery.'
2226           required: true
2227           schema:
2228             type: string
2229       responses:
2230         '200':
2231           $ref: '#/components/responses/standard'
2232         '400':
2233           $ref: '#/components/responses/badrequest'
2234         '401':
2235           $ref: '#/components/responses/unauthorized'
2236       security:
2237         -
2238           openemr_auth: []
2239     put:
2240       tags:
2241         - standard
2242       description: 'Edit a surgery'
2243       parameters:
2244         -
2245           name: pid
2246           in: path
2247           description: 'The pid for the patient.'
2248           required: true
2249           schema:
2250             type: string
2251         -
2252           name: sid
2253           in: path
2254           description: 'The id for the surgery.'
2255           required: true
2256           schema:
2257             type: string
2258       requestBody:
2259         required: true
2260         content:
2261           application/json:
2262             schema:
2263               $ref: '#/components/schemas/api_surgery_request'
2264       responses:
2265         '200':
2266           $ref: '#/components/responses/standard'
2267         '400':
2268           $ref: '#/components/responses/badrequest'
2269         '401':
2270           $ref: '#/components/responses/unauthorized'
2271       security:
2272         -
2273           openemr_auth: []
2274     delete:
2275       tags:
2276         - standard
2277       description: 'Delete a surgery'
2278       parameters:
2279         -
2280           name: pid
2281           in: path
2282           description: 'The id for the patient.'
2283           required: true
2284           schema:
2285             type: string
2286         -
2287           name: sid
2288           in: path
2289           description: 'The id for the surgery.'
2290           required: true
2291           schema:
2292             type: string
2293       responses:
2294         '200':
2295           $ref: '#/components/responses/standard'
2296         '400':
2297           $ref: '#/components/responses/badrequest'
2298         '401':
2299           $ref: '#/components/responses/unauthorized'
2300       security:
2301         -
2302           openemr_auth: []
2303   '/api/patient/{pid}/dental_issue':
2304     get:
2305       tags:
2306         - standard
2307       description: 'Retrieves all dental issues for a patient'
2308       parameters:
2309         -
2310           name: pid
2311           in: path
2312           description: 'The pid for the patient.'
2313           required: true
2314           schema:
2315             type: string
2316       responses:
2317         '200':
2318           $ref: '#/components/responses/standard'
2319         '400':
2320           $ref: '#/components/responses/badrequest'
2321         '401':
2322           $ref: '#/components/responses/unauthorized'
2323       security:
2324         -
2325           openemr_auth: []
2326     post:
2327       tags:
2328         - standard
2329       description: 'Submits a new dental issue'
2330       parameters:
2331         -
2332           name: pid
2333           in: path
2334           description: 'The pid for the patient.'
2335           required: true
2336           schema:
2337             type: string
2338       requestBody:
2339         required: true
2340         content:
2341           application/json:
2342             schema:
2343               $ref: '#/components/schemas/api_dental_issue_request'
2344       responses:
2345         '200':
2346           $ref: '#/components/responses/standard'
2347         '400':
2348           $ref: '#/components/responses/badrequest'
2349         '401':
2350           $ref: '#/components/responses/unauthorized'
2351       security:
2352         -
2353           openemr_auth: []
2354   '/api/patient/{pid}/dental_issue/{did}':
2355     get:
2356       tags:
2357         - standard
2358       description: 'Retrieves a dental issue for a patient'
2359       parameters:
2360         -
2361           name: pid
2362           in: path
2363           description: 'The id for the patient.'
2364           required: true
2365           schema:
2366             type: string
2367         -
2368           name: did
2369           in: path
2370           description: 'The id for the dental issue.'
2371           required: true
2372           schema:
2373             type: string
2374       responses:
2375         '200':
2376           $ref: '#/components/responses/standard'
2377         '400':
2378           $ref: '#/components/responses/badrequest'
2379         '401':
2380           $ref: '#/components/responses/unauthorized'
2381       security:
2382         -
2383           openemr_auth: []
2384     put:
2385       tags:
2386         - standard
2387       description: 'Edit a dental issue'
2388       parameters:
2389         -
2390           name: pid
2391           in: path
2392           description: 'The pid for the patient.'
2393           required: true
2394           schema:
2395             type: string
2396         -
2397           name: did
2398           in: path
2399           description: 'The id for the dental issue.'
2400           required: true
2401           schema:
2402             type: string
2403       requestBody:
2404         required: true
2405         content:
2406           application/json:
2407             schema:
2408               $ref: '#/components/schemas/api_dental_issue_request'
2409       responses:
2410         '200':
2411           $ref: '#/components/responses/standard'
2412         '400':
2413           $ref: '#/components/responses/badrequest'
2414         '401':
2415           $ref: '#/components/responses/unauthorized'
2416       security:
2417         -
2418           openemr_auth: []
2419     delete:
2420       tags:
2421         - standard
2422       description: 'Delete a dental issue'
2423       parameters:
2424         -
2425           name: pid
2426           in: path
2427           description: 'The id for the patient.'
2428           required: true
2429           schema:
2430             type: string
2431         -
2432           name: did
2433           in: path
2434           description: 'The id for the dental issue.'
2435           required: true
2436           schema:
2437             type: string
2438       responses:
2439         '200':
2440           $ref: '#/components/responses/standard'
2441         '400':
2442           $ref: '#/components/responses/badrequest'
2443         '401':
2444           $ref: '#/components/responses/unauthorized'
2445       security:
2446         -
2447           openemr_auth: []
2448   '/api/patient/{pid}/appointment':
2449     get:
2450       tags:
2451         - standard
2452       description: 'Retrieves all appointments for a patient'
2453       parameters:
2454         -
2455           name: pid
2456           in: path
2457           description: 'The pid for the patient.'
2458           required: true
2459           schema:
2460             type: string
2461       responses:
2462         '200':
2463           $ref: '#/components/responses/standard'
2464         '400':
2465           $ref: '#/components/responses/badrequest'
2466         '401':
2467           $ref: '#/components/responses/unauthorized'
2468       security:
2469         -
2470           openemr_auth: []
2471     post:
2472       tags:
2473         - standard
2474       description: 'Submits a new appointment'
2475       parameters:
2476         -
2477           name: pid
2478           in: path
2479           description: 'The id for the patient.'
2480           required: true
2481           schema:
2482             type: string
2483       requestBody:
2484         required: true
2485         content:
2486           application/json:
2487             schema:
2488               required:
2489                 - pc_catid
2490                 - pc_title
2491                 - pc_duration
2492                 - pc_hometext
2493                 - pc_apptstatus
2494                 - pc_eventDate
2495                 - pc_startTime
2496                 - pc_facility
2497                 - pc_billing_location
2498               properties:
2499                 pc_catid:
2500                   description: 'The category of the appointment.'
2501                   type: string
2502                 pc_title:
2503                   description: 'The title of the appointment.'
2504                   type: string
2505                 pc_duration:
2506                   description: 'The duration of the appointment.'
2507                   type: string
2508                 pc_hometext:
2509                   description: 'Comments for the appointment.'
2510                   type: string
2511                 pc_apptstatus:
2512                   description: 'use an option from resource=/api/list/apptstat'
2513                   type: string
2514                 pc_eventDate:
2515                   description: 'The date of the appointment.'
2516                   type: string
2517                 pc_startTime:
2518                   description: 'The time of the appointment.'
2519                   type: string
2520                 pc_facility:
2521                   description: 'The facility id of the appointment.'
2522                   type: string
2523                 pc_billing_location:
2524                   description: 'The billinag location id of the appointment.'
2525                   type: string
2526                 pc_aid:
2527                   description: 'The provider id for the appointment.'
2528                   type: string
2529               type: object
2530               example:
2531                 pc_catid: '5'
2532                 pc_title: 'Office Visit'
2533                 pc_duration: '900'
2534                 pc_hometext: Test
2535                 pc_apptstatus: '-'
2536                 pc_eventDate: '2018-10-19'
2537                 pc_startTime: '09:00'
2538                 pc_facility: '9'
2539                 pc_billing_location: '10'
2540                 pc_aid: '1'
2541       responses:
2542         '200':
2543           $ref: '#/components/responses/standard'
2544         '400':
2545           $ref: '#/components/responses/badrequest'
2546         '401':
2547           $ref: '#/components/responses/unauthorized'
2548       security:
2549         -
2550           openemr_auth: []
2551   /api/appointment:
2552     get:
2553       tags:
2554         - standard
2555       description: 'Retrieves all appointments'
2556       responses:
2557         '200':
2558           $ref: '#/components/responses/standard'
2559         '400':
2560           $ref: '#/components/responses/badrequest'
2561         '401':
2562           $ref: '#/components/responses/unauthorized'
2563       security:
2564         -
2565           openemr_auth: []
2566   '/api/appointment/{eid}':
2567     get:
2568       tags:
2569         - standard
2570       description: 'Retrieves an appointment'
2571       parameters:
2572         -
2573           name: eid
2574           in: path
2575           description: 'The eid for the appointment.'
2576           required: true
2577           schema:
2578             type: string
2579       responses:
2580         '200':
2581           $ref: '#/components/responses/standard'
2582         '400':
2583           $ref: '#/components/responses/badrequest'
2584         '401':
2585           $ref: '#/components/responses/unauthorized'
2586       security:
2587         -
2588           openemr_auth: []
2589   '/api/patient/{pid}/appointment/{eid}':
2590     get:
2591       tags:
2592         - standard
2593       description: 'Retrieves a appointment for a patient'
2594       parameters:
2595         -
2596           name: pid
2597           in: path
2598           description: 'The id for the patient.'
2599           required: true
2600           schema:
2601             type: string
2602         -
2603           name: eid
2604           in: path
2605           description: 'The eid for the appointment.'
2606           required: true
2607           schema:
2608             type: string
2609       responses:
2610         '200':
2611           $ref: '#/components/responses/standard'
2612         '400':
2613           $ref: '#/components/responses/badrequest'
2614         '401':
2615           $ref: '#/components/responses/unauthorized'
2616       security:
2617         -
2618           openemr_auth: []
2619     delete:
2620       tags:
2621         - standard
2622       description: 'Delete a appointment'
2623       parameters:
2624         -
2625           name: pid
2626           in: path
2627           description: 'The id for the patient.'
2628           required: true
2629           schema:
2630             type: string
2631         -
2632           name: eid
2633           in: path
2634           description: 'The eid for the appointment.'
2635           required: true
2636           schema:
2637             type: string
2638       responses:
2639         '200':
2640           $ref: '#/components/responses/standard'
2641         '400':
2642           $ref: '#/components/responses/badrequest'
2643         '401':
2644           $ref: '#/components/responses/unauthorized'
2645       security:
2646         -
2647           openemr_auth: []
2648   '/api/list/{list_name}':
2649     get:
2650       tags:
2651         - standard
2652       description: 'Retrieves a list'
2653       parameters:
2654         -
2655           name: list_name
2656           in: path
2657           description: 'The list_id of the list.'
2658           required: true
2659           schema:
2660             type: string
2661       responses:
2662         '200':
2663           $ref: '#/components/responses/standard'
2664         '400':
2665           $ref: '#/components/responses/badrequest'
2666         '401':
2667           $ref: '#/components/responses/unauthorized'
2668       security:
2669         -
2670           openemr_auth: []
2671   /api/user:
2672     get:
2673       tags:
2674         - standard
2675       description: 'Retrieves a list of users'
2676       parameters:
2677         -
2678           name: id
2679           in: query
2680           description: 'The id for the user.'
2681           required: false
2682           schema:
2683             type: string
2684         -
2685           name: title
2686           in: query
2687           description: 'The title for the user.'
2688           required: false
2689           schema:
2690             type: string
2691         -
2692           name: fname
2693           in: query
2694           description: 'The first name for the user.'
2695           required: false
2696           schema:
2697             type: string
2698         -
2699           name: lname
2700           in: query
2701           description: 'The last name for the user.'
2702           required: false
2703           schema:
2704             type: string
2705         -
2706           name: mname
2707           in: query
2708           description: 'The middle name for the user.'
2709           required: false
2710           schema:
2711             type: string
2712         -
2713           name: federaltaxid
2714           in: query
2715           description: 'The federal tax id for the user.'
2716           required: false
2717           schema:
2718             type: string
2719         -
2720           name: federaldrugid
2721           in: query
2722           description: 'The federal drug id for the user.'
2723           required: false
2724           schema:
2725             type: string
2726         -
2727           name: upin
2728           in: query
2729           description: 'The upin for the user.'
2730           required: false
2731           schema:
2732             type: string
2733         -
2734           name: facility_id
2735           in: query
2736           description: 'The facility id for the user.'
2737           required: false
2738           schema:
2739             type: string
2740         -
2741           name: facility
2742           in: query
2743           description: 'The facility for the user.'
2744           required: false
2745           schema:
2746             type: string
2747         -
2748           name: npi
2749           in: query
2750           description: 'The npi for the user.'
2751           required: false
2752           schema:
2753             type: string
2754         -
2755           name: email
2756           in: query
2757           description: 'The email for the user.'
2758           required: false
2759           schema:
2760             type: string
2761         -
2762           name: specialty
2763           in: query
2764           description: 'The specialty for the user.'
2765           required: false
2766           schema:
2767             type: string
2768         -
2769           name: billname
2770           in: query
2771           description: 'The billname for the user.'
2772           required: false
2773           schema:
2774             type: string
2775         -
2776           name: url
2777           in: query
2778           description: 'The url for the user.'
2779           required: false
2780           schema:
2781             type: string
2782         -
2783           name: assistant
2784           in: query
2785           description: 'The assistant for the user.'
2786           required: false
2787           schema:
2788             type: string
2789         -
2790           name: organization
2791           in: query
2792           description: 'The organization for the user.'
2793           required: false
2794           schema:
2795             type: string
2796         -
2797           name: valedictory
2798           in: query
2799           description: 'The valedictory for the user.'
2800           required: false
2801           schema:
2802             type: string
2803         -
2804           name: street
2805           in: query
2806           description: 'The street for the user.'
2807           required: false
2808           schema:
2809             type: string
2810         -
2811           name: streetb
2812           in: query
2813           description: 'The street (line 2) for the user.'
2814           required: false
2815           schema:
2816             type: string
2817         -
2818           name: city
2819           in: query
2820           description: 'The city for the user.'
2821           required: false
2822           schema:
2823             type: string
2824         -
2825           name: state
2826           in: query
2827           description: 'The state for the user.'
2828           required: false
2829           schema:
2830             type: string
2831         -
2832           name: zip
2833           in: query
2834           description: 'The zip for the user.'
2835           required: false
2836           schema:
2837             type: string
2838         -
2839           name: phone
2840           in: query
2841           description: 'The phone for the user.'
2842           required: false
2843           schema:
2844             type: string
2845         -
2846           name: fax
2847           in: query
2848           description: 'The fax for the user.'
2849           required: false
2850           schema:
2851             type: string
2852         -
2853           name: phonew1
2854           in: query
2855           description: 'The phonew1 for the user.'
2856           required: false
2857           schema:
2858             type: string
2859         -
2860           name: phonecell
2861           in: query
2862           description: 'The phonecell for the user.'
2863           required: false
2864           schema:
2865             type: string
2866         -
2867           name: notes
2868           in: query
2869           description: 'The notes for the user.'
2870           required: false
2871           schema:
2872             type: string
2873         -
2874           name: state_license_number2
2875           in: query
2876           description: 'The state license number for the user.'
2877           required: false
2878           schema:
2879             type: string
2880         -
2881           name: username
2882           in: query
2883           description: 'The username for the user.'
2884           required: false
2885           schema:
2886             type: string
2887       responses:
2888         '200':
2889           $ref: '#/components/responses/standard'
2890         '400':
2891           $ref: '#/components/responses/badrequest'
2892         '401':
2893           $ref: '#/components/responses/unauthorized'
2894       security:
2895         -
2896           openemr_auth: []
2897   '/api/user/{uuid}':
2898     get:
2899       tags:
2900         - standard
2901       description: 'Retrieves a single user by their uuid'
2902       parameters:
2903         -
2904           name: uuid
2905           in: path
2906           description: 'The uuid for the user.'
2907           required: true
2908           schema:
2909             type: string
2910       responses:
2911         '200':
2912           $ref: '#/components/responses/standard'
2913         '400':
2914           $ref: '#/components/responses/badrequest'
2915         '401':
2916           $ref: '#/components/responses/unauthorized'
2917       security:
2918         -
2919           openemr_auth: []
2920   /api/version:
2921     get:
2922       tags:
2923         - standard
2924       description: 'Retrieves the OpenEMR version information'
2925       responses:
2926         '200':
2927           $ref: '#/components/responses/standard'
2928         '400':
2929           $ref: '#/components/responses/badrequest'
2930         '401':
2931           $ref: '#/components/responses/unauthorized'
2932       security:
2933         -
2934           openemr_auth: []
2935   /api/product:
2936     get:
2937       tags:
2938         - standard
2939       description: 'Retrieves the OpenEMR product registration information'
2940       responses:
2941         '200':
2942           $ref: '#/components/responses/standard'
2943         '400':
2944           $ref: '#/components/responses/badrequest'
2945         '401':
2946           $ref: '#/components/responses/unauthorized'
2947       security:
2948         -
2949           openemr_auth: []
2950   /api/insurance_company:
2951     get:
2952       tags:
2953         - standard
2954       description: 'Retrieves all insurance companies'
2955       responses:
2956         '200':
2957           $ref: '#/components/responses/standard'
2958         '400':
2959           $ref: '#/components/responses/badrequest'
2960         '401':
2961           $ref: '#/components/responses/unauthorized'
2962       security:
2963         -
2964           openemr_auth: []
2965     post:
2966       tags:
2967         - standard
2968       description: 'Submits a new insurance company'
2969       requestBody:
2970         required: true
2971         content:
2972           application/json:
2973             schema:
2974               $ref: '#/components/schemas/api_insurance_company_request'
2975       responses:
2976         '200':
2977           $ref: '#/components/responses/standard'
2978         '400':
2979           $ref: '#/components/responses/badrequest'
2980         '401':
2981           $ref: '#/components/responses/unauthorized'
2982       security:
2983         -
2984           openemr_auth: []
2985   '/api/insurance_company/{iid}':
2986     get:
2987       tags:
2988         - standard
2989       description: 'Retrieves insurance company'
2990       parameters:
2991         -
2992           name: iid
2993           in: path
2994           description: 'The id of the insurance company.'
2995           required: true
2996           schema:
2997             type: string
2998       responses:
2999         '200':
3000           $ref: '#/components/responses/standard'
3001         '400':
3002           $ref: '#/components/responses/badrequest'
3003         '401':
3004           $ref: '#/components/responses/unauthorized'
3005       security:
3006         -
3007           openemr_auth: []
3008     put:
3009       tags:
3010         - standard
3011       description: 'Edit a insurance company'
3012       parameters:
3013         -
3014           name: iid
3015           in: path
3016           description: 'The id for the insurance company.'
3017           required: true
3018           schema:
3019             type: string
3020       requestBody:
3021         required: true
3022         content:
3023           application/json:
3024             schema:
3025               $ref: '#/components/schemas/api_insurance_company_request'
3026       responses:
3027         '200':
3028           $ref: '#/components/responses/standard'
3029         '400':
3030           $ref: '#/components/responses/badrequest'
3031         '401':
3032           $ref: '#/components/responses/unauthorized'
3033       security:
3034         -
3035           openemr_auth: []
3036   /api/insurance_type:
3037     get:
3038       tags:
3039         - standard
3040       description: 'Retrieves all insurance types'
3041       responses:
3042         '200':
3043           $ref: '#/components/responses/standard'
3044         '400':
3045           $ref: '#/components/responses/badrequest'
3046         '401':
3047           $ref: '#/components/responses/unauthorized'
3048       security:
3049         -
3050           openemr_auth: []
3051   '/api/patient/{pid}/document':
3052     get:
3053       tags:
3054         - standard
3055       description: 'Retrieves all file information of documents from a category for a patient'
3056       parameters:
3057         -
3058           name: pid
3059           in: path
3060           description: 'The pid for the patient.'
3061           required: true
3062           schema:
3063             type: string
3064         -
3065           name: path
3066           in: query
3067           description: 'The category of the documents.'
3068           required: true
3069           schema:
3070             type: string
3071       responses:
3072         '200':
3073           $ref: '#/components/responses/standard'
3074         '400':
3075           $ref: '#/components/responses/badrequest'
3076         '401':
3077           $ref: '#/components/responses/unauthorized'
3078       security:
3079         -
3080           openemr_auth: []
3081     post:
3082       tags:
3083         - standard
3084       description: 'Submits a new patient document'
3085       parameters:
3086         -
3087           name: pid
3088           in: path
3089           description: 'The pid for the patient.'
3090           required: true
3091           schema:
3092             type: string
3093         -
3094           name: path
3095           in: query
3096           description: 'The category of the document.'
3097           required: true
3098           schema:
3099             type: string
3100       requestBody:
3101         required: true
3102         content:
3103           multipart/form-data:
3104             schema:
3105               properties:
3106                 document:
3107                   description: document
3108                   type: string
3109                   format: binary
3110               type: object
3111       responses:
3112         '200':
3113           $ref: '#/components/responses/standard'
3114         '400':
3115           $ref: '#/components/responses/badrequest'
3116         '401':
3117           $ref: '#/components/responses/unauthorized'
3118       security:
3119         -
3120           openemr_auth: []
3121   '/api/patient/{pid}/document/{did}':
3122     get:
3123       tags:
3124         - standard
3125       description: 'Retrieves a document for a patient'
3126       parameters:
3127         -
3128           name: pid
3129           in: path
3130           description: 'The pid for the patient.'
3131           required: true
3132           schema:
3133             type: string
3134         -
3135           name: did
3136           in: path
3137           description: 'The id for the patient document.'
3138           required: true
3139           schema:
3140             type: string
3141       responses:
3142         '200':
3143           $ref: '#/components/responses/standard'
3144         '400':
3145           $ref: '#/components/responses/badrequest'
3146         '401':
3147           $ref: '#/components/responses/unauthorized'
3148       security:
3149         -
3150           openemr_auth: []
3151   '/api/patient/{puuid}/employer':
3152     get:
3153       tags:
3154         - standard
3155       description: 'Retrieves all the employer data for a patient. Returns an array of the employer data for the patient.'
3156       parameters:
3157         -
3158           name: pid
3159           in: path
3160           description: 'The uuid for the patient.'
3161           required: true
3162           schema:
3163             type: string
3164       responses:
3165         '200':
3166           $ref: '#/components/responses/standard'
3167         '400':
3168           $ref: '#/components/responses/badrequest'
3169         '401':
3170           $ref: '#/components/responses/unauthorized'
3171       security:
3172         -
3173           openemr_auth: []
3174   '/api/patient/{puuid}/insurance':
3175     get:
3176       tags:
3177         - standard
3178       description: 'Retrieves all insurances for a patient'
3179       parameters:
3180         -
3181           name: pid
3182           in: path
3183           description: 'The uuid for the patient.'
3184           required: true
3185           schema:
3186             type: string
3187       responses:
3188         '200':
3189           $ref: '#/components/responses/standard'
3190         '400':
3191           $ref: '#/components/responses/badrequest'
3192         '401':
3193           $ref: '#/components/responses/unauthorized'
3194       security:
3195         -
3196           openemr_auth: []
3197     post:
3198       tags:
3199         - standard
3200       description: 'Submits a new patient insurance.'
3201       parameters:
3202         -
3203           name: puuid
3204           in: path
3205           description: 'The uuid for the patient.'
3206           required: true
3207           schema:
3208             type: string
3209       requestBody:
3210         required: true
3211         content:
3212           application/json:
3213             schema:
3214               $ref: '#/components/schemas/api_insurance_request'
3215       responses:
3216         '200':
3217           $ref: '#/components/responses/standard'
3218         '400':
3219           $ref: '#/components/responses/badrequest'
3220         '401':
3221           $ref: '#/components/responses/unauthorized'
3222       security:
3223         -
3224           openemr_auth: []
3225   '/api/patient/{puuid}/insurance/$swap-insurance':
3226     get:
3227       tags:
3228         - standard
3229       description: 'Updates the insurance for the passed in uuid to be a policy of type `type` and updates (if one exists) the current or most recent insurance for the passed in `type` for a patient to be the `type` of the insurance for the given `uuid`. Validations on the swap operation are performed to make sure the effective `date` of the src and target policies being swapped can be received in each given policy `type` as a policy `type` and `date` must together be unique per patient.'
3230       parameters:
3231         -
3232           name: pid
3233           in: path
3234           description: 'The uuid for the patient.'
3235           required: true
3236           schema:
3237             type: string
3238         -
3239           name: type
3240           in: query
3241           description: 'The type or category of OpenEMR insurance policy, ''primary'', ''secondary'', or ''tertiary''.'
3242           required: true
3243           schema:
3244             type: string
3245         -
3246           name: uuid
3247           in: query
3248           description: 'The insurance uuid that will be swapped into the list of insurances for the type query parameter'
3249           required: true
3250           schema:
3251             type: string
3252       responses:
3253         '200':
3254           $ref: '#/components/responses/standard'
3255         '400':
3256           $ref: '#/components/responses/badrequest'
3257         '401':
3258           $ref: '#/components/responses/unauthorized'
3259       security:
3260         -
3261           openemr_auth: []
3262   '/api/patient/{puuid}/insurance/{uuid}':
3263     get:
3264       tags:
3265         - standard
3266       description: 'Retrieves all insurances for a patient'
3267       parameters:
3268         -
3269           name: pid
3270           in: path
3271           description: 'The uuid for the patient.'
3272           required: true
3273           schema:
3274             type: string
3275       responses:
3276         '200':
3277           $ref: '#/components/responses/standard'
3278         '400':
3279           $ref: '#/components/responses/badrequest'
3280         '401':
3281           $ref: '#/components/responses/unauthorized'
3282       security:
3283         -
3284           openemr_auth: []
3285   '/api/patient/{puuid}/insurance/{insuranceUuid}':
3286     put:
3287       tags:
3288         - standard
3289       description: 'Edit a specific patient insurance policy. Requires the patients/demo/write ACL to call. This method is the preferred method for updating a patient insurance policy. The {insuranceId} can be found by querying /api/patient/{pid}/insurance'
3290       parameters:
3291         -
3292           name: puuid
3293           in: path
3294           description: 'The uuid for the patient.'
3295           required: true
3296           schema:
3297             type: string
3298         -
3299           name: insuranceUuid
3300           in: path
3301           description: 'The insurance policy uuid for the patient.'
3302           required: true
3303           schema:
3304             type: string
3305       requestBody:
3306         required: true
3307         content:
3308           application/json:
3309             schema:
3310               $ref: '#/components/schemas/api_insurance_request'
3311       responses:
3312         '200':
3313           $ref: '#/components/responses/standard'
3314         '400':
3315           $ref: '#/components/responses/badrequest'
3316         '401':
3317           $ref: '#/components/responses/unauthorized'
3318       security:
3319         -
3320           openemr_auth: []
3321   '/api/patient/{pid}/message':
3322     post:
3323       tags:
3324         - standard
3325       description: 'Submits a pnote message'
3326       parameters:
3327         -
3328           name: pid
3329           in: path
3330           description: 'The id for the patient.'
3331           required: true
3332           schema:
3333             type: string
3334       requestBody:
3335         required: true
3336         content:
3337           application/json:
3338             schema:
3339               $ref: '#/components/schemas/api_message_request'
3340       responses:
3341         '200':
3342           $ref: '#/components/responses/standard'
3343         '400':
3344           $ref: '#/components/responses/badrequest'
3345         '401':
3346           $ref: '#/components/responses/unauthorized'
3347       security:
3348         -
3349           openemr_auth: []
3350   '/api/patient/{pid}/transaction':
3351     get:
3352       tags:
3353         - standard
3354       description: 'Get Transactions for a patient'
3355       parameters:
3356         -
3357           name: pid
3358           in: path
3359           description: 'The pid for the patient'
3360           required: true
3361           schema:
3362             type: string
3363       responses:
3364         '200':
3365           $ref: '#/components/responses/standard'
3366         '400':
3367           $ref: '#/components/responses/badrequest'
3368         '401':
3369           $ref: '#/components/responses/unauthorized'
3370       security:
3371         -
3372           openemr_auth: []
3373     post:
3374       tags:
3375         - standard
3376       description: 'Submits a transaction'
3377       parameters:
3378         -
3379           name: pid
3380           in: path
3381           description: 'The pid for the patient.'
3382           required: true
3383           schema:
3384             type: string
3385       requestBody:
3386         required: true
3387         content:
3388           application/json:
3389             schema:
3390               $ref: '#/components/schemas/api_transaction_request'
3391       responses:
3392         '200':
3393           $ref: '#/components/responses/standard'
3394         '400':
3395           $ref: '#/components/responses/badrequest'
3396         '401':
3397           $ref: '#/components/responses/unauthorized'
3398       security:
3399         -
3400           openemr_auth: []
3401   '/api/transaction/{tid}':
3402     put:
3403       tags:
3404         - standard
3405       description: 'Updates a transaction'
3406       parameters:
3407         -
3408           name: tid
3409           in: path
3410           description: 'The id for the transaction.'
3411           required: true
3412           schema:
3413             type: string
3414       requestBody:
3415         required: true
3416         content:
3417           application/json:
3418             schema:
3419               $ref: '#/components/schemas/api_transaction_request'
3420       responses:
3421         '200':
3422           $ref: '#/components/responses/standard'
3423         '400':
3424           $ref: '#/components/responses/badrequest'
3425         '401':
3426           $ref: '#/components/responses/unauthorized'
3427       security:
3428         -
3429           openemr_auth: []
3430   '/api/patient/{pid}/message/{mid}':
3431     put:
3432       tags:
3433         - standard
3434       description: 'Edit a pnote message'
3435       parameters:
3436         -
3437           name: pid
3438           in: path
3439           description: 'The id for the patient.'
3440           required: true
3441           schema:
3442             type: string
3443         -
3444           name: mid
3445           in: path
3446           description: 'The id for the pnote message.'
3447           required: true
3448           schema:
3449             type: string
3450       requestBody:
3451         required: true
3452         content:
3453           application/json:
3454             schema:
3455               $ref: '#/components/schemas/api_message_request'
3456       responses:
3457         '200':
3458           $ref: '#/components/responses/standard'
3459         '400':
3460           $ref: '#/components/responses/badrequest'
3461         '401':
3462           $ref: '#/components/responses/unauthorized'
3463       security:
3464         -
3465           openemr_auth: []
3466     delete:
3467       tags:
3468         - standard
3469       description: 'Delete a pnote message'
3470       parameters:
3471         -
3472           name: pid
3473           in: path
3474           description: 'The id for the patient.'
3475           required: true
3476           schema:
3477             type: string
3478         -
3479           name: mid
3480           in: path
3481           description: 'The id for the pnote message.'
3482           required: true
3483           schema:
3484             type: string
3485       responses:
3486         '200':
3487           $ref: '#/components/responses/standard'
3488         '400':
3489           $ref: '#/components/responses/badrequest'
3490         '401':
3491           $ref: '#/components/responses/unauthorized'
3492       security:
3493         -
3494           openemr_auth: []
3495   /api/immunization:
3496     get:
3497       tags:
3498         - standard
3499       description: 'Retrieves a list of immunizations'
3500       parameters:
3501         -
3502           name: patient_id
3503           in: query
3504           description: 'The pid for the patient.'
3505           required: false
3506           schema:
3507             type: string
3508         -
3509           name: id
3510           in: query
3511           description: 'The id for the immunization.'
3512           required: false
3513           schema:
3514             type: string
3515         -
3516           name: uuid
3517           in: query
3518           description: 'The uuid for the immunization.'
3519           required: false
3520           schema:
3521             type: string
3522         -
3523           name: administered_date
3524           in: query
3525           description: 'The administered date for the immunization.'
3526           required: false
3527           schema:
3528             type: string
3529         -
3530           name: immunization_id
3531           in: query
3532           description: 'The immunization list_id for the immunization.'
3533           required: false
3534           schema:
3535             type: string
3536         -
3537           name: cvx_code
3538           in: query
3539           description: 'The cvx code for the immunization.'
3540           required: false
3541           schema:
3542             type: string
3543         -
3544           name: manufacturer
3545           in: query
3546           description: 'The manufacturer for the immunization.'
3547           required: false
3548           schema:
3549             type: string
3550         -
3551           name: lot_number
3552           in: query
3553           description: 'The lot number for the immunization.'
3554           required: false
3555           schema:
3556             type: string
3557         -
3558           name: administered_by_id
3559           in: query
3560           description: 'The administered by id for the immunization.'
3561           required: false
3562           schema:
3563             type: string
3564         -
3565           name: administered_by
3566           in: query
3567           description: 'The administered by for the immunization.'
3568           required: false
3569           schema:
3570             type: string
3571         -
3572           name: education_date
3573           in: query
3574           description: 'The education date for the immunization.'
3575           required: false
3576           schema:
3577             type: string
3578         -
3579           name: vis_date
3580           in: query
3581           description: 'The vis date for the immunization.'
3582           required: false
3583           schema:
3584             type: string
3585         -
3586           name: note
3587           in: query
3588           description: 'The note for the immunization.'
3589           required: false
3590           schema:
3591             type: string
3592         -
3593           name: create_date
3594           in: query
3595           description: 'The create date for the immunization.'
3596           required: false
3597           schema:
3598             type: string
3599         -
3600           name: update_date
3601           in: query
3602           description: 'The update date for the immunization.'
3603           required: false
3604           schema:
3605             type: string
3606         -
3607           name: created_by
3608           in: query
3609           description: 'The created_by for the immunization.'
3610           required: false
3611           schema:
3612             type: string
3613         -
3614           name: updated_by
3615           in: query
3616           description: 'The updated_by for the immunization.'
3617           required: false
3618           schema:
3619             type: string
3620         -
3621           name: amount_administered
3622           in: query
3623           description: 'The amount administered for the immunization.'
3624           required: false
3625           schema:
3626             type: string
3627         -
3628           name: amount_administered_unit
3629           in: query
3630           description: 'The amount administered unit for the immunization.'
3631           required: false
3632           schema:
3633             type: string
3634         -
3635           name: expiration_date
3636           in: query
3637           description: 'The expiration date for the immunization.'
3638           required: false
3639           schema:
3640             type: string
3641         -
3642           name: route
3643           in: query
3644           description: 'The route for the immunization.'
3645           required: false
3646           schema:
3647             type: string
3648         -
3649           name: administration_site
3650           in: query
3651           description: 'The administration site for the immunization.'
3652           required: false
3653           schema:
3654             type: string
3655         -
3656           name: added_erroneously
3657           in: query
3658           description: 'The added_erroneously for the immunization.'
3659           required: false
3660           schema:
3661             type: string
3662         -
3663           name: external_id
3664           in: query
3665           description: 'The external_id for the immunization.'
3666           required: false
3667           schema:
3668             type: string
3669         -
3670           name: completion_status
3671           in: query
3672           description: 'The completion status for the immunization.'
3673           required: false
3674           schema:
3675             type: string
3676         -
3677           name: information_source
3678           in: query
3679           description: 'The information source for the immunization.'
3680           required: false
3681           schema:
3682             type: string
3683         -
3684           name: refusal_reason
3685           in: query
3686           description: 'The refusal reason for the immunization.'
3687           required: false
3688           schema:
3689             type: string
3690         -
3691           name: ordering_provider
3692           in: query
3693           description: 'The ordering provider for the immunization.'
3694           required: false
3695           schema:
3696             type: string
3697       responses:
3698         '200':
3699           $ref: '#/components/responses/standard'
3700         '400':
3701           $ref: '#/components/responses/badrequest'
3702         '401':
3703           $ref: '#/components/responses/unauthorized'
3704       security:
3705         -
3706           openemr_auth: []
3707   '/api/immunization/{uuid}':
3708     get:
3709       tags:
3710         - standard
3711       description: 'Retrieves a immunization'
3712       parameters:
3713         -
3714           name: uuid
3715           in: path
3716           description: 'The uuid for the immunization.'
3717           required: true
3718           schema:
3719             type: string
3720       responses:
3721         '200':
3722           $ref: '#/components/responses/standard'
3723         '400':
3724           $ref: '#/components/responses/badrequest'
3725         '401':
3726           $ref: '#/components/responses/unauthorized'
3727       security:
3728         -
3729           openemr_auth: []
3730   /api/procedure:
3731     get:
3732       tags:
3733         - standard
3734       description: 'Retrieves a list of all procedures'
3735       responses:
3736         '200':
3737           $ref: '#/components/responses/standard'
3738         '400':
3739           $ref: '#/components/responses/badrequest'
3740         '401':
3741           $ref: '#/components/responses/unauthorized'
3742       security:
3743         -
3744           openemr_auth: []
3745   '/api/procedure/{uuid}':
3746     get:
3747       tags:
3748         - standard
3749       description: 'Retrieves a procedure'
3750       parameters:
3751         -
3752           name: uuid
3753           in: path
3754           description: 'The uuid for the procedure.'
3755           required: true
3756           schema:
3757             type: string
3758       responses:
3759         '200':
3760           $ref: '#/components/responses/standard'
3761         '400':
3762           $ref: '#/components/responses/badrequest'
3763         '401':
3764           $ref: '#/components/responses/unauthorized'
3765       security:
3766         -
3767           openemr_auth: []
3768   /api/drug:
3769     get:
3770       tags:
3771         - standard
3772       description: 'Retrieves a list of all drugs'
3773       responses:
3774         '200':
3775           $ref: '#/components/responses/standard'
3776         '400':
3777           $ref: '#/components/responses/badrequest'
3778         '401':
3779           $ref: '#/components/responses/unauthorized'
3780       security:
3781         -
3782           openemr_auth: []
3783   '/api/drug/{uuid}':
3784     get:
3785       tags:
3786         - standard
3787       description: 'Retrieves a drug'
3788       parameters:
3789         -
3790           name: uuid
3791           in: path
3792           description: 'The uuid for the drug.'
3793           required: true
3794           schema:
3795             type: string
3796       responses:
3797         '200':
3798           $ref: '#/components/responses/standard'
3799         '400':
3800           $ref: '#/components/responses/badrequest'
3801         '401':
3802           $ref: '#/components/responses/unauthorized'
3803       security:
3804         -
3805           openemr_auth: []
3806   /api/prescription:
3807     get:
3808       tags:
3809         - standard
3810       description: 'Retrieves a list of all prescriptions'
3811       responses:
3812         '200':
3813           $ref: '#/components/responses/standard'
3814         '400':
3815           $ref: '#/components/responses/badrequest'
3816         '401':
3817           $ref: '#/components/responses/unauthorized'
3818       security:
3819         -
3820           openemr_auth: []
3821   '/api/prescription/{uuid}':
3822     get:
3823       tags:
3824         - standard
3825       description: 'Retrieves a prescription'
3826       parameters:
3827         -
3828           name: uuid
3829           in: path
3830           description: 'The uuid for the prescription.'
3831           required: true
3832           schema:
3833             type: string
3834       responses:
3835         '200':
3836           $ref: '#/components/responses/standard'
3837         '400':
3838           $ref: '#/components/responses/badrequest'
3839         '401':
3840           $ref: '#/components/responses/unauthorized'
3841       security:
3842         -
3843           openemr_auth: []
3844   /fhir/AllergyIntolerance:
3845     get:
3846       tags:
3847         - fhir
3848       description: 'Returns a list of AllergyIntolerance resources.'
3849       parameters:
3850         -
3851           name: _id
3852           in: query
3853           description: 'The uuid for the AllergyIntolerance resource.'
3854           required: false
3855           schema:
3856             type: string
3857         -
3858           name: patient
3859           in: query
3860           description: 'The uuid for the patient.'
3861           required: false
3862           schema:
3863             type: string
3864       responses:
3865         '200':
3866           description: 'Standard Response'
3867           content:
3868             application/json:
3869               schema:
3870                 properties:
3871                   'json object': { description: 'FHIR Json object.', type: object }
3872                 type: object
3873                 example:
3874                   meta: { lastUpdated: '2021-09-14T09:13:51' }
3875                   resourceType: Bundle
3876                   type: collection
3877                   total: 0
3878                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/AllergyIntolerance' }]
3879         '400':
3880           $ref: '#/components/responses/badrequest'
3881         '401':
3882           $ref: '#/components/responses/unauthorized'
3883       security:
3884         -
3885           openemr_auth: []
3886   '/fhir/AllergyIntolerance/{uuid}':
3887     get:
3888       tags:
3889         - fhir
3890       description: 'Returns a single AllergyIntolerance resource.'
3891       parameters:
3892         -
3893           name: uuid
3894           in: path
3895           description: 'The uuid for the AllergyIntolerance resource.'
3896           required: true
3897           schema:
3898             type: string
3899       responses:
3900         '200':
3901           description: 'Standard Response'
3902           content:
3903             application/json:
3904               schema:
3905                 properties:
3906                   'json object': { description: 'FHIR Json object.', type: object }
3907                 type: object
3908                 example:
3909                   id: 94682fe5-f383-4885-9505-64b02e34906f
3910                   meta: { versionId: '1', lastUpdated: '2021-09-16T00:27:32+00:00' }
3911                   resourceType: AllergyIntolerance
3912                   text: { status: additional, div: '<div xmlns=''http://www.w3.org/1999/xhtml''>penicillin</div>' }
3913                   clinicalStatus: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/allergyintolerance-clinical', code: active, display: Active }] }
3914                   verificationStatus: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/allergyintolerance-verification', code: confirmed, display: Confirmed }] }
3915                   category: [medication]
3916                   criticality: low
3917                   code: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/data-absent-reason', code: unknown, display: Unknown }] }
3918                   patient: { reference: Patient/94682ef5-b0e3-4289-b19a-11b9592e9c92 }
3919                   reaction: [{ manifestation: [{ coding: [{ system: 'http://snomed.info/sct', code: '422587007', display: Nausea }], text: Nausea }] }]
3920         '400':
3921           $ref: '#/components/responses/badrequest'
3922         '401':
3923           $ref: '#/components/responses/unauthorized'
3924         '404':
3925           $ref: '#/components/responses/uuidnotfound'
3926       security:
3927         -
3928           openemr_auth: []
3929   /fhir/Appointment:
3930     get:
3931       tags:
3932         - fhir
3933       description: 'Returns a list of Appointment resources.'
3934       parameters:
3935         -
3936           name: _id
3937           in: query
3938           description: 'The uuid for the Appointment resource.'
3939           required: false
3940           schema:
3941             type: string
3942         -
3943           name: patient
3944           in: query
3945           description: 'The uuid for the patient.'
3946           required: false
3947           schema:
3948             type: string
3949       responses:
3950         '200':
3951           description: 'Standard Response'
3952           content:
3953             application/json:
3954               schema:
3955                 properties:
3956                   'json object': { description: 'FHIR Json object.', type: object }
3957                 type: object
3958                 example:
3959                   meta: { lastUpdated: '2021-09-14T09:13:51' }
3960                   resourceType: Bundle
3961                   type: collection
3962                   total: 0
3963                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/AllergyIntolerance' }]
3964         '400':
3965           $ref: '#/components/responses/badrequest'
3966         '401':
3967           $ref: '#/components/responses/unauthorized'
3968       security:
3969         -
3970           openemr_auth: []
3971   '/fhir/Appointment/{uuid}':
3972     get:
3973       tags:
3974         - fhir
3975       description: 'Returns a single Appointment resource.'
3976       parameters:
3977         -
3978           name: uuid
3979           in: path
3980           description: 'The uuid for the Appointment resource.'
3981           required: true
3982           schema:
3983             type: string
3984       responses:
3985         '200':
3986           description: 'Standard Response'
3987           content:
3988             application/json:
3989               schema:
3990                 properties:
3991                   'json object': { description: 'FHIR Json object.', type: object }
3992                 type: object
3993                 example: []
3994         '400':
3995           $ref: '#/components/responses/badrequest'
3996         '401':
3997           $ref: '#/components/responses/unauthorized'
3998         '404':
3999           $ref: '#/components/responses/uuidnotfound'
4000       security:
4001         -
4002           openemr_auth: []
4003   /fhir/CarePlan:
4004     get:
4005       tags:
4006         - fhir
4007       description: 'Returns a list of CarePlan resources.'
4008       parameters:
4009         -
4010           name: _id
4011           in: query
4012           description: 'The uuid for the CarePlan resource.'
4013           required: false
4014           schema:
4015             type: string
4016         -
4017           name: patient
4018           in: query
4019           description: 'The uuid for the patient.'
4020           required: false
4021           schema:
4022             type: string
4023         -
4024           name: category
4025           in: query
4026           description: 'The category of the CarePlan resource.'
4027           required: false
4028           schema:
4029             type: string
4030       responses:
4031         '200':
4032           description: 'Standard Response'
4033           content:
4034             application/json:
4035               schema:
4036                 properties:
4037                   'json object': { description: 'FHIR Json object.', type: object }
4038                 type: object
4039                 example:
4040                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4041                   resourceType: Bundle
4042                   type: collection
4043                   total: 0
4044                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/CarePlan' }]
4045         '400':
4046           $ref: '#/components/responses/badrequest'
4047         '401':
4048           $ref: '#/components/responses/unauthorized'
4049       security:
4050         -
4051           openemr_auth: []
4052   '/fhir/CarePlan/{uuid}':
4053     get:
4054       tags:
4055         - fhir
4056       description: 'Returns a single CarePlan resource.'
4057       parameters:
4058         -
4059           name: uuid
4060           in: path
4061           description: 'The uuid for the CarePlan resource.'
4062           required: true
4063           schema:
4064             type: string
4065       responses:
4066         '200':
4067           description: 'Standard Response'
4068           content:
4069             application/json:
4070               schema:
4071                 properties:
4072                   'json object': { description: 'FHIR Json object.', type: object }
4073                 type: object
4074                 example:
4075                   id: 94682f08-8fbc-451e-b1ec-f922d765c38f_1
4076                   meta: { versionId: '1', lastUpdated: '2021-09-16T00:54:18+00:00' }
4077                   resourceType: CarePlan
4078                   text: { status: generated, div: '<div xmlns="http://www.w3.org/1999/xhtml"><p>Treat flu.</p></div>' }
4079                   status: active
4080                   intent: plan
4081                   category: [{ coding: [{ system: 'http://hl7.org/fhir/us/core/CodeSystem/careplan-category', code: assess-plan }] }]
4082                   description: 'Treat flu.'
4083                   subject: { reference: Patient/94682ef5-b0e3-4289-b19a-11b9592e9c92, type: Patient }
4084         '400':
4085           $ref: '#/components/responses/badrequest'
4086         '401':
4087           $ref: '#/components/responses/unauthorized'
4088         '404':
4089           $ref: '#/components/responses/uuidnotfound'
4090       security:
4091         -
4092           openemr_auth: []
4093   /fhir/CareTeam:
4094     get:
4095       tags:
4096         - fhir
4097       description: 'Returns a list of CareTeam resources.'
4098       parameters:
4099         -
4100           name: _id
4101           in: query
4102           description: 'The uuid for the CareTeam resource.'
4103           required: false
4104           schema:
4105             type: string
4106         -
4107           name: patient
4108           in: query
4109           description: 'The uuid for the patient.'
4110           required: false
4111           schema:
4112             type: string
4113         -
4114           name: status
4115           in: query
4116           description: 'The status of the CarePlan resource.'
4117           required: false
4118           schema:
4119             type: string
4120       responses:
4121         '200':
4122           description: 'Standard Response'
4123           content:
4124             application/json:
4125               schema:
4126                 properties:
4127                   'json object': { description: 'FHIR Json object.', type: object }
4128                 type: object
4129                 example:
4130                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4131                   resourceType: Bundle
4132                   type: collection
4133                   total: 0
4134                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/CareTeam' }]
4135         '400':
4136           $ref: '#/components/responses/badrequest'
4137         '401':
4138           $ref: '#/components/responses/unauthorized'
4139       security:
4140         -
4141           openemr_auth: []
4142   '/fhir/CareTeam/{uuid}':
4143     get:
4144       tags:
4145         - fhir
4146       description: 'Returns a single CareTeam resource.'
4147       parameters:
4148         -
4149           name: uuid
4150           in: path
4151           description: 'The uuid for the CareTeam resource.'
4152           required: true
4153           schema:
4154             type: string
4155       responses:
4156         '200':
4157           description: 'Standard Response'
4158           content:
4159             application/json:
4160               schema:
4161                 properties:
4162                   'json object': { description: 'FHIR Json object.', type: object }
4163                 type: object
4164                 example:
4165                   id: 94682f09-69fe-4ada-8ea6-753a52bd1516
4166                   meta: { versionId: '1', lastUpdated: '2021-09-16T01:07:22+00:00' }
4167                   resourceType: CareTeam
4168                   status: active
4169                   subject: { reference: Patient/94682ef5-b0e3-4289-b19a-11b9592e9c92, type: Patient }
4170                   participant: [{ role: [{ coding: [{ system: 'http://nucc.org/provider-taxonomy', code: 102L00000X, display: Psychoanalyst }] }], member: { reference: Practitioner/94682c68-f712-4c39-9158-ff132a08f26b, type: Practitioner }, onBehalfOf: { reference: Organization/94682c62-b801-4498-84a1-13f158bb2a18, type: Organization } }, { role: [{ coding: [{ system: 'http://terminology.hl7.org/CodeSystem/data-absent-reason', code: unknown, display: Unknown }] }], member: { reference: Organization/94682c62-b801-4498-84a1-13f158bb2a18, type: Organization } }]
4171         '400':
4172           $ref: '#/components/responses/badrequest'
4173         '401':
4174           $ref: '#/components/responses/unauthorized'
4175         '404':
4176           $ref: '#/components/responses/uuidnotfound'
4177       security:
4178         -
4179           openemr_auth: []
4180   /fhir/Condition:
4181     get:
4182       tags:
4183         - fhir
4184       description: 'Returns a list of Condition resources.'
4185       parameters:
4186         -
4187           name: _id
4188           in: query
4189           description: 'The uuid for the Condition resource.'
4190           required: false
4191           schema:
4192             type: string
4193         -
4194           name: patient
4195           in: query
4196           description: 'The uuid for the patient.'
4197           required: false
4198           schema:
4199             type: string
4200       responses:
4201         '200':
4202           description: 'Standard Response'
4203           content:
4204             application/json:
4205               schema:
4206                 properties:
4207                   'json object': { description: 'FHIR Json object.', type: object }
4208                 type: object
4209                 example:
4210                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4211                   resourceType: Bundle
4212                   type: collection
4213                   total: 0
4214                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Condition' }]
4215         '400':
4216           $ref: '#/components/responses/badrequest'
4217         '401':
4218           $ref: '#/components/responses/unauthorized'
4219       security:
4220         -
4221           openemr_auth: []
4222   '/fhir/Condition/{uuid}':
4223     get:
4224       tags:
4225         - fhir
4226       description: 'Returns a single Condition resource.'
4227       parameters:
4228         -
4229           name: uuid
4230           in: path
4231           description: 'The uuid for the Condition resource.'
4232           required: true
4233           schema:
4234             type: string
4235       responses:
4236         '200':
4237           description: 'Standard Response'
4238           content:
4239             application/json:
4240               schema:
4241                 properties:
4242                   'json object': { description: 'FHIR Json object.', type: object }
4243                 type: object
4244                 example:
4245                   id: 94682c68-e5bb-4c5c-859a-cebaa5a1e582
4246                   meta: { versionId: '1', lastUpdated: '2021-09-16T02:41:53+00:00' }
4247                   resourceType: Condition
4248                   clinicalStatus: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/condition-clinical', code: inactive, display: Inactive }] }
4249                   verificationStatus: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/condition-ver-status', code: unconfirmed, display: Unconfirmed }] }
4250                   category: [{ coding: [{ system: 'http://terminology.hl7.org/CodeSystem/condition-category', code: problem-list-item, display: 'Problem List Item' }] }]
4251                   code: { coding: [{ system: 'http://snomed.info/sct', code: '444814009', display: '' }] }
4252                   subject: { reference: Patient/94682c62-d37e-48b5-8018-c5f6f3566609 }
4253         '400':
4254           $ref: '#/components/responses/badrequest'
4255         '401':
4256           $ref: '#/components/responses/unauthorized'
4257         '404':
4258           $ref: '#/components/responses/uuidnotfound'
4259       security:
4260         -
4261           openemr_auth: []
4262   /fhir/Coverage:
4263     get:
4264       tags:
4265         - fhir
4266       description: 'Returns a list of Coverage resources.'
4267       parameters:
4268         -
4269           name: _id
4270           in: query
4271           description: 'The uuid for the Coverage resource.'
4272           required: false
4273           schema:
4274             type: string
4275         -
4276           name: patient
4277           in: query
4278           description: 'The uuid for the patient.'
4279           required: false
4280           schema:
4281             type: string
4282         -
4283           name: payor
4284           in: query
4285           description: 'The payor of the Coverage resource.'
4286           required: false
4287           schema:
4288             type: string
4289       responses:
4290         '200':
4291           description: 'Standard Response'
4292           content:
4293             application/json:
4294               schema:
4295                 properties:
4296                   'json object': { description: 'FHIR Json object.', type: object }
4297                 type: object
4298                 example:
4299                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4300                   resourceType: Bundle
4301                   type: collection
4302                   total: 0
4303                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Coverage' }]
4304         '400':
4305           $ref: '#/components/responses/badrequest'
4306         '401':
4307           $ref: '#/components/responses/unauthorized'
4308       security:
4309         -
4310           openemr_auth: []
4311   '/fhir/Coverage/{uuid}':
4312     get:
4313       tags:
4314         - fhir
4315       description: 'Returns a single Coverage resource.'
4316       parameters:
4317         -
4318           name: uuid
4319           in: path
4320           description: 'The uuid for the Coverage resource.'
4321           required: true
4322           schema:
4323             type: string
4324       responses:
4325         '200':
4326           description: 'Standard Response'
4327           content:
4328             application/json:
4329               schema:
4330                 properties:
4331                   'json object': { description: 'FHIR Json object.', type: object }
4332                 type: object
4333                 example:
4334                   id: 960d5f10-edc6-4c65-a6d4-39a1e1da87a8
4335                   meta: { versionId: '1', lastUpdated: '2022-04-14T07:58:45+00:00' }
4336                   resourceType: Coverage
4337                   status: active
4338                   beneficiary: { reference: Patient/960d5f08-9fdf-4bdc-9108-84a149e28bac }
4339                   relationship: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/subscriber-relationship', code: '' }] }
4340         '400':
4341           $ref: '#/components/responses/badrequest'
4342         '401':
4343           $ref: '#/components/responses/unauthorized'
4344         '404':
4345           $ref: '#/components/responses/uuidnotfound'
4346       security:
4347         -
4348           openemr_auth: []
4349   /fhir/Device:
4350     get:
4351       tags:
4352         - fhir
4353       description: 'Returns a list of Device resources.'
4354       parameters:
4355         -
4356           name: _id
4357           in: query
4358           description: 'The uuid for the Device resource.'
4359           required: false
4360           schema:
4361             type: string
4362         -
4363           name: patient
4364           in: query
4365           description: 'The uuid for the patient.'
4366           required: false
4367           schema:
4368             type: string
4369       responses:
4370         '200':
4371           description: 'Standard Response'
4372           content:
4373             application/json:
4374               schema:
4375                 properties:
4376                   'json object': { description: 'FHIR Json object.', type: object }
4377                 type: object
4378                 example:
4379                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4380                   resourceType: Bundle
4381                   type: collection
4382                   total: 0
4383                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Device' }]
4384         '400':
4385           $ref: '#/components/responses/badrequest'
4386         '401':
4387           $ref: '#/components/responses/unauthorized'
4388       security:
4389         -
4390           openemr_auth: []
4391   '/fhir/Device/{uuid}':
4392     get:
4393       tags:
4394         - fhir
4395       description: 'Returns a single Device resource.'
4396       parameters:
4397         -
4398           name: uuid
4399           in: path
4400           description: 'The uuid for the Device resource.'
4401           required: true
4402           schema:
4403             type: string
4404       responses:
4405         '200':
4406           description: 'Standard Response'
4407           content:
4408             application/json:
4409               schema:
4410                 properties:
4411                   'json object': { description: 'FHIR Json object.', type: object }
4412                 type: object
4413                 example:
4414                   id: 946dce19-c80a-402c-862a-eadf3f2377f0
4415                   meta: { versionId: '1', lastUpdated: '2021-09-18T19:28:59+00:00' }
4416                   resourceType: Device
4417                   udiCarrier: [{ deviceIdentifier: '08717648200274', carrierHRF: '=/08717648200274=,000025=A99971312345600=>014032=}013032&,1000000000000XYZ123' }]
4418                   distinctIdentifier: A99971312345600
4419                   manufactureDate: '2013-02-01'
4420                   expirationDate: '2014-02-01'
4421                   lotNumber: 000000000000XYZ123
4422                   serialNumber: '000025'
4423                   type: { extension: [{ valueCode: unknown, url: 'http://hl7.org/fhir/StructureDefinition/data-absent-reason' }] }
4424                   patient: { reference: Patient/946da619-c631-431a-a282-487cd6fb7802, type: Patient }
4425         '400':
4426           $ref: '#/components/responses/badrequest'
4427         '401':
4428           $ref: '#/components/responses/unauthorized'
4429         '404':
4430           $ref: '#/components/responses/uuidnotfound'
4431       security:
4432         -
4433           openemr_auth: []
4434   /fhir/DiagnosticReport:
4435     get:
4436       tags:
4437         - fhir
4438       description: 'Returns a list of DiagnosticReport resources.'
4439       parameters:
4440         -
4441           name: _id
4442           in: query
4443           description: 'The uuid for the DiagnosticReport resource.'
4444           required: false
4445           schema:
4446             type: string
4447         -
4448           name: patient
4449           in: query
4450           description: 'The uuid for the patient.'
4451           required: false
4452           schema:
4453             type: string
4454         -
4455           name: code
4456           in: query
4457           description: 'The code of the DiagnosticReport resource.'
4458           required: false
4459           schema:
4460             type: string
4461         -
4462           name: category
4463           in: query
4464           description: 'The category of the DiagnosticReport resource.'
4465           required: false
4466           schema:
4467             type: string
4468         -
4469           name: date
4470           in: query
4471           description: 'The datetime of the DiagnosticReport resource.'
4472           required: false
4473           schema:
4474             type: string
4475       responses:
4476         '200':
4477           description: 'Standard Response'
4478           content:
4479             application/json:
4480               schema:
4481                 properties:
4482                   'json object': { description: 'FHIR Json object.', type: object }
4483                 type: object
4484                 example:
4485                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4486                   resourceType: Bundle
4487                   type: collection
4488                   total: 0
4489                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/DiagnosticReport' }]
4490         '400':
4491           $ref: '#/components/responses/badrequest'
4492         '401':
4493           $ref: '#/components/responses/unauthorized'
4494       security:
4495         -
4496           openemr_auth: []
4497   '/fhir/DiagnosticReport/{uuid}':
4498     get:
4499       tags:
4500         - fhir
4501       description: 'Returns a single DiagnosticReport resource.'
4502       parameters:
4503         -
4504           name: uuid
4505           in: path
4506           description: 'The uuid for the DiagnosticReport resource.'
4507           required: true
4508           schema:
4509             type: string
4510       responses:
4511         '200':
4512           description: 'Standard Response'
4513           content:
4514             application/json:
4515               schema:
4516                 properties:
4517                   'json object': { description: 'FHIR Json object.', type: object }
4518                 type: object
4519                 example:
4520                   id: 93fb2d6a-77ac-48ca-a12d-1a17e40007e3
4521                   meta: { versionId: '1', lastUpdated: '2021-09-18T20:52:34+00:00' }
4522                   resourceType: DiagnosticReport
4523                   status: final
4524                   category: [{ coding: [{ system: 'http://loinc.org', code: LP7839-6, display: Pathology }] }]
4525                   code: { coding: [{ system: 'http://loinc.org', code: 11502-2, display: 'Laboratory report' }] }
4526                   subject: { reference: Patient/9353b8f5-0a87-4e2a-afd4-25341fdb0fbc, type: Patient }
4527                   encounter: { reference: Encounter/93540818-cb5f-49df-b73b-83901bb793b6, type: Encounter }
4528                   effectiveDateTime: '2015-06-22T00:00:00+00:00'
4529                   issued: '2015-06-22T00:00:00+00:00'
4530                   performer: [{ reference: Organization/935249b5-0ba6-4b5b-8863-a7a27d4c6350, type: Organization }]
4531                   presentedForm: [{ contentType: text/plain, data: TXMgQWxpY2UgTmV3bWFuIHdhcyB0ZXN0ZWQgZm9yIHRoZSBVcmluYW5hbHlzaXMgbWFjcm8gcGFuZWwgYW5kIHRoZSByZXN1bHRzIGhhdmUgYmVlbiBmb3VuZCB0byBiZSANCm5vcm1hbC4= }]
4532         '400':
4533           $ref: '#/components/responses/badrequest'
4534         '401':
4535           $ref: '#/components/responses/unauthorized'
4536         '404':
4537           $ref: '#/components/responses/uuidnotfound'
4538       security:
4539         -
4540           openemr_auth: []
4541   /fhir/DocumentReference:
4542     get:
4543       tags:
4544         - fhir
4545       description: 'Returns a list of DocumentReference resources.'
4546       parameters:
4547         -
4548           name: _id
4549           in: query
4550           description: 'The uuid for the DocumentReference resource.'
4551           required: false
4552           schema:
4553             type: string
4554         -
4555           name: patient
4556           in: query
4557           description: 'The uuid for the patient.'
4558           required: false
4559           schema:
4560             type: string
4561         -
4562           name: type
4563           in: query
4564           description: 'The type of the DocumentReference resource.'
4565           required: false
4566           schema:
4567             type: string
4568         -
4569           name: category
4570           in: query
4571           description: 'The category of the DocumentReference resource.'
4572           required: false
4573           schema:
4574             type: string
4575         -
4576           name: date
4577           in: query
4578           description: 'The datetime of the DocumentReference resource.'
4579           required: false
4580           schema:
4581             type: string
4582       responses:
4583         '200':
4584           description: 'Standard Response'
4585           content:
4586             application/json:
4587               schema:
4588                 properties:
4589                   'json object': { description: 'FHIR Json object.', type: object }
4590                 type: object
4591                 example:
4592                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4593                   resourceType: Bundle
4594                   type: collection
4595                   total: 0
4596                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/DocumentReference' }]
4597         '400':
4598           $ref: '#/components/responses/badrequest'
4599         '401':
4600           $ref: '#/components/responses/unauthorized'
4601       security:
4602         -
4603           openemr_auth: []
4604   /fhir/DocumentReference/$docref:
4605     post:
4606       tags:
4607         - fhir
4608       description: 'The $docref operation is used to request the server generates a document based on the specified parameters. If no additional parameters are specified then a DocumentReference to the patient''s most current Clinical Summary of Care Document (CCD) is returned. The document itself is retrieved using the DocumentReference.content.attachment.url element.  See <a href=''http://hl7.org/fhir/us/core/OperationDefinition-docref.html'' target=''_blank'' rel=''noopener''>http://hl7.org/fhir/us/core/OperationDefinition-docref.html</a> for more details.'
4609       externalDocs:
4610         description: 'Detailed documentation on this operation'
4611         url: 'https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API'
4612       parameters:
4613         -
4614           name: patient
4615           in: query
4616           description: 'The uuid for the patient.'
4617           required: true
4618           schema:
4619             type: string
4620         -
4621           name: start
4622           in: query
4623           description: 'The datetime refers to care dates not record currency dates.  All records relating to care provided in a certain date range.  If no start date is provided then all documents prior to the end date are in scope.  If no start and end date are provided, the most recent or current document is in scope.'
4624           required: false
4625           schema:
4626             type: string
4627         -
4628           name: end
4629           in: query
4630           description: 'The datetime refers to care dates not record currency dates.  All records relating to care provided in a certain date range.  If no end date is provided then all documents subsequent to the start date are in scope.  If no start and end date are provided, the most recent or current document is in scope.'
4631           required: false
4632           schema:
4633             type: string
4634         -
4635           name: type
4636           in: query
4637           description: 'The type refers to the document type.  This is a LOINC code from the valueset of <a href=''http://hl7.org/fhir/R4/valueset-c80-doc-typecodes.html'' target=''_blank'' rel=''noopener''>http://hl7.org/fhir/R4/valueset-c80-doc-typecodes.html</a>. The server currently only supports the LOINC code of 34133-9 (Summary of episode node).'
4638           required: false
4639           schema:
4640             type: string
4641       responses:
4642         '200':
4643           description: 'A search bundle of DocumentReferences is returned'
4644         '400':
4645           $ref: '#/components/responses/badrequest'
4646         '401':
4647           $ref: '#/components/responses/unauthorized'
4648       security:
4649         -
4650           openemr_auth: []
4651   '/fhir/DocumentReference/{uuid}':
4652     get:
4653       tags:
4654         - fhir
4655       description: 'Returns a single DocumentReference resource.'
4656       parameters:
4657         -
4658           name: uuid
4659           in: path
4660           description: 'The uuid for the DocumentReference resource.'
4661           required: true
4662           schema:
4663             type: string
4664       responses:
4665         '200':
4666           description: 'Standard Response'
4667           content:
4668             application/json:
4669               schema:
4670                 properties:
4671                   'json object': { description: 'FHIR Json object.', type: object }
4672                 type: object
4673                 example:
4674                   id: 946e7553-1aaa-49f8-8f81-ae15ccaa9165
4675                   meta: { versionId: '1', lastUpdated: '2021-09-19T03:17:51+00:00' }
4676                   resourceType: DocumentReference
4677                   identifier: [{ value: 946e7553-1aaa-49f8-8f81-ae15ccaa9165 }]
4678                   status: current
4679                   type: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/v3-NullFlavor', code: UNK, display: unknown }] }
4680                   category: [{ coding: [{ system: 'https://localhost:9300/apis/default/fhir/ValueSet/openemr-document-types', code: openemr-document, display: 'OpenEMR Document' }] }]
4681                   subject: { reference: Patient/946da619-c631-431a-a282-487cd6fb7802, type: Patient }
4682                   date: '2021-09-19T03:15:56+00:00'
4683                   author: [null]
4684                   content: [{ attachment: { contentType: image/gif, url: 'https://localhost:9300/apis/default/fhir/Binary/7' }, format: { system: 'http://ihe.net/fhir/ValueSet/IHE.FormatCode.codesystem', code: 'urn:ihe:iti:xds:2017:mimeTypeSufficient', display: 'mimeType Sufficient' } }]
4685         '400':
4686           $ref: '#/components/responses/badrequest'
4687         '401':
4688           $ref: '#/components/responses/unauthorized'
4689         '404':
4690           $ref: '#/components/responses/uuidnotfound'
4691       security:
4692         -
4693           openemr_auth: []
4694   '/fhir/Binary/{id}':
4695     get:
4696       tags:
4697         - fhir
4698       description: 'Used for downloading binary documents generated either with BULK FHIR Export or with the $docref CCD export operation.  Documentation can be found at <a href=''https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API'' target=''_blank'' rel=''noopener''>https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API</a>'
4699       parameters:
4700         -
4701           name: id
4702           in: path
4703           description: 'The id for the Document.'
4704           required: true
4705           schema:
4706             type: string
4707       responses:
4708         '200':
4709           description: 'The documentation for working with BULK FHIR or $docref document exports can be found at <a href=''https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API'' target=''_blank'' rel=''noopener''>https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API</a>'
4710         '400':
4711           $ref: '#/components/responses/badrequest'
4712         '401':
4713           $ref: '#/components/responses/unauthorized'
4714       security:
4715         -
4716           openemr_auth: []
4717   /fhir/Encounter:
4718     get:
4719       tags:
4720         - fhir
4721       description: 'Returns a list of Encounter resources.'
4722       parameters:
4723         -
4724           name: _id
4725           in: query
4726           description: 'The uuid for the Encounter resource.'
4727           required: false
4728           schema:
4729             type: string
4730         -
4731           name: patient
4732           in: query
4733           description: 'The uuid for the patient.'
4734           required: false
4735           schema:
4736             type: string
4737         -
4738           name: date
4739           in: query
4740           description: 'The datetime of the Encounter resource.'
4741           required: false
4742           schema:
4743             type: string
4744       responses:
4745         '200':
4746           description: 'Standard Response'
4747           content:
4748             application/json:
4749               schema:
4750                 properties:
4751                   'json object': { description: 'FHIR Json object.', type: object }
4752                 type: object
4753                 example:
4754                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4755                   resourceType: Bundle
4756                   type: collection
4757                   total: 0
4758                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Encounter' }]
4759         '400':
4760           $ref: '#/components/responses/badrequest'
4761         '401':
4762           $ref: '#/components/responses/unauthorized'
4763       security:
4764         -
4765           openemr_auth: []
4766   '/fhir/Encounter/{uuid}':
4767     get:
4768       tags:
4769         - fhir
4770       description: 'Returns a single Encounter resource.'
4771       parameters:
4772         -
4773           name: uuid
4774           in: path
4775           description: 'The uuid for the Encounter resource.'
4776           required: true
4777           schema:
4778             type: string
4779       responses:
4780         '200':
4781           description: 'Standard Response'
4782           content:
4783             application/json:
4784               schema:
4785                 properties:
4786                   'json object': { description: 'FHIR Json object.', type: object }
4787                 type: object
4788                 example:
4789                   id: 946da61d-6b95-4f8e-abe5-534a25913b71
4790                   meta: { versionId: '1', lastUpdated: '2021-09-19T06:27:41+00:00' }
4791                   resourceType: Encounter
4792                   identifier: [{ system: 'urn:ietf:rfc:3986', value: 946da61d-6b95-4f8e-abe5-534a25913b71 }]
4793                   status: finished
4794                   class: { system: 'http://terminology.hl7.org/CodeSystem/v3-ActCode', code: AMB, display: ambulatory }
4795                   type: [{ coding: [{ system: 'http://snomed.info/sct', code: '185349003', display: 'Encounter for check up (procedure)' }] }]
4796                   subject: { reference: Patient/946da61b-626b-4f88-81e2-adfb88f4f0fe, type: Patient }
4797                   participant: [{ type: [{ coding: [{ system: 'http://terminology.hl7.org/CodeSystem/v3-ParticipationType', code: PPRF, display: 'Primary Performer' }] }], period: { start: '2012-08-13T00:00:00+00:00' }, individual: { reference: Practitioner/946da61d-ac5f-4fdc-b3f2-7b58dc49976b, type: Practitioner } }]
4798                   period: { start: '2012-08-13T00:00:00+00:00' }
4799         '400':
4800           $ref: '#/components/responses/badrequest'
4801         '401':
4802           $ref: '#/components/responses/unauthorized'
4803         '404':
4804           $ref: '#/components/responses/uuidnotfound'
4805       security:
4806         -
4807           openemr_auth: []
4808   /fhir/Goal:
4809     get:
4810       tags:
4811         - fhir
4812       description: 'Returns a list of Condition resources.'
4813       parameters:
4814         -
4815           name: _id
4816           in: query
4817           description: 'The uuid for the Goal resource.'
4818           required: false
4819           schema:
4820             type: string
4821         -
4822           name: patient
4823           in: query
4824           description: 'The uuid for the patient.'
4825           required: false
4826           schema:
4827             type: string
4828       responses:
4829         '200':
4830           description: 'Standard Response'
4831           content:
4832             application/json:
4833               schema:
4834                 properties:
4835                   'json object': { description: 'FHIR Json object.', type: object }
4836                 type: object
4837                 example:
4838                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4839                   resourceType: Bundle
4840                   type: collection
4841                   total: 0
4842                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Goal' }]
4843         '400':
4844           $ref: '#/components/responses/badrequest'
4845         '401':
4846           $ref: '#/components/responses/unauthorized'
4847       security:
4848         -
4849           openemr_auth: []
4850   '/fhir/Goal/{uuid}':
4851     get:
4852       tags:
4853         - fhir
4854       description: 'Returns a single Goal resource.'
4855       parameters:
4856         -
4857           name: uuid
4858           in: path
4859           description: 'The uuid for the Goal resource.'
4860           required: true
4861           schema:
4862             type: string
4863       responses:
4864         '200':
4865           description: 'Standard Response'
4866           content:
4867             application/json:
4868               schema:
4869                 properties:
4870                   'json object': { description: 'FHIR Json object.', type: object }
4871                 type: object
4872                 example:
4873                   id: 946da61d-6b88-4d54-bdd6-4029e2ad9e3f_1
4874                   meta: { versionId: '1', lastUpdated: '2021-09-19T06:45:58+00:00' }
4875                   resourceType: Goal
4876                   lifecycleStatus: active
4877                   description: { text: 'Eating more vegetables.' }
4878                   subject: { reference: Patient/946da619-c631-431a-a282-487cd6fb7802, type: Patient }
4879                   target: [{ measure: { extension: [{ valueCode: unknown, url: 'http://hl7.org/fhir/StructureDefinition/data-absent-reason' }] }, detailString: 'Eating more vegetables.', dueDate: '2021-09-09' }]
4880         '400':
4881           $ref: '#/components/responses/badrequest'
4882         '401':
4883           $ref: '#/components/responses/unauthorized'
4884         '404':
4885           $ref: '#/components/responses/uuidnotfound'
4886       security:
4887         -
4888           openemr_auth: []
4889   /fhir/Group:
4890     get:
4891       tags:
4892         - fhir
4893       description: 'The BULK FHIR Exports documentation can be found at <a href=''https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API'' target=''_blank'' rel=''noopener''>https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API</a>'
4894       parameters:
4895         -
4896           name: _id
4897           in: query
4898           description: 'The uuid for the Group resource.'
4899           required: false
4900           schema:
4901             type: string
4902         -
4903           name: patient
4904           in: query
4905           description: 'The uuid for the patient.'
4906           required: false
4907           schema:
4908             type: string
4909       responses:
4910         '200':
4911           description: 'Standard Response'
4912           content:
4913             application/json:
4914               schema:
4915                 properties:
4916                   'json object': { description: 'FHIR Json object.', type: object }
4917                 type: object
4918                 example:
4919                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4920                   resourceType: Bundle
4921                   type: collection
4922                   total: 0
4923                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Group' }]
4924         '400':
4925           $ref: '#/components/responses/badrequest'
4926         '401':
4927           $ref: '#/components/responses/unauthorized'
4928       security:
4929         -
4930           openemr_auth: []
4931   '/fhir/Group/{uuid}':
4932     get:
4933       tags:
4934         - fhir
4935       description: 'The BULK FHIR Exports documentation can be found at <a href=''https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API'' target=''_blank'' rel=''noopener''>https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API</a>'
4936       parameters:
4937         -
4938           name: uuid
4939           in: path
4940           description: 'The uuid for the Group resource.'
4941           required: true
4942           schema:
4943             type: string
4944       responses:
4945         '200':
4946           description: 'The BULK FHIR Exports documentation can be found at <a href=''https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API'' target=''_blank'' rel=''noopener''>https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API</a>'
4947         '400':
4948           $ref: '#/components/responses/badrequest'
4949         '401':
4950           $ref: '#/components/responses/unauthorized'
4951         '404':
4952           $ref: '#/components/responses/uuidnotfound'
4953       security:
4954         -
4955           openemr_auth: []
4956   '/fhir/Group/{id}/$export':
4957     get:
4958       tags:
4959         - fhir
4960       description: 'The BULK FHIR Exports documentation can be found at <a href=''https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API'' target=''_blank'' rel=''noopener''>https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API</a>'
4961       parameters:
4962         -
4963           name: id
4964           in: path
4965           description: 'The id for the Group resource.'
4966           required: true
4967           schema:
4968             type: string
4969       responses:
4970         '200':
4971           description: 'The BULK FHIR Exports documentation can be found at <a href=''https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API'' target=''_blank'' rel=''noopener''>https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API</a>'
4972         '400':
4973           $ref: '#/components/responses/badrequest'
4974         '401':
4975           $ref: '#/components/responses/unauthorized'
4976       security:
4977         -
4978           openemr_auth: []
4979   /fhir/Immunization:
4980     get:
4981       tags:
4982         - fhir
4983       description: 'Returns a list of Immunization resources.'
4984       parameters:
4985         -
4986           name: _id
4987           in: query
4988           description: 'The uuid for the Immunization resource.'
4989           required: false
4990           schema:
4991             type: string
4992         -
4993           name: patient
4994           in: query
4995           description: 'The uuid for the patient.'
4996           required: false
4997           schema:
4998             type: string
4999       responses:
5000         '200':
5001           description: 'Standard Response'
5002           content:
5003             application/json:
5004               schema:
5005                 properties:
5006                   'json object': { description: 'FHIR Json object.', type: object }
5007                 type: object
5008                 example:
5009                   meta: { lastUpdated: '2021-09-14T09:13:51' }
5010                   resourceType: Bundle
5011                   type: collection
5012                   total: 0
5013                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Immunization' }]
5014         '400':
5015           $ref: '#/components/responses/badrequest'
5016         '401':
5017           $ref: '#/components/responses/unauthorized'
5018       security:
5019         -
5020           openemr_auth: []
5021   '/fhir/Immunization/{uuid}':
5022     get:
5023       tags:
5024         - fhir
5025       description: 'Returns a single Immunization resource.'
5026       parameters:
5027         -
5028           name: uuid
5029           in: path
5030           description: 'The uuid for the Immunization resource.'
5031           required: true
5032           schema:
5033             type: string
5034       responses:
5035         '200':
5036           description: 'Standard Response'
5037           content:
5038             application/json:
5039               schema:
5040                 properties:
5041                   'json object': { description: 'FHIR Json object.', type: object }
5042                 type: object
5043                 example:
5044                   id: 95e8d8b7-e3e2-4e03-8eb1-31e1d9097d8f
5045                   meta: { versionId: '1', lastUpdated: '2022-03-26T05:42:59+00:00' }
5046                   resourceType: Immunization
5047                   status: completed
5048                   vaccineCode: { coding: [{ system: 'http://hl7.org/fhir/sid/cvx', code: '207', display: 'SARS-COV-2 (COVID-19) vaccine, mRNA, spike protein, LNP, preservative free, 100 mcg/0.5mL dose' }] }
5049                   patient: { reference: Patient/95e8d830-3068-48cf-930a-2fefb18c2bcf }
5050                   occurrenceDateTime: '2022-03-26T05:35:00+00:00'
5051                   recorded: '2022-03-26T05:42:26+00:00'
5052                   primarySource: false
5053         '400':
5054           $ref: '#/components/responses/badrequest'
5055         '401':
5056           $ref: '#/components/responses/unauthorized'
5057         '404':
5058           $ref: '#/components/responses/uuidnotfound'
5059       security:
5060         -
5061           openemr_auth: []
5062   /fhir/Location:
5063     get:
5064       tags:
5065         - fhir
5066       description: 'Returns a list of Location resources.'
5067       parameters:
5068         -
5069           name: _id
5070           in: query
5071           description: 'The uuid for the Location resource.'
5072           required: false
5073           schema:
5074             type: string
5075       responses:
5076         '200':
5077           description: 'Standard Response'
5078           content:
5079             application/json:
5080               schema:
5081                 properties:
5082                   'json object': { description: 'FHIR Json object.', type: object }
5083                 type: object
5084                 example:
5085                   meta: { lastUpdated: '2021-09-14T09:13:51' }
5086                   resourceType: Bundle
5087                   type: collection
5088                   total: 0
5089                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Location' }]
5090         '400':
5091           $ref: '#/components/responses/badrequest'
5092         '401':
5093           $ref: '#/components/responses/unauthorized'
5094       security:
5095         -
5096           openemr_auth: []
5097   '/fhir/Location/{uuid}':
5098     get:
5099       tags:
5100         - fhir
5101       description: 'Returns a single Location resource.'
5102       parameters:
5103         -
5104           name: uuid
5105           in: path
5106           description: 'The uuid for the Location resource.'
5107           required: true
5108           schema:
5109             type: string
5110       responses:
5111         '200':
5112           description: 'Standard Response'
5113           content:
5114             application/json:
5115               schema:
5116                 properties:
5117                   'json object': { description: 'FHIR Json object.', type: object }
5118                 type: object
5119                 example:
5120                   id: 946da61d-c4f2-4f03-a2a7-b571f6a24b65
5121                   meta: { versionId: '1', lastUpdated: '2021-09-19T08:14:58+00:00' }
5122                   resourceType: Location
5123                   status: active
5124                   name: 'Your Clinic Name Here'
5125                   telecom: [{ system: phone, value: 000-000-0000 }, { system: fax, value: 000-000-0000 }]
5126         '400':
5127           $ref: '#/components/responses/badrequest'
5128         '401':
5129           $ref: '#/components/responses/unauthorized'
5130         '404':
5131           $ref: '#/components/responses/uuidnotfound'
5132       security:
5133         -
5134           openemr_auth: []
5135   /fhir/Medication:
5136     get:
5137       tags:
5138         - fhir
5139       description: 'Returns a list of Medication resources.'
5140       responses:
5141         '200':
5142           description: 'Standard Response'
5143           content:
5144             application/json:
5145               schema:
5146                 properties:
5147                   'json object': { description: 'FHIR Json object.', type: object }
5148                 type: object
5149                 example:
5150                   meta: { lastUpdated: '2021-09-14T09:13:51' }
5151                   resourceType: Bundle
5152                   type: collection
5153                   total: 0
5154                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Medication' }]
5155         '400':
5156           $ref: '#/components/responses/badrequest'
5157         '401':
5158           $ref: '#/components/responses/unauthorized'
5159       security:
5160         -
5161           openemr_auth: []
5162   '/fhir/Medication/{uuid}':
5163     get:
5164       tags:
5165         - fhir
5166       description: 'Returns a single Medication resource.'
5167       parameters:
5168         -
5169           name: uuid
5170           in: path
5171           description: 'The uuid for the Medication resource.'
5172           required: true
5173           schema:
5174             type: string
5175       responses:
5176         '200':
5177           description: 'Standard Response'
5178           content:
5179             application/json:
5180               schema:
5181                 properties:
5182                   'json object': { description: 'FHIR Json object.', type: object }
5183                 type: object
5184                 example:
5185                   id: 961aa334-9348-4145-8252-de665e3c4afa
5186                   meta: { versionId: '1', lastUpdated: '2022-04-19T23:42:14+00:00' }
5187                   resourceType: Medication
5188                   code: { coding: [{ system: 'http://www.nlm.nih.gov/research/umls/rxnorm', code: 153165 }] }
5189                   status: active
5190                   batch: { lotNumber: '132', expirationDate: '0000-00-00' }
5191         '400':
5192           $ref: '#/components/responses/badrequest'
5193         '401':
5194           $ref: '#/components/responses/unauthorized'
5195         '404':
5196           $ref: '#/components/responses/uuidnotfound'
5197       security:
5198         -
5199           openemr_auth: []
5200   /fhir/MedicationRequest:
5201     get:
5202       tags:
5203         - fhir
5204       description: 'Returns a list of MedicationRequest resources.'
5205       parameters:
5206         -
5207           name: _id
5208           in: query
5209           description: 'The uuid for the MedicationRequest resource.'
5210           required: false
5211           schema:
5212             type: string
5213         -
5214           name: patient
5215           in: query
5216           description: 'The uuid for the patient.'
5217           required: false
5218           schema:
5219             type: string
5220         -
5221           name: intent
5222           in: query
5223           description: 'The intent of the MedicationRequest resource.'
5224           required: false
5225           schema:
5226             type: string
5227         -
5228           name: status
5229           in: query
5230           description: 'The status of the MedicationRequest resource.'
5231           required: false
5232           schema:
5233             type: string
5234       responses:
5235         '200':
5236           description: 'Standard Response'
5237           content:
5238             application/json:
5239               schema:
5240                 properties:
5241                   'json object': { description: 'FHIR Json object.', type: object }
5242                 type: object
5243                 example:
5244                   meta: { lastUpdated: '2021-09-14T09:13:51' }
5245                   resourceType: Bundle
5246                   type: collection
5247                   total: 0
5248                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/MedicationRequest' }]
5249         '400':
5250           $ref: '#/components/responses/badrequest'
5251         '401':
5252           $ref: '#/components/responses/unauthorized'
5253       security:
5254         -
5255           openemr_auth: []
5256   '/fhir/MedicationRequest/{uuid}':
5257     get:
5258       tags:
5259         - fhir
5260       description: 'Returns a single MedicationRequest resource.'
5261       parameters:
5262         -
5263           name: uuid
5264           in: path
5265           description: 'The uuid for the MedicationRequest resource.'
5266           required: true
5267           schema:
5268             type: string
5269       responses:
5270         '200':
5271           description: 'Standard Response'
5272           content:
5273             application/json:
5274               schema:
5275                 properties:
5276                   'json object': { description: 'FHIR Json object.', type: object }
5277                 type: object
5278                 example:
5279                   id: 946da61d-9cff-4416-8d27-805f19f9d7d8
5280                   meta: { versionId: '1', lastUpdated: '2021-09-20T04:03:14+00:00' }
5281                   resourceType: MedicationRequest
5282                   status: active
5283                   intent: order
5284                   category: [{ coding: [{ system: 'http://terminology.hl7.org/CodeSystem/medicationrequest-category', code: community, display: Home/Community }] }]
5285                   reportedBoolean: false
5286                   medicationCodeableConcept: { coding: [{ system: 'http://www.nlm.nih.gov/research/umls/rxnorm', code: '1738139', display: 'Acetaminophen 325 MG Oral Tablet' }] }
5287                   subject: { reference: Patient/946da617-1a4a-4b2c-ae66-93b84377cb1e, type: Patient }
5288                   authoredOn: '2021-09-18T00:00:00+00:00'
5289                   requester: { reference: Practitioner/946da61d-ac5f-4fdc-b3f2-7b58dc49976b, type: Practitioner }
5290         '400':
5291           $ref: '#/components/responses/badrequest'
5292         '401':
5293           $ref: '#/components/responses/unauthorized'
5294         '404':
5295           $ref: '#/components/responses/uuidnotfound'
5296       security:
5297         -
5298           openemr_auth: []
5299   /fhir/Observation:
5300     get:
5301       tags:
5302         - fhir
5303       description: 'Returns a list of Observation resources.'
5304       parameters:
5305         -
5306           name: _id
5307           in: query
5308           description: 'The uuid for the Observation resource.'
5309           required: false
5310           schema:
5311             type: string
5312         -
5313           name: patient
5314           in: query
5315           description: 'The uuid for the patient.'
5316           required: false
5317           schema:
5318             type: string
5319         -
5320           name: code
5321           in: query
5322           description: 'The code of the Observation resource.'
5323           required: false
5324           schema:
5325             type: string
5326         -
5327           name: category
5328           in: query
5329           description: 'The category of the Observation resource.'
5330           required: false
5331           schema:
5332             type: string
5333         -
5334           name: date
5335           in: query
5336           description: 'The datetime of the Observation resource.'
5337           required: false
5338           schema:
5339             type: string
5340       responses:
5341         '200':
5342           description: 'Standard Response'
5343           content:
5344             application/json:
5345               schema:
5346                 properties:
5347                   'json object': { description: 'FHIR Json object.', type: object }
5348                 type: object
5349                 example:
5350                   meta: { lastUpdated: '2021-09-14T09:13:51' }
5351                   resourceType: Bundle
5352                   type: collection
5353                   total: 0
5354                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Observation' }]
5355         '400':
5356           $ref: '#/components/responses/badrequest'
5357         '401':
5358           $ref: '#/components/responses/unauthorized'
5359       security:
5360         -
5361           openemr_auth: []
5362   '/fhir/Observation/{uuid}':
5363     get:
5364       tags:
5365         - fhir
5366       description: 'Returns a single Observation resource.'
5367       parameters:
5368         -
5369           name: uuid
5370           in: path
5371           description: 'The uuid for the Observation resource.'
5372           required: true
5373           schema:
5374             type: string
5375       responses:
5376         '200':
5377           description: 'Standard Response'
5378           content:
5379             application/json:
5380               schema:
5381                 properties:
5382                   'json object': { description: 'FHIR Json object.', type: object }
5383                 type: object
5384                 example:
5385                   id: 946da61e-0597-485e-9dfd-a87205ea56b3
5386                   meta: { versionId: '1', lastUpdated: '2021-09-20T04:12:16+00:00' }
5387                   resourceType: Observation
5388                   status: final
5389                   category: [{ coding: [{ system: 'http://terminology.hl7.org/CodeSystem/observation-category', code: vital-signs }] }]
5390                   code: { coding: [{ system: 'http://loinc.org', code: 85354-9, display: 'Blood pressure systolic and diastolic' }] }
5391                   subject: { reference: Patient/946da619-c631-431a-a282-487cd6fb7802, type: Patient }
5392                   effectiveDateTime: '2015-08-31T00:00:00+00:00'
5393                   component: [{ code: { coding: [{ system: 'http://loinc.org', code: 8480-6, display: 'Systolic blood pressure' }] }, valueQuantity: { value: 122, unit: 'mm[Hg]', system: 'http://unitsofmeasure.org', code: 'mm[Hg]' } }, { code: { coding: [{ system: 'http://loinc.org', code: 8462-4, display: 'Diastolic blood pressure' }] }, valueQuantity: { value: 77, unit: 'mm[Hg]', system: 'http://unitsofmeasure.org', code: 'mm[Hg]' } }]
5394         '400':
5395           $ref: '#/components/responses/badrequest'
5396         '401':
5397           $ref: '#/components/responses/unauthorized'
5398         '404':
5399           $ref: '#/components/responses/uuidnotfound'
5400       security:
5401         -
5402           openemr_auth: []
5403   /fhir/Organization:
5404     get:
5405       tags:
5406         - fhir
5407       description: 'Returns a list of Organization resources.'
5408       parameters:
5409         -
5410           name: _id
5411           in: query
5412           description: 'The uuid for the Organization resource.'
5413           required: false
5414           schema:
5415             type: string
5416         -
5417           name: name
5418           in: query
5419           description: 'The name of the Organization resource.'
5420           required: false
5421           schema:
5422             type: string
5423         -
5424           name: email
5425           in: query
5426           description: 'The email of the Organization resource.'
5427           required: false
5428           schema:
5429             type: string
5430         -
5431           name: phone
5432           in: query
5433           description: 'The phone of the Organization resource.'
5434           required: false
5435           schema:
5436             type: string
5437         -
5438           name: telecom
5439           in: query
5440           description: 'The telecom of the Organization resource.'
5441           required: false
5442           schema:
5443             type: string
5444         -
5445           name: address
5446           in: query
5447           description: 'The address of the Organization resource.'
5448           required: false
5449           schema:
5450             type: string
5451         -
5452           name: address-city
5453           in: query
5454           description: 'The address-city of the Organization resource.'
5455           required: false
5456           schema:
5457             type: string
5458         -
5459           name: address-postalcode
5460           in: query
5461           description: 'The address-postalcode of the Organization resource.'
5462           required: false
5463           schema:
5464             type: string
5465         -
5466           name: address-state
5467           in: query
5468           description: 'The address-state of the Organization resource.'
5469           required: false
5470           schema:
5471             type: string
5472       responses:
5473         '200':
5474           description: 'Standard Response'
5475           content:
5476             application/json:
5477               schema:
5478                 properties:
5479                   'json object': { description: 'FHIR Json object.', type: object }
5480                 type: object
5481                 example:
5482                   meta: { lastUpdated: '2021-09-14T09:13:51' }
5483                   resourceType: Bundle
5484                   type: collection
5485                   total: 0
5486                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Organization' }]
5487         '400':
5488           $ref: '#/components/responses/badrequest'
5489         '401':
5490           $ref: '#/components/responses/unauthorized'
5491       security:
5492         -
5493           openemr_auth: []
5494     post:
5495       tags:
5496         - fhir
5497       description: 'Adds a Organization resource.'
5498       requestBody:
5499         required: true
5500         content:
5501           application/json:
5502             schema:
5503               description: 'The json object for the Organization resource.'
5504               type: object
5505             example:
5506               id: 95f0e672-be37-4c73-95c9-649c2d200018
5507               meta:
5508                 versionId: '1'
5509                 lastUpdated: '2022-03-30T07:43:23+00:00'
5510               resourceType: Organization
5511               text:
5512                 status: generated
5513                 div: '<div xmlns=''http://www.w3.org/1999/xhtml''> <p>Your Clinic Name Here</p></div>'
5514               identifier:
5515                 -
5516                   system: 'http://hl7.org/fhir/sid/us-npi'
5517                   value: '1234567890'
5518               active: true
5519               type:
5520                 -
5521                   coding: [{ system: 'http://terminology.hl7.org/CodeSystem/organization-type', code: prov, display: 'Healthcare Provider' }]
5522               name: 'Your Clinic Name Here Hey'
5523               telecom:
5524                 -
5525                   system: phone
5526                   value: 000-000-0000
5527                   use: work
5528                 -
5529                   system: fax
5530                   value: 000-000-0000
5531                   use: work
5532               address:
5533                 - null
5534       responses:
5535         '200':
5536           description: 'Standard Response'
5537           content:
5538             application/json:
5539               schema:
5540                 properties:
5541                   'json object': { description: 'FHIR Json object.', type: object }
5542                 type: object
5543                 example:
5544                   id: 95f0e672-be37-4c73-95c9-649c2d200018
5545                   meta: { versionId: '1', lastUpdated: '2022-03-30T07:43:23+00:00' }
5546                   resourceType: Organization
5547                   text: { status: generated, div: '<div xmlns=''http://www.w3.org/1999/xhtml''> <p>Your Clinic Name Here</p></div>' }
5548                   identifier: [{ system: 'http://hl7.org/fhir/sid/us-npi', value: '1234567890' }]
5549                   active: true
5550                   type: [{ coding: [{ system: 'http://terminology.hl7.org/CodeSystem/organization-type', code: prov, display: 'Healthcare Provider' }] }]
5551                   name: 'Your Clinic Name Here Now'
5552                   telecom: [{ system: phone, value: 000-000-0000, use: work }, { system: fax, value: 000-000-0000, use: work }]
5553                   address: [null]
5554         '400':
5555           $ref: '#/components/responses/badrequest'
5556         '401':
5557           $ref: '#/components/responses/unauthorized'
5558       security:
5559         -
5560           openemr_auth: []
5561   '/fhir/Organization/{uuid}':
5562     get:
5563       tags:
5564         - fhir
5565       description: 'Returns a single Organization resource.'
5566       parameters:
5567         -
5568           name: uuid
5569           in: path
5570           description: 'The uuid for the Organization resource.'
5571           required: true
5572           schema:
5573             type: string
5574       responses:
5575         '200':
5576           description: 'Standard Response'
5577           content:
5578             application/json:
5579               schema:
5580                 properties:
5581                   'json object': { description: 'FHIR Json object.', type: object }
5582                 type: object
5583                 example:
5584                   id: 95f0e672-be37-4c73-95c9-649c2d200018
5585                   meta: { versionId: '1', lastUpdated: '2022-03-30T07:43:23+00:00' }
5586                   resourceType: Organization
5587                   text: { status: generated, div: '<div xmlns=''http://www.w3.org/1999/xhtml''> <p>Your Clinic Name Here</p></div>' }
5588                   identifier: [{ system: 'http://hl7.org/fhir/sid/us-npi', value: '1234567890' }]
5589                   active: true
5590                   type: [{ coding: [{ system: 'http://terminology.hl7.org/CodeSystem/organization-type', code: prov, display: 'Healthcare Provider' }] }]
5591                   name: 'Your Clinic Name Here'
5592                   telecom: [{ system: phone, value: 000-000-0000, use: work }, { system: fax, value: 000-000-0000, use: work }]
5593                   address: [null]
5594         '400':
5595           $ref: '#/components/responses/badrequest'
5596         '401':
5597           $ref: '#/components/responses/unauthorized'
5598         '404':
5599           $ref: '#/components/responses/uuidnotfound'
5600       security:
5601         -
5602           openemr_auth: []
5603     put:
5604       tags:
5605         - fhir
5606       description: 'Modifies a Organization resource.'
5607       parameters:
5608         -
5609           name: uuid
5610           in: path
5611           description: 'The uuid for the organization.'
5612           required: true
5613           schema:
5614             type: string
5615       requestBody:
5616         required: true
5617         content:
5618           application/json:
5619             schema:
5620               description: 'The json object for the Organization resource.'
5621               type: object
5622             example:
5623               id: 95f0e672-be37-4c73-95c9-649c2d200018
5624               meta:
5625                 versionId: '1'
5626                 lastUpdated: '2022-03-30T07:43:23+00:00'
5627               resourceType: Organization
5628               text:
5629                 status: generated
5630                 div: '<div xmlns=''http://www.w3.org/1999/xhtml''> <p>Your Clinic Name Here</p></div>'
5631               identifier:
5632                 -
5633                   system: 'http://hl7.org/fhir/sid/us-npi'
5634                   value: '1234567890'
5635               active: true
5636               type:
5637                 -
5638                   coding: [{ system: 'http://terminology.hl7.org/CodeSystem/organization-type', code: prov, display: 'Healthcare Provider' }]
5639               name: 'Your Clinic Name Here'
5640               telecom:
5641                 -
5642                   system: phone
5643                   value: 000-000-0000
5644                   use: work
5645                 -
5646                   system: fax
5647                   value: 000-000-0000
5648                   use: work
5649               address:
5650                 - null
5651       responses:
5652         '201':
5653           description: 'Standard Response'
5654           content:
5655             application/json:
5656               schema:
5657                 example:
5658                   id: 14
5659                   uuid: 95f217c1-258c-44ca-bf11-909dce369574
5660         '400':
5661           $ref: '#/components/responses/badrequest'
5662         '401':
5663           $ref: '#/components/responses/unauthorized'
5664       security:
5665         -
5666           openemr_auth: []
5667   /fhir/Patient:
5668     get:
5669       tags:
5670         - fhir
5671       description: 'Returns a list of Patient resources.'
5672       parameters:
5673         -
5674           name: _id
5675           in: query
5676           description: 'The uuid for the Patient resource.'
5677           required: false
5678           schema:
5679             type: string
5680         -
5681           name: identifier
5682           in: query
5683           description: 'The identifier of the Patient resource.'
5684           required: false
5685           schema:
5686             type: string
5687         -
5688           name: name
5689           in: query
5690           description: 'The name of the Patient resource.'
5691           required: false
5692           schema:
5693             type: string
5694         -
5695           name: birthdate
5696           in: query
5697           description: 'The birthdate of the Patient resource.'
5698           required: false
5699           schema:
5700             type: string
5701         -
5702           name: gender
5703           in: query
5704           description: 'The gender of the Patient resource.'
5705           required: false
5706           schema:
5707             type: string
5708         -
5709           name: address
5710           in: query
5711           description: 'The address of the Patient resource.'
5712           required: false
5713           schema:
5714             type: string
5715         -
5716           name: address-city
5717           in: query
5718           description: 'The address-city of the Patient resource.'
5719           required: false
5720           schema:
5721             type: string
5722         -
5723           name: address-postalcode
5724           in: query
5725           description: 'The address-postalcode of the Patient resource.'
5726           required: false
5727           schema:
5728             type: string
5729         -
5730           name: address-state
5731           in: query
5732           description: 'The address-state of the Patient resource.'
5733           required: false
5734           schema:
5735             type: string
5736         -
5737           name: email
5738           in: query
5739           description: 'The email of the Patient resource.'
5740           required: false
5741           schema:
5742             type: string
5743         -
5744           name: family
5745           in: query
5746           description: 'The family name of the Patient resource.'
5747           required: false
5748           schema:
5749             type: string
5750         -
5751           name: given
5752           in: query
5753           description: 'The given name of the Patient resource.'
5754           required: false
5755           schema:
5756             type: string
5757         -
5758           name: phone
5759           in: query
5760           description: 'The phone number of the Patient resource.'
5761           required: false
5762           schema:
5763             type: string
5764         -
5765           name: telecom
5766           in: query
5767           description: 'The fax number of the Patient resource.'
5768           required: false
5769           schema:
5770             type: string
5771         -
5772           $ref: '#/components/parameters/_lastUpdated'
5773       responses:
5774         '200':
5775           description: 'Standard Response'
5776           content:
5777             application/json:
5778               schema:
5779                 properties:
5780                   'json object': { description: 'FHIR Json object.', type: object }
5781                 type: object
5782                 example:
5783                   meta: { lastUpdated: '2021-09-14T09:13:51' }
5784                   resourceType: Bundle
5785                   type: collection
5786                   total: 0
5787                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Patient' }]
5788         '400':
5789           $ref: '#/components/responses/badrequest'
5790         '401':
5791           $ref: '#/components/responses/unauthorized'
5792       security:
5793         -
5794           openemr_auth: []
5795     post:
5796       tags:
5797         - fhir
5798       description: 'Adds a Patient resource.'
5799       requestBody:
5800         required: true
5801         content:
5802           application/json:
5803             schema:
5804               description: 'The json object for the Patient resource.'
5805               type: object
5806             example:
5807               id: 95f22ff4-dd25-4290-8b52-1dd2fedf8e54
5808               meta:
5809                 versionId: '1'
5810                 lastUpdated: '2022-03-31T02:48:28+00:00'
5811               resourceType: Patient
5812               text:
5813                 status: generated
5814                 div: '<div xmlns=''http://www.w3.org/1999/xhtml''> <p>Brenda Smith</p></div>'
5815               extension:
5816                 -
5817                   valueCode: F
5818                   url: 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-birthsex'
5819                 -
5820                   extension: [{ valueCoding: { system: 'http://terminology.hl7.org/CodeSystem/v3-NullFlavor', code: UNK, display: Unknown }, url: ombCategory }, { valueString: Unknown, url: text }]
5821                   url: 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-race'
5822               identifier:
5823                 -
5824                   use: official
5825                   type: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/v2-0203', code: PT }] }
5826                   system: 'http://terminology.hl7.org/CodeSystem/v2-0203'
5827                   value: '1'
5828               active: true
5829               name:
5830                 -
5831                   use: official
5832                   family: Smith
5833                   given: [Brenda]
5834               gender: female
5835               birthDate: '2017-03-10'
5836               communication:
5837                 -
5838                   language: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/data-absent-reason', code: unknown, display: Unknown }] }
5839       responses:
5840         '200':
5841           description: 'Standard Response'
5842           content:
5843             application/json:
5844               schema:
5845                 properties:
5846                   'json object': { description: 'FHIR Json object.', type: object }
5847                 type: object
5848                 example:
5849                   id: 95f22ff4-dd25-4290-8b52-1dd2fedf8e54
5850                   meta: { versionId: '1', lastUpdated: '2022-03-31T02:48:28+00:00' }
5851                   resourceType: Patient
5852                   text: { status: generated, div: '<div xmlns=''http://www.w3.org/1999/xhtml''> <p>Brenda Smith</p></div>' }
5853                   extension: [{ valueCode: F, url: 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-birthsex' }, { extension: [{ valueCoding: { system: 'http://terminology.hl7.org/CodeSystem/v3-NullFlavor', code: UNK, display: Unknown }, url: ombCategory }, { valueString: Unknown, url: text }], url: 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-race' }]
5854                   identifier: [{ use: official, type: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/v2-0203', code: PT }] }, system: 'http://terminology.hl7.org/CodeSystem/v2-0203', value: '1' }]
5855                   active: true
5856                   name: [{ use: official, family: Smith, given: [Brenda] }]
5857                   gender: female
5858                   birthDate: '2017-03-10'
5859                   communication: [{ language: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/data-absent-reason', code: unknown, display: Unknown }] } }]
5860         '400':
5861           $ref: '#/components/responses/badrequest'
5862         '401':
5863           $ref: '#/components/responses/unauthorized'
5864       security:
5865         -
5866           openemr_auth: []
5867   '/fhir/Patient/{uuid}':
5868     get:
5869       tags:
5870         - fhir
5871       description: 'Returns a single Patient resource.'
5872       parameters:
5873         -
5874           name: uuid
5875           in: path
5876           description: 'The uuid for the Patient resource.'
5877           required: true
5878           schema:
5879             type: string
5880       responses:
5881         '200':
5882           description: 'Standard Response'
5883           content:
5884             application/json:
5885               schema:
5886                 properties:
5887                   'json object': { description: 'FHIR Json object.', type: object }
5888                 type: object
5889                 example:
5890                   id: 946da617-1a4a-4b2c-ae66-93b84377cb1e
5891                   meta: { versionId: '1', lastUpdated: '2021-09-21T17:08:03+00:00' }
5892                   resourceType: Patient
5893                   text: { status: generated, div: '<div xmlns="http://www.w3.org/1999/xhtml"> <p>Aurore252 Von197</p></div>' }
5894                   extension: [{ valueCode: F, url: 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-birthsex' }, { extension: [{ valueCoding: { system: 'urn:oid:2.16.840.1.113883.6.238', code: 1006-6, display: Abenaki }, url: ombCategory }, { valueString: Abenaki, url: text }], url: 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-race' }, { extension: [{ valueString: 'Declined To Specify', url: text }], url: 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-ethnicity' }]
5895                   identifier: [{ use: official, type: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/v2-0203', code: PT }] }, system: 'http://terminology.hl7.org/CodeSystem/v2-0203', value: '1' }]
5896                   active: true
5897                   name: [{ use: official, family: Von197, given: [Aurore252] }]
5898                   gender: female
5899                   birthDate: '1970-07-03'
5900                   address: [{ line: ['245 Crona Wall'], city: Boston, state: Massachusetts, postalCode: '02215', period: { start: '2020-09-21T17:08:03.532+00:00' } }]
5901                   communication: [{ language: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/data-absent-reason', code: unknown, display: Unknown }] } }]
5902         '400':
5903           $ref: '#/components/responses/badrequest'
5904         '401':
5905           $ref: '#/components/responses/unauthorized'
5906         '404':
5907           $ref: '#/components/responses/uuidnotfound'
5908       security:
5909         -
5910           openemr_auth: []
5911     put:
5912       tags:
5913         - fhir
5914       description: 'Modifies a Patient resource.'
5915       parameters:
5916         -
5917           name: uuid
5918           in: path
5919           description: 'The uuid for the Patient resource.'
5920           required: true
5921           schema:
5922             type: string
5923       requestBody:
5924         required: true
5925         content:
5926           application/json:
5927             schema:
5928               description: 'The json object for the Patient resource.'
5929               type: object
5930             example:
5931               id: 95f22ff4-dd25-4290-8b52-1dd2fedf8e54
5932               meta:
5933                 versionId: '1'
5934                 lastUpdated: '2022-03-31T02:48:28+00:00'
5935               resourceType: Patient
5936               text:
5937                 status: generated
5938                 div: '<div xmlns=''http://www.w3.org/1999/xhtml''> <p>Brenda Smith</p></div>'
5939               extension:
5940                 -
5941                   valueCode: F
5942                   url: 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-birthsex'
5943                 -
5944                   extension: [{ valueCoding: { system: 'http://terminology.hl7.org/CodeSystem/v3-NullFlavor', code: UNK, display: Unknown }, url: ombCategory }, { valueString: Unknown, url: text }]
5945                   url: 'http://hl7.org/fhir/us/core/StructureDefinition/us-core-race'
5946               identifier:
5947                 -
5948                   use: official
5949                   type: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/v2-0203', code: PT }] }
5950                   system: 'http://terminology.hl7.org/CodeSystem/v2-0203'
5951                   value: '1'
5952               active: true
5953               name:
5954                 -
5955                   use: official
5956                   family: Smith
5957                   given: [Brenda]
5958               gender: female
5959               birthDate: '2017-03-10'
5960               communication:
5961                 -
5962                   language: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/data-absent-reason', code: unknown, display: Unknown }] }
5963       responses:
5964         '201':
5965           description: 'Standard Response'
5966           content:
5967             application/json:
5968               schema:
5969                 example:
5970                   id: 2
5971                   uuid: 95f2ad04-5834-4243-8838-e396a7faadbf
5972         '400':
5973           $ref: '#/components/responses/badrequest'
5974         '401':
5975           $ref: '#/components/responses/unauthorized'
5976       security:
5977         -
5978           openemr_auth: []
5979   /fhir/Patient/$export:
5980     get:
5981       tags:
5982         - fhir
5983       description: 'The BULK FHIR Exports documentation can be found at <a href=''https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API'' target=''_blank'' rel=''noopener''>https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API</a>'
5984       responses:
5985         '200':
5986           description: 'The BULK FHIR Exports documentation can be found at <a href=''https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API'' target=''_blank'' rel=''noopener''>https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API</a>'
5987         '400':
5988           $ref: '#/components/responses/badrequest'
5989         '401':
5990           $ref: '#/components/responses/unauthorized'
5991       security:
5992         -
5993           openemr_auth: []
5994   /fhir/Person:
5995     get:
5996       tags:
5997         - fhir
5998       description: 'Returns a list of Person resources.'
5999       parameters:
6000         -
6001           name: name
6002           in: query
6003           description: 'The name of the Person resource.'
6004           required: false
6005           schema:
6006             type: string
6007         -
6008           name: active
6009           in: query
6010           description: 'The active status of the Person resource.'
6011           required: false
6012           schema:
6013             type: string
6014         -
6015           name: address
6016           in: query
6017           description: 'The address of the Person resource.'
6018           required: false
6019           schema:
6020             type: string
6021         -
6022           name: address-city
6023           in: query
6024           description: 'The address-city of the Person resource.'
6025           required: false
6026           schema:
6027             type: string
6028         -
6029           name: address-postalcode
6030           in: query
6031           description: 'The address-postalcode of the Person resource.'
6032           required: false
6033           schema:
6034             type: string
6035         -
6036           name: address-state
6037           in: query
6038           description: 'The address-state of the Person resource.'
6039           required: false
6040           schema:
6041             type: string
6042         -
6043           name: email
6044           in: query
6045           description: 'The email of the Person resource.'
6046           required: false
6047           schema:
6048             type: string
6049         -
6050           name: family
6051           in: query
6052           description: 'The family name of the Person resource.'
6053           required: false
6054           schema:
6055             type: string
6056         -
6057           name: given
6058           in: query
6059           description: 'The given name of the Person resource.'
6060           required: false
6061           schema:
6062             type: string
6063         -
6064           name: phone
6065           in: query
6066           description: 'The phone number of the Person resource.'
6067           required: false
6068           schema:
6069             type: string
6070         -
6071           name: telecom
6072           in: query
6073           description: 'The fax number of the Person resource.'
6074           required: false
6075           schema:
6076             type: string
6077       responses:
6078         '200':
6079           description: 'Standard Response'
6080           content:
6081             application/json:
6082               schema:
6083                 properties:
6084                   'json object': { description: 'FHIR Json object.', type: object }
6085                 type: object
6086                 example:
6087                   meta: { lastUpdated: '2021-09-14T09:13:51' }
6088                   resourceType: Bundle
6089                   type: collection
6090                   total: 0
6091                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Person' }]
6092         '400':
6093           $ref: '#/components/responses/badrequest'
6094         '401':
6095           $ref: '#/components/responses/unauthorized'
6096       security:
6097         -
6098           openemr_auth: []
6099   '/fhir/Person/{uuid}':
6100     get:
6101       tags:
6102         - fhir
6103       description: 'Returns a single Person resource.'
6104       parameters:
6105         -
6106           name: uuid
6107           in: path
6108           description: 'The uuid for the Person resource.'
6109           required: true
6110           schema:
6111             type: string
6112       responses:
6113         '200':
6114           description: 'Standard Response'
6115           content:
6116             application/json:
6117               schema:
6118                 properties:
6119                   'json object': { description: 'FHIR Json object.', type: object }
6120                 type: object
6121                 example:
6122                   id: 960c7cd6-187a-4119-8cd4-85389d80efb9
6123                   meta: { versionId: '1', lastUpdated: '2022-04-13T08:57:32+00:00' }
6124                   resourceType: Person
6125                   text: { status: generated, div: '<div xmlns=''http://www.w3.org/1999/xhtml''> <p>Administrator Administrator</p></div>' }
6126                   name: [{ use: official, family: Administrator, given: [Administrator, Larry] }]
6127                   telecom: [{ system: phone, value: '1234567890', use: home }, { system: phone, value: '1234567890', use: work }, { system: phone, value: '1234567890', use: mobile }, { system: email, value: hey@hey.com, use: home }]
6128                   address: [{ line: ['123 Lane Street'], city: Bellevue, state: WA, period: { start: '2021-04-13T08:57:32.146+00:00' } }]
6129                   active: true
6130         '400':
6131           $ref: '#/components/responses/badrequest'
6132         '401':
6133           $ref: '#/components/responses/unauthorized'
6134         '404':
6135           $ref: '#/components/responses/uuidnotfound'
6136       security:
6137         -
6138           openemr_auth: []
6139   /fhir/Practitioner:
6140     get:
6141       tags:
6142         - fhir
6143       description: 'Returns a list of Practitioner resources.'
6144       parameters:
6145         -
6146           name: _id
6147           in: query
6148           description: 'The uuid for the Practitioner resource.'
6149           required: false
6150           schema:
6151             type: string
6152         -
6153           name: name
6154           in: query
6155           description: 'The name of the Practitioner resource.'
6156           required: false
6157           schema:
6158             type: string
6159         -
6160           name: active
6161           in: query
6162           description: 'The active status of the Practitioner resource.'
6163           required: false
6164           schema:
6165             type: string
6166         -
6167           name: address
6168           in: query
6169           description: 'The address of the Practitioner resource.'
6170           required: false
6171           schema:
6172             type: string
6173         -
6174           name: address-city
6175           in: query
6176           description: 'The address-city of the Practitioner resource.'
6177           required: false
6178           schema:
6179             type: string
6180         -
6181           name: address-postalcode
6182           in: query
6183           description: 'The address-postalcode of the Practitioner resource.'
6184           required: false
6185           schema:
6186             type: string
6187         -
6188           name: address-state
6189           in: query
6190           description: 'The address-state of the Practitioner resource.'
6191           required: false
6192           schema:
6193             type: string
6194         -
6195           name: email
6196           in: query
6197           description: 'The email of the Practitioner resource.'
6198           required: false
6199           schema:
6200             type: string
6201         -
6202           name: family
6203           in: query
6204           description: 'The family name of the Practitioner resource.'
6205           required: false
6206           schema:
6207             type: string
6208         -
6209           name: given
6210           in: query
6211           description: 'The given name of the Practitioner resource.'
6212           required: false
6213           schema:
6214             type: string
6215         -
6216           name: phone
6217           in: query
6218           description: 'The phone number of the Practitioner resource.'
6219           required: false
6220           schema:
6221             type: string
6222         -
6223           name: telecom
6224           in: query
6225           description: 'The fax number of the Practitioner resource.'
6226           required: false
6227           schema:
6228             type: string
6229       responses:
6230         '200':
6231           description: 'Standard Response'
6232           content:
6233             application/json:
6234               schema:
6235                 properties:
6236                   'json object': { description: 'FHIR Json object.', type: object }
6237                 type: object
6238                 example:
6239                   meta: { lastUpdated: '2021-09-14T09:13:51' }
6240                   resourceType: Bundle
6241                   type: collection
6242                   total: 0
6243                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Practitioner' }]
6244         '400':
6245           $ref: '#/components/responses/badrequest'
6246         '401':
6247           $ref: '#/components/responses/unauthorized'
6248       security:
6249         -
6250           openemr_auth: []
6251     post:
6252       tags:
6253         - fhir
6254       description: 'Adds a Practitioner resources.'
6255       requestBody:
6256         required: true
6257         content:
6258           application/json:
6259             schema:
6260               description: 'The json object for the Practitioner resource.'
6261               type: object
6262             example:
6263               id: 9473b0cf-e969-4eaa-8044-51037767fa4f
6264               meta:
6265                 versionId: '1'
6266                 lastUpdated: '2021-09-21T17:41:57+00:00'
6267               resourceType: Practitioner
6268               text:
6269                 status: generated
6270                 div: '<div xmlns="http://www.w3.org/1999/xhtml"> <p>Billy Smith</p></div>'
6271               identifier:
6272                 -
6273                   system: 'http://hl7.org/fhir/sid/us-npi'
6274                   value: '11223344554543'
6275               active: true
6276               name:
6277                 -
6278                   use: official
6279                   family: Smith
6280                   given: [Danny]
6281       responses:
6282         '200':
6283           description: 'Standard Response'
6284           content:
6285             application/json:
6286               schema:
6287                 properties:
6288                   'json object': { description: 'FHIR Json object.', type: object }
6289                 type: object
6290                 example:
6291                   id: 9473b0cf-e969-4eaa-8044-51037767fa4f
6292                   meta: { versionId: '1', lastUpdated: '2021-09-21T17:41:57+00:00' }
6293                   resourceType: Practitioner
6294                   text: { status: generated, div: '<div xmlns="http://www.w3.org/1999/xhtml"> <p>Billy Smith</p></div>' }
6295                   identifier: [{ system: 'http://hl7.org/fhir/sid/us-npi', value: '11223344554543' }]
6296                   active: true
6297                   name: [{ use: official, family: Smith, given: [Danny] }]
6298         '400':
6299           $ref: '#/components/responses/badrequest'
6300         '401':
6301           $ref: '#/components/responses/unauthorized'
6302       security:
6303         -
6304           openemr_auth: []
6305   '/fhir/Practitioner/{uuid}':
6306     get:
6307       tags:
6308         - fhir
6309       description: 'Returns a single Practitioner resource.'
6310       parameters:
6311         -
6312           name: uuid
6313           in: path
6314           description: 'The uuid for the Practitioner resource.'
6315           required: true
6316           schema:
6317             type: string
6318       responses:
6319         '200':
6320           description: 'Standard Response'
6321           content:
6322             application/json:
6323               schema:
6324                 properties:
6325                   'json object': { description: 'FHIR Json object.', type: object }
6326                 type: object
6327                 example:
6328                   id: 9473b0cf-e969-4eaa-8044-51037767fa4f
6329                   meta: { versionId: '1', lastUpdated: '2021-09-21T17:41:57+00:00' }
6330                   resourceType: Practitioner
6331                   text: { status: generated, div: '<div xmlns="http://www.w3.org/1999/xhtml"> <p>Billy Smith</p></div>' }
6332                   identifier: [{ system: 'http://hl7.org/fhir/sid/us-npi', value: '11223344554543' }]
6333                   active: true
6334                   name: [{ use: official, family: Smith, given: [Billy] }]
6335         '400':
6336           $ref: '#/components/responses/badrequest'
6337         '401':
6338           $ref: '#/components/responses/unauthorized'
6339         '404':
6340           $ref: '#/components/responses/uuidnotfound'
6341       security:
6342         -
6343           openemr_auth: []
6344     put:
6345       tags:
6346         - fhir
6347       description: 'Modify a Practitioner resource.'
6348       parameters:
6349         -
6350           name: uuid
6351           in: path
6352           description: 'The uuid for the Practitioner resource.'
6353           required: true
6354           schema:
6355             type: string
6356       requestBody:
6357         required: true
6358         content:
6359           application/json:
6360             schema:
6361               description: 'The json object for the Practitioner resource.'
6362               type: object
6363             example:
6364               id: 9473b0cf-e969-4eaa-8044-51037767fa4f
6365               meta:
6366                 versionId: '1'
6367                 lastUpdated: '2021-09-21T17:41:57+00:00'
6368               resourceType: Practitioner
6369               text:
6370                 status: generated
6371                 div: '<div xmlns="http://www.w3.org/1999/xhtml"> <p>Billy Smith</p></div>'
6372               identifier:
6373                 -
6374                   system: 'http://hl7.org/fhir/sid/us-npi'
6375                   value: '11223344554543'
6376               active: true
6377               name:
6378                 -
6379                   use: official
6380                   family: Smith
6381                   given: [Billy]
6382       responses:
6383         '201':
6384           description: 'Standard Response'
6385           content:
6386             application/json:
6387               schema:
6388                 example:
6389                   id: 5
6390                   uuid: 95f294d7-e14c-441d-81a6-309fe369ee21
6391         '400':
6392           $ref: '#/components/responses/badrequest'
6393         '401':
6394           $ref: '#/components/responses/unauthorized'
6395       security:
6396         -
6397           openemr_auth: []
6398   /fhir/PractitionerRole:
6399     get:
6400       tags:
6401         - fhir
6402       description: 'Returns a list of PractitionerRole resources.'
6403       parameters:
6404         -
6405           name: specialty
6406           in: query
6407           description: 'The specialty of the PractitionerRole resource.'
6408           required: false
6409           schema:
6410             type: string
6411         -
6412           name: practitioner
6413           in: query
6414           description: 'The practitioner of the PractitionerRole resource.'
6415           required: false
6416           schema:
6417             type: string
6418       responses:
6419         '200':
6420           description: 'Standard Response'
6421           content:
6422             application/json:
6423               schema:
6424                 properties:
6425                   'json object': { description: 'FHIR Json object.', type: object }
6426                 type: object
6427                 example:
6428                   meta: { lastUpdated: '2021-09-14T09:13:51' }
6429                   resourceType: Bundle
6430                   type: collection
6431                   total: 0
6432                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/PractitionerRole' }]
6433         '400':
6434           $ref: '#/components/responses/badrequest'
6435         '401':
6436           $ref: '#/components/responses/unauthorized'
6437       security:
6438         -
6439           openemr_auth: []
6440   '/fhir/PractitionerRole/{uuid}':
6441     get:
6442       tags:
6443         - fhir
6444       description: 'Returns a single PractitionerRole resource.'
6445       parameters:
6446         -
6447           name: uuid
6448           in: path
6449           description: 'The uuid for the PractitionerRole resource.'
6450           required: true
6451           schema:
6452             type: string
6453       responses:
6454         '200':
6455           description: 'Standard Response'
6456           content:
6457             application/json:
6458               schema:
6459                 properties:
6460                   'json object': { description: 'FHIR Json object.', type: object }
6461                 type: object
6462                 example:
6463                   id: 960c806f-9463-482e-b228-67b5be1fed55
6464                   meta: { versionId: '1', lastUpdated: '2022-04-13T06:18:17+00:00' }
6465                   resourceType: PractitionerRole
6466                   practitioner: { reference: Practitioner/960c7cd6-187a-4119-8cd4-85389d80efb9, display: 'Administrator Administrator' }
6467                   organization: { reference: Organization/960c7cc6-b4ae-49bc-877b-1a2913271c43, display: 'Your Clinic Name Here' }
6468                   code: [{ coding: [102L00000X], text: Psychoanalyst }, { coding: [101Y00000X], text: Counselor }]
6469         '400':
6470           $ref: '#/components/responses/badrequest'
6471         '401':
6472           $ref: '#/components/responses/unauthorized'
6473         '404':
6474           $ref: '#/components/responses/uuidnotfound'
6475       security:
6476         -
6477           openemr_auth: []
6478   /fhir/Procedure:
6479     get:
6480       tags:
6481         - fhir
6482       description: 'Returns a list of Procedure resources.'
6483       parameters:
6484         -
6485           name: _id
6486           in: query
6487           description: 'The uuid for the Procedure resource.'
6488           required: false
6489           schema:
6490             type: string
6491         -
6492           name: patient
6493           in: query
6494           description: 'The uuid for the patient.'
6495           required: false
6496           schema:
6497             type: string
6498         -
6499           name: date
6500           in: query
6501           description: 'The datetime of the Procedure resource.'
6502           required: false
6503           schema:
6504             type: string
6505       responses:
6506         '200':
6507           description: 'Standard Response'
6508           content:
6509             application/json:
6510               schema:
6511                 properties:
6512                   'json object': { description: 'FHIR Json object.', type: object }
6513                 type: object
6514                 example:
6515                   meta: { lastUpdated: '2021-09-14T09:13:51' }
6516                   resourceType: Bundle
6517                   type: collection
6518                   total: 0
6519                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Procedure' }]
6520         '400':
6521           $ref: '#/components/responses/badrequest'
6522         '401':
6523           $ref: '#/components/responses/unauthorized'
6524       security:
6525         -
6526           openemr_auth: []
6527   '/fhir/Procedure/{uuid}':
6528     get:
6529       tags:
6530         - fhir
6531       description: 'Returns a single Procedure resource.'
6532       parameters:
6533         -
6534           name: uuid
6535           in: path
6536           description: 'The uuid for the Procedure resource.'
6537           required: true
6538           schema:
6539             type: string
6540       responses:
6541         '200':
6542           description: 'Standard Response'
6543           content:
6544             application/json:
6545               schema:
6546                 properties:
6547                   'json object': { description: 'FHIR Json object.', type: object }
6548                 type: object
6549                 example:
6550                   id: 95e9d3fb-fe7b-448a-aa60-d40b11b486a5
6551                   meta: { versionId: '1', lastUpdated: '2022-03-26T17:20:14+00:00' }
6552                   resourceType: Procedure
6553                   status: in-progress
6554                   subject: { reference: Patient/95e8d830-3068-48cf-930a-2fefb18c2bcf, type: Patient }
6555         '400':
6556           $ref: '#/components/responses/badrequest'
6557         '401':
6558           $ref: '#/components/responses/unauthorized'
6559         '404':
6560           $ref: '#/components/responses/uuidnotfound'
6561       security:
6562         -
6563           openemr_auth: []
6564   '/fhir/Provenance/{uuid}':
6565     get:
6566       tags:
6567         - fhir
6568       description: 'Returns a single Provenance resource.'
6569       parameters:
6570         -
6571           name: uuid
6572           in: path
6573           description: 'The id for the Provenance resource. Format is \<resource name\>:\<uuid\> (Example: AllergyIntolerance:95ea43f3-1066-4bc7-b224-6c23b985f145).'
6574           required: true
6575           schema:
6576             type: string
6577       responses:
6578         '200':
6579           description: 'Standard Response'
6580           content:
6581             application/json:
6582               schema:
6583                 properties:
6584                   'json object': { description: 'FHIR Json object.', type: object }
6585                 type: object
6586                 example:
6587                   id: 'AllergyIntolerance:95ea43f3-1066-4bc7-b224-6c23b985f145'
6588                   resourceType: Provenance
6589                   target: [{ reference: AllergyIntolerance/95ea43f3-1066-4bc7-b224-6c23b985f145, type: AllergyIntolerance }]
6590                   recorded: '2022-03-26T22:43:30+00:00'
6591                   agent: { '0': { type: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/provenance-participant-type', code: author, display: Author }] }, who: { reference: Organization/95e8d810-7e55-44aa-bb48-fecd5b0d88c7, type: Organization }, onBehalfOf: { reference: Organization/95e8d810-7e55-44aa-bb48-fecd5b0d88c7, type: Organization } }, '1': { type: { coding: [{ system: 'http://hl7.org/fhir/us/core/CodeSystem/us-core-provenance-participant-type', code: transmitter, display: Transmitter }] } }, who: { reference: Organization/95e8d810-7e55-44aa-bb48-fecd5b0d88c7, type: Organization }, onBehalfOf: { reference: Organization/95e8d810-7e55-44aa-bb48-fecd5b0d88c7, type: Organization } }
6592         '400':
6593           $ref: '#/components/responses/badrequest'
6594         '401':
6595           $ref: '#/components/responses/unauthorized'
6596         '404':
6597           $ref: '#/components/responses/uuidnotfound'
6598       security:
6599         -
6600           openemr_auth: []
6601   /fhir/Provenance:
6602     get:
6603       tags:
6604         - fhir
6605       description: 'Returns a list of Provenance resources.'
6606       parameters:
6607         -
6608           name: _id
6609           in: query
6610           description: 'The id for the Provenance resource. Format is \<resource name\>:\<uuid\> (Example: AllergyIntolerance:95ea43f3-1066-4bc7-b224-6c23b985f145).'
6611           required: false
6612           schema:
6613             type: string
6614       responses:
6615         '200':
6616           description: 'Standard Response'
6617           content:
6618             application/json:
6619               schema:
6620                 properties:
6621                   'json object': { description: 'FHIR Json object.', type: object }
6622                 type: object
6623                 example:
6624                   meta: { lastUpdated: '2021-09-14T09:13:51' }
6625                   resourceType: Bundle
6626                   type: collection
6627                   total: 0
6628                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Provenance' }]
6629         '400':
6630           $ref: '#/components/responses/badrequest'
6631         '401':
6632           $ref: '#/components/responses/unauthorized'
6633       security:
6634         -
6635           openemr_auth: []
6636   /fhir/ValueSet:
6637     get:
6638       tags:
6639         - fhir
6640       description: 'Returns a list of ValueSet resources.'
6641       parameters:
6642         -
6643           name: _id
6644           in: query
6645           description: 'The uuid for the ValueSet resource.'
6646           required: false
6647           schema:
6648             type: string
6649       responses:
6650         '200':
6651           description: 'Standard Response'
6652           content:
6653             application/json:
6654               schema:
6655                 properties:
6656                   'json object': { description: 'FHIR Json object.', type: object }
6657                 type: object
6658                 example:
6659                   meta: { lastUpdated: '2021-09-14T09:13:51' }
6660                   resourceType: Bundle
6661                   type: collection
6662                   total: 0
6663                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/ValueSet' }]
6664         '400':
6665           $ref: '#/components/responses/badrequest'
6666         '401':
6667           $ref: '#/components/responses/unauthorized'
6668       security:
6669         -
6670           openemr_auth: []
6671   '/fhir/ValueSet/{uuid}':
6672     get:
6673       tags:
6674         - fhir
6675       description: 'Returns a single ValueSet resource.'
6676       parameters:
6677         -
6678           name: uuid
6679           in: path
6680           description: 'The uuid for the ValueSet resource.'
6681           required: true
6682           schema:
6683             type: string
6684       responses:
6685         '200':
6686           description: 'Standard Response'
6687           content:
6688             application/json:
6689               schema:
6690                 properties:
6691                   'json object': { description: 'FHIR Json object.', type: object }
6692                 type: object
6693                 example:
6694                   resourceType: ValueSet
6695                   id: appointment-type
6696                   compose: { include: [{ concept: [{ code: no_show, display: 'No Show' }, { code: office_visit, display: 'Office Visit' }, { code: established_patient, display: 'Established Patient' }, { code: new_patient, display: 'New Patient' }, { code: health_and_behavioral_assessment, display: 'Health and Behavioral Assessment' }, { code: preventive_care_services, display: 'Preventive Care Services' }, { code: ophthalmological_services, display: 'Ophthalmological Services' }] }] }
6697         '400':
6698           $ref: '#/components/responses/badrequest'
6699         '401':
6700           $ref: '#/components/responses/unauthorized'
6701         '404':
6702           $ref: '#/components/responses/uuidnotfound'
6703       security:
6704         -
6705           openemr_auth: []
6706   /fhir/metadata:
6707     get:
6708       tags:
6709         - fhir
6710       description: 'Returns metadata (ie. CapabilityStatement resource) of the fhir server.'
6711       responses:
6712         '200':
6713           description: 'Return CapabilityStatement resource of the fhir server'
6714   /fhir/.well-known/smart-configuration:
6715     get:
6716       tags:
6717         - fhir
6718       description: 'Returns smart configuration of the fhir server.'
6719       responses:
6720         '200':
6721           description: 'Return smart configuration of the fhir server'
6722   /fhir/OperationDefinition:
6723     get:
6724       tags:
6725         - fhir
6726       description: 'Returns a list of the OperationDefinition resources that are specific to this OpenEMR installation'
6727       responses:
6728         '200':
6729           description: 'Return list of OperationDefinition resources'
6730   '/fhir/OperationDefinition/{operation}':
6731     get:
6732       tags:
6733         - fhir
6734       description: 'Returns a single OperationDefinition resource that is specific to this OpenEMR installation'
6735       parameters:
6736         -
6737           name: operation
6738           in: path
6739           description: 'The name of the operation to query. For example $bulkdata-status'
6740           required: true
6741           schema:
6742             type: string
6743       responses:
6744         '200':
6745           description: 'Standard Response'
6746           content:
6747             application/json:
6748               schema:
6749                 properties:
6750                   'json object': { description: 'FHIR Json object.', type: object }
6751                 type: object
6752                 example:
6753                   resourceType: OperationDefinition
6754                   name: $bulkdata-status
6755                   status: active
6756                   kind: operation
6757                   parameter: [{ name: job, use: in, min: 1, max: 1, type: { system: 'http://hl7.org/fhir/data-types', code: string, display: string }, searchType: { system: 'http://hl7.org/fhir/ValueSet/search-param-type', code: string, display: string } }]
6758   /fhir/$export:
6759     get:
6760       tags:
6761         - fhir
6762       description: 'The BULK FHIR Exports documentation can be found at <a href=''https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API'' target=''_blank'' rel=''noopener''>https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API</a>'
6763       responses:
6764         '200':
6765           description: 'The BULK FHIR Exports documentation can be found at <a href=''https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API'' target=''_blank'' rel=''noopener''>https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API</a>'
6766         '400':
6767           $ref: '#/components/responses/badrequest'
6768         '401':
6769           $ref: '#/components/responses/unauthorized'
6770       security:
6771         -
6772           openemr_auth: []
6773   /fhir/$bulkdata-status:
6774     get:
6775       tags:
6776         - fhir
6777       description: 'The BULK FHIR Exports documentation can be found at <a href=''https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API'' target=''_blank'' rel=''noopener''>https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API</a>'
6778       responses:
6779         '200':
6780           description: 'The BULK FHIR Exports documentation can be found at <a href=''https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API'' target=''_blank'' rel=''noopener''>https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API</a>'
6781         '400':
6782           $ref: '#/components/responses/badrequest'
6783         '401':
6784           $ref: '#/components/responses/unauthorized'
6785       security:
6786         -
6787           openemr_auth: []
6788     delete:
6789       tags:
6790         - fhir
6791       description: 'The BULK FHIR Exports documentation can be found at <a href=''https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API'' target=''_blank'' rel=''noopener''>https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API</a>'
6792       responses:
6793         '200':
6794           description: 'The BULK FHIR Exports documentation can be found at <a href=''https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API'' target=''_blank'' rel=''noopener''>https://www.open-emr.org/wiki/index.php/OpenEMR_Wiki_Home_Page#API</a>'
6795         '400':
6796           $ref: '#/components/responses/badrequest'
6797         '401':
6798           $ref: '#/components/responses/unauthorized'
6799       security:
6800         -
6801           openemr_auth: []
6802   /portal/patient:
6803     get:
6804       tags:
6805         - standard-patient
6806       description: 'Returns the patient.'
6807       responses:
6808         '200':
6809           description: 'Standard response'
6810           content:
6811             application/json:
6812               schema:
6813                 $ref: '#/components/schemas/api_patient_response'
6814         '401':
6815           $ref: '#/components/responses/unauthorized'
6816       security:
6817         -
6818           openemr_auth: []
6819   /portal/patient/encounter:
6820     get:
6821       tags:
6822         - standard-patient
6823       description: 'Returns encounters for the patient.'
6824       responses:
6825         '200':
6826           $ref: '#/components/responses/standard'
6827         '400':
6828           $ref: '#/components/responses/badrequest'
6829         '401':
6830           $ref: '#/components/responses/unauthorized'
6831       security:
6832         -
6833           openemr_auth: []
6834   '/portal/patient/encounter/{euuid}':
6835     get:
6836       tags:
6837         - standard-patient
6838       description: 'Returns a selected encounter by its uuid.'
6839       parameters:
6840         -
6841           name: euuid
6842           in: path
6843           description: 'The uuid for the encounter.'
6844           required: true
6845           schema:
6846             type: string
6847       responses:
6848         '200':
6849           $ref: '#/components/responses/standard'
6850         '400':
6851           $ref: '#/components/responses/badrequest'
6852         '401':
6853           $ref: '#/components/responses/unauthorized'
6854       security:
6855         -
6856           openemr_auth: []
6857   /portal/patient/appointment:
6858     get:
6859       tags:
6860         - standard-patient
6861       description: 'Retrieves all appointments for a patient'
6862       responses:
6863         '200':
6864           $ref: '#/components/responses/standard'
6865         '400':
6866           $ref: '#/components/responses/badrequest'
6867         '401':
6868           $ref: '#/components/responses/unauthorized'
6869       security:
6870         -
6871           openemr_auth: []
6872   '/portal/patient/appointment/{auuid}':
6873     get:
6874       tags:
6875         - standard-patient
6876       description: 'Returns a selected appointment by its uuid.'
6877       parameters:
6878         -
6879           name: auuid
6880           in: path
6881           description: 'The uuid for the appointment.'
6882           required: true
6883           schema:
6884             type: string
6885       responses:
6886         '200':
6887           $ref: '#/components/responses/standard'
6888         '400':
6889           $ref: '#/components/responses/badrequest'
6890         '401':
6891           $ref: '#/components/responses/unauthorized'
6892       security:
6893         -
6894           openemr_auth: []
6895 components:
6896   schemas:
6897     api_patient_request:
6898       description: 'Schema for the patient request'
6899       required:
6900         - fname
6901         - lname
6902         - DOB
6903         - sex
6904       properties:
6905         title:
6906           description: 'The title of patient.'
6907           type: string
6908         fname:
6909           description: 'The fname of patient.'
6910           type: string
6911         mname:
6912           description: 'The mname of patient.'
6913           type: string
6914         lname:
6915           description: 'The lname of patient.'
6916           type: string
6917         street:
6918           description: 'The street address of patient.'
6919           type: string
6920         postal_code:
6921           description: 'The postal code of patient.'
6922           type: string
6923         city:
6924           description: 'The city of patient.'
6925           type: string
6926         state:
6927           description: 'The state of patient.'
6928           type: string
6929         country_code:
6930           description: 'The country code of patient.'
6931           type: string
6932         phone_contact:
6933           description: 'The phone contact of patient.'
6934           type: string
6935         DOB:
6936           description: 'The DOB of patient.'
6937           type: string
6938         sex:
6939           description: 'The lname of patient.'
6940           type: string
6941         race:
6942           description: 'The race of patient.'
6943           type: string
6944         ethnicity:
6945           description: 'The ethnicity of patient.'
6946           type: string
6947       type: object
6948       example:
6949         title: Mr
6950         fname: Foo
6951         mname: ''
6952         lname: Bar
6953         street: '456 Tree Lane'
6954         postal_code: '08642'
6955         city: FooTown
6956         state: FL
6957         country_code: US
6958         phone_contact: 123-456-7890
6959         DOB: '1992-02-02'
6960         sex: Male
6961         race: ''
6962         ethnicity: ''
6963     api_patient_response:
6964       description: 'Schema for the patient response'
6965       properties:
6966         validationErrors:
6967           description: 'Validation errors.'
6968           type: array
6969           items:
6970             type: object
6971         internalErrors:
6972           description: 'Internal errors.'
6973           type: array
6974           items:
6975             type: object
6976         data:
6977           description: 'Returned data.'
6978           type: array
6979           items:
6980             properties:
6981               id:
6982                 description: 'patient id'
6983                 type: string
6984               pid:
6985                 description: 'patient pid'
6986                 type: string
6987               pubpid:
6988                 description: 'patient public id'
6989                 type: string
6990               title:
6991                 description: 'patient title'
6992                 type: string
6993               fname:
6994                 description: 'patient first name'
6995                 type: string
6996               mname:
6997                 description: 'patient middle name'
6998                 type: string
6999               lname:
7000                 description: 'patient last name'
7001                 type: string
7002               ss:
7003                 description: 'patient social security number'
7004                 type: string
7005               street:
7006                 description: 'patient street address'
7007                 type: string
7008               postal_code:
7009                 description: 'patient postal code'
7010                 type: string
7011               city:
7012                 description: 'patient city'
7013                 type: string
7014               state:
7015                 description: 'patient state'
7016                 type: string
7017               county:
7018                 description: 'patient county'
7019                 type: string
7020               country_code:
7021                 description: 'patient country code'
7022                 type: string
7023               drivers_license:
7024                 description: 'patient drivers license id'
7025                 type: string
7026               contact_relationship:
7027                 description: 'patient contact relationship'
7028                 type: string
7029               phone_contact:
7030                 description: 'patient phone contact'
7031                 type: string
7032               phone_home:
7033                 description: 'patient home phone'
7034                 type: string
7035               phone_biz:
7036                 description: 'patient work phone'
7037                 type: string
7038               phone_cell:
7039                 description: 'patient mobile phone'
7040                 type: string
7041               email:
7042                 description: 'patient email'
7043                 type: string
7044               DOB:
7045                 description: 'patient DOB'
7046                 type: string
7047               sex:
7048                 description: 'patient sex (gender)'
7049                 type: string
7050               race:
7051                 description: 'patient race'
7052                 type: string
7053               ethnicity:
7054                 description: 'patient ethnicity'
7055                 type: string
7056               status:
7057                 description: 'patient status'
7058                 type: string
7059             type: object
7060       type: object
7061       example:
7062         validationErrors: []
7063         error_description: []
7064         data:
7065           id: '193'
7066           pid: '1'
7067           pubpid: ''
7068           title: Mr
7069           fname: Baz
7070           mname: ''
7071           lname: Bop
7072           ss: ''
7073           street: '456 Tree Lane'
7074           postal_code: '08642'
7075           city: FooTown
7076           state: FL
7077           county: ''
7078           country_code: US
7079           drivers_license: ''
7080           contact_relationship: ''
7081           phone_contact: 123-456-7890
7082           phone_home: ''
7083           phone_biz: ''
7084           phone_cell: ''
7085           email: ''
7086           DOB: '1992-02-03'
7087           sex: Male
7088           race: ''
7089           ethnicity: ''
7090           status: ''
7091     api_encounter_request:
7092       description: 'Schema for the encounter request'
7093       required:
7094         - pc_catid
7095         - class_code
7096       properties:
7097         date:
7098           description: 'The date of encounter.'
7099           type: string
7100         onset_date:
7101           description: 'The onset date of encounter.'
7102           type: string
7103         reason:
7104           description: 'The reason of encounter.'
7105           type: string
7106         facility:
7107           description: 'The facility of encounter.'
7108           type: string
7109         pc_catid:
7110           description: 'The pc_catid of encounter.'
7111           type: string
7112         facility_id:
7113           description: 'The facility id of encounter.'
7114           type: string
7115         billing_facility:
7116           description: 'The billing facility id of encounter.'
7117           type: string
7118         sensitivity:
7119           description: 'The sensitivity of encounter.'
7120           type: string
7121         referral_source:
7122           description: 'The referral source of encounter.'
7123           type: string
7124         pos_code:
7125           description: 'The pos_code of encounter.'
7126           type: string
7127         external_id:
7128           description: 'The external id of encounter.'
7129           type: string
7130         provider_id:
7131           description: 'The provider id of encounter.'
7132           type: string
7133         class_code:
7134           description: 'The class_code of encounter.'
7135           type: string
7136       type: object
7137       example:
7138         date: '2020-11-10'
7139         onset_date: ''
7140         reason: 'Pregnancy Test'
7141         facility: 'Owerri General Hospital'
7142         pc_catid: '5'
7143         facility_id: '3'
7144         billing_facility: '3'
7145         sensitivity: normal
7146         referral_source: ''
7147         pos_code: '0'
7148         external_id: ''
7149         provider_id: '1'
7150         class_code: AMB
7151     api_encounter_response:
7152       description: 'Schema for the encounter response'
7153       properties:
7154         validationErrors:
7155           description: 'Validation errors.'
7156           type: array
7157           items:
7158             type: object
7159         internalErrors:
7160           description: 'Internal errors.'
7161           type: array
7162           items:
7163             type: object
7164         data:
7165           description: 'Returned data.'
7166           type: array
7167           items:
7168             properties:
7169               id:
7170                 description: 'encounter id'
7171                 type: string
7172               uuid:
7173                 description: 'encounter uuid'
7174                 type: string
7175               date:
7176                 description: 'encounter date'
7177                 type: string
7178               reason:
7179                 description: 'encounter reason'
7180                 type: string
7181               facility:
7182                 description: 'encounter facility name'
7183                 type: string
7184               facility_id:
7185                 description: 'encounter facility id name'
7186                 type: string
7187               pid:
7188                 description: 'encounter for patient pid'
7189                 type: string
7190               onset_date:
7191                 description: 'encounter onset date'
7192                 type: string
7193               sensitivity:
7194                 description: 'encounter sensitivity'
7195                 type: string
7196               billing_note:
7197                 description: 'encounter billing note'
7198                 type: string
7199               pc_catid:
7200                 description: 'encounter pc_catid'
7201                 type: string
7202               last_level_billed:
7203                 description: 'encounter last_level_billed'
7204                 type: string
7205               last_level_closed:
7206                 description: 'encounter last_level_closed'
7207                 type: string
7208               last_stmt_date:
7209                 description: 'encounter last_stmt_date'
7210                 type: string
7211               stmt_count:
7212                 description: 'encounter stmt_count'
7213                 type: string
7214               provider_id:
7215                 description: 'provider id'
7216                 type: string
7217               supervisor_id:
7218                 description: 'encounter supervisor id'
7219                 type: string
7220               invoice_refno:
7221                 description: 'encounter invoice_refno'
7222                 type: string
7223               referral_source:
7224                 description: 'encounter referral source'
7225                 type: string
7226               billing_facility:
7227                 description: 'encounter billing facility id'
7228                 type: string
7229               external_id:
7230                 description: 'encounter external id'
7231                 type: string
7232               pos_code:
7233                 description: 'encounter pos_code'
7234                 type: string
7235               class_code:
7236                 description: 'encounter class_code'
7237                 type: string
7238               class_title:
7239                 description: 'encounter class_title'
7240                 type: string
7241               pc_catname:
7242                 description: 'encounter pc_catname'
7243                 type: string
7244               billing_facility_name:
7245                 description: 'encounter billing facility name'
7246                 type: string
7247             type: object
7248       type: object
7249       example:
7250         validationErrors: []
7251         error_description: []
7252         data:
7253           id: '1'
7254           uuid: 90c196f2-51cc-4655-8858-3a80aebff3ef
7255           date: '2019-09-14 00:00:00'
7256           reason: 'Pregnancy Test'
7257           facility: 'Owerri General Hospital'
7258           facility_id: '3'
7259           pid: '1'
7260           onset_date: '2019-04-20 00:00:00'
7261           sensitivity: normal
7262           billing_note: null
7263           pc_catid: '5'
7264           last_level_billed: '0'
7265           last_level_closed: '0'
7266           last_stmt_date: null
7267           stmt_count: '0'
7268           provider_id: '1'
7269           supervisor_id: '0'
7270           invoice_refno: ''
7271           referral_source: ''
7272           billing_facility: '3'
7273           external_id: ''
7274           pos_code: '0'
7275           class_code: AMB
7276           class_title: ambulatory
7277           pc_catname: 'Office Visit'
7278           billing_facility_name: 'Owerri General Hospital'
7279     api_vital_request:
7280       description: 'Schema for the vital request'
7281       properties:
7282         bps:
7283           description: 'The bps of vitals.'
7284           type: string
7285         bpd:
7286           description: 'The bpd of vitals.'
7287           type: string
7288         weight:
7289           description: 'The weight of vitals. (unit is lb)'
7290           type: string
7291         height:
7292           description: 'The height of vitals. (unit is inches)'
7293           type: string
7294         temperature:
7295           description: 'The temperature of temperature. (unit is F)'
7296           type: string
7297         temp_method:
7298           description: 'The temp_method of vitals.'
7299           type: string
7300         pulse:
7301           description: 'The pulse of vitals.'
7302           type: string
7303         respiration:
7304           description: 'The respiration of vitals.'
7305           type: string
7306         note:
7307           description: 'The note (ie. comments) of vitals.'
7308           type: string
7309         waist_circ:
7310           description: 'The waist circumference of vitals. (unit is inches)'
7311           type: string
7312         head_circ:
7313           description: 'The head circumference of vitals. (unit is inches)'
7314           type: string
7315         oxygen_saturation:
7316           description: 'The oxygen_saturation of vitals.'
7317           type: string
7318       type: object
7319       example:
7320         bps: '130'
7321         bpd: '80'
7322         weight: '220'
7323         height: '70'
7324         temperature: '98'
7325         temp_method: Oral
7326         pulse: '60'
7327         respiration: '20'
7328         note: 'Patient with difficulty standing, which made weight measurement difficult.'
7329         waist_circ: '37'
7330         head_circ: '22.2'
7331         oxygen_saturation: '96'
7332     api_soap_note_request:
7333       description: 'Schema for the soap_note request'
7334       properties:
7335         subjective:
7336           description: 'The subjective of soap note.'
7337           type: string
7338         objective:
7339           description: 'The objective of soap note.'
7340           type: string
7341         assessment:
7342           description: 'The assessment of soap note.'
7343           type: string
7344         plan:
7345           description: 'The plan of soap note.'
7346           type: string
7347       type: object
7348       example:
7349         subjective: 'The patient with mechanical fall and cut finger.'
7350         objective: 'The patient with finger laceration on exam.'
7351         assessment: 'The patient with finger laceration requiring sutures.'
7352         plan: 'Sutured finger laceration.'
7353     api_medical_problem_request:
7354       description: 'Schema for the medical_problem request'
7355       required:
7356         - title
7357         - begdate
7358       properties:
7359         title:
7360           description: 'The title of medical problem.'
7361           type: string
7362         begdate:
7363           description: 'The beginning date of medical problem.'
7364           type: string
7365         enddate:
7366           description: 'The end date of medical problem.'
7367           type: string
7368         diagnosis:
7369           description: 'The diagnosis of medical problem. In format `<codetype>:<code>`'
7370           type: string
7371       type: object
7372       example:
7373         title: Dermatochalasis
7374         begdate: '2010-10-13'
7375         enddate: null
7376         diagnosis: 'ICD10:H02.839'
7377     api_allergy_request:
7378       description: 'Schema for the allergy request'
7379       required:
7380         - title
7381         - begdate
7382       properties:
7383         title:
7384           description: 'The title of allergy.'
7385           type: string
7386         begdate:
7387           description: 'The beginning date of allergy.'
7388           type: string
7389         enddate:
7390           description: 'The end date of allergy.'
7391           type: string
7392         diagnosis:
7393           description: 'The diagnosis of allergy. In format `<codetype>:<code>`'
7394           type: string
7395       type: object
7396       example:
7397         title: Iodine
7398         begdate: '2010-10-13'
7399         enddate: null
7400     api_medication_request:
7401       description: 'Schema for the medication request'
7402       required:
7403         - title
7404         - begdate
7405       properties:
7406         title:
7407           description: 'The title of medication.'
7408           type: string
7409         begdate:
7410           description: 'The beginning date of medication.'
7411           type: string
7412         enddate:
7413           description: 'The end date of medication.'
7414           type: string
7415         diagnosis:
7416           description: 'The diagnosis of medication. In format `<codetype>:<code>`'
7417           type: string
7418       type: object
7419       example:
7420         title: Norvasc
7421         begdate: '2013-04-13'
7422         enddate: null
7423     api_surgery_request:
7424       description: 'Schema for the surgery request'
7425       required:
7426         - title
7427         - begdate
7428       properties:
7429         title:
7430           description: 'The title of surgery.'
7431           type: string
7432         begdate:
7433           description: 'The beginning date of surgery.'
7434           type: string
7435         enddate:
7436           description: 'The end date of surgery.'
7437           type: string
7438         diagnosis:
7439           description: 'The diagnosis of surgery. In format `<codetype>:<code>`'
7440           type: string
7441       type: object
7442       example:
7443         title: Blepharoplasty
7444         begdate: '2013-10-14'
7445         enddate: null
7446         diagnosis: 'CPT4:15823-50'
7447     api_dental_issue_request:
7448       description: 'Schema for the dental_issue request'
7449       required:
7450         - title
7451         - begdate
7452       properties:
7453         title:
7454           description: 'The title of dental issue.'
7455           type: string
7456         begdate:
7457           description: 'The beginning date of dental issue.'
7458           type: string
7459         enddate:
7460           description: 'The end date of dental issue.'
7461           type: string
7462         diagnosis:
7463           description: 'The diagnosis of dental issue. In format `<codetype>:<code>`'
7464           type: string
7465       type: object
7466       example:
7467         title: Halitosis
7468         begdate: '2015-03-17'
7469         enddate: null
7470     api_insurance_company_request:
7471       description: 'Schema for the insurance_company request'
7472       required:
7473         - name
7474       properties:
7475         name:
7476           description: 'The name of insurance company.'
7477           type: string
7478         attn:
7479           description: 'The attn of insurance company.'
7480           type: string
7481         cms_id:
7482           description: 'The cms id of insurance company.'
7483           type: string
7484         ins_type_code:
7485           description: 'The insurance type code of insurance company. The insurance type code can be found by inspecting the route at (/api/insurance_type).'
7486           type: string
7487         x12_receiver_id:
7488           description: 'The x12 receiver id of insurance company.'
7489           type: string
7490         x12_default_partner_id:
7491           description: 'The x12 default partner id of insurance company.'
7492           type: string
7493         alt_cms_id:
7494           description: 'The alternate cms id of insurance company.'
7495           type: string
7496         line1:
7497           description: 'The line1 address of insurance company.'
7498           type: string
7499         line2:
7500           description: 'The line2 address of insurance company.'
7501           type: string
7502         city:
7503           description: 'The city of insurance company.'
7504           type: string
7505         state:
7506           description: 'The state of insurance company.'
7507           type: string
7508         zip:
7509           description: 'The zip of insurance company.'
7510           type: string
7511         country:
7512           description: 'The country of insurance company.'
7513           type: string
7514       type: object
7515       example:
7516         name: 'Cool Insurance Company'
7517         attn: null
7518         cms_id: null
7519         ins_type_code: '2'
7520         x12_receiver_id: null
7521         x12_default_partner_id: null
7522         alt_cms_id: ''
7523         line1: '123 Cool Lane'
7524         line2: 'Suite 123'
7525         city: Cooltown
7526         state: CA
7527         zip: '12245'
7528         country: USA
7529     api_insurance_request:
7530       description: "Schema for the insurance request.  Note the following additional validation checks on the request.\nIf the subscriber_relationship value is of type 'self' then the subscriber_fname and subscriber_lname fields\nmust match the patient's first and last name or a patient's previous first and last name.\n\nIf the subscriber_relationship value is of type 'self' then the subscriber_ss field must match the patient's\nsocial security number.\n\nIf the subscriber_relationship value is not of type 'self' then the subscriber_ss field MUST not be the current patient's social security number.\n\nIf the system's global configuration permits only a single insurance type option then any insurance rquest where the type is NOT 'primary' will fail.\n\nAn insurance is considered the current policy for the policy type if the policy date_end field is null.  Only one of these records per policy type can exist for a patient."
7531       required:
7532         - provider
7533         - policy_number
7534         - subscriber_fname
7535         - subscriber_lname
7536         - subscriber_relationship
7537         - subscriber_ss
7538         - subscriber_DOB
7539         - subscriber_street
7540         - subscriber_postal_code
7541         - subscriber_city
7542         - subscriber_state
7543         - subscriber_country
7544         - subscriber_sex
7545         - accept_assignment
7546       properties:
7547         provider:
7548           description: 'The insurance company id.'
7549           type: string
7550         plan_name:
7551           description: 'The plan name of insurance. (2-255 characters)'
7552           type: string
7553         policy_number:
7554           description: 'The policy number of insurance. (2-255 characters)'
7555           type: string
7556         group_number:
7557           description: 'The group number of insurance.(2-255 characters)'
7558           type: string
7559         subscriber_lname:
7560           description: 'The subscriber last name of insurance.(2-255 characters).'
7561           type: string
7562         subscriber_mname:
7563           description: 'The subscriber middle name of insurance.'
7564           type: string
7565         subscriber_fname:
7566           description: 'The subscriber first name of insurance.'
7567           type: string
7568         subscriber_relationship:
7569           description: 'The subscriber relationship of insurance. `subscriber_relationship` can be found by querying `resource=/api/list/subscriber_relationship`'
7570           type: string
7571         subscriber_ss:
7572           description: 'The subscriber ss number of insurance.'
7573           type: string
7574         subscriber_DOB:
7575           description: 'The subscriber DOB of insurance.'
7576           type: string
7577         subscriber_street:
7578           description: 'The subscriber street address of insurance.'
7579           type: string
7580         subscriber_postal_code:
7581           description: 'The subscriber postal code of insurance.'
7582           type: string
7583         subscriber_city:
7584           description: 'The subscriber city of insurance.'
7585           type: string
7586         subscriber_state:
7587           description: 'The subscriber state of insurance. `state` can be found by querying `resource=/api/list/state`'
7588           type: string
7589         subscriber_country:
7590           description: 'The subscriber country of insurance. `country` can be found by querying `resource=/api/list/country`'
7591           type: string
7592         subscriber_phone:
7593           description: 'The subscriber phone of insurance.'
7594           type: string
7595         subscriber_employer:
7596           description: 'The subscriber employer of insurance.'
7597           type: string
7598         subscriber_employer_street:
7599           description: 'The subscriber employer street of insurance.'
7600           type: string
7601         subscriber_employer_postal_code:
7602           description: 'The subscriber employer postal code of insurance.'
7603           type: string
7604         subscriber_employer_state:
7605           description: 'The subscriber employer state of insurance.'
7606           type: string
7607         subscriber_employer_country:
7608           description: 'The subscriber employer country of insurance.'
7609           type: string
7610         subscriber_employer_city:
7611           description: 'The subscriber employer city of insurance.'
7612           type: string
7613         copay:
7614           description: 'The copay of insurance.'
7615           type: string
7616         date:
7617           description: 'The effective date of insurance in YYYY-MM-DD format.  This value cannot be after the date_end property and cannot be the same date as any other insurance policy for the same insurance type (''primary, ''secondary'', etc).'
7618           type: string
7619         date_end:
7620           description: 'The effective end date of insurance in YYYY-MM-DD format.  This value cannot be before the date property. If it is null then this policy is the current policy for this policy type for the patient.  There can only be one current policy per type and the request will fail if there is already a current policy for this type.'
7621           type: string
7622         subscriber_sex:
7623           description: 'The subscriber sex of insurance.'
7624           type: string
7625         accept_assignment:
7626           description: 'The accept_assignment of insurance.'
7627           type: string
7628         policy_type:
7629           description: 'The 837p list of policy types for an insurance.  See src/Billing/InsurancePolicyType.php for the list of valid values.'
7630           type: string
7631         type:
7632           description: 'The type or category of OpenEMR insurance policy, ''primary'', ''secondary'', or ''tertiary''. If this field is missing it will default to ''primary''.'
7633           type: string
7634       type: object
7635       example:
7636         provider: '33'
7637         plan_name: 'Some Plan'
7638         policy_number: '12345'
7639         group_number: '252412'
7640         subscriber_lname: Tester
7641         subscriber_mname: Xi
7642         subscriber_fname: Foo
7643         subscriber_relationship: other
7644         subscriber_ss: '234231234'
7645         subscriber_DOB: '2018-10-03'
7646         subscriber_street: '183 Cool St'
7647         subscriber_postal_code: '23418'
7648         subscriber_city: Cooltown
7649         subscriber_state: AZ
7650         subscriber_country: USA
7651         subscriber_phone: 234-598-2123
7652         subscriber_employer: 'Some Employer'
7653         subscriber_employer_street: '123 Heather Lane'
7654         subscriber_employer_postal_code: '23415'
7655         subscriber_employer_state: AZ
7656         subscriber_employer_country: USA
7657         subscriber_employer_city: Cooltown
7658         copay: '35'
7659         date: '2018-10-15'
7660         subscriber_sex: Female
7661         accept_assignment: 'TRUE'
7662         policy_type: a
7663         type: primary
7664     api_message_request:
7665       description: 'Schema for the message request'
7666       required:
7667         - body
7668         - groupname
7669         - from
7670         - to
7671         - title
7672         - message_status
7673       properties:
7674         body:
7675           description: 'The body of message.'
7676           type: string
7677         groupname:
7678           description: 'The group name (usually is ''Default'').'
7679           type: string
7680         from:
7681           description: 'The sender of the message.'
7682           type: string
7683         to:
7684           description: 'The recipient of the message.'
7685           type: string
7686         title:
7687           description: 'use an option from resource=/api/list/note_type'
7688           type: string
7689         message_status:
7690           description: 'use an option from resource=/api/list/message_status'
7691           type: string
7692       type: object
7693       example:
7694         body: 'Test 456'
7695         groupname: Default
7696         from: Matthew
7697         to: admin
7698         title: Other
7699         message_status: New
7700     api_transaction_request:
7701       description: 'Schema for the transaction request'
7702       required:
7703         - message
7704         - groupname
7705         - title
7706       properties:
7707         message:
7708           description: 'The message of the transaction.'
7709           type: string
7710         type:
7711           description: 'The type of transaction. Use an option from resource=/api/transaction_type'
7712           type: string
7713         groupname:
7714           description: 'The group name (usually is ''Default'').'
7715           type: string
7716         referByNpi:
7717           description: 'NPI of the person creating the referral.'
7718           type: string
7719         referToNpi:
7720           description: 'NPI of the person getting the referral.'
7721           type: string
7722         referDiagnosis:
7723           description: 'The referral diagnosis.'
7724           type: string
7725         riskLevel:
7726           description: 'The risk level. (Low, Medium, High)'
7727           type: string
7728         includeVitals:
7729           description: 'Are vitals included (0,1)'
7730           type: string
7731         referralDate:
7732           description: 'The date of the referral'
7733           type: string
7734         authorization:
7735           description: 'The authorization for the referral'
7736           type: string
7737         visits:
7738           description: 'The number of vists for the referral'
7739           type: string
7740         validFrom:
7741           description: 'The date the referral is valid from'
7742           type: string
7743         validThrough:
7744           description: 'The date the referral is valid through'
7745           type: string
7746       type: object
7747       example:
7748         message: Message
7749         type: LBTref
7750         groupname: Default
7751         referByNpi: '9999999999'
7752         referToNpi: '9999999999'
7753         referDiagnosis: 'Diag 1'
7754         riskLevel: Low
7755         includeVitals: '1'
7756         referralDate: '2022-01-01'
7757         authorization: Auth_123
7758         visits: '1'
7759         validFrom: '2022-01-02'
7760         validThrough: '2022-01-03'
7761         body: 'Reason 1'
7762   responses:
7763     standard:
7764       description: 'Standard Response'
7765       content:
7766         application/json:
7767           schema:
7768             properties:
7769               validationErrors:
7770                 description: 'Validation errors.'
7771                 type: array
7772                 items:
7773                   type: object
7774               internalErrors:
7775                 description: 'Internal errors.'
7776                 type: array
7777                 items:
7778                   type: object
7779               data:
7780                 description: 'Returned data.'
7781                 type: array
7782                 items:
7783                   type: object
7784             type: object
7785             example:
7786               validationErrors: []
7787               error_description: []
7788               data: []
7789     badrequest:
7790       description: 'Bad Request'
7791       content:
7792         application/json:
7793           schema:
7794             properties:
7795               validationErrors:
7796                 description: 'Validation errors.'
7797                 type: object
7798             type: object
7799             example:
7800               validationErrors:
7801                 _id: 'The search field argument was invalid, improperly formatted, or could not be parsed.  Inner message: UUID columns must be a valid UUID string'
7802     unauthorized:
7803       description: Unauthorized
7804       content:
7805         application/json:
7806           schema:
7807             properties:
7808               error:
7809                 description: 'The error.'
7810                 type: string
7811               error_description:
7812                 description: 'The description of the error.'
7813                 type: string
7814               hint:
7815                 description: 'More specific information on the error.'
7816                 type: string
7817               message:
7818                 description: 'Message regarding the error.'
7819                 type: string
7820             type: object
7821             example:
7822               error: access_denied
7823               error_description: 'The resource owner or authorization server denied the request.'
7824               hint: 'Missing "Authorization" header'
7825               message: 'The resource owner or authorization server denied the request.'
7826     uuidnotfound:
7827       description: 'Not Found'
7828       content:
7829         application/json:
7830           schema:
7831             properties:
7832               empty:
7833                 description: empty
7834                 type: object
7835             type: object
7836             example: []
7837   parameters:
7838     _sort:
7839       name: _sort
7840       in: query
7841       description: 'The sort criteria specified in comma separated order with Descending order being specified by a dash before the search parameter name. (Example: name,-category)'
7842       required: false
7843       schema:
7844         type: string
7845     _lastUpdated:
7846       name: _lastUpdated
7847       in: query
7848       description: 'The date the resource was last updated.'
7849       required: false
7850       schema:
7851         type: string
7852   securitySchemes:
7853     openemr_auth:
7854       type: oauth2
7855       flows:
7856         authorizationCode:
7857           authorizationUrl: /oauth2/default/authorize
7858           tokenUrl: /oauth2/default/token
7859           refreshUrl: /oauth2/default/token
7860           scopes:
7861             openid: 'Generic mandatory scope'
7862             offline_access: 'Will signal server to provide a refresh token'
7863             launch/patient: 'Will provide a patient selector when logging in as an OpenEMR user (required for testing patient/* scopes in swagger if not logging in as a patient)'
7864             'api:fhir': 'FHIR R4 API'
7865             patient/AllergyIntolerance.read: 'Read allergy intolerance resources for the current patient (api:fhir)'
7866             patient/Appointment.read: 'Read appointment resources for the current patient (api:fhir)'
7867             patient/Binary.read: 'Read binary document resources for the current patient (api:fhir)'
7868             patient/CarePlan.read: 'Read care plan resources for the current patient (api:fhir)'
7869             patient/CareTeam.read: 'Read care team resources for the current patient (api:fhir)'
7870             patient/Condition.read: 'Read condition resources for the current patient (api:fhir)'
7871             patient/Coverage.read: 'Read coverage resources for the current patient (api:fhir)'
7872             patient/Device.read: 'Read device resources for the current patient (api:fhir)'
7873             patient/DiagnosticReport.read: 'Read diagnostic report resources for the current patient (api:fhir)'
7874             patient/DocumentReference.read: 'Read document reference resources for the current patient (api:fhir)'
7875             patient/DocumentReference.$docref: 'Generate a document for the current patient or returns the most current Clinical Summary of Care Document (CCD)'
7876             patient/Encounter.read: 'Read encounter resources for the current patient (api:fhir)'
7877             patient/Goal.read: 'Read goal resources for the current patient (api:fhir)'
7878             patient/Immunization.read: 'Read immunization resources for the current patient (api:fhir)'
7879             patient/Location.read: 'Read location resources for the current patient (api:fhir)'
7880             patient/Medication.read: 'Read medication resources for the current patient (api:fhir)'
7881             patient/MedicationRequest.read: 'Read medication request resources for the current patient (api:fhir)'
7882             patient/Observation.read: 'Read observation resources for the current patient (api:fhir)'
7883             patient/Organization.read: 'Read organization resources for the current patient (api:fhir)'
7884             patient/Patient.read: 'Read patient resource for the current patient (api:fhir)'
7885             patient/Person.read: 'Read person resources for the current patient (api:fhir)'
7886             patient/Practitioner.read: 'Read practitioner resources for the current patient (api:fhir)'
7887             patient/Procedure.read: 'Read procedure resources for the current patient (api:fhir)'
7888             patient/Provenance.read: 'Read provenance resources for the current patient (api:fhir)'
7889             system/AllergyIntolerance.read: 'Read all allergy intolerance resources in the system (api:fhir)'
7890             system/Binary.read: 'Read all binary document resources in the system (api:fhir)'
7891             system/CarePlan.read: 'Read all care plan resources in the system (api:fhir)'
7892             system/CareTeam.read: 'Read all care team resources in the system (api:fhir)'
7893             system/Condition.read: 'Read all condition resources in the system (api:fhir)'
7894             system/Coverage.read: 'Read all coverage resources in the system (api:fhir)'
7895             system/Device.read: 'Read all device resources in the system (api:fhir)'
7896             system/DiagnosticReport.read: 'Read all diagnostic report resources in the system (api:fhir)'
7897             system/DocumentReference.read: 'Read all document reference resources in the system (api:fhir)'
7898             system/DocumentReference.$docref: 'Generate a document for any patient in the system or returns the most current Clinical Summary of Care Document (CCD)'
7899             system/Encounter.read: 'Read all encounter resources in the system (api:fhir)'
7900             system/Goal.read: 'Read all goal resources in the system (api:fhir)'
7901             system/Group.read: 'Read all group resources in the system (api:fhir)'
7902             system/Immunization.read: 'Read all immunization resources in the system (api:fhir)'
7903             system/Location.read: 'Read all location resources in the system (api:fhir)'
7904             system/Medication.read: 'Read all medication resources in the system (api:fhir)'
7905             system/MedicationRequest.read: 'Read all medication request resources in the system (api:fhir)'
7906             system/Observation.read: 'Read all observation resources in the system (api:fhir)'
7907             system/Organization.read: 'Read all organization resources in the system (api:fhir)'
7908             system/Patient.read: 'Read all patient resources in the system (api:fhir)'
7909             system/Person.read: 'Read all person resources in the system (api:fhir)'
7910             system/Practitioner.read: 'Read all practitioner resources in the system (api:fhir)'
7911             system/PractitionerRole.read: 'Read all practitioner role resources in the system (api:fhir)'
7912             system/Procedure.read: 'Read all procedure resources in the system (api:fhir)'
7913             system/Provenance.read: 'Read all provenance resources in the system (api:fhir)'
7914             system/ValueSet.read: 'Read all valueSet resources in the system (api:fhir)'
7915             user/AllergyIntolerance.read: 'Read all allergy intolerance resources the user has access to (api:fhir)'
7916             user/Binary.read: 'Read all binary documents the user has access to (api:fhir)'
7917             user/CarePlan.read: 'Read all care plan resources the user has access to (api:fhir)'
7918             user/CareTeam.read: 'Read all care team resources the user has access to (api:fhir)'
7919             user/Condition.read: 'Read all condition resources the user has access to (api:fhir)'
7920             user/Coverage.read: 'Read all coverage resources the user has access to (api:fhir)'
7921             user/Device.read: 'Read all device resources the user has access to (api:fhir)'
7922             user/DiagnosticReport.read: 'Read all diagnostic report resources the user has access to (api:fhir)'
7923             user/DocumentReference.read: 'Read all document reference resources the user has access to (api:fhir)'
7924             user/DocumentReference.$docref: 'Generate a document for any patient the user has access to or returns the most current Clinical Summary of Care Document (CCD) (api:fhir)'
7925             user/Encounter.read: 'Read all encounter resources the user has access to (api:fhir)'
7926             user/Goal.read: 'Read all goal resources the user has access to (api:fhir)'
7927             user/Immunization.read: 'Read all immunization resources the user has access to (api:fhir)'
7928             user/Location.read: 'Read all location resources the user has access to (api:fhir)'
7929             user/Medication.read: 'Read all medication resources the user has access to (api:fhir)'
7930             user/MedicationRequest.read: 'Read all medication request resources the user has access to (api:fhir)'
7931             user/Observation.read: 'Read all observation resources the user has access to (api:fhir)'
7932             user/Organization.read: 'Read all organization resources the user has access to (api:fhir)'
7933             user/Organization.write: 'Write all organization resources the user has access to (api:fhir)'
7934             user/Patient.read: 'Read all patient resources the user has access to (api:fhir)'
7935             user/Patient.write: 'Write all patient resources the user has access to (api:fhir)'
7936             user/Person.read: 'Read all person resources the user has access to (api:fhir)'
7937             user/Practitioner.read: 'Read all practitioner resources the user has access to (api:fhir)'
7938             user/Practitioner.write: 'Write all practitioner resources the user has access to (api:fhir)'
7939             user/PractitionerRole.read: 'Read all practitioner role resources the user has access to (api:fhir)'
7940             user/Procedure.read: 'Read all procedure resources the user has access to (api:fhir)'
7941             user/Provenance.read: 'Read all provenance resources the user has access to (api:fhir)'
7942             user/ValueSet.read: 'Read all valueSet resources the user has access to (api:fhir)'
7943             'api:oemr': 'Standard OpenEMR API'
7944             user/allergy.read: 'Read allergies the user has access to (api:oemr)'
7945             user/allergy.write: 'Write allergies the user has access to for (api:oemr)'
7946             user/appointment.read: 'Read appointments the user has access to (api:oemr)'
7947             user/appointment.write: 'Write appointments the user has access to for (api:oemr)'
7948             user/dental_issue.read: 'Read dental issues the user has access to (api:oemr)'
7949             user/dental_issue.write: 'Write dental issues the user has access to (api:oemr)'
7950             user/document.read: 'Read documents the user has access to (api:oemr)'
7951             user/document.write: 'Write documents the user has access to (api:oemr)'
7952             user/drug.read: 'Read drugs the user has access to (api:oemr)'
7953             user/encounter.read: 'Read encounters the user has access to (api:oemr)'
7954             user/encounter.write: 'Write encounters the user has access to (api:oemr)'
7955             user/facility.read: 'Read facilities the user has access to (api:oemr)'
7956             user/facility.write: 'Write facilities the user has access to (api:oemr)'
7957             user/immunization.read: 'Read immunizations the user has access to (api:oemr)'
7958             user/insurance.read: 'Read insurances the user has access to (api:oemr)'
7959             user/insurance.write: 'Write insurances the user has access to (api:oemr)'
7960             user/insurance_company.read: 'Read insurance companies the user has access to (api:oemr)'
7961             user/insurance_company.write: 'Write insurance companies the user has access to (api:oemr)'
7962             user/insurance_type.read: 'Read insurance types the user has access to (api:oemr)'
7963             user/list.read: 'Read lists the user has access to (api:oemr)'
7964             user/medical_problem.read: 'Read medical problems the user has access to (api:oemr)'
7965             user/medical_problem.write: 'Write medical problems the user has access to (api:oemr)'
7966             user/medication.read: 'Read medications the user has access to (api:oemr)'
7967             user/medication.write: 'Write medications the user has access to (api:oemr)'
7968             user/message.write: 'Read messages the user has access to (api:oemr)'
7969             user/patient.read: 'Read patients the user has access to (api:oemr)'
7970             user/patient.write: 'Write patients the user has access to (api:oemr)'
7971             user/practitioner.read: 'Read practitioners the user has access to (api:oemr)'
7972             user/practitioner.write: 'Write practitioners the user has access to (api:oemr)'
7973             user/prescription.read: 'Read prescriptions the user has access to (api:oemr)'
7974             user/procedure.read: 'Read procedures the user has access to (api:oemr)'
7975             user/soap_note.read: 'Read soap notes the user has access to (api:oemr)'
7976             user/soap_note.write: 'Write soap notes the user has access to (api:oemr)'
7977             user/surgery.read: 'Read surgeries the user has access to (api:oemr)'
7978             user/surgery.write: 'Write surgeries the user has access to (api:oemr)'
7979             user/transaction.read: 'Read transactions the user has access to (api:oemr)'
7980             user/transaction.write: 'Write transactions the user has access to (api:oemr)'
7981             user/user.read: 'Read users the current user has access to (api:oemr)'
7982             user/vital.read: 'Read vitals the user has access to (api:oemr)'
7983             user/vital.write: 'Write vitals the user has access to (api:oemr)'
7984             'api:port': 'Standard Patient Portal OpenEMR API'
7985             patient/encounter.read: 'Read encounters the patient has access to (api:port)'
7986             patient/patient.read: 'Write encounters the patient has access to (api:port)'
7987             patient/appointment.read: 'Read appointments the patient has access to (api:port)'
7988 tags:
7989   -
7990     name: fhir
7991     description: 'FHIR R4 API'
7992   -
7993     name: standard
7994     description: 'Standard OpenEMR API'
7995   -
7996     name: standard-patient
7997     description: 'Standard Patient Portal OpenEMR API'