300-435 Question 217
Select 3You are tasked with automating the provisioning of network devices in a Cisco SD-WAN environment. To achieve this, you decide to utilize the vManage REST API. Which of the following steps are required to successfully authenticate and retrieve a session token from the vManage API?
- A
Send a POST request to the '/j_security_check' endpoint with valid username and password in the body.
- B
Send a GET request to the '/session/token' endpoint to retrieve the session token after successful authentication.
- C
Include the session token in the 'Authorization' header for all subsequent API requests.
- D
Send a PUT request to the '/api/system/status' endpoint to verify the connection to the vManage server.
- E
Use the session token retrieved from '/j_security_check' directly without any additional API calls.
Show answer and explanation
Correct answers: A, B, C
Explanation
To authenticate with the vManage API, you first need to send a POST request to the '/j_security_check' endpoint with your login credentials. After successful authentication, you must send a GET request to '/session/token' to retrieve the session token. This token is then included in the 'Authorization' header of all subsequent API requests. The '/api/system/status' endpoint and skipping the token retrieval step are not valid for this process.
- A. Correct.
Correct: The '/j_security_check' endpoint is used to post login credentials for authentication, making it a required step.
- B. Correct.
Correct: To retrieve a session token after authentication, a GET request to '/session/token' is necessary.
- C. Correct.
Correct: The session token must be included in the 'Authorization' header for subsequent requests to authenticate API calls.
- D. Incorrect.
Incorrect: The '/api/system/status' endpoint is used to check the system status, but it is not directly related to authentication or session token retrieval.
- E. Incorrect.
Incorrect: The '/j_security_check' endpoint does not directly return a session token. An additional call to '/session/token' is required to obtain the token.