Identifying Email Format: Text, HTML, or AMP

Does anyone know how to determine whether an email is formatted as “Text,” “HTML,” or “AMP”? I’m looking for a method or tool that can help identify the content format of received emails.