setup rest api for all mongo tables