def METHOD_NAME(self, domain, record_name):
    """
    Get the name attribute appropriate for hetzner api. This means it's the name
    without domain name if record name ends with managed domain name else a fqdn
    :param domain: Name of domain for which dns zone should be searched
    :param record_name: The record name to convert
    :rtype: str
    :return: The record name in an appropriate format for hetzner api
    """
    if record_name.rstrip(".").endswith(domain):
        record_name = self._relative_name(record_name)
    return record_name