{"record":{"id":"47d9ed90828fa041","repo":"router-for-me/CLIProxyAPI","slug":"vertex-api-key-d-weight-w","errorCode":null,"errorMessage":"vertex-api-key[%d].weight: %w","messagePattern":"vertex-api-key\\[(.+?)\\]\\.weight: %w","errorType":"validation","errorClass":null,"httpStatus":null,"severity":"error","filePath":"internal/config/weight.go","lineNumber":131,"sourceCode":"\t}\n\tfor index := range cfg.GeminiKey {\n\t\tif errValidate := ValidateCredentialWeight(cfg.GeminiKey[index].Weight); errValidate != nil {\n\t\t\treturn fmt.Errorf(\"gemini-api-key[%d].weight: %w\", index, errValidate)\n\t\t}\n\t}\n\tfor index := range cfg.InteractionsKey {\n\t\tif errValidate := ValidateCredentialWeight(cfg.InteractionsKey[index].Weight); errValidate != nil {\n\t\t\treturn fmt.Errorf(\"interactions-api-key[%d].weight: %w\", index, errValidate)\n\t\t}\n\t}\n\tfor index := range cfg.ClaudeKey {\n\t\tif errValidate := ValidateCredentialWeight(cfg.ClaudeKey[index].Weight); errValidate != nil {\n\t\t\treturn fmt.Errorf(\"claude-api-key[%d].weight: %w\", index, errValidate)\n\t\t}\n\t}\n\tfor index := range cfg.VertexCompatAPIKey {\n\t\tif errValidate := ValidateCredentialWeight(cfg.VertexCompatAPIKey[index].Weight); errValidate != nil {\n\t\t\treturn fmt.Errorf(\"vertex-api-key[%d].weight: %w\", index, errValidate)\n\t\t}\n\t}\n\tfor index := range cfg.CodexKey {\n\t\tif errValidate := ValidateCredentialWeight(cfg.CodexKey[index].Weight); errValidate != nil {\n\t\t\treturn fmt.Errorf(\"codex-api-key[%d].weight: %w\", index, errValidate)\n\t\t}\n\t}\n\tfor index := range cfg.XAIKey {\n\t\tif errValidate := ValidateCredentialWeight(cfg.XAIKey[index].Weight); errValidate != nil {\n\t\t\treturn fmt.Errorf(\"xai-api-key[%d].weight: %w\", index, errValidate)\n\t\t}\n\t}\n\tfor providerIndex := range cfg.OpenAICompatibility {\n\t\tfor keyIndex := range cfg.OpenAICompatibility[providerIndex].APIKeyEntries {\n\t\t\tweight := cfg.OpenAICompatibility[providerIndex].APIKeyEntries[keyIndex].Weight\n\t\t\tif errValidate := ValidateCredentialWeight(weight); errValidate != nil {\n\t\t\t\treturn fmt.Errorf(\"openai-compatibility[%d].api-key-entries[%d].weight: %w\", providerIndex, keyIndex, errValidate)\n\t\t\t}","sourceCodeStart":113,"sourceCodeEnd":149,"githubUrl":"https://github.com/router-for-me/CLIProxyAPI/blob/78f0c4079e3e6273d65d03b5549cffc898703264/internal/config/weight.go#L113-L149","documentation":"Error \"vertex-api-key[%d].weight: %w\" thrown in router-for-me/CLIProxyAPI.","triggerScenarios":"Thrown at internal/config/weight.go:131 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Fix the weight of the reported vertex-api-key entry to a valid integer within bounds.","Check the wrapped error for the exact validation failure."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"78f0c4079e3e6273d65d03b5549cffc898703264","analyzedAt":"2026-08-15T12:26:37.444Z","schemaVersion":2},"datasetVersion":"2026-08-15T17:31:12.345Z"}