nerdexam
Cisco

300-435 · Question #131

An engineer must receive the BGP routes between two of the Cisco SDWAN Devices. The Python Viptela SDK for Cisco SDWAN must be used. Drag and drop the code snippets from the bottom onto the boxes in…

This question tests the ability to construct a Python script using the Viptela SDK to authenticate against Cisco vManage and retrieve BGP routes between two SD-WAN devices by querying the correct REST API endpoint with the appropriate device parameters.

Controller-Based Network Automation

Question

An engineer must receive the BGP routes between two of the Cisco SDWAN Devices. The Python Viptela SDK for Cisco SDWAN must be used. Drag and drop the code snippets from the bottom onto the boxes in the code to create an API call to get BGP routes on Device1 (1.1.1.9) toward Device2 (1.1.1.11). Not all options are used.

Explanation

This question tests the ability to construct a Python script using the Viptela SDK to authenticate against Cisco vManage and retrieve BGP routes between two SD-WAN devices by querying the correct REST API endpoint with the appropriate device parameters.

Approach. The correct approach requires three stages: (1) importing the Viptela class from the viptela SDK and instantiating it with the vManage host, username, and password; (2) calling the login() method to establish an authenticated session; and (3) invoking the BGP routes method - typically mapped to the REST endpoint GET /dataservice/device/bgp/routes - passing 'deviceId=1.1.1.9' (Device1, the source) and a peer filter of '1.1.1.11' (Device2, the neighbor). The deviceId parameter identifies which WAN edge device to query, while the peer address narrows results to routes exchanged with the specific BGP neighbor, making both parameters essential for the correct API call.

Concept tested. Using the Python Viptela SDK to authenticate to Cisco vManage and programmatically retrieve BGP routing table entries from a specific SD-WAN edge device, filtered by BGP peer address, via the /dataservice/device/bgp/routes REST API endpoint.

Reference. Cisco SD-WAN (Viptela) REST API documentation - /dataservice/device/bgp/routes; Python viptela SDK on PyPI/GitHub (CiscoDevNet/python-viptela)

Topics

#Cisco SD-WAN#Python SDK#BGP#API Calls

Community Discussion

No community discussion yet for this question.

Full 300-435 Practice