summaryrefslogtreecommitdiff
path: root/doc/api/system_hooks.md
blob: f6e11ed238e8f6dd6f9c9286e4677ff04a4b0e93 (plain)
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
All methods require admin authorization.

## List system hooks

Get list of system hooks

```
GET /hooks
```

Will return hooks with status `200 OK` on success, or `404 Not found` on fail.

## Add new system hook hook

```
POST /hooks
```

Parameters:

+ `url` (required) - The hook URL

Will return status `201 Created` on success, or `404 Not found` on fail.

## Test system hook

```
GET /hooks/:id
```

Parameters:

+ `id` (required) - The ID of hook

Will return hook with status `200 OK` on success, or `404 Not found` on fail.

## Delete system hook

```
DELETE /hooks/:id
```

Parameters:

+ `id` (required) - The ID of hook

Will return status `200 OK` on success, or `404 Not found` on fail.