The Image Generator is a web application designed to simplify the process of creating images using advanced technologies, including OpenAI's image generation API. This tool provides a user-friendly interface for generating a wide range of images based on your input.
- Intuitive Interface: The application boasts a simple and intuitive interface, making it accessible to users of all skill levels.
- Image Gallery: Browse through a gallery of images previously generated by users, offering inspiration and creative ideas.
- Custom Prompt Generation: Users can input their desired prompt, triggering the image generation process tailored to their specifications.
- Real-Time Generation: With the click of a button, images are generated in real-time using the powerful OpenAI API, ensuring quick and seamless results.
- Share and Download: Once generated, users have the option to share their creations with the community or download them for personal use.
- Clone the repository:
git clone https://github.com/ksaxena149/dalleclone.git
- Navigate to the project server directory:
cd dalleclone/server
- Install dependencies:
npm install
- Navigate to project client directory
cd dalleclone/client
- Install dependencies:
npm install
- Set up environment variables:
- Create a
.env
file in thecd dalleclone/server
directory. - Copy the following code into
.env
file and change the values to your own keys.
- Create a
OPENAI_API_KEY = "your_api_key"
MONGODB_URL="mongodb_url"
CLOUDINARY_CLOUD_NAME=""
CLOUDINARY_API_KEY=""
CLOUDINARY_API_SECRET=""
- Start the server:
nodemon index.js
- Navigate to client project directory
cd dalleclone/client
- Start the client:
npm run dev
- Visit
http://localhost:3000
in your browser to access the application.
- Explore the home page to view a gallery of previously generated images.
- Navigate to the image generation page to create your own image.
- Fill in the required fields (Name, Prompt) and click on the "Generate Image" button.
- Once the image is generated, it will be displayed in the placeholder.
- Share your creation with the community or download it for personal use.