Commit 17270e9
feat: add StandaloneInterceptor to all 3 SDKs — works without API key
Adds offline/standalone mode to Python, TypeScript, and Go SDKs:
- Embedded Cedar policy evaluator (forbid/permit rules)
- Local JSONL event logging (thread-safe)
- Three enforcement modes: block, warn, log
- URL exclusion patterns
- Zero external dependencies for policy evaluation
- 34 Python tests, 74 TypeScript tests, 50 Go tests — all passing
- STANDALONE.md docs + examples for each SDK
- README updated with standalone vs platform comparison table
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>1 parent 2aaeece commit 17270e9
File tree
24 files changed
+6578
-0
lines changed- trusera-agent-sdk
- examples
- tests
- trusera_sdk
- trusera-sdk-go
- examples/standalone
- trusera-sdk-js
- docs
- examples
- src
- tests
24 files changed
+6578
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
23 | 23 | | |
24 | 24 | | |
25 | 25 | | |
| 26 | + | |
26 | 27 | | |
27 | 28 | | |
28 | 29 | | |
| |||
140 | 141 | | |
141 | 142 | | |
142 | 143 | | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| 197 | + | |
| 198 | + | |
| 199 | + | |
| 200 | + | |
| 201 | + | |
| 202 | + | |
143 | 203 | | |
144 | 204 | | |
145 | 205 | | |
| |||
0 commit comments