{"record":{"id":"e46268d09712eecf","repo":"floci-io/floci","slug":"requesttokennotfoundexception","errorCode":"RequestTokenNotFoundException","errorMessage":"RequestToken is required.","messagePattern":"RequestToken is required\\.","errorType":"error_code","errorClass":"AwsException","httpStatus":404,"severity":"error","filePath":"src/main/java/io/github/hectorvent/floci/services/cloudcontrol/CloudControlJsonHandler.java","lineNumber":88,"sourceCode":"     * InvalidRequestException is the code Cloud Control declares for a malformed request, so it is\n     * what an SDK maps onto a typed exception. ValidationException is not in the service model.\n     */\n    private String required(JsonNode request, String field) {\n        String value = request.path(field).asText(null);\n        if (value == null || value.isBlank()) {\n            throw new AwsException(\"InvalidRequestException\", field + \" is required.\", 400);\n        }\n        return value;\n    }\n\n    /**\n     * GetResourceRequestStatus declares only RequestTokenNotFoundException, so an absent token\n     * reports that rather than the InvalidRequestException the other operations declare.\n     */\n    private String requestToken(JsonNode request) {\n        String value = request.path(\"RequestToken\").asText(null);\n        if (value == null || value.isBlank()) {\n            throw new AwsException(\"RequestTokenNotFoundException\", \"RequestToken is required.\", 404);\n        }\n        return value;\n    }\n\n    private Response listResources(JsonNode request, String region) {\n        String typeName = required(request, \"TypeName\");\n        ObjectNode response = mapper.createObjectNode();\n        response.put(\"TypeName\", typeName);\n        ArrayNode resources = response.putArray(\"ResourceDescriptions\");\n        for (CloudControlService.ResourceDescription resource : service.listResources(region, typeName)) {\n            ObjectNode node = mapper.createObjectNode();\n            node.put(\"Identifier\", resource.identifier());\n            node.put(\"Properties\", resource.properties());\n            resources.add(node);\n        }\n        return Response.ok(response).build();\n    }\n}","sourceCodeStart":70,"sourceCodeEnd":106,"githubUrl":"https://github.com/floci-io/floci/blob/62ff490619e7bd3554597c28c704081b4c15add5/src/main/java/io/github/hectorvent/floci/services/cloudcontrol/CloudControlJsonHandler.java#L70-L106","documentation":"Error \"RequestToken is required.\" thrown in floci-io/floci.","triggerScenarios":"Thrown at src/main/java/io/github/hectorvent/floci/services/cloudcontrol/CloudControlJsonHandler.java:88 when the library encounters an invalid state.","commonSituations":"Occurs when a CloudControl mutating request omits RequestToken. Provide a unique client request token for idempotency.","solutions":["Provide a unique RequestToken (client token) for the operation."],"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-15T17:31:12.345Z"}