Amniocentesis is a procedure capable to be done after 20 weeks (if I recall correctly) where they take some of the amniotic fluid to run DNA tests to see if there will be any congenital/birth defects: this is how they know a baby will have Down Syndrome before it's born, for example. It's only done if there is a reason for concern, because despite being a simple procedure there is potential for complications such as triggering an early birth.