Mycobacterium protein tyrosine phosphatase B (mPTPB) is essential for the survival and persistence of Mycobacterium in the host. Thus small molecule inhibitors of mPTPB are potential anti-TB agents. We developed an efficient organocatalytic multicomponent reaction (MCR) between pyrrole, formaldehyde and aniline, affording a potent and selective mPTPB inhibitor with an IC(50) value of 1.5 μM and >50-fold specificity. Our studies provide a successful example of using organocatalysis as a discovery tool for the acquisition of PTP inhibitors.