Bump routes v4 -> v5
Remplacer références GetV4 -> GetHealth Ajouter package responses Remplacer handlers.GetHealthResponse -> responses.GetHealth
This commit is contained in:
parent
9ac95672b9
commit
764093f99d
5 changed files with 20 additions and 17 deletions
12
cmd/api.go
12
cmd/api.go
|
@ -41,17 +41,17 @@ var apiCmd = &cobra.Command{
|
|||
|
||||
// Routes
|
||||
|
||||
e.GET("/v4/health/", handlers.GetHealth)
|
||||
e.GET("/v5/health/", handlers.GetHealth)
|
||||
|
||||
e.POST("/v4/membres/", handlers.PostMembres)
|
||||
e.POST("/v5/membres/", handlers.PostMembres)
|
||||
|
||||
e.GET("/v4/membres/:membre_id/", handlers.ReadMembre)
|
||||
e.GET("/v5/membres/:membre_id/", handlers.ReadMembre)
|
||||
|
||||
e.PUT("/v4/membres/:membre_id/prefered_name/", handlers.PutMembrePreferedName)
|
||||
e.PUT("/v5/membres/:membre_id/prefered_name/", handlers.PutMembrePreferedName)
|
||||
|
||||
e.POST("/v4/programmes/", handlers.PostProgrammes)
|
||||
e.POST("/v5/programmes/", handlers.PostProgrammes)
|
||||
|
||||
e.POST("/v4/seed/", handlers.PostSeed)
|
||||
e.POST("/v5/seed/", handlers.PostSeed)
|
||||
|
||||
// Execution
|
||||
|
||||
|
|
|
@ -55,7 +55,7 @@ var webCmd = &cobra.Command{
|
|||
|
||||
apiClient := data.NewApiClient(webApiKey, webApiHost, webApiProtocol, webApiPort)
|
||||
|
||||
pingResult, err := apiClient.GetV4()
|
||||
pingResult, err := apiClient.GetHealth()
|
||||
if err != nil {
|
||||
log.Fatal(err)
|
||||
}
|
||||
|
|
Reference in a new issue