The fungal natural product CJ-12662 is a structurally complex terpene-amino acid hybrid, and is a potent anthelmintic compound. The biosynthetic pathway of CJ-12662 is elucidated based on metabolite analysis from heterologous expression. We demonstrate the terpene portion is derived from successive P450-catalyzed oxidations of amorpha-4,11-diene, while three flavin-dependent enzymes are involved in morphing the esterified tryptophan into a chlorinated pyrrolobenzoxazine, utilizing a cascaded [1,2]-Meisenheimer rearrangement.