Programming and Application Security
APIs
Working with REST APIs, JSON and authentication.
- 10 notes
- 88 minutes of reading
- What an API is and how REST APIs workA plain introduction to APIs (Application Programming Interfaces) and the REST style: resources, URLs, methods, statelessness and JSON, with network and cloud examples. 8 min · Beginner
- HTTP methods, URLs, headers and status codes for APIsHow an API request is built: the parts of a URL, the HTTP methods GET, POST, PUT, PATCH and DELETE, the headers that matter, and how to read status codes. 9 min · Beginner
- JSON and XML for APIs: structure, parsing and pitfallsHow JSON and XML represent data, how they map to Python structures, how to parse and create them safely, and when each format appears in network and security work. 8 min · Beginner
- API authentication: API keys, basic auth, OAuth 2.0 and JWTsHow APIs identify callers using API keys, basic authentication, session tokens, OAuth 2.0 flows and JSON Web Tokens, with secure ways to store and use secrets in scripts. 10 min · Intermediate
- Testing APIs with Postman and curlA hands-on guide to exploring and testing REST APIs with curl on the command line and with Postman collections, environments and simple response tests. 8 min · Beginner
- Calling REST APIs from Python with requestsHow to call REST APIs from Python with the requests library: sessions, headers, JSON bodies, timeouts, error handling, retries with back-off and pagination, without hard-coded secrets. 10 min · Intermediate
- Webhooks and event-driven integrationsHow webhooks push events from one system to another, how they differ from polling, and how to build a receiver that verifies signatures, handles retries and stays secure. 9 min · Intermediate
- API security: the OWASP API Security Top 10 and defencesA defender’s guide to the OWASP API Security Top 10 (2023 edition): what each risk means in practice, how it is detected and the controls that prevent it. 10 min · Intermediate
- Network automation: why automate, the toolchain and model-driven APIsWhy manual configuration doesn’t scale, the benefits of automation, the automation stack, how tools talk to devices (SSH, NETCONF, RESTCONF, gNMI, REST), YANG, YAML and JSON, sources of truth and idempotency. 8 min · Intermediate
- Network planes and software-defined networking (SDN)The data, control and management planes inside every network device, how SDN separates and centralises control, controllers and their northbound and southbound APIs, underlay and overlay, and intent-based networking. 8 min · Intermediate