diff --git a/core/src/main/java/io/kestra/core/docs/JsonSchemaGenerator.java b/core/src/main/java/io/kestra/core/docs/JsonSchemaGenerator.java index 7e8df297b0c..58801a563e2 100644 --- a/core/src/main/java/io/kestra/core/docs/JsonSchemaGenerator.java +++ b/core/src/main/java/io/kestra/core/docs/JsonSchemaGenerator.java @@ -16,6 +16,7 @@ import com.github.victools.jsonschema.module.jakarta.validation.JakartaValidationOption; import com.github.victools.jsonschema.module.swagger2.Swagger2Module; import com.google.common.collect.ImmutableMap; +import io.kestra.core.models.property.Data; import io.kestra.core.models.property.Property; import io.kestra.core.models.annotations.Plugin; import io.kestra.core.models.annotations.PluginProperty; @@ -277,6 +278,8 @@ public CustomDefinition provideCustomSchemaDefinition(ResolvedType javaType, Sch if (!String.class.isAssignableFrom(targetType) && String.class.isAssignableFrom(member.getType().getErasedType())) { memberAttributes.put("pattern", ".*{{.*}}.*"); } + } else if (member.getDeclaredType().isInstanceOf(Data.class)) { + memberAttributes.put("$dynamic", false); } });