Skip to content

Commit 059ea93

Browse files
alpslaclaude
andcommitted
fix(corgea): Handle status:'ok' response format in health check
🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 96b8efb commit 059ea93

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

packages/agents/src/two-branch/tools/cloud-api/corgea-fixer.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -130,7 +130,8 @@ interface CorgeaScanResponse {
130130
}
131131

132132
interface CorgeaVerifyResponse {
133-
valid: boolean;
133+
status?: string; // API returns {"status": "ok"}
134+
valid?: boolean; // Alternative format
134135
user?: {
135136
email: string;
136137
organization: string;
@@ -244,7 +245,8 @@ export class CorgeaFixer extends CloudAPIToolBase {
244245
async checkHealth(): Promise<boolean> {
245246
try {
246247
const response = await this.makeRequest<CorgeaVerifyResponse>('GET', '/verify');
247-
return response.data.valid === true;
248+
// API returns {"status": "ok"} or {"valid": true}
249+
return response.data.status === 'ok' || response.data.valid === true;
248250
} catch {
249251
return false;
250252
}

0 commit comments

Comments
 (0)