-
Notifications
You must be signed in to change notification settings - Fork 0
/
sample.ps1
85 lines (83 loc) · 1.22 KB
/
sample.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
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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
$headers = @{}
$headers.Add("Content-Type","application/json")
$headers.Add("Accept","application/json")
$headers.Add("token","234a2526-11c6-4a72-b1b6-2eea0080604c")
$body = @"
[
{
"target": {
"x": 0,
"y": 150,
"z": 50
},
"type": "moveTo"
},
{
"target": {
"x": 0,
"y": 150,
"z": 0
},
"type": "moveTo"
},
{
"target": {
"x": 0,
"y": 150,
"z": 130
},
"type": "moveTo"
},
{
"target": {
"x": 0,
"y": 150,
"z": 50
},
"type": "moveTo"
},
{ "type": "grab"},
{
"target": {
"x": -150,
"y": 130,
"z": 50
},
"type": "moveTo"
},
{
"target": {
"x": 150,
"y": 130,
"z": 50
},
"type": "moveTo"
},
{ "type": "release" },
{
"target": {
"x": 0,
"y": 150,
"z": -50
},
"type": "moveTo"
},
{
"target": {
"x": 0,
"y": 100,
"z": -50
},
"type": "moveTo"
},
{
"target": {
"x": 0,
"y": 173,
"z": 0
},
"type": "moveTo"
}
]
"@
Invoke-WebRequest -method POST -headers $headers -Body $body -Uri 'http://192.168.1.253:8080/Avanade.meArm/1.0.0/arm/00006415121314/operate'