openapi: 3.2.0 info: version: 1.0.0 title: NextGen Office FHIR Specimen 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: Specimen description: https://hl7.org/fhir/R4/specimen.html paths: /fhir/r4/Specimen/{id}: get: tags: - Specimen description: 'Fetches a single Specimen by ID. FHIR Resource: [Specimen](http://hl7.org/fhir/R4/specimen.html) * Retrieves a specific Specimen resource by its logical ID. ' parameters: - name: id in: path required: true description: The ID of the Specimen resource schema: type: string responses: '200': description: Success - Returns the Specimen resource. content: application/json: schema: $ref: '#/components/schemas/Specimen' '404': $ref: '#/components/responses/ResourceNotFound404' '401': $ref: '#/components/responses/ResourceNotAuthorized401' /fhir/r4/Specimen: get: tags: - Specimen description: 'Fetches a Bundle containing Specimen resources. Supports filtering by patient or _id. If neither parameter is provided, the server will return a 400 Bad Request. FHIR Resource: [Specimen](http://hl7.org/fhir/R4/specimen.html) ' parameters: - name: _id in: query required: false description: Search by Specimen logical ID schema: type: string - name: patient in: query required: false description: Search by Patient reference (e.g., patient ID) schema: type: string responses: '200': description: Success - Returns a Bundle of Specimen resources. content: application/json: schema: $ref: '#/components/schemas/SpecimenBundled' '400': description: '**Invalid request:** The following conditions will result in a `400 Bad Request`: - `_id` and `patient` cannot be provided together. - Neither `_id` nor `patient` is provided. ' '404': $ref: '#/components/responses/ResourceNotFound404' '401': $ref: '#/components/responses/ResourceNotAuthorized401' components: schemas: Specimen: type: object properties: resourceType: type: string example: Specimen id: type: string status: type: string type: type: object subject: type: object collection: type: object required: - resourceType - id SpecimenBundled: type: object description: A FHIR Bundle of Specimen resources properties: resourceType: type: string example: Bundle type: type: string example: searchset total: type: integer example: 1 entry: type: array items: type: object properties: fullUrl: type: string example: http://example.com/fhir/r4/Specimen/123 resource: $ref: '#/components/schemas/Specimen' responses: ResourceNotAuthorized401: description: Resource not authorized to be viewed by this user ResourceNotFound404: description: Resource not found 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