query available languages in the local server using js