import requests


def get_countries_names() -> list:
    """
    Function for getting list of all countries names procived by public
    COVID-19 api on site "https://api.covid19api.com"

    Returns
    -------
    List with all countries names.

    Example
    -------
    >>> countries_names = get_countries_names()
    """

    countries_names = []
    url = "https://api.covid19api.com/countries"

    payload = {}
    headers = {}

    response = requests.request("GET", url, headers=headers, data=payload)

    for element in response.json():
        countries_names.append(element['Slug'])

    return countries_names