Pharmacy Billing

Last updated: 26 July 2026

Overview

Pharmacy in NICE HMS is an accounting channel within the Accounts module, not a standalone module with its own pages. There is no dedicated "Pharmacy" sidebar menu — pharmacy users access everything through Accounts.

Pharmacy transactions use the same forms as other billing workflows (invoice, purchase, debit note, credit note) but with pharmacy-specific voucher types, print headers, and the accountHeaderPharmacyUrl letterhead. The pharmacist role is restricted to pharmacy voucher types only.

Enabling Pharmacy Billing

Before using pharmacy billing, enable it in organization settings:

  1. Admin → Organization → Settings
  2. Toggle Pharmacy Billing to ON.
  3. This creates a PHARMACY ledger account for the organization.

The pharmacy toggle is at the organization level. Once enabled, the Pharmacy card appears on the Accounts landing page (/admin/accounts) with two links: Purchase and Debit Note.

Pharmacy Items

Pharmacy items (medicines, consumables) are created through Item Management (Accounts → Masters → Items), not through a separate pharmacy inventory page. See Item Management for the full item creation form.

Key configuration for pharmacy items:

SettingValue
CategoryPharmacy
Sub CategoryPharmacy
PurchasableTRUE (can be bought from vendors)
SaleableTRUE (can be sold to patients)

Batch Tracking

Medicines can be tracked by batch through the batchMaster table. Each batch record stores:

FieldDescription
BatchBatch number
Expiry DateExpiration date
Manufacturing DateDate of manufacture
ItemLinked item ID

Batch tracking applies to all inventory items, not just pharmacy. During purchase entry, batch details are recorded so that stock is tracked per batch.

Pharmacy Voucher Types

Four voucher types handle pharmacy transactions. They use the same UI components as their non-pharmacy counterparts but are routed through pharmacy-specific APIs and print with pharmacy headers:

Voucher TypePurposeCounterpart
INVOICE_PSale of medicines to a patientINVOICE
CREDIT_NOTE_PReturn/refund for pharmacy saleCREDIT_NOTE
PURCHASE_PPurchase of stock from a vendorPURCHASE
DEBIT_NOTE_PReturn of stock to a vendorDEBIT_NOTE

Access

TransactionAccess Path
Patient sale (invoice)Accounts → Pharmacy → use the general Invoice link with vouchertype=INVOICE_P
Vendor purchaseAccounts → Pharmacy → Purchase (/admin/accounts/bill/create?vouchertype=PURCHASE_P)
Purchase returnAccounts → Pharmacy → Debit Note (/admin/accounts/bill/create?vouchertype=DEBIT_NOTE_P)

Form Fields

The purchase and invoice forms are the same as the generic bill and invoice forms (see Bill Transaction and Purchase). The voucher type parameter determines:

  • Which API endpoint handles the transaction
  • Which accounts (Dr/Cr) are available
  • Which letterhead appears on the printed document

Pharmacist Role Restrictions

The pharmacist role can only create pharmacy-tagged vouchers. The create-purchase API rejects pharmacists for non-pharmacy purchase types:

if (user.role == "pharmacist" && type != "PURCHASE_P" && type != "DEBIT_NOTE_P") {
  throw new Error("forbidden");
}

Similarly, the create-invoice API restricts pharmacists to INVOICE_P and CREDIT_NOTE_P types only.

Stock Tracking

Stock levels for pharmacy items are tracked through the shared stock system alongside hospital-category items. The stock is calculated from purchase and invoice voucher quantities.

Current Stock Report

Sidebar → MIS Reports → Stock → Current (/admin/mis-reports/stock/current/0?category=Pharmacy)

Filter by category=Pharmacy to view only pharmacy items. The report shows current stock levels per item with batch-wise breakdown.

Expiry Tracking

The batchMaster table stores expiry dates per batch. An expiryStock() function queries batches approaching expiry, but there is no dedicated expiry alerts page — use the batch master data to identify items nearing expiration.

Physical Stock Adjustment

Use Physical Stock vouchers (PHYSICAL_POSITIVE / PHYSICAL_NEGATIVE types) to adjust stock levels for physical verification corrections, wastage, or damage. This is a shared inventory feature, not pharmacy-specific.

Printing

Pharmacy vouchers automatically use the pharmacy-specific letterhead:

  • Printed headings show: INVOICE (Pharmacy), CREDIT NOTE (Pharmacy), PURCHASE (Pharmacy), or DEBIT NOTE (Pharmacy)
  • The letterhead image uses accountHeaderPharmacyUrl from organization uploads (see Printing and Letter Pad Header)

The invoice component detects the _P suffix in the voucher type and switches to the pharmacy header automatically.

FAQ

Q: Where do I find the pharmacy menu? A: There is no separate pharmacy menu. Go to Sidebar → Accounts. If pharmacy billing is enabled in organization settings, a Pharmacy card appears with Purchase and Debit Note links. For patient sales, use the general Invoice link with a pharmacy item.

Q: How do I add new medicines to the pharmacy? A: Use Accounts → Masters → Items (see Item Management). Set the category to "Pharmacy" and mark it as purchasable and saleable.

Q: Can I track medicine expiry dates? A: Yes. Batch tracking records manufacturing and expiry dates for each batch of medicine. Use the batch master data to identify items approaching expiry.

Q: What can a pharmacist user do? A: A user with the pharmacist role can create and edit pharmacy vouchers (INVOICE_P, CREDIT_NOTE_P, PURCHASE_P, DEBIT_NOTE_P), create receipts/payments, and view MIS reports. They cannot create non-pharmacy transactions.

Q: Does pharmacy billing work differently from regular billing? A: The forms are identical. The difference is the voucher type suffix (_P), which routes through pharmacy-specific accounting and uses the pharmacy letterhead for printed documents.

Q: How do I dispense medicines against a prescription? A: There is no dedicated dispensing interface. Create a pharmacy invoice (INVOICE_P) for the patient with the prescribed medicines as line items. Stock is reduced automatically when the invoice is saved.

Q: Is there integration with the ABDM Drug Registry? A: Not currently. A medication resolver integration is planned but not yet implemented.

Was this page helpful?
NICE HMS. 1st Gate Nehru Stadium, City Hubballi, District Dhrawad, State Karnataka, 580020
INDIA, Phone : email , GST 29AEYPB4702Q1ZS
facebook
twitter
linkedin
youtube
RSS