From aafc63933a7e213261e28ac7f528cea50b70e1af Mon Sep 17 00:00:00 2001 From: Saturnino Abril Date: Tue, 14 Mar 2017 06:13:48 +0900 Subject: APIv4: GET /files/{file_id}/public (#5665) --- api4/api.go | 3 +++ 1 file changed, 3 insertions(+) (limited to 'api4/api.go') diff --git a/api4/api.go b/api4/api.go index d5a44731f..29986f551 100644 --- a/api4/api.go +++ b/api4/api.go @@ -49,6 +49,8 @@ type Routes struct { Files *mux.Router // 'api/v4/files' File *mux.Router // 'api/v4/files/{file_id:[A-Za-z0-9]+}' + PublicFile *mux.Router // 'files/{file_id:[A-Za-z0-9]+}/public' + Commands *mux.Router // 'api/v4/commands' Command *mux.Router // 'api/v4/commands/{command_id:[A-Za-z0-9]+}' CommandsForTeam *mux.Router // 'api/v4/teams/{team_id:[A-Za-z0-9]+}/commands' @@ -120,6 +122,7 @@ func InitApi(full bool) { BaseRoutes.Files = BaseRoutes.ApiRoot.PathPrefix("/files").Subrouter() BaseRoutes.File = BaseRoutes.Files.PathPrefix("/{file_id:[A-Za-z0-9]+}").Subrouter() + BaseRoutes.PublicFile = BaseRoutes.Root.PathPrefix("/files/{file_id:[A-Za-z0-9]+}/public").Subrouter() BaseRoutes.Commands = BaseRoutes.ApiRoot.PathPrefix("/commands").Subrouter() BaseRoutes.Command = BaseRoutes.Commands.PathPrefix("/{command_id:[A-Za-z0-9]+}").Subrouter() -- cgit v1.2.3-1-g7c22