API URL for button.press service call

I am trying to press a button from Rest API using curl command.
I already tried a variety of combinations of this command:

curl -X POST -H 'Authorization: Bearer <KEY>' -H 'Content-Type: application/json' -d '{"entity_id": "button.pill_dispenser"}' https://my_server.duckdns.org:8123/api/services/button.press

The result comes with 2 square brackets: [] but without any action.
I already have this working with other services like thermostat control, lights, switches, scripts, etc…
I would be very grateful if someone can point me in the right direction.

1 Like

/api/services/button/press