def rest_format(text: str) -> str:
    """
    Converts a string to be compatible with iControl REST API.

    Arguments:
        text: String to be converted.

    """

    text = text.replace("/", "~")
    text = text.replace("%", "%25")
    return text