fix(routes): align whatsapp call ids

This commit is contained in:
2026-06-07 13:04:27 +08:00
parent 5062acec61
commit 7ea4bf9362
7 changed files with 53 additions and 51 deletions
@@ -70,12 +70,12 @@ func setupWhatsAppCallHandlerTest(t *testing.T) (*gin.Engine, *gorm.DB, *model.A
c.Set("user_id", uint(7))
c.Next()
})
router.GET("/api/v1/accounts/:account_id/whatsapp_calls/:call_id", handler.Show)
router.GET("/api/v1/accounts/:account_id/whatsapp_calls/:id", handler.Show)
router.POST("/api/v1/accounts/:account_id/whatsapp_calls/initiate", handler.Initiate)
router.POST("/api/v1/accounts/:account_id/whatsapp_calls/:call_id/accept", handler.Accept)
router.POST("/api/v1/accounts/:account_id/whatsapp_calls/:call_id/reject", handler.Reject)
router.POST("/api/v1/accounts/:account_id/whatsapp_calls/:call_id/terminate", handler.Terminate)
router.POST("/api/v1/accounts/:account_id/whatsapp_calls/:call_id/upload_recording", handler.UploadRecording)
router.POST("/api/v1/accounts/:account_id/whatsapp_calls/:id/accept", handler.Accept)
router.POST("/api/v1/accounts/:account_id/whatsapp_calls/:id/reject", handler.Reject)
router.POST("/api/v1/accounts/:account_id/whatsapp_calls/:id/terminate", handler.Terminate)
router.POST("/api/v1/accounts/:account_id/whatsapp_calls/:id/upload_recording", handler.UploadRecording)
return router, db, account, conversation
}