Perl 微信模块--Weixin::Client

鄢选
2023-12-01
package Weixin::Client;
use strict;
use File::Spec;
use Weixin::Util;
use LWP::UserAgent;
use Weixin::UserAgent;
use LWP::Protocol::https;

use base qw(
    Weixin::Message 
    Weixin::Client::Callback
    Weixin::Client::Operate
    Weixin::Client::Friend
    Weixin::Client::Chatroom
    Weixin::Client::Request 
    Weixin::Client::Cron
    Weixin::Client::Plugin
    Weixin::Client::Base
);

our $VERSION = "2.0";

sub new{
    ##$class 是Weixin::Client
    my $class = shift;
	##%pdebug0  是传入的my $client = Weixin::Client->new(debug=>0);  
    my %p = @_;
    my $agent = 'Mozilla/5.0 (Windows NT 6.1) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/37.0.2062'; 
    my $tmpdir = File::Spec->tmpdir();
    my $cookie_filename = $p{login_file} || "$tmpdir/weixin_client_login.dat";
    my $self = {
        cookie_jar              => HTTP::Cookies->new(hide_cookie2=>1,file=
 类似资料: