This document outlines a Python lesson focused on the PIP package manager and APIs. It explains the purpose of PIP for installing libraries and provides an overview of APIs, including requests and responses. The lesson includes practical exercises to enhance understanding of accessing and using APIs.
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0 ratings0% found this document useful (0 votes)
4 views
Lesson 6 Python.pptx
This document outlines a Python lesson focused on the PIP package manager and APIs. It explains the purpose of PIP for installing libraries and provides an overview of APIs, including requests and responses. The lesson includes practical exercises to enhance understanding of accessing and using APIs.
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 7
PYTHON
LESSON 6
CFGDEGREE → FOUNDATION MODULE
AGENDA
01 PIP package manager
02 API PYTHON PIP DEFINITION # DEMO EXAMPLE
● pip: A package manager used to ● Together with your instructor
install libraries that other people install the requests library using have written pip
● pip is used via the terminal pip install requests
(command-line)
● Note that we need to install pip
itself first, which would allow us to install new packages in Python in the future API APPLICATION PROGRAMMING INTERFACE # RESPONSE EXAMPLE
● API: A way for different programs to interact.
For example they can send data to one Status Code Name Explanation another. Web APIs allow you to interact with 200 OK Request worked other programs over the internet. Could not find url 404 Not found requested ● API Request: When your program asks an API for some or to complete a specific action Request you made 400 Bad request is not understood
● API Response: The result of your request
from the API API APPLICATION PROGRAMMING INTERFACE
# EXAMPLE 1
# EXAMPLE 2 API PRACTICE PYTHON DATA TYPE # EXAMPLE
Complete a number of exercises with your
instructor to learn how to access and use APIs THANK YOU!