def METHOD_NAME(self, edpt):
    tags_map = {}
    if not edpt or type(edpt) is not dict:
        return tags_map
    attrs = edpt.get('attributes', {})
    if type(attrs) is not dict:
        return tags_map
    epg_name = attrs.get('name')
    dn = attrs.get('dn')
    if epg_name:
        tags_map["endpoint_group"] = "" + epg_name  # type enforcement
    if dn:
        tenant = re.search(TN_REGEX, dn)
        if tenant:
            tenant_name = tenant.group(1)
            tags_map["tenant"] = tenant_name
        app = re.search(APP_REGEX, dn)
        if app:
            app_name = app.group(1)
            tags_map["application"] = app_name
    return tags_map