You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/openapi3.yaml
+177-1Lines changed: 177 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -37,6 +37,9 @@ tags:
37
37
- name: Configuration
38
38
description: |
39
39
This resource allows you to configure Predator programmatically.
40
+
- name: Webhooks
41
+
description: |
42
+
This resource allows you to configure webhooks.
40
43
x-tagGroups:
41
44
- name: Reference
42
45
tags:
@@ -46,6 +49,7 @@ x-tagGroups:
46
49
- Jobs
47
50
- Reports
48
51
- Configuration
52
+
- Webhooks
49
53
50
54
paths:
51
55
#DSL Definitions
@@ -1383,6 +1387,142 @@ paths:
1383
1387
application/json:
1384
1388
schema:
1385
1389
$ref: '#/components/schemas/error_response'
1390
+
# Webhooks
1391
+
/v1/webhooks:
1392
+
get:
1393
+
operationId: retrieve-webhooks
1394
+
tags:
1395
+
- Webhooks
1396
+
summary: Retrieve webhooks
1397
+
description: Retrieve all webhooks.
1398
+
responses:
1399
+
'200':
1400
+
description: Success
1401
+
content:
1402
+
application/json:
1403
+
schema:
1404
+
type: array
1405
+
items:
1406
+
$ref: '#/components/schemas/webhook'
1407
+
'400':
1408
+
description: Bad request
1409
+
content:
1410
+
application/json:
1411
+
schema:
1412
+
$ref: '#/components/schemas/error_response'
1413
+
'404':
1414
+
description: Not found
1415
+
content:
1416
+
application/json:
1417
+
schema:
1418
+
$ref: '#/components/schemas/error_response'
1419
+
'500':
1420
+
description: Internal server error
1421
+
content:
1422
+
application/json:
1423
+
schema:
1424
+
$ref: '#/components/schemas/error_response'
1425
+
post:
1426
+
operationId: create-a-webhook
1427
+
tags:
1428
+
- Webhooks
1429
+
summary: Create a Webhook
1430
+
description: Create a new Webhook.
1431
+
responses:
1432
+
'201':
1433
+
description: Success
1434
+
content:
1435
+
application/json:
1436
+
schema:
1437
+
$ref: '#/components/schemas/webhook'
1438
+
'400':
1439
+
description: Bad request
1440
+
content:
1441
+
application/json:
1442
+
schema:
1443
+
$ref: '#/components/schemas/error_response'
1444
+
'422':
1445
+
description: Unprocessable entity
1446
+
content:
1447
+
application/json:
1448
+
schema:
1449
+
$ref: '#/components/schemas/error_response'
1450
+
'500':
1451
+
description: Internal server error
1452
+
content:
1453
+
application/json:
1454
+
schema:
1455
+
$ref: '#/components/schemas/error_response'
1456
+
requestBody:
1457
+
content:
1458
+
application/json:
1459
+
schema:
1460
+
$ref: '#/components/schemas/webhook'
1461
+
description: The webhook to add
1462
+
required: true
1463
+
/v1/webhooks/{webhook_id}:
1464
+
get:
1465
+
operationId: retrieve-a-webhook
1466
+
tags:
1467
+
- Webhooks
1468
+
summary: Retrieve a webhook by id
1469
+
description: Retrieve a webhook by id.
1470
+
responses:
1471
+
'200':
1472
+
description: Success
1473
+
content:
1474
+
application/json:
1475
+
schema:
1476
+
$ref: '#/components/schemas/webhook'
1477
+
'404':
1478
+
description: Not found
1479
+
content:
1480
+
application/json:
1481
+
schema:
1482
+
$ref: '#/components/schemas/error_response'
1483
+
'500':
1484
+
description: Internal server error
1485
+
content:
1486
+
application/json:
1487
+
schema:
1488
+
$ref: '#/components/schemas/error_response'
1489
+
put:
1490
+
operationId: update-a-webhook
1491
+
tags:
1492
+
- Webhooks
1493
+
summary: Update a webhook
1494
+
description: Update a webhook.
1495
+
responses:
1496
+
'200':
1497
+
description: Success
1498
+
content:
1499
+
application/json:
1500
+
schema:
1501
+
$ref: '#/components/schemas/webhook'
1502
+
'400':
1503
+
description: Bad request
1504
+
content:
1505
+
application/json:
1506
+
schema:
1507
+
$ref: '#/components/schemas/error_response'
1508
+
'422':
1509
+
description: Unprocessable entity
1510
+
content:
1511
+
application/json:
1512
+
schema:
1513
+
$ref: '#/components/schemas/error_response'
1514
+
'404':
1515
+
description: Not found
1516
+
content:
1517
+
application/json:
1518
+
schema:
1519
+
$ref: '#/components/schemas/error_response'
1520
+
'500':
1521
+
description: Internal server error
1522
+
content:
1523
+
application/json:
1524
+
schema:
1525
+
$ref: '#/components/schemas/error_response'
1386
1526
1387
1527
components:
1388
1528
parameters:
@@ -1856,7 +1996,8 @@ components:
1856
1996
The event body will include detailed information about the test, such as the number of scenarios that were executed and the number of requests that were invoked.
1857
1997
items:
1858
1998
type: string
1859
-
description: The url of where to send the webhook with the report information
1999
+
format: uuid
2000
+
description: The id of the webhook
1860
2001
arrival_rate:
1861
2002
type: number
1862
2003
minimum: 1
@@ -2277,3 +2418,38 @@ components:
2277
2418
percentage:
2278
2419
type: number
2279
2420
description: benchmark percentage weight
2421
+
webhook:
2422
+
type: object
2423
+
required:
2424
+
- name
2425
+
- webhook_url
2426
+
- events
2427
+
properties:
2428
+
id:
2429
+
description: Unique webhook identifier
2430
+
type: string
2431
+
format: uuid
2432
+
readOnly: true
2433
+
name:
2434
+
type: string
2435
+
description: Webhook name
2436
+
webhook_url:
2437
+
type: string
2438
+
description: Webhook url to post events
2439
+
events:
2440
+
description: list of events which will trigger the webhook
0 commit comments