mediumMultiple Choice
200-901 Practice Question: A network administrator uses the Cisco IOS XE CLI…
A network administrator uses the Cisco IOS XE CLI to configure a router. They want to use a Python script to automate this configuration via the guest shell. Which library should they use to interact with the CLI from within the guest shell?
⚠ Common exam trap
Cisco often tests the distinction between on-box automation (using the `cli` library) and off-box automation (using libraries like paramiko, ncclient, or requests), and the trap here is that candidates may assume any SSH library (paramiko) works for local Guest Shell interaction, not realizing the `cli` library is purpose-built for direct host communication.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
cli
The `cli` library is a built-in Python module available within the Cisco Guest Shell that allows scripts to execute IOS XE CLI commands directly on the host device. This library provides functions like `cli.execute()` and `cli.configure()` to send commands and retrieve output, making it the correct choice for automating configuration via the Guest Shell without external dependencies.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✓
cli
Why this is correct
The cli Python module is bundled inside the IOS XE guest shell, exposing functions such as cli.execute and cli.configurep to run CLI commands programmatically. It satisfies the constraint of interacting with the router's CLI from within the guest shell itself.
- ✗
requests
Why it's wrong here
Requests issues HTTP requests to REST endpoints; it cannot execute IOS XE CLI commands locally within the guest shell. CLI automation there uses the CLI library that runs commands in-process. Requests is correct when calling RESTCONF or other HTTP-based APIs rather than interacting with the command-line interface.
- ✗
ncclient
Why it's wrong here
ncclient speaks NETCONF, exchanging XML-encoded configuration over SSH against devices exposing a NETCONF subsystem. The guest shell requirement is driving the local IOS XE CLI, not model-driven NETCONF RPCs. ncclient is correct when automating configuration on a NETCONF-capable device using YANG data models.
- ✗
paramiko
Why it's wrong here
Paramiko implements SSH transport for reaching remote devices over the network; inside the guest shell the CLI is already local, so no SSH session is needed. The correct library invokes IOS XE CLI commands directly in-process. Paramiko is right when a script must SSH into a remote router from an external host.
Go deeper
Related to this question
About these practice questions
One of 975 original 200-901 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This 200-901 practice question is part of Courseiva's free Cisco certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the 200-901 exam.