Paracetamol hypersensitivity management

Reading File
Finding Sources
Finding Sources
Finding Sources
Searching PubMed

paracetamol acetaminophen hypersensitivity management

Finding Sources
Finding Sources
Finding Sources
Searching PubMed

acetaminophen hypersensitivity reaction urticaria angioedema

Reading File
Reading File
Reading Article

PMID: 42123311

Searching the Web

paracetamol acetaminophen hypersensitivity management treatment WAO EAACI guidelines 2024 2025

Reading Web Page

https://www.worldallergyorganizationjournal.org/article/S193…

Finding Sources
Reading Article

PMID: 37519510

I now have comprehensive information to write a thorough answer. Let me compile everything.

Paracetamol (Acetaminophen) Hypersensitivity: Management

Overview and Classification

Paracetamol has a unique pharmacological profile compared to classical NSAIDs. It is a weak COX-1 inhibitor (primarily COX-3/central mechanism), and this separates most of its hypersensitivity reactions into two fundamentally different categories:
CategoryMechanismCharacteristics
Pharmacologically-mediated (pseudo-allergic)Weak COX-1 inhibition - arachidonic acid dysregulationNon-IgE, cross-reactive with NSAIDs, dose-dependent
True immunological (allergic)IgE-mediated (Type I) or T-cell-mediated (Type IV)Drug-specific, not cross-reactive with other NSAIDs
The WAO 2025 updated classification (published August 2025) recognises the following cross-reactive NSAID hypersensitivity phenotypes that are relevant to paracetamol:
  • NERD - NSAID-exacerbated respiratory disease
  • NIUA/NIUAA - NSAID-induced urticaria/angioedema (± anaphylaxis)
  • NECD - NSAID-exacerbated cutaneous disease
  • SNIUAA - Single-NSAID-induced urticaria/angioedema/anaphylaxis (true allergy, drug-specific)
  • SNIDHR - Single-NSAID-induced delayed hypersensitivity reaction
Paracetamol provocation testing in a cohort of 527 NSAID-hypersensitive patients (WAO 2025 reclassification study) showed 97.8% tolerability to paracetamol - the highest of all tested agents, confirming its relative safety as an alternative analgesic. (Bulut & Katran, 2026, PMID: 41510935)

Specific Hypersensitivity Reactions to Paracetamol Itself

1. Immediate Reactions (Type I / Anaphylaxis)

  • Rare but documented; urticaria, angioedema, bronchospasm, anaphylaxis
  • May be IgE-mediated in true allergy, or pharmacological at higher doses
  • The 2026 review by Andryszkiewicz et al. confirms: "Paracetamol is generally considered a safer alternative due to its weak COX-1 inhibition; however, reactions may still occur, particularly at higher doses."

2. Cutaneous Reactions

  • Fixed drug eruption (FDE): localised, recurrent, non-scarring
  • Maculopapular exanthema (MPE): diffuse, often Type IVb/IVc
  • Stevens-Johnson Syndrome (SJS) / Toxic Epidermal Necrolysis (TEN): rare, but paracetamol is a documented culprit. Involves CD8+ T-cell mediated apoptosis of the epidermis. HLA gene variants (HLA susceptibility alleles) have been implicated. Diagnosis by BSA involvement: SJS < 10%, TEN > 30%. (Spillers et al., 2023, PMID: 37519510)

3. Delayed Reactions (Type IV)

  • T-cell mediated; onset 1-72 hours after exposure
  • Presents as maculopapular rash, drug reaction with eosinophilia and systemic symptoms (DRESS), or SJS/TEN

4. Hepatic Hypersensitivity

As noted in Sleisenger & Fordtran's GI and Liver Disease: "Systemic features of drug hypersensitivity may indicate the correct diagnosis. These include fever, rash, mucositis, eosinophilia, lymphadenopathy, a mononucleosis-like syndrome, bone marrow suppression, vasculitis, acute kidney injury, pneumonitis."
Paracetamol predominantly causes dose-dependent (intrinsic/Type A) hepatotoxicity, but rare idiosyncratic (Type B) hypersensitivity hepatitis has been reported.

Management Strategy

Step 1: Acute Reaction Management

Anaphylaxis / Severe immediate reaction:
  • Epinephrine (adrenaline) IM 0.3-0.5 mg (0.01 mg/kg in children) into anterolateral thigh - FIRST-LINE
  • Lay patient flat, legs elevated (unless respiratory distress)
  • IV access, supplemental oxygen
  • IV fluids for hypotension
  • H1 antihistamine (chlorphenamine/diphenhydramine) IV - adjunct only
  • Systemic corticosteroids (hydrocortisone/prednisolone) - adjunct to prevent biphasic reactions
  • Beta-agonist (salbutamol) for bronchospasm
  • ICU admission if severe; observe minimum 4-6 hours (24 hours if biphasic risk)
Urticaria/Angioedema (without anaphylaxis):
  • Discontinue paracetamol immediately
  • Oral/IV H1 antihistamine (cetirizine, loratadine)
  • Systemic corticosteroids for moderate-severe cases
  • Epinephrine if laryngeal angioedema threatened
SJS / TEN:
  • Immediate paracetamol withdrawal - critical (stopping the causative drug is the single most important step)
  • Urgent dermatology/burns unit admission for TEN
  • Supportive care: wound management, eye care, nutritional support, IV fluids
  • Ophthalmology review (prevent ocular sequelae)
  • Consider IVIG, cyclosporin, or TNF inhibitors (etanercept) based on severity - evidence is evolving
  • Avoid systemic corticosteroids in TEN (controversial/potentially harmful)
Drug-induced hepatotoxicity (hypersensitivity type):
  • Withdraw paracetamol
  • Supportive care; monitor LFTs
  • N-acetylcysteine (NAC) for overdose-mediated injury
  • Liver transplant evaluation for fulminant hepatic failure

Step 2: Diagnostic Work-Up After Acute Phase

Performed 4-6 weeks after complete recovery:
  1. Detailed history - onset, dose, temporal relationship, prior exposures, concomitant NSAID use
  2. Skin tests - limited value for paracetamol; may be considered for IgE-mediated reactions
    • Skin prick test (SPT) at 10 mg/mL
    • Intradermal test (IDT) if SPT negative
  3. In-vitro testing - specific IgE (if available), basophil activation test (BAT)
  4. Drug provocation test (DPT) - the gold standard for confirming diagnosis and verifying tolerability
Per WAO 2025 guidelines: DCs (drug challenges) with alternative agents should be performed by administering one-tenth to one-quarter of the therapeutic dose first, followed by the remaining dose. Reactions to DCs are generally milder than the index reaction and are easily controlled with symptomatic treatment.

Step 3: Long-Term Management and Safe Alternatives

If paracetamol is the confirmed culprit:

Alternative AnalgesicTolerability in NSAID-HSRNotes
Selective COX-2 inhibitors (celecoxib, etoricoxib)~92-96% toleratedConfirm by DPT; sporadic reactions possible
Nimesulide (preferential COX-2)~96% toleratedAvailable in some countries
Metamizole/dipyroneVariableSeparate mechanism; may be tolerated
Weak opioids (codeine, tramadol)Generally safeNot cross-reactive with COX pathway
Strong opioidsGenerally safeFor severe pain

If patient is an NSAID-hypersensitive patient needing analgesia:

  • Paracetamol is the first-choice alternative with 97.8% tolerability
  • Particularly safe in NERD, NECD phenotypes at standard doses (≤ 1g/dose)
  • Dose-caution: At doses > 1g, some NSAID-hypersensitive patients may react due to increased COX-1 inhibition
  • Always confirm tolerability with supervised DPT before prescribing long-term

For paracetamol-specific true allergy (SNIUAA/SNIDHR):

  • Avoid paracetamol entirely
  • Use selective COX-2 inhibitors or opioids as confirmed alternatives
  • Desensitisation is technically possible but rarely indicated given available alternatives - reserved for cases where no safe alternative exists (e.g., specific post-transplant or oncology settings)

Step 4: Special Situations

In aspirin-exacerbated respiratory disease (AERD/NERD):
  • Low-dose paracetamol (< 1g) is typically tolerated
  • Aspirin desensitisation followed by high-dose aspirin maintenance therapy is a specific treatment for AERD and may reduce overall NSAID sensitivity
In chronic urticaria (NECD phenotype):
  • Antihistamine premedication (cetirizine) before paracetamol use may prevent breakthrough urticaria - supported by evidence from studies on weak COX-1 inhibitors
Pregnancy:
  • Paracetamol remains the analgesic of choice; hypersensitivity management follows standard anaphylaxis protocols (epinephrine is NOT contraindicated in pregnancy for anaphylaxis)
Children (per EAACI/ENDA paediatric position paper):
  • Paracetamol is the most common alternative studied in paediatric NSAID-HSR
  • DPT protocols should be adapted to weight-based dosing
  • 97%+ tolerability in NSAID-hypersensitive children

Summary Algorithm

Suspected paracetamol hypersensitivity
            |
    ┌───────┴───────┐
 Immediate        Delayed
 (< 1 hour)      (> 1 hour)
    |                |
 Anaphylaxis?    SJS/TEN/DRESS?
 → Epinephrine   → Withdraw drug
 → Antihistamine → Supportive care
 → Steroids      → Dermatology
    |
 Stabilise → 4-6 weeks → Allergy work-up
                              |
                    Confirm mechanism
                    (skin test / DPT)
                              |
                 Identify safe alternatives
              (COX-2 inhibitor / opioid / DPT)

Key references:
  • Andryszkiewicz et al., 2026 - Cross-reactivity among NSAIDs, paracetamol safety, COX-1 mechanism (PMID: 42123311)
  • Bulut & Katran, 2026 - WAO 2025 reclassification; 97.8% paracetamol tolerability in NSAID-HSR
  • Spillers et al., 2023 - Paracetamol-associated SJS/TEN, HLA genetics, management options (PMID: 37519510)
  • WAO 2025 Statement - Updated NSAID hypersensitivity classification and management
  • Sleisenger & Fordtran's GI and Liver Disease - Systemic features of drug hypersensitivity hepatitis

Create a quick reference PDF summarizing paracetamol hypersensitivity diagnosis and safe alternatives

Reading File
Running Command

ls -la /tmp/workspace/ 2>/dev/null || echo "workspace empty or missing"

Running Command

mkdir -p /tmp/workspace/paracetamol-hypersensitivity

Writing File

~/paracetamol-hypersensitivity/generate_pdf.py

from reportlab.lib.pagesizes import A4
from reportlab.lib import colors
from reportlab.lib.styles import getSampleStyleSheet, ParagraphStyle
from reportlab.lib.units import cm, mm
from reportlab.platypus import (
    SimpleDocTemplate, Paragraph, Spacer, Table, TableStyle,
    HRFlowable, KeepTogether
)
from reportlab.lib.enums import TA_LEFT, TA_CENTER, TA_JUSTIFY
from reportlab.platypus import ListFlowable, ListItem

OUTPUT = "/tmp/workspace/paracetamol-hypersensitivity/Paracetamol_Hypersensitivity_Quick_Reference.pdf"

# ── Colour palette ─────────────────────────────────────────────────────────────
NAVY      = colors.HexColor("#1A3557")
TEAL      = colors.HexColor("#1E7F74")
AMBER     = colors.HexColor("#E87722")
RED       = colors.HexColor("#C0392B")
GREEN     = colors.HexColor("#1E7F74")
LIGHT_BG  = colors.HexColor("#F0F4F8")
AMBER_BG  = colors.HexColor("#FFF3E0")
RED_BG    = colors.HexColor("#FDEDEB")
GREEN_BG  = colors.HexColor("#E8F5E9")
WHITE     = colors.white
DARK_GREY = colors.HexColor("#2C3E50")
MID_GREY  = colors.HexColor("#7F8C8D")

W, H = A4

doc = SimpleDocTemplate(
    OUTPUT,
    pagesize=A4,
    topMargin=1.5*cm, bottomMargin=1.5*cm,
    leftMargin=1.6*cm, rightMargin=1.6*cm,
    title="Paracetamol Hypersensitivity – Quick Reference",
    author="Orris Clinical Reference",
    subject="Diagnosis & Safe Alternatives",
)

styles = getSampleStyleSheet()

# Custom styles
def make_style(name, parent="Normal", **kwargs):
    s = ParagraphStyle(name, parent=styles[parent], **kwargs)
    return s

title_style = make_style("MainTitle",
    fontSize=20, textColor=WHITE, alignment=TA_CENTER,
    fontName="Helvetica-Bold", spaceAfter=2, leading=24)

subtitle_style = make_style("Subtitle",
    fontSize=10, textColor=colors.HexColor("#BDC8D4"), alignment=TA_CENTER,
    fontName="Helvetica", spaceAfter=0, leading=13)

section_header = make_style("SectionHeader",
    fontSize=11, textColor=WHITE, fontName="Helvetica-Bold",
    leading=14, spaceAfter=0, spaceBefore=0, leftIndent=6)

body = make_style("Body",
    fontSize=8.5, textColor=DARK_GREY, fontName="Helvetica",
    leading=12, spaceAfter=3, alignment=TA_JUSTIFY)

bold_body = make_style("BoldBody",
    fontSize=8.5, textColor=DARK_GREY, fontName="Helvetica-Bold",
    leading=12, spaceAfter=2)

small_label = make_style("SmallLabel",
    fontSize=7.5, textColor=MID_GREY, fontName="Helvetica",
    leading=10, spaceAfter=1)

table_header = make_style("TableHeader",
    fontSize=8, textColor=WHITE, fontName="Helvetica-Bold",
    alignment=TA_CENTER, leading=10)

table_cell = make_style("TableCell",
    fontSize=8, textColor=DARK_GREY, fontName="Helvetica",
    leading=10, alignment=TA_LEFT)

table_cell_c = make_style("TableCellC",
    fontSize=8, textColor=DARK_GREY, fontName="Helvetica",
    leading=10, alignment=TA_CENTER)

bullet_style = make_style("Bullet",
    fontSize=8.5, textColor=DARK_GREY, fontName="Helvetica",
    leading=11, leftIndent=10, spaceAfter=1)

red_bold = make_style("RedBold",
    fontSize=8.5, textColor=RED, fontName="Helvetica-Bold", leading=12)

green_bold = make_style("GreenBold",
    fontSize=8.5, textColor=TEAL, fontName="Helvetica-Bold", leading=12)

footnote_style = make_style("Footnote",
    fontSize=7, textColor=MID_GREY, fontName="Helvetica-Oblique",
    leading=9, alignment=TA_CENTER)

story = []

# ════════════════════════════════════════════════════════════
# HEADER BANNER
# ════════════════════════════════════════════════════════════
usable_w = W - 3.2*cm

header_data = [[
    Paragraph("Paracetamol Hypersensitivity", title_style),
    Paragraph("Quick Reference: Diagnosis &amp; Safe Alternatives", subtitle_style),
]]
header_table = Table([[Paragraph("Paracetamol Hypersensitivity", title_style)],
                       [Paragraph("Quick Reference: Diagnosis &amp; Safe Alternatives", subtitle_style)]],
                      colWidths=[usable_w])
header_table.setStyle(TableStyle([
    ("BACKGROUND", (0,0), (-1,-1), NAVY),
    ("TOPPADDING",    (0,0), (-1,-1), 10),
    ("BOTTOMPADDING", (0,0), (-1,-1), 10),
    ("LEFTPADDING",   (0,0), (-1,-1), 12),
    ("RIGHTPADDING",  (0,0), (-1,-1), 12),
    ("ROWBACKGROUNDS", (0,0), (-1,-1), [NAVY]),
]))
story.append(header_table)
story.append(Spacer(1, 8))

# ════════════════════════════════════════════════════════════
# HELPER: coloured section box
# ════════════════════════════════════════════════════════════
def section_box(title, content_rows, header_color=NAVY, col_widths=None):
    """Wrap content in a titled box with coloured header."""
    if col_widths is None:
        col_widths = [usable_w]
    rows = [[Paragraph(title, section_header)]]
    rows += content_rows
    t = Table(rows, colWidths=col_widths)
    style = [
        ("BACKGROUND",   (0, 0), (-1, 0), header_color),
        ("TOPPADDING",   (0, 0), (-1, 0), 5),
        ("BOTTOMPADDING",(0, 0), (-1, 0), 5),
        ("LEFTPADDING",  (0, 0), (-1,-1), 8),
        ("RIGHTPADDING", (0, 0), (-1,-1), 8),
        ("TOPPADDING",   (0, 1), (-1,-1), 4),
        ("BOTTOMPADDING",(0, 1), (-1,-1), 4),
        ("BACKGROUND",   (0, 1), (-1,-1), LIGHT_BG),
        ("BOX",          (0, 0), (-1,-1), 0.8, header_color),
        ("LINEBELOW",    (0, 0), (-1, 0), 0.5, WHITE),
        ("SPAN",         (0, 0), (-1, 0)),
    ]
    t.setStyle(TableStyle(style))
    return t

# ════════════════════════════════════════════════════════════
# ROW 1 — two columns: Classification | Reaction Types
# ════════════════════════════════════════════════════════════
col1 = usable_w * 0.48
col2 = usable_w * 0.52

# --- Left: Classification ---
classif_data = [
    [Paragraph("Pharmacological (pseudo-allergic)", bold_body)],
    [Paragraph("• Weak COX-1 inhibition at higher doses<br/>"
               "• Non-IgE mediated, dose-related<br/>"
               "• Can cross-react with other NSAIDs<br/>"
               "• Phenotypes: NERD, NIUA, NECD", body)],
    [Spacer(1,3)],
    [Paragraph("True Immunological (allergic)", bold_body)],
    [Paragraph("• IgE-mediated (Type I) — drug-specific<br/>"
               "• T-cell mediated (Type IV) — drug-specific<br/>"
               "• Does NOT cross-react with other NSAIDs<br/>"
               "• Phenotypes: SNIUAA, SNIDHR", body)],
    [Spacer(1,3)],
    [Paragraph("⚑  Key fact: Paracetamol is a weak COX-1 inhibitor — "
               "97.8% of NSAID-hypersensitive patients tolerate it "
               "(WAO 2025; Bulut &amp; Katran, 2026).", small_label)],
]
left_box = section_box("CLASSIFICATION", classif_data, NAVY, [col1])

# --- Right: Reaction Types ---
react_data = [
    [Paragraph("<b>Immediate (&lt;1 h)</b>", bold_body)],
    [Paragraph("Urticaria · Angioedema · Bronchospasm · Anaphylaxis", body)],
    [Spacer(1,2)],
    [Paragraph("<b>Cutaneous (delayed)</b>", bold_body)],
    [Paragraph("Fixed drug eruption · Maculopapular exanthema<br/>"
               "<font color='#C0392B'><b>SJS (&lt;10% BSA) · TEN (&gt;30% BSA)</b></font><br/>"
               "Type IV, CD8+ T-cell apoptosis; HLA variants implicated", body)],
    [Spacer(1,2)],
    [Paragraph("<b>Hepatic hypersensitivity (rare)</b>", bold_body)],
    [Paragraph("Fever · Rash · Eosinophilia · Elevated LFTs<br/>"
               "Distinct from dose-dependent APAP hepatotoxicity", body)],
    [Spacer(1,2)],
    [Paragraph("<b>DRESS (rare)</b>", bold_body)],
    [Paragraph("Rash + fever + lymphadenopathy + multi-organ involvement", body)],
]
right_box = section_box("REACTION TYPES", react_data, TEAL, [col2])

row1 = Table([[left_box, Spacer(0.3*cm, 1), right_box]],
             colWidths=[col1, 0.3*cm, col2])
row1.setStyle(TableStyle([
    ("VALIGN", (0,0), (-1,-1), "TOP"),
    ("TOPPADDING",    (0,0), (-1,-1), 0),
    ("BOTTOMPADDING", (0,0), (-1,-1), 0),
    ("LEFTPADDING",   (0,0), (-1,-1), 0),
    ("RIGHTPADDING",  (0,0), (-1,-1), 0),
]))
story.append(row1)
story.append(Spacer(1, 6))

# ════════════════════════════════════════════════════════════
# ACUTE MANAGEMENT (full width, 2 side-by-side boxes)
# ════════════════════════════════════════════════════════════
mgmt_w1 = usable_w * 0.50
mgmt_w2 = usable_w * 0.50

# --- Anaphylaxis box ---
anaph_rows = [
    [Paragraph("<font color='#C0392B'><b>STOP paracetamol immediately</b></font>", bold_body)],
    [Paragraph("<b>1.</b> Epinephrine IM 0.3–0.5 mg anterolateral thigh<br/>"
               "&nbsp;&nbsp;&nbsp;&nbsp;(child: 0.01 mg/kg; max 0.5 mg)", body)],
    [Paragraph("<b>2.</b> Lay flat, legs elevated (unless respiratory distress)", body)],
    [Paragraph("<b>3.</b> High-flow O₂ · IV access · IV fluids (hypotension)", body)],
    [Paragraph("<b>4.</b> H1 antihistamine IV — adjunct only", body)],
    [Paragraph("<b>5.</b> IV hydrocortisone — biphasic reaction prevention", body)],
    [Paragraph("<b>6.</b> Salbutamol nebulised for bronchospasm", body)],
    [Paragraph("<b>7.</b> Observe min 4–6 h; 24 h if biphasic risk", body)],
    [Spacer(1,2)],
    [Paragraph("⚑  Epinephrine is NOT contraindicated in pregnancy.", small_label)],
]
anaph_box = section_box("ANAPHYLAXIS / SEVERE IMMEDIATE REACTION", anaph_rows,
                         RED, [mgmt_w1 - 0.15*cm])

# --- SJS/TEN + Urticaria box ---
sjs_rows = [
    [Paragraph("<b>Urticaria / Angioedema (no anaphylaxis)</b>", bold_body)],
    [Paragraph("• Oral/IV H1 antihistamine (cetirizine/loratadine)<br/>"
               "• Systemic corticosteroids (moderate–severe)<br/>"
               "• Epinephrine if laryngeal oedema threatened", body)],
    [Spacer(1,3)],
    [Paragraph("<b>SJS / TEN</b>", bold_body)],
    [Paragraph("• Immediate drug withdrawal (most critical step)<br/>"
               "• Burns/dermatology unit admission<br/>"
               "• Wound care · Eye care · IV fluids · Nutrition<br/>"
               "• Consider IVIG, cyclosporin, or etanercept<br/>"
               "• Ophthalmology review<br/>"
               "<font color='#C0392B'>• Avoid systemic steroids in TEN</font>", body)],
    [Spacer(1,3)],
    [Paragraph("<b>Hepatic hypersensitivity</b>", bold_body)],
    [Paragraph("• Withdraw drug · Monitor LFTs<br/>"
               "• NAC for overdose-mediated injury<br/>"
               "• Liver transplant evaluation if fulminant", body)],
]
sjs_box = section_box("URTICARIA · SJS/TEN · HEPATIC HSR", sjs_rows,
                       AMBER, [mgmt_w2 - 0.15*cm])

mgmt_row = Table([[anaph_box, Spacer(0.3*cm, 1), sjs_box]],
                  colWidths=[mgmt_w1, 0.3*cm, mgmt_w2])
mgmt_row.setStyle(TableStyle([
    ("VALIGN", (0,0), (-1,-1), "TOP"),
    ("TOPPADDING",    (0,0), (-1,-1), 0),
    ("BOTTOMPADDING", (0,0), (-1,-1), 0),
    ("LEFTPADDING",   (0,0), (-1,-1), 0),
    ("RIGHTPADDING",  (0,0), (-1,-1), 0),
]))
story.append(mgmt_row)
story.append(Spacer(1, 6))

# ════════════════════════════════════════════════════════════
# DIAGNOSIS WORK-UP
# ════════════════════════════════════════════════════════════
diag_rows = [
    [Paragraph("Perform 4–6 weeks after complete recovery", small_label)],
    [Paragraph("<b>Step 1 — Detailed history:</b> Dose, onset timing, prior NSAID use, "
               "concomitant medications, underlying conditions (asthma, chronic urticaria)", body)],
    [Paragraph("<b>Step 2 — Skin tests</b> (limited utility for paracetamol; better for "
               "IgE-mediated): Skin prick test (10 mg/mL) → Intradermal test if SPT negative. "
               "Basophil activation test (BAT) and specific IgE where available.", body)],
    [Paragraph("<b>Step 3 — Drug provocation test (DPT): Gold standard.</b> "
               "Administer 1/10–1/4 of therapeutic dose first, then full dose under supervision. "
               "Reactions to DCs are generally milder than the index reaction and easily controlled. "
               "(WAO 2025)", body)],
    [Paragraph("WAO 2025 phenotype classification: NERD · NIUA/NIUAA · NECD · SNIUAA · SNIDHR", small_label)],
]
diag_box = section_box("DIAGNOSTIC WORK-UP (POST-ACUTE PHASE)", diag_rows, NAVY, [usable_w])
story.append(diag_box)
story.append(Spacer(1, 6))

# ════════════════════════════════════════════════════════════
# SAFE ALTERNATIVES TABLE
# ════════════════════════════════════════════════════════════
alt_header = [
    Paragraph("SAFE ALTERNATIVES — WHEN PARACETAMOL IS THE CULPRIT", section_header)
]

col_w = [usable_w * p for p in [0.22, 0.16, 0.32, 0.30]]

alt_rows = [
    [Paragraph("Agent", table_header),
     Paragraph("Tolerability", table_header),
     Paragraph("Notes", table_header),
     Paragraph("Use When", table_header)],

    [Paragraph("Selective COX-2\ninhibitors\n(celecoxib,\netoricoxib)", table_cell),
     Paragraph("92–96%", table_cell_c),
     Paragraph("Confirm by supervised DPT before prescribing long-term. Sporadic reactions possible.", table_cell),
     Paragraph("First-line alternative; most evidence base", table_cell)],

    [Paragraph("Nimesulide\n(preferential\nCOX-2)", table_cell),
     Paragraph("~96%", table_cell_c),
     Paragraph("Available in some countries. Confirm by DPT.", table_cell),
     Paragraph("Where available and COXIBs not suitable", table_cell)],

    [Paragraph("Metamizole /\nDipyrone", table_cell),
     Paragraph("Variable", table_cell_c),
     Paragraph("Separate mechanism from COX pathway. Agranulocytosis risk — monitor.", table_cell),
     Paragraph("Short-term, moderate–severe pain", table_cell)],

    [Paragraph("Weak opioids\n(tramadol,\ncodeine)", table_cell),
     Paragraph("Generally\nsafe", table_cell_c),
     Paragraph("No COX interaction. Standard opioid cautions apply.", table_cell),
     Paragraph("When anti-inflammatory effect not required", table_cell)],

    [Paragraph("Strong opioids\n(morphine,\noxycodone)", table_cell),
     Paragraph("Generally\nsafe", table_cell_c),
     Paragraph("No cross-reactivity. Titrate carefully.", table_cell),
     Paragraph("Moderate–severe pain; short-term", table_cell)],
]

alt_table = Table(alt_rows, colWidths=col_w)
alt_table.setStyle(TableStyle([
    ("BACKGROUND",    (0,0), (-1,0), TEAL),
    ("TEXTCOLOR",     (0,0), (-1,0), WHITE),
    ("FONTNAME",      (0,0), (-1,0), "Helvetica-Bold"),
    ("FONTSIZE",      (0,0), (-1,-1), 8),
    ("ROWBACKGROUNDS",(0,1), (-1,-1), [WHITE, LIGHT_BG]),
    ("GRID",          (0,0), (-1,-1), 0.4, colors.HexColor("#CBD5E0")),
    ("VALIGN",        (0,0), (-1,-1), "TOP"),
    ("TOPPADDING",    (0,0), (-1,-1), 5),
    ("BOTTOMPADDING", (0,0), (-1,-1), 5),
    ("LEFTPADDING",   (0,0), (-1,-1), 6),
    ("RIGHTPADDING",  (0,0), (-1,-1), 6),
    ("ALIGN",         (1,1), (1,-1), "CENTER"),
]))

alt_wrapper = Table(
    [[Paragraph("SAFE ALTERNATIVES — WHEN PARACETAMOL IS THE CULPRIT", section_header)],
     [alt_table]],
    colWidths=[usable_w]
)
alt_wrapper.setStyle(TableStyle([
    ("BACKGROUND",    (0,0), (-1,0), TEAL),
    ("TOPPADDING",    (0,0), (-1,0), 5),
    ("BOTTOMPADDING", (0,0), (-1,0), 5),
    ("LEFTPADDING",   (0,0), (-1,-1), 0),
    ("RIGHTPADDING",  (0,0), (-1,-1), 0),
    ("TOPPADDING",    (0,1), (-1,-1), 0),
    ("BOTTOMPADDING", (0,1), (-1,-1), 0),
    ("BOX",           (0,0), (-1,-1), 0.8, TEAL),
]))
story.append(alt_wrapper)
story.append(Spacer(1, 6))

# ════════════════════════════════════════════════════════════
# PARACETAMOL AS ALTERNATIVE (for NSAID-HSR patients)
# ════════════════════════════════════════════════════════════
para_alt_data = [
    [Paragraph(
        "When the patient is NSAID-hypersensitive and you need an analgesic — "
        "paracetamol is the first-choice alternative (97.8% tolerability, WAO 2025 data). "
        "Always confirm with supervised DPT if doubt exists.",
        body)],
    [Spacer(1,3)],
]

# Phenotype tolerance mini-table
phen_rows = [
    [Paragraph("Phenotype", table_header),
     Paragraph("Paracetamol Safe?", table_header),
     Paragraph("Dose Caution", table_header),
     Paragraph("Notes", table_header)],
    [Paragraph("NERD", table_cell_c),
     Paragraph("✓ Usually", table_cell_c),
     Paragraph("≤1 g/dose", table_cell_c),
     Paragraph("Rare reactions reported at doses >1 g; COX-1 inhibition increases with dose", table_cell)],
    [Paragraph("NIUA / NIUAA", table_cell_c),
     Paragraph("✓ Usually", table_cell_c),
     Paragraph("≤1 g/dose", table_cell_c),
     Paragraph("Confirm by DPT; standard dose generally safe", table_cell)],
    [Paragraph("NECD", table_cell_c),
     Paragraph("✓ Preferred", table_cell_c),
     Paragraph("Standard", table_cell_c),
     Paragraph("Highest tolerability in this group; preferred analgesic", table_cell)],
    [Paragraph("SNIUAA (true allergy)", table_cell_c),
     Paragraph("✓ Safe", table_cell_c),
     Paragraph("Standard", table_cell_c),
     Paragraph("Drug-specific reaction — no cross-reactivity with paracetamol", table_cell)],
    [Paragraph("SNIDHR", table_cell_c),
     Paragraph("✓ Safe", table_cell_c),
     Paragraph("Standard", table_cell_c),
     Paragraph("Drug-specific; paracetamol is not cross-reactive", table_cell)],
]
phen_table = Table(phen_rows, colWidths=[usable_w*p for p in [0.1, 0.14, 0.13, 0.63]])
phen_table.setStyle(TableStyle([
    ("BACKGROUND",    (0,0), (-1,0), NAVY),
    ("TEXTCOLOR",     (0,0), (-1,0), WHITE),
    ("ROWBACKGROUNDS",(0,1), (-1,-1), [WHITE, LIGHT_BG]),
    ("GRID",          (0,0), (-1,-1), 0.4, colors.HexColor("#CBD5E0")),
    ("VALIGN",        (0,0), (-1,-1), "MIDDLE"),
    ("FONTSIZE",      (0,0), (-1,-1), 7.5),
    ("TOPPADDING",    (0,0), (-1,-1), 4),
    ("BOTTOMPADDING", (0,0), (-1,-1), 4),
    ("LEFTPADDING",   (0,0), (-1,-1), 5),
    ("RIGHTPADDING",  (0,0), (-1,-1), 5),
    ("ALIGN",         (0,0), (2,-1), "CENTER"),
]))
para_alt_data.append([phen_table])

para_alt_box = section_box(
    "PARACETAMOL AS SAFE ALTERNATIVE IN NSAID-HYPERSENSITIVE PATIENTS",
    para_alt_data, NAVY, [usable_w])
story.append(para_alt_box)
story.append(Spacer(1, 6))

# ════════════════════════════════════════════════════════════
# SPECIAL POPULATIONS + KEY NOTES  (2 columns)
# ════════════════════════════════════════════════════════════
sp_col = usable_w * 0.48

sp_data = [
    [Paragraph("<b>Pregnancy:</b> Epinephrine is NOT contraindicated in anaphylaxis. "
               "Paracetamol remains analgesic of choice.", body)],
    [Paragraph("<b>Children (EAACI/ENDA):</b> Paracetamol is the most studied alternative "
               "in paediatric NSAID-HSR; DPT protocols use weight-based dosing.", body)],
    [Paragraph("<b>AERD/NERD:</b> Low-dose paracetamol (&lt;1 g) is typically tolerated. "
               "Aspirin desensitisation + high-dose ASA maintenance is specific therapy for AERD.", body)],
    [Paragraph("<b>Chronic urticaria (NECD):</b> Cetirizine premedication before paracetamol "
               "may prevent breakthrough urticaria from weak COX-1 inhibitors.", body)],
]
sp_box = section_box("SPECIAL POPULATIONS", sp_data, AMBER, [sp_col])

kn_data = [
    [Paragraph("<b>Desensitisation:</b> Technically possible but rarely indicated given available "
               "alternatives. Reserved for cases where no safe alternative exists "
               "(e.g. specific transplant/oncology settings).", body)],
    [Spacer(1,3)],
    [Paragraph("<b>Skin tests:</b> Limited sensitivity/specificity for paracetamol. "
               "DPT is the gold standard for both confirming diagnosis and verifying "
               "tolerability of an alternative.", body)],
    [Spacer(1,3)],
    [Paragraph("<b>SJS/TEN HLA risk:</b> HLA susceptibility alleles have been implicated in "
               "paracetamol-induced SJS/TEN. Genomic screening is investigational.", body)],
]
kn_box = section_box("KEY CLINICAL NOTES", kn_data, AMBER, [sp_col])

sp_row = Table([[sp_box, Spacer(0.3*cm, 1), kn_box]],
               colWidths=[sp_col, 0.3*cm, sp_col])
sp_row.setStyle(TableStyle([
    ("VALIGN",        (0,0), (-1,-1), "TOP"),
    ("TOPPADDING",    (0,0), (-1,-1), 0),
    ("BOTTOMPADDING", (0,0), (-1,-1), 0),
    ("LEFTPADDING",   (0,0), (-1,-1), 0),
    ("RIGHTPADDING",  (0,0), (-1,-1), 0),
]))
story.append(sp_row)
story.append(Spacer(1, 7))

# ════════════════════════════════════════════════════════════
# FOOTER
# ════════════════════════════════════════════════════════════
story.append(HRFlowable(width=usable_w, thickness=0.5, color=MID_GREY))
story.append(Spacer(1, 3))
story.append(Paragraph(
    "Sources: Andryszkiewicz et al., Int J Mol Sci 2026 (PMID 42123311) · Bulut &amp; Katran, Allergol Immunopathol 2026 (PMID 41510935) · "
    "Spillers et al., Cureus 2023 (PMID 37519510) · WAO 2025 NSAID Hypersensitivity Statement · "
    "Sleisenger &amp; Fordtran's GI and Liver Disease · EAACI/ENDA Paediatric NSAID-HSR Position Paper. "
    "For clinical decisions, consult current guidelines and specialist opinion.",
    footnote_style))

# ════════════════════════════════════════════════════════════
# BUILD
# ════════════════════════════════════════════════════════════
doc.build(story)
print(f"PDF created: {OUTPUT}")
Running Command

cd /tmp/workspace/paracetamol-hypersensitivity && python generate_pdf.py 2>&1

Running Command

ls -lh /tmp/workspace/paracetamol-hypersensitivity/

The PDF has been created successfully (10 KB, single A4 page). Here it is:

Paracetamol Hypersensitivity Quick Reference

PDF Document · PDF


Here's what's included in the quick reference:
Page structure (single A4, colour-coded):
  • Navy header banner - title and subtitle
  • Classification box - pharmacological (pseudo-allergic, COX-1 mediated) vs. true immunological (IgE/T-cell), with the key 97.8% tolerability stat
  • Reaction types box - immediate (urticaria/anaphylaxis), cutaneous/SJS/TEN with BSA thresholds, hepatic hypersensitivity, DRESS
  • Acute management (two colour-coded panels):
    • Red panel - stepwise anaphylaxis management (epinephrine first-line, 7-step protocol)
    • Amber panel - urticaria/angioedema, SJS/TEN, hepatic HSR
  • Diagnostic work-up - 3-step post-acute protocol including DPT guidance per WAO 2025
  • Safe alternatives table - COX-2 inhibitors, nimesulide, metamizole, opioids with tolerability percentages and clinical notes
  • Phenotype tolerance table - NERD/NIUA/NECD/SNIUAA/SNIDHR with paracetamol safety and dose cautions
  • Special populations - pregnancy, paediatrics, AERD, chronic urticaria
  • Key clinical notes - desensitisation, skin test limitations, HLA/SJS genetics
  • Footnote with all source citations (PMIDs)
This is a shared conversation. Sign in to Orris to start your own chat.