Commit 5ea67d0
feat(connectors): allow skipping OAuth with Esc key (#217)
* feat(connectors): add OAuth connector resource schemas and file parsing
Add connector resource module supporting 12 OAuth providers:
googlecalendar, googledrive, gmail, googlesheets, googledocs,
googleslides, slack, notion, salesforce, hubspot, linkedin, tiktok.
- Zod discriminated union schema with type discriminator per provider
- JSDoc links to official OAuth scope documentation for each provider
- JSONC file reading with validation (filename must match type field)
- API response schemas for upstream connector state
- Unit tests with fixtures for valid, invalid, and mismatched connectors
Part of: #184
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* feat(connectors): implement push logic for syncing connectors (#191)
* feat(connectors): implement push logic for syncing connectors
Add pushConnectors function that:
- Syncs all local connectors via /sync endpoint
- Removes upstream-only connectors not in local config
- Returns typed results (synced, removed, needs_oauth, error)
Includes unit tests covering all scenarios.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* feat(connectors): add OAuth flow handling with browser redirect and polling (#192)
* feat(connectors): add OAuth flow handling with browser redirect and polling
Add runOAuthFlow function that:
- Opens OAuth redirect URL in browser
- Polls getOAuthStatus until ACTIVE or FAILED
- Returns PENDING on timeout (5 minutes)
Uses p-wait-for TimeoutError for robust timeout detection.
Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
* connectors: base44 connectors push (#194)
* final connector work sofi 1
* scopes
---------
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
* feat(connectors): support arbitrary OAuth providers
Change provider field from closed enum to flexible union that accepts both
known providers (googlecalendar, notion, slack, etc.) and any arbitrary
provider string. This enables users to configure custom OAuth providers
without waiting for first-class Base44 support.
Schema changes:
- Add GenericConnectorSchema for arbitrary provider types
- Update ConnectorResourceSchema to union of specific + generic schemas
- Update IntegrationTypeSchema to accept known enum OR any non-empty string
- Only reject empty strings
Test coverage:
- Verify known providers continue to work
- Verify arbitrary providers are accepted
- Verify empty strings are rejected
- All 137 tests passing
Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
* review fixes
* feat(connectors): allow skipping OAuth authorization with Esc key
Override process.exit temporarily during the spinner to intercept
Ctrl+C/Escape (which clack's block() converts to process.exit(0)),
letting users skip individual connector authorizations instead of
killing the entire process. Adds SKIPPED status to the summary.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
* fix
* lint
* review fixes: add process.exit override comment, use try/catch/finally
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>1 parent 73b9d2f commit 5ea67d0
1 file changed
Lines changed: 95 additions & 36 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | | - | |
| 1 | + | |
2 | 2 | | |
3 | 3 | | |
4 | 4 | | |
| |||
14 | 14 | | |
15 | 15 | | |
16 | 16 | | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
17 | 97 | | |
18 | 98 | | |
19 | 99 | | |
| |||
25 | 105 | | |
26 | 106 | | |
27 | 107 | | |
28 | | - | |
| 108 | + | |
29 | 109 | | |
30 | 110 | | |
31 | 111 | | |
32 | 112 | | |
| 113 | + | |
33 | 114 | | |
34 | 115 | | |
35 | 116 | | |
| |||
44 | 125 | | |
45 | 126 | | |
46 | 127 | | |
| 128 | + | |
| 129 | + | |
47 | 130 | | |
48 | 131 | | |
49 | 132 | | |
| |||
66 | 149 | | |
67 | 150 | | |
68 | 151 | | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
69 | 155 | | |
70 | 156 | | |
71 | 157 | | |
| |||
92 | 178 | | |
93 | 179 | | |
94 | 180 | | |
95 | | - | |
| 181 | + | |
96 | 182 | | |
97 | 183 | | |
98 | 184 | | |
| |||
125 | 211 | | |
126 | 212 | | |
127 | 213 | | |
128 | | - | |
129 | | - | |
130 | | - | |
131 | | - | |
132 | | - | |
133 | | - | |
134 | | - | |
135 | | - | |
136 | | - | |
137 | | - | |
138 | | - | |
139 | | - | |
140 | | - | |
141 | | - | |
142 | | - | |
143 | | - | |
144 | | - | |
145 | | - | |
146 | | - | |
147 | | - | |
148 | | - | |
149 | | - | |
150 | | - | |
151 | | - | |
152 | | - | |
153 | | - | |
154 | | - | |
155 | | - | |
156 | | - | |
157 | | - | |
158 | | - | |
159 | | - | |
| 214 | + | |
| 215 | + | |
| 216 | + | |
| 217 | + | |
| 218 | + | |
160 | 219 | | |
161 | 220 | | |
162 | | - | |
| 221 | + | |
163 | 222 | | |
164 | 223 | | |
165 | 224 | | |
| |||
0 commit comments