To be safe I would go to the Thai embassy in your home country and if required fill out the one 60 day tourist visa. It will be stressful enough dealing with medical procedures and the piece of mind of having a full 60 days would be worth it (in my opinion). If for whatever reason you still have the option to extend by an additional 30 days (90 day stay total). I’ve done this several times and it is worth it if you plan on staying past the normal 30 day entry visa.
I’d just get a visa prior to leaving your country. It could save you a bunch of hassle at immigration when you land. It’s not like the good ol’ days when you could over stay and pay the penalty on departure. If you choose to do the 30 day extension plan on wasting a full day. Usually you have to show up at 7:00a.m and hang around until after the immigration gets back from lunch.
Other option is Plan a boarder crossing part way through your trip but that is another wasted day and would cost you just as much as you’d pay for a 60 day visa in your home country. I suggest just getting the proper visa before leaving home and enjoy your vacation stress free 👍🏽