Element API Endpoint returns data but has 404 header
Removing this from my site's nginx conf fixed it:

location ~* \.(?:manifest|appcache|html?|xml|json)$ {
 expires -1;
}


However, what I really want to do is cache stuff, without breaking this endpoint