feat(goTo): add postAuth and modules#2947
Open
immdipu wants to merge 2 commits into
Open
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds post-authentication metadata retrieval to the GoTo connector (to discover accountKey) and updates the GoTo provider catalog to support two modules with different base URLs, along with a manual smoke test program.
Changes:
- Introduce
providers/gotoconnector implementation withGetPostAuthInfo()that fetchesaccountKeyfrom/admin/rest/v1/me. - Update
providers/goTo.gocatalog entry to require post-auth info and definegoTo+goToConnectmodules. - Add
test/gotohelper +test/goto/auth-metadatamanual smoke test to print the retrievedaccountKey.
Reviewed changes
Copilot reviewed 6 out of 6 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| test/goto/connector.go | Adds a test helper to construct an authenticated GoTo connector instance from local creds. |
| test/goto/auth-metadata/main.go | Adds a manual go run smoke test to call GetPostAuthInfo() and log the accountKey. |
| providers/goto/connector.go | Defines the GoTo connector struct and NewConnector() using internal/components. |
| providers/goto/authmetamodel.go | Adds a small model helper for accountKey post-auth catalog vars. |
| providers/goto/authmetadata.go | Implements post-auth discovery call to /admin/rest/v1/me and returns CatalogVars. |
| providers/goTo.go | Updates the GoTo ProviderInfo to require post-auth metadata and introduces module definitions. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
accountKeyfrom/admin/rest/v1/me, GoTo API endpoints require it.goTo(api.getgo.com, default) andgoToConnect(api.goto.com), since the two share auth but live on different base URLs.