All perfect praise be to Allaah, the Lord of the worlds. I testify that there is none worthy of worship except Allaah and that Muhammad is His slave and messenger.
Using endoscopes for investigating the causes of illness does not affect the validity of fasting, as explained by the Islamic Fiqh Academy. As for vaginal tablets, the fasting woman should delay taking such medicine until night or until after Ramadan, if possible. There is a difference in the scholarly opinions regarding the validity of the fast if these tablets are taken during the daytime in Ramadan. According to Hanbali and Maliki scholars, injecting a medicine through the vagina does not invalidate fasting. This is different from the view held by Shaafi’i scholars.
In his Book Kashshaaf Al-Qinaa’, Al-Buhooti, the Hanbali scholar says:
"Vaginal injection does not invalidate fasting because the bladder does not extend to the throat. Also, our fellow Hanbli scholars did not consider it one of the body entrances that lead to the stomach. Thus, injecting something through it does not invalidate the fast."
In Haashiyat Ad-Dusooqi, the Maliki scholar Ad-Dusooqi says, “… it is thus known that the injection through the vagina does not invalidate fasting just like injection through the penis does not.”
An-Nawawi, the Shaafi‘i scholar, says in Al-Majmoo‘, “Injection invalidates fasting whether or not it reaches the abdomen and whether the injected substance is little or much.”
That being said, if you need to take the medicine mentioned in your question during the daytime in Ramadan to the extent that if you do not take it your condition will worsen and your recovery will be delayed, then you may break your fast to take that medicine and make up for the fast later on in order to avoid the difference in opinions among the scholars in this regard and to be more prudent.
Allaah Knows best.