Trello API “add comment” not working

Hello all.

I am not able to succeed with „add new comment" request via Trello API.

There is test curl request (from the docs):
curl --request POST
–url ‘https://api.trello.com/1/cards/CARD_ID/actions/comments?text=text&key=API_KEY&token=API_TOKEN
–header ‘Accept: application/json’

Of course CARD_ID, API_KEY and API_TOKEN have to be replace with corresponding values of the real card id/key/token.
The authorization exception is raised.

For comparison I’ve used this „get comments" curl request which works with the same credentials:
curl --request GET
–url ‘https://api.trello.com/1/cards/CARD_ID/actions?filter=commentCard&key=API_KEY&token=API_TOKEN
–header ‘Accept: application/json’

I assume that this API endpoint just doesn’t work (or docs aren’t up to date).

Hello @WojciechKluz

I just tested the Add a new comment to a Card endpoint and it’s working perfectly. You’re probably doing something wrong.

What is the specific error code and message you get back from the request?
Did you get the same result when you tested the same request with a tool like Postman?
Does it work if you omit the --header flag and don’t specify an Accept value?