--- id: pybgpkit version: "0.8.0" license: MIT license_treatment: permissive maintenance: active --- # pybgpkit — BGPKIT tools Python bindings License: permissive · Maintenance: active · Downloads: 103.3K/mo ## What it is and what it does PyBGPKit is a Python wrapper around BGPKIT, a suite of tools for working with Border Gateway Protocol (BGP) data. It provides bindings to parse BGP update messages from MRT files, query historical BGP data from public archives, and perform IP/ASN/ROAS lookups against BGP information sources. The package exposes several APIs: a full-featured Parser for detailed BGP element extraction with filtering, a faster RouteParser for route-level data, a Broker for searching and retrieving MRT files by time range and collector, and lookup classes for IP geolocation, ASN details, BGP communities, and RPKI ROAS validation. The package is designed for network operators, security researchers, and BGP analysts who need programmatic access to BGP routing data. It depends on pybgpkit-parser and requests. With support for Python 3.9 through 3.13 and an MIT license, it is suitable for both research and production use. Use it for: - Query historical BGP updates from a specific time window to analyze routing changes or detect anomalies. - Look up the ASN, country, and organization details for an IP address to enrich network traffic logs. - Validate RPKI ROAs for a given prefix to check BGPSEC compliance and detect route hijacks. - Parse BGP community values and their meanings to understand routing policies in a network. - Retrieve peer information and active collectors to build a map of BGP monitoring infrastructure. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Python bindings for BGPKIT tools that parse BGP data, query MRT archives, and look up IP/ASN/ROAS information from public BGP repositories. Yes. PyBGPKit is actively maintained, has low install friction, carries no known vulnerabilities, and offers a clean Python interface to production BGP data infrastructure. Install it if you work with BGP routing analysis, network security, or IP geolocation at scale. The MIT license and broad Python version support make it suitable for both research and commercial projects. ## Install pip install pybgpkit uv add pybgpkit poetry add pybgpkit ## Installing pybgpkit Before you install: Low friction: pure Python wheel with only two runtime dependencies (pybgpkit-parser and requests). Actively maintained with a recent release 43 days ago and continuous repository activity. License in practice: MIT license permits commercial and private use with minimal restrictions; you may use, modify, and distribute the package freely provided you include the license notice. Quickstart: pip install pybgpkit import pybgpkit # Parse BGP updates from a remote source parser = pybgpkit.Parser(url="https://spaces.bgpkit.org/parser/update-example") for elem in parser: print(elem) # Query MRT archive broker = pybgpkit.Broker() items = broker.query(ts_start="2024-01-01T00:00:00Z", ts_end="2024-01-01T01:00:00Z") Verify before relying: - Whether pybgpkit-parser is a compiled extension or pure Python (affects cross-platform reliability). - Rate limits or authentication requirements for the public BGPKIT Broker and lookup services. - Whether offline or local data sources are supported, or if all queries require network access. ## Package facts - License: MIT (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 103.3K/month (top 15,000 on PyPI) - Known vulnerabilities: none known ## Tags BGP data parsing python, MRT file query, IP ASN lookup, BGP route analysis, BGPKIT python bindings, BGP community lookup, ROAS validation python, bgp-routing, network-analysis, geolocation [View on SkillFed](https://skillfed.io/packages/pybgpkit) · [View on PyPI](https://pypi.org/project/pybgpkit/)