Heat the oil in a large pan over medium heat and add the chopped onions and jalapeno peppers if using. Cook for about 5 minutes until softened and fragrant.
Once the onions are translucent, add the chopped garlic and cook for another 30 seconds to 1 minute, stirring frequently until fragrant but not burnt.
Season the chicken thighs generously with salt and pepper before adding them to the pan. Cook for about 2 minutes on one side, then flip and cook for an additional 2 minutes until lightly browned.
In a food processor, blend together the tomato sauce and chipotles in adobo sauce until smooth, then pour this mixture into the pan over the chicken, ensuring they are well covered.
Stir in chili powder, cumin, Mexican oregano, along with additional salt and pepper as needed. Bring to a quick boil before reducing the heat to simmer.
Let it simmer for about 30 minutes or until the chicken is cooked through and easily pulls apart with a fork. Remove the chicken, shred it, and return it to the sauce for an extra five minutes before serving.