Mongo Db Querry

Hello everyone I am new to retool and I am using Mongo Db. But when I write my nosql queries I get an error message that Json is invalid, yet when I test the same query on compact and on jsonformatter there is no problem. I would like to know the reaso