def METHOD_NAME():
    """Get a valid Bearer token for the Name Request Service."""
    token_url = current_app.config.get('NAMEX_AUTH_SVC_URL')
    client_id = current_app.config.get('NAMEX_SERVICE_CLIENT_USERNAME')
    client_secret = current_app.config.get('NAMEX_SERVICE_CLIENT_SECRET')
    data = 'grant_type=client_credentials'
    # get service account token
    res = requests.post(url=token_url,
                        data=data,
                        headers={'content-type': 'application/x-www-form-urlencoded'},
                        auth=(client_id, client_secret))
    try:
        return res.json().get('access_token')
    except Exception:  # noqa B902; pylint: disable=W0703;
        logger.error('Failed to get nr token')
        return None