I am trying to get a command line switch to work with access token authentication, but I am not having any luck. This used to work with the api password, but I keep getting failed login with the following set up. Nothing else change but the Authorization: Bearer MYACCESSTOKEN
portion.
zone_kitchen:
command_on: "curl -X POST -H 'Authorization: Bearer MYACCESSTOKEN' -H 'Content-Type: application/json' -d '{ \"entity_id\": \"media_player.kitchen\" }' 'https://myhass.duckdns.org/api/services/media_player/turn_on'"
command_off: "curl -X POST -H 'Authorization: Bearer MYACCESSTOKEN' -H 'Content-Type: application/json' -d '{ \"entity_id\": \"media_player.kitchen\" }' 'https://myhass.duckdns.org/api/services/media_player/turn_off'"