openapi: 3.2.0 info: version: 1.0.0 title: NextGen Office FHIR Patient API description: 'Our API is coded against the US Core Specification (FHIR Version: 4.0.0) https://hl7.org/fhir/us/core/CapabilityStatement-server.html' contact: email: nextgen-office-api@nextgen.com servers: - url: https://fhir.meditouchehr.com/api/ security: - OauthSecurity: - patient/*.read tags: - name: Patient description: https://hl7.org/fhir/R4/patient.html paths: /fhir/r4/Patient/{id}: get: tags: - Patient description: "Fetches a single Patient by patient Id \n \n FHIR Resource: Patient.name.given \n * First Name \n *\tMiddle Name \n \n FHIR Resource: Patient.name.family \n *\tLast Name \n \n FHIR Resource: Patient.name \n *\tPrevious Name \n \n FHIR Resource: Patient.name.suffix \n *\tSuffix \n \n FHIR Resource: US Core Sex Extension \n *\tSex \n \n FHIR Resource: Patient.birthDate \n *\tDate of Birth \n \n FHIR Resource: US Core Race Extension \n *\tRace \n \n FHIR Resource: US Core Ethnicity Extension \n *\tEthnicity \n \n FHIR Resource: US Core Tribal Affiliation Extension \n *\tTribal Affiliation \n \n FHIR Resource: US Core Gender Identity Extension \n *\tGender Identity \n \n FHIR Resource: Patient.deceasedBoolean / Patient.deceasedDateTime \n * Deceased Status / Deceased Date \n \n FHIR Resource: Patient.communication \n *\tPreferred Language \n \n FHIR Resource: Patient.address \n *\tAddress \n \n FHIR Resource: Patient.telecom \n *\tPhone Number" parameters: - $ref: '#/components/parameters/id' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/Patient' '404': $ref: '#/components/responses/ResourceNotFound404' '401': $ref: '#/components/responses/ResourceNotAuthorized401' /fhir/r4/Patient: get: tags: - Patient description: "Fetches a bundled resource containing the valid patients mentioned in the request parameters. \n \n FHIR Resource: Patient.name.given \n * First Name \n *\tMiddle Name \n \n FHIR Resource: Patient.name.family \n *\tLast Name \n \n FHIR Resource: Patient.name \n *\tPrevious Name \n \n FHIR Resource: Patient.name.suffix \n *\tSuffix \n \n FHIR Resource: US Core Sex Extension \n * Sex \n \n FHIR Resource: Patient.birthDate \n *\tDate of Birth \n \n FHIR Resource: US Core Race Extension \n *\tRace \n \n FHIR Resource: US Core Ethnicity Extension \n *\tEthnicity \n \n FHIR Resource: US Core Tribal Affiliation Extension \n *\tTribal Affiliation \n \n FHIR Resource: US Core Gender Identity Extension \n *\tGender Identity \n \n FHIR Resource: Patient.deceasedBoolean / Patient.deceasedDateTime \n *\tDeceased Status / Deceased Date \n \n FHIR Resource: Patient.communication \n *\tPreferred Language \n \n FHIR Resource: Patient.address \n *\tAddress \n \n FHIR Resource: Patient.telecom \n *\tPhone Number" parameters: - $ref: '#/components/parameters/_id' - $ref: '#/components/parameters/patient_identifier' - $ref: '#/components/parameters/patient_name' - $ref: '#/components/parameters/patient_birthdate' - $ref: '#/components/parameters/patient_gender' responses: '200': description: Success content: application/json: schema: $ref: '#/components/schemas/PatientBundled' '404': $ref: '#/components/responses/ResourceNotFound404' '401': $ref: '#/components/responses/ResourceNotAuthorized401' components: schemas: Patient: type: object properties: resourceType: type: string minLength: 1 id: type: string minLength: 1 description: id of the resource active: type: boolean description: Whether this patient's record is in active use. identifier: type: array description: An identifier for the patient items: type: object properties: use: type: string type: type: object properties: coding: type: array items: type: object properties: system: type: string code: type: string display: type: string required: - system - code - display text: type: string System: type: string Value: type: string required: - use - type - System - Value telcom: type: array description: contact detail for the individual items: type: object properties: system: type: string use: type: string value: type: string name: type: array description: name associated with the patient items: type: object properties: use: type: string text: type: string family: type: string given: type: array items: type: string givenElement: type: array items: type: string address: type: array description: address of the patient items: type: object properties: line: type: array items: type: string city: type: string state: type: string postalCode: type: string period: type: object properties: start: format: date-time type: string end: format: date-time type: string use: type: string birthdate: format: date-time type: string extension: type: array items: type: object properties: url: type: string value: type: array items: type: object properties: system: type: string code: type: string display: type: string communication: description: language used to communicate with the patient type: array items: type: object properties: language: type: object properties: coding: type: array items: type: object properties: system: type: string code: type: string display: type: string text: type: string deceasedBoolean: type: boolean description: Indicates if the patient is deceased but date of death is not known. Mutually exclusive with 'deceasedDateTime'. deceasedDateTime: type: string format: date-time description: Date and time when the patient died. Only present if patient is deceased and a date of death is known. Mutually exclusive with 'deceasedBoolean'. required: - resourceType - id - active - identifier - telcom - name - address - birthDate - extension - communication PatientBundled: type: object properties: resourceType: type: string minLength: 1 id: type: string minLength: 1 description: id of the resource Meta: type: object description: Metadata about the resource properties: lastUpdated: type: string type: type: string minLength: 1 description: Type of Search total: type: integer description: Number of Consitions in entry field Link: type: object properties: relation: type: string minLength: 1 description: relation of the resource with link provided in url url: type: string minLength: 1 description: FHIR URI of the request required: - relation - url entry: type: array items: type: object properties: fullUrl: type: string minLength: 1 description: FHIR URI of respective Condition resource in entry resource: $ref: '#/components/schemas/Patient' required: - resourceType - id - meta - type - total - link responses: ResourceNotFound404: description: Resource not found ResourceNotAuthorized401: description: Resource not authorized to be viewed by this user parameters: id: description: The id of the resource name: id in: path required: true schema: type: string patient_name: description: Name of the patient name: name in: query required: false schema: type: string _id: description: The id of the resource name: _id in: query required: false schema: type: string patient_gender: description: Gender of the patient. Supported values male | female | undifferentiated | both. See http://hl7.org/fhir/R4/valueset-administrative-gender.html name: gender in: query required: false schema: type: string patient_birthdate: description: Date of birth of the patient.The format is YYYY-MM-DD e.g. 1905-08-23.There shall be no time zone.Dates shall be valid dates. See https://www.hl7.org/fhir/R4/search.html#birthDate. name: birthdate in: query required: false schema: type: string patient_identifier: description: A patient identifier name: identifier in: query required: false schema: type: string securitySchemes: OauthSecurity: type: oauth2 flows: authorizationCode: scopes: openid: Open ID scope launch/patient: Used by clients to request a patient-scoped access token offline_access: Request a refresh_token that can be used to obtain a new access token to replace an expired one, and that will be usable for as long as the end-user remains online. patient/*.read: Read access to all Patient Resources authorizationUrl: https://idp-prod.prod.ngo.nextgenaws.net/auth/realms/nextgen/protocol/openid-connect/auth?aud=https://fhir.meditouchehr.com/api/fhir/r4 tokenUrl: https://idp-prod.prod.ngo.nextgenaws.net/auth/realms/nextgen/protocol/openid-connect/token description: Access code based oauth authentication externalDocs: description: Find out more about NextGen Office FHIR API url: https://www.nextgen.com/products-and-services/nextgen-office