@@ -5,7 +5,7 @@ package Metabrik::Client::Onyphe;
55use strict;
66use warnings;
77
8- our $VERSION = ' 3.01 ' ;
8+ our $VERSION = ' 3.02 ' ;
99
1010use base qw( Metabrik) ;
1111
@@ -24,6 +24,7 @@ sub brik_properties {
2424 apikey => [ qw( key) ],
2525 apisize => [ qw( size) ],
2626 apitrackquery => [ qw( 0|1) ],
27+ apicalculated => [ qw( 0|1) ],
2728 apikeepalive => [ qw( 0|1) ],
2829 wait => [ qw( seconds) ],
2930 # API options:
@@ -146,6 +147,7 @@ sub search {
146147
147148 my $apiargs = [];
148149 push @$apiargs , { trackquery => ' true' } if $self -> apitrackquery;
150+ push @$apiargs , { calculated => ' true' } if $self -> apicalculated;
149151 push @$apiargs , { size => $self -> apisize } if $self -> apisize;
150152
151153 for my $page (1..$maxpage ) {
@@ -178,6 +180,7 @@ sub export {
178180 my $apiargs = [];
179181 # push @$apiargs, { keepalive => 'true' } if $self->apikeepalive; # Not supported
180182 # push @$apiargs, { trackquery => 'true' } if $self->apitrackquery; # Not supported
183+ # push @$apiargs, { calculated => 'true' } if $self->apicalculated; # Not supported
181184 push @$apiargs , { size => $self -> apisize } if $self -> apisize;
182185
183186 return $self -> ao-> export($oql , $apiargs , $self -> callback, $opl );
@@ -205,6 +208,7 @@ sub simple {
205208 my $apiargs = [];
206209 push @$apiargs , { keepalive => ' true' } if $self -> apikeepalive;
207210 push @$apiargs , { trackquery => ' true' } if $self -> apitrackquery;
211+ # push @$apiargs, { calculated => 'true' } if $self->apicalculated; # Not supported
208212 push @$apiargs , { size => $self -> apisize } if $self -> apisize;
209213 return $self -> best
210214 ? $self -> ao-> bulk_simple_best($oql , $category , $apiargs , $self -> callback, $opl )
@@ -238,6 +242,7 @@ sub summary {
238242 my $apiargs = [];
239243 push @$apiargs , { keepalive => ' true' } if $self -> apikeepalive;
240244 push @$apiargs , { trackquery => ' true' } if $self -> apitrackquery;
245+ # push @$apiargs, { calculated => 'true' } if $self->apicalculated; # Not supported
241246 push @$apiargs , { size => $self -> apisize } if $self -> apisize;
242247 return $self -> ao-> bulk_summary($oql , $type , $apiargs , $self -> callback, $opl );
243248 }
@@ -263,6 +268,7 @@ sub discovery {
263268 my $apiargs = [];
264269 push @$apiargs , { keepalive => ' true' } if $self -> apikeepalive;
265270 push @$apiargs , { trackquery => ' true' } if $self -> apitrackquery;
271+ # push @$apiargs, { calculated => 'true' } if $self->apicalculated; # Not supported
266272 push @$apiargs , { size => $self -> apisize } if $self -> apisize;
267273
268274 return $self -> ao-> bulk_discovery($oql , $category , $apiargs , $self -> callback, $opl );
@@ -536,6 +542,10 @@ Number of results to return per page. Default: 10.
536542
537543Activate track query mode: it will add a trackquery field to results. Default: 0.
538544
545+ =item B<apicalculated > (0|1)
546+
547+ Activate calculated fields mode: it will add a calculated field to results. Default: 0.
548+
539549=item B<apikeepalive > (0|1)
540550
541551Activate keep alive mode: it will print some dummy results on API calls when nothing has been rendered to support long running API calls. Default: 0.
0 commit comments