> ## Documentation Index
> Fetch the complete documentation index at: https://docs.decodahealth.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Mark Phlebotomy Order Completed

> Toggle the manual staff "did the draw happen" tick against the calling
provider. ``completed=False`` clears the tick (an accidental-tick undo).



## OpenAPI

````yaml patch /phlebotomy-orders/{order_id}/completed
openapi: 3.1.0
info:
  title: Decoda API
  description: External API documentation for the Decoda Health platform.
  version: '1.0'
servers: []
security: []
paths:
  /phlebotomy-orders/{order_id}/completed:
    patch:
      tags:
        - Phlebotomy Orders
      summary: Mark Phlebotomy Order Completed
      description: |-
        Toggle the manual staff "did the draw happen" tick against the calling
        provider. ``completed=False`` clears the tick (an accidental-tick undo).
      operationId: >-
        mark_phlebotomy_order_completed_phlebotomy_orders__order_id__completed_patch
      parameters:
        - name: TENANT
          in: header
          required: true
          schema:
            type: string
            title: Tenant
          description: The tenant you are making this request on behalf of
        - name: API-KEY
          in: header
          required: true
          schema:
            type: string
            title: Api-Key
          description: Your api key
        - name: order_id
          in: path
          required: true
          schema:
            type: string
            title: Order Id
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/PhlebotomyOrderMarkCompletedRequest'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PhlebotomyOrderResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    PhlebotomyOrderMarkCompletedRequest:
      properties:
        completed:
          type: boolean
          title: Completed
      type: object
      required:
        - completed
      title: PhlebotomyOrderMarkCompletedRequest
      description: >-
        Request body for ``PATCH /phlebotomy-orders/{id}/completed``.
        ``completed``

        toggles the tick — ``True`` stamps
        ``completed_date``/``completed_by_provider_id``

        against the calling provider, ``False`` clears both (an accidental-tick
        undo).
    PhlebotomyOrderResponse:
      properties:
        id:
          type: string
          title: Id
        patientId:
          type: string
          title: Patientid
        orderingProviderId:
          type: string
          title: Orderingproviderid
        recipientFaxContactId:
          anyOf:
            - type: string
            - type: 'null'
          title: Recipientfaxcontactid
        diagnosisHh:
          type: boolean
          title: Diagnosishh
        diagnosisTt:
          type: boolean
          title: Diagnosistt
        otherDiagnoses:
          anyOf:
            - type: string
            - type: 'null'
          title: Otherdiagnoses
        frequency:
          anyOf:
            - $ref: '#/components/schemas/PhlebotomyFrequency'
            - type: 'null'
        otherFrequency:
          anyOf:
            - type: string
            - type: 'null'
          title: Otherfrequency
        hemoglobinThreshold:
          anyOf:
            - type: string
              pattern: ^(?!^[-+.]*$)[+-]?0*\d*\.?\d*$
            - type: 'null'
          title: Hemoglobinthreshold
        amount:
          anyOf:
            - $ref: '#/components/schemas/PhlebotomyAmount'
            - type: 'null'
        otherAmountMl:
          anyOf:
            - type: integer
            - type: 'null'
          title: Otheramountml
        comments:
          anyOf:
            - type: string
            - type: 'null'
          title: Comments
        signatureUrl:
          anyOf:
            - type: string
            - type: 'null'
          title: Signatureurl
        formVersion:
          type: string
          title: Formversion
        sentAt:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Sentat
        sentChannels:
          items:
            $ref: '#/components/schemas/PhlebotomyOrderSentVia'
          type: array
          title: Sentchannels
        completedDate:
          anyOf:
            - type: string
              format: date-time
            - type: 'null'
          title: Completeddate
        completedByProviderId:
          anyOf:
            - type: string
            - type: 'null'
          title: Completedbyproviderid
        documentId:
          type: string
          title: Documentid
        documentFilePath:
          type: string
          title: Documentfilepath
        documentTitle:
          type: string
          title: Documenttitle
        createdDate:
          type: string
          format: date-time
          title: Createddate
      type: object
      required:
        - id
        - patientId
        - orderingProviderId
        - recipientFaxContactId
        - diagnosisHh
        - diagnosisTt
        - otherDiagnoses
        - frequency
        - otherFrequency
        - hemoglobinThreshold
        - amount
        - otherAmountMl
        - comments
        - signatureUrl
        - formVersion
        - sentAt
        - sentChannels
        - completedDate
        - completedByProviderId
        - documentId
        - documentFilePath
        - documentTitle
        - createdDate
      title: PhlebotomyOrderResponse
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    PhlebotomyFrequency:
      type: string
      enum:
        - ONE_TIME
        - WEEKLY
        - EVERY_2_WEEKS
        - EVERY_4_WEEKS
        - EVERY_8_WEEKS
        - OTHER
      title: PhlebotomyFrequency
      description: |-
        Draw frequency on the OneBlood Form-96 phlebotomy order.

        Rendered as checkboxes on the form but functionally exclusive — a single
        selection, not independent booleans. ``OTHER`` carries free text in
        ``PatientPhlebotomyOrder.other_frequency``.
    PhlebotomyAmount:
      type: string
      enum:
        - ONE_UNIT
        - OTHER
      title: PhlebotomyAmount
      description: |-
        Draw amount on the OneBlood Form-96 phlebotomy order.

        Rendered as checkboxes on the form but functionally exclusive — a single
        selection, not independent booleans. ``OTHER`` carries a free-text mL
        amount in ``PatientPhlebotomyOrder.other_amount_ml``.
    PhlebotomyOrderSentVia:
      type: string
      enum:
        - EMAIL
        - FAX
        - PORTAL
      title: PhlebotomyOrderSentVia
      description: >-
        A channel a phlebotomy order's document went out on.


        Derived, never stamped — each member corresponds to a link that already

        exists once the document leaves the building:


        - ``FAX``: a ``fax_attachment`` row references the document

        - ``EMAIL``: an ``email_attachment`` row references the document

        - ``PORTAL``: ``document.shared_with_patient`` is set (a portal share,
        or
          the SMS that texts the patient a portal link)

        An order can therefore be on several channels at once, which is why the

        response carries a list rather than one "how was it sent" value.
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError

````