Skip to main content
New Participant
Jun 28, 2021 9:55 AM UTC
Question

Expression may not be longer than 4,000 characters. You have entered 6,811 characters

Hi,

I have created a Process Model with Start a Process Template. My Process Model has around 58 Process Variabes but through WEBApi when i try to pass those details, Web Api Throws an error like

​

"Expression may not be longer than 4,000 characters. You have entered 6,811 characters."

​

what can be done to overcome this?

Thanks,

Sakthi S.

7 replies

gayathris111098
Inspiring
Jun 28, 2021 11:12 AM UTC

Hi, where is this error coming? When you test or in actual process calling?

stefanhelzle0001
Brainy
Jun 28, 2021 11:14 AM UTC

Assuming that you have an incoming JSON data structure, why not pass that into the process?

Another option is to pass the JSON into a separate expression which maps that into a dictionary containing all your process parameters. Then use this expression inside a!startProcess.

davel001150
Inspiring
Jun 28, 2021 11:59 AM UTC

I was mistaken.

stefanhelzle0001
Brainy
Jun 28, 2021 12:00 PM UTC

The expression editor for web APIs is limited to 4k characters of actual expression code.

davel001150
Inspiring
Jun 28, 2021 12:03 PM UTC

Ah, thank you for that.  Yes, reading the error more clearly that's what it's saying.

Disregard what I posted earlier; you'll simply have to get what you want with fewer lines of code.