fixed JSON output for API call