fix: Add recursive query string (#4507)

### Description
- Adds `recursive=true` query string to the url in github-proxy
pull/4509/head
Lee 2 months ago committed by GitHub
parent 59b5e12e1b
commit 3113807e3d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
  1. 5
      .changeset/loud-elephants-reflect.md
  2. 23
      typescript/github-proxy/README.md
  3. 2
      typescript/github-proxy/src/index.ts

@ -0,0 +1,5 @@
---
'@hyperlane-xyz/github-proxy': minor
---
Add recursive=true query string to Github Proxy to allow nested tree search

@ -0,0 +1,23 @@
# Github Proxy
## Overview
Github Proxy is a CloudFlare Worker that makes a Github API requests using an API key. This authenticated method allows higher limits than the non-authenticated mode.
## Keys
Acquire a Github api key by creating a new [fine-grained personal access token](https://github.com/settings/tokens).
## Local Development
Prerequisites: Copy the `.dev.vars.example` and add the Github API key.
Development is managed by the Wrangler CLI. To start dev mode execute `yarn dev`. This will start a local server.
## Testing
Unit tests can be executed using `yarn test`.
## Deployment
Execute `yarn deploy` to deploy to production. Note that the deployment requires permissions. To deploy to a staging environment use `yarn deploy:staging`. Use `yarn deploy:key` to attach the Github key to the Worker.

@ -12,7 +12,7 @@ export default {
return new Response(DISALLOWED_URL_MSG, { status: 401 });
}
const apiUrl = new URL(`${GITPUB_API_HOST}${apiUrlPath}`);
const apiUrl = new URL(`${GITPUB_API_HOST}${apiUrlPath}?recursive=true`);
return fetch(apiUrl, {
method: 'GET',
headers: {

Loading…
Cancel
Save