How long should I wait to send an email after an interview?
It's best to send a thank-you email within 24 hours of your interview. Doing so demonstrates your interest in the job. It also keeps you top of mind with those you met with as they consider other candidates.
What do you say in a follow up email after an interview?
Thank them for their time in the interview. Explain that you're following up on your interview - remember to be specific about the job, mentioning the job title and interview date. Restate your interest in the position and say you're keen to hear about next steps.
Is it appropriate to ask if you got the job?
Like so many other aspects of the job search process, of course you need to be professional. But it's definitely OK to ask if you got the job after a successful interview and, in fact, shows initiative and a desire for the role. (Just be sure you're not inappropriate, annoying or pushy.)