I understand its OK to work online as long as the platform you use to teach is not Thai or based in Thailand and your students are not Thai.
That said, the laws change often but the last time (a few months ago) I had a conversation, this was the case
There is the DTV option which I enquired about but because I have been in the UK 2 years and havent used the platform I use for online teaching, I didnt qualify as you have to have up to date payments from your platform to show (live and currently working) when you apply. Speak to Thai Visa
@THAI *****************************
and they will be able to guide you more. I spoke via email with someone else (a different agent) who informed me of this. The DTV gives you 5 years in 6 month increments and I think the amount you need to have in your bank is 500,000bht