Node-RED node to access the ChatGPT API
Run the following command in your Node-RED user directory - typically ~/.node-red
npm install node-red-contrib-chatgpt
- Get the API key from the OpenAI API portal (https://platform.openai.com/account/api-keys)
- Add the API key to the ChatGPT node property
- Pass the text via
msg.payload
to the ChatGPT node
And then the ChatGPT node will output the answer.