- Use Node 20+
npm install
- Run without iitm using
npm run start
, observe OpenAI make the request (even though it fails because of auth) - Run with iitm using
npm run start:iitm
, observe TypeError: getDefaultAgent is not a function:
TypeError: getDefaultAgent is not a function
at OpenAI.buildRequest (./iitm-openai/node_modules/openai/core.mjs:208:66)
at OpenAI.makeRequest (./iitm-openai/node_modules/openai/core.mjs:279:44)
at async doWork (./iitm-openai/src/index.mjs:8:20)