I am new to ScriptRunner Behaviors in Cloud. I want to see if there is a way to set a form message on a custom field, like I was able to do DC version of Behaviors. The setError method is recognized in Behaviors for Cloud.
Hi David,
Unfortunately, in Jira Cloud the Behaviours module does not provide setError() function so this means your use case cannot be achieved.
The reason for this is that Behaviours in Jira Cloud uses the UI Modifications API from Atlassian, which does not provide a setError() method.
You can see what methods the cloud version provides here for reference. The closest workaround would be to use setDescription() method to add some text to indicate an error.
I hope this helps.
Regards,
Kristian
Since in Jira Cloud the Behaviours module does not provide setError() function and you are trying to guide users (not only block them), another approach you might consider is using Smart Forms for Jira (my team’s app) for the input step and then mapping the answers back to Jira:
Put guidance right next to questions with Description(describe your field) and Help text(appear on hover) on each form element
Add richer instructions (or visuals) with a Content text box or Embedded content (images/video) so users see examples before they type
Use Conditional logic to show/hide whole blocks only when relevant (keeps forms short and clear).
If you do need hard validation, add Regex rules with custom error messages on text fields (e.g., email, ID format, numeric ranges) — this behaves a lot like setError()
but is configured on the form and shows a concise, user‑friendly message.
After submit, map responses to Jira fields or create the issue so your normal workflow continues as usual.
For a friendly post‑submit note (e.g., “Thanks, we’ll review within 1 business day”), set a custom submission message with form elements values once the form is sent.
Quick example (mirrors a Behaviors-style rule):
Field: “Employee ID” (Single-line text)
Regex: ^[A-Z]{3}-\d{4}$
Error message: “Use format ABC‑1234 (3 letters, dash, 4 digits).”
This enforces the pattern and shows the custom message if it doesn’t match.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.