ensure always a unique installation id when need it (#4654)
[openemr.git] / swagger / openemr-api.yaml
blobd0feb4109cf554f713afa4b704c406efbd63ea29
1 openapi: 3.0.0
2 info:
3   title: 'OpenEMR API'
4   version: 6.1.0
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           name: fname
396           in: query
397           description: 'The first name for the patient.'
398           required: false
399           schema:
400             type: string
401         -
402           name: lname
403           in: query
404           description: 'The last name for the patient.'
405           required: false
406           schema:
407             type: string
408         -
409           name: ss
410           in: query
411           description: 'The social security number for the patient.'
412           required: false
413           schema:
414             type: string
415         -
416           name: street
417           in: query
418           description: 'The street for the patient.'
419           required: false
420           schema:
421             type: string
422         -
423           name: postal_code
424           in: query
425           description: 'The postal code for the patient.'
426           required: false
427           schema:
428             type: string
429         -
430           name: city
431           in: query
432           description: 'The city for the patient.'
433           required: false
434           schema:
435             type: string
436         -
437           name: state
438           in: query
439           description: 'The state for the patient.'
440           required: false
441           schema:
442             type: string
443         -
444           name: phone_home
445           in: query
446           description: 'The home phone for the patient.'
447           required: false
448           schema:
449             type: string
450         -
451           name: phone_biz
452           in: query
453           description: 'The business phone for the patient.'
454           required: false
455           schema:
456             type: string
457         -
458           name: phone_cell
459           in: query
460           description: 'The cell phone for the patient.'
461           required: false
462           schema:
463             type: string
464         -
465           name: postal_contact
466           in: query
467           description: 'The postal_contact for the patient.'
468           required: false
469           schema:
470             type: string
471         -
472           name: sex
473           in: query
474           description: 'The gender for the patient.'
475           required: false
476           schema:
477             type: string
478         -
479           name: country_code
480           in: query
481           description: 'The country code for the patient.'
482           required: false
483           schema:
484             type: string
485         -
486           name: email
487           in: query
488           description: 'The email for the patient.'
489           required: false
490           schema:
491             type: string
492         -
493           name: DOB
494           in: query
495           description: 'The DOB for the patient.'
496           required: false
497           schema:
498             type: string
499       responses:
500         '200':
501           $ref: '#/components/responses/standard'
502         '400':
503           $ref: '#/components/responses/badrequest'
504         '401':
505           $ref: '#/components/responses/unauthorized'
506       security:
507         -
508           openemr_auth: []
509     post:
510       tags:
511         - standard
512       description: 'Creates a new patient'
513       requestBody:
514         required: true
515         content:
516           application/json:
517             schema:
518               $ref: '#/components/schemas/api_patient_request'
519       responses:
520         '200':
521           description: 'Standard response'
522           content:
523             application/json:
524               schema:
525                 properties:
526                   validationErrors: { description: 'Validation errors.', type: array, items: { type: object } }
527                   internalErrors: { description: 'Internal errors.', type: array, items: { type: object } }
528                   data: { description: 'Returned data.', type: array, items: { properties: { pid: { description: 'patient pid', type: integer } }, type: object } }
529                 type: object
530                 example:
531                   validationErrors: []
532                   error_description: []
533                   data: { pid: 1 }
534         '401':
535           $ref: '#/components/responses/unauthorized'
536       security:
537         -
538           openemr_auth: []
539   '/api/patient/{puuid}':
540     get:
541       tags:
542         - standard
543       description: 'Retrieves a single patient by their uuid'
544       parameters:
545         -
546           name: puuid
547           in: path
548           description: 'The uuid for the patient.'
549           required: true
550           schema:
551             type: string
552       responses:
553         '200':
554           description: 'Standard response'
555           content:
556             application/json:
557               schema:
558                 $ref: '#/components/schemas/api_patient_response'
559         '401':
560           $ref: '#/components/responses/unauthorized'
561       security:
562         -
563           openemr_auth: []
564     put:
565       tags:
566         - standard
567       description: 'Updates a patient'
568       parameters:
569         -
570           name: puuid
571           in: path
572           description: 'The uuid for the patient.'
573           required: true
574           schema:
575             type: string
576       requestBody:
577         required: true
578         content:
579           application/json:
580             schema:
581               $ref: '#/components/schemas/api_patient_request'
582       responses:
583         '200':
584           description: 'Standard response'
585           content:
586             application/json:
587               schema:
588                 $ref: '#/components/schemas/api_patient_response'
589         '401':
590           $ref: '#/components/responses/unauthorized'
591       security:
592         -
593           openemr_auth: []
594   '/api/patient/{puuid}/encounter':
595     get:
596       tags:
597         - standard
598       description: 'Retrieves a list of encounters for a single patient'
599       parameters:
600         -
601           name: puuid
602           in: path
603           description: 'The uuid for the patient.'
604           required: true
605           schema:
606             type: string
607       responses:
608         '200':
609           $ref: '#/components/responses/standard'
610         '400':
611           $ref: '#/components/responses/badrequest'
612         '401':
613           $ref: '#/components/responses/unauthorized'
614       security:
615         -
616           openemr_auth: []
617     post:
618       tags:
619         - standard
620       description: 'Creates a new encounter'
621       parameters:
622         -
623           name: puuid
624           in: path
625           description: 'The uuid for the patient.'
626           required: true
627           schema:
628             type: string
629       requestBody:
630         required: true
631         content:
632           application/json:
633             schema:
634               $ref: '#/components/schemas/api_encounter_request'
635       responses:
636         '200':
637           description: 'Standard response'
638           content:
639             application/json:
640               schema:
641                 properties:
642                   validationErrors: { description: 'Validation errors.', type: array, items: { type: object } }
643                   internalErrors: { description: 'Internal errors.', type: array, items: { type: object } }
644                   data: { description: 'Returned data.', type: array, items: { properties: { encounter: { description: 'encounter id', type: integer }, uuid: { description: 'encounter uuid', type: string } }, type: object } }
645                 type: object
646                 example:
647                   validationErrors: []
648                   error_description: []
649                   data: { encounter: 1, uuid: 90c196f2-51cc-4655-8858-3a80aebff3ef }
650         '401':
651           $ref: '#/components/responses/unauthorized'
652       security:
653         -
654           openemr_auth: []
655   '/api/patient/{puuid}/encounter/{euuid}':
656     get:
657       tags:
658         - standard
659       description: 'Retrieves a single encounter for a patient'
660       parameters:
661         -
662           name: puuid
663           in: path
664           description: 'The uuid for the patient.'
665           required: true
666           schema:
667             type: string
668         -
669           name: euuid
670           in: path
671           description: 'The uuid for the encounter.'
672           required: true
673           schema:
674             type: string
675       responses:
676         '200':
677           description: 'Standard response'
678           content:
679             application/json:
680               schema:
681                 $ref: '#/components/schemas/api_encounter_response'
682         '401':
683           $ref: '#/components/responses/unauthorized'
684       security:
685         -
686           openemr_auth: []
687     put:
688       tags:
689         - standard
690       description: 'Modify a encounter'
691       parameters:
692         -
693           name: puuid
694           in: path
695           description: 'The uuid for the patient.'
696           required: true
697           schema:
698             type: string
699         -
700           name: euuid
701           in: path
702           description: 'The uuid for the encounter.'
703           required: true
704           schema:
705             type: string
706       requestBody:
707         required: true
708         content:
709           application/json:
710             schema:
711               $ref: '#/components/schemas/api_encounter_request'
712       responses:
713         '200':
714           description: 'Standard response'
715           content:
716             application/json:
717               schema:
718                 $ref: '#/components/schemas/api_encounter_response'
719         '401':
720           $ref: '#/components/responses/unauthorized'
721       security:
722         -
723           openemr_auth: []
724   '/api/patient/{pid}/encounter/{eid}/soap_note':
725     get:
726       tags:
727         - standard
728       description: 'Retrieves soap notes from an encounter for a patient'
729       parameters:
730         -
731           name: pid
732           in: path
733           description: 'The pid for the patient.'
734           required: true
735           schema:
736             type: string
737         -
738           name: eid
739           in: path
740           description: 'The id for the encounter.'
741           required: true
742           schema:
743             type: string
744       responses:
745         '200':
746           $ref: '#/components/responses/standard'
747         '400':
748           $ref: '#/components/responses/badrequest'
749         '401':
750           $ref: '#/components/responses/unauthorized'
751       security:
752         -
753           openemr_auth: []
754     post:
755       tags:
756         - standard
757       description: 'Submits a new soap note'
758       parameters:
759         -
760           name: pid
761           in: path
762           description: 'The id for the patient.'
763           required: true
764           schema:
765             type: string
766         -
767           name: eid
768           in: path
769           description: 'The id for the encounter.'
770           required: true
771           schema:
772             type: string
773       requestBody:
774         required: true
775         content:
776           application/json:
777             schema:
778               $ref: '#/components/schemas/api_soap_note_request'
779       responses:
780         '200':
781           $ref: '#/components/responses/standard'
782         '400':
783           $ref: '#/components/responses/badrequest'
784         '401':
785           $ref: '#/components/responses/unauthorized'
786       security:
787         -
788           openemr_auth: []
789   '/api/patient/{pid}/encounter/{eid}/vital':
790     get:
791       tags:
792         - standard
793       description: 'Retrieves all vitals from an encounter for a patient'
794       parameters:
795         -
796           name: pid
797           in: path
798           description: 'The pid for the patient.'
799           required: true
800           schema:
801             type: string
802         -
803           name: eid
804           in: path
805           description: 'The id for the encounter.'
806           required: true
807           schema:
808             type: string
809       responses:
810         '200':
811           $ref: '#/components/responses/standard'
812         '400':
813           $ref: '#/components/responses/badrequest'
814         '401':
815           $ref: '#/components/responses/unauthorized'
816       security:
817         -
818           openemr_auth: []
819     post:
820       tags:
821         - standard
822       description: 'Submits a new vitals form'
823       parameters:
824         -
825           name: pid
826           in: path
827           description: 'The id for the patient.'
828           required: true
829           schema:
830             type: string
831         -
832           name: eid
833           in: path
834           description: 'The id for the encounter.'
835           required: true
836           schema:
837             type: string
838       requestBody:
839         required: true
840         content:
841           application/json:
842             schema:
843               $ref: '#/components/schemas/api_vital_request'
844       responses:
845         '200':
846           $ref: '#/components/responses/standard'
847         '400':
848           $ref: '#/components/responses/badrequest'
849         '401':
850           $ref: '#/components/responses/unauthorized'
851       security:
852         -
853           openemr_auth: []
854   '/api/patient/{pid}/encounter/{eid}/vital/{vid}':
855     get:
856       tags:
857         - standard
858       description: 'Retrieves a vitals form from an encounter for a patient'
859       parameters:
860         -
861           name: pid
862           in: path
863           description: 'The pid for the patient.'
864           required: true
865           schema:
866             type: string
867         -
868           name: eid
869           in: path
870           description: 'The id for the encounter.'
871           required: true
872           schema:
873             type: string
874         -
875           name: vid
876           in: path
877           description: 'The id for the vitals form.'
878           required: true
879           schema:
880             type: string
881       responses:
882         '200':
883           $ref: '#/components/responses/standard'
884         '400':
885           $ref: '#/components/responses/badrequest'
886         '401':
887           $ref: '#/components/responses/unauthorized'
888       security:
889         -
890           openemr_auth: []
891     put:
892       tags:
893         - standard
894       description: 'Edit a vitals form'
895       parameters:
896         -
897           name: pid
898           in: path
899           description: 'The id for the patient.'
900           required: true
901           schema:
902             type: string
903         -
904           name: eid
905           in: path
906           description: 'The id for the encounter.'
907           required: true
908           schema:
909             type: string
910         -
911           name: vid
912           in: path
913           description: 'The id for the vitalss form.'
914           required: true
915           schema:
916             type: string
917       requestBody:
918         required: true
919         content:
920           application/json:
921             schema:
922               $ref: '#/components/schemas/api_vital_request'
923       responses:
924         '200':
925           $ref: '#/components/responses/standard'
926         '400':
927           $ref: '#/components/responses/badrequest'
928         '401':
929           $ref: '#/components/responses/unauthorized'
930       security:
931         -
932           openemr_auth: []
933   '/api/patient/{pid}/encounter/{eid}/soap_note/{sid}':
934     get:
935       tags:
936         - standard
937       description: 'Retrieves a soap note from an encounter for a patient'
938       parameters:
939         -
940           name: pid
941           in: path
942           description: 'The pid for the patient.'
943           required: true
944           schema:
945             type: string
946         -
947           name: eid
948           in: path
949           description: 'The id for the encounter.'
950           required: true
951           schema:
952             type: string
953         -
954           name: sid
955           in: path
956           description: 'The id for the soap note.'
957           required: true
958           schema:
959             type: string
960       responses:
961         '200':
962           $ref: '#/components/responses/standard'
963         '400':
964           $ref: '#/components/responses/badrequest'
965         '401':
966           $ref: '#/components/responses/unauthorized'
967       security:
968         -
969           openemr_auth: []
970     put:
971       tags:
972         - standard
973       description: 'Edit a soap note'
974       parameters:
975         -
976           name: pid
977           in: path
978           description: 'The id for the patient.'
979           required: true
980           schema:
981             type: string
982         -
983           name: eid
984           in: path
985           description: 'The id for the encounter.'
986           required: true
987           schema:
988             type: string
989         -
990           name: sid
991           in: path
992           description: 'The id for the soap noted.'
993           required: true
994           schema:
995             type: string
996       requestBody:
997         required: true
998         content:
999           application/json:
1000             schema:
1001               $ref: '#/components/schemas/api_soap_note_request'
1002       responses:
1003         '200':
1004           $ref: '#/components/responses/standard'
1005         '400':
1006           $ref: '#/components/responses/badrequest'
1007         '401':
1008           $ref: '#/components/responses/unauthorized'
1009       security:
1010         -
1011           openemr_auth: []
1012   /api/practitioner:
1013     get:
1014       tags:
1015         - standard
1016       description: 'Retrieves a list of practitioners'
1017       parameters:
1018         -
1019           name: title
1020           in: query
1021           description: 'The title for the practitioner.'
1022           required: false
1023           schema:
1024             type: string
1025         -
1026           name: fname
1027           in: query
1028           description: 'The first name for the practitioner.'
1029           required: false
1030           schema:
1031             type: string
1032         -
1033           name: lname
1034           in: query
1035           description: 'The last name for the practitioner.'
1036           required: false
1037           schema:
1038             type: string
1039         -
1040           name: mname
1041           in: query
1042           description: 'The middle name for the practitioner.'
1043           required: false
1044           schema:
1045             type: string
1046         -
1047           name: federaltaxid
1048           in: query
1049           description: 'The federal tax id for the practitioner.'
1050           required: false
1051           schema:
1052             type: string
1053         -
1054           name: federaldrugid
1055           in: query
1056           description: 'The federal drug id for the practitioner.'
1057           required: false
1058           schema:
1059             type: string
1060         -
1061           name: upin
1062           in: query
1063           description: 'The upin for the practitioner.'
1064           required: false
1065           schema:
1066             type: string
1067         -
1068           name: facility_id
1069           in: query
1070           description: 'The facility id for the practitioner.'
1071           required: false
1072           schema:
1073             type: string
1074         -
1075           name: facility
1076           in: query
1077           description: 'The facility for the practitioner.'
1078           required: false
1079           schema:
1080             type: string
1081         -
1082           name: npi
1083           in: query
1084           description: 'The npi for the practitioner.'
1085           required: false
1086           schema:
1087             type: string
1088         -
1089           name: email
1090           in: query
1091           description: 'The email for the practitioner.'
1092           required: false
1093           schema:
1094             type: string
1095         -
1096           name: specialty
1097           in: query
1098           description: 'The specialty for the practitioner.'
1099           required: false
1100           schema:
1101             type: string
1102         -
1103           name: billname
1104           in: query
1105           description: 'The billname for the practitioner.'
1106           required: false
1107           schema:
1108             type: string
1109         -
1110           name: url
1111           in: query
1112           description: 'The url for the practitioner.'
1113           required: false
1114           schema:
1115             type: string
1116         -
1117           name: assistant
1118           in: query
1119           description: 'The assistant for the practitioner.'
1120           required: false
1121           schema:
1122             type: string
1123         -
1124           name: organization
1125           in: query
1126           description: 'The organization for the practitioner.'
1127           required: false
1128           schema:
1129             type: string
1130         -
1131           name: valedictory
1132           in: query
1133           description: 'The valedictory for the practitioner.'
1134           required: false
1135           schema:
1136             type: string
1137         -
1138           name: street
1139           in: query
1140           description: 'The street for the practitioner.'
1141           required: false
1142           schema:
1143             type: string
1144         -
1145           name: streetb
1146           in: query
1147           description: 'The street (line 2) for the practitioner.'
1148           required: false
1149           schema:
1150             type: string
1151         -
1152           name: city
1153           in: query
1154           description: 'The city for the practitioner.'
1155           required: false
1156           schema:
1157             type: string
1158         -
1159           name: state
1160           in: query
1161           description: 'The state for the practitioner.'
1162           required: false
1163           schema:
1164             type: string
1165         -
1166           name: zip
1167           in: query
1168           description: 'The zip for the practitioner.'
1169           required: false
1170           schema:
1171             type: string
1172         -
1173           name: phone
1174           in: query
1175           description: 'The phone for the practitioner.'
1176           required: false
1177           schema:
1178             type: string
1179         -
1180           name: fax
1181           in: query
1182           description: 'The fax for the practitioner.'
1183           required: false
1184           schema:
1185             type: string
1186         -
1187           name: phonew1
1188           in: query
1189           description: 'The phonew1 for the practitioner.'
1190           required: false
1191           schema:
1192             type: string
1193         -
1194           name: phonecell
1195           in: query
1196           description: 'The phonecell for the practitioner.'
1197           required: false
1198           schema:
1199             type: string
1200         -
1201           name: notes
1202           in: query
1203           description: 'The notes for the practitioner.'
1204           required: false
1205           schema:
1206             type: string
1207         -
1208           name: state_license_number2
1209           in: query
1210           description: 'The state license number for the practitioner.'
1211           required: false
1212           schema:
1213             type: string
1214         -
1215           name: username
1216           in: query
1217           description: 'The username for the practitioner.'
1218           required: false
1219           schema:
1220             type: string
1221       responses:
1222         '200':
1223           $ref: '#/components/responses/standard'
1224         '400':
1225           $ref: '#/components/responses/badrequest'
1226         '401':
1227           $ref: '#/components/responses/unauthorized'
1228       security:
1229         -
1230           openemr_auth: []
1231     post:
1232       tags:
1233         - standard
1234       description: 'Submits a new practitioner'
1235       requestBody:
1236         required: true
1237         content:
1238           application/json:
1239             schema:
1240               required:
1241                 - fname
1242                 - lname
1243                 - npi
1244               properties:
1245                 title:
1246                   description: 'The title for the practitioner.'
1247                   type: string
1248                 fname:
1249                   description: 'The first name for the practitioner.'
1250                   type: string
1251                 mname:
1252                   description: 'The middle name for the practitioner.'
1253                   type: string
1254                 lname:
1255                   description: 'The last name for the practitioner.'
1256                   type: string
1257                 federaltaxid:
1258                   description: 'The federal tax id for the practitioner.'
1259                   type: string
1260                 federaldrugid:
1261                   description: 'The federal drug id for the practitioner.'
1262                   type: string
1263                 upin:
1264                   description: 'The upin for the practitioner.'
1265                   type: string
1266                 facility_id:
1267                   description: 'The facility_id for the practitioner.'
1268                   type: string
1269                 facility:
1270                   description: 'The facility name for the practitioner.'
1271                   type: string
1272                 npi:
1273                   description: 'The npi for the practitioner.'
1274                   type: string
1275                 email:
1276                   description: 'The email for the practitioner.'
1277                   type: string
1278                 specialty:
1279                   description: 'The specialty for the practitioner.'
1280                   type: string
1281                 billname:
1282                   description: 'The billname for the practitioner.'
1283                   type: string
1284                 url:
1285                   description: 'The url for the practitioner.'
1286                   type: string
1287                 assistant:
1288                   description: 'The assistant for the practitioner.'
1289                   type: string
1290                 valedictory:
1291                   description: 'The valedictory for the practitioner.'
1292                   type: string
1293                 street:
1294                   description: 'The street address for the practitioner.'
1295                   type: string
1296                 streetb:
1297                   description: 'The streetb address for the practitioner.'
1298                   type: string
1299                 city:
1300                   description: 'The city for the practitioner.'
1301                   type: string
1302                 state:
1303                   description: 'The state for the practitioner.'
1304                   type: string
1305                 zip:
1306                   description: 'The zip for the practitioner.'
1307                   type: string
1308                 phone:
1309                   description: 'The phone for the practitioner.'
1310                   type: string
1311                 fax:
1312                   description: 'The fax for the practitioner.'
1313                   type: string
1314                 phonew1:
1315                   description: 'The phonew1 for the practitioner.'
1316                   type: string
1317                 phonecell:
1318                   description: 'The phonecell for the practitioner.'
1319                   type: string
1320                 notes:
1321                   description: 'The notes for the practitioner.'
1322                   type: string
1323                 state_license_number:
1324                   description: 'The state license number for the practitioner.'
1325                   type: string
1326                 username:
1327                   description: 'The username for the practitioner.'
1328                   type: string
1329               type: object
1330               example:
1331                 title: Mrs.
1332                 fname: Eduardo
1333                 mname: Kathy
1334                 lname: Perez
1335                 federaltaxid: ''
1336                 federaldrugid: ''
1337                 upin: ''
1338                 facility_id: '3'
1339                 facility: 'Your Clinic Name Here'
1340                 npi: '12345678901'
1341                 email: info@pennfirm.com
1342                 specialty: ''
1343                 billname: null
1344                 url: null
1345                 assistant: null
1346                 organization: null
1347                 valedictory: null
1348                 street: '789 Third Avenue'
1349                 streetb: '123 Cannaut Street'
1350                 city: 'San Diego'
1351                 state: CA
1352                 zip: '90210'
1353                 phone: '(619) 555-9827'
1354                 fax: null
1355                 phonew1: '(619) 555-7822'
1356                 phonecell: '(619) 555-7821'
1357                 notes: null
1358                 state_license_number: '123456'
1359                 username: eduardoperez
1360       responses:
1361         '200':
1362           description: 'Standard response'
1363           content:
1364             application/json:
1365               schema:
1366                 properties:
1367                   validationErrors: { description: 'Validation errors.', type: array, items: { type: object } }
1368                   internalErrors: { description: 'Internal errors.', type: array, items: { type: object } }
1369                   data: { description: 'Returned data.', type: array, items: { properties: { id: { description: 'practitioner id', type: integer }, uuid: { description: 'practitioner uuid', type: string } }, type: object } }
1370                 type: object
1371                 example:
1372                   validationErrors: []
1373                   error_description: []
1374                   data: { id: 7, uuid: 90d453fb-0248-4c0d-9575-d99d02b169f5 }
1375         '401':
1376           $ref: '#/components/responses/unauthorized'
1377       security:
1378         -
1379           openemr_auth: []
1380   '/api/practitioner/{pruuid}':
1381     get:
1382       tags:
1383         - standard
1384       description: 'Retrieves a single practitioner by their uuid'
1385       parameters:
1386         -
1387           name: pruuid
1388           in: path
1389           description: 'The uuid for the practitioner.'
1390           required: true
1391           schema:
1392             type: string
1393       responses:
1394         '200':
1395           $ref: '#/components/responses/standard'
1396         '400':
1397           $ref: '#/components/responses/badrequest'
1398         '401':
1399           $ref: '#/components/responses/unauthorized'
1400       security:
1401         -
1402           openemr_auth: []
1403     put:
1404       tags:
1405         - standard
1406       description: 'Edit a practitioner'
1407       parameters:
1408         -
1409           name: pruuid
1410           in: path
1411           description: 'The uuid for the practitioner.'
1412           required: true
1413           schema:
1414             type: string
1415       requestBody:
1416         required: true
1417         content:
1418           application/json:
1419             schema:
1420               properties:
1421                 title:
1422                   description: 'The title for the practitioner.'
1423                   type: string
1424                 fname:
1425                   description: 'The first name for the practitioner.'
1426                   type: string
1427                 mname:
1428                   description: 'The middle name for the practitioner.'
1429                   type: string
1430                 lname:
1431                   description: 'The last name for the practitioner.'
1432                   type: string
1433                 federaltaxid:
1434                   description: 'The federal tax id for the practitioner.'
1435                   type: string
1436                 federaldrugid:
1437                   description: 'The federal drug id for the practitioner.'
1438                   type: string
1439                 upin:
1440                   description: 'The upin for the practitioner.'
1441                   type: string
1442                 facility_id:
1443                   description: 'The facility_id for the practitioner.'
1444                   type: string
1445                 facility:
1446                   description: 'The facility name for the practitioner.'
1447                   type: string
1448                 npi:
1449                   description: 'The npi for the practitioner.'
1450                   type: string
1451                 email:
1452                   description: 'The email for the practitioner.'
1453                   type: string
1454                 specialty:
1455                   description: 'The specialty for the practitioner.'
1456                   type: string
1457                 billname:
1458                   description: 'The billname for the practitioner.'
1459                   type: string
1460                 url:
1461                   description: 'The url for the practitioner.'
1462                   type: string
1463                 assistant:
1464                   description: 'The assistant for the practitioner.'
1465                   type: string
1466                 valedictory:
1467                   description: 'The valedictory for the practitioner.'
1468                   type: string
1469                 street:
1470                   description: 'The street address for the practitioner.'
1471                   type: string
1472                 streetb:
1473                   description: 'The streetb address for the practitioner.'
1474                   type: string
1475                 city:
1476                   description: 'The city for the practitioner.'
1477                   type: string
1478                 state:
1479                   description: 'The state for the practitioner.'
1480                   type: string
1481                 zip:
1482                   description: 'The zip for the practitioner.'
1483                   type: string
1484                 phone:
1485                   description: 'The phone for the practitioner.'
1486                   type: string
1487                 fax:
1488                   description: 'The fax for the practitioner.'
1489                   type: string
1490                 phonew1:
1491                   description: 'The phonew1 for the practitioner.'
1492                   type: string
1493                 phonecell:
1494                   description: 'The phonecell for the practitioner.'
1495                   type: string
1496                 notes:
1497                   description: 'The notes for the practitioner.'
1498                   type: string
1499                 state_license_number:
1500                   description: 'The state license number for the practitioner.'
1501                   type: string
1502                 username:
1503                   description: 'The username for the practitioner.'
1504                   type: string
1505               type: object
1506               example:
1507                 title: Mr
1508                 fname: Baz
1509                 mname: ''
1510                 lname: Bop
1511                 street: '456 Tree Lane'
1512                 zip: '08642'
1513                 city: FooTown
1514                 state: FL
1515                 phone: 123-456-7890
1516       responses:
1517         '200':
1518           description: 'Standard response'
1519           content:
1520             application/json:
1521               schema:
1522                 properties:
1523                   validationErrors: { description: 'Validation errors.', type: array, items: { type: object } }
1524                   internalErrors: { description: 'Internal errors.', type: array, items: { type: object } }
1525                   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 } }
1526                 type: object
1527                 example:
1528                   validationErrors: []
1529                   error_description: []
1530                   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 }
1531         '401':
1532           $ref: '#/components/responses/unauthorized'
1533       security:
1534         -
1535           openemr_auth: []
1536   /api/medical_problem:
1537     get:
1538       tags:
1539         - standard
1540       description: 'Retrieves a list of medical problems'
1541       parameters:
1542         -
1543           name: puuid
1544           in: query
1545           description: 'The uuid for the patient.'
1546           required: false
1547           schema:
1548             type: string
1549         -
1550           name: condition_uuid
1551           in: query
1552           description: 'The uuid for the medical problem.'
1553           required: false
1554           schema:
1555             type: string
1556         -
1557           name: title
1558           in: query
1559           description: 'The title for the medical problem.'
1560           required: false
1561           schema:
1562             type: string
1563         -
1564           name: begdate
1565           in: query
1566           description: 'The start date for the medical problem.'
1567           required: false
1568           schema:
1569             type: string
1570         -
1571           name: enddate
1572           in: query
1573           description: 'The end date for the medical problem.'
1574           required: false
1575           schema:
1576             type: string
1577         -
1578           name: diagnosis
1579           in: query
1580           description: 'The diagnosis for the medical problem.'
1581           required: false
1582           schema:
1583             type: string
1584       responses:
1585         '200':
1586           $ref: '#/components/responses/standard'
1587         '400':
1588           $ref: '#/components/responses/badrequest'
1589         '401':
1590           $ref: '#/components/responses/unauthorized'
1591       security:
1592         -
1593           openemr_auth: []
1594   '/api/medical_problem/{muuid}':
1595     get:
1596       tags:
1597         - standard
1598       description: 'Retrieves a single medical problem by their uuid'
1599       parameters:
1600         -
1601           name: muuid
1602           in: path
1603           description: 'The uuid for the medical problem.'
1604           required: true
1605           schema:
1606             type: string
1607       responses:
1608         '200':
1609           $ref: '#/components/responses/standard'
1610         '400':
1611           $ref: '#/components/responses/badrequest'
1612         '401':
1613           $ref: '#/components/responses/unauthorized'
1614       security:
1615         -
1616           openemr_auth: []
1617   '/api/patient/{puuid}/medical_problem':
1618     get:
1619       tags:
1620         - standard
1621       description: 'Retrieves all medical problems for a patient'
1622       parameters:
1623         -
1624           name: puuid
1625           in: path
1626           description: 'The uuid for the patient.'
1627           required: true
1628           schema:
1629             type: string
1630       responses:
1631         '200':
1632           $ref: '#/components/responses/standard'
1633         '400':
1634           $ref: '#/components/responses/badrequest'
1635         '401':
1636           $ref: '#/components/responses/unauthorized'
1637       security:
1638         -
1639           openemr_auth: []
1640     post:
1641       tags:
1642         - standard
1643       description: 'Submits a new medical problem'
1644       parameters:
1645         -
1646           name: puuid
1647           in: path
1648           description: 'The uuid for the patient.'
1649           required: true
1650           schema:
1651             type: string
1652       requestBody:
1653         required: true
1654         content:
1655           application/json:
1656             schema:
1657               $ref: '#/components/schemas/api_medical_problem_request'
1658       responses:
1659         '200':
1660           $ref: '#/components/responses/standard'
1661         '400':
1662           $ref: '#/components/responses/badrequest'
1663         '401':
1664           $ref: '#/components/responses/unauthorized'
1665       security:
1666         -
1667           openemr_auth: []
1668   '/api/patient/{puuid}/medical_problem/{muuid}':
1669     get:
1670       tags:
1671         - standard
1672       description: 'Retrieves a medical problem for a patient'
1673       parameters:
1674         -
1675           name: puuid
1676           in: path
1677           description: 'The uuid for the patient.'
1678           required: true
1679           schema:
1680             type: string
1681         -
1682           name: muuid
1683           in: path
1684           description: 'The uuid for the medical problem.'
1685           required: true
1686           schema:
1687             type: string
1688       responses:
1689         '200':
1690           $ref: '#/components/responses/standard'
1691         '400':
1692           $ref: '#/components/responses/badrequest'
1693         '401':
1694           $ref: '#/components/responses/unauthorized'
1695       security:
1696         -
1697           openemr_auth: []
1698     put:
1699       tags:
1700         - standard
1701       description: 'Edit a medical problem'
1702       parameters:
1703         -
1704           name: puuid
1705           in: path
1706           description: 'The uuid for the patient.'
1707           required: true
1708           schema:
1709             type: string
1710         -
1711           name: muuid
1712           in: path
1713           description: 'The uuid for the medical problem.'
1714           required: true
1715           schema:
1716             type: string
1717       requestBody:
1718         required: true
1719         content:
1720           application/json:
1721             schema:
1722               $ref: '#/components/schemas/api_medical_problem_request'
1723       responses:
1724         '200':
1725           $ref: '#/components/responses/standard'
1726         '400':
1727           $ref: '#/components/responses/badrequest'
1728         '401':
1729           $ref: '#/components/responses/unauthorized'
1730       security:
1731         -
1732           openemr_auth: []
1733     delete:
1734       tags:
1735         - standard
1736       description: 'Delete a medical problem'
1737       parameters:
1738         -
1739           name: puuid
1740           in: path
1741           description: 'The uuid for the patient.'
1742           required: true
1743           schema:
1744             type: string
1745         -
1746           name: muuid
1747           in: path
1748           description: 'The uuid for the medical problem.'
1749           required: true
1750           schema:
1751             type: string
1752       responses:
1753         '200':
1754           $ref: '#/components/responses/standard'
1755         '400':
1756           $ref: '#/components/responses/badrequest'
1757         '401':
1758           $ref: '#/components/responses/unauthorized'
1759       security:
1760         -
1761           openemr_auth: []
1762   /api/allergy:
1763     get:
1764       tags:
1765         - standard
1766       description: 'Retrieves a list of allergies'
1767       parameters:
1768         -
1769           name: lists.pid
1770           in: query
1771           description: 'The uuid for the patient.'
1772           required: false
1773           schema:
1774             type: string
1775         -
1776           name: lists.id
1777           in: query
1778           description: 'The uuid for the allergy.'
1779           required: false
1780           schema:
1781             type: string
1782         -
1783           name: title
1784           in: query
1785           description: 'The title for the allergy.'
1786           required: false
1787           schema:
1788             type: string
1789         -
1790           name: begdate
1791           in: query
1792           description: 'The start date for the allergy.'
1793           required: false
1794           schema:
1795             type: string
1796         -
1797           name: enddate
1798           in: query
1799           description: 'The end date for the allergy.'
1800           required: false
1801           schema:
1802             type: string
1803         -
1804           name: diagnosis
1805           in: query
1806           description: 'The diagnosis for the allergy.'
1807           required: false
1808           schema:
1809             type: string
1810       responses:
1811         '200':
1812           $ref: '#/components/responses/standard'
1813         '400':
1814           $ref: '#/components/responses/badrequest'
1815         '401':
1816           $ref: '#/components/responses/unauthorized'
1817       security:
1818         -
1819           openemr_auth: []
1820   '/api/allergy/{auuid}':
1821     get:
1822       tags:
1823         - standard
1824       description: 'Retrieves a single allergy by their uuid'
1825       parameters:
1826         -
1827           name: auuid
1828           in: path
1829           description: 'The uuid for the allergy.'
1830           required: true
1831           schema:
1832             type: string
1833       responses:
1834         '200':
1835           $ref: '#/components/responses/standard'
1836         '400':
1837           $ref: '#/components/responses/badrequest'
1838         '401':
1839           $ref: '#/components/responses/unauthorized'
1840       security:
1841         -
1842           openemr_auth: []
1843   '/api/patient/{puuid}/allergy':
1844     get:
1845       tags:
1846         - standard
1847       description: 'Retrieves all allergies for a patient'
1848       parameters:
1849         -
1850           name: puuid
1851           in: path
1852           description: 'The uuid for the patient.'
1853           required: true
1854           schema:
1855             type: string
1856       responses:
1857         '200':
1858           $ref: '#/components/responses/standard'
1859         '400':
1860           $ref: '#/components/responses/badrequest'
1861         '401':
1862           $ref: '#/components/responses/unauthorized'
1863       security:
1864         -
1865           openemr_auth: []
1866     post:
1867       tags:
1868         - standard
1869       description: 'Submits a new allergy'
1870       parameters:
1871         -
1872           name: puuid
1873           in: path
1874           description: 'The uuid for the patient.'
1875           required: true
1876           schema:
1877             type: string
1878       requestBody:
1879         required: true
1880         content:
1881           application/json:
1882             schema:
1883               $ref: '#/components/schemas/api_allergy_request'
1884       responses:
1885         '200':
1886           $ref: '#/components/responses/standard'
1887         '400':
1888           $ref: '#/components/responses/badrequest'
1889         '401':
1890           $ref: '#/components/responses/unauthorized'
1891       security:
1892         -
1893           openemr_auth: []
1894   '/api/patient/{puuid}/allergy/{auuid}':
1895     get:
1896       tags:
1897         - standard
1898       description: 'Retrieves a allergy for a patient'
1899       parameters:
1900         -
1901           name: puuid
1902           in: path
1903           description: 'The uuid for the patient.'
1904           required: true
1905           schema:
1906             type: string
1907         -
1908           name: auuid
1909           in: path
1910           description: 'The uuid for the allergy.'
1911           required: true
1912           schema:
1913             type: string
1914       responses:
1915         '200':
1916           $ref: '#/components/responses/standard'
1917         '400':
1918           $ref: '#/components/responses/badrequest'
1919         '401':
1920           $ref: '#/components/responses/unauthorized'
1921       security:
1922         -
1923           openemr_auth: []
1924     put:
1925       tags:
1926         - standard
1927       description: 'Edit a allergy'
1928       parameters:
1929         -
1930           name: puuid
1931           in: path
1932           description: 'The uuid for the patient.'
1933           required: true
1934           schema:
1935             type: string
1936         -
1937           name: auuid
1938           in: path
1939           description: 'The uuid for the allergy.'
1940           required: true
1941           schema:
1942             type: string
1943       requestBody:
1944         required: true
1945         content:
1946           application/json:
1947             schema:
1948               $ref: '#/components/schemas/api_allergy_request'
1949       responses:
1950         '200':
1951           $ref: '#/components/responses/standard'
1952         '400':
1953           $ref: '#/components/responses/badrequest'
1954         '401':
1955           $ref: '#/components/responses/unauthorized'
1956       security:
1957         -
1958           openemr_auth: []
1959     delete:
1960       tags:
1961         - standard
1962       description: 'Delete a medical problem'
1963       parameters:
1964         -
1965           name: puuid
1966           in: path
1967           description: 'The uuid for the patient.'
1968           required: true
1969           schema:
1970             type: string
1971         -
1972           name: auuid
1973           in: path
1974           description: 'The uuid for the allergy.'
1975           required: true
1976           schema:
1977             type: string
1978       responses:
1979         '200':
1980           $ref: '#/components/responses/standard'
1981         '400':
1982           $ref: '#/components/responses/badrequest'
1983         '401':
1984           $ref: '#/components/responses/unauthorized'
1985       security:
1986         -
1987           openemr_auth: []
1988   '/api/patient/{pid}/medication':
1989     get:
1990       tags:
1991         - standard
1992       description: 'Retrieves all medications for a patient'
1993       parameters:
1994         -
1995           name: pid
1996           in: path
1997           description: 'The pid for the patient.'
1998           required: true
1999           schema:
2000             type: string
2001       responses:
2002         '200':
2003           $ref: '#/components/responses/standard'
2004         '400':
2005           $ref: '#/components/responses/badrequest'
2006         '401':
2007           $ref: '#/components/responses/unauthorized'
2008       security:
2009         -
2010           openemr_auth: []
2011     post:
2012       tags:
2013         - standard
2014       description: 'Submits a new medication'
2015       parameters:
2016         -
2017           name: pid
2018           in: path
2019           description: 'The pid for the patient.'
2020           required: true
2021           schema:
2022             type: string
2023       requestBody:
2024         required: true
2025         content:
2026           application/json:
2027             schema:
2028               $ref: '#/components/schemas/api_medication_request'
2029       responses:
2030         '200':
2031           $ref: '#/components/responses/standard'
2032         '400':
2033           $ref: '#/components/responses/badrequest'
2034         '401':
2035           $ref: '#/components/responses/unauthorized'
2036       security:
2037         -
2038           openemr_auth: []
2039   '/api/patient/{pid}/medication/{mid}':
2040     get:
2041       tags:
2042         - standard
2043       description: 'Retrieves a medication for a patient'
2044       parameters:
2045         -
2046           name: pid
2047           in: path
2048           description: 'The id for the patient.'
2049           required: true
2050           schema:
2051             type: string
2052         -
2053           name: mid
2054           in: path
2055           description: 'The id for the medication.'
2056           required: true
2057           schema:
2058             type: string
2059       responses:
2060         '200':
2061           $ref: '#/components/responses/standard'
2062         '400':
2063           $ref: '#/components/responses/badrequest'
2064         '401':
2065           $ref: '#/components/responses/unauthorized'
2066       security:
2067         -
2068           openemr_auth: []
2069     put:
2070       tags:
2071         - standard
2072       description: 'Edit a medication'
2073       parameters:
2074         -
2075           name: pid
2076           in: path
2077           description: 'The pid for the patient.'
2078           required: true
2079           schema:
2080             type: string
2081         -
2082           name: mid
2083           in: path
2084           description: 'The id for the medication.'
2085           required: true
2086           schema:
2087             type: string
2088       requestBody:
2089         required: true
2090         content:
2091           application/json:
2092             schema:
2093               $ref: '#/components/schemas/api_medication_request'
2094       responses:
2095         '200':
2096           $ref: '#/components/responses/standard'
2097         '400':
2098           $ref: '#/components/responses/badrequest'
2099         '401':
2100           $ref: '#/components/responses/unauthorized'
2101       security:
2102         -
2103           openemr_auth: []
2104     delete:
2105       tags:
2106         - standard
2107       description: 'Delete a medication'
2108       parameters:
2109         -
2110           name: pid
2111           in: path
2112           description: 'The id for the patient.'
2113           required: true
2114           schema:
2115             type: string
2116         -
2117           name: mid
2118           in: path
2119           description: 'The id for the medication.'
2120           required: true
2121           schema:
2122             type: string
2123       responses:
2124         '200':
2125           $ref: '#/components/responses/standard'
2126         '400':
2127           $ref: '#/components/responses/badrequest'
2128         '401':
2129           $ref: '#/components/responses/unauthorized'
2130       security:
2131         -
2132           openemr_auth: []
2133   '/api/patient/{pid}/surgery':
2134     get:
2135       tags:
2136         - standard
2137       description: 'Retrieves all surgeries for a patient'
2138       parameters:
2139         -
2140           name: pid
2141           in: path
2142           description: 'The pid for the patient.'
2143           required: true
2144           schema:
2145             type: string
2146       responses:
2147         '200':
2148           $ref: '#/components/responses/standard'
2149         '400':
2150           $ref: '#/components/responses/badrequest'
2151         '401':
2152           $ref: '#/components/responses/unauthorized'
2153       security:
2154         -
2155           openemr_auth: []
2156     post:
2157       tags:
2158         - standard
2159       description: 'Submits a new surgery'
2160       parameters:
2161         -
2162           name: pid
2163           in: path
2164           description: 'The pid for the patient.'
2165           required: true
2166           schema:
2167             type: string
2168       requestBody:
2169         required: true
2170         content:
2171           application/json:
2172             schema:
2173               $ref: '#/components/schemas/api_surgery_request'
2174       responses:
2175         '200':
2176           $ref: '#/components/responses/standard'
2177         '400':
2178           $ref: '#/components/responses/badrequest'
2179         '401':
2180           $ref: '#/components/responses/unauthorized'
2181       security:
2182         -
2183           openemr_auth: []
2184   '/api/patient/{pid}/surgery/{sid}':
2185     get:
2186       tags:
2187         - standard
2188       description: 'Retrieves a surgery for a patient'
2189       parameters:
2190         -
2191           name: pid
2192           in: path
2193           description: 'The id for the patient.'
2194           required: true
2195           schema:
2196             type: string
2197         -
2198           name: sid
2199           in: path
2200           description: 'The id for the surgery.'
2201           required: true
2202           schema:
2203             type: string
2204       responses:
2205         '200':
2206           $ref: '#/components/responses/standard'
2207         '400':
2208           $ref: '#/components/responses/badrequest'
2209         '401':
2210           $ref: '#/components/responses/unauthorized'
2211       security:
2212         -
2213           openemr_auth: []
2214     put:
2215       tags:
2216         - standard
2217       description: 'Edit a surgery'
2218       parameters:
2219         -
2220           name: pid
2221           in: path
2222           description: 'The pid for the patient.'
2223           required: true
2224           schema:
2225             type: string
2226         -
2227           name: sid
2228           in: path
2229           description: 'The id for the surgery.'
2230           required: true
2231           schema:
2232             type: string
2233       requestBody:
2234         required: true
2235         content:
2236           application/json:
2237             schema:
2238               $ref: '#/components/schemas/api_surgery_request'
2239       responses:
2240         '200':
2241           $ref: '#/components/responses/standard'
2242         '400':
2243           $ref: '#/components/responses/badrequest'
2244         '401':
2245           $ref: '#/components/responses/unauthorized'
2246       security:
2247         -
2248           openemr_auth: []
2249     delete:
2250       tags:
2251         - standard
2252       description: 'Delete a surgery'
2253       parameters:
2254         -
2255           name: pid
2256           in: path
2257           description: 'The id for the patient.'
2258           required: true
2259           schema:
2260             type: string
2261         -
2262           name: sid
2263           in: path
2264           description: 'The id for the surgery.'
2265           required: true
2266           schema:
2267             type: string
2268       responses:
2269         '200':
2270           $ref: '#/components/responses/standard'
2271         '400':
2272           $ref: '#/components/responses/badrequest'
2273         '401':
2274           $ref: '#/components/responses/unauthorized'
2275       security:
2276         -
2277           openemr_auth: []
2278   '/api/patient/{pid}/dental_issue':
2279     get:
2280       tags:
2281         - standard
2282       description: 'Retrieves all dental issues for a patient'
2283       parameters:
2284         -
2285           name: pid
2286           in: path
2287           description: 'The pid for the patient.'
2288           required: true
2289           schema:
2290             type: string
2291       responses:
2292         '200':
2293           $ref: '#/components/responses/standard'
2294         '400':
2295           $ref: '#/components/responses/badrequest'
2296         '401':
2297           $ref: '#/components/responses/unauthorized'
2298       security:
2299         -
2300           openemr_auth: []
2301     post:
2302       tags:
2303         - standard
2304       description: 'Submits a new dental issue'
2305       parameters:
2306         -
2307           name: pid
2308           in: path
2309           description: 'The pid for the patient.'
2310           required: true
2311           schema:
2312             type: string
2313       requestBody:
2314         required: true
2315         content:
2316           application/json:
2317             schema:
2318               $ref: '#/components/schemas/api_dental_issue_request'
2319       responses:
2320         '200':
2321           $ref: '#/components/responses/standard'
2322         '400':
2323           $ref: '#/components/responses/badrequest'
2324         '401':
2325           $ref: '#/components/responses/unauthorized'
2326       security:
2327         -
2328           openemr_auth: []
2329   '/api/patient/{pid}/dental_issue/{did}':
2330     get:
2331       tags:
2332         - standard
2333       description: 'Retrieves a dental issue for a patient'
2334       parameters:
2335         -
2336           name: pid
2337           in: path
2338           description: 'The id for the patient.'
2339           required: true
2340           schema:
2341             type: string
2342         -
2343           name: did
2344           in: path
2345           description: 'The id for the dental issue.'
2346           required: true
2347           schema:
2348             type: string
2349       responses:
2350         '200':
2351           $ref: '#/components/responses/standard'
2352         '400':
2353           $ref: '#/components/responses/badrequest'
2354         '401':
2355           $ref: '#/components/responses/unauthorized'
2356       security:
2357         -
2358           openemr_auth: []
2359     put:
2360       tags:
2361         - standard
2362       description: 'Edit a dental issue'
2363       parameters:
2364         -
2365           name: pid
2366           in: path
2367           description: 'The pid for the patient.'
2368           required: true
2369           schema:
2370             type: string
2371         -
2372           name: did
2373           in: path
2374           description: 'The id for the dental issue.'
2375           required: true
2376           schema:
2377             type: string
2378       requestBody:
2379         required: true
2380         content:
2381           application/json:
2382             schema:
2383               $ref: '#/components/schemas/api_dental_issue_request'
2384       responses:
2385         '200':
2386           $ref: '#/components/responses/standard'
2387         '400':
2388           $ref: '#/components/responses/badrequest'
2389         '401':
2390           $ref: '#/components/responses/unauthorized'
2391       security:
2392         -
2393           openemr_auth: []
2394     delete:
2395       tags:
2396         - standard
2397       description: 'Delete a dental issue'
2398       parameters:
2399         -
2400           name: pid
2401           in: path
2402           description: 'The id for the patient.'
2403           required: true
2404           schema:
2405             type: string
2406         -
2407           name: did
2408           in: path
2409           description: 'The id for the dental issue.'
2410           required: true
2411           schema:
2412             type: string
2413       responses:
2414         '200':
2415           $ref: '#/components/responses/standard'
2416         '400':
2417           $ref: '#/components/responses/badrequest'
2418         '401':
2419           $ref: '#/components/responses/unauthorized'
2420       security:
2421         -
2422           openemr_auth: []
2423   '/api/patient/{pid}/appointment':
2424     get:
2425       tags:
2426         - standard
2427       description: 'Retrieves all appointments for a patient'
2428       parameters:
2429         -
2430           name: pid
2431           in: path
2432           description: 'The pid for the patient.'
2433           required: true
2434           schema:
2435             type: string
2436       responses:
2437         '200':
2438           $ref: '#/components/responses/standard'
2439         '400':
2440           $ref: '#/components/responses/badrequest'
2441         '401':
2442           $ref: '#/components/responses/unauthorized'
2443       security:
2444         -
2445           openemr_auth: []
2446     post:
2447       tags:
2448         - standard
2449       description: 'Submits a new appointment'
2450       parameters:
2451         -
2452           name: pid
2453           in: path
2454           description: 'The id for the patient.'
2455           required: true
2456           schema:
2457             type: string
2458       requestBody:
2459         required: true
2460         content:
2461           application/json:
2462             schema:
2463               required:
2464                 - pc_catid
2465                 - pc_title
2466                 - pc_duration
2467                 - pc_hometext
2468                 - pc_apptstatus
2469                 - pc_eventDate
2470                 - pc_startTime
2471                 - pc_facility
2472                 - pc_billing_location
2473               properties:
2474                 pc_catid:
2475                   description: 'The category of the appointment.'
2476                   type: string
2477                 pc_title:
2478                   description: 'The title of the appointment.'
2479                   type: string
2480                 pc_duration:
2481                   description: 'The duration of the appointment.'
2482                   type: string
2483                 pc_hometext:
2484                   description: 'Comments for the appointment.'
2485                   type: string
2486                 pc_apptstatus:
2487                   description: 'use an option from resource=/api/list/apptstat'
2488                   type: string
2489                 pc_eventDate:
2490                   description: 'The date of the appointment.'
2491                   type: string
2492                 pc_startTime:
2493                   description: 'The time of the appointment.'
2494                   type: string
2495                 pc_facility:
2496                   description: 'The facility id of the appointment.'
2497                   type: string
2498                 pc_billing_location:
2499                   description: 'The billinag location id of the appointment.'
2500                   type: string
2501               type: object
2502               example:
2503                 pc_catid: '5'
2504                 pc_title: 'Office Visit'
2505                 pc_duration: '900'
2506                 pc_hometext: Test
2507                 pc_apptstatus: '-'
2508                 pc_eventDate: '2018-10-19'
2509                 pc_startTime: '09:00'
2510                 pc_facility: '9'
2511                 pc_billing_location: '10'
2512       responses:
2513         '200':
2514           $ref: '#/components/responses/standard'
2515         '400':
2516           $ref: '#/components/responses/badrequest'
2517         '401':
2518           $ref: '#/components/responses/unauthorized'
2519       security:
2520         -
2521           openemr_auth: []
2522   /api/appointment:
2523     get:
2524       tags:
2525         - standard
2526       description: 'Retrieves all appointments'
2527       responses:
2528         '200':
2529           $ref: '#/components/responses/standard'
2530         '400':
2531           $ref: '#/components/responses/badrequest'
2532         '401':
2533           $ref: '#/components/responses/unauthorized'
2534       security:
2535         -
2536           openemr_auth: []
2537   '/api/appointment/{eid}':
2538     get:
2539       tags:
2540         - standard
2541       description: 'Retrieves an appointment'
2542       parameters:
2543         -
2544           name: eid
2545           in: path
2546           description: 'The eid for the appointment.'
2547           required: true
2548           schema:
2549             type: string
2550       responses:
2551         '200':
2552           $ref: '#/components/responses/standard'
2553         '400':
2554           $ref: '#/components/responses/badrequest'
2555         '401':
2556           $ref: '#/components/responses/unauthorized'
2557       security:
2558         -
2559           openemr_auth: []
2560   '/api/patient/{pid}/appointment/{eid}':
2561     get:
2562       tags:
2563         - standard
2564       description: 'Retrieves a appointment for a patient'
2565       parameters:
2566         -
2567           name: pid
2568           in: path
2569           description: 'The id for the patient.'
2570           required: true
2571           schema:
2572             type: string
2573         -
2574           name: eid
2575           in: path
2576           description: 'The eid for the appointment.'
2577           required: true
2578           schema:
2579             type: string
2580       responses:
2581         '200':
2582           $ref: '#/components/responses/standard'
2583         '400':
2584           $ref: '#/components/responses/badrequest'
2585         '401':
2586           $ref: '#/components/responses/unauthorized'
2587       security:
2588         -
2589           openemr_auth: []
2590     delete:
2591       tags:
2592         - standard
2593       description: 'Delete a appointment'
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   '/api/list/{list_name}':
2620     get:
2621       tags:
2622         - standard
2623       description: 'Retrieves a list'
2624       parameters:
2625         -
2626           name: list_name
2627           in: path
2628           description: 'The list_id of the list.'
2629           required: true
2630           schema:
2631             type: string
2632       responses:
2633         '200':
2634           $ref: '#/components/responses/standard'
2635         '400':
2636           $ref: '#/components/responses/badrequest'
2637         '401':
2638           $ref: '#/components/responses/unauthorized'
2639       security:
2640         -
2641           openemr_auth: []
2642   /api/version:
2643     get:
2644       tags:
2645         - standard
2646       description: 'Retrieves the OpenEMR version information'
2647       responses:
2648         '200':
2649           $ref: '#/components/responses/standard'
2650         '400':
2651           $ref: '#/components/responses/badrequest'
2652         '401':
2653           $ref: '#/components/responses/unauthorized'
2654       security:
2655         -
2656           openemr_auth: []
2657   /api/product:
2658     get:
2659       tags:
2660         - standard
2661       description: 'Retrieves the OpenEMR product registration information'
2662       responses:
2663         '200':
2664           $ref: '#/components/responses/standard'
2665         '400':
2666           $ref: '#/components/responses/badrequest'
2667         '401':
2668           $ref: '#/components/responses/unauthorized'
2669       security:
2670         -
2671           openemr_auth: []
2672   /api/insurance_company:
2673     get:
2674       tags:
2675         - standard
2676       description: 'Retrieves all insurance companies'
2677       responses:
2678         '200':
2679           $ref: '#/components/responses/standard'
2680         '400':
2681           $ref: '#/components/responses/badrequest'
2682         '401':
2683           $ref: '#/components/responses/unauthorized'
2684       security:
2685         -
2686           openemr_auth: []
2687     post:
2688       tags:
2689         - standard
2690       description: 'Submits a new insurance company'
2691       requestBody:
2692         required: true
2693         content:
2694           application/json:
2695             schema:
2696               $ref: '#/components/schemas/api_insurance_company_request'
2697       responses:
2698         '200':
2699           $ref: '#/components/responses/standard'
2700         '400':
2701           $ref: '#/components/responses/badrequest'
2702         '401':
2703           $ref: '#/components/responses/unauthorized'
2704       security:
2705         -
2706           openemr_auth: []
2707   '/api/insurance_company/{iid}':
2708     get:
2709       tags:
2710         - standard
2711       description: 'Retrieves insurance company'
2712       parameters:
2713         -
2714           name: iid
2715           in: path
2716           description: 'The id of the insurance company.'
2717           required: true
2718           schema:
2719             type: string
2720       responses:
2721         '200':
2722           $ref: '#/components/responses/standard'
2723         '400':
2724           $ref: '#/components/responses/badrequest'
2725         '401':
2726           $ref: '#/components/responses/unauthorized'
2727       security:
2728         -
2729           openemr_auth: []
2730     put:
2731       tags:
2732         - standard
2733       description: 'Edit a insurance company'
2734       parameters:
2735         -
2736           name: iid
2737           in: path
2738           description: 'The id for the insurance company.'
2739           required: true
2740           schema:
2741             type: string
2742       requestBody:
2743         required: true
2744         content:
2745           application/json:
2746             schema:
2747               $ref: '#/components/schemas/api_insurance_company_request'
2748       responses:
2749         '200':
2750           $ref: '#/components/responses/standard'
2751         '400':
2752           $ref: '#/components/responses/badrequest'
2753         '401':
2754           $ref: '#/components/responses/unauthorized'
2755       security:
2756         -
2757           openemr_auth: []
2758   /api/insurance_type:
2759     get:
2760       tags:
2761         - standard
2762       description: 'Retrieves all insurance types'
2763       responses:
2764         '200':
2765           $ref: '#/components/responses/standard'
2766         '400':
2767           $ref: '#/components/responses/badrequest'
2768         '401':
2769           $ref: '#/components/responses/unauthorized'
2770       security:
2771         -
2772           openemr_auth: []
2773   '/api/patient/{pid}/document':
2774     get:
2775       tags:
2776         - standard
2777       description: 'Retrieves all file information of documents from a category for a patient'
2778       parameters:
2779         -
2780           name: pid
2781           in: path
2782           description: 'The pid for the patient.'
2783           required: true
2784           schema:
2785             type: string
2786         -
2787           name: path
2788           in: query
2789           description: 'The category of the documents.'
2790           required: true
2791           schema:
2792             type: string
2793       responses:
2794         '200':
2795           $ref: '#/components/responses/standard'
2796         '400':
2797           $ref: '#/components/responses/badrequest'
2798         '401':
2799           $ref: '#/components/responses/unauthorized'
2800       security:
2801         -
2802           openemr_auth: []
2803     post:
2804       tags:
2805         - standard
2806       description: 'Submits a new patient document'
2807       parameters:
2808         -
2809           name: pid
2810           in: path
2811           description: 'The pid for the patient.'
2812           required: true
2813           schema:
2814             type: string
2815         -
2816           name: path
2817           in: query
2818           description: 'The category of the document.'
2819           required: true
2820           schema:
2821             type: string
2822       requestBody:
2823         required: true
2824         content:
2825           multipart/form-data:
2826             schema:
2827               properties:
2828                 document:
2829                   description: document
2830                   type: string
2831                   format: binary
2832               type: object
2833       responses:
2834         '200':
2835           $ref: '#/components/responses/standard'
2836         '400':
2837           $ref: '#/components/responses/badrequest'
2838         '401':
2839           $ref: '#/components/responses/unauthorized'
2840       security:
2841         -
2842           openemr_auth: []
2843   '/api/patient/{pid}/document/{did}':
2844     get:
2845       tags:
2846         - standard
2847       description: 'Retrieves a document for a patient'
2848       parameters:
2849         -
2850           name: pid
2851           in: path
2852           description: 'The pid for the patient.'
2853           required: true
2854           schema:
2855             type: string
2856         -
2857           name: did
2858           in: path
2859           description: 'The id for the patient document.'
2860           required: true
2861           schema:
2862             type: string
2863       responses:
2864         '200':
2865           $ref: '#/components/responses/standard'
2866         '400':
2867           $ref: '#/components/responses/badrequest'
2868         '401':
2869           $ref: '#/components/responses/unauthorized'
2870       security:
2871         -
2872           openemr_auth: []
2873   '/api/patient/{pid}/insurance':
2874     get:
2875       tags:
2876         - standard
2877       description: 'Retrieves all insurances for a patient'
2878       parameters:
2879         -
2880           name: pid
2881           in: path
2882           description: 'The pid for the patient.'
2883           required: true
2884           schema:
2885             type: string
2886       responses:
2887         '200':
2888           $ref: '#/components/responses/standard'
2889         '400':
2890           $ref: '#/components/responses/badrequest'
2891         '401':
2892           $ref: '#/components/responses/unauthorized'
2893       security:
2894         -
2895           openemr_auth: []
2896   '/api/patient/{pid}/insurance/{type}':
2897     get:
2898       tags:
2899         - standard
2900       description: 'Retrieves a insurance (by type) for a patient'
2901       parameters:
2902         -
2903           name: pid
2904           in: path
2905           description: 'The pid for the patient.'
2906           required: true
2907           schema:
2908             type: string
2909         -
2910           name: type
2911           in: path
2912           description: 'The insurance type for the patient. (options are ''primary'', ''secondary'', or ''tertiary'')'
2913           required: true
2914           schema:
2915             type: string
2916       responses:
2917         '200':
2918           $ref: '#/components/responses/standard'
2919         '400':
2920           $ref: '#/components/responses/badrequest'
2921         '401':
2922           $ref: '#/components/responses/unauthorized'
2923       security:
2924         -
2925           openemr_auth: []
2926     put:
2927       tags:
2928         - standard
2929       description: 'Edit a patient insurance (by type)'
2930       parameters:
2931         -
2932           name: pid
2933           in: path
2934           description: 'The pid for the patient.'
2935           required: true
2936           schema:
2937             type: string
2938         -
2939           name: type
2940           in: path
2941           description: 'The insurance type for the patient. (options are ''primary'', ''secondary'', or ''tertiary'')'
2942           required: true
2943           schema:
2944             type: string
2945       requestBody:
2946         required: true
2947         content:
2948           application/json:
2949             schema:
2950               $ref: '#/components/schemas/api_insurance_request'
2951       responses:
2952         '200':
2953           $ref: '#/components/responses/standard'
2954         '400':
2955           $ref: '#/components/responses/badrequest'
2956         '401':
2957           $ref: '#/components/responses/unauthorized'
2958       security:
2959         -
2960           openemr_auth: []
2961     post:
2962       tags:
2963         - standard
2964       description: 'Submits a new patient insurance (with type)'
2965       parameters:
2966         -
2967           name: pid
2968           in: path
2969           description: 'The pid for the patient.'
2970           required: true
2971           schema:
2972             type: string
2973         -
2974           name: type
2975           in: path
2976           description: 'The insurance type for the patient. (options are ''primary'', ''secondary'', or ''tertiary'')'
2977           required: true
2978           schema:
2979             type: string
2980       requestBody:
2981         required: true
2982         content:
2983           application/json:
2984             schema:
2985               $ref: '#/components/schemas/api_insurance_request'
2986       responses:
2987         '200':
2988           $ref: '#/components/responses/standard'
2989         '400':
2990           $ref: '#/components/responses/badrequest'
2991         '401':
2992           $ref: '#/components/responses/unauthorized'
2993       security:
2994         -
2995           openemr_auth: []
2996   '/api/patient/{pid}/message':
2997     post:
2998       tags:
2999         - standard
3000       description: 'Submits a pnote message'
3001       parameters:
3002         -
3003           name: pid
3004           in: path
3005           description: 'The id for the patient.'
3006           required: true
3007           schema:
3008             type: string
3009       requestBody:
3010         required: true
3011         content:
3012           application/json:
3013             schema:
3014               $ref: '#/components/schemas/api_message_request'
3015       responses:
3016         '200':
3017           $ref: '#/components/responses/standard'
3018         '400':
3019           $ref: '#/components/responses/badrequest'
3020         '401':
3021           $ref: '#/components/responses/unauthorized'
3022       security:
3023         -
3024           openemr_auth: []
3025   '/api/patient/{pid}/message/{mid}':
3026     put:
3027       tags:
3028         - standard
3029       description: 'Edit a pnote message'
3030       parameters:
3031         -
3032           name: pid
3033           in: path
3034           description: 'The id for the patient.'
3035           required: true
3036           schema:
3037             type: string
3038         -
3039           name: mid
3040           in: path
3041           description: 'The id for the pnote message.'
3042           required: true
3043           schema:
3044             type: string
3045       requestBody:
3046         required: true
3047         content:
3048           application/json:
3049             schema:
3050               $ref: '#/components/schemas/api_message_request'
3051       responses:
3052         '200':
3053           $ref: '#/components/responses/standard'
3054         '400':
3055           $ref: '#/components/responses/badrequest'
3056         '401':
3057           $ref: '#/components/responses/unauthorized'
3058       security:
3059         -
3060           openemr_auth: []
3061     delete:
3062       tags:
3063         - standard
3064       description: 'Delete a pnote message'
3065       parameters:
3066         -
3067           name: pid
3068           in: path
3069           description: 'The id for the patient.'
3070           required: true
3071           schema:
3072             type: string
3073         -
3074           name: eid
3075           in: path
3076           description: 'The id for the pnote message.'
3077           required: true
3078           schema:
3079             type: string
3080       responses:
3081         '200':
3082           $ref: '#/components/responses/standard'
3083         '400':
3084           $ref: '#/components/responses/badrequest'
3085         '401':
3086           $ref: '#/components/responses/unauthorized'
3087       security:
3088         -
3089           openemr_auth: []
3090   /api/immunization:
3091     get:
3092       tags:
3093         - standard
3094       description: 'Retrieves a list of immunizations'
3095       parameters:
3096         -
3097           name: patient_id
3098           in: query
3099           description: 'The pid for the patient.'
3100           required: false
3101           schema:
3102             type: string
3103         -
3104           name: id
3105           in: query
3106           description: 'The id for the immunization.'
3107           required: false
3108           schema:
3109             type: string
3110         -
3111           name: uuid
3112           in: query
3113           description: 'The uuid for the immunization.'
3114           required: false
3115           schema:
3116             type: string
3117         -
3118           name: administered_date
3119           in: query
3120           description: 'The administered date for the immunization.'
3121           required: false
3122           schema:
3123             type: string
3124         -
3125           name: immunization_id
3126           in: query
3127           description: 'The immunization list_id for the immunization.'
3128           required: false
3129           schema:
3130             type: string
3131         -
3132           name: cvx_code
3133           in: query
3134           description: 'The cvx code for the immunization.'
3135           required: false
3136           schema:
3137             type: string
3138         -
3139           name: manufacturer
3140           in: query
3141           description: 'The manufacturer for the immunization.'
3142           required: false
3143           schema:
3144             type: string
3145         -
3146           name: lot_number
3147           in: query
3148           description: 'The lot number for the immunization.'
3149           required: false
3150           schema:
3151             type: string
3152         -
3153           name: administered_by_id
3154           in: query
3155           description: 'The administered by id for the immunization.'
3156           required: false
3157           schema:
3158             type: string
3159         -
3160           name: administered_by
3161           in: query
3162           description: 'The administered by for the immunization.'
3163           required: false
3164           schema:
3165             type: string
3166         -
3167           name: education_date
3168           in: query
3169           description: 'The education date for the immunization.'
3170           required: false
3171           schema:
3172             type: string
3173         -
3174           name: vis_date
3175           in: query
3176           description: 'The vis date for the immunization.'
3177           required: false
3178           schema:
3179             type: string
3180         -
3181           name: note
3182           in: query
3183           description: 'The note for the immunization.'
3184           required: false
3185           schema:
3186             type: string
3187         -
3188           name: create_date
3189           in: query
3190           description: 'The create date for the immunization.'
3191           required: false
3192           schema:
3193             type: string
3194         -
3195           name: update_date
3196           in: query
3197           description: 'The update date for the immunization.'
3198           required: false
3199           schema:
3200             type: string
3201         -
3202           name: created_by
3203           in: query
3204           description: 'The created_by for the immunization.'
3205           required: false
3206           schema:
3207             type: string
3208         -
3209           name: updated_by
3210           in: query
3211           description: 'The updated_by for the immunization.'
3212           required: false
3213           schema:
3214             type: string
3215         -
3216           name: amount_administered
3217           in: query
3218           description: 'The amount administered for the immunization.'
3219           required: false
3220           schema:
3221             type: string
3222         -
3223           name: amount_administered_unit
3224           in: query
3225           description: 'The amount administered unit for the immunization.'
3226           required: false
3227           schema:
3228             type: string
3229         -
3230           name: expiration_date
3231           in: query
3232           description: 'The expiration date for the immunization.'
3233           required: false
3234           schema:
3235             type: string
3236         -
3237           name: route
3238           in: query
3239           description: 'The route for the immunization.'
3240           required: false
3241           schema:
3242             type: string
3243         -
3244           name: administration_site
3245           in: query
3246           description: 'The administration site for the immunization.'
3247           required: false
3248           schema:
3249             type: string
3250         -
3251           name: added_erroneously
3252           in: query
3253           description: 'The added_erroneously for the immunization.'
3254           required: false
3255           schema:
3256             type: string
3257         -
3258           name: external_id
3259           in: query
3260           description: 'The external_id for the immunization.'
3261           required: false
3262           schema:
3263             type: string
3264         -
3265           name: completion_status
3266           in: query
3267           description: 'The completion status for the immunization.'
3268           required: false
3269           schema:
3270             type: string
3271         -
3272           name: information_source
3273           in: query
3274           description: 'The information source for the immunization.'
3275           required: false
3276           schema:
3277             type: string
3278         -
3279           name: refusal_reason
3280           in: query
3281           description: 'The refusal reason for the immunization.'
3282           required: false
3283           schema:
3284             type: string
3285         -
3286           name: ordering_provider
3287           in: query
3288           description: 'The ordering provider for the immunization.'
3289           required: false
3290           schema:
3291             type: string
3292       responses:
3293         '200':
3294           $ref: '#/components/responses/standard'
3295         '400':
3296           $ref: '#/components/responses/badrequest'
3297         '401':
3298           $ref: '#/components/responses/unauthorized'
3299       security:
3300         -
3301           openemr_auth: []
3302   '/api/immunization/{uuid}':
3303     get:
3304       tags:
3305         - standard
3306       description: 'Retrieves a immunization'
3307       parameters:
3308         -
3309           name: uuid
3310           in: path
3311           description: 'The uuid for the immunization.'
3312           required: true
3313           schema:
3314             type: string
3315       responses:
3316         '200':
3317           $ref: '#/components/responses/standard'
3318         '400':
3319           $ref: '#/components/responses/badrequest'
3320         '401':
3321           $ref: '#/components/responses/unauthorized'
3322       security:
3323         -
3324           openemr_auth: []
3325   /api/procedure:
3326     get:
3327       tags:
3328         - standard
3329       description: 'Retrieves a list of all procedures'
3330       responses:
3331         '200':
3332           $ref: '#/components/responses/standard'
3333         '400':
3334           $ref: '#/components/responses/badrequest'
3335         '401':
3336           $ref: '#/components/responses/unauthorized'
3337       security:
3338         -
3339           openemr_auth: []
3340   '/api/procedure/{uuid}':
3341     get:
3342       tags:
3343         - standard
3344       description: 'Retrieves a procedure'
3345       parameters:
3346         -
3347           name: uuid
3348           in: path
3349           description: 'The uuid for the procedure.'
3350           required: true
3351           schema:
3352             type: string
3353       responses:
3354         '200':
3355           $ref: '#/components/responses/standard'
3356         '400':
3357           $ref: '#/components/responses/badrequest'
3358         '401':
3359           $ref: '#/components/responses/unauthorized'
3360       security:
3361         -
3362           openemr_auth: []
3363   /api/drug:
3364     get:
3365       tags:
3366         - standard
3367       description: 'Retrieves a list of all drugs'
3368       responses:
3369         '200':
3370           $ref: '#/components/responses/standard'
3371         '400':
3372           $ref: '#/components/responses/badrequest'
3373         '401':
3374           $ref: '#/components/responses/unauthorized'
3375       security:
3376         -
3377           openemr_auth: []
3378   '/api/drug/{uuid}':
3379     get:
3380       tags:
3381         - standard
3382       description: 'Retrieves a drug'
3383       parameters:
3384         -
3385           name: uuid
3386           in: path
3387           description: 'The uuid for the drug.'
3388           required: true
3389           schema:
3390             type: string
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/prescription:
3402     get:
3403       tags:
3404         - standard
3405       description: 'Retrieves a list of all prescriptions'
3406       responses:
3407         '200':
3408           $ref: '#/components/responses/standard'
3409         '400':
3410           $ref: '#/components/responses/badrequest'
3411         '401':
3412           $ref: '#/components/responses/unauthorized'
3413       security:
3414         -
3415           openemr_auth: []
3416   '/api/prescription/{uuid}':
3417     get:
3418       tags:
3419         - standard
3420       description: 'Retrieves a prescription'
3421       parameters:
3422         -
3423           name: uuid
3424           in: path
3425           description: 'The uuid for the prescription.'
3426           required: true
3427           schema:
3428             type: string
3429       responses:
3430         '200':
3431           $ref: '#/components/responses/standard'
3432         '400':
3433           $ref: '#/components/responses/badrequest'
3434         '401':
3435           $ref: '#/components/responses/unauthorized'
3436       security:
3437         -
3438           openemr_auth: []
3439   /fhir/AllergyIntolerance:
3440     get:
3441       tags:
3442         - fhir
3443       description: 'Returns a list of AllergyIntolerance resources.'
3444       parameters:
3445         -
3446           name: _id
3447           in: query
3448           description: 'The uuid for the AllergyIntolerance resource.'
3449           required: false
3450           schema:
3451             type: string
3452         -
3453           name: patient
3454           in: query
3455           description: 'The uuid for the patient.'
3456           required: false
3457           schema:
3458             type: string
3459       responses:
3460         '200':
3461           description: 'Standard Response'
3462           content:
3463             application/json:
3464               schema:
3465                 properties:
3466                   'json object': { description: 'FHIR Json object.', type: object }
3467                 type: object
3468                 example:
3469                   meta: { lastUpdated: '2021-09-14T09:13:51' }
3470                   resourceType: Bundle
3471                   type: collection
3472                   total: 0
3473                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/AllergyIntolerance' }]
3474         '400':
3475           $ref: '#/components/responses/badrequest'
3476         '401':
3477           $ref: '#/components/responses/unauthorized'
3478       security:
3479         -
3480           openemr_auth: []
3481   '/fhir/AllergyIntolerance/{uuid}':
3482     get:
3483       tags:
3484         - fhir
3485       description: 'Returns a single AllergyIntolerance resource.'
3486       parameters:
3487         -
3488           name: uuid
3489           in: path
3490           description: 'The uuid for the AllergyIntolerance resource.'
3491           required: true
3492           schema:
3493             type: string
3494       responses:
3495         '200':
3496           description: 'Standard Response'
3497           content:
3498             application/json:
3499               schema:
3500                 properties:
3501                   'json object': { description: 'FHIR Json object.', type: object }
3502                 type: object
3503                 example:
3504                   id: 94682fe5-f383-4885-9505-64b02e34906f
3505                   meta: { versionId: '1', lastUpdated: '2021-09-16T00:27:32+00:00' }
3506                   resourceType: AllergyIntolerance
3507                   text: { status: additional, div: '<div xmlns=''http://www.w3.org/1999/xhtml''>penicillin</div>' }
3508                   clinicalStatus: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/allergyintolerance-clinical', code: active, display: Active }] }
3509                   verificationStatus: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/allergyintolerance-verification', code: confirmed, display: Confirmed }] }
3510                   category: [medication]
3511                   criticality: low
3512                   code: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/data-absent-reason', code: unknown, display: Unknown }] }
3513                   patient: { reference: Patient/94682ef5-b0e3-4289-b19a-11b9592e9c92 }
3514                   reaction: [{ manifestation: [{ coding: [{ system: 'http://snomed.info/sct', code: '422587007', display: Nausea }], text: Nausea }] }]
3515         '400':
3516           $ref: '#/components/responses/badrequest'
3517         '401':
3518           $ref: '#/components/responses/unauthorized'
3519         '404':
3520           $ref: '#/components/responses/uuidnotfound'
3521       security:
3522         -
3523           openemr_auth: []
3524   /fhir/CarePlan:
3525     get:
3526       tags:
3527         - fhir
3528       description: 'Returns a list of CarePlan resources.'
3529       parameters:
3530         -
3531           name: _id
3532           in: query
3533           description: 'The uuid for the CarePlan resource.'
3534           required: false
3535           schema:
3536             type: string
3537         -
3538           name: patient
3539           in: query
3540           description: 'The uuid for the patient.'
3541           required: false
3542           schema:
3543             type: string
3544         -
3545           name: category
3546           in: query
3547           description: 'The category of the CarePlan resource.'
3548           required: false
3549           schema:
3550             type: string
3551       responses:
3552         '200':
3553           description: 'Standard Response'
3554           content:
3555             application/json:
3556               schema:
3557                 properties:
3558                   'json object': { description: 'FHIR Json object.', type: object }
3559                 type: object
3560                 example:
3561                   meta: { lastUpdated: '2021-09-14T09:13:51' }
3562                   resourceType: Bundle
3563                   type: collection
3564                   total: 0
3565                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/CarePlan' }]
3566         '400':
3567           $ref: '#/components/responses/badrequest'
3568         '401':
3569           $ref: '#/components/responses/unauthorized'
3570       security:
3571         -
3572           openemr_auth: []
3573   '/fhir/CarePlan/{uuid}':
3574     get:
3575       tags:
3576         - fhir
3577       description: 'Returns a single CarePlan resource.'
3578       parameters:
3579         -
3580           name: uuid
3581           in: path
3582           description: 'The uuid for the CarePlan resource.'
3583           required: true
3584           schema:
3585             type: string
3586       responses:
3587         '200':
3588           description: 'Standard Response'
3589           content:
3590             application/json:
3591               schema:
3592                 properties:
3593                   'json object': { description: 'FHIR Json object.', type: object }
3594                 type: object
3595                 example:
3596                   id: 94682f08-8fbc-451e-b1ec-f922d765c38f_1
3597                   meta: { versionId: '1', lastUpdated: '2021-09-16T00:54:18+00:00' }
3598                   resourceType: CarePlan
3599                   text: { status: generated, div: '<div xmlns="http://www.w3.org/1999/xhtml"><p>Treat flu.</p></div>' }
3600                   status: active
3601                   intent: plan
3602                   category: [{ coding: [{ system: 'http://hl7.org/fhir/us/core/CodeSystem/careplan-category', code: assess-plan }] }]
3603                   description: 'Treat flu.'
3604                   subject: { reference: Patient/94682ef5-b0e3-4289-b19a-11b9592e9c92, type: Patient }
3605         '400':
3606           $ref: '#/components/responses/badrequest'
3607         '401':
3608           $ref: '#/components/responses/unauthorized'
3609         '404':
3610           $ref: '#/components/responses/uuidnotfound'
3611       security:
3612         -
3613           openemr_auth: []
3614   /fhir/CareTeam:
3615     get:
3616       tags:
3617         - fhir
3618       description: 'Returns a list of CareTeam resources.'
3619       parameters:
3620         -
3621           name: _id
3622           in: query
3623           description: 'The uuid for the CareTeam resource.'
3624           required: false
3625           schema:
3626             type: string
3627         -
3628           name: patient
3629           in: query
3630           description: 'The uuid for the patient.'
3631           required: false
3632           schema:
3633             type: string
3634         -
3635           name: status
3636           in: query
3637           description: 'The status of the CarePlan resource.'
3638           required: false
3639           schema:
3640             type: string
3641       responses:
3642         '200':
3643           description: 'Standard Response'
3644           content:
3645             application/json:
3646               schema:
3647                 properties:
3648                   'json object': { description: 'FHIR Json object.', type: object }
3649                 type: object
3650                 example:
3651                   meta: { lastUpdated: '2021-09-14T09:13:51' }
3652                   resourceType: Bundle
3653                   type: collection
3654                   total: 0
3655                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/CareTeam' }]
3656         '400':
3657           $ref: '#/components/responses/badrequest'
3658         '401':
3659           $ref: '#/components/responses/unauthorized'
3660       security:
3661         -
3662           openemr_auth: []
3663   '/fhir/CareTeam/{uuid}':
3664     get:
3665       tags:
3666         - fhir
3667       description: 'Returns a single CareTeam resource.'
3668       parameters:
3669         -
3670           name: uuid
3671           in: path
3672           description: 'The uuid for the CareTeam resource.'
3673           required: true
3674           schema:
3675             type: string
3676       responses:
3677         '200':
3678           description: 'Standard Response'
3679           content:
3680             application/json:
3681               schema:
3682                 properties:
3683                   'json object': { description: 'FHIR Json object.', type: object }
3684                 type: object
3685                 example:
3686                   id: 94682f09-69fe-4ada-8ea6-753a52bd1516
3687                   meta: { versionId: '1', lastUpdated: '2021-09-16T01:07:22+00:00' }
3688                   resourceType: CareTeam
3689                   status: active
3690                   subject: { reference: Patient/94682ef5-b0e3-4289-b19a-11b9592e9c92, type: Patient }
3691                   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 } }]
3692         '400':
3693           $ref: '#/components/responses/badrequest'
3694         '401':
3695           $ref: '#/components/responses/unauthorized'
3696         '404':
3697           $ref: '#/components/responses/uuidnotfound'
3698       security:
3699         -
3700           openemr_auth: []
3701   /fhir/Condition:
3702     get:
3703       tags:
3704         - fhir
3705       description: 'Returns a list of Condition resources.'
3706       parameters:
3707         -
3708           name: _id
3709           in: query
3710           description: 'The uuid for the Condition resource.'
3711           required: false
3712           schema:
3713             type: string
3714         -
3715           name: patient
3716           in: query
3717           description: 'The uuid for the patient.'
3718           required: false
3719           schema:
3720             type: string
3721       responses:
3722         '200':
3723           description: 'Standard Response'
3724           content:
3725             application/json:
3726               schema:
3727                 properties:
3728                   'json object': { description: 'FHIR Json object.', type: object }
3729                 type: object
3730                 example:
3731                   meta: { lastUpdated: '2021-09-14T09:13:51' }
3732                   resourceType: Bundle
3733                   type: collection
3734                   total: 0
3735                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Condition' }]
3736         '400':
3737           $ref: '#/components/responses/badrequest'
3738         '401':
3739           $ref: '#/components/responses/unauthorized'
3740       security:
3741         -
3742           openemr_auth: []
3743   '/fhir/Condition/{uuid}':
3744     get:
3745       tags:
3746         - fhir
3747       description: 'Returns a single Condition resource.'
3748       parameters:
3749         -
3750           name: uuid
3751           in: path
3752           description: 'The uuid for the Condition resource.'
3753           required: true
3754           schema:
3755             type: string
3756       responses:
3757         '200':
3758           description: 'Standard Response'
3759           content:
3760             application/json:
3761               schema:
3762                 properties:
3763                   'json object': { description: 'FHIR Json object.', type: object }
3764                 type: object
3765                 example:
3766                   id: 94682c68-e5bb-4c5c-859a-cebaa5a1e582
3767                   meta: { versionId: '1', lastUpdated: '2021-09-16T02:41:53+00:00' }
3768                   resourceType: Condition
3769                   clinicalStatus: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/condition-clinical', code: inactive, display: Inactive }] }
3770                   verificationStatus: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/condition-ver-status', code: unconfirmed, display: Unconfirmed }] }
3771                   category: [{ coding: [{ system: 'http://terminology.hl7.org/CodeSystem/condition-category', code: problem-list-item, display: 'Problem List Item' }] }]
3772                   code: { coding: [{ system: 'http://snomed.info/sct', code: '444814009', display: '' }] }
3773                   subject: { reference: Patient/94682c62-d37e-48b5-8018-c5f6f3566609 }
3774         '400':
3775           $ref: '#/components/responses/badrequest'
3776         '401':
3777           $ref: '#/components/responses/unauthorized'
3778         '404':
3779           $ref: '#/components/responses/uuidnotfound'
3780       security:
3781         -
3782           openemr_auth: []
3783   /fhir/Coverage:
3784     get:
3785       tags:
3786         - fhir
3787       description: 'Returns a list of Coverage resources.'
3788       parameters:
3789         -
3790           name: _id
3791           in: query
3792           description: 'The uuid for the Coverage resource.'
3793           required: false
3794           schema:
3795             type: string
3796         -
3797           name: patient
3798           in: query
3799           description: 'The uuid for the patient.'
3800           required: false
3801           schema:
3802             type: string
3803         -
3804           name: payor
3805           in: query
3806           description: 'The payor of the Coverage resource.'
3807           required: false
3808           schema:
3809             type: string
3810       responses:
3811         '200':
3812           description: 'Standard Response'
3813           content:
3814             application/json:
3815               schema:
3816                 properties:
3817                   'json object': { description: 'FHIR Json object.', type: object }
3818                 type: object
3819                 example:
3820                   meta: { lastUpdated: '2021-09-14T09:13:51' }
3821                   resourceType: Bundle
3822                   type: collection
3823                   total: 0
3824                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Coverage' }]
3825         '400':
3826           $ref: '#/components/responses/badrequest'
3827         '401':
3828           $ref: '#/components/responses/unauthorized'
3829       security:
3830         -
3831           openemr_auth: []
3832   '/fhir/Coverage/{uuid}':
3833     get:
3834       tags:
3835         - fhir
3836       description: 'Returns a single Coverage resource.'
3837       parameters:
3838         -
3839           name: uuid
3840           in: path
3841           description: 'The uuid for the Coverage resource.'
3842           required: true
3843           schema:
3844             type: string
3845       responses:
3846         '200':
3847           $ref: '#/components/responses/standard'
3848         '400':
3849           $ref: '#/components/responses/badrequest'
3850         '401':
3851           $ref: '#/components/responses/unauthorized'
3852         '404':
3853           $ref: '#/components/responses/uuidnotfound'
3854       security:
3855         -
3856           openemr_auth: []
3857   /fhir/Device:
3858     get:
3859       tags:
3860         - fhir
3861       description: 'Returns a list of Device resources.'
3862       parameters:
3863         -
3864           name: _id
3865           in: query
3866           description: 'The uuid for the Device resource.'
3867           required: false
3868           schema:
3869             type: string
3870         -
3871           name: patient
3872           in: query
3873           description: 'The uuid for the patient.'
3874           required: false
3875           schema:
3876             type: string
3877       responses:
3878         '200':
3879           description: 'Standard Response'
3880           content:
3881             application/json:
3882               schema:
3883                 properties:
3884                   'json object': { description: 'FHIR Json object.', type: object }
3885                 type: object
3886                 example:
3887                   meta: { lastUpdated: '2021-09-14T09:13:51' }
3888                   resourceType: Bundle
3889                   type: collection
3890                   total: 0
3891                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Device' }]
3892         '400':
3893           $ref: '#/components/responses/badrequest'
3894         '401':
3895           $ref: '#/components/responses/unauthorized'
3896       security:
3897         -
3898           openemr_auth: []
3899   '/fhir/Device/{uuid}':
3900     get:
3901       tags:
3902         - fhir
3903       description: 'Returns a single Device resource.'
3904       parameters:
3905         -
3906           name: uuid
3907           in: path
3908           description: 'The uuid for the Device resource.'
3909           required: true
3910           schema:
3911             type: string
3912       responses:
3913         '200':
3914           description: 'Standard Response'
3915           content:
3916             application/json:
3917               schema:
3918                 properties:
3919                   'json object': { description: 'FHIR Json object.', type: object }
3920                 type: object
3921                 example:
3922                   id: 946dce19-c80a-402c-862a-eadf3f2377f0
3923                   meta: { versionId: '1', lastUpdated: '2021-09-18T19:28:59+00:00' }
3924                   resourceType: Device
3925                   udiCarrier: [{ deviceIdentifier: '08717648200274', carrierHRF: '=/08717648200274=,000025=A99971312345600=>014032=}013032&,1000000000000XYZ123' }]
3926                   distinctIdentifier: A99971312345600
3927                   manufactureDate: '2013-02-01'
3928                   expirationDate: '2014-02-01'
3929                   lotNumber: 000000000000XYZ123
3930                   serialNumber: '000025'
3931                   type: { extension: [{ valueCode: unknown, url: 'http://hl7.org/fhir/StructureDefinition/data-absent-reason' }] }
3932                   patient: { reference: Patient/946da619-c631-431a-a282-487cd6fb7802, type: Patient }
3933         '400':
3934           $ref: '#/components/responses/badrequest'
3935         '401':
3936           $ref: '#/components/responses/unauthorized'
3937         '404':
3938           $ref: '#/components/responses/uuidnotfound'
3939       security:
3940         -
3941           openemr_auth: []
3942   /fhir/DiagnosticReport:
3943     get:
3944       tags:
3945         - fhir
3946       description: 'Returns a list of DiagnosticReport resources.'
3947       parameters:
3948         -
3949           name: _id
3950           in: query
3951           description: 'The uuid for the DiagnosticReport resource.'
3952           required: false
3953           schema:
3954             type: string
3955         -
3956           name: patient
3957           in: query
3958           description: 'The uuid for the patient.'
3959           required: false
3960           schema:
3961             type: string
3962         -
3963           name: code
3964           in: query
3965           description: 'The code of the DiagnosticReport resource.'
3966           required: false
3967           schema:
3968             type: string
3969         -
3970           name: category
3971           in: query
3972           description: 'The category of the DiagnosticReport resource.'
3973           required: false
3974           schema:
3975             type: string
3976         -
3977           name: date
3978           in: query
3979           description: 'The datetime of the DiagnosticReport resource.'
3980           required: false
3981           schema:
3982             type: string
3983       responses:
3984         '200':
3985           description: 'Standard Response'
3986           content:
3987             application/json:
3988               schema:
3989                 properties:
3990                   'json object': { description: 'FHIR Json object.', type: object }
3991                 type: object
3992                 example:
3993                   meta: { lastUpdated: '2021-09-14T09:13:51' }
3994                   resourceType: Bundle
3995                   type: collection
3996                   total: 0
3997                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/DiagnosticReport' }]
3998         '400':
3999           $ref: '#/components/responses/badrequest'
4000         '401':
4001           $ref: '#/components/responses/unauthorized'
4002       security:
4003         -
4004           openemr_auth: []
4005   '/fhir/DiagnosticReport/{uuid}':
4006     get:
4007       tags:
4008         - fhir
4009       description: 'Returns a single DiagnosticReport resource.'
4010       parameters:
4011         -
4012           name: uuid
4013           in: path
4014           description: 'The uuid for the DiagnosticReport resource.'
4015           required: true
4016           schema:
4017             type: string
4018       responses:
4019         '200':
4020           description: 'Standard Response'
4021           content:
4022             application/json:
4023               schema:
4024                 properties:
4025                   'json object': { description: 'FHIR Json object.', type: object }
4026                 type: object
4027                 example:
4028                   id: 93fb2d6a-77ac-48ca-a12d-1a17e40007e3
4029                   meta: { versionId: '1', lastUpdated: '2021-09-18T20:52:34+00:00' }
4030                   resourceType: DiagnosticReport
4031                   status: final
4032                   category: [{ coding: [{ system: 'http://loinc.org', code: LP7839-6, display: Pathology }] }]
4033                   code: { coding: [{ system: 'http://loinc.org', code: 11502-2, display: 'Laboratory report' }] }
4034                   subject: { reference: Patient/9353b8f5-0a87-4e2a-afd4-25341fdb0fbc, type: Patient }
4035                   encounter: { reference: Encounter/93540818-cb5f-49df-b73b-83901bb793b6, type: Encounter }
4036                   effectiveDateTime: '2015-06-22T00:00:00+00:00'
4037                   issued: '2015-06-22T00:00:00+00:00'
4038                   performer: [{ reference: Organization/935249b5-0ba6-4b5b-8863-a7a27d4c6350, type: Organization }]
4039                   presentedForm: [{ contentType: text/plain, data: TXMgQWxpY2UgTmV3bWFuIHdhcyB0ZXN0ZWQgZm9yIHRoZSBVcmluYW5hbHlzaXMgbWFjcm8gcGFuZWwgYW5kIHRoZSByZXN1bHRzIGhhdmUgYmVlbiBmb3VuZCB0byBiZSANCm5vcm1hbC4= }]
4040         '400':
4041           $ref: '#/components/responses/badrequest'
4042         '401':
4043           $ref: '#/components/responses/unauthorized'
4044         '404':
4045           $ref: '#/components/responses/uuidnotfound'
4046       security:
4047         -
4048           openemr_auth: []
4049   /fhir/DocumentReference:
4050     get:
4051       tags:
4052         - fhir
4053       description: 'Returns a list of DocumentReference resources.'
4054       parameters:
4055         -
4056           name: _id
4057           in: query
4058           description: 'The uuid for the DocumentReference resource.'
4059           required: false
4060           schema:
4061             type: string
4062         -
4063           name: patient
4064           in: query
4065           description: 'The uuid for the patient.'
4066           required: false
4067           schema:
4068             type: string
4069         -
4070           name: type
4071           in: query
4072           description: 'The type of the DocumentReference resource.'
4073           required: false
4074           schema:
4075             type: string
4076         -
4077           name: category
4078           in: query
4079           description: 'The category of the DocumentReference resource.'
4080           required: false
4081           schema:
4082             type: string
4083         -
4084           name: date
4085           in: query
4086           description: 'The datetime of the DocumentReference resource.'
4087           required: false
4088           schema:
4089             type: string
4090       responses:
4091         '200':
4092           description: 'Standard Response'
4093           content:
4094             application/json:
4095               schema:
4096                 properties:
4097                   'json object': { description: 'FHIR Json object.', type: object }
4098                 type: object
4099                 example:
4100                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4101                   resourceType: Bundle
4102                   type: collection
4103                   total: 0
4104                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/DocumentReference' }]
4105         '400':
4106           $ref: '#/components/responses/badrequest'
4107         '401':
4108           $ref: '#/components/responses/unauthorized'
4109       security:
4110         -
4111           openemr_auth: []
4112   '/fhir/DocumentReference/{uuid}':
4113     get:
4114       tags:
4115         - fhir
4116       description: 'Returns a single DocumentReference resource.'
4117       parameters:
4118         -
4119           name: uuid
4120           in: path
4121           description: 'The uuid for the DocumentReference resource.'
4122           required: true
4123           schema:
4124             type: string
4125       responses:
4126         '200':
4127           description: 'Standard Response'
4128           content:
4129             application/json:
4130               schema:
4131                 properties:
4132                   'json object': { description: 'FHIR Json object.', type: object }
4133                 type: object
4134                 example:
4135                   id: 946e7553-1aaa-49f8-8f81-ae15ccaa9165
4136                   meta: { versionId: '1', lastUpdated: '2021-09-19T03:17:51+00:00' }
4137                   resourceType: DocumentReference
4138                   identifier: [{ value: 946e7553-1aaa-49f8-8f81-ae15ccaa9165 }]
4139                   status: current
4140                   type: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/v3-NullFlavor', code: UNK, display: unknown }] }
4141                   category: [{ coding: [{ system: 'https://localhost:9300/apis/default/fhir/ValueSet/openemr-document-types', code: openemr-document, display: 'OpenEMR Document' }] }]
4142                   subject: { reference: Patient/946da619-c631-431a-a282-487cd6fb7802, type: Patient }
4143                   date: '2021-09-19T03:15:56+00:00'
4144                   author: [null]
4145                   content: [{ attachment: { contentType: image/gif, url: 'https://localhost:9300/apis/default/fhir/Document/7/Binary' }, format: { system: 'http://ihe.net/fhir/ValueSet/IHE.FormatCode.codesystem', code: 'urn:ihe:iti:xds:2017:mimeTypeSufficient', display: 'mimeType Sufficient' } }]
4146         '400':
4147           $ref: '#/components/responses/badrequest'
4148         '401':
4149           $ref: '#/components/responses/unauthorized'
4150         '404':
4151           $ref: '#/components/responses/uuidnotfound'
4152       security:
4153         -
4154           openemr_auth: []
4155   '/fhir/Document/{id}/Binary':
4156     get:
4157       tags:
4158         - fhir
4159       description: 'THIS ENDPOINT DOCUMENTATION IS UNDER CONSTRUCTION.'
4160       parameters:
4161         -
4162           name: id
4163           in: path
4164           description: 'The id for the Document.'
4165           required: true
4166           schema:
4167             type: string
4168       responses:
4169         '200':
4170           $ref: '#/components/responses/standard'
4171         '400':
4172           $ref: '#/components/responses/badrequest'
4173         '401':
4174           $ref: '#/components/responses/unauthorized'
4175       security:
4176         -
4177           openemr_auth: []
4178   /fhir/Encounter:
4179     get:
4180       tags:
4181         - fhir
4182       description: 'Returns a list of Encounter resources.'
4183       parameters:
4184         -
4185           name: _id
4186           in: query
4187           description: 'The uuid for the Encounter resource.'
4188           required: false
4189           schema:
4190             type: string
4191         -
4192           name: patient
4193           in: query
4194           description: 'The uuid for the patient.'
4195           required: false
4196           schema:
4197             type: string
4198         -
4199           name: date
4200           in: query
4201           description: 'The datetime of the Encounter resource.'
4202           required: false
4203           schema:
4204             type: string
4205       responses:
4206         '200':
4207           description: 'Standard Response'
4208           content:
4209             application/json:
4210               schema:
4211                 properties:
4212                   'json object': { description: 'FHIR Json object.', type: object }
4213                 type: object
4214                 example:
4215                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4216                   resourceType: Bundle
4217                   type: collection
4218                   total: 0
4219                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Encounter' }]
4220         '400':
4221           $ref: '#/components/responses/badrequest'
4222         '401':
4223           $ref: '#/components/responses/unauthorized'
4224       security:
4225         -
4226           openemr_auth: []
4227   '/fhir/Encounter/{uuid}':
4228     get:
4229       tags:
4230         - fhir
4231       description: 'Returns a single Encounter resource.'
4232       parameters:
4233         -
4234           name: uuid
4235           in: path
4236           description: 'The uuid for the Encounter resource.'
4237           required: true
4238           schema:
4239             type: string
4240       responses:
4241         '200':
4242           description: 'Standard Response'
4243           content:
4244             application/json:
4245               schema:
4246                 properties:
4247                   'json object': { description: 'FHIR Json object.', type: object }
4248                 type: object
4249                 example:
4250                   id: 946da61d-6b95-4f8e-abe5-534a25913b71
4251                   meta: { versionId: '1', lastUpdated: '2021-09-19T06:27:41+00:00' }
4252                   resourceType: Encounter
4253                   identifier: [{ system: 'urn:ietf:rfc:3986', value: 946da61d-6b95-4f8e-abe5-534a25913b71 }]
4254                   status: finished
4255                   class: { system: 'http://terminology.hl7.org/CodeSystem/v3-ActCode', code: AMB, display: ambulatory }
4256                   type: [{ coding: [{ system: 'http://snomed.info/sct', code: '185349003', display: 'Encounter for check up (procedure)' }] }]
4257                   subject: { reference: Patient/946da61b-626b-4f88-81e2-adfb88f4f0fe, type: Patient }
4258                   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 } }]
4259                   period: { start: '2012-08-13T00:00:00+00:00' }
4260         '400':
4261           $ref: '#/components/responses/badrequest'
4262         '401':
4263           $ref: '#/components/responses/unauthorized'
4264         '404':
4265           $ref: '#/components/responses/uuidnotfound'
4266       security:
4267         -
4268           openemr_auth: []
4269   /fhir/Goal:
4270     get:
4271       tags:
4272         - fhir
4273       description: 'Returns a list of Condition resources.'
4274       parameters:
4275         -
4276           name: _id
4277           in: query
4278           description: 'The uuid for the Goal resource.'
4279           required: false
4280           schema:
4281             type: string
4282         -
4283           name: patient
4284           in: query
4285           description: 'The uuid for the patient.'
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/Goal' }]
4304         '400':
4305           $ref: '#/components/responses/badrequest'
4306         '401':
4307           $ref: '#/components/responses/unauthorized'
4308       security:
4309         -
4310           openemr_auth: []
4311   '/fhir/Goal/{uuid}':
4312     get:
4313       tags:
4314         - fhir
4315       description: 'Returns a single Goal resource.'
4316       parameters:
4317         -
4318           name: uuid
4319           in: path
4320           description: 'The uuid for the Goal 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: 946da61d-6b88-4d54-bdd6-4029e2ad9e3f_1
4335                   meta: { versionId: '1', lastUpdated: '2021-09-19T06:45:58+00:00' }
4336                   resourceType: Goal
4337                   lifecycleStatus: active
4338                   description: { text: 'Eating more vegetables.' }
4339                   subject: { reference: Patient/946da619-c631-431a-a282-487cd6fb7802, type: Patient }
4340                   target: [{ measure: { extension: [{ valueCode: unknown, url: 'http://hl7.org/fhir/StructureDefinition/data-absent-reason' }] }, detailString: 'Eating more vegetables.', dueDate: '2021-09-09' }]
4341         '400':
4342           $ref: '#/components/responses/badrequest'
4343         '401':
4344           $ref: '#/components/responses/unauthorized'
4345         '404':
4346           $ref: '#/components/responses/uuidnotfound'
4347       security:
4348         -
4349           openemr_auth: []
4350   /fhir/Group:
4351     get:
4352       tags:
4353         - fhir
4354       description: 'Returns a list of Group resources.'
4355       parameters:
4356         -
4357           name: _id
4358           in: query
4359           description: 'The uuid for the Group resource.'
4360           required: false
4361           schema:
4362             type: string
4363         -
4364           name: patient
4365           in: query
4366           description: 'The uuid for the patient.'
4367           required: false
4368           schema:
4369             type: string
4370       responses:
4371         '200':
4372           description: 'Standard Response'
4373           content:
4374             application/json:
4375               schema:
4376                 properties:
4377                   'json object': { description: 'FHIR Json object.', type: object }
4378                 type: object
4379                 example:
4380                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4381                   resourceType: Bundle
4382                   type: collection
4383                   total: 0
4384                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Group' }]
4385         '400':
4386           $ref: '#/components/responses/badrequest'
4387         '401':
4388           $ref: '#/components/responses/unauthorized'
4389       security:
4390         -
4391           openemr_auth: []
4392   '/fhir/Group/{uuid}':
4393     get:
4394       tags:
4395         - fhir
4396       description: 'Returns a single Group resource.'
4397       parameters:
4398         -
4399           name: uuid
4400           in: path
4401           description: 'The uuid for the Group resource.'
4402           required: true
4403           schema:
4404             type: string
4405       responses:
4406         '200':
4407           $ref: '#/components/responses/standard'
4408         '400':
4409           $ref: '#/components/responses/badrequest'
4410         '401':
4411           $ref: '#/components/responses/unauthorized'
4412         '404':
4413           $ref: '#/components/responses/uuidnotfound'
4414       security:
4415         -
4416           openemr_auth: []
4417   '/fhir/Group/{id}/$export':
4418     get:
4419       tags:
4420         - fhir
4421       description: 'THIS ENDPOINT DOCUMENTATION IS UNDER CONSTRUCTION.'
4422       responses:
4423         '200':
4424           $ref: '#/components/responses/standard'
4425         '400':
4426           $ref: '#/components/responses/badrequest'
4427         '401':
4428           $ref: '#/components/responses/unauthorized'
4429       security:
4430         -
4431           openemr_auth: []
4432   /fhir/Immunization:
4433     get:
4434       tags:
4435         - fhir
4436       description: 'Returns a list of Immunization resources.'
4437       parameters:
4438         -
4439           name: _id
4440           in: query
4441           description: 'The uuid for the Immunization resource.'
4442           required: false
4443           schema:
4444             type: string
4445         -
4446           name: patient
4447           in: query
4448           description: 'The uuid for the patient.'
4449           required: false
4450           schema:
4451             type: string
4452       responses:
4453         '200':
4454           description: 'Standard Response'
4455           content:
4456             application/json:
4457               schema:
4458                 properties:
4459                   'json object': { description: 'FHIR Json object.', type: object }
4460                 type: object
4461                 example:
4462                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4463                   resourceType: Bundle
4464                   type: collection
4465                   total: 0
4466                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Immunization' }]
4467         '400':
4468           $ref: '#/components/responses/badrequest'
4469         '401':
4470           $ref: '#/components/responses/unauthorized'
4471       security:
4472         -
4473           openemr_auth: []
4474   '/fhir/Immunization/{uuid}':
4475     get:
4476       tags:
4477         - fhir
4478       description: 'Returns a single Immunization resource.'
4479       parameters:
4480         -
4481           name: uuid
4482           in: path
4483           description: 'The uuid for the Immunization resource.'
4484           required: true
4485           schema:
4486             type: string
4487       responses:
4488         '200':
4489           $ref: '#/components/responses/standard'
4490         '400':
4491           $ref: '#/components/responses/badrequest'
4492         '401':
4493           $ref: '#/components/responses/unauthorized'
4494         '404':
4495           $ref: '#/components/responses/uuidnotfound'
4496       security:
4497         -
4498           openemr_auth: []
4499   /fhir/Location:
4500     get:
4501       tags:
4502         - fhir
4503       description: 'Returns a list of Location resources.'
4504       parameters:
4505         -
4506           name: _id
4507           in: query
4508           description: 'The uuid for the Location resource.'
4509           required: false
4510           schema:
4511             type: string
4512       responses:
4513         '200':
4514           description: 'Standard Response'
4515           content:
4516             application/json:
4517               schema:
4518                 properties:
4519                   'json object': { description: 'FHIR Json object.', type: object }
4520                 type: object
4521                 example:
4522                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4523                   resourceType: Bundle
4524                   type: collection
4525                   total: 0
4526                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Location' }]
4527         '400':
4528           $ref: '#/components/responses/badrequest'
4529         '401':
4530           $ref: '#/components/responses/unauthorized'
4531       security:
4532         -
4533           openemr_auth: []
4534   '/fhir/Location/{uuid}':
4535     get:
4536       tags:
4537         - fhir
4538       description: 'Returns a single Location resource.'
4539       parameters:
4540         -
4541           name: uuid
4542           in: path
4543           description: 'The uuid for the Location resource.'
4544           required: true
4545           schema:
4546             type: string
4547       responses:
4548         '200':
4549           description: 'Standard Response'
4550           content:
4551             application/json:
4552               schema:
4553                 properties:
4554                   'json object': { description: 'FHIR Json object.', type: object }
4555                 type: object
4556                 example:
4557                   id: 946da61d-c4f2-4f03-a2a7-b571f6a24b65
4558                   meta: { versionId: '1', lastUpdated: '2021-09-19T08:14:58+00:00' }
4559                   resourceType: Location
4560                   status: active
4561                   name: 'Your Clinic Name Here'
4562                   telecom: [{ system: phone, value: 000-000-0000 }, { system: fax, value: 000-000-0000 }]
4563         '400':
4564           $ref: '#/components/responses/badrequest'
4565         '401':
4566           $ref: '#/components/responses/unauthorized'
4567         '404':
4568           $ref: '#/components/responses/uuidnotfound'
4569       security:
4570         -
4571           openemr_auth: []
4572   /fhir/Medication:
4573     get:
4574       tags:
4575         - fhir
4576       description: 'Returns a list of Medication resources.'
4577       responses:
4578         '200':
4579           description: 'Standard Response'
4580           content:
4581             application/json:
4582               schema:
4583                 properties:
4584                   'json object': { description: 'FHIR Json object.', type: object }
4585                 type: object
4586                 example:
4587                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4588                   resourceType: Bundle
4589                   type: collection
4590                   total: 0
4591                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Medication' }]
4592         '400':
4593           $ref: '#/components/responses/badrequest'
4594         '401':
4595           $ref: '#/components/responses/unauthorized'
4596       security:
4597         -
4598           openemr_auth: []
4599   '/fhir/Medication/{uuid}':
4600     get:
4601       tags:
4602         - fhir
4603       description: 'Returns a single Medication resource.'
4604       parameters:
4605         -
4606           name: uuid
4607           in: path
4608           description: 'The uuid for the Medication resource.'
4609           required: true
4610           schema:
4611             type: string
4612       responses:
4613         '200':
4614           $ref: '#/components/responses/standard'
4615         '400':
4616           $ref: '#/components/responses/badrequest'
4617         '401':
4618           $ref: '#/components/responses/unauthorized'
4619         '404':
4620           $ref: '#/components/responses/uuidnotfound'
4621       security:
4622         -
4623           openemr_auth: []
4624   /fhir/MedicationRequest:
4625     get:
4626       tags:
4627         - fhir
4628       description: 'Returns a list of MedicationRequest resources.'
4629       parameters:
4630         -
4631           name: _id
4632           in: query
4633           description: 'The uuid for the MedicationRequest resource.'
4634           required: false
4635           schema:
4636             type: string
4637         -
4638           name: patient
4639           in: query
4640           description: 'The uuid for the patient.'
4641           required: false
4642           schema:
4643             type: string
4644         -
4645           name: intent
4646           in: query
4647           description: 'The intent of the MedicationRequest resource.'
4648           required: false
4649           schema:
4650             type: string
4651         -
4652           name: status
4653           in: query
4654           description: 'The status of the MedicationRequest resource.'
4655           required: false
4656           schema:
4657             type: string
4658       responses:
4659         '200':
4660           description: 'Standard Response'
4661           content:
4662             application/json:
4663               schema:
4664                 properties:
4665                   'json object': { description: 'FHIR Json object.', type: object }
4666                 type: object
4667                 example:
4668                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4669                   resourceType: Bundle
4670                   type: collection
4671                   total: 0
4672                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/MedicationRequest' }]
4673         '400':
4674           $ref: '#/components/responses/badrequest'
4675         '401':
4676           $ref: '#/components/responses/unauthorized'
4677       security:
4678         -
4679           openemr_auth: []
4680   '/fhir/MedicationRequest/{uuid}':
4681     get:
4682       tags:
4683         - fhir
4684       description: 'Returns a single MedicationRequest resource.'
4685       parameters:
4686         -
4687           name: uuid
4688           in: path
4689           description: 'The uuid for the MedicationRequest resource.'
4690           required: true
4691           schema:
4692             type: string
4693       responses:
4694         '200':
4695           description: 'Standard Response'
4696           content:
4697             application/json:
4698               schema:
4699                 properties:
4700                   'json object': { description: 'FHIR Json object.', type: object }
4701                 type: object
4702                 example:
4703                   id: 946da61d-9cff-4416-8d27-805f19f9d7d8
4704                   meta: { versionId: '1', lastUpdated: '2021-09-20T04:03:14+00:00' }
4705                   resourceType: MedicationRequest
4706                   status: active
4707                   intent: order
4708                   category: [{ coding: [{ system: 'http://terminology.hl7.org/CodeSystem/medicationrequest-category', code: community, display: Home/Community }] }]
4709                   reportedBoolean: false
4710                   medicationCodeableConcept: { coding: [{ system: 'http://www.nlm.nih.gov/research/umls/rxnorm', code: '1738139', display: 'Acetaminophen 325 MG Oral Tablet' }] }
4711                   subject: { reference: Patient/946da617-1a4a-4b2c-ae66-93b84377cb1e, type: Patient }
4712                   authoredOn: '2021-09-18T00:00:00+00:00'
4713                   requester: { reference: Practitioner/946da61d-ac5f-4fdc-b3f2-7b58dc49976b, type: Practitioner }
4714         '400':
4715           $ref: '#/components/responses/badrequest'
4716         '401':
4717           $ref: '#/components/responses/unauthorized'
4718         '404':
4719           $ref: '#/components/responses/uuidnotfound'
4720       security:
4721         -
4722           openemr_auth: []
4723   /fhir/Observation:
4724     get:
4725       tags:
4726         - fhir
4727       description: 'Returns a list of Observation resources.'
4728       parameters:
4729         -
4730           name: _id
4731           in: query
4732           description: 'The uuid for the Observation resource.'
4733           required: false
4734           schema:
4735             type: string
4736         -
4737           name: patient
4738           in: query
4739           description: 'The uuid for the patient.'
4740           required: false
4741           schema:
4742             type: string
4743         -
4744           name: code
4745           in: query
4746           description: 'The code of the Observation resource.'
4747           required: false
4748           schema:
4749             type: string
4750         -
4751           name: category
4752           in: query
4753           description: 'The category of the Observation resource.'
4754           required: false
4755           schema:
4756             type: string
4757         -
4758           name: date
4759           in: query
4760           description: 'The datetime of the Observation resource.'
4761           required: false
4762           schema:
4763             type: string
4764       responses:
4765         '200':
4766           description: 'Standard Response'
4767           content:
4768             application/json:
4769               schema:
4770                 properties:
4771                   'json object': { description: 'FHIR Json object.', type: object }
4772                 type: object
4773                 example:
4774                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4775                   resourceType: Bundle
4776                   type: collection
4777                   total: 0
4778                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Observation' }]
4779         '400':
4780           $ref: '#/components/responses/badrequest'
4781         '401':
4782           $ref: '#/components/responses/unauthorized'
4783       security:
4784         -
4785           openemr_auth: []
4786   '/fhir/Observation/{uuid}':
4787     get:
4788       tags:
4789         - fhir
4790       description: 'Returns a single Observation resource.'
4791       parameters:
4792         -
4793           name: uuid
4794           in: path
4795           description: 'The uuid for the Observation resource.'
4796           required: true
4797           schema:
4798             type: string
4799       responses:
4800         '200':
4801           description: 'Standard Response'
4802           content:
4803             application/json:
4804               schema:
4805                 properties:
4806                   'json object': { description: 'FHIR Json object.', type: object }
4807                 type: object
4808                 example:
4809                   id: 946da61e-0597-485e-9dfd-a87205ea56b3
4810                   meta: { versionId: '1', lastUpdated: '2021-09-20T04:12:16+00:00' }
4811                   resourceType: Observation
4812                   status: final
4813                   category: [{ coding: [{ system: 'http://terminology.hl7.org/CodeSystem/observation-category', code: vital-signs }] }]
4814                   code: { coding: [{ system: 'http://loinc.org', code: 85354-9, display: 'Blood pressure systolic and diastolic' }] }
4815                   subject: { reference: Patient/946da619-c631-431a-a282-487cd6fb7802, type: Patient }
4816                   effectiveDateTime: '2015-08-31T00:00:00+00:00'
4817                   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]' } }]
4818         '400':
4819           $ref: '#/components/responses/badrequest'
4820         '401':
4821           $ref: '#/components/responses/unauthorized'
4822         '404':
4823           $ref: '#/components/responses/uuidnotfound'
4824       security:
4825         -
4826           openemr_auth: []
4827   /fhir/Organization:
4828     get:
4829       tags:
4830         - fhir
4831       description: 'Returns a list of Organization resources.'
4832       parameters:
4833         -
4834           name: _id
4835           in: query
4836           description: 'The uuid for the Organization resource.'
4837           required: false
4838           schema:
4839             type: string
4840         -
4841           name: name
4842           in: query
4843           description: 'The name of the Organization resource.'
4844           required: false
4845           schema:
4846             type: string
4847         -
4848           name: email
4849           in: query
4850           description: 'The email of the Organization resource.'
4851           required: false
4852           schema:
4853             type: string
4854         -
4855           name: phone
4856           in: query
4857           description: 'The phone of the Organization resource.'
4858           required: false
4859           schema:
4860             type: string
4861         -
4862           name: telecom
4863           in: query
4864           description: 'The telecom of the Organization resource.'
4865           required: false
4866           schema:
4867             type: string
4868         -
4869           name: address
4870           in: query
4871           description: 'The address of the Organization resource.'
4872           required: false
4873           schema:
4874             type: string
4875         -
4876           name: address-city
4877           in: query
4878           description: 'The address-city of the Organization resource.'
4879           required: false
4880           schema:
4881             type: string
4882         -
4883           name: address-postalcode
4884           in: query
4885           description: 'The address-postalcode of the Organization resource.'
4886           required: false
4887           schema:
4888             type: string
4889         -
4890           name: address-state
4891           in: query
4892           description: 'The address-state of the Organization resource.'
4893           required: false
4894           schema:
4895             type: string
4896       responses:
4897         '200':
4898           description: 'Standard Response'
4899           content:
4900             application/json:
4901               schema:
4902                 properties:
4903                   'json object': { description: 'FHIR Json object.', type: object }
4904                 type: object
4905                 example:
4906                   meta: { lastUpdated: '2021-09-14T09:13:51' }
4907                   resourceType: Bundle
4908                   type: collection
4909                   total: 0
4910                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Organization' }]
4911         '400':
4912           $ref: '#/components/responses/badrequest'
4913         '401':
4914           $ref: '#/components/responses/unauthorized'
4915       security:
4916         -
4917           openemr_auth: []
4918     post:
4919       tags:
4920         - fhir
4921       description: 'Adds a Organization resource.'
4922       requestBody:
4923         required: true
4924         content:
4925           application/json:
4926             schema:
4927               description: 'The json object for the Organization resource.'
4928               type: object
4929       responses:
4930         '200':
4931           $ref: '#/components/responses/standard'
4932         '400':
4933           $ref: '#/components/responses/badrequest'
4934         '401':
4935           $ref: '#/components/responses/unauthorized'
4936       security:
4937         -
4938           openemr_auth: []
4939   '/fhir/Organization/{uuid}':
4940     get:
4941       tags:
4942         - fhir
4943       description: 'Returns a single Organization resource.'
4944       parameters:
4945         -
4946           name: uuid
4947           in: path
4948           description: 'The uuid for the Organization resource.'
4949           required: true
4950           schema:
4951             type: string
4952       responses:
4953         '200':
4954           description: 'Standard Response'
4955           content:
4956             application/json:
4957               schema:
4958                 properties:
4959                   'json object': { description: 'FHIR Json object.', type: object }
4960                 type: object
4961                 example:
4962                   id: 946da616-fae2-409d-b24d-56425bfb3316
4963                   meta: { versionId: '1', lastUpdated: '2021-09-21T16:47:36+00:00' }
4964                   resourceType: Organization
4965                   text: { status: generated, div: '<div xmlns="http://www.w3.org/1999/xhtml"> <p>Your Clinic Name Here</p></div>' }
4966                   active: true
4967                   type: [{ coding: [{ system: 'http://terminology.hl7.org/CodeSystem/organization-type', code: prov, display: 'Healthcare Provider' }] }]
4968                   name: 'Your Clinic Name Here'
4969                   telecom: [{ system: phone, value: 000-000-0000, use: work }, { system: fax, value: 000-000-0000, use: work }]
4970                   address: [null]
4971         '400':
4972           $ref: '#/components/responses/badrequest'
4973         '401':
4974           $ref: '#/components/responses/unauthorized'
4975         '404':
4976           $ref: '#/components/responses/uuidnotfound'
4977       security:
4978         -
4979           openemr_auth: []
4980     put:
4981       tags:
4982         - fhir
4983       description: 'Modifies a Organization resource.'
4984       parameters:
4985         -
4986           name: uuid
4987           in: path
4988           description: 'The uuid for the organization.'
4989           required: true
4990           schema:
4991             type: string
4992       requestBody:
4993         required: true
4994         content:
4995           application/json:
4996             schema:
4997               description: 'The json object for the Organization resource.'
4998               type: object
4999       responses:
5000         '200':
5001           $ref: '#/components/responses/standard'
5002         '400':
5003           $ref: '#/components/responses/badrequest'
5004         '401':
5005           $ref: '#/components/responses/unauthorized'
5006       security:
5007         -
5008           openemr_auth: []
5009   /fhir/Patient:
5010     get:
5011       tags:
5012         - fhir
5013       description: 'Returns a list of Patient resources.'
5014       parameters:
5015         -
5016           name: _id
5017           in: query
5018           description: 'The uuid for the Patient resource.'
5019           required: false
5020           schema:
5021             type: string
5022         -
5023           name: identifier
5024           in: query
5025           description: 'The identifier of the Patient resource.'
5026           required: false
5027           schema:
5028             type: string
5029         -
5030           name: name
5031           in: query
5032           description: 'The name of the Patient resource.'
5033           required: false
5034           schema:
5035             type: string
5036         -
5037           name: birthdate
5038           in: query
5039           description: 'The birthdate of the Patient resource.'
5040           required: false
5041           schema:
5042             type: string
5043         -
5044           name: gender
5045           in: query
5046           description: 'The gender of the Patient resource.'
5047           required: false
5048           schema:
5049             type: string
5050         -
5051           name: address
5052           in: query
5053           description: 'The address of the Patient resource.'
5054           required: false
5055           schema:
5056             type: string
5057         -
5058           name: address-city
5059           in: query
5060           description: 'The address-city of the Patient resource.'
5061           required: false
5062           schema:
5063             type: string
5064         -
5065           name: address-postalcode
5066           in: query
5067           description: 'The address-postalcode of the Patient resource.'
5068           required: false
5069           schema:
5070             type: string
5071         -
5072           name: address-state
5073           in: query
5074           description: 'The address-state of the Patient resource.'
5075           required: false
5076           schema:
5077             type: string
5078         -
5079           name: email
5080           in: query
5081           description: 'The email of the Patient resource.'
5082           required: false
5083           schema:
5084             type: string
5085         -
5086           name: family
5087           in: query
5088           description: 'The family name of the Patient resource.'
5089           required: false
5090           schema:
5091             type: string
5092         -
5093           name: given
5094           in: query
5095           description: 'The given name of the Patient resource.'
5096           required: false
5097           schema:
5098             type: string
5099         -
5100           name: phone
5101           in: query
5102           description: 'The phone number of the Patient resource.'
5103           required: false
5104           schema:
5105             type: string
5106         -
5107           name: telecom
5108           in: query
5109           description: 'The fax number of the Patient resource.'
5110           required: false
5111           schema:
5112             type: string
5113       responses:
5114         '200':
5115           description: 'Standard Response'
5116           content:
5117             application/json:
5118               schema:
5119                 properties:
5120                   'json object': { description: 'FHIR Json object.', type: object }
5121                 type: object
5122                 example:
5123                   meta: { lastUpdated: '2021-09-14T09:13:51' }
5124                   resourceType: Bundle
5125                   type: collection
5126                   total: 0
5127                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Patient' }]
5128         '400':
5129           $ref: '#/components/responses/badrequest'
5130         '401':
5131           $ref: '#/components/responses/unauthorized'
5132       security:
5133         -
5134           openemr_auth: []
5135     post:
5136       tags:
5137         - fhir
5138       description: 'Adds a Patient resource.'
5139       requestBody:
5140         required: true
5141         content:
5142           application/json:
5143             schema:
5144               description: 'The json object for the Patient resource.'
5145               type: object
5146       responses:
5147         '200':
5148           $ref: '#/components/responses/standard'
5149         '400':
5150           $ref: '#/components/responses/badrequest'
5151         '401':
5152           $ref: '#/components/responses/unauthorized'
5153       security:
5154         -
5155           openemr_auth: []
5156   '/fhir/Patient/{uuid}':
5157     get:
5158       tags:
5159         - fhir
5160       description: 'Returns a single Patient resource.'
5161       parameters:
5162         -
5163           name: uuid
5164           in: path
5165           description: 'The uuid for the Patient resource.'
5166           required: true
5167           schema:
5168             type: string
5169       responses:
5170         '200':
5171           description: 'Standard Response'
5172           content:
5173             application/json:
5174               schema:
5175                 properties:
5176                   'json object': { description: 'FHIR Json object.', type: object }
5177                 type: object
5178                 example:
5179                   id: 946da617-1a4a-4b2c-ae66-93b84377cb1e
5180                   meta: { versionId: '1', lastUpdated: '2021-09-21T17:08:03+00:00' }
5181                   resourceType: Patient
5182                   text: { status: generated, div: '<div xmlns="http://www.w3.org/1999/xhtml"> <p>Aurore252 Von197</p></div>' }
5183                   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' }]
5184                   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' }]
5185                   active: true
5186                   name: [{ use: official, family: Von197, given: [Aurore252] }]
5187                   gender: female
5188                   birthDate: '1970-07-03'
5189                   address: [{ line: ['245 Crona Wall'], city: Boston, state: Massachusetts, postalCode: '02215', period: { start: '2020-09-21T17:08:03.532+00:00' } }]
5190                   communication: [{ language: { coding: [{ system: 'http://terminology.hl7.org/CodeSystem/data-absent-reason', code: unknown, display: Unknown }] } }]
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     put:
5201       tags:
5202         - fhir
5203       description: 'Modifies a Patient resource.'
5204       parameters:
5205         -
5206           name: uuid
5207           in: path
5208           description: 'The uuid for the Patient resource.'
5209           required: true
5210           schema:
5211             type: string
5212       requestBody:
5213         required: true
5214         content:
5215           application/json:
5216             schema:
5217               description: 'The json object for the Patient resource.'
5218               type: object
5219       responses:
5220         '200':
5221           $ref: '#/components/responses/standard'
5222         '400':
5223           $ref: '#/components/responses/badrequest'
5224         '401':
5225           $ref: '#/components/responses/unauthorized'
5226       security:
5227         -
5228           openemr_auth: []
5229   /fhir/Patient/$export:
5230     get:
5231       tags:
5232         - fhir
5233       description: 'THIS ENDPOINT DOCUMENTATION IS UNDER CONSTRUCTION.'
5234       responses:
5235         '200':
5236           $ref: '#/components/responses/standard'
5237         '400':
5238           $ref: '#/components/responses/badrequest'
5239         '401':
5240           $ref: '#/components/responses/unauthorized'
5241       security:
5242         -
5243           openemr_auth: []
5244   /fhir/Person:
5245     get:
5246       tags:
5247         - fhir
5248       description: 'Returns a list of Person resources.'
5249       parameters:
5250         -
5251           name: name
5252           in: query
5253           description: 'The name of the Person resource.'
5254           required: false
5255           schema:
5256             type: string
5257         -
5258           name: active
5259           in: query
5260           description: 'The active status of the Person resource.'
5261           required: false
5262           schema:
5263             type: string
5264         -
5265           name: address
5266           in: query
5267           description: 'The address of the Person resource.'
5268           required: false
5269           schema:
5270             type: string
5271         -
5272           name: address-city
5273           in: query
5274           description: 'The address-city of the Person resource.'
5275           required: false
5276           schema:
5277             type: string
5278         -
5279           name: address-postalcode
5280           in: query
5281           description: 'The address-postalcode of the Person resource.'
5282           required: false
5283           schema:
5284             type: string
5285         -
5286           name: address-state
5287           in: query
5288           description: 'The address-state of the Person resource.'
5289           required: false
5290           schema:
5291             type: string
5292         -
5293           name: email
5294           in: query
5295           description: 'The email of the Person resource.'
5296           required: false
5297           schema:
5298             type: string
5299         -
5300           name: family
5301           in: query
5302           description: 'The family name of the Person resource.'
5303           required: false
5304           schema:
5305             type: string
5306         -
5307           name: given
5308           in: query
5309           description: 'The given name of the Person resource.'
5310           required: false
5311           schema:
5312             type: string
5313         -
5314           name: phone
5315           in: query
5316           description: 'The phone number of the Person resource.'
5317           required: false
5318           schema:
5319             type: string
5320         -
5321           name: telecom
5322           in: query
5323           description: 'The fax number of the Person resource.'
5324           required: false
5325           schema:
5326             type: string
5327       responses:
5328         '200':
5329           description: 'Standard Response'
5330           content:
5331             application/json:
5332               schema:
5333                 properties:
5334                   'json object': { description: 'FHIR Json object.', type: object }
5335                 type: object
5336                 example:
5337                   meta: { lastUpdated: '2021-09-14T09:13:51' }
5338                   resourceType: Bundle
5339                   type: collection
5340                   total: 0
5341                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Person' }]
5342         '400':
5343           $ref: '#/components/responses/badrequest'
5344         '401':
5345           $ref: '#/components/responses/unauthorized'
5346       security:
5347         -
5348           openemr_auth: []
5349   '/fhir/Person/{uuid}':
5350     get:
5351       tags:
5352         - fhir
5353       description: 'Returns a single Person resource.'
5354       parameters:
5355         -
5356           name: uuid
5357           in: path
5358           description: 'The uuid for the Person resource.'
5359           required: true
5360           schema:
5361             type: string
5362       responses:
5363         '200':
5364           $ref: '#/components/responses/standard'
5365         '400':
5366           $ref: '#/components/responses/badrequest'
5367         '401':
5368           $ref: '#/components/responses/unauthorized'
5369         '404':
5370           $ref: '#/components/responses/uuidnotfound'
5371       security:
5372         -
5373           openemr_auth: []
5374   /fhir/Practitioner:
5375     get:
5376       tags:
5377         - fhir
5378       description: 'Returns a list of Practitioner resources.'
5379       parameters:
5380         -
5381           name: _id
5382           in: query
5383           description: 'The uuid for the Practitioner resource.'
5384           required: false
5385           schema:
5386             type: string
5387         -
5388           name: name
5389           in: query
5390           description: 'The name of the Practitioner resource.'
5391           required: false
5392           schema:
5393             type: string
5394         -
5395           name: active
5396           in: query
5397           description: 'The active status of the Practitioner resource.'
5398           required: false
5399           schema:
5400             type: string
5401         -
5402           name: address
5403           in: query
5404           description: 'The address of the Practitioner resource.'
5405           required: false
5406           schema:
5407             type: string
5408         -
5409           name: address-city
5410           in: query
5411           description: 'The address-city of the Practitioner resource.'
5412           required: false
5413           schema:
5414             type: string
5415         -
5416           name: address-postalcode
5417           in: query
5418           description: 'The address-postalcode of the Practitioner resource.'
5419           required: false
5420           schema:
5421             type: string
5422         -
5423           name: address-state
5424           in: query
5425           description: 'The address-state of the Practitioner resource.'
5426           required: false
5427           schema:
5428             type: string
5429         -
5430           name: email
5431           in: query
5432           description: 'The email of the Practitioner resource.'
5433           required: false
5434           schema:
5435             type: string
5436         -
5437           name: family
5438           in: query
5439           description: 'The family name of the Practitioner resource.'
5440           required: false
5441           schema:
5442             type: string
5443         -
5444           name: given
5445           in: query
5446           description: 'The given name of the Practitioner resource.'
5447           required: false
5448           schema:
5449             type: string
5450         -
5451           name: phone
5452           in: query
5453           description: 'The phone number of the Practitioner resource.'
5454           required: false
5455           schema:
5456             type: string
5457         -
5458           name: telecom
5459           in: query
5460           description: 'The fax number of the Practitioner resource.'
5461           required: false
5462           schema:
5463             type: string
5464       responses:
5465         '200':
5466           description: 'Standard Response'
5467           content:
5468             application/json:
5469               schema:
5470                 properties:
5471                   'json object': { description: 'FHIR Json object.', type: object }
5472                 type: object
5473                 example:
5474                   meta: { lastUpdated: '2021-09-14T09:13:51' }
5475                   resourceType: Bundle
5476                   type: collection
5477                   total: 0
5478                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Practitioner' }]
5479         '400':
5480           $ref: '#/components/responses/badrequest'
5481         '401':
5482           $ref: '#/components/responses/unauthorized'
5483       security:
5484         -
5485           openemr_auth: []
5486     post:
5487       tags:
5488         - fhir
5489       description: 'Adds a Practitioner resources.'
5490       requestBody:
5491         required: true
5492         content:
5493           application/json:
5494             schema:
5495               description: 'The json object for the Practitioner resource.'
5496               type: object
5497       responses:
5498         '200':
5499           $ref: '#/components/responses/standard'
5500         '400':
5501           $ref: '#/components/responses/badrequest'
5502         '401':
5503           $ref: '#/components/responses/unauthorized'
5504       security:
5505         -
5506           openemr_auth: []
5507   '/fhir/Practitioner/{uuid}':
5508     get:
5509       tags:
5510         - fhir
5511       description: 'Returns a single Practitioner resource.'
5512       parameters:
5513         -
5514           name: uuid
5515           in: path
5516           description: 'The uuid for the Practitioner resource.'
5517           required: true
5518           schema:
5519             type: string
5520       responses:
5521         '200':
5522           description: 'Standard Response'
5523           content:
5524             application/json:
5525               schema:
5526                 properties:
5527                   'json object': { description: 'FHIR Json object.', type: object }
5528                 type: object
5529                 example:
5530                   id: 9473b0cf-e969-4eaa-8044-51037767fa4f
5531                   meta: { versionId: '1', lastUpdated: '2021-09-21T17:41:57+00:00' }
5532                   resourceType: Practitioner
5533                   text: { status: generated, div: '<div xmlns="http://www.w3.org/1999/xhtml"> <p>Billy Smith</p></div>' }
5534                   identifier: [{ system: 'http://hl7.org/fhir/sid/us-npi', value: '11223344554543' }]
5535                   active: true
5536                   name: [{ use: official, family: Smith, given: [Billy] }]
5537         '400':
5538           $ref: '#/components/responses/badrequest'
5539         '401':
5540           $ref: '#/components/responses/unauthorized'
5541         '404':
5542           $ref: '#/components/responses/uuidnotfound'
5543       security:
5544         -
5545           openemr_auth: []
5546     put:
5547       tags:
5548         - fhir
5549       description: 'Modify a Practitioner resource.'
5550       parameters:
5551         -
5552           name: uuid
5553           in: path
5554           description: 'The uuid for the Practitioner resource.'
5555           required: true
5556           schema:
5557             type: string
5558       requestBody:
5559         required: true
5560         content:
5561           application/json:
5562             schema:
5563               description: 'The json object for the Practitioner resource.'
5564               type: object
5565       responses:
5566         '200':
5567           $ref: '#/components/responses/standard'
5568         '400':
5569           $ref: '#/components/responses/badrequest'
5570         '401':
5571           $ref: '#/components/responses/unauthorized'
5572       security:
5573         -
5574           openemr_auth: []
5575   /fhir/PractitionerRole:
5576     get:
5577       tags:
5578         - fhir
5579       description: 'Returns a list of PractitionerRole resources.'
5580       parameters:
5581         -
5582           name: specialty
5583           in: query
5584           description: 'The specialty of the PractitionerRole resource.'
5585           required: false
5586           schema:
5587             type: string
5588         -
5589           name: practitioner
5590           in: query
5591           description: 'The practitioner of the PractitionerRole resource.'
5592           required: false
5593           schema:
5594             type: string
5595       responses:
5596         '200':
5597           description: 'Standard Response'
5598           content:
5599             application/json:
5600               schema:
5601                 properties:
5602                   'json object': { description: 'FHIR Json object.', type: object }
5603                 type: object
5604                 example:
5605                   meta: { lastUpdated: '2021-09-14T09:13:51' }
5606                   resourceType: Bundle
5607                   type: collection
5608                   total: 0
5609                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/PractitionerRole' }]
5610         '400':
5611           $ref: '#/components/responses/badrequest'
5612         '401':
5613           $ref: '#/components/responses/unauthorized'
5614       security:
5615         -
5616           openemr_auth: []
5617   '/fhir/PractitionerRole/{uuid}':
5618     get:
5619       tags:
5620         - fhir
5621       description: 'Returns a single PractitionerRole resource.'
5622       parameters:
5623         -
5624           name: uuid
5625           in: path
5626           description: 'The uuid for the PractitionerRole resource.'
5627           required: true
5628           schema:
5629             type: string
5630       responses:
5631         '200':
5632           $ref: '#/components/responses/standard'
5633         '400':
5634           $ref: '#/components/responses/badrequest'
5635         '401':
5636           $ref: '#/components/responses/unauthorized'
5637         '404':
5638           $ref: '#/components/responses/uuidnotfound'
5639       security:
5640         -
5641           openemr_auth: []
5642   /fhir/Procedure:
5643     get:
5644       tags:
5645         - fhir
5646       description: 'Returns a list of Procedure resources.'
5647       parameters:
5648         -
5649           name: _id
5650           in: query
5651           description: 'The uuid for the Procedure resource.'
5652           required: false
5653           schema:
5654             type: string
5655         -
5656           name: patient
5657           in: query
5658           description: 'The uuid for the patient.'
5659           required: false
5660           schema:
5661             type: string
5662         -
5663           name: date
5664           in: query
5665           description: 'The datetime of the Procedure resource.'
5666           required: false
5667           schema:
5668             type: string
5669       responses:
5670         '200':
5671           description: 'Standard Response'
5672           content:
5673             application/json:
5674               schema:
5675                 properties:
5676                   'json object': { description: 'FHIR Json object.', type: object }
5677                 type: object
5678                 example:
5679                   meta: { lastUpdated: '2021-09-14T09:13:51' }
5680                   resourceType: Bundle
5681                   type: collection
5682                   total: 0
5683                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Procedure' }]
5684         '400':
5685           $ref: '#/components/responses/badrequest'
5686         '401':
5687           $ref: '#/components/responses/unauthorized'
5688       security:
5689         -
5690           openemr_auth: []
5691   '/fhir/Procedure/{uuid}':
5692     get:
5693       tags:
5694         - fhir
5695       description: 'Returns a single Procedure resource.'
5696       parameters:
5697         -
5698           name: uuid
5699           in: path
5700           description: 'The uuid for the Procedure resource.'
5701           required: true
5702           schema:
5703             type: string
5704       responses:
5705         '200':
5706           $ref: '#/components/responses/standard'
5707         '400':
5708           $ref: '#/components/responses/badrequest'
5709         '401':
5710           $ref: '#/components/responses/unauthorized'
5711         '404':
5712           $ref: '#/components/responses/uuidnotfound'
5713       security:
5714         -
5715           openemr_auth: []
5716   '/fhir/Provenance/{uuid}':
5717     get:
5718       tags:
5719         - fhir
5720       description: 'Returns a single Provenance resource.'
5721       parameters:
5722         -
5723           name: uuid
5724           in: path
5725           description: 'The uuid for the Provenance resource.'
5726           required: true
5727           schema:
5728             type: string
5729       responses:
5730         '200':
5731           $ref: '#/components/responses/standard'
5732         '400':
5733           $ref: '#/components/responses/badrequest'
5734         '401':
5735           $ref: '#/components/responses/unauthorized'
5736         '404':
5737           $ref: '#/components/responses/uuidnotfound'
5738       security:
5739         -
5740           openemr_auth: []
5741   /fhir/Provenance:
5742     get:
5743       tags:
5744         - fhir
5745       description: 'Returns a list of Provenance resources.'
5746       parameters:
5747         -
5748           name: _id
5749           in: query
5750           description: 'The uuid for the Provenance resource.'
5751           required: false
5752           schema:
5753             type: string
5754       responses:
5755         '200':
5756           description: 'Standard Response'
5757           content:
5758             application/json:
5759               schema:
5760                 properties:
5761                   'json object': { description: 'FHIR Json object.', type: object }
5762                 type: object
5763                 example:
5764                   meta: { lastUpdated: '2021-09-14T09:13:51' }
5765                   resourceType: Bundle
5766                   type: collection
5767                   total: 0
5768                   link: [{ relation: self, url: 'https://localhost:9300/apis/default/fhir/Provenance' }]
5769         '400':
5770           $ref: '#/components/responses/badrequest'
5771         '401':
5772           $ref: '#/components/responses/unauthorized'
5773       security:
5774         -
5775           openemr_auth: []
5776   /fhir/metadata:
5777     get:
5778       tags:
5779         - fhir
5780       description: 'Returns metadata (ie. CapabilityStatement resource) of the fhir server.'
5781       responses:
5782         '200':
5783           description: 'Return CapabilityStatement resource of the fhir server'
5784   /fhir/.well-known/smart-configuration:
5785     get:
5786       tags:
5787         - fhir
5788       description: 'Returns smart configuration of the fhir server.'
5789       responses:
5790         '200':
5791           description: 'Return smart configuration of the fhir server'
5792   /fhir/$export:
5793     get:
5794       tags:
5795         - fhir
5796       description: 'THIS ENDPOINT DOCUMENTATION IS UNDER CONSTRUCTION.'
5797       responses:
5798         '200':
5799           $ref: '#/components/responses/standard'
5800         '400':
5801           $ref: '#/components/responses/badrequest'
5802         '401':
5803           $ref: '#/components/responses/unauthorized'
5804       security:
5805         -
5806           openemr_auth: []
5807   /fhir/$bulkdata-status:
5808     get:
5809       tags:
5810         - fhir
5811       description: 'THIS ENDPOINT DOCUMENTATION IS UNDER CONSTRUCTION.'
5812       responses:
5813         '200':
5814           $ref: '#/components/responses/standard'
5815         '400':
5816           $ref: '#/components/responses/badrequest'
5817         '401':
5818           $ref: '#/components/responses/unauthorized'
5819       security:
5820         -
5821           openemr_auth: []
5822     delete:
5823       tags:
5824         - fhir
5825       description: 'THIS ENDPOINT DOCUMENTATION IS UNDER CONSTRUCTION.'
5826       responses:
5827         '200':
5828           $ref: '#/components/responses/standard'
5829         '400':
5830           $ref: '#/components/responses/badrequest'
5831         '401':
5832           $ref: '#/components/responses/unauthorized'
5833       security:
5834         -
5835           openemr_auth: []
5836   /portal/patient:
5837     get:
5838       tags:
5839         - standard-patient
5840       description: 'Returns the patient.'
5841       responses:
5842         '200':
5843           description: 'Standard response'
5844           content:
5845             application/json:
5846               schema:
5847                 $ref: '#/components/schemas/api_patient_response'
5848         '401':
5849           $ref: '#/components/responses/unauthorized'
5850       security:
5851         -
5852           openemr_auth: []
5853   /portal/patient/encounter:
5854     get:
5855       tags:
5856         - standard-patient
5857       description: 'Returns encounters for the patient.'
5858       responses:
5859         '200':
5860           $ref: '#/components/responses/standard'
5861         '400':
5862           $ref: '#/components/responses/badrequest'
5863         '401':
5864           $ref: '#/components/responses/unauthorized'
5865       security:
5866         -
5867           openemr_auth: []
5868   '/portal/patient/encounter/{euuid}':
5869     get:
5870       tags:
5871         - standard-patient
5872       description: 'Returns a selected encounter by its uuid.'
5873       parameters:
5874         -
5875           name: euuid
5876           in: path
5877           description: 'The uuid for the encounter.'
5878           required: true
5879           schema:
5880             type: string
5881       responses:
5882         '200':
5883           $ref: '#/components/responses/standard'
5884         '400':
5885           $ref: '#/components/responses/badrequest'
5886         '401':
5887           $ref: '#/components/responses/unauthorized'
5888       security:
5889         -
5890           openemr_auth: []
5891 components:
5892   schemas:
5893     api_patient_request:
5894       description: 'Schema for the patient request'
5895       required:
5896         - fname
5897         - lname
5898         - DOB
5899         - sex
5900       properties:
5901         title:
5902           description: 'The title of patient.'
5903           type: string
5904         fname:
5905           description: 'The fname of patient.'
5906           type: string
5907         mname:
5908           description: 'The mname of patient.'
5909           type: string
5910         lname:
5911           description: 'The lname of patient.'
5912           type: string
5913         street:
5914           description: 'The street address of patient.'
5915           type: string
5916         postal_code:
5917           description: 'The postal code of patient.'
5918           type: string
5919         city:
5920           description: 'The city of patient.'
5921           type: string
5922         state:
5923           description: 'The state of patient.'
5924           type: string
5925         country_code:
5926           description: 'The country code of patient.'
5927           type: string
5928         phone_contact:
5929           description: 'The phone contact of patient.'
5930           type: string
5931         DOB:
5932           description: 'The DOB of patient.'
5933           type: string
5934         sex:
5935           description: 'The lname of patient.'
5936           type: string
5937         race:
5938           description: 'The race of patient.'
5939           type: string
5940         ethnicity:
5941           description: 'The ethnicity of patient.'
5942           type: string
5943       type: object
5944       example:
5945         title: Mr
5946         fname: Foo
5947         mname: ''
5948         lname: Bar
5949         street: '456 Tree Lane'
5950         postal_code: '08642'
5951         city: FooTown
5952         state: FL
5953         country_code: US
5954         phone_contact: 123-456-7890
5955         DOB: '1992-02-02'
5956         sex: Male
5957         race: ''
5958         ethnicity: ''
5959     api_patient_response:
5960       description: 'Schema for the patient response'
5961       properties:
5962         validationErrors:
5963           description: 'Validation errors.'
5964           type: array
5965           items:
5966             type: object
5967         internalErrors:
5968           description: 'Internal errors.'
5969           type: array
5970           items:
5971             type: object
5972         data:
5973           description: 'Returned data.'
5974           type: array
5975           items:
5976             properties:
5977               id:
5978                 description: 'patient id'
5979                 type: string
5980               pid:
5981                 description: 'patient pid'
5982                 type: string
5983               pubpid:
5984                 description: 'patient public id'
5985                 type: string
5986               title:
5987                 description: 'patient title'
5988                 type: string
5989               fname:
5990                 description: 'patient first name'
5991                 type: string
5992               mname:
5993                 description: 'patient middle name'
5994                 type: string
5995               lname:
5996                 description: 'patient last name'
5997                 type: string
5998               ss:
5999                 description: 'patient social security number'
6000                 type: string
6001               street:
6002                 description: 'patient street address'
6003                 type: string
6004               postal_code:
6005                 description: 'patient postal code'
6006                 type: string
6007               city:
6008                 description: 'patient city'
6009                 type: string
6010               state:
6011                 description: 'patient state'
6012                 type: string
6013               county:
6014                 description: 'patient county'
6015                 type: string
6016               country_code:
6017                 description: 'patient country code'
6018                 type: string
6019               drivers_license:
6020                 description: 'patient drivers license id'
6021                 type: string
6022               contact_relationship:
6023                 description: 'patient contact relationship'
6024                 type: string
6025               phone_contact:
6026                 description: 'patient phone contact'
6027                 type: string
6028               phone_home:
6029                 description: 'patient home phone'
6030                 type: string
6031               phone_biz:
6032                 description: 'patient work phone'
6033                 type: string
6034               phone_cell:
6035                 description: 'patient mobile phone'
6036                 type: string
6037               email:
6038                 description: 'patient email'
6039                 type: string
6040               DOB:
6041                 description: 'patient DOB'
6042                 type: string
6043               sex:
6044                 description: 'patient sex (gender)'
6045                 type: string
6046               race:
6047                 description: 'patient race'
6048                 type: string
6049               ethnicity:
6050                 description: 'patient ethnicity'
6051                 type: string
6052               status:
6053                 description: 'patient status'
6054                 type: string
6055             type: object
6056       type: object
6057       example:
6058         validationErrors: []
6059         error_description: []
6060         data:
6061           id: '193'
6062           pid: '1'
6063           pubpid: ''
6064           title: Mr
6065           fname: Baz
6066           mname: ''
6067           lname: Bop
6068           ss: ''
6069           street: '456 Tree Lane'
6070           postal_code: '08642'
6071           city: FooTown
6072           state: FL
6073           county: ''
6074           country_code: US
6075           drivers_license: ''
6076           contact_relationship: ''
6077           phone_contact: 123-456-7890
6078           phone_home: ''
6079           phone_biz: ''
6080           phone_cell: ''
6081           email: ''
6082           DOB: '1992-02-03'
6083           sex: Male
6084           race: ''
6085           ethnicity: ''
6086           status: ''
6087     api_encounter_request:
6088       description: 'Schema for the encounter request'
6089       required:
6090         - pc_catid
6091         - class_code
6092       properties:
6093         date:
6094           description: 'The date of encounter.'
6095           type: string
6096         onset_date:
6097           description: 'The onset date of encounter.'
6098           type: string
6099         reason:
6100           description: 'The reason of encounter.'
6101           type: string
6102         facility:
6103           description: 'The facility of encounter.'
6104           type: string
6105         pc_catid:
6106           description: 'The pc_catid of encounter.'
6107           type: string
6108         facility_id:
6109           description: 'The facility id of encounter.'
6110           type: string
6111         billing_facility:
6112           description: 'The billing facility id of encounter.'
6113           type: string
6114         sensitivity:
6115           description: 'The sensitivity of encounter.'
6116           type: string
6117         referral_source:
6118           description: 'The referral source of encounter.'
6119           type: string
6120         pos_code:
6121           description: 'The pos_code of encounter.'
6122           type: string
6123         external_id:
6124           description: 'The external id of encounter.'
6125           type: string
6126         provider_id:
6127           description: 'The provider id of encounter.'
6128           type: string
6129         class_code:
6130           description: 'The class_code of encounter.'
6131           type: string
6132       type: object
6133       example:
6134         date: '2020-11-10'
6135         onset_date: ''
6136         reason: 'Pregnancy Test'
6137         facility: 'Owerri General Hospital'
6138         pc_catid: '5'
6139         facility_id: '3'
6140         billing_facility: '3'
6141         sensitivity: normal
6142         referral_source: ''
6143         pos_code: '0'
6144         external_id: ''
6145         provider_id: '1'
6146         class_code: AMB
6147     api_encounter_response:
6148       description: 'Schema for the encounter response'
6149       properties:
6150         validationErrors:
6151           description: 'Validation errors.'
6152           type: array
6153           items:
6154             type: object
6155         internalErrors:
6156           description: 'Internal errors.'
6157           type: array
6158           items:
6159             type: object
6160         data:
6161           description: 'Returned data.'
6162           type: array
6163           items:
6164             properties:
6165               id:
6166                 description: 'encounter id'
6167                 type: string
6168               uuid:
6169                 description: 'encounter uuid'
6170                 type: string
6171               date:
6172                 description: 'encounter date'
6173                 type: string
6174               reason:
6175                 description: 'encounter reason'
6176                 type: string
6177               facility:
6178                 description: 'encounter facility name'
6179                 type: string
6180               facility_id:
6181                 description: 'encounter facility id name'
6182                 type: string
6183               pid:
6184                 description: 'encounter for patient pid'
6185                 type: string
6186               onset_date:
6187                 description: 'encounter onset date'
6188                 type: string
6189               sensitivity:
6190                 description: 'encounter sensitivity'
6191                 type: string
6192               billing_note:
6193                 description: 'encounter billing note'
6194                 type: string
6195               pc_catid:
6196                 description: 'encounter pc_catid'
6197                 type: string
6198               last_level_billed:
6199                 description: 'encounter last_level_billed'
6200                 type: string
6201               last_level_closed:
6202                 description: 'encounter last_level_closed'
6203                 type: string
6204               last_stmt_date:
6205                 description: 'encounter last_stmt_date'
6206                 type: string
6207               stmt_count:
6208                 description: 'encounter stmt_count'
6209                 type: string
6210               provider_id:
6211                 description: 'provider id'
6212                 type: string
6213               supervisor_id:
6214                 description: 'encounter supervisor id'
6215                 type: string
6216               invoice_refno:
6217                 description: 'encounter invoice_refno'
6218                 type: string
6219               referral_source:
6220                 description: 'encounter referral source'
6221                 type: string
6222               billing_facility:
6223                 description: 'encounter billing facility id'
6224                 type: string
6225               external_id:
6226                 description: 'encounter external id'
6227                 type: string
6228               pos_code:
6229                 description: 'encounter pos_code'
6230                 type: string
6231               class_code:
6232                 description: 'encounter class_code'
6233                 type: string
6234               class_title:
6235                 description: 'encounter class_title'
6236                 type: string
6237               pc_catname:
6238                 description: 'encounter pc_catname'
6239                 type: string
6240               billing_facility_name:
6241                 description: 'encounter billing facility name'
6242                 type: string
6243             type: object
6244       type: object
6245       example:
6246         validationErrors: []
6247         error_description: []
6248         data:
6249           id: '1'
6250           uuid: 90c196f2-51cc-4655-8858-3a80aebff3ef
6251           date: '2019-09-14 00:00:00'
6252           reason: 'Pregnancy Test'
6253           facility: 'Owerri General Hospital'
6254           facility_id: '3'
6255           pid: '1'
6256           onset_date: '2019-04-20 00:00:00'
6257           sensitivity: normal
6258           billing_note: null
6259           pc_catid: '5'
6260           last_level_billed: '0'
6261           last_level_closed: '0'
6262           last_stmt_date: null
6263           stmt_count: '0'
6264           provider_id: '1'
6265           supervisor_id: '0'
6266           invoice_refno: ''
6267           referral_source: ''
6268           billing_facility: '3'
6269           external_id: ''
6270           pos_code: '0'
6271           class_code: AMB
6272           class_title: ambulatory
6273           pc_catname: 'Office Visit'
6274           billing_facility_name: 'Owerri General Hospital'
6275     api_vital_request:
6276       description: 'Schema for the vital request'
6277       properties:
6278         bps:
6279           description: 'The bps of vitals.'
6280           type: string
6281         bpd:
6282           description: 'The bpd of vitals.'
6283           type: string
6284         weight:
6285           description: 'The weight of vitals. (unit is lb)'
6286           type: string
6287         height:
6288           description: 'The height of vitals. (unit is inches)'
6289           type: string
6290         temperature:
6291           description: 'The temperature of temperature. (unit is F)'
6292           type: string
6293         temp_method:
6294           description: 'The temp_method of vitals.'
6295           type: string
6296         pulse:
6297           description: 'The pulse of vitals.'
6298           type: string
6299         respiration:
6300           description: 'The respiration of vitals.'
6301           type: string
6302         note:
6303           description: 'The note (ie. comments) of vitals.'
6304           type: string
6305         waist_circ:
6306           description: 'The waist circumference of vitals. (unit is inches)'
6307           type: string
6308         head_circ:
6309           description: 'The head circumference of vitals. (unit is inches)'
6310           type: string
6311         oxygen_saturation:
6312           description: 'The oxygen_saturation of vitals.'
6313           type: string
6314       type: object
6315       example:
6316         bps: '130'
6317         bpd: '80'
6318         weight: '220'
6319         height: '70'
6320         temperature: '98'
6321         temp_method: Oral
6322         pulse: '60'
6323         respiration: '20'
6324         note: 'Patient with difficulty standing, which made weight measurement difficult.'
6325         waist_circ: '37'
6326         head_circ: '22.2'
6327         oxygen_saturation: '96'
6328     api_soap_note_request:
6329       description: 'Schema for the soap_note request'
6330       properties:
6331         subjective:
6332           description: 'The subjective of soap note.'
6333           type: string
6334         objective:
6335           description: 'The objective of soap note.'
6336           type: string
6337         assessment:
6338           description: 'The assessment of soap note.'
6339           type: string
6340         plan:
6341           description: 'The plan of soap note.'
6342           type: string
6343       type: object
6344       example:
6345         subjective: 'The patient with mechanical fall and cut finger.'
6346         objective: 'The patient with finger laceration on exam.'
6347         assessment: 'The patient with finger laceration requiring sutures.'
6348         plan: 'Sutured finger laceration.'
6349     api_medical_problem_request:
6350       description: 'Schema for the medical_problem request'
6351       required:
6352         - title
6353         - begdate
6354       properties:
6355         title:
6356           description: 'The title of medical problem.'
6357           type: string
6358         begdate:
6359           description: 'The beginning date of medical problem.'
6360           type: string
6361         enddate:
6362           description: 'The end date of medical problem.'
6363           type: string
6364         diagnosis:
6365           description: 'The diagnosis of medical problem. In format `<codetype>:<code>`'
6366           type: string
6367       type: object
6368       example:
6369         title: Dermatochalasis
6370         begdate: '2010-10-13'
6371         enddate: null
6372         diagnosis: 'ICD10:H02.839'
6373     api_allergy_request:
6374       description: 'Schema for the allergy request'
6375       required:
6376         - title
6377         - begdate
6378       properties:
6379         title:
6380           description: 'The title of allergy.'
6381           type: string
6382         begdate:
6383           description: 'The beginning date of allergy.'
6384           type: string
6385         enddate:
6386           description: 'The end date of allergy.'
6387           type: string
6388         diagnosis:
6389           description: 'The diagnosis of allergy. In format `<codetype>:<code>`'
6390           type: string
6391       type: object
6392       example:
6393         title: Iodine
6394         begdate: '2010-10-13'
6395         enddate: null
6396     api_medication_request:
6397       description: 'Schema for the medication request'
6398       required:
6399         - title
6400         - begdate
6401       properties:
6402         title:
6403           description: 'The title of medication.'
6404           type: string
6405         begdate:
6406           description: 'The beginning date of medication.'
6407           type: string
6408         enddate:
6409           description: 'The end date of medication.'
6410           type: string
6411         diagnosis:
6412           description: 'The diagnosis of medication. In format `<codetype>:<code>`'
6413           type: string
6414       type: object
6415       example:
6416         title: Norvasc
6417         begdate: '2013-04-13'
6418         enddate: null
6419     api_surgery_request:
6420       description: 'Schema for the surgery request'
6421       required:
6422         - title
6423         - begdate
6424       properties:
6425         title:
6426           description: 'The title of surgery.'
6427           type: string
6428         begdate:
6429           description: 'The beginning date of surgery.'
6430           type: string
6431         enddate:
6432           description: 'The end date of surgery.'
6433           type: string
6434         diagnosis:
6435           description: 'The diagnosis of surgery. In format `<codetype>:<code>`'
6436           type: string
6437       type: object
6438       example:
6439         title: Blepharoplasty
6440         begdate: '2013-10-14'
6441         enddate: null
6442         diagnosis: 'CPT4:15823-50'
6443     api_dental_issue_request:
6444       description: 'Schema for the dental_issue request'
6445       required:
6446         - title
6447         - begdate
6448       properties:
6449         title:
6450           description: 'The title of dental issue.'
6451           type: string
6452         begdate:
6453           description: 'The beginning date of dental issue.'
6454           type: string
6455         enddate:
6456           description: 'The end date of dental issue.'
6457           type: string
6458         diagnosis:
6459           description: 'The diagnosis of dental issue. In format `<codetype>:<code>`'
6460           type: string
6461       type: object
6462       example:
6463         title: Halitosis
6464         begdate: '2015-03-17'
6465         enddate: null
6466     api_insurance_company_request:
6467       description: 'Schema for the insurance_company request'
6468       required:
6469         - name
6470       properties:
6471         name:
6472           description: 'The name of insurance company.'
6473           type: string
6474         attn:
6475           description: 'The attn of insurance company.'
6476           type: string
6477         cms_id:
6478           description: 'The cms id of insurance company.'
6479           type: string
6480         ins_type_code:
6481           description: 'The insurance type code of insurance company. The insurance type code can be found by inspecting the route at (/api/insurance_type).'
6482           type: string
6483         x12_receiver_id:
6484           description: 'The x12 receiver id of insurance company.'
6485           type: string
6486         x12_default_partner_id:
6487           description: 'The x12 default partner id of insurance company.'
6488           type: string
6489         alt_cms_id:
6490           description: 'The alternate cms id of insurance company.'
6491           type: string
6492         line1:
6493           description: 'The line1 address of insurance company.'
6494           type: string
6495         line2:
6496           description: 'The line2 address of insurance company.'
6497           type: string
6498         city:
6499           description: 'The city of insurance company.'
6500           type: string
6501         state:
6502           description: 'The state of insurance company.'
6503           type: string
6504         zip:
6505           description: 'The zip of insurance company.'
6506           type: string
6507         country:
6508           description: 'The country of insurance company.'
6509           type: string
6510       type: object
6511       example:
6512         name: 'Cool Insurance Company'
6513         attn: null
6514         cms_id: null
6515         ins_type_code: '2'
6516         x12_receiver_id: null
6517         x12_default_partner_id: null
6518         alt_cms_id: ''
6519         line1: '123 Cool Lane'
6520         line2: 'Suite 123'
6521         city: Cooltown
6522         state: CA
6523         zip: '12245'
6524         country: USA
6525     api_insurance_request:
6526       description: 'Schema for the insurance request'
6527       required:
6528         - provider
6529         - plan_name
6530         - policy_number
6531         - group_number
6532         - subscriber_fname
6533         - subscriber_lname
6534         - subscriber_relationship
6535         - subscriber_ss
6536         - subscriber_DOB
6537         - subscriber_street
6538         - subscriber_postal_code
6539         - subscriber_city
6540         - subscriber_state
6541         - subscriber_country
6542         - subscriber_phone
6543         - subscriber_sex
6544         - accept_assignment
6545         - policy_type
6546       properties:
6547         provider:
6548           description: 'The insurance company id.'
6549           type: string
6550         plan_name:
6551           description: 'The plan name of insurance.'
6552           type: string
6553         policy_number:
6554           description: 'The policy number of insurance.'
6555           type: string
6556         group_number:
6557           description: 'The group number of insurance.'
6558           type: string
6559         subscriber_lname:
6560           description: 'The subscriber last name of insurance.'
6561           type: string
6562         subscriber_mname:
6563           description: 'The subscriber middle name of insurance.'
6564           type: string
6565         subscriber_fname:
6566           description: 'The subscriber first name of insurance.'
6567           type: string
6568         subscriber_relationship:
6569           description: 'The subscriber relationship of insurance.'
6570           type: string
6571         subscriber_ss:
6572           description: 'The subscriber ss number of insurance.'
6573           type: string
6574         subscriber_DOB:
6575           description: 'The subscriber DOB of insurance.'
6576           type: string
6577         subscriber_street:
6578           description: 'The subscriber street address of insurance.'
6579           type: string
6580         subscriber_postal_code:
6581           description: 'The subscriber postal code of insurance.'
6582           type: string
6583         subscriber_city:
6584           description: 'The subscriber city of insurance.'
6585           type: string
6586         subscriber_state:
6587           description: 'The subscriber state of insurance. `state` can be found by querying `resource=/api/list/state`'
6588           type: string
6589         subscriber_country:
6590           description: 'The subscriber country of insurance. `country` can be found by querying `resource=/api/list/country`'
6591           type: string
6592         subscriber_phone:
6593           description: 'The subscriber phone of insurance.'
6594           type: string
6595         subscriber_employer:
6596           description: 'The subscriber employer of insurance.'
6597           type: string
6598         subscriber_employer_street:
6599           description: 'The subscriber employer street of insurance.'
6600           type: string
6601         subscriber_employer_postal_code:
6602           description: 'The subscriber employer postal code of insurance.'
6603           type: string
6604         subscriber_employer_state:
6605           description: 'The subscriber employer state of insurance.'
6606           type: string
6607         subscriber_employer_country:
6608           description: 'The subscriber employer country of insurance.'
6609           type: string
6610         subscriber_employer_city:
6611           description: 'The subscriber employer city of insurance.'
6612           type: string
6613         copay:
6614           description: 'The copay of insurance.'
6615           type: string
6616         date:
6617           description: 'The date of insurance.'
6618           type: string
6619         subscriber_sex:
6620           description: 'The subscriber sex of insurance.'
6621           type: string
6622         accept_assignment:
6623           description: 'The accept_assignment of insurance.'
6624           type: string
6625         policy_type:
6626           description: 'The policy_type of insurance.'
6627           type: string
6628       type: object
6629       example:
6630         provider: '33'
6631         plan_name: 'Some Plan'
6632         policy_number: '12345'
6633         group_number: '252412'
6634         subscriber_lname: Tester
6635         subscriber_mname: Xi
6636         subscriber_fname: Foo
6637         subscriber_relationship: other
6638         subscriber_ss: '234231234'
6639         subscriber_DOB: '2018-10-03'
6640         subscriber_street: '183 Cool St'
6641         subscriber_postal_code: '23418'
6642         subscriber_city: Cooltown
6643         subscriber_state: AZ
6644         subscriber_country: USA
6645         subscriber_phone: 234-598-2123
6646         subscriber_employer: 'Some Employer'
6647         subscriber_employer_street: '123 Heather Lane'
6648         subscriber_employer_postal_code: '23415'
6649         subscriber_employer_state: AZ
6650         subscriber_employer_country: USA
6651         subscriber_employer_city: Cooltown
6652         copay: '35'
6653         date: '2018-10-15'
6654         subscriber_sex: Female
6655         accept_assignment: 'TRUE'
6656         policy_type: a
6657     api_message_request:
6658       description: 'Schema for the message request'
6659       required:
6660         - body
6661         - groupname
6662         - from
6663         - to
6664         - title
6665         - message_status
6666       properties:
6667         body:
6668           description: 'The body of message.'
6669           type: string
6670         groupname:
6671           description: 'The group name (usually is ''Default'').'
6672           type: string
6673         from:
6674           description: 'The sender of the message.'
6675           type: string
6676         to:
6677           description: 'The recipient of the message.'
6678           type: string
6679         title:
6680           description: 'use an option from resource=/api/list/note_type'
6681           type: string
6682         message_status:
6683           description: 'use an option from resource=/api/list/message_status'
6684           type: string
6685       type: object
6686       example:
6687         body: 'Test 456'
6688         groupname: Default
6689         from: Matthew
6690         to: admin
6691         title: Other
6692         message_status: New
6693   responses:
6694     standard:
6695       description: 'Standard Response'
6696       content:
6697         application/json:
6698           schema:
6699             properties:
6700               validationErrors:
6701                 description: 'Validation errors.'
6702                 type: array
6703                 items:
6704                   type: object
6705               internalErrors:
6706                 description: 'Internal errors.'
6707                 type: array
6708                 items:
6709                   type: object
6710               data:
6711                 description: 'Returned data.'
6712                 type: array
6713                 items:
6714                   type: object
6715             type: object
6716             example:
6717               validationErrors: []
6718               error_description: []
6719               data: []
6720     badrequest:
6721       description: 'Bad Request'
6722       content:
6723         application/json:
6724           schema:
6725             properties:
6726               validationErrors:
6727                 description: 'Validation errors.'
6728                 type: object
6729             type: object
6730             example:
6731               validationErrors:
6732                 _id: 'The search field argument was invalid, improperly formatted, or could not be parsed.  Inner message: UUID columns must be a valid UUID string'
6733     unauthorized:
6734       description: Unauthorized
6735       content:
6736         application/json:
6737           schema:
6738             properties:
6739               error:
6740                 description: 'The error.'
6741                 type: string
6742               error_description:
6743                 description: 'The description of the error.'
6744                 type: string
6745               hint:
6746                 description: 'More specific information on the error.'
6747                 type: string
6748               message:
6749                 description: 'Message regarding the error.'
6750                 type: string
6751             type: object
6752             example:
6753               error: access_denied
6754               error_description: 'The resource owner or authorization server denied the request.'
6755               hint: 'Missing "Authorization" header'
6756               message: 'The resource owner or authorization server denied the request.'
6757     uuidnotfound:
6758       description: 'Not Found'
6759       content:
6760         application/json:
6761           schema:
6762             properties:
6763               empty:
6764                 description: empty
6765                 type: object
6766             type: object
6767             example: []
6768   securitySchemes:
6769     openemr_auth:
6770       type: oauth2
6771       flows:
6772         authorizationCode:
6773           authorizationUrl: /oauth2/default/authorize
6774           tokenUrl: /oauth2/default/token
6775           refreshUrl: /oauth2/default/token
6776           scopes:
6777             openid: 'Generic mandatory scope'
6778             offline_access: 'Will signal server to provide a refresh token'
6779             'api:fhir': 'FHIR R4 API'
6780             patient/AllergyIntolerance.read: 'Read allergy intolerance resources for the current patient (api:fhir)'
6781             patient/CarePlan.read: 'Read care plan resources for the current patient (api:fhir)'
6782             patient/CareTeam.read: 'Read care team resources for the current patient (api:fhir)'
6783             patient/Condition.read: 'Read condition resources for the current patient (api:fhir)'
6784             patient/Device.read: 'Read device resources for the current patient (api:fhir)'
6785             patient/DiagnosticReport.read: 'Read diagnostic report resources for the current patient (api:fhir)'
6786             patient/DocumentReference.read: 'Read document reference resources for the current patient (api:fhir)'
6787             patient/Encounter.read: 'Read encounter resources for the current patient (api:fhir)'
6788             patient/Goal.read: 'Read goal resources for the current patient (api:fhir)'
6789             patient/Immunization.read: 'Read immunization resources for the current patient (api:fhir)'
6790             patient/Location.read: 'Read location resources for the current patient (api:fhir)'
6791             patient/Medication.read: 'Read medication resources for the current patient (api:fhir)'
6792             patient/MedicationRequest.read: 'Read medication request resources for the current patient (api:fhir)'
6793             patient/Observation.read: 'Read observation resources for the current patient (api:fhir)'
6794             patient/Organization.read: 'Read organization resources for the current patient (api:fhir)'
6795             patient/Patient.read: 'Read patient resource for the current patient (api:fhir)'
6796             patient/Person.read: 'Read person resources for the current patient (api:fhir)'
6797             patient/Practitioner.read: 'Read practitioner resources for the current patient (api:fhir)'
6798             patient/Procedure.read: 'Read procedure resources for the current patient (api:fhir)'
6799             patient/Provenance.read: 'Read provenance resources for the current patient (api:fhir)'
6800             system/AllergyIntolerance.read: 'Read all allergy intolerance resources in the system (api:fhir)'
6801             system/CarePlan.read: 'Read all care plan resources in the system (api:fhir)'
6802             system/CareTeam.read: 'Read all care team resources in the system (api:fhir)'
6803             system/Condition.read: 'Read all condition resources in the system (api:fhir)'
6804             system/Coverage.read: 'Read all coverage resources in the system (api:fhir)'
6805             system/Device.read: 'Read all device resources in the system (api:fhir)'
6806             system/DiagnosticReport.read: 'Read all diagnostic report resources in the system (api:fhir)'
6807             system/Document.read: 'Read all document resources in the system (api:fhir)'
6808             system/DocumentReference.read: 'Read all document reference resources in the system (api:fhir)'
6809             system/Encounter.read: 'Read all encounter resources in the system (api:fhir)'
6810             system/Goal.read: 'Read all goal resources in the system (api:fhir)'
6811             system/Group.read: 'Read all group resources in the system (api:fhir)'
6812             system/Immunization.read: 'Read all immunization resources in the system (api:fhir)'
6813             system/Location.read: 'Read all location resources in the system (api:fhir)'
6814             system/Medication.read: 'Read all medication resources in the system (api:fhir)'
6815             system/MedicationRequest.read: 'Read all medication request resources in the system (api:fhir)'
6816             system/Observation.read: 'Read all observation resources in the system (api:fhir)'
6817             system/Organization.read: 'Read all organization resources in the system (api:fhir)'
6818             system/Patient.read: 'Read all patient resources in the system (api:fhir)'
6819             system/Person.read: 'Read all person resources in the system (api:fhir)'
6820             system/Practitioner.read: 'Read all practitioner resources in the system (api:fhir)'
6821             system/PractitionerRole.read: 'Read all practitioner role resources in the system (api:fhir)'
6822             system/Procedure.read: 'Read all procedure resources in the system (api:fhir)'
6823             system/Provenance.read: 'Read all provenance resources in the system (api:fhir)'
6824             user/AllergyIntolerance.read: 'Read all allergy intolerance resources the user has access to (api:fhir)'
6825             user/CarePlan.read: 'Read all care plan resources the user has access to (api:fhir)'
6826             user/CareTeam.read: 'Read all care team resources the user has access to (api:fhir)'
6827             user/Condition.read: 'Read all condition resources the user has access to (api:fhir)'
6828             user/Coverage.read: 'Read all coverage resources the user has access to (api:fhir)'
6829             user/Device.read: 'Read all device resources the user has access to (api:fhir)'
6830             user/DiagnosticReport.read: 'Read all diagnostic report resources the user has access to (api:fhir)'
6831             user/DocumentReference.read: 'Read all document reference resources the user has access to (api:fhir)'
6832             user/Encounter.read: 'Read all encounter resources the user has access to (api:fhir)'
6833             user/Goal.read: 'Read all goal resources the user has access to (api:fhir)'
6834             user/Immunization.read: 'Read all immunization resources the user has access to (api:fhir)'
6835             user/Location.read: 'Read all location resources the user has access to (api:fhir)'
6836             user/Medication.read: 'Read all medication resources the user has access to (api:fhir)'
6837             user/MedicationRequest.read: 'Read all medication request resources the user has access to (api:fhir)'
6838             user/Observation.read: 'Read all observation resources the user has access to (api:fhir)'
6839             user/Organization.read: 'Read all organization resources the user has access to (api:fhir)'
6840             user/Organization.write: 'Write all organization resources the user has access to (api:fhir)'
6841             user/Patient.read: 'Read all patient resources the user has access to (api:fhir)'
6842             user/Patient.write: 'Write all patient resources the user has access to (api:fhir)'
6843             user/Person.read: 'Read all person resources the user has access to (api:fhir)'
6844             user/Practitioner.read: 'Read all practitioner resources the user has access to (api:fhir)'
6845             user/Practitioner.write: 'Write all practitioner resources the user has access to (api:fhir)'
6846             user/PractitionerRole.read: 'Read all practitioner role resources the user has access to (api:fhir)'
6847             user/Procedure.read: 'Read all procedure resources the user has access to (api:fhir)'
6848             user/Provenance.read: 'Read all provenance resources the user has access to (api:fhir)'
6849             'api:oemr': 'Standard OpenEMR API'
6850             user/allergy.read: 'Read allergies the user has access to (api:oemr)'
6851             user/allergy.write: 'Write allergies the user has access to for (api:oemr)'
6852             user/appointment.read: 'Read appointments the user has access to (api:oemr)'
6853             user/appointment.write: 'Write appointments the user has access to for (api:oemr)'
6854             user/dental_issue.read: 'Read dental issues the user has access to (api:oemr)'
6855             user/dental_issue.write: 'Write dental issues the user has access to (api:oemr)'
6856             user/document.read: 'Read documents the user has access to (api:oemr)'
6857             user/document.write: 'Write documents the user has access to (api:oemr)'
6858             user/drug.read: 'Read drugs the user has access to (api:oemr)'
6859             user/encounter.read: 'Read encounters the user has access to (api:oemr)'
6860             user/encounter.write: 'Write encounters the user has access to (api:oemr)'
6861             user/facility.read: 'Read facilities the user has access to (api:oemr)'
6862             user/facility.write: 'Write facilities the user has access to (api:oemr)'
6863             user/immunization.read: 'Read immunizations the user has access to (api:oemr)'
6864             user/insurance.read: 'Read insurances the user has access to (api:oemr)'
6865             user/insurance.write: 'Write insurances the user has access to (api:oemr)'
6866             user/insurance_company.read: 'Read insurance companies the user has access to (api:oemr)'
6867             user/insurance_company.write: 'Write insurance companies the user has access to (api:oemr)'
6868             user/insurance_type.read: 'Read insurance types the user has access to (api:oemr)'
6869             user/list.read: 'Read lists the user has access to (api:oemr)'
6870             user/medical_problem.read: 'Read medical problems the user has access to (api:oemr)'
6871             user/medical_problem.write: 'Write medical problems the user has access to (api:oemr)'
6872             user/medication.read: 'Read medications the user has access to (api:oemr)'
6873             user/medication.write: 'Write medications the user has access to (api:oemr)'
6874             user/message.write: 'Read messages the user has access to (api:oemr)'
6875             user/patient.read: 'Read patients the user has access to (api:oemr)'
6876             user/patient.write: 'Write patients the user has access to (api:oemr)'
6877             user/practitioner.read: 'Read practitioners the user has access to (api:oemr)'
6878             user/practitioner.write: 'Write practitioners the user has access to (api:oemr)'
6879             user/prescription.read: 'Read prescriptions the user has access to (api:oemr)'
6880             user/procedure.read: 'Read procedures the user has access to (api:oemr)'
6881             user/soap_note.read: 'Read soap notes the user has access to (api:oemr)'
6882             user/soap_note.write: 'Write soap notes the user has access to (api:oemr)'
6883             user/surgery.read: 'Read surgeries the user has access to (api:oemr)'
6884             user/surgery.write: 'Write surgeries the user has access to (api:oemr)'
6885             user/vital.read: 'Read vitals the user has access to (api:oemr)'
6886             user/vital.write: 'Write vitals the user has access to (api:oemr)'
6887             'api:port': 'Standard Patient Portal OpenEMR API'
6888             patient/encounter.read: 'Read encounters the patient has access to (api:port)'
6889             patient/patient.read: 'Write encounters the patient has access to (api:port)'
6890 tags:
6891   -
6892     name: fhir
6893     description: 'FHIR R4 API'
6894   -
6895     name: standard
6896     description: 'Standard OpenEMR API'
6897   -
6898     name: standard-patient
6899     description: 'Standard Patient Portal OpenEMR API'