import requests


def api_get_courses(srcdb):
    """
    Return the API response for a search for all CU Boulder courses.
    """
    url = "https://classes.colorado.edu/api/?page=fose&route=search"
    data = {
        "other": {
            "srcdb": srcdb,
        },
        "criteria": []
    }
    resp = requests.post(url, json=data)
    resp.raise_for_status()
    return resp.json()