nerdexam
Cisco

200-901 · Question #577

Refer to the exhibit. A developer created a Python script that is used by network engineers to retrieve information from Cisco DNA Center by using the Cisco DNA Center API. Which workflow does the Pyt

The correct answer is D. Retrieve a specific device from Cisco DNA Center by using a serial number.. The Python script uses a requests.get call to a Cisco DNA Center API endpoint that includes a device_id, indicating it retrieves information for a specific network device.

Understanding and Using APIs

Question

Refer to the exhibit. A developer created a Python script that is used by network engineers to retrieve information from Cisco DNA Center by using the Cisco DNA Center API. Which workflow does the Python script execute?

Exhibit

200-901 question #577 exhibit

Options

  • ARetrieve all the devices and serial numbers in Cisco DNA Center.
  • BProvision a new device in Cisco DNA Center.
  • CRetrieve all network information in Cisco DNA Center.
  • DRetrieve a specific device from Cisco DNA Center by using a serial number.

How the community answered

(27 responses)
  • A
    4% (1)
  • C
    4% (1)
  • D
    93% (25)

Why each option

The Python script uses a `requests.get` call to a Cisco DNA Center API endpoint that includes a `device_id`, indicating it retrieves information for a specific network device.

ARetrieve all the devices and serial numbers in Cisco DNA Center.

The script uses a `device_id` in the URL, indicating it targets a specific device, not all devices.

BProvision a new device in Cisco DNA Center.

Provisioning typically involves POST or PUT requests to create or modify resources, whereas the script uses a GET request which is for retrieval.

CRetrieve all network information in Cisco DNA Center.

The URL path includes a `device_id`, meaning the script retrieves information for a specific device, not all network information in general.

DRetrieve a specific device from Cisco DNA Center by using a serial number.Correct

The Python script constructs a URL with a specific `device_id` and then performs an HTTP GET request to `/dna/intent/api/v1/network-device/`. This API endpoint, combined with the GET method and `device_id`, is used to retrieve detailed information about a particular network device.

Concept tested: Cisco DNA Center API interaction (GET)

Source: https://developer.cisco.com/dnac/apis/#!network-device

Topics

#Cisco DNA Center API#Python scripting#API retrieval#Device management

Community Discussion

No community discussion yet for this question.

Full 200-901 Practice