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

# Withdraw a discharge notification

> Withdraws a previous notification because the discharge was cancelled. Pharmacies that cannot withdraw a notification come back `UNSUPPORTED` rather than failed.



## OpenAPI

````yaml api-reference/doc-tool/ipd-api/ipd-sdk-openapi.json post /ipd/v1/sdk/admissions/{admission_id}/pharmacy-clearance-notify/cancel
openapi: 3.1.0
info:
  title: Eka IPD Admission API
  version: '1.0'
servers:
  - description: Production
    url: https://api.eka.care
  - description: Stage/Sandbox
    url: https://api.dev.eka.care
security: []
paths:
  /ipd/v1/sdk/admissions/{admission_id}/pharmacy-clearance-notify/cancel:
    post:
      tags:
        - IPD API
      summary: Withdraw a discharge notification
      description: >-
        Withdraws a previous notification because the discharge was cancelled.
        Pharmacies that cannot withdraw a notification come back `UNSUPPORTED`
        rather than failed.
      operationId: IpdSdkWithdrawADischargeNotification
      parameters:
        - name: auth
          in: header
          required: true
          schema:
            type: string
          example: >-
            eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJiX2lkIjoiMTIzNDU2IiwiY2xpZW50X2lkIjoiNzg5MCIsImV4dHJhX2ZpZWxkIjoiZXh0cmFfZmllbGRfZGF0YSJ9.q9KzBI6f4l3OyM_EkB5Quq0l9EEMFh5JS-fx3F_PHUM
        - schema:
            minLength: 1
            type: string
          in: path
          name: admission_id
          required: true
          description: Id of the IPD admission.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              additionalProperties: false
              type: object
              properties:
                by:
                  description: >-
                    Actor recorded against the attempt; defaults to the
                    authenticated operator.
                  additionalProperties: true
                  type: object
                  required:
                    - id
                  properties:
                    id:
                      type: string
                    name:
                      type: string
                    role:
                      type: string
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                additionalProperties: true
                type: object
                required:
                  - state
                  - targets
                properties:
                  skipped:
                    description: Set when the round was a deliberate no-op.
                    anyOf:
                      - type: string
                        enum:
                          - no-ipid
                      - type: string
                        enum:
                          - no-targets
                  state:
                    description: Rolled-up state across every pharmacy.
                    anyOf:
                      - type: string
                        enum:
                          - none
                      - type: string
                        enum:
                          - partial
                      - type: string
                        enum:
                          - all
                      - type: string
                        enum:
                          - failed
                  targets:
                    description: Per-pharmacy state, keyed by "provider:pharmacyId".
                    type: object
                    additionalProperties:
                      additionalProperties: true
                      type: object
                      required:
                        - provider
                        - pharmacy_id
                        - status
                        - attempts
                      properties:
                        provider:
                          type: string
                        pharmacy_id:
                          type: string
                        pharmacy_name:
                          type: string
                        status:
                          anyOf:
                            - type: string
                              enum:
                                - NOTIFIED
                            - type: string
                              enum:
                                - FAILED
                            - type: string
                              enum:
                                - CLEARED
                            - type: string
                              enum:
                                - CANCELLED
                            - type: string
                              enum:
                                - UNSUPPORTED
                        attempts:
                          description: Total attempts — drives the "Sent 4 times" copy.
                          type: number
                        last_error:
                          type: string
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                type: object
                required:
                  - message
                properties:
                  message:
                    type: string
        '404':
          description: >-
            Not Found — the admission (or the addressed record) does not exist
            in your workspace.
          content:
            application/json:
              schema:
                type: object
                required:
                  - message
                properties:
                  message:
                    type: string

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.