Hi, I’ve got an FXO analogue line card hooked up to Asterisk with DAHDI drivers and want to try and automate going off-hook and dialling a number so simulate a user using an analogue phone.
I’m using the Python language binding for ARI and have created the
channel-dump Stasis application running in the background. So far I have:
channel = client.channels.create(endpoint='DAHDI/16', app='channel-dump') channel.dial() channel.sendDTMF(dtmf='1234')
However the sendDTMF function returns with the error:
412 Client Error: Precondition Failed for url: http://asterisk:8088/ari/channels/1591883354.12/dtmf?dtmf=1234
Is there more initialisation I need to do in order to send DTMF?