NovuN
Novu13mo ago
iStun4Fun

Novu @ Next 13.4.8

Hey! Its possible to run a dev instance in the same instance that our project is? we are working on a Next 13.4.8 project and found that we need to create a totally different app to run in dev to work. I can create an endpoint tunnel for the bridging endpoint but.. couldnt we use the workflows and serve on the same app instead of creating a third app in the dev server? Maybe is how we have config the nextJs?

we are receiving this bug in a pages/api setup when going to /api/novu:

Server Error
SyntaxError: Named export 'checkIsResponseError' not found. The requested module '@novu/shared' is a CommonJS module, which may not support all module.exports as named exports.
CommonJS modules can always be imported via the default export, for example using:

import pkg from '@novu/shared';
...

Here is the endpoint content and created it in the way that documentation told us:

// pages/api/novu.ts
import { serve } from '@novu/framework/next';
import { contractsUpdate, progressUpdate } from '@/novu/workflows';

export default serve({ workflows: [contractsUpdate, progressUpdate] });
Was this page helpful?