Strapi Create Content With Open AI & Gemini
npm install ai-content-creator
npm i ai-content-creator
config/plugins.js file.
javascript
// config/plugins.js (or similar configuration file)
module.exports = ({ env }) => {
return {
'ai-content-creator': {
enabled: true,
// The 'resolve' path is typically only required when the plugin is installed locally.
// resolve: './src/plugins/ai-content-creator',
config: {
openAi:{
enabled: true,
apiKey: env("OPEN_AI_KEY", ""), // Fetches API key from an Environment Variable
contentList:["api::webpage.webpage"] // Specifies the Content Types where the plugin's UI should be visible
// OR
contentList:[] // leave it empty if you want the plugin's UI visible in all pages
},
gemini:{
enabled: true,
apiKey: env("GEMINI_AI_KEY", ""), // Fetches API key from an Environment Variable
contentList:["api::webpage.webpage"] // Specifies the Content Types where the plugin's UI should be visible
// OR
contentList:[] // leave it empty if you want the plugin's UI visible in all pages
}
},
},
}
};
``