{"record":{"id":"42a40f2211b1e167","repo":"floci-io/floci","slug":"validationexception-42a40f","errorCode":"ValidationException","errorMessage":"Unsupported GroupBy.Type: {}","messagePattern":"Unsupported GroupBy\\.Type: (.+?)","errorType":"error_code","errorClass":"AwsException","httpStatus":400,"severity":"error","filePath":"src/main/java/io/github/hectorvent/floci/services/ce/GroupAggregator.java","lineNumber":101,"sourceCode":"                mv.put(\"Amount\", formatAmount(me.getValue()));\n                mv.put(\"Unit\", groupUnits.get(entry.getKey()).getOrDefault(me.getKey(), \"\"));\n            }\n        }\n        result.put(\"Estimated\", false);\n        return result;\n    }\n\n    private static List<String> groupKey(List<GroupBy> groupBys, UsageLine line) {\n        List<String> out = new ArrayList<>(groupBys.size());\n        for (GroupBy gb : groupBys) {\n            out.add(switch (gb.type()) {\n                case \"DIMENSION\" -> {\n                    String v = FilterExpressionEvaluator.dimensionValue(gb.key(), line);\n                    yield v == null ? \"\" : v;\n                }\n                case \"TAG\" -> line.tags() == null ? \"\" : line.tags().getOrDefault(gb.key(), \"\");\n                case \"COST_CATEGORY\" -> \"\";\n                default -> throw new AwsException(\"ValidationException\",\n                        \"Unsupported GroupBy.Type: \" + gb.type(), 400);\n            });\n        }\n        return out;\n    }\n\n    static List<GroupBy> parseGroupBy(JsonNode node) {\n        List<GroupBy> out = new ArrayList<>();\n        if (!node.isArray()) {\n            return out;\n        }\n        for (JsonNode entry : node) {\n            String type = entry.path(\"Type\").asText(\"DIMENSION\");\n            String key = entry.path(\"Key\").asText(null);\n            if (key == null || key.isEmpty()) {\n                throw new AwsException(\"ValidationException\",\n                        \"GroupBy entries must include a Key.\", 400);\n            }","sourceCodeStart":83,"sourceCodeEnd":119,"githubUrl":"https://github.com/floci-io/floci/blob/62ff490619e7bd3554597c28c704081b4c15add5/src/main/java/io/github/hectorvent/floci/services/ce/GroupAggregator.java#L83-L119","documentation":"Error \"Unsupported GroupBy.Type: {}\" thrown in floci-io/floci.","triggerScenarios":"Thrown at src/main/java/io/github/hectorvent/floci/services/ce/GroupAggregator.java:101 when the library encounters an invalid state.","commonSituations":"Occurs when a GetCostAndUsage request uses a GroupBy type other than DIMENSION or TAG. Use Type=DIMENSION with a supported Key, or Type=TAG.","solutions":["Use a supported GroupBy.Type such as DIMENSION or TAG.","Check the GetCostAndUsage GroupBy parameter in the request."],"exampleFix":null,"handlingStrategy":null,"validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"62ff490619e7bd3554597c28c704081b4c15add5","analyzedAt":"2026-08-14T14:25:23.764Z","schemaVersion":2},"datasetVersion":"2026-08-15T22:17:37.221Z"}