for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
/*
* This file is part of the overtrue/wechat.
*
* (c) overtrue <[email protected]>
* This source file is subject to the MIT license that is bundled
* with this source code in the file LICENSE.
*/
namespace EasyWeChat\BasicService\ContentSecurity;
use EasyWeChat\Kernel\BaseClient;
/**
* Class Client.
* @author tianyong90 <[email protected]>
class Client extends BaseClient
{
* @var string
protected $baseUri = 'https://api.weixin.qq.com/wxa/';
* Text content security check.
* @param string $text
* @return array|\EasyWeChat\Kernel\Support\Collection|object|\Psr\Http\Message\ResponseInterface|string
* @throws \EasyWeChat\Kernel\Exceptions\InvalidConfigException
public function checkText(string $text)
$params = [
'content' => $text,
];
return $this->httpPostJson('msg_sec_check', $params);
}
* Image security check.
* @param string $path
public function checkImage(string $path)
return $this->httpUpload('img_sec_check', ['media' => $path]);