Resp api service call to set helper value

I like to fire an rest api call from a php page to set an input_number helper value.
I know I have to use the /services/input_number/set_value endpoint.
I use the following json as the body of the post

{“entity_id”: “input_number.gewenste_temp”, “value”: 21}

but get an 405: Method Not Allowed error.
What to do?