Skip to content

Commit dbc1fda

Browse files
authored
feat: .apps.getWebhookDelivery(), .apps.listWebhookDeliveries(), .apps.redeliverWebhookDelivery(), .orgs.getWebhookDelivery(), .orgs.listWebhookDeliveries(), .orgs.redeliverWebhookDelivery(), .repos.getWebhookDelivery(), .repos.listWebhookDeliveries(), .repos.redeliverWebhookDelivery() (#414)
1 parent 9d74305 commit dbc1fda

17 files changed

+1411
-201
lines changed

.github/workflows/update.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@ jobs:
1616
runs-on: ubuntu-latest
1717
steps:
1818
- uses: actions/checkout@v2
19+
with:
20+
# make sure that other actions get triggered when using `git push` in gr2m/create-or-update-pull-request-action
21+
token: ${{ secrets.OCTOKITBOT_PAT }}
1922
- uses: actions/setup-node@v2
2023
with:
2124
node-version: 14

docs/actions/approveWorkflowRun.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,6 @@ type: API method
88

99
# Approve a workflow run for a fork pull request
1010

11-
**Note:** This endpoint is currently in beta and is subject to change.
12-
1311
Approves a workflow run for a pull request from a public fork of a first time contributor. For more information, see ["Approving workflow runs from public forks](https://docs.github.com/actions/managing-workflow-runs/approving-workflow-runs-from-public-forks)."
1412

1513
You must authenticate using an access token with the `repo` scope to use this endpoint. GitHub Apps must have the `actions:write` permission to use this endpoint.

docs/apps/getWebhookDelivery.md

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
---
2+
name: Get a delivery for an app webhook
3+
example: octokit.rest.apps.getWebhookDelivery({ delivery_id })
4+
route: GET /app/hook/deliveries/{delivery_id}
5+
scope: apps
6+
type: API method
7+
---
8+
9+
# Get a delivery for an app webhook
10+
11+
Returns a delivery for the webhook configured for a GitHub App.
12+
13+
You must use a [JWT](https://docs.github.com/apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.
14+
15+
```js
16+
octokit.rest.apps.getWebhookDelivery({
17+
delivery_id,
18+
});
19+
```
20+
21+
## Parameters
22+
23+
<table>
24+
<thead>
25+
<tr>
26+
<th>name</th>
27+
<th>required</th>
28+
<th>description</th>
29+
</tr>
30+
</thead>
31+
<tbody>
32+
<tr><td>delivery_id</td><td>yes</td><td>
33+
34+
</td></tr>
35+
</tbody>
36+
</table>
37+
38+
See also: [GitHub Developer Guide documentation](https://docs.github.com/rest/reference/apps#get-a-delivery-for-an-app-webhook).

docs/apps/listWebhookDeliveries.md

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
---
2+
name: List deliveries for an app webhook
3+
example: octokit.rest.apps.listWebhookDeliveries()
4+
route: GET /app/hook/deliveries
5+
scope: apps
6+
type: API method
7+
---
8+
9+
# List deliveries for an app webhook
10+
11+
Returns a list of webhook deliveries for the webhook configured for a GitHub App.
12+
13+
You must use a [JWT](https://docs.github.com/apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.
14+
15+
```js
16+
octokit.rest.apps.listWebhookDeliveries();
17+
```
18+
19+
## Parameters
20+
21+
<table>
22+
<thead>
23+
<tr>
24+
<th>name</th>
25+
<th>required</th>
26+
<th>description</th>
27+
</tr>
28+
</thead>
29+
<tbody>
30+
<tr><td>per_page</td><td>no</td><td>
31+
32+
Results per page (max 100).
33+
34+
</td></tr>
35+
<tr><td>cursor</td><td>no</td><td>
36+
37+
Used for pagination: the starting delivery from which the page of deliveries is fetched. Refer to the `link` header for the next and previous page cursors.
38+
39+
</td></tr>
40+
</tbody>
41+
</table>
42+
43+
See also: [GitHub Developer Guide documentation](https://docs.github.com/rest/reference/apps#list-deliveries-for-an-app-webhook).
Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
---
2+
name: Redeliver a delivery for an app webhook
3+
example: octokit.rest.apps.redeliverWebhookDelivery({ delivery_id })
4+
route: POST /app/hook/deliveries/{delivery_id}/attempts
5+
scope: apps
6+
type: API method
7+
---
8+
9+
# Redeliver a delivery for an app webhook
10+
11+
Redeliver a delivery for the webhook configured for a GitHub App.
12+
13+
You must use a [JWT](https://docs.github.com/apps/building-github-apps/authenticating-with-github-apps/#authenticating-as-a-github-app) to access this endpoint.
14+
15+
```js
16+
octokit.rest.apps.redeliverWebhookDelivery({
17+
delivery_id,
18+
});
19+
```
20+
21+
## Parameters
22+
23+
<table>
24+
<thead>
25+
<tr>
26+
<th>name</th>
27+
<th>required</th>
28+
<th>description</th>
29+
</tr>
30+
</thead>
31+
<tbody>
32+
<tr><td>delivery_id</td><td>yes</td><td>
33+
34+
</td></tr>
35+
</tbody>
36+
</table>
37+
38+
See also: [GitHub Developer Guide documentation](https://docs.github.com/rest/reference/apps#redeliver-a-delivery-for-an-app-webhook).

docs/orgs/getWebhookDelivery.md

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
---
2+
name: Get a webhook delivery for an organization webhook
3+
example: octokit.rest.orgs.getWebhookDelivery({ org, hook_id, delivery_id })
4+
route: GET /orgs/{org}/hooks/{hook_id}/deliveries/{delivery_id}
5+
scope: orgs
6+
type: API method
7+
---
8+
9+
# Get a webhook delivery for an organization webhook
10+
11+
Returns a delivery for a webhook configured in an organization.
12+
13+
```js
14+
octokit.rest.orgs.getWebhookDelivery({
15+
org,
16+
hook_id,
17+
delivery_id,
18+
});
19+
```
20+
21+
## Parameters
22+
23+
<table>
24+
<thead>
25+
<tr>
26+
<th>name</th>
27+
<th>required</th>
28+
<th>description</th>
29+
</tr>
30+
</thead>
31+
<tbody>
32+
<tr><td>org</td><td>yes</td><td>
33+
34+
</td></tr>
35+
<tr><td>hook_id</td><td>yes</td><td>
36+
37+
</td></tr>
38+
<tr><td>delivery_id</td><td>yes</td><td>
39+
40+
</td></tr>
41+
</tbody>
42+
</table>
43+
44+
See also: [GitHub Developer Guide documentation](https://docs.github.com/rest/reference/orgs#get-a-webhook-delivery-for-an-organization-webhook).

docs/orgs/listWebhookDeliveries.md

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
---
2+
name: List deliveries for an organization webhook
3+
example: octokit.rest.orgs.listWebhookDeliveries({ org, hook_id })
4+
route: GET /orgs/{org}/hooks/{hook_id}/deliveries
5+
scope: orgs
6+
type: API method
7+
---
8+
9+
# List deliveries for an organization webhook
10+
11+
Returns a list of webhook deliveries for a webhook configured in an organization.
12+
13+
```js
14+
octokit.rest.orgs.listWebhookDeliveries({
15+
org,
16+
hook_id,
17+
});
18+
```
19+
20+
## Parameters
21+
22+
<table>
23+
<thead>
24+
<tr>
25+
<th>name</th>
26+
<th>required</th>
27+
<th>description</th>
28+
</tr>
29+
</thead>
30+
<tbody>
31+
<tr><td>org</td><td>yes</td><td>
32+
33+
</td></tr>
34+
<tr><td>hook_id</td><td>yes</td><td>
35+
36+
</td></tr>
37+
<tr><td>per_page</td><td>no</td><td>
38+
39+
Results per page (max 100).
40+
41+
</td></tr>
42+
<tr><td>cursor</td><td>no</td><td>
43+
44+
Used for pagination: the starting delivery from which the page of deliveries is fetched. Refer to the `link` header for the next and previous page cursors.
45+
46+
</td></tr>
47+
</tbody>
48+
</table>
49+
50+
See also: [GitHub Developer Guide documentation](https://docs.github.com/rest/reference/orgs#list-deliveries-for-an-organization-webhook).
Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
---
2+
name: Redeliver a delivery for an organization webhook
3+
example: octokit.rest.orgs.redeliverWebhookDelivery({ org, hook_id, delivery_id })
4+
route: POST /orgs/{org}/hooks/{hook_id}/deliveries/{delivery_id}/attempts
5+
scope: orgs
6+
type: API method
7+
---
8+
9+
# Redeliver a delivery for an organization webhook
10+
11+
Redeliver a delivery for a webhook configured in an organization.
12+
13+
```js
14+
octokit.rest.orgs.redeliverWebhookDelivery({
15+
org,
16+
hook_id,
17+
delivery_id,
18+
});
19+
```
20+
21+
## Parameters
22+
23+
<table>
24+
<thead>
25+
<tr>
26+
<th>name</th>
27+
<th>required</th>
28+
<th>description</th>
29+
</tr>
30+
</thead>
31+
<tbody>
32+
<tr><td>org</td><td>yes</td><td>
33+
34+
</td></tr>
35+
<tr><td>hook_id</td><td>yes</td><td>
36+
37+
</td></tr>
38+
<tr><td>delivery_id</td><td>yes</td><td>
39+
40+
</td></tr>
41+
</tbody>
42+
</table>
43+
44+
See also: [GitHub Developer Guide documentation](https://docs.github.com/rest/reference/orgs#redeliver-a-delivery-for-an-organization-webhook).

docs/repos/getWebhookDelivery.md

Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
---
2+
name: Get a delivery for a repository webhook
3+
example: octokit.rest.repos.getWebhookDelivery({ owner, repo, hook_id, delivery_id })
4+
route: GET /repos/{owner}/{repo}/hooks/{hook_id}/deliveries/{delivery_id}
5+
scope: repos
6+
type: API method
7+
---
8+
9+
# Get a delivery for a repository webhook
10+
11+
Returns a delivery for a webhook configured in a repository.
12+
13+
```js
14+
octokit.rest.repos.getWebhookDelivery({
15+
owner,
16+
repo,
17+
hook_id,
18+
delivery_id,
19+
});
20+
```
21+
22+
## Parameters
23+
24+
<table>
25+
<thead>
26+
<tr>
27+
<th>name</th>
28+
<th>required</th>
29+
<th>description</th>
30+
</tr>
31+
</thead>
32+
<tbody>
33+
<tr><td>owner</td><td>yes</td><td>
34+
35+
</td></tr>
36+
<tr><td>repo</td><td>yes</td><td>
37+
38+
</td></tr>
39+
<tr><td>hook_id</td><td>yes</td><td>
40+
41+
</td></tr>
42+
<tr><td>delivery_id</td><td>yes</td><td>
43+
44+
</td></tr>
45+
</tbody>
46+
</table>
47+
48+
See also: [GitHub Developer Guide documentation](https://docs.github.com/rest/reference/repos#get-a-delivery-for-a-repository-webhook).
Lines changed: 54 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,54 @@
1+
---
2+
name: List deliveries for a repository webhook
3+
example: octokit.rest.repos.listWebhookDeliveries({ owner, repo, hook_id })
4+
route: GET /repos/{owner}/{repo}/hooks/{hook_id}/deliveries
5+
scope: repos
6+
type: API method
7+
---
8+
9+
# List deliveries for a repository webhook
10+
11+
Returns a list of webhook deliveries for a webhook configured in a repository.
12+
13+
```js
14+
octokit.rest.repos.listWebhookDeliveries({
15+
owner,
16+
repo,
17+
hook_id,
18+
});
19+
```
20+
21+
## Parameters
22+
23+
<table>
24+
<thead>
25+
<tr>
26+
<th>name</th>
27+
<th>required</th>
28+
<th>description</th>
29+
</tr>
30+
</thead>
31+
<tbody>
32+
<tr><td>owner</td><td>yes</td><td>
33+
34+
</td></tr>
35+
<tr><td>repo</td><td>yes</td><td>
36+
37+
</td></tr>
38+
<tr><td>hook_id</td><td>yes</td><td>
39+
40+
</td></tr>
41+
<tr><td>per_page</td><td>no</td><td>
42+
43+
Results per page (max 100).
44+
45+
</td></tr>
46+
<tr><td>cursor</td><td>no</td><td>
47+
48+
Used for pagination: the starting delivery from which the page of deliveries is fetched. Refer to the `link` header for the next and previous page cursors.
49+
50+
</td></tr>
51+
</tbody>
52+
</table>
53+
54+
See also: [GitHub Developer Guide documentation](https://docs.github.com/rest/reference/repos#list-deliveries-for-a-repository-webhook).

0 commit comments

Comments
 (0)