feat(netbox): Add NetBox API client for fabric intent retrieval
Implements FabricNetBoxClient using pynetbox to fetch: - Device and interface data - BGP sessions and peer groups (plugin) - L2VPN/EVPN VNI mappings - VRF and route target configuration - MLAG custom fields Relates to #5
This commit is contained in:
36
src/netbox/__init__.py
Normal file
36
src/netbox/__init__.py
Normal file
@@ -0,0 +1,36 @@
|
||||
"""
|
||||
NetBox Client Module for Fabric Orchestrator.
|
||||
|
||||
This module provides a NetBox API client for fetching fabric intent data
|
||||
using pynetbox.
|
||||
|
||||
Usage:
|
||||
from src.netbox import FabricNetBoxClient
|
||||
|
||||
client = FabricNetBoxClient(
|
||||
url="http://netbox.local",
|
||||
token="your-token"
|
||||
)
|
||||
|
||||
# Get all leaf devices
|
||||
leaves = client.get_leaf_devices()
|
||||
|
||||
# Get complete intent for a device
|
||||
intent = client.get_device_intent("leaf1")
|
||||
"""
|
||||
|
||||
from .client import (
|
||||
FabricNetBoxClient,
|
||||
NetBoxAPIError,
|
||||
NetBoxConnectionError,
|
||||
NetBoxError,
|
||||
NetBoxNotFoundError,
|
||||
)
|
||||
|
||||
__all__ = [
|
||||
"FabricNetBoxClient",
|
||||
"NetBoxError",
|
||||
"NetBoxConnectionError",
|
||||
"NetBoxNotFoundError",
|
||||
"NetBoxAPIError",
|
||||
]
|
||||
Reference in New Issue
Block a user