FlashGenius Logo FlashGenius
CCNA 200-301 Exam Prep · Topic 5 of 5

Automation & Programmability

REST APIs · JSON/YANG · Python · Ansible · SD-WAN · DNA Center · Configuration Management

Study with Practice Tests →

Automation & Programmability — Overview

The final CCNA domain covers modern network automation. Though weighted at ~10% of the exam, this area is rapidly growing in real-world importance as networks shift toward programmable, controller-driven architectures.

Domain Weight: ~10% · ~12 Questions

CCNA 200-301 Exam Domains

#DomainWeight
1Network Fundamentals20%
2Network Access20%
3IP Connectivity25%
4IP Services10%
5Security Fundamentals15%
6Automation & Programmability10%
Real-world note: While automation accounts for only ~10% of exam questions, network programmability is one of the fastest-growing skill areas in the industry. Understanding APIs, Ansible, and DNA Center is essential for modern network engineers — this knowledge pays dividends far beyond the exam.

Core Concept Summary

🌐 REST APIs

Representational State Transfer over HTTP(S). Uses HTTP methods (GET, POST, PUT, PATCH, DELETE) to interact with network devices and controllers. Returns data in JSON or XML. Stateless: each request is self-contained.

📄 JSON / YANG

JSON is the dominant data format for REST APIs — human-readable key-value pairs. YANG (RFC 6020) is a data modeling language that defines the schema for network config data. Used with NETCONF (SSH+XML) and RESTCONF (HTTP+JSON/XML).

🐍 Python (netmiko / NAPALM)

Python is the go-to language for network automation scripts. netmiko provides SSH connectivity to Cisco/Juniper/Arista devices. NAPALM abstracts vendor differences. The requests library handles REST API calls.

🤖 Ansible

Agentless configuration management tool. Uses YAML playbooks pushed over SSH or API. Idempotent: safe to run multiple times. Key advantage over Puppet/Chef for networking: no agent software needed on devices.

🗺️ SD-WAN

Software-Defined WAN separates the control plane from the data plane. Cisco SD-WAN (formerly Viptela) uses vManage (GUI), vSmart (control), vBond (orchestration), and vEdge/cEdge (data plane). Enables application-aware routing.

🏗️ DNA Center

Cisco's Intent-Based Networking (IBN) platform. Defines WHAT the network should do; DNA Center figures out HOW. Provides automation, AI/ML assurance, and SD-Access fabric management. Uses northbound REST APIs for integrations.

REST APIs & Data Formats

Understanding programmability concepts, REST API fundamentals, and modern data formats is essential for the automation domain.

Network Programmability Concepts

Traditional Management Limitations

  • CLI per device via SSH/Telnet
  • Error-prone manual configuration
  • Doesn't scale across hundreds of devices
  • No version control, no audit trail
  • Inconsistent configs across devices

Programmability Benefits

  • Automation: scripts replace repetitive CLI tasks
  • Consistency: identical config across all devices
  • Speed: mass changes in minutes vs days
  • Version control: Git tracks every config change
  • Reduced human error and faster rollback

Controller-Based Networking

  • Centralized controller manages many devices via APIs
  • Examples: DNA Center (campus), WLC (wireless), vManage (WAN)
  • Northbound API: controller ↔ apps/scripts
  • Southbound API: controller ↔ network devices
  • Separates management plane from control/data plane

REST API Fundamentals

What is REST?

REST (Representational State Transfer) is an architectural style for APIs that uses HTTP(S). It is stateless — each request contains all information needed; no session state is stored on the server. Data is typically exchanged in JSON or XML format.

HTTP Methods (CRUD Operations)

HTTP MethodCRUD OperationDescriptionExample Use
GETReadRetrieve resource data, no modificationGet interface status
POSTCreateCreate a new resourceAdd a new VLAN
PUTUpdate/ReplaceReplace entire resourceReplace full interface config
PATCHPartial UpdateUpdate specific fields onlyChange IP address only
DELETEDeleteRemove a resourceDelete a static route

HTTP Status Codes

CodeMeaningCategory
200OK — Request succeeded2xx Success
201Created — Resource created successfully2xx Success
204No Content — Success, no body returned2xx Success
400Bad Request — Malformed request syntax4xx Client Error
401Unauthorized — Authentication required4xx Client Error
403Forbidden — Authenticated but not authorized4xx Client Error
404Not Found — Resource doesn't exist4xx Client Error
500Internal Server Error — Server-side failure5xx Server Error

Authentication & Headers

Authentication Methods

  • Basic Auth: base64(username:password) in Authorization header — requires HTTPS
  • Token/Bearer: OAuth 2.0 or JWT token after initial login. Authorization: Bearer TOKEN
  • API Keys: Static string passed in header or query parameter

Common Headers

  • Content-Type: application/json — body format you're sending
  • Accept: application/json — format you want to receive
  • Authorization: Bearer TOKEN — auth credential
  • Stateless: every request must include all needed auth/context info

Data Formats

JSON (JavaScript Object Notation)

Key-value pairs, arrays, and nested objects. Human-readable. Most common format in REST APIs. Default for DNA Center and most modern network APIs.

{"hostname": "R1", "interfaces": ["Gi0/0", "Gi0/1"]}

XML (eXtensible Markup Language)

Tag-based, more verbose than JSON. Used in NETCONF. Supports attributes and namespaces. More complex to read but widely supported.

<hostname>R1</hostname>

YANG (Yet Another Next Generation)

Data modeling language (RFC 6020). Defines the structure, data types, and constraints for network config data — like a schema or blueprint. Works with NETCONF and RESTCONF. YANG = schema; NETCONF/RESTCONF = transport carrying actual data.

NETCONF vs RESTCONF

FeatureREST APINETCONFRESTCONF
TransportHTTP/HTTPSSSH (port 830)HTTP/HTTPS
Data FormatJSON / XMLXML onlyJSON or XML
Data ModelVariesYANGYANG
OperationsGET/POST/PUT/DELETEget-config, edit-config, commitGET/POST/PUT/DELETE
TransactionsNoYes (candidate config + commit)Partial (no commit)
Cisco SupportDNA Center NBIIOS-XE, IOS-XR, NX-OSIOS-XE 16.6+
Key distinction: NETCONF uses edit-config and get-config operations over SSH. It supports a candidate configuration that is only applied to running config after a commit operation — making it transactional and safer than direct running-config changes.

Network Automation Tools

Python libraries and tools like Ansible provide the building blocks for scalable, consistent network automation across multivendor environments.

Python for Networking

🐍 netmiko

  • SSH library purpose-built for network devices
  • Supports Cisco IOS, NX-OS, IOS-XR, Juniper, Arista, and more
  • ConnectHandler() — establish SSH connection
  • send_command() — run show commands, capture output
  • send_config_set() — push config lines
  • Handles SSH negotiation quirks of network devices automatically

🔧 NAPALM

Network Automation and Programmability Abstraction Layer with Multivendor support

  • Abstracts vendor differences behind a common API
  • get_facts() — hostname, OS version, uptime
  • get_interfaces() — interface details
  • load_merge_candidate() — stage config changes
  • Supports Cisco IOS, NX-OS, IOS-XR, Juniper JunOS, Arista EOS

📡 Requests Library

  • Python's standard HTTP library for REST API calls
  • requests.get(url, headers=h, auth=(u,p))
  • requests.post(url, json=data, headers=h)
  • response.json() — parse JSON response
  • response.status_code — check HTTP status
  • Used to interact with DNA Center, Meraki, and other REST APIs

🔑 Paramiko

  • Low-level SSH library for Python
  • netmiko is built on top of Paramiko
  • More complex to use for network devices directly
  • Provides fine-grained control over SSH sessions
  • Useful when netmiko doesn't support a specific device

Ansible

Key exam facts: Ansible is agentless (uses SSH/API, no software on managed devices) and idempotent (running a playbook multiple times produces the same result — only changes what's needed). It uses a push model (pushes config from control node to devices).

Ansible Components

  • Inventory: list of managed hosts/devices (INI or YAML format)
  • Playbook: YAML file containing ordered tasks to execute
  • Module: unit of work (e.g., ios_config, ios_command)
  • Role: reusable, self-contained playbook structure
  • Control Node: the machine running Ansible (not the device)

Key Networking Modules

  • ios_command — run show commands on IOS devices
  • ios_config — push config lines to IOS devices
  • nxos_config — config management for NX-OS
  • cli_command — vendor-agnostic CLI commands
  • cli_config — vendor-agnostic config push

Playbook Structure (YAML)

  • hosts: — target devices from inventory
  • gather_facts: — collect device info (often no for network)
  • tasks: — list of steps to execute
  • - name: — human-readable task description
  • ios_config: / lines: — config to apply
  • Run with: ansible-playbook playbook.yml -i inventory

Ansible vs Puppet vs Chef

FeatureAnsiblePuppetChef
Agent RequiredNo (agentless)Yes (Puppet agent)Yes (Chef agent)
ModelPush (control node → devices)Pull (agent pulls from master)Pull (agent pulls from server)
LanguageYAMLRuby DSL (Puppet DSL)Ruby (recipes/cookbooks)
Master RequiredNo (control node only)Yes (Puppet Master)Yes (Chef Server)
Network Device SupportExcellent (purpose-built modules)Limited (designed for servers)Limited (designed for servers)
ComplexityLow — easy to startMedium-HighMedium-High
CCNA Key FactAgentless + YAML + PushAgent + Ruby + PullAgent + Ruby + Pull

Configuration Management Benefits

Version Control (Git)

Every config change is tracked, reviewable, and reversible. Full audit trail of who changed what and when. Rollback to any previous state instantly.

Consistency & Scale

Identical config deployed to 500 switches in minutes instead of days. Eliminates typos and variance from manual CLI input across devices.

Infrastructure as Code (IaC)

Network configs treated like application code — tested, reviewed, stored in Git repos, and deployed through CI/CD pipelines. Enables automated compliance checking.

SD-WAN & DNA Center

Software-Defined WAN and Cisco's DNA Center represent the practical application of SDN principles to enterprise WAN and campus networks.

SD-WAN (Software-Defined WAN)

Core concept: SD-WAN separates the control plane from the data plane (SDN applied to WAN). Cisco SD-WAN was formerly known as Viptela after Cisco's acquisition. It enables centralized policy management across MPLS, Internet, 4G/LTE, and other transports.

SD-WAN Components

vManage — Management Plane

  • Web GUI and REST API interface for administrators
  • Centralized configuration, monitoring, and reporting
  • Where network engineers define policies and templates
  • Think: the dashboard / command center

vSmart — Control Plane

  • The "brain" — distributes routing and policy info
  • Uses OMP (Overlay Management Protocol) to communicate with vEdge routers
  • Acts like a route reflector for the SD-WAN overlay
  • Distributes: routes, policies, crypto keys, service chains
  • Think: the controller / traffic director

vBond — Orchestration

  • First point of contact for new devices (ZTP)
  • Authenticates and onboards vEdge routers
  • Helps devices discover vManage and vSmart
  • Requires a public IP address
  • Think: the bouncer / authenticator

vEdge / cEdge — Data Plane

  • Physical or virtual routers at branch/hub sites
  • Actually forwards user traffic (data plane)
  • vEdge = Viptela hardware/software; cEdge = Cisco IOS-XE SD-WAN
  • Receives policies from vSmart via OMP
  • Think: the edge / the actual router

SD-WAN Key Features

OMP — Overlay Management Protocol

SD-WAN's control plane protocol. Runs between vSmart and vEdge/cEdge over DTLS/TLS tunnels. Distributes routes, policies, and crypto keys. Similar in function to BGP within the SD-WAN fabric.

Application-Aware Routing

Routes traffic based on application type and real-time path quality metrics (loss, latency, jitter). Business-critical apps (VoIP, video) can be routed over best-performing path automatically.

ZTP (Zero-Touch Provisioning)

New vEdge devices connect to vBond automatically on boot. No manual configuration needed at branch sites. Dramatically simplifies large-scale deployments.

Transport Independence

Works across MPLS, internet broadband, 4G/LTE, satellite. SD-WAN abstracts transport type — policies apply uniformly regardless of underlying WAN technology.

DNA Center (Cisco Digital Network Architecture)

What is DNA Center?

Cisco's network management and automation platform for campus and branch networks. Available as SaaS or on-premises appliance. Provides Intent-Based Networking (IBN), network automation, AI/ML assurance, and SD-Access fabric management.

Intent-Based Networking (IBN)

Administrator defines INTENT (business policy: "Finance VLAN should never reach HR VLAN"). DNA Center translates intent into actual device configurations automatically across the entire network.

DNA Center Assurance

AI/ML analytics engine that monitors network health in real time. Predicts issues before users are impacted. Provides guided remediation and root cause analysis. Tracks KPIs for applications, clients, and infrastructure.

SD-Access

Campus fabric architecture using VXLAN + LISP. Replaces traditional VLANs with scalable Virtual Networks (VNs) and policy-based segmentation. Users get access based on identity, not port location.

DNA Center APIs

  • NB API (Northbound): REST API for apps and scripts to consume DNA Center data and trigger automation
  • SB API (Southbound): NETCONF, RESTCONF, SSH used to configure actual network devices

SDN Three-Layer Architecture

LayerComponentsAPIs UsedFunction
Application LayerBusiness apps, automation scripts, REST clientsNorthbound API (NBI)Define what the network should do
Control LayerSDN Controller (DNA Center, OpenDaylight)NBI (up) + SBI (down)Translate intent into device instructions
Infrastructure LayerPhysical/virtual switches and routersSouthbound API (SBI)Forward data plane traffic

Northbound Interface (NBI)

Between the SDN controller and applications/scripts. Uses REST APIs with JSON. Allows automation scripts, monitoring apps, and business applications to consume network data and trigger changes.

Southbound Interface (SBI)

Between the SDN controller and network devices. Protocols: NETCONF, RESTCONF, OpenFlow, SNMP, SSH. The controller uses SBI to push configurations and collect telemetry from physical/virtual devices.

Traditional vs DNA Center: Traditional management = device-by-device CLI with no network-wide visibility or intent. DNA Center = define intent once, platform configures all devices consistently and monitors whether intent is being fulfilled across the entire network continuously.

Practice Quiz — Automation & Programmability

10 exam-style questions covering REST APIs, data formats, Ansible, SD-WAN, and DNA Center. Select your answers and check your score.

1. Which HTTP method is used to retrieve data from a REST API without modifying it?
2. A REST API returns HTTP status code 404. What does this indicate?
3. Which data format uses key-value pairs and is most commonly used in REST APIs?
4. Which Ansible characteristic means it requires no software installed on managed network devices?
5. In Cisco SD-WAN, which component is responsible for distributing routing and policy information to vEdge routers?
6. What does "idempotent" mean in the context of Ansible?
7. Which protocol does NETCONF use for transport?
8. In the SDN architecture, what is the northbound API used for?
9. Which Cisco platform provides Intent-Based Networking and SD-Access capabilities?
10. Which Python library is specifically designed for SSH connections to network devices like Cisco IOS?

Memory Hooks

Six visual memory anchors to lock in the key automation and programmability concepts for the CCNA exam.

🌐
REST HTTP Methods
"CRUD = GET · POST · PUT · DELETE"
Create=POST, Read=GET, Update=PUT/PATCH, Delete=DELETE. Status codes: 2xx=success, 4xx=client error, 5xx=server error. 200=OK, 201=Created, 404=Not Found, 401=Unauthorized, 500=Server Error.
📄
JSON vs XML vs YANG
"JSON=Readable · XML=Structured · YANG=Schema"
JSON uses braces/brackets, easy to read, default for REST. XML uses tags, more verbose, used in NETCONF. YANG is the MODEL (schema) — it defines what data looks like. NETCONF/RESTCONF carry the actual data.
🤖
Ansible in One Line
"Agentless · Idempotent · YAML · Push"
No agents needed (SSH/API). Idempotent = safe to re-run. Written in YAML (playbooks). Pushes config from control node. Compare: Puppet/Chef = agent-based, pull model, Ruby — more complex for network use.
🗺️
SD-WAN Components
"Manage · Smart · Bond · Edge"
vManage=GUI/management. vSmart=brain/control plane (OMP). vBond=bouncer/orchestration (authenticates devices). vEdge/cEdge=data plane (actual routing). Think: Manage the Smart Bond at the Edge.
🏗️
SDN Three Layers
"Apps → Controller → Devices"
Application layer uses NBI (northbound, REST) to talk to controller. Controller uses SBI (southbound: NETCONF, RESTCONF, OpenFlow) to program devices. DNA Center is Cisco's SDN controller for campus/enterprise.
🐍
Python Networking Libraries
"netmiko=SSH · NAPALM=Multi-vendor · requests=HTTP"
netmiko: SSH to Cisco/Juniper/Arista, send_command(), send_config_set(). NAPALM: abstracts vendor differences, get_facts(). requests: HTTP calls to REST APIs, requests.get(url, headers=h).

Flashcards & Study Advisor

Click any flashcard to reveal the answer. Use the Study Advisor below to explore specific topic areas.

Click a card to flip it · Click again to flip back

REST API Authentication
Three main authentication types for REST APIs
Basic Auth: base64(username:password) in Authorization header — insecure without HTTPS.

Token/Bearer: OAuth 2.0 or JWT token after initial login.

API Key: static string in header or query param. Always use HTTPS to protect credentials in transit.
YANG Data Models
What YANG is and how it relates to NETCONF/RESTCONF
YANG (RFC 6020): defines structure, data types, and constraints for network config data — like a schema. Used with NETCONF (SSH+XML) and RESTCONF (HTTP+JSON/XML). Cisco IOS-XE, IOS-XR, NX-OS all support YANG models.
Ansible Playbook Structure
Key YAML fields in an Ansible network playbook
YAML format. Top level: hosts: (which devices), gather_facts:, tasks: (list of steps). Each task: - name: (description), module name (e.g., ios_config:), module args (lines:, parents:). Run with: ansible-playbook playbook.yml -i inventory.
SD-WAN OMP
Overlay Management Protocol — what it does and who uses it
Overlay Management Protocol: control plane protocol between vSmart controller and vEdge/cEdge routers. Distributes: routes, policies, crypto keys, service chains. Similar to BGP in function. Runs over DTLS/TLS tunnels. vSmart acts as route reflector for OMP.
DNA Center Intent-Based Networking
What IBN means and how DNA Center assurance works
IBN: administrator defines INTENT (business policy: "Finance VLAN should not reach HR VLAN") — DNA Center translates intent into device configs automatically. Assurance: AI/ML monitors network health, predicts issues. Uses SD-Access fabric underneath (VXLAN+LISP).
NETCONF Operations
Core NETCONF RPC operations and transport details
<get-config>: retrieve config from candidate/running/startup.
<edit-config>: modify config (merge, replace, create, delete).
<commit>: apply candidate config to running.
<lock>/<unlock>: prevent concurrent changes.
Transport: SSH port 830. Data: XML.
Configuration Management Benefits
Why IaC and version control matter for networks
Version control (Git): every config change tracked, reviewable, reversible.
Consistency: identical config deployed to 500 switches in minutes vs days.
Compliance: automatically verify configs match policy.
IaC: treat network config like application code — test, review, CI/CD pipeline.
Puppet vs Ansible vs Chef
Key differences between the three config management tools
Puppet: agent-based, pull model, Ruby DSL, Puppet master + agent.
Chef: agent-based, pull model, Ruby, cookbooks + recipes.
Ansible: agentless, push model, YAML, no master needed.
For CCNA: Ansible=agentless+YAML+push, Puppet/Chef=agent+pull.

Study Advisor

Select a topic area to get focused study guidance.

REST APIs

    Ready to Ace the CCNA Automation Domain?

    Practice with full-length mock exams and adaptive flashcards on FlashGenius

    Start Free Practice →