
CiscoCertified DevNet Professional
Domain 2Objective 2
Implement Control Flow of Consumer Code for Unrecoverable REST API Errors 350-901 Practice Questions (Page 5)
Part of the 2.0 Using APIs domain, which accounts for 20% of the 350-901 exam. Cisco does not publish an official question count, but from its 120-minute exam (~50–80 total, ~10–16 in this domain), expect 2–3 from this objective — we provide 25 practice questions to prepare you well beyond it. (estimate)
25questions here
5free pages
4concepts
20%of the exam
Questions 21–25
- 21
A script polls the Cisco DNA Center API for a network device's configuration. During a maintenance window, the API returns HTTP 503 Service Unavailable with a Retry-After header of 120 seconds. After the maintenance window ends, the API returns HTTP 400 Bad Request because the device ID in the URL is malformed. How should the script classify these two responses?
Select an answer first - 22
A Python script uses the requests library to call the Cisco Intersight API. The script receives an HTTP 400 Bad Request with a JSON error body stating 'Invalid parameter: deviceId'. The script is part of a larger batch job that processes multiple devices. What is the best control flow for this specific request?
Select an answer first - 23
A Python script processes a list of 100 devices from a CSV file, calling the Cisco DNA Center API to update each device's location. The script uses a single try/except block that catches all HTTPError exceptions and retries each request up to 3 times. During a run, 5 devices return HTTP 404 (device not found) and 3 devices return HTTP 429 (rate limit). The script currently retries both error types, causing the 404s to be retried 3 times each before failing. The team wants to minimize API calls and complete the batch faster. What is the best control flow redesign?
Select an answer first - 24
A script calls the Cisco DNA Center API to retrieve a list of sites. The API returns HTTP 500 Internal Server Error with a JSON body indicating a database connection failure. The script's current logic retries the request three times. What is the most appropriate classification of this error?
Select an answer first - 25
A Python script uses the requests library to call the Cisco Intersight API. The script receives an HTTP 405 Method Not Allowed when trying to DELETE a resource. The API documentation states that the DELETE method is not supported for this resource type. What is the best control flow?
Select an answer first
Finished these 5 questions?
Review the revealed explanations, or continue through the curriculum.
No more pagesBack to 350-901
Free Basic Practice is a study aid with revealable answers — not a scored exam. Examers.io is independent and not affiliated with or endorsed by Cisco. “350-901” is a trademark of its owner, used for identification only.