Created
August 17, 2018 07:42
-
-
Save MKtalk/740250aa2e00af32714f2681ae2a9a21 to your computer and use it in GitHub Desktop.
간단한 설문 조사 챗봇과 구글 설문지 연동
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def set_pools(self, event, context, **kwargs): | |
q1 = kwargs.get('question1') # slots id 와 대응 | |
q2 = kwargs.get('question2') | |
form_url = 'https://docs.google.com/forms/d/e/1FAIpQLScsCKP5Arszf84igEzoL5Yrbr5qcZIND9a4NeJyNw_onUUavw/formResponse' | |
params = '?entry.1894278833={}&entry.281957015={}'.format(q1, q2) | |
url = form_url + params | |
requests.post(url) | |
msg = '설문이 등록 되었습니다.'.format(q1, q2) | |
self.send_message(msg) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment