flowable/flowable-engine · error · FlowableIllegalArgumentException
Decision key is required.
Error message
Decision key is required.
What it means
REST request validation in DmnRuleServiceResource.execute: the execute-decision request body did not include a decision key (and no table/definition identifier), so the DMN rule service cannot determine which decision to evaluate.
Solutions
- Include "decisionKey" in the JSON request body.
- Validate the request payload on the client before sending.
- Check client serialization is not omitting the field (e.g. null-skipping serializers with a null value).
- Catch the 400 response and inspect the error message to confirm which field is missing.
Example fix
// before
POST /dmn-rule/execute {"inputVariables": {"a": 1}}
// after
POST /dmn-rule/execute {"decisionKey": "myDecision", "inputVariables": {"a": 1}} Defensive patterns
Strategy: validation
Validate before calling
if (request.getDecisionKey() == null || request.getDecisionKey().isEmpty()) {
throw new IllegalArgumentException("decisionKey is required");
} Try / catch
try {
ResponseEntity<DmnRuleServiceResponse> resp = rest.postForEntity(url, request, DmnRuleServiceResponse.class);
} catch (HttpClientErrorException.BadRequest e) {
logger.error("decisionKey missing: {}", e.getResponseBodyAsString());
} Prevention
- Always set decisionKey in execute requests
- Add client-side payload validation before posting
- Verify serializers do not drop the field
When it happens
Trigger: POSTing JSON to /dmn-rule/execute without a decisionKey field, or with decisionKey explicitly set to null.
Common situations: Client payloads missing the field due to serialization settings skipping nulls/defaults; renaming the property in the client while the server expects decisionKey; copy-pasted request templates from other endpoints.
Understand the failure class
Background: "missing required argument" and "the following required arguments were not provided": what required-argument errors mean and how to fix them — this error's family across 20 libraries.
Related errors
- Either caseDefinitionId or caseDefinitionKey is required.
- Variable ' ' has unsupported type: ' '.
- A group or a user is required to create an identity link.
- A group or a user is required to create an identity link.
- A group or a user is required to create an identity link.
AI-assisted analysis of flowable/flowable-engine@d6d39ce1c6 (2026-09-11).
Data as JSON: /api/errors/695819d21ca60ddf.
Report an issue: GitHub.
Appendix: source
Thrown at modules/flowable-dmn-rest/src/main/java/org/flowable/dmn/rest/service/api/decision/DmnRuleServiceResource.java:67
@Autowired
protected DmnRestResponseFactory dmnRestResponseFactory;
@Autowired
protected DmnDecisionService dmnDecisionService;
@Autowired(required = false)
protected DmnRestApiInterceptor restApiInterceptor;
@ApiOperation(value = "Execute a Decision", tags = { "DMN Rule Service" }, code = 201)
@ApiResponses(value = {
@ApiResponse(code = 201, message = "Indicates the Decision has been executed")
})
@PostMapping(value = "/dmn-rule/execute", produces = "application/json")
@ResponseStatus(HttpStatus.CREATED)
public DmnRuleServiceResponse execute(@ApiParam("request") @RequestBody DmnRuleServiceRequest request) {
if (request.getDecisionKey() == null) {
throw new FlowableIllegalArgumentException("Decision key is required.");
}
if (restApiInterceptor != null) {
restApiInterceptor.executeDecision(request);
}
Map<String, Object> inputVariables = composeInputVariables(request.getInputVariables());
try {
ExecuteDecisionBuilder decisionBuilder = dmnDecisionService.createExecuteDecisionBuilder();
decisionBuilder.decisionKey(request.getDecisionKey()).variables(inputVariables);
if (StringUtils.isNotEmpty(request.getParentDeploymentId())) {
decisionBuilder.parentDeploymentId(request.getParentDeploymentId());
}
if (StringUtils.isNotEmpty(request.getTenantId())) {
decisionBuilder.tenantId(request.getTenantId());View on GitHub (pinned to d6d39ce1c6)