from typing import List
import requests


def get_all_intents(endpoint: str = 'http://localhost:8080/api/intent') -> List[str]:
    """
    Send a sentence to get a list of all possible intents.

    Parameters
    -----------
    - **endpoint**: (*optional*) the intent route to the endpoint, default to localhost route on port 8080.

    Return
    -----------
    The list of all intent class.
    """
    r = requests.get(endpoint + '?sentence=im a teapot')  # classify anything just to have the labels
    return sorted(list(r.json().keys()))