Hey! I did some research because I know this question was answered, before, so here are some links to questions previously asked in /r/AskHistorians!
How did Siam (Thailand) avoid colonization by Europeans?
Why was Thailand never colonized by a European power?