Skip to content

explicit-logic/python-module-13.3

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Module 13 - Programming with Python

This repository contains a demo project created as part of my DevOps studies in the TechWorld with Nana – DevOps Bootcamp.

Demo Project: API Request to GitHub

Technologies used: Python, PyCharm, Git

Project Description:

  • Write an application that talks to an API of an external application (GitHub) and lists all the public GitHub repositories for a specified user

Prerequisites

  1. Install Python

Download from python.org/downloads, then verify the installation:

python3 --version
  1. Install uv
curl -LsSf https://astral.sh/uv/install.sh | sh

# Verify
uv --version
  1. Install an IDE: PyCharm

  2. Create the virtual environment & install dependencies

uv sync

Overview

The application main.py uses the requests library to call the public GitHub REST API endpoint:

GET https://api.github.com/users/{username}/repos

It parses the JSON response and prints each repository's name and URL to the console.

Configuration

The target GitHub user is set via the username variable in main.py:3:

username = "explicit-logic"

Change this value to list repositories for any other GitHub account.

Run the Application

uv run main.py

Result