Skip to content

Commit

Permalink
Merge pull request #923 from momorientes/main
Browse files Browse the repository at this point in the history
Adding Jira HTTP Report documentation
  • Loading branch information
massimocandela authored Jan 31, 2023
2 parents 9e403f9 + 7c6c85a commit 2c7eeac
Showing 1 changed file with 43 additions and 0 deletions.
43 changes: 43 additions & 0 deletions docs/report-http.md
Original file line number Diff line number Diff line change
Expand Up @@ -209,3 +209,46 @@ reports:
> Configure the "_CHANNEL_NAME_" in the template. Start with @ for user or # for channel. Eg: @john or #general

Thanks to [cadirol](https://github.com/nttgin/BGPalerter/pull/704).

## Jira

Jira is a project management tool by Atlassian.

You need to set the project key and the issuetype ID according to your environment.
To obtain the issuetype ID:
```bash
curl 'https://user:token@domain.atlassian.net/rest/api/latest/issue/SUP-123' | jq .fields.issuetype.id
```

If your username includes the `@`-character replace it with `%40`.

```yaml
- file: reportHTTP
channels:
- hijack
- newprefix
- visibility
- path
- misconfiguration
- rpki
params:
templates:
default: '{
"fields": {
"project":
{
"key": "SUP"
},
"summary": "BGPAlerter: ${type}: ${prefix}",
"description": "Prefix: ${prefix}\nEvent Type: ${type}\nEarliest: ${earliest}\nLatest: ${latest}\nASN: ${asn}\nBGPlay: ${bgplay}\n",
"issuetype": {
"id": "10223"
}
}
}'
isTemplateJSON: true
headers:
showPaths: 0 # Amount of AS_PATHs to report in the alert
hooks:
default: 'https://user%domain.com:<token>@company.atlassian.net/rest/api/2/issue'
```

0 comments on commit 2c7eeac

Please sign in to comment.