The issue was solved by upgrading @azure/functions to a version >=4.3.0. The root cause is the same as the issue Cannot read properties of undefined (reading 'type'). The issue was fixed with Fix out-of-sync binding names causing null ref error and released with 4.3.0 of the npm package.