| Server IP : 104.21.17.213 / Your IP : 216.73.217.141 Web Server : Apache System : Linux hosting01.arsenalhost.com 4.18.0-425.13.1.lve.el8.x86_64 #1 SMP Mon Feb 27 15:23:24 EST 2023 x86_64 User : corbizre ( 1013) PHP Version : 7.4.33 Disable Function : exec,passthru,shell_exec,system MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : ON | Pkexec : ON Directory : /home/corbizre/findnextproperty.com/console/controllers/ |
Upload File : |
<?php
namespace console\controllers;
use Yii;
use yii\httpclient\Client;
class VideoController extends \yii\console\Controller
{
const TOKEN = '77a854d36b7193981ec12f21f71d4880b6c7395d69bd6ee6601761338c5c3dee2a3dc7ff74cf6c61fe00ecfc3b5ad9e028a8e1b588dcf76400256992b36b9aaf';
public function actionTest()
{
$client = new Client();
$response = $client->createRequest()
->setMethod('post')
->setFormat(Client::FORMAT_JSON)
->setUrl('http://144.76.33.130/help/api/v2')
->setData([
'token' => self::TOKEN,
'email' => '[email protected]'
])
->send();
if ($response->isOk) {
$newUserId = $response->data['id'];
vd($response);
}
vd($response);
}
}