simontelephonics / smsconnector

SMS Connector module for FreePBX 16 and 17
https://simon.tel/open-source/
GNU General Public License v3.0
43 stars 16 forks source link

Update provider-Voxtelesys.php #27

Closed wecaredoyou closed 1 year ago

wecaredoyou commented 1 year ago

by adding the brackets within the to fixes error of the to not being in a array $req = array( 'from' => '+'.$from, 'to' => ['+'.$to], 'media' => $this->media_urls($id)

public function sendMessage($id, $to, $from, $message=null)
{
    $req = array(
        'from'  => '+'.$from,
        'to'    => ['+'.$to],
        'body'  => $message

I have tested this error is now gone and message sends. Error thrown before change was sms connector Server Error: Unable to send message: HTTP 422, {"status":"error","error":"to must be an array"}

billsimon commented 1 year ago

Fixed in release v16.0.12