Dude, curl post give input from file works best when the file is properly formatted. Use `jsonlint` to validate your `data.json` first.
Also, some APIs hate the `-X POST` flag. Try just:
`curl http://example.com/api -d @data.json`
Curl defaults to POST with `-d` anyway. Weird, but true!
Also, some APIs hate the `-X POST` flag. Try just:
`curl http://example.com/api -d @data.json`
Curl defaults to POST with `-d` anyway. Weird, but true!
