BlueCat Edge Python API - BlueCat Python Library - 22.4.1

BlueCat Python Library Guide

Locale
English
Product name
BlueCat Python Library
Version
22.4.1

The BlueCat Edge Python API is a set of wrapper classes abstracting the functionality of the BlueCat DNS Edge APIs. The initial offering delivers wrapped endpoints for key Edge use-cases, including Service Point status and better filtering of top queried external domains.

The standard usage pattern is to instantiate a client, authenticate, and perform one or multiple calls.

Example:
from bluecat_libraries.edge.api import EdgeClient

start = 0   # Start of time range. Defaults to last 24 hours.
count = 10  # Number of results to return, e.g., top 10.

with EdgeClient(<edge_ci_url>) as client:
    client.authenticate(<client_id>, <client_secret>)
    result = client.get_v1_api_customer_dnsquerystats_topdomains(start, count)

    for stat in result:
        print(stat['domain'], stat['hitCount'])