There are many pathogenic species of ecoli. The use of PCR has allowed the differentiation of these organisms in stool specimens. The following article discusses Enteroinvasive E. coli (EIEC).
https://www.asm.org/Articles/2019/March/Whats-the-Significance-of-Enteroinvasive-E-coli