keon94 commented on code in PR #318: URL: https://github.com/apache/incubator-devlake-website/pull/318#discussion_r1038415876
########## docs/Plugins/pagerduty.md: ########## @@ -0,0 +1,74 @@ +--- +title: "Pagerduty (WIP)" +description: > + Pagerduty Plugin +--- + + + +## Summary + +This plugin collects all incidents from Pagerduty, and uses them to compute incident-type DORA metrics. + +As of v0.15.0, the `pagerduty` plugin can only be invoked through the DevLake API. Its support in Config-UI is WIP. + + +## Usage via DevLake API + +> Note: Please replace the `http://localhost:8080` in the sample requests with your actual DevLake API endpoint. For how to view DevLake API's swagger documentation, please refer to the "Using DevLake API" section of [Developer Setup](../DeveloperManuals/DeveloperSetup.md). + + +1. Create a Pagerduty data connection: `POST /plugins/pagerduty/connections`. Please see a sample request below: + +``` +curl --location --request POST 'http://localhost:8080/plugins/pagerduty/connections' \ +--header 'Content-Type: application/json' \ +--data-raw '{ + "name": "pagerduty-test1", + "endpoint": "https://api.pagerduty.com", + "token": "<api-access-token>" +}' +``` + +2. Create a blueprint to collect data from Pagerduty: `POST /blueprints`. Please see a sample request below: + +``` +curl --location --request POST 'http://localhost:8080/blueprints' \ +--header 'Content-Type: application/json' \ +--data-raw '{ + "cronConfig": "manual", + "enable": true, + "isManual": true, + "mode": "NORMAL", + "name": "test-blueprint", + "settings": { + "connections": [ + { + "connectionId": 1, + "plugin": "pagerduty", + "scope": [ + { + "entities": [ + "TICKET" Review Comment: I added a small explanation here. But I don't think there's a need for much because "TICKET" is the only supported entity for this plugin. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
