Skip to content

feat(cli): add authconnection delete command#1310

Draft
toiroakr wants to merge 3 commits into
feat/auth-connection-labelsfrom
feat/auth-connection-delete
Draft

feat(cli): add authconnection delete command#1310
toiroakr wants to merge 3 commits into
feat/auth-connection-labelsfrom
feat/auth-connection-delete

Conversation

@toiroakr
Copy link
Copy Markdown
Contributor

@toiroakr toiroakr commented Jun 3, 2026

Summary

  • Add tailor authconnection delete to remove an auth connection entirely (configuration + tokens). On older platforms without the new RPC it falls back to revoke, which still deletes there.
  • tailor authconnection revoke now only invalidates the connection's tokens and keeps the connection so it can be re-authorized, matching the platform's revoke/delete split. The command notes call out that older platforms still delete on revoke.
  • deploy now uses DeleteAuthConnection when replacing or removing auth connections, falling back to RevokeAuthConnection on platforms that do not implement it yet. Without this, deploys would fail with AlreadyExists once the platform split rolls out.
  • Regenerated the @tailor-proto bindings to include DeleteAuthConnection. The regeneration tracks the current upstream proto, so it also picks up unrelated new upstream bindings (organization IP restriction, custom domains, workflow execution policies, etc.).

Depends on

The platform-side DeleteAuthConnection RPC and token-only revoke behavior, which roll out separately. Until then, deploy and authconnection delete fall back to revoke (which still deletes on older platforms).

Base

Stacked on #1309.

@changeset-bot
Copy link
Copy Markdown

changeset-bot Bot commented Jun 3, 2026

🦋 Changeset detected

Latest commit: abcaeb0

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 2 packages
Name Type
@tailor-platform/sdk Minor
@tailor-platform/create-sdk Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Jun 3, 2026

⚡ pkg.pr.new

@tailor-platform/sdk

pnpm add https://pkg.pr.new/@tailor-platform/sdk@abcaeb0
pnpm dlx https://pkg.pr.new/@tailor-platform/sdk@abcaeb0 --help

@tailor-platform/create-sdk

pnpm add https://pkg.pr.new/@tailor-platform/create-sdk@abcaeb0
pnpm dlx https://pkg.pr.new/@tailor-platform/create-sdk@abcaeb0 my-app

commit: abcaeb0

toiroakr added 2 commits June 5, 2026 22:40
Add 'tailor authconnection delete' to remove an auth connection entirely, and
clarify that 'authconnection revoke' now only invalidates tokens. Regenerate the
@tailor-proto bindings to include DeleteAuthConnection (syncs tailor-proto to the
current tailor-inc/proto).
Once the platform splits revoke (token-only) from delete, the deploy flow's
revoke-then-create replacement would fail with AlreadyExists and its deletions
would silently stop removing connections. Use DeleteAuthConnection for both,
falling back to RevokeAuthConnection on platforms that do not implement it yet,
where revoke still deletes the connection.
@toiroakr toiroakr force-pushed the feat/auth-connection-delete branch from adcfca6 to 3f53df5 Compare June 5, 2026 13:58
@toiroakr
Copy link
Copy Markdown
Contributor Author

toiroakr commented Jun 5, 2026

Post-rollout cleanup: once the platform's revoke/delete split has rolled out to every environment, remove the RevokeAuthConnection fallback in deleteConnectionWithFallback (packages/sdk/src/cli/commands/deploy/auth-connection.ts). The fallback only exists because revoke still deletes the connection on older platforms.

This comment was marked as outdated.

…orms

Older platforms have no DeleteAuthConnection RPC, where revoke still deletes
the connection, so the CLI delete command now falls back to revoke on
Unimplemented like deploy does. Document the version-dependent revoke behavior
in the command notes, and fill the previously missing api subcommands table in
the generated docs.
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

Copilot reviewed 20 out of 32 changed files in this pull request and generated 1 comment.

Files not reviewed (1)
  • packages/tailor-proto/src/tailor/v1/service_pb.js: Language not supported


feat(cli): add `authconnection delete` and make `authconnection revoke` token-only

`tailor authconnection delete` removes an auth connection entirely (configuration and tokens). `tailor authconnection revoke` now only invalidates the connection's tokens while keeping the connection so it can be re-authorized — previously revoke removed the connection entirely. `deploy` now uses delete when replacing or removing auth connections (falling back to revoke on platforms without it), so update the SDK before the platform's revoke/delete split rolls out.
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