A glimpse into Python network automation and APIs
This chapter excerpt from 'Mastering Python Networking' dives into the importance of APIs and network state when working with Python network automation and intent-based networking.
When people ask author Eric Chou how to get started with network automation, he advises them to start small and celebrate small victories.
In his book, Mastering Python Networking, from Packt Publishing, Chou dives into a range of Python network automation scenarios. His goal with the book was to help network engineers who might be in the same position he was when first tackling network automation. Specifically, he wanted to help people who thought they need to reach a certain stage before their skills or knowledge could be useful. Instead, he said incremental automation wins can help engineers move forward.
"Inevitably, you will hit roadblocks and challenging parts," Chou said. "You will have interruptions from family and friends, or you just don't feel like doing it. But, if you celebrate small victories, you're able to sustain that energy and keep going. That's the key: Just keep going, even if you just do a small bit per day."
Network engineers don't need to take on every aspect of network automation at once. Instead, they can find a couple areas they're interested in and work on implementing automation and scripts. For Chou, network automation finally clicked when he moved away from Perl -- which he said didn't align with how his mind processed problems -- and started working with Python. Over time, he found Python enabled him to grow organically and work in different areas.
Much of the innovation with automation comes from APIs that can build predictability and consistent outcomes into typically unpredictable networks. This predictability is more valuable than ever because teams face more complexity in their environments and must manage an increased number of devices, Chou said.
Below is an excerpt from Chapter 3, "APIs and Intent-Driven Networking," from Mastering Python Networking - Third Edition. In this chapter, Chou explains how APIs build structure into networks and provides various scripts that enable network engineers to implement automation.
Explore Mastering Python Networking
Click here to read Chapter 3, "APIs and Intent-Driven Networking."