return JSON from both entry points