feat(coding-agent): added resolver-based auth retries to image and search tools

- Routed image-gen, inspect-image, and web search providers through `withAuth`.
- Used `reuseInitialApiKey`/`createAuthStorageResolver` for force-refresh and rotate retries.
- Attached HTTP status to thrown errors so the retry classifier detects retryable failures.
This commit is contained in:
can1357
2026-06-07 04:39:06 +02:00
parent fceff5e6b6
commit c10eb5e50e
28 changed files with 377 additions and 269 deletions
@@ -29,6 +29,9 @@ function createRegistry(model: Model<Api>) {
return {
getAvailable: () => [model],
getApiKey: async () => "test-key",
getApiKeyForProvider: async () => "test-key",
authStorage: { rotateSessionCredential: async () => false },
resolver: () => async () => "test-key",
} as never;
}