Skip to content

feat: add secrets to oo-sdk#756

Merged
james-rl merged 5 commits intonextfrom
james/secrets
Mar 17, 2026
Merged

feat: add secrets to oo-sdk#756
james-rl merged 5 commits intonextfrom
james/secrets

Conversation

@james-rl
Copy link
Contributor

@james-rl james-rl commented Mar 6, 2026

I discovered that there was a gap in our oo-sdk. Secrets now have coverage.

Also added examples

@james-rl james-rl requested a review from sid-rl March 6, 2026 01:41
@james-rl james-rl changed the base branch from main to next March 6, 2026 18:11
"""
return Secret(self._client, name)

def update(
Copy link
Contributor

Choose a reason for hiding this comment

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

having an update() method in both the Ops class and the object class feels redundant. we should only have it in one (i think within the Secrets class itself) so that there's one canonical way to update secrets.

"""
name = secret if isinstance(secret, str) else secret.name
self._client.secrets.update(name, value=value, **options)
return Secret(self._client, name)
Copy link
Contributor

Choose a reason for hiding this comment

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

we should pass id into the return object

:type client: AsyncRunloop
:param name: The globally unique name of the secret
:type name: str
:param id: The secret ID (optional, may not be known until get_info is called)
Copy link
Contributor

Choose a reason for hiding this comment

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

is this a paradigm we want to incorporate across the rest of the oo-sdk as well? feels a bit weird that this is the only class that implements it, if we want to go this route

@stainless-app stainless-app bot force-pushed the next branch 2 times, most recently from 5dfcd93 to 8428682 Compare March 11, 2026 01:06
@james-rl james-rl requested a review from dines-rl March 16, 2026 23:39
@james-rl james-rl merged commit 82020d7 into next Mar 17, 2026
6 checks passed
@james-rl james-rl deleted the james/secrets branch March 17, 2026 01:08
@stainless-app stainless-app bot mentioned this pull request Mar 17, 2026
stainless-app bot added a commit that referenced this pull request Mar 18, 2026
Co-authored-by: stainless-app[bot] <142633134+stainless-app[bot]@users.noreply.github.com>
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

Successfully merging this pull request may close these issues.

2 participants