add wechaty ca, see https://github.com/wechaty/php-wechaty/issues/16
PHP Wechaty Starter Project Template that Works Out-of-the-Box
Wechaty is a RPA SDK for Wechat Individual Account that can help you create a chatbot in 8 lines of PHP.
$wechaty = \IO\Github\Wechaty\Wechaty::getInstance($token, $endPoint); $wechaty->onScan(function($qrcode, $status, $data) { $qr = \IO\Github\Wechaty\Util\QrcodeUtils::getQr($qrcode); echo "$qr\n\nOnline Image: https://wechaty.github.io/qrcode/$qrcode\n"; })->onLogin(function(\IO\Github\Wechaty\User\ContactSelf $user) { })->onMessage(function(\IO\Github\Wechaty\User\Message $message) { $message->say("hello from PHP7.4"); })->start();
# Install make sure php is 7.4+ sudo yum install php-pecl-grpc sudo yum install php-pecl-protobuf sudo yum install php-xml # curl -sS https://getcomposer.org/installer | php php -r "copy('https://install.phpcomposer.com/installer', 'composer-setup.php');" php composer-setup.php php -r "unlink('composer-setup.php');" mv composer.phar /usr/local/bin/composer make install
export WECHATY_PUPPET_HOSTIE_TOKEN=your_token_at_here make bot
WECHATY_PUPPET_SERVICE_TLS_CA_CERT
options.tlsRootCert
For Puppet Server:
WECHATY_PUPPET_SERVICE_TLS_SERVER_CERT
options.tls.serverCert
WECHATY_PUPPET_SERVICE_TLS_SERVER_KEY
options.tls.serverKey
WECHATY_PUPPET_SERVICE_NO_TLS_INSECURE_SERVER
options.tls.disable
true
For Puppet Client:
WECHATY_PUPPET_SERVICE_AUTHORITY
options.authority
api.chatie.io
options.caCert
WECHATY_PUPPET_SERVICE_TLS_SERVER_NAME
options.serverName
WECHATY_PUPPET_SERVICE_NO_TLS_INSECURE_CLIENT
Learn more about tls at https://github.com/wechaty/puppet-service
[](https://github.com/wechaty/php-wechaty)
@wechaty/php
版权所有:中国计算机学会技术支持:开源发展技术委员会 京ICP备13000930号-9 京公网安备 11010802032778号
php-wechaty-getting-started

PHP Wechaty Starter Project Template that Works Out-of-the-Box
Connecting Chatbots
Wechaty is a RPA SDK for Wechat Individual Account that can help you create a chatbot in 8 lines of PHP.
The World’s Shortest PHP ChatBot: 8 lines of Code
Usage
Install
Run
New environment variables
WECHATY_PUPPET_SERVICE_TLS_CA_CERT: can be overwrite byoptions.tlsRootCert. Set Root CA Cert to verify the server or client.For Puppet Server:
WECHATY_PUPPET_SERVICE_TLS_SERVER_CERToptions.tls.serverCertWECHATY_PUPPET_SERVICE_TLS_SERVER_KEYoptions.tls.serverKeyWECHATY_PUPPET_SERVICE_NO_TLS_INSECURE_SERVERoptions.tls.disabletrueto disable server TLSFor Puppet Client:
WECHATY_PUPPET_SERVICE_AUTHORITYoptions.authorityapi.chatie.ioWECHATY_PUPPET_SERVICE_TLS_CA_CERToptions.caCertWECHATY_PUPPET_SERVICE_TLS_SERVER_NAMEoptions.serverNameWECHATY_PUPPET_SERVICE_NO_TLS_INSECURE_CLIENToptions.tls.disabletrueto disable client TLSWechaty Getting Started in Multiple Languages
Badge
Maintainers
@wechaty/php
Copyright & License