-
Notifications
You must be signed in to change notification settings - Fork 2
/
buttonUI.gs
69 lines (69 loc) · 1.86 KB
/
buttonUI.gs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
function searchPrefecture(reply_token) {
UrlFetchApp.fetch(LINE_REPLY_ENDPOINT, {
'headers': {
'Content-Type': 'application/json; charset=UTF-8',
'Authorization': 'Bearer ' + CHANNEL_ACCESS_TOKEN,
},
'method': 'post',
'payload': JSON.stringify({
'replyToken': reply_token,
'messages': [{
'type': 'text',
'text': 'どの県について調べるんー?',
'quickReply': {
"items": [
{
"type": "action",
"action": {
"type": "message",
"label": "大阪府",
"text": "大阪府"
}
},
{
"type": "action",
"action": {
"type": "message",
"label": "京都府",
"text": "京都府"
}
},
{
"type": "action",
"action": {
"type": "message",
"label": "滋賀県",
"text": "滋賀県"
}
},
{
"type": "action",
"action": {
"type": "message",
"label": "兵庫県",
"text": "兵庫県"
}
},
{
"type": "action",
"action": {
"type": "message",
"label": "奈良県",
"text": "奈良県"
}
},
{
"type": "action",
"action": {
"type": "message",
"label": "和歌山県",
"text": "和歌山県"
}
}
]
}
}],
}),
});
return ContentService.createTextOutput(JSON.stringify({ 'content': 'post ok' })).setMimeType(ContentService.MimeType.JSON);
}