Migrate Connect to use Connect SDK instead of CLI#138
Closed
Migrate Connect to use Connect SDK instead of CLI#138
Conversation
JillRegan
commented
Feb 20, 2026
| run: | | ||
| echo "$OP_CONNECT_CREDENTIALS" > 1password-credentials.json | ||
| docker compose -f tests/fixtures/docker-compose.yml up -d && sleep 10 | ||
| docker compose -f tests/fixtures/docker-compose.yml up -d && sleep 30 |
Contributor
Author
There was a problem hiding this comment.
increased start up time now that we are testing for file content
JillRegan
commented
Feb 23, 2026
| } | ||
|
|
||
| if (fileId) { | ||
| return getFileContentWithRetry(client, parsed.vault, parsed.item, fileId); |
Contributor
Author
There was a problem hiding this comment.
Ran into issues with getting file content returning 503. This was only happened in e2e runs on GitHub Actions and could not be reproduced locally. The server may be temporarily overloaded or unavailable. Loading file content is now retried on 503 (up to 3 attempts with a 2s delay) so transient failures in CI don’t cause the action to fail.
Base automatically changed from
jill/validate-secret-reference
to
feature/migrate-to-sdk
February 23, 2026 16:42
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.
Overview
This PR updates the Connect-based secret resolution path to use the 1Password Connect JavaScript SDK when OP_CONNECT_HOST and OP_CONNECT_TOKEN are provided, instead of shelling out to the op CLI. The goal is to keep behavior consistent with the current action while making Connect resolution fully SDK-driven.
When users configure the action for Connect (OP_CONNECT_HOST + OP_CONNECT_TOKEN), we must resolve op:// references via the Connect API. The op CLI’s Go implementation is used as the reference spec for:
What Changed
How to Test Manually
I tested this locally by:
.github/workflows/test-locally.ymland added the below script. FYI as long as Docker is runnign this will spin up a connect server for you do you don't have to do it yourself.The item and field names in the workflow (e.g. test-secret, file-secret, multiline-secret) match the current testing vault used for this action. You can change them to match your own vault, items, and fields.
brew install act