Skip to content

Feature/api coverage expansion#78

Open
CyberneticCodeComposer wants to merge 5 commits intoaruba:v2(pre-release)from
CyberneticCodeComposer:feature/api-coverage-expansion
Open

Feature/api coverage expansion#78
CyberneticCodeComposer wants to merge 5 commits intoaruba:v2(pre-release)from
CyberneticCodeComposer:feature/api-coverage-expansion

Conversation

@CyberneticCodeComposer
Copy link
Copy Markdown

Summary

Adds API coverage for monitoring, services, and scope management endpoints that were previously unimplemented in pycentral v2.

New modules:

  • new_monitoring/switches.py — MonitoringSwitches: list/details/ports/stacks/VLANs/CPU and memory utilization trends for switches
  • new_monitoring/alerts.py — Alerts: paginated alert list and detail retrieval via network-notifications/v1
  • new_monitoring/reporting.py — Reporting: full CRUD for saved reports and run history via network-monitoring/v1alpha1
  • new_monitoring/location.py — LocationServices: device locations, AP ranging scans, and asset tag data via network-monitoring/v1alpha2
  • new_monitoring/location_analytics.py — LocationAnalytics: location trends and per-site insights
  • new_monitoring/floorplan.py — FloorPlan: buildings, floors (create/update/scale/import), wall types, walls, zones, device placement, and heatmaps
  • services/ (new package) — Webhooks (full CRUD + HMAC key rotation), FirmwareService (firmware details list), AuditTrail (event list with time-range
    filtering and event details) via network-services/v1
  • scopes/device_group_api.py — DeviceGroupAPI: create, update, delete (single and bulk), and add/remove devices for
    network-config/v1alpha1/device-collections — completing the write-side of device group management that was previously read-only

Supporting changes:

  • utils/url_utils.py: added v1alpha2 to the supported versions list; added notifications (network-notifications) and services (network-services) URL
    categories
  • All new classes exported from their respective package init.py files
  • PLAN.md: documents remaining work (Phase 5 — typed config profile wrappers; Phase 6 — Central NAC package) for follow-on PRs
  • CLAUDE.md: adds repo guidance for Claude Code

Test plan

  • Verify from pycentral.new_monitoring import MonitoringSwitches, Alerts, Reporting, LocationServices, LocationAnalytics, FloorPlan resolves
    correctly
  • Verify from pycentral.services import Webhooks, FirmwareService, AuditTrail resolves correctly
  • Verify from pycentral.scopes import DeviceGroupAPI resolves correctly
  • Test MonitoringSwitches.get_all_switches() against a Central environment with switches
  • Test Alerts.get_all_alerts() and confirm pagination works
  • Test DeviceGroupAPI.create_device_group() / delete_device_group() round-trip
  • Test Webhooks.create_webhook() / delete_webhook() round-trip
  • Test FloorPlan.get_buildings() against an environment with floor plans configured

Eric Kenny and others added 5 commits March 27, 2026 09:52
Documents all unimplemented New Central and New Central Config API
endpoints across 6 phases, ordered by user impact. Includes
implementation notes, url_utils prerequisites, and docstring format
guidance for contributors.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Signed-off-by: Eric Kenny <eric_kenny@harvard.edu>
Prerequisite for implementing alerts, webhooks, firmware, audit, and
v1alpha2 monitoring endpoints (location, gateway details).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Signed-off-by: Eric Kenny <eric_kenny@harvard.edu>
New modules (all syntax-verified):

Monitoring:
- MonitoringSwitches: list/details/ports/stacks/VLANs/CPU/memory trends
- Alerts: paginated list and detail via network-notifications/v1
- Reporting: CRUD + run history via network-monitoring/v1alpha1
- LocationServices: device locations, ranging scans, asset tags (v1alpha2)
- LocationAnalytics: trends and per-site insights

Services (new package):
- Webhooks: full CRUD + HMAC key rotation via network-services/v1
- FirmwareService: firmware details list with pagination
- AuditTrail: event list with time-range filtering and event details

Scopes:
- DeviceGroupAPI: full CRUD + add/remove devices for device-collections

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Signed-off-by: Eric Kenny <eric_kenny@harvard.edu>
Implements buildings (get, update, delete), floors (create, get, delete,
update map, scale, bulk import + status), wall types (full CRUD), walls
(full CRUD per floor), zones (full CRUD per floor), device placement
(place, remove, change assignment, associated devices), and heatmaps
(coverage and channel occupancy) against network-monitoring/v1.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Signed-off-by: Eric Kenny <eric_kenny@harvard.edu>
- new_monitoring/__init__.py: export MonitoringSwitches, Alerts,
  Reporting, LocationServices, LocationAnalytics, FloorPlan
- services/__init__.py: export Webhooks, FirmwareService, AuditTrail
- scopes/__init__.py: export DeviceGroupAPI (+ add to __all__)
- PLAN.md: mark prerequisite and phases 1-4 as complete

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Signed-off-by: Eric Kenny <eric_kenny@harvard.edu>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant