I am sure the “medicine” had something bad in it like arsenic or mercury. You need something potent enough to kill the critters in your tummy.
If you google “tapeworm removal” there are, um....videos (gag, choke, sputter, cough, wheeze)