feat: move V1DocumentPOST route declaration to pave

This commit is contained in:
Victor Lacasse-Beaudoin 2023-11-20 16:34:19 -05:00
parent c65cf4a211
commit c7282edcc2

View file

@ -242,7 +242,11 @@ func RunServer() {
log.Fatal(err) log.Fatal(err)
} }
groupV1.POST("/bucket/:bucket", v1Handler.V1DocumentPOST) if err := pave.EchoRegister[
apirequest.V1DocumentPOST,
apiresponse.V1DocumentPOST](groupV1, &p, "/v1", http.MethodPost, "/bucket/:bucket", "Upload document to specified bucket", "V1DocumentPOST", v1Handler.V1DocumentPOST); err != nil {
log.Fatal(err)
}
groupV1.GET("/bucket/:bucket/:document", v1Handler.V1DocumentGET) groupV1.GET("/bucket/:bucket/:document", v1Handler.V1DocumentGET)