Skip to content

Commit 1d90b3d

Browse files
committed
chore: bump depts
1 parent f227899 commit 1d90b3d

File tree

3 files changed

+17
-11
lines changed

3 files changed

+17
-11
lines changed

README.md

Lines changed: 12 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
</div>
1212

13-
Track how many GitHub API requests a workflow job consumes, parttioned by bucket (core, GraphQL, search, etc.).
13+
Track how many GitHub API requests a workflow job consumes, partitioned by bucket (core, GraphQL, search, etc.).
1414

1515
This action captures the rate-limit state at job start and compares it with the state at job end.
1616

@@ -23,9 +23,9 @@ jobs:
2323
search:
2424
runs-on: ubuntu-latest
2525
steps:
26-
- name Checkout
26+
- name: Checkout
2727
uses: actions/checkout@v4
28-
- name Track Usage
28+
- name: Track Usage
2929
uses: hesreallyhim/github-api-usage-tracker@v1
3030
- name: Query API
3131
uses: actions/github-script@v6
@@ -45,13 +45,19 @@ After your job completes, you'll get a nice summary in the workflow UI:
4545

4646
| Name | Description | Default |
4747
| ----------- | ---------------------------------------------------------------------------------------------------------------------- | ----------------------------- |
48-
| token | Name of GitHub token used to query rate limits | github.token (`GITHUB_TOKEN`) |
48+
| token | GitHub token used to query rate limits | github.token (`GITHUB_TOKEN`) |
4949
| buckets | Comma-separated list of rate-limit buckets to track.<br>(core, search, graphql...) - see reference below for full list | core,search,graphql |
5050
| output_path | Write usage report JSON to this path (empty to disable) | github_api_usage.json |
5151

5252
## Outputs
5353

54-
| Name | Description |
54+
| Name | Description |
55+
| ------- | --------------------------------------------------------------- |
56+
| `usage` | JSON string with the fields described below (stringified JSON). |
57+
58+
The `usage` output is a JSON string with the following structure (stringified):
59+
60+
| Path | Description |
5561
| --------------------------------------- | ------------------------------------------------------------------- |
5662
| `total` | Summation of captured queries/points used per bucket |
5763
| `duration_ms` | Duration between first and last snapshot in milliseconds |
@@ -109,7 +115,7 @@ Example output:
109115

110116
### Token Types
111117

112-
- GitHub’s primary rate limit for Actions using the `GITHUB_TOKEN` is 1,000 REST API requests per repository per hour (or 15,000 per repository per hour for GitHub Enterprise Cloud).
118+
- GitHub’s primary rate limit for Actions using the `GITHUB_TOKEN` is 1,000 REST API requests per repository per hour (or 15,000 per repository per hour for GitHub Enterprise Cloud); these limits are policy-level and can change independently of the API version.
113119
- If you set the `token` to be a PAT, or something besides `GITHUB_TOKEN`, that token has the same rate-limit in the Action as it does elsewhere (and rate-limit "snapshots" will be impacted).
114120
- Despite appearances, `GITHUB_TOKEN` is an ephemeral token that is minted at the start of each job, as an app installation token from the GitHub Actions app. However, the same _rate limit_ applies to any job within the repo, even though the tokens are, strictly speaking, non-identical.
115121
- For this reason, the API usage measurements can only be considered precise if there is _no other job_ running concurrently with the action that you wish to track. This is also why the rate limit starting snapshot may already show non-0 usage data.

package-lock.json

Lines changed: 4 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
"@vercel/ncc": "0.38.4",
2424
"@vitest/coverage-v8": "4.0.18",
2525
"eslint": "9.39.2",
26-
"globals": "17.0.0",
26+
"globals": "17.1.0",
2727
"husky": "9.1.7",
2828
"prettier": "3.8.1",
2929
"rimraf": "6.1.2",

0 commit comments

Comments
 (0)