-
Notifications
You must be signed in to change notification settings - Fork 0
/
Dummy-TestHello.ps1
42 lines (40 loc) · 1.29 KB
/
Dummy-TestHello.ps1
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
param(
[string]$user_name
)
$answer = @"
{
'response_type': 'in_channel',
'attachments': [{
'text': "text",
'actions': [{
'name': 'Vote Yes',
'integration': {
'url': "http://192.168.0.1:12345/testbuttonanswer",
'context': {
'poll_id': 11,
'vote': 'Yes'
}
}
}, {
'name': 'Vote No',
'integration': {
'url': "http://192.168.0.1:12345/testbuttonanswer",
'context': {
'poll_id': 12,
'vote': 'No'
}
}
}, {
'name': 'End Poll',
'integration': {
'url': "http://192.168.0.1:12345/testbuttonanswer",
'context': {
'poll_id': 13,
'prompt': "End poll"
}
}
}]
}]
}
"@ | ConvertFrom-Json
return ($answer|Convertto-Json -Compress -Depth 100)