reportParams = $reportParams; } /** * Execute the job. * @throws \GuzzleHttp\Exception\GuzzleException */ public function handle() { $client = new Client(); $params = [ 'ip' => $this->reportParams->ip, 'device_no' => $this->reportParams->device_no, 'mac' => $this->reportParams->mac ?? '', 'channel_id' => (int)$this->reportParams->channel_id, 'uid' => (int)$this->reportParams->uid, 'register_time' => $this->reportParams->register_time, 'is_report' => (string)$this->reportParams->is_report, 'source' => 'zsy', 'send_order_id' => $this->reportParams->send_order_id, ]; $params['sign'] = _sign($params, SysConsts::TIKTOK_KEY); $url = env('TIKTOK_API_URL').'api/qappuser/register'; $response = $client->request('post', $url, ['form_params' => $params])->getBody()->getContents(); myLog('qapp_user_register')->info($response); $result = json_decode($response); if ($result) { if ($result->code != 0) { myLog('qapp_user_register')->info($response); } } } }