Skip to content

[OTHER]πŸ“¦ Add Product Management APIs (CRUD) – BackendΒ #180

@shreesriv12

Description

@shreesriv12

πŸ“ Other Issue

Description
Provide a clear and concise description of the issue or topic.
We need to implement the backend API endpoints to manage products in the StyleCart store. This includes creating the schema/model for products, and implementing standard CRUD operations.


Type of Issue
Select the type of issue:

  • πŸ“„ Documentation
  • πŸ› οΈ Build/Deployment
  • πŸ–ΌοΈ UI/UX Design
  • βš™οΈ Performance
  • Other (please specify)

Tasks
Create a Mongoose Product Schema
Fields: name, brand, price, description, category, image, stock, rating, reviews
Save it as models/Product.js
Create API Routes in Express

GET /products β†’ List all products

GET /products/:id β†’ Get product by ID

POST /products β†’ Add new product (admin only)

PUT /products/:id β†’ Update existing product

DELETE /products/:id β†’ Delete product by ID

Additional Context
Add any other context, suggestions, or relevant details regarding the issue.


Checklist

  • I have searched the existing issues, and this issue is not a duplicate.
  • I have starred this repository.
  • I have provided all necessary details.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions