ARI - channel/bridge recording

Hello there,

I’m using phpari with Asterisk 13 and trying to record a bridge (mixing type).
In my code:

It returns:

array(4) { ["name"]=> string(5) "debug" ["format"]=> string(3) "wav" ["state"]=> string(6) "queued" ["target_uri"]=> string(15) "bridge:5:1:503" }

When and I stop and save with

It returns FALSE.

I debug with


* About to connect() to localhost port 8088 (#0)
*   Trying ::1... Connection refused
*   Trying connected
* Connected to localhost ( port 8088 (#0)
* Server auth using Basic with user 'xxxxx'
> POST /ari/recordings/live/debug/stop HTTP/1.1
> Authorization: Basic xxxxxxx
> User-Agent: curl/7.19.7 (xxxxx) libcurl/7.19.7 NSS/ Basic ECC zlib/1.2.3 libidn/1.18 libssh2/1.4.2
> Host: localhost:8088
> Accept: */*
< HTTP/1.1 404 Not Found
< Server: Asterisk/13.2.0
< Date: Thu, 19 Feb 2015 11:58:18 GMT
< Cache-Control: no-cache, no-store
< Content-type: application/json
< Content-Length: 38
  "message": "Recording not found"
* Connection #0 to host localhost left intact
* Closing connection #0

Any help?

Thank you

Verbose 5 trace:

I’ve solved the problem with the help of mjordan on the IRC channel.

It was a simple write permission problem.

Asterisk user couldn’t write on /var/spool/asterisk/recording because it was owned by root. Changing the ownership to the asterisk user solved it.

This problem can be detected by looking at the Asterisk CLI trace again:

This b[/b] indicates that the file could not be written, so I checked the folder and saw where the problem was.