{"record":{"id":"ad5e7a7533ddda36","repo":"chenhg5/cc-connect","slug":"webex-getmessage-status-d","errorCode":null,"errorMessage":"webex: getMessage status %d","messagePattern":"webex: getMessage status (.+?)","errorType":"http","errorClass":null,"httpStatus":null,"severity":"error","filePath":"platform/webex/client.go","lineNumber":174,"sourceCode":"\tresp, err := c.doWithRetry(ctx, http.MethodDelete, deviceURL, nil, \"\", \"webex: deleteDevice\")\n\tif err != nil {\n\t\treturn err\n\t}\n\tdefer func() { _ = resp.Body.Close() }()\n\tif resp.StatusCode != http.StatusOK && resp.StatusCode != http.StatusNoContent && resp.StatusCode != http.StatusAccepted {\n\t\treturn fmt.Errorf(\"webex: deleteDevice status %d\", resp.StatusCode)\n\t}\n\treturn nil\n}\n\nfunc (c *httpClient) GetMessage(ctx context.Context, id string) (*message, error) {\n\tresp, err := c.doWithRetry(ctx, http.MethodGet, c.base()+\"/messages/\"+id, nil, \"\", \"webex: getMessage\")\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tdefer func() { _ = resp.Body.Close() }()\n\tif resp.StatusCode != http.StatusOK {\n\t\treturn nil, fmt.Errorf(\"webex: getMessage status %d\", resp.StatusCode)\n\t}\n\tvar m message\n\tif err := json.NewDecoder(resp.Body).Decode(&m); err != nil {\n\t\treturn nil, err\n\t}\n\treturn &m, nil\n}\n\nfunc (c *httpClient) DownloadFile(ctx context.Context, url string) (*downloadedFile, error) {\n\tresp, err := c.doWithRetry(ctx, http.MethodGet, url, nil, \"\", \"webex: downloadFile\")\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\tdefer func() { _ = resp.Body.Close() }()\n\tif resp.StatusCode != http.StatusOK {\n\t\treturn nil, fmt.Errorf(\"webex: downloadFile status %d\", resp.StatusCode)\n\t}\n\tdata, err := io.ReadAll(resp.Body)","sourceCodeStart":156,"sourceCodeEnd":192,"githubUrl":"https://github.com/chenhg5/cc-connect/blob/4000b2338aa6e850c99df54f8b0ed6ed7460b401/platform/webex/client.go#L156-L192","documentation":"The Webex REST call GET /messages/{id} completed but returned a status other than 200 OK. This is a post-retry status guard: common causes are 401 (bad/expired token, covered by TestGetMessageUnauthorized) or a non-transient failure that doWithRetry's 429 backoff (TestGetMessageRetriesOn429) could not absorb.","triggerScenarios":"Thrown at platform/webex/client.go:174 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["On 401, re-issue the bot token and retry the fetch","On 404, the message was deleted or is inaccessible; skip it rather than retrying","Include the response body in logs to see the Webex error payload","For persistent 5xx, back off and retry at the caller"],"exampleFix":null,"handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"4000b2338aa6e850c99df54f8b0ed6ed7460b401","analyzedAt":"2026-09-06T11:45:09.575Z","contentChangedAt":"2026-09-06T11:45:09.575Z","schemaVersion":2},"datasetVersion":"2026-09-14T00:17:10.932Z"}