Help needed: Jira Expression Validator Forge App – manifest errors with CLI 12.6.1

Hi all,

I’m trying to create a generic Jira Expression Validator using Forge for Jira Cloud (CLI v12.6.1, Manifest v2). The goal is to allow workflow transitions only if a Jira Expression evaluates to true.

Here’s what we’ve done so far:
1. Manifest setup (attempt 1)

modules:
jira:workflowValidator:
- key: jira-expression-validator
function: main
name: Jira Expression Validator
description: Generic Jira Expression Validator
parameters:
- key: expression
type: string
required: true
functions:

  • key: main
    handler: index.run
    permissions:
    scopes:
    • read:jira-work
      app:
      runtime:
      name: nodejs22.x

Error received:

document should NOT have additional property ‘functions’

2.	**Manifest attempt using resolver.endpoint + resources**

modules:
jira:workflowValidator:
- key: jira-expression-validator
resolver:
endpoint: main
name: Jira Expression Validator
description: Generic Jira Expression Validator
parameters:
- key: expression
type: string
required: true
resources:

  • key: main
    path: src/index.js
    permissions:
    scopes:
    • read:jira-work
    • read:jira-user
      app:
      runtime:
      name: nodejs22.x

Errors received:

jira:workflowValidator references undefined endpoint module with key ‘main’
jira:workflowValidator module ‘jira-expression-validator’ must have either a function or expression
C:\…\index.js: POST /rest/api/3/expression/eval requires “read:jira-user” scope

3.	**JS handler** (index.js) exports run exactly as per the documentation:

import api, { route } from “@forge/api”;
export const run = async ({ issue, configuration }) => { … }

4.	**Changes we’ve tried to fix the errors so far:**
•	Removed any functions: block, as it’s deprecated in CLI v12.6.1
•	Added read:jira-user scope for expression evaluation
•	Ensured resolver.endpoint matches resources.key exactly
•	Verified index.js exports run

Current problem:
Even after all these fixes, the validator in Jira still shows:

jira:workflowValidator references undefined endpoint module with key ‘main’
jira:workflowValidator module ‘jira-expression-validator’ must have either a function or expression

We are confident that the index.js exports the run function correctly, and that the scopes are sufficient.

Questions:
1. Are there any additional requirements for manifest v2 validators using the resolver.endpoint approach?
2. Should the JS resource export a specific named function, or is run always sufficient?
3. Has anyone successfully implemented a generic Jira Expression Validator in Forge CLI ≥12.6.1? If so, could you share a minimal working manifest + JS example?

Any guidance or reference to a working example would be highly appreciated.

Thanks in Advance,