OAuth2.0 and Cisco APIs - Working on a Use Case
Output of our Python Code

OAuth2.0 and Cisco APIs - Working on a Use Case

In the last few posts, we have gone through the basics of OAuth2.0 framework and how one can use tools like Postman to understand the interaction between applications and APIs that require OAuth2.0 based authentication/authorization. In today’s concluding part of this series, we will be writing some code in Python that would accomplish the use case we had outlined in the last post. If you haven’t gone through Part 1 and Part 2 of this series, then please do so first. Otherwise, a lot of stuff explained in this post will not make much sense. Secondly, it is assumed that you already have some basic understanding of Python data types likes Lists, Dictionaries etc, APIs, different payload formats like JSON and XML. If you want to jump straight to the Github repository and download the code then click on point# 8 below.

So, without much ado, let’s dive right into it!!

Use Case

At the end of the exercise, we should be looking at something like the following. This table lists the IOS-XE image recommended by Cisco for 4431 series router platform along with its release date.

No alt text provided for this image

The table of contents is listed below. You can click on the link to get to relevant sections on the blog.

  1. Use Case
  2. Declaring the Variables and loading them with values
  3. Get the Token
  4. Send a request to the API
  5. Output (IOS Display name and Image name)
  6. Prettifying the Output
  7. Prettified Output
  8. Github Repository

To view or add a comment, sign in

More articles by Simranjit Singh

Insights from the community

Others also viewed

Explore topics