encode query for mapcenter call