INNER CODE UNIT · Python

fetch_basic_profile

sunithvs/devb.io · api/main.py:87

async def fetch_basic_profile(
    username: Annotated[str, Depends(verify_username)], 
    background_tasks: BackgroundTasks
):
    """Fetch basic GitHub user profile information"""
    username = username.strip().lower()
    return await get_cached_github_profile(username)

@app.get("/user/{username}/projects", response_model=Dict[str, Any])
async def fetch_projects_data(username: Annotated[str, Depends(verify_username)]):
    """Fetch GitHub user's projects and languages data"""
    try:
        username = username.strip().lower()
        cache_key = f"github_profile_projects:{username}"
        if Settings.CACHE_ENABLED:
            cached_response = await redis_client.get(cache_key)

            if cached_response and not Settings.DEBUG:

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…