Hi, I'm a endoscopy nurse. Sounds like you're having a gastroscopy.
Some units have smaller cameras that go through a nostril instead, these are usually more comfortable than going through the mouth - but be aware some places will only go through the mouth.
Generally what happens is, you'll get some numbing spray first (patients usually tell me this is the worst bit), some opt for sedation, it's up to you but if you do make sure you bring someone with you to take you home.
If going through the mouth, they'll put a mouthpiece in to put the camera through easily and prevent you biting it.
The camera travels down your throat, your oesophagus (gullet) and into your stomach, to the duodenum (beginning of the small intestine). This is as far as the camera goes. The endoscopist will usually perform something called a J manoeuvre which is basically turning the tip of the camera back on itself to look at the top of the stomach.
Then they'll head out.
They may take biopsies if need be, depending on what they see or what you've been referred for. You won't feel these being taken, and it usually happens on the way out.
They may test for the presence of helicobacter pylori in your stomach, during which they'd take a small biopsy and then test it there, and let you know the result before you leave. Again, depends if your GP has already done this via a stool test or not, and also depends what you've been referred for.
Where I work, these procedures don't usually take longer than 5 minutes on average.
I will advise though, that if you're feeling panicky at all, DO NOT try and pull the camera out yourself or grab hold of it in any way! This could be dangerous and cause you damage. Remember to breathe, nice steady breaths in and out, this will lessen any gagging and panicking.
Let me know if you have any questions! Good luck, you will be fine!