Skip to content

feat: implement the resolve endpoint - #18

Open
iyad-f wants to merge 7 commits into
mainfrom
feat/resolve-endpoint
Open

iyad-f wants to merge 7 commits into
mainfrom
feat/resolve-endpoint

Conversation

@iyad-f

@iyad-f iyad-f commented Sep 13, 2026

Copy link
Copy Markdown
Member

Summary

Type of change

  • Bug fix (fixes an issue, non-breaking)
  • New feature (adds functionality, non-breaking)
  • Breaking change (alters existing behaviour/compatibility)
  • Refactor (internal cleanup, no behaviour change)
  • CI / dependency update
  • Documentation update

Checklist

  • Self-reviewed the changes and removed debug code or unrelated changes
  • Tests pass, and I have manually tested the GitHub Action where applicable
  • Documentation or changelog has been updated where necessary
  • Complies with the AI Contribution Policy

@iyad-f
iyad-f requested a review from a team as a code owner September 13, 2026 19:14
@github-actions github-actions Bot added the idea: new feature Proposal for a new capability or verification check. label Sep 13, 2026
@vmphase

vmphase commented Sep 14, 2026

Copy link
Copy Markdown
Member

Do you expect it to send the authorization url when the /v1/link?repository_id= endpoint is triggered? I was planning to directly trigger the GitHub action to send the link depending on /v1/resolve?... response.

@iyad-f

iyad-f commented Sep 14, 2026

Copy link
Copy Markdown
Member Author

Do you expect it to send the authorization url when the /v1/link?repository_id= endpoint is triggered? I was planning to directly trigger the GitHub action to send the link depending on /v1/resolve?... response.

The resolve endpoint sends back a setup_url which the action can send as a comment for the linking process

Comment thread internal/server/resolve.go Outdated
@vmphase vmphase mentioned this pull request Sep 14, 2026
10 tasks
Comment thread .env.example
Comment on lines +31 to +32
# GitHub
GITHUB_OIDC_AUDIENCE=

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be removed. If ever being planned to be used on our Go-backend, it should be dynamically loaded from GitHub environmental variables (secrets), as we can't load any variables from .env dynamically in action.yml, but still want to avoid duplicating the same values.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah i mean technically a secrets manager would be used to load secrets.

@vmphase vmphase Sep 14, 2026

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Replace it with dynamic loading and mark this solved.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Uhh actually the aud is anyway present in the jwt token under the aud field i believe so this aint really a secret, although we do have to do this secrets manager for stuff like postgres password and discord client secret etc.

Comment thread .env.example
Comment thread internal/server/resolve.go Outdated
@vmphase
vmphase added this pull request to stack #20 September 14, 2026 18:25
@iyad-f

iyad-f commented Sep 14, 2026

Copy link
Copy Markdown
Member Author

Do you expect it to send the authorization url when the /v1/link?repository_id= endpoint is triggered? I was planning to directly trigger the GitHub action to send the link depending on /v1/resolve?... response.

The resolve endpoint sends back a setup_url which the action can send as a comment for the linking process

What is the /v1/link/ endpoint's purpose then?

there is no /v1/link, its just /link (public for users to click), and its purpose is basically to have the repo id and gh user id in the query parameters and hmac signature eventually and then we redirect the user to github oauth flow to prove their github identitiy and then in the callback we have do stuff and then redirect them back to the github oauth screen and handle its callback. Atleast this is what i though

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

idea: new feature Proposal for a new capability or verification check.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants