Installation

When we speak about data and API access, we have to provide users with a Command Line Interface (CLI). That’s the best way to interact with APIs. Furthermore, we have created our own ONYPHE Processing Pipeline language called OPP.

It’s basically an expandable way of parsing JSON, like jq, but in a more easier way to play with. This OPP language is now also a standalone tool you can use on any JSON data.

Installation for Ubuntu/Debian/Kali systems

git clone https://github.com/onyphe/cli.git
cd cli
./install.sh

Installation for other systems

First, install your system cpanminus package. Then, install Perl dependencies:

git clone https://github.com/onyphe/cli.git
cd cli
./install.sh

sudo cpanm -n Mojolicious Config::INI::Tiny Tie::IxHash LWP::Protocol::https JSON::XS
sudo cpanm -n Text::ParseWords File::Slurp
sudo cpanm -n Regexp::IPv4 Text::CSV_XS Net::IPv4Addr Regexp::IPv6

perl Build.PL
./Build && ./Build test
sudo ./Build install

You’re done

To verify everything works, you can try the following queries:

onyphe -version
onyphe -help
onyphe -search 'protocol:http | uniq domain | addcount'

Complete configuration options

Automatic paging

Maybe you want to setup automatic paging with Search API? There is an option for that. This option is activated by default with install.sh script.

WARNING: 1 query eats 1 credit. With automatic paging, you may consume up to 1,000 credits with a single -search query.

echo 'api_endpoint = https://www.onyphe.io/api/v2' > ~/.onyphe.ini
echo 'api_key = YOUR_APIKEY' >> ~/.onyphe.ini
echo 'api_maxpage = 1000' >> ~/.onyphe.ini
onyphe -search 'protocol:http | uniq domain | addcount'

For Unrated API option

We provide Unrated API access with a paid option to all our Enterprise licenses. Contact sales[at]onyphe{dot}io to learn more.

echo 'api_unrated_endpoint = https://www.onyphe.io/unrated/api/v2' > ~/.onyphe.ini
echo 'api_unrated_email = YOUR_LOGIN_EMAIL' >> ~/.onyphe.ini
echo 'api_key = YOUR_APIKEY' >> ~/.onyphe.ini
echo 'api_maxpage = 1000' >> ~/.onyphe.ini