# tkdebnath/netbox-meraki architecture

> Architecture diagram of the GitHub repository tkdebnath/netbox-meraki, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-03). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/tkdebnath/netbox-meraki
- Repository: https://github.com/tkdebnath/netbox-meraki

## Overview

NetBox Meraki Sync imports Cisco Meraki Dashboard data into NetBox. The main workflow is to initiate a sync, retrieve organization and network data through the Meraki client, process infrastructure domains, and apply changes immediately, stage them for review, or preview them in dry-run mode. The plugin also provides configuration and filtering, scheduled/background execution, and sync history and progress through web and REST interfaces. The excerpts show the sync service invoking the client and persisting log/review data; several domain details are documented in the README but their implementations were not sampled.

Main entry points: [`netbox_meraki/sync_service.py`](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/sync_service.py) (Sync orchestration), [`netbox_meraki/views.py`](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/views.py) (Web interface), [`netbox_meraki/api/views.py`](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/api/views.py) (REST API), [`netbox_meraki/models.py`](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/models.py) (Sync history)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_entry["Entry points"]
  node_cli["Sync command<br/>[sync_meraki.py]"]
  node_web["Web interface<br/>[views.py]"]
  node_background["Background job<br/>[jobs.py]"]
  node_rest["REST API<br/>[views.py]"]
end

subgraph group_sync["Synchronization"]
  node_service["Sync orchestration<br/>[sync_service.py]"]
  node_client["Meraki API client<br/>[meraki_client.py]"]
  node_inventory["Networks and devices<br/>[sync_service.py]"]
  node_addressing["VLANs and prefixes<br/>[sync_service.py]"]
  node_wireless["Wireless LANs<br/>[sync_service.py]"]
  node_interfaces["Interfaces<br/>[sync_service.py]"]
end

subgraph group_control["Configuration and review"]
  node_settings["Sync settings<br/>[models.py]"]
  node_rules["Naming and filters<br/>[models.py]"]
  node_review["Review staging<br/>[models.py]"]
  node_store[("NetBox and plugin records<br/>[models.py]")]
end

subgraph group_observability["Status and interfaces"]
  node_history[("Sync history<br/>[models.py]")]
  node_forms["Configuration forms<br/>[forms.py]"]
  node_serializer["Log serializer<br/>[serializers.py]"]
end

node_operator(("NetBox operator"))
node_meraki["Meraki Dashboard"]

node_operator -->|"runs"| node_cli
node_operator -.->|"manages"| node_web
node_operator -.->|"requests"| node_rest
node_cli -->|"starts sync"| node_service
node_web -->|"starts sync"| node_service
node_web -->|"schedules"| node_background
node_background -->|"runs sync"| node_service
node_rest -->|"starts sync"| node_service
node_service -->|"requests data"| node_client
node_client -->|"fetches"| node_meraki
node_service -->|"syncs"| node_inventory
node_service -->|"syncs"| node_addressing
node_service -->|"syncs"| node_wireless
node_service -->|"syncs"| node_interfaces
node_service -->|"applies changes"| node_store
node_service -->|"stages changes"| node_review
node_service -->|"records progress"| node_history
node_settings -.->|"configures"| node_service
node_rules -.->|"filters and transforms"| node_service
node_forms -->|"edits"| node_settings
node_web -.->|"uses"| node_forms
node_rest -->|"reads logs"| node_history
node_rest -->|"serializes logs"| node_serializer
node_serializer -->|"serializes"| node_history

click node_cli "https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/management/commands/sync_meraki.py"
click node_web "https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/views.py"
click node_background "https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/jobs.py"
click node_rest "https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/api/views.py"
click node_service "https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/sync_service.py"
click node_client "https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/meraki_client.py"
click node_inventory "https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/sync_service.py"
click node_addressing "https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/sync_service.py"
click node_wireless "https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/sync_service.py"
click node_interfaces "https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/sync_service.py"
click node_settings "https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/models.py"
click node_rules "https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/models.py"
click node_review "https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/models.py"
click node_store "https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/models.py"
click node_history "https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/models.py"
click node_forms "https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/forms.py"
click node_serializer "https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/api/serializers.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_cli,node_web,node_background,node_rest toneBlue
class node_service,node_client,node_inventory,node_addressing,node_wireless,node_interfaces toneAmber
class node_settings,node_rules,node_review,node_store toneMint
class node_history,node_forms,node_serializer toneRose
class node_operator,node_meraki toneIndigo
```

## Components

### Entry points

- [Sync command](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/management/commands/sync_meraki.py): `netbox_meraki/management/commands/sync_meraki.py`
- [Web interface](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/views.py): `netbox_meraki/views.py`
- [Background job](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/jobs.py): `netbox_meraki/jobs.py`
- [REST API](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/api/views.py): `netbox_meraki/api/views.py`

### Synchronization

- [Sync orchestration](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/sync_service.py): `netbox_meraki/sync_service.py`
- [Meraki API client](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/meraki_client.py): `netbox_meraki/meraki_client.py`
- [Networks and devices](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/sync_service.py): `netbox_meraki/sync_service.py`
- [VLANs and prefixes](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/sync_service.py): `netbox_meraki/sync_service.py`
- [Wireless LANs](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/sync_service.py): `netbox_meraki/sync_service.py`
- [Interfaces](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/sync_service.py): `netbox_meraki/sync_service.py`

### Configuration and review

- [Sync settings](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/models.py): `netbox_meraki/models.py`
- [Naming and filters](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/models.py): `netbox_meraki/models.py`
- [Review staging](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/models.py): `netbox_meraki/models.py`
- [NetBox and plugin records](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/models.py): `netbox_meraki/models.py`

### Status and interfaces

- [Sync history](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/models.py): `netbox_meraki/models.py`
- [Configuration forms](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/forms.py): `netbox_meraki/forms.py`
- [Log serializer](https://github.com/tkdebnath/netbox-meraki/blob/master/netbox_meraki/api/serializers.py): `netbox_meraki/api/serializers.py`

### Other components

- **NetBox operator**
- **Meraki Dashboard**

## Connections

- NetBox operator → Sync command: runs (evidence: `netbox_meraki/management/commands/sync_meraki.py`)
- NetBox operator → Web interface: manages
- NetBox operator → REST API: requests
- Sync command → Sync orchestration: starts sync (evidence: `netbox_meraki/management/commands/sync_meraki.py`)
- Web interface → Sync orchestration: starts sync (evidence: `netbox_meraki/views.py`)
- Web interface → Background job: schedules (evidence: `netbox_meraki/views.py`)
- Background job → Sync orchestration: runs sync (evidence: `netbox_meraki/jobs.py`)
- REST API → Sync orchestration: starts sync (evidence: `netbox_meraki/api/views.py`)
- Sync orchestration → Meraki API client: requests data (evidence: `netbox_meraki/sync_service.py`)
- Meraki API client → Meraki Dashboard: fetches (evidence: `netbox_meraki/meraki_client.py`)
- Sync orchestration → Networks and devices: syncs (evidence: `README.md`)
- Sync orchestration → VLANs and prefixes: syncs (evidence: `README.md`)
- Sync orchestration → Wireless LANs: syncs (evidence: `README.md`)
- Sync orchestration → Interfaces: syncs (evidence: `README.md`)
- Sync orchestration → NetBox and plugin records: applies changes (evidence: `README.md`)
- Sync orchestration → Review staging: stages changes (evidence: `netbox_meraki/sync_service.py`)
- Sync orchestration → Sync history: records progress (evidence: `netbox_meraki/sync_service.py`)
- Sync settings → Sync orchestration: configures (evidence: `netbox_meraki/models.py`)
- Naming and filters → Sync orchestration: filters and transforms (evidence: `netbox_meraki/models.py`)
- Configuration forms → Sync settings: edits (evidence: `netbox_meraki/forms.py`)
- Web interface → Configuration forms: uses (evidence: `netbox_meraki/views.py`)
- REST API → Sync history: reads logs (evidence: `netbox_meraki/api/views.py`)
- REST API → Log serializer: serializes logs (evidence: `netbox_meraki/api/views.py`)
- Log serializer → Sync history: serializes (evidence: `netbox_meraki/api/serializers.py`)
