You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
To enable extension recordings, but these parameters are not working. Extensions are always being created with 'dontcare'.
Looking at the api code in /var/www/html/pbxapi/controllers/extension.php in lines 512 to 515 it is possible to see that there are validations for the following parameters: recording.inbound_external, recording.inbound_internal, recording.outbound_external, recording.outbound_internal are not received, by default they will be 'dontcare'. Example:
I think here we have the first error: the name of the parameters in validation is different from what was documented, causing the Recording Options not to work when passing the parameters that was documented.
I did tests passing the parameters as lines 512-515 expect, but I still got 'dontcare', so I found the possible second error.
In line 898 of the file /var/www/html/pbxapi/controllers/extension.php, it renames the received parameters according to the variable $field_map, declared in the same file in line 42, causing the parameters of the Recording Options to be renamed as follows:
The parameters are now called 'astdb.ampusers.recording/in/external', 'astdb.ampusers.recording/in/internal', 'astdb.ampusers.recording/out/external', 'astdb.ampusers.recording/out/ internal', different from what lines 512-515 expect, causing the value to always be 'dontcare'.
Could you fix that? Thanks!
Edit: My suggestion for correction: change lines 512-515 to: $RECINEXT = isset($post['astdb.ampusers.recording/in/external'])?$post['astdb.ampusers.recording/in/external']:'dontcare'; $RECININT = isset($post['astdb.ampusers.recording/in/internal'])?$post['astdb.ampusers.recording/in/internal']:'dontcare'; $RECOUTEXT = isset($post['astdb.ampusers.recording/out/external'])?post['astdb.ampusers.recording/out/external']:'dontcare'; $RECOUTINT = isset($post['astdb.ampusers.recording/out/internal'])?post['astdb.ampusers.recording/out/internal']:'dontcare';
The text was updated successfully, but these errors were encountered:
The api documentation says that it is possible to pass the following parameters:
To enable extension recordings, but these parameters are not working. Extensions are always being created with 'dontcare'.
Looking at the api code in /var/www/html/pbxapi/controllers/extension.php in lines 512 to 515 it is possible to see that there are validations for the following parameters: recording.inbound_external, recording.inbound_internal, recording.outbound_external, recording.outbound_internal are not received, by default they will be 'dontcare'. Example:
$RECINEXT = isset($post['recording.inbound_external'])?$post['recording.inbound_external']:'dontcare';
I think here we have the first error: the name of the parameters in validation is different from what was documented, causing the Recording Options not to work when passing the parameters that was documented.
I did tests passing the parameters as lines 512-515 expect, but I still got 'dontcare', so I found the possible second error.
In line 898 of the file /var/www/html/pbxapi/controllers/extension.php, it renames the received parameters according to the variable $field_map, declared in the same file in line 42, causing the parameters of the Recording Options to be renamed as follows:
The parameters are now called 'astdb.ampusers.recording/in/external', 'astdb.ampusers.recording/in/internal', 'astdb.ampusers.recording/out/external', 'astdb.ampusers.recording/out/ internal', different from what lines 512-515 expect, causing the value to always be 'dontcare'.
Could you fix that? Thanks!
Edit: My suggestion for correction: change lines 512-515 to:
$RECINEXT = isset($post['astdb.ampusers.recording/in/external'])?$post['astdb.ampusers.recording/in/external']:'dontcare'; $RECININT = isset($post['astdb.ampusers.recording/in/internal'])?$post['astdb.ampusers.recording/in/internal']:'dontcare'; $RECOUTEXT = isset($post['astdb.ampusers.recording/out/external'])?post['astdb.ampusers.recording/out/external']:'dontcare'; $RECOUTINT = isset($post['astdb.ampusers.recording/out/internal'])?post['astdb.ampusers.recording/out/internal']:'dontcare';
The text was updated successfully, but these errors were encountered: