Exemplo n.º 1
0
	def post(self):
		'Handle the post request.'
		msg = IncomingSMSMessage(self.request.get('phone'), 
							self.request.get('body'))
		msg.confirm()
		event = msg.save()
		if msg:
			template_values = {'event': event}
			path = os.path.join(os.path.dirname(__file__), 'templates/notification.html')
			self.response.out.write(template.render(path, template_values))
Exemplo n.º 2
0
    def post(self):
	'Handle the post request.'
        api_key = self.request.get('api_key')

        'hope its not a spammer'
        if len(api_key) > 0 and api_key == API_KEY:
	    msg = IncomingSMSMessage(self.request.get('phone'), 
	    self.request.get('body'))
	    msg.confirm()
	    event = msg.save()

        if msg:
            template_values = {'event': event}
	    path = os.path.join(os.path.dirname(__file__), 'templates/notification.html')
	    self.response.out.write(template.render(path, template_values))
Exemplo n.º 3
0
	def post(self):
		'Handle the post request.'
		msg = IncomingSMSMessage(self.request.get('phone'), 
							self.request.get('body'))
		msg.confirm()
		msg.save()