added delete contact route
This commit is contained in:
@@ -12,10 +12,15 @@ func SetupRoutes(app *fiber.App) {
|
||||
return c.SendString("Hello, World!")
|
||||
})
|
||||
api := app.Group("/api", logger.New())
|
||||
chat := api.Group("/chat", middleware.Protected(), logger.New())
|
||||
|
||||
// Auth group
|
||||
auth := api.Group("/auth", middleware.Protected(), handlers.ValidateToken)
|
||||
auth.Post("/signup", handlers.Signup)
|
||||
auth.Post("/login", handlers.Login)
|
||||
auth.Get("/validate", handlers.ValidateToken)
|
||||
|
||||
// Contacts group
|
||||
contacts := chat.Group("/contacts", middleware.Protected(), logger.New())
|
||||
contacts.Delete("/:contact_id/:conversation_id", handlers.DeleteContact)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user