NetSec-Architect Practice Question: Centralized Management And Security Automation AT Scale
An automation engineer is writing a Python script to interact with the Palo Alto Networks XML API. The script needs to authenticate and retrieve the running configuration from Panorama. Which initial API request parameter is required to generate a valid API key?
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
✓
type=keygen with 'user' and 'password' parameters
To generate an API key via the XML API, a POST or GET request must be sent to the /api/ endpoint using the 'type=keygen' parameter along with valid administrative credentials ('user' and 'password').
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
type=op with the 'cmd=<show><system><state></state></system></show>' parameter
Why it's wrong here
This executes an operational command, which also requires an existing API key.
- ✓
type=keygen with 'user' and 'password' parameters
Why this is correct
The 'type=keygen' request exchanges administrator credentials for a time-limited or persistent API key.
- ✗
type=report with the 'async=yes' parameter
Why it's wrong here
This initiates an asynchronous report generation task, requiring prior authentication.
- ✗
type=config with the 'action=get' parameter
Why it's wrong here
This request retrieves configuration data, but it requires an already valid API key in the header or query string.
About these practice questions
One of 228 original NetSec-Architect 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 and reviewed by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
Last reviewed August 2026 · checked against the official Palo Alto Networks exam blueprint
This NetSec-Architect practice question is part of Courseiva's free Palo Alto Networks 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 NetSec-Architect exam.