flowable/flowable-engine · error · FlowableIllegalArgumentException
IdentityId is required.
Error message
IdentityId is required.
What it means
validateIdentityLinkArguments requires a non-null identityId path variable identifying the user or group of the identity link. A null identityId throws FlowableIllegalArgumentException("IdentityId is required.").
Solutions
- Supply the user or group id in the identityId path segment.
- Validate the id is non-null before invoking the REST call.
- Check URL templates are fully interpolated.
Example fix
// before
call("/cmmn-runtime/case-instances/case-1/identitylinks/users//participant")
// after
call("/cmmn-runtime/case-instances/case-1/identitylinks/users/kermit/participant") Defensive patterns
Strategy: validation
Validate before calling
// Java
if (identityId == null || identityId.isEmpty()) {
throw new IllegalArgumentException("identityId is required");
} Prevention
- Assert URL template placeholders are filled
- Validate ids before building REST URLs
- Log the final URL before sending for debugging
When it happens
Trigger: GET or DELETE .../identitylinks/{family}/{identityId}/{type} with a missing/empty {identityId} path segment resolved to null by the caller.
Common situations: Template URLs left with unfilled placeholders; clients dropping the identity segment when building the URL programmatically.
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
- Type is required.
- A group or a user is required to create an identity link.
- Identity link family should be 'users' or 'groups'.
- IdentityId is required.
- Only one of user or group can be used to create an identity…
AI-assisted analysis of flowable/flowable-engine@d6d39ce1c6 (2026-09-11).
Data as JSON: /api/errors/d158b4684e2b5cc8.
Report an issue: GitHub.
Appendix: source
Thrown at modules/flowable-cmmn-rest/src/main/java/org/flowable/cmmn/rest/service/api/runtime/caze/CaseInstanceIdentityLinkResource.java:105
if (restApiInterceptor != null) {
restApiInterceptor.deleteCaseInstanceIdentityLink(caseInstance, link);
}
if (CmmnRestUrls.SEGMENT_IDENTITYLINKS_FAMILY_GROUPS.equals(family)) {
runtimeService.deleteGroupIdentityLink(caseInstance.getId(), identityId, type);
} else {
runtimeService.deleteUserIdentityLink(caseInstance.getId(), identityId, type);
}
}
protected void validateIdentityLinkArguments(String family, String identityId, String type) {
if (family == null || (!CmmnRestUrls.SEGMENT_IDENTITYLINKS_FAMILY_GROUPS.equals(family) && !CmmnRestUrls.SEGMENT_IDENTITYLINKS_FAMILY_USERS.equals(family))) {
throw new FlowableIllegalArgumentException("Identity link family should be 'users' or 'groups'.");
}
if (identityId == null) {
throw new FlowableIllegalArgumentException("IdentityId is required.");
}
if (type == null) {
throw new FlowableIllegalArgumentException("Type is required.");
}
}
protected IdentityLink getIdentityLink(String identityId, String family, String type, String caseInstanceId) {
// Perhaps it would be better to offer getting a single identity link
// from the API
List<IdentityLink> allLinks = runtimeService.getIdentityLinksForCaseInstance(caseInstanceId);
for (IdentityLink link : allLinks) {
if (CmmnRestUrls.SEGMENT_IDENTITYLINKS_FAMILY_USERS.equals(family) && identityId.equals(link.getUserId()) && link.getType().equals(type)) {
return link;
} else if (CmmnRestUrls.SEGMENT_IDENTITYLINKS_FAMILY_GROUPS.equals(family) && identityId.equals(link.getGroupId()) && link.getType().equals(type)) {
return link;
}
}View on GitHub (pinned to d6d39ce1c6)