def METHOD_NAME(self, headers=None, username=None):
    if headers and 'HTTP_AUTHORIZATION' in headers:
        return {}
    username = username or self.username
    api_key = self.api_key.key
    if username != self.username:
        web_user = WebUser.get_by_username(username)
        api_key, _ = HQApiKey.objects.get_or_create(user=WebUser.get_django_user(web_user))
        api_key = api_key.key
    return {
        'HTTP_AUTHORIZATION': f'apikey {username}:{api_key}'
    }