Formulary & Products
Formulary & Products
Manage your pharmacy’s product catalog — search medications, check stock levels, update pricing, and organize your formulary.
Search Formulary
Search your pharmacy’s available medications.
# Search your product catalogfetchFormularyForProvider({ query: "Amoxicillin 500mg", branchId: "BR-123", category: "antibiotics", inStockOnly: true})Parameters:
| Parameter | Type | Required | Description |
|---|---|---|---|
query | string | No | Search by name or generic |
branchId | string | No | Filter by branch location |
category | string | No | Filter by category |
inStockOnly | boolean | No | Only show in-stock items |
Response:
{ "products": [ { "id": "MED-123", "name": "Amoxicillin 500mg Capsules", "generic": "Amoxicillin", "manufacturer": "Emzor Pharmaceuticals", "category": "antibiotics", "form": "Capsule", "strength": "500mg", "packSize": "24 capsules", "price": 2500, "stockQuantity": 45, "branchId": "BR-123", "requiresPrescription": true, "storage": "Room temperature", "expiryDate": "2027-03-15" }, { "id": "MED-124", "name": "Amoxicillin 250mg Suspension", "generic": "Amoxicillin", "manufacturer": "Juhel Nigeria", "category": "antibiotics", "form": "Suspension", "strength": "250mg/5ml", "packSize": "100ml bottle", "price": 1800, "stockQuantity": 12, "branchId": "BR-123", "requiresPrescription": true, "storage": "Refrigerate after opening", "expiryDate": "2026-12-20" } ], "total": 23, "categories": ["antibiotics", "analgesics", "antimalarial"]}Get Product Details
View comprehensive information about a specific product.
# Get detailed product infogetFormularyProductDetails({ productId: "MED-123"})Response:
{ "id": "MED-123", "name": "Amoxicillin 500mg Capsules", "generic": "Amoxicillin", "manufacturer": "Emzor Pharmaceuticals", "category": "antibiotics", "subcategory": "Penicillins", "form": "Capsule", "strength": "500mg", "packSize": "24 capsules", "description": "Broad-spectrum antibiotic for bacterial infections", "indications": ["Respiratory infections", "UTIs", "Skin infections"], "contraindications": ["Penicillin allergy"], "sideEffects": ["Nausea", "Diarrhea", "Rash"], "dosage": "Adults: 500mg every 8 hours", "storage": "Store below 25°C", "price": 2500, "costPrice": 1800, "stockQuantity": 45, "reorderLevel": 20, "reorderQuantity": 50, "requiresPrescription": true, "controlled": false, "branches": [ { "branchId": "BR-123", "quantity": 45 }, { "branchId": "BR-124", "quantity": 30 } ], "expiryDate": "2027-03-15", "lastRestocked": "2026-02-10T10:00:00Z"}Update Stock
Update stock quantity for a product.
# Update stock quantityupdateProductStock({ productId: "MED-123", branchId: "BR-123", quantity: 60, operation: "set", // "set", "add", "subtract" reason: "New stock received"})Update Price
Change the selling price of a product.
# Update product priceupdateProductPrice({ productId: "MED-123", newPrice: 2800, effectiveDate: "2026-05-01"})Add New Product
Add a new medication to your formulary.
# Add new product to catalogaddFormularyProduct({ name: "Lisinopril 10mg Tablets", generic: "Lisinopril", manufacturer: "Swiss Pharma", category: "cardiovascular", form: "Tablet", strength: "10mg", packSize": "30 tablets", price: 3500, costPrice: 2500, stockQuantity: 100, reorderLevel: 30, requiresPrescription: true, storage: "Room temperature", branches: ["BR-123", "BR-124"]})Check Low Stock
View products that need restocking.
# Get low stock alertsgetLowStockProducts({ branchId: "BR-123", threshold: 10 // optional: override default threshold})Response:
{ "lowStock": [ { "id": "MED-456", "name": "Ibuprofen 400mg", "currentStock": 8, "reorderLevel": 20, "suggestedOrder": 50 }, { "id": "MED-457", "name": "Paracetamol 500mg", "currentStock": 5, "reorderLevel": 30, "suggestedOrder": 100 } ], "totalLowStock": 12}Expiring Products
Track products nearing expiry.
# Get expiring productsgetExpiringProducts({ days: 90, // products expiring in next 90 days branchId: "BR-123"})Product Categories
Organize products by category:
# Get all categoriesgetProductCategories()
# Response:{ "categories": [ { "id": "CAT-1", "name": "Antibiotics", "productCount": 45 }, { "id": "CAT-2", "name": "Analgesics", "productCount": 32 }, { "id": "CAT-3", "name": "Antimalarial", "productCount": 18 }, { "id": "CAT-4", "name": "Cardiovascular", "productCount": 27 } ]}Example: Inventory Management
# Step 1: Check low stockgetLowStockProducts({ branchId: "BR-123" })# → Shows products below reorder level
# Step 2: Search for specific productfetchFormularyForProvider({ query: "Amoxicillin", branchId: "BR-123"})# → Shows current stock levels
# Step 3: Update after restockingupdateProductStock({ productId: "MED-123", quantity: 100, operation: "add", reason: "New delivery from supplier"})