PHP code example of wisdom / call-voice

1. Go to this page and download the library: Download wisdom/call-voice library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

wisdom / call-voice example snippets


$data['phone_url'] = 需要拨打电话语音的电话获取连接url,例如:'https://www.baidu.com/tests';
$data['route_num'] = 指定此批电话所执行的行为ID,例如:'52000700002';
(new Voice($data))->start();

$data = [
            'code' => 200,
            'reason' => 'ok',
            'isend' => 'true',
            'nums' => [
                [
                    'id'=>1,
                    'phone'=>[
                        '18655555555',
                        '18666666666'
                    ],
                    'param'=>1,
                ]
            ],
        ];
return response()->json($data, 200);