appsmithorg/appsmith · error · AppsmithPluginException
PE-ARG-5000
PE-ARG-5000
Error message
request type is missing
What it means
Thrown at the top of AwsLambdaPlugin.trigger() when request.getRequestType() is null or blank. The trigger() method powers dynamic dropdown population in the editor (function names, function versions, function aliases). Without a request type the plugin cannot decide which list to fetch, so it refuses early with PLUGIN_EXECUTE_ARGUMENT_ERROR.
Source
Thrown at app/server/appsmith-plugins/awsLambdaPlugin/src/main/java/com/external/plugins/AwsLambdaPlugin.java:106
IllegalArgumentException.class,
e -> new AppsmithPluginException(
AppsmithPluginError.PLUGIN_ERROR, "Unsupported command: " + command))
.onErrorMap(
ResourceNotFoundException.class,
e -> new AppsmithPluginException(AppsmithPluginError.PLUGIN_ERROR, e.getErrorMessage()))
.onErrorMap(
Exception.class,
e -> new AppsmithPluginException(AppsmithPluginError.PLUGIN_ERROR, e.getMessage()))
.map(obj -> obj)
.subscribeOn(Schedulers.boundedElastic());
}
@Override
public Mono<TriggerResultDTO> trigger(
AWSLambda connection, DatasourceConfiguration datasourceConfiguration, TriggerRequestDTO request) {
log.debug(Thread.currentThread().getName() + ": trigger() called for AWS Lambda plugin.");
if (!StringUtils.hasText(request.getRequestType())) {
throw new AppsmithPluginException(
AppsmithPluginError.PLUGIN_EXECUTE_ARGUMENT_ERROR, "request type is missing");
}
String requestType = request.getRequestType();
ActionExecutionResult actionExecutionResult;
List<Map<String, String>> options;
Map<?, Object> params = request.getParameters() == null ? Map.of() : request.getParameters();
switch (requestType) {
case "FUNCTION_NAMES" -> {
actionExecutionResult = listFunctions(null, connection);
ArrayNode body = (ArrayNode) actionExecutionResult.getBody();
options = StreamSupport.stream(body.spliterator(), false)
.map(function -> function.get("functionName").asText())
.sorted()
.map(functionName -> Map.of("label", functionName, "value", functionName))
.collect(Collectors.toList());
}View on GitHub (pinned to 8cd9021c24)
Solutions
- Set request.setRequestType("FUNCTION_NAMES") (or FUNCTION_VERSIONS / FUNCTION_ALIASES) before calling trigger().
- If building TriggerRequestDTO from editor parameters, default to FUNCTION_NAMES when no sub-step has been chosen.
- Verify the request payload key name matches the TriggerRequestDTO.requestType field exactly.
Example fix
// before
TriggerRequestDTO request = new TriggerRequestDTO();
// requestType never set -> error
plugin.trigger(connection, dsConfig, request);
// after
TriggerRequestDTO request = new TriggerRequestDTO();
request.setRequestType("FUNCTION_NAMES");
plugin.trigger(connection, dsConfig, request); Defensive patterns
Strategy: validation
Validate before calling
if (!StringUtils.hasText(request.getRequestType())) {
throw new IllegalArgumentException(
"TriggerRequestDTO.requestType is required. Use FUNCTION_NAMES, FUNCTION_VERSIONS, or FUNCTION_ALIASES.");
} Try / catch
plugin.trigger(connection, dsConfig, request)
.onErrorResume(AppsmithPluginException.class, e -> {
if ("PE-ARG-5000".equals(e.getErrorDTO().getAppErrorCode())) {
return Mono.just(TriggerResultDTO.empty());
}
return Mono.error(e);
}); Prevention
- Always call request.setRequestType(...) before invoking trigger().
- Default to FUNCTION_NAMES when no sub-step has been chosen.
- Verify the request payload key maps to getRequestType() exactly.
When it happens
Trigger: trigger() is invoked with a TriggerRequestDTO whose requestType field is null or empty — for example the editor's dropdown refresh fired before a request type was assigned, or a programmatic call that constructed TriggerRequestDTO without calling setRequestType.
Common situations: A UI race where the dropdown request omits requestType; programmatic trigger calls that forgot to set the field; a deserialization mismatch where the JSON key for request type does not map to getRequestType().
Related errors
AI-assisted analysis of appsmithorg/appsmith@8cd9021c24 (2026-08-12).
Data as JSON: /api/errors/bac7da8c12e92a5b.
Report an issue: GitHub.