From ff3e81145749b8b1db06e861f44a728e21ed6195 Mon Sep 17 00:00:00 2001 From: Victor Lacasse-Beaudoin Date: Mon, 18 Dec 2023 17:46:31 -0500 Subject: [PATCH] feat: Ajouter route `/bucket/:bucket/many` pour `V1DocumentsPOST` MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Nécessite plus de travail sur les fonctions sous-jacentes, mais la route devrait au moins maintenant exister. Sera éventuellement utilisée pour remplacer `/bucket/:bucket`. TODO Tests nécessaires. --- cmd/server.go | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/cmd/server.go b/cmd/server.go index 5f61cd0..fc7f54b 100644 --- a/cmd/server.go +++ b/cmd/server.go @@ -242,6 +242,12 @@ func RunServer() { log.Fatal(err) } + if err := pave.EchoRegister[ + apirequest.V1DocumentsPOST, + apiresponse.V1DocumentsPOST](groupV1, &p, "/v1", http.MethodPost, "/bucket/:bucket/many", "Upload documents to specified bucket", "V1DocumentsPOST", v1Handler.V1DocumentsPOST); err != nil { + log.Fatal(err) + } + 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 {