constant DEBUG => $ENV{DEBUG};
use if DEBUG, 'Smart::Comments';
use LWP::UserAgent;
use JSON qw( decode_json );
use String::Util qw(trim);
our $VERSION = '1.67_01'; # TRIAL VERSION
our $DISPLAY =
charset=UTF-8',
};
my $reply = $ua->post($url, $form);
my $search = JSON::decode_json $reply->content;
### Search : $url, $form, $reply->code
### Search : $sea
nings;
use Encode qw(encode_utf8);
use HTML::TreeBuilder;
use HTTP::Request::Common;
use JSON qw( decode_json );
use Date::Parse qw(str2time);
use POSIX qw(strftime);
use constant DEBUG => $ENV{DEBU
}
sub onvista {
my $quoter = shift;
my @stocks = @_;
my (%info, $tree, $url, $reply, $json, $json_decoded);
my $ua = $quoter->user_agent();
foreach my $stock (@stocks) {
$url = $O
body)) {
$tree->eof;
unless ( $json = encode_utf8 (($tree->look_down(_tag => 'script', id => '__NEXT_DATA__', type => 'application/json')->content_list())[0]) ) {
$info{ $st
#!/usr/bin/perl -w
# This module is based on the Finance::Quote::yahooJSON module
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU Gene
lose as returned in the JSON.
# Bruce Schuck (bschuck at asgard hyphen systems dot com)
package Finance::Quote::AlphaVantage;
use strict;
use JSON qw( decode_json );
use HTTP::Request::C
ort
my $ALPHAVANTAGE_URL =
'https://www.alphavantage.co/query?function=GLOBAL_QUOTE&datatype=json';
my %currencies_by_suffix = (
# Country City/Exchange Name
'.US'
2110-1301, USA
package Finance::Quote::Fool;
use strict;
use HTTP::Request::Common;
use JSON qw( decode_json );
use Text::Template;
use Encode qw(decode);
use constant DEBUG => $ENV{DEBUG};
use if
D}?timeFrame=OneWeek&precision=Day&apikey=6cbf5f34-ba40-4108-a1ab-d951c608955e');
# Fool returns JSON with a Currency stanza
# '1' -> USD
my %currencies_by_id = (
'1' => 'USD',
);
our $DISPLAY
t;
my @stocks = @_;
my (%info, $symbol, $url, $reply, $code, $desc, $body);
my ($json_data, $instrumentID, $exchange, $tree );
my %mnames = (jan => 1, feb => 2, mar => 3, apr => 4
omments';
use LWP::UserAgent;
use HTTP::Request::Common;
use HTML::TableExtract;
use Encode;
use JSON;
use Web::Scraper;
our $VERSION = '1.65'; # VERSION
my $BAMOSZ_MAINURL = "http://www.bamosz.hu/
ed to find JSON data" unless $response->content =~ m|window[.]dataSourceResults=([{].+[}])</script>|;
my $json = decode_json $1;
### json : $json
### keys : keys %{$json}
my
grep {/CompanyProfileDataSource;table=left/} keys %{$json};
die "Failed to process JSON" unless @profile_key == 1;
my $profile = $json->{$profile_key[0]};
### profile : $profile
e strict;
use warnings;
use constant DEBUG => $ENV{DEBUG};
use if DEBUG, 'Smart::Comments';
use JSON;
use Web::Scraper;
our $VERSION = '1.64_03'; # TRIAL VERSION
sub methods {
return (aufunds =>
200;
my $json_data = JSON::decode_json $reply->content;
### MorningstarAU lookup: $json_data
die "Failed to find unique APIR $symbol" unless $json_data and $json_data->{hits}->{
total} == 1;
my $id = $json_data->{hits}->{hits}[0]->{_source}->{Symbol};
### MorningstarAU input: $symbol
### MorningstarAU id : $id
my $url = "https://www.morningsta
se Encode qw( encode_utf8 );
use HTTP::Request::Common;
use HTML::TreeBuilder::XPath;
use JSON qw( decode_json );
use LWP::Protocol::http;
use Text::Template;
use HTTP::Cookies;
use URI::Escape;
use
=> $ENV{DEBUG};
use if DEBUG, 'Smart::Comments';
use constant URLTAG => "data-url";
use constant JSONBODY => "body";
our $VERSION = '1.67_01'; # TRIAL VERSION
# Fix for 500 Header line too long mes
>decoded_content);
$script_tag = $tree->look_down(_tag => 'script', type => 'application/json', URLTAG, qr!https://query1.finance.yahoo.com/v7/finance/quote\?fields=fiftyTwoWeekHigh.*! );
ud::Object::DocumentReplaceResult;
require 5.6.0;
use strict;
use warnings;
use utf8;
use JSON qw(decode_json);
use Data::Dumper;
use Module::Runtime qw(use_module);
use Log::Any qw($log);
use Date::
bute};
$self->$attribute( $args{ $args_key } );
}
return $self;
}
# used by JSON for serialization
sub TO_JSON {
my $self = shift;
my $_data = {};
foreach my $_key (keys %{$self->a
sCloud::Object::ShapeExportFormat;
require 5.6.0;
use strict;
use warnings;
use utf8;
use JSON qw(decode_json);
use Data::Dumper;
use Module::Runtime qw(use_module);
use Log::Any qw($log);
use Date::
bute};
$self->$attribute( $args{ $args_key } );
}
return $self;
}
# used by JSON for serialization
sub TO_JSON {
my $self = shift;
my $_data = {};
foreach my $_key (keys %{$self->a
e AsposeSlidesCloud::Object::Task;
require 5.6.0;
use strict;
use warnings;
use utf8;
use JSON qw(decode_json);
use Data::Dumper;
use Module::Runtime qw(use_module);
use Log::Any qw($log);
use Date::
bute};
$self->$attribute( $args{ $args_key } );
}
return $self;
}
# used by JSON for serialization
sub TO_JSON {
my $self = shift;
my $_data = {};
foreach my $_key (keys %{$self->a
esCloud::Object::DelimiterElement;
require 5.6.0;
use strict;
use warnings;
use utf8;
use JSON qw(decode_json);
use Data::Dumper;
use Module::Runtime qw(use_module);
use Log::Any qw($log);
use Date::
s{ $args_key } );
}
$self->{ type } = 'Delimiter';
return $self;
}
# used by JSON for serialization
sub TO_JSON {
my $self = shift;
my $_data = {};
foreach my $_key (keys %{$self->a
oud::Object::ImageTransformEffect;
require 5.6.0;
use strict;
use warnings;
use utf8;
use JSON qw(decode_json);
use Data::Dumper;
use Module::Runtime qw(use_module);
use Log::Any qw($log);
use Date::
bute};
$self->$attribute( $args{ $args_key } );
}
return $self;
}
# used by JSON for serialization
sub TO_JSON {
my $self = shift;
my $_data = {};
foreach my $_key (keys %{$self->a
lidesCloud::Object::PathInputFile;
require 5.6.0;
use strict;
use warnings;
use utf8;
use JSON qw(decode_json);
use Data::Dumper;
use Module::Runtime qw(use_module);
use Log::Any qw($log);
use Date::
$args{ $args_key } );
}
$self->{ type } = 'Path';
return $self;
}
# used by JSON for serialization
sub TO_JSON {
my $self = shift;
my $_data = {};
foreach my $_key (keys %{$self->a
esCloud::Object::ReflectionEffect;
require 5.6.0;
use strict;
use warnings;
use utf8;
use JSON qw(decode_json);
use Data::Dumper;
use Module::Runtime qw(use_module);
use Log::Any qw($log);
use Date::
bute};
$self->$attribute( $args{ $args_key } );
}
return $self;
}
# used by JSON for serialization
sub TO_JSON {
my $self = shift;
my $_data = {};
foreach my $_key (keys %{$self->a
SlidesCloud::Object::ReorderSlide;
require 5.6.0;
use strict;
use warnings;
use utf8;
use JSON qw(decode_json);
use Data::Dumper;
use Module::Runtime qw(use_module);
use Log::Any qw($log);
use Date::
$args_key } );
}
$self->{ type } = 'ReoderSlide';
return $self;
}
# used by JSON for serialization
sub TO_JSON {
my $self = shift;
my $_data = {};
foreach my $_key (keys %{$self->a
SlidesCloud::Object::ErrorDetails;
require 5.6.0;
use strict;
use warnings;
use utf8;
use JSON qw(decode_json);
use Data::Dumper;
use Module::Runtime qw(use_module);
use Log::Any qw($log);
use Date::
bute};
$self->$attribute( $args{ $args_key } );
}
return $self;
}
# used by JSON for serialization
sub TO_JSON {
my $self = shift;
my $_data = {};
foreach my $_key (keys %{$self->a
desCloud::Object::FunctionElement;
require 5.6.0;
use strict;
use warnings;
use utf8;
use JSON qw(decode_json);
use Data::Dumper;
use Module::Runtime qw(use_module);
use Log::Any qw($log);
use Date::
gs{ $args_key } );
}
$self->{ type } = 'Function';
return $self;
}
# used by JSON for serialization
sub TO_JSON {
my $self = shift;
my $_data = {};
foreach my $_key (keys %{$self->a
lidesCloud::Object::ChartWallType;
require 5.6.0;
use strict;
use warnings;
use utf8;
use JSON qw(decode_json);
use Data::Dumper;
use Module::Runtime qw(use_module);
use Log::Any qw($log);
use Date::
bute};
$self->$attribute( $args{ $args_key } );
}
return $self;
}
# used by JSON for serialization
sub TO_JSON {
my $self = shift;
my $_data = {};
foreach my $_key (keys %{$self->a
sCloud::Object::FilesUploadResult;
require 5.6.0;
use strict;
use warnings;
use utf8;
use JSON qw(decode_json);
use Data::Dumper;
use Module::Runtime qw(use_module);
use Log::Any qw($log);
use Date::
bute};
$self->$attribute( $args{ $args_key } );
}
return $self;
}
# used by JSON for serialization
sub TO_JSON {
my $self = shift;
my $_data = {};
foreach my $_key (keys %{$self->a
seSlidesCloud::Object::VideoFrame;
require 5.6.0;
use strict;
use warnings;
use utf8;
use JSON qw(decode_json);
use Data::Dumper;
use Module::Runtime qw(use_module);
use Log::Any qw($log);
use Date::
{ $args_key } );
}
$self->{ type } = 'VideoFrame';
return $self;
}
# used by JSON for serialization
sub TO_JSON {
my $self = shift;
my $_data = {};
foreach my $_key (keys %{$self->a