Yo, had the same issue last week! Here’s the magic combo:
```
curl -X POST https://example.com/api \
-H "Content-Type: application/json" \
-d '{"name": "test"}'
```
If it’s still failing, maybe the API expects a trailing slash or something? Try `https://example.com/api/`.
Also, `jq` is handy for pretty-printing JSON responses if you’re on Linux/Mac.
```
curl -X POST https://example.com/api \
-H "Content-Type: application/json" \
-d '{"name": "test"}'
```
If it’s still failing, maybe the API expects a trailing slash or something? Try `https://example.com/api/`.
Also, `jq` is handy for pretty-printing JSON responses if you’re on Linux/Mac.
