Naturally, what happens when you put a fish in tap water depends on what's in the tap water.
Most tap water has chlorine added to it (to kill pathogenic bacteria). In a great many cases, it also has ammonia added (the ammonia/chlorine combination is known as chloramine). For aquarium purposes, this is important because chloramine is very stable, and will not escape from water on its own, the way free chlorine will if you "age" the water. If you are on a city water utility, you can get more information about exactly what's in the water from the water department. If you have your own well or cistern, you may have to pay for a test to find out what chemicals are in the water. (Most well water is not chlorinated, but it may contain other toxic elements.)
Both chlorine and ammonia poison fish by burning the fish's gills. Therefore, the fish cannot respirate properly and doesn't get enough oxygen. (By the way, chlorine gas was used as a chemical weapon against humans in World War I.) A strong dose of chlorine or ammonia, or chloramine, will kill a fish more or less instantly, but a small amount will just make the fish sick.
Most of us in the aquarium hobby use tap water, rather than bottled water, to fill our tanks, but before putting fish in, we add water conditioner. Water conditioner, also known as dechlorinator or dechloraminator, is just a chemical or a group of chemicals, that neutralizes chlorine and ammonia in the water. Some brands of water conditioner claim to also do various other things. It is inexpensive, especially in the amount you'll need for a typical betta tank, and is available at every pet shop. Even some large grocery stores, drug stores, hardware stores, and feed stores sell aquarium water conditioner. Some brands of water conditioner neutralize chlorine but not ammonia, so if there is ammonia or chloramine in your water, or if you don't know if there is or not, be sure to get water conditioner that says on the label that it neutralizes (or "removes") both chlorine and ammonia.
As for your fish, if it is still in the untreated tap water, I would get it out of that water as soon as possible and put it in water that has been treated to remove the chlorine and ammonia.