<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def shortlink_scanned(self, data):
 """Called when a shortlink_scanned event is received """

        # Inform log that we received an event
        self.logger.info("Received shortlink_scanned event")

        data = json.loads(data)
        customer_token = str(data['object']['id'])
        response = self.mapiclient.create_payment_request(
            customer=customer_token,
            currency="NOK",
            amount="20.00",
            allow_credit=True,
            pos_id=self._pos_id,
            pos_tid=str(uuid.uuid4()),
            action='auth',
            expires_in=90,
            callback_uri="pusher:m-winterwarming-pos_callback_chan",
            text='Have some hot chocolate!')
        self._tid = response['id']
        print(str(self._tid))