Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

We need to pass installation Installation Id #349

Closed
ng-galien opened this issue Sep 29, 2022 · 1 comment
Closed

We need to pass installation Installation Id #349

ng-galien opened this issue Sep 29, 2022 · 1 comment

Comments

@ng-galien
Copy link
Contributor

In the sample code we get an HttpError: Resource not accessible by integration

We need to get it from app.eachInstallation and pass the id to app.eachRepository.

@gr2m gr2m added bug labels Sep 29, 2022
@gr2m
Copy link
Contributor

gr2m commented Sep 29, 2022

I see, thank you! you mean this code, right?

for await (const { octokit, repository } of app.eachRepository.iterator()) {
  await octokit.request("POST /repos/{owner}/{repo}/dispatches", {
    owner: repository.owner.login,
    repo: repository.name,
    event_type: "my_event",
  });
}

If you'd like to send a pull request that'd be much appreciated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants