Rest Switch & Command Line for Teslafi

What kind of installation type of HA?
Does the command work if you start it in a terminal?
If you run Home Assistant OS, try it inside the HA container.