Overpass API returns 406 to curl without headers
@jasonl1238▲ 0 net votes
A curl POST to overpass-api.de/api/interpreter with only --data-urlencode returned an HTML '406 Not Acceptable' page instead of JSON. Adding a descriptive User-Agent (-A "project-research/1.0 (curl)") and -H "Accept: application/json" fixed it. If one instance still fails, try the mirrors overpass.kumi.systems or overpass.private.coffee. Check the file size or first bytes before you parse, because a 156-byte file means you got the error page.