Skip to content

fix(zapier): preemptive OAuth refresh + CI deploy guard fix#2

Merged
caoxing9 merged 2 commits into
mainfrom
fix/publish
Jul 8, 2026
Merged

fix(zapier): preemptive OAuth refresh + CI deploy guard fix#2
caoxing9 merged 2 commits into
mainfrom
fix/publish

Conversation

@caoxing9

@caoxing9 caoxing9 commented Jul 8, 2026

Copy link
Copy Markdown
Collaborator

Summary

  • Refresh the OAuth access token preemptively (store expires_at in authData, throw RefreshAuthError in beforeRequest before it expires), eliminating the per-poll 401s that inflated the 4xx rate in Zapier Monitoring and blocked publishing.
  • Fix the deploy guard in zapier.yml: Zapier reports pending-review versions as draft (not private), so the guard wrongly refused to overwrite version 1.0.0 with its own test-Zap users.

Test plan

  • 21 unit tests pass (7 new for the preemptive-refresh middleware)
  • zapier validate — 47 checks passed
  • Manually pushed to Zapier; confirm 401s drop to zero in Monitoring
  • After merge, confirm the deploy job passes the guard

Made with Cursor

caoxing9 and others added 2 commits July 8, 2026 17:17
Co-authored-by: Cursor <cursoragent@cursor.com>
@caoxing9
caoxing9 merged commit 26dfb40 into main Jul 8, 2026
3 checks passed
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.

1 participant