@staticmethod
def get_intent_name(payload):
    """ Return the simple intent name. An intent has the form:

           {
               "input": "turn the lights green",
               "intent": {
                   "intentName": "user_BJW0GIoCx__Lights",
                   ...
               },
               "slots": [...]
           }

           and this function extracts the last part of the intent
           name ("Lights"), i.e. removing the user id.

        :param payload: the intent, in JSON format.
        :return: the simpe intent name.
        """
    if 'intent' in payload and 'intentName' in payload['intent']:
        return payload['intent']['intentName'].split('__')[-1]
    return None
