summaryrefslogtreecommitdiff
path: root/internal/api/api.go
diff options
context:
space:
mode:
authorGravatar Pontus Jensen Karlsson <wolfhechel@users.noreply.github.com> 2024-08-18 20:53:19 +0200
committerGravatar GitHub <noreply@github.com> 2024-08-18 11:53:19 -0700
commit810b3517725b7e1c4f66ec9e40400bf1d1cf24dd (patch)
tree90586698031cb913a44f487641aca4081d120c8c /internal/api/api.go
parent89ff33ddd0125782ee6dbe075a3e21c0eacda15e (diff)
downloadv2-810b3517725b7e1c4f66ec9e40400bf1d1cf24dd.tar.gz
v2-810b3517725b7e1c4f66ec9e40400bf1d1cf24dd.tar.zst
v2-810b3517725b7e1c4f66ec9e40400bf1d1cf24dd.zip
feat: add API routes `/v1/enclosures/{enclosureID}`
Diffstat (limited to 'internal/api/api.go')
-rw-r--r--internal/api/api.go2
1 files changed, 2 insertions, 0 deletions
diff --git a/internal/api/api.go b/internal/api/api.go
index 2963a990..1109acda 100644
--- a/internal/api/api.go
+++ b/internal/api/api.go
@@ -72,6 +72,8 @@ func Serve(router *mux.Router, store *storage.Storage, pool *worker.Pool) {
sr.HandleFunc("/entries/{entryID}/fetch-content", handler.fetchContent).Methods(http.MethodGet)
sr.HandleFunc("/flush-history", handler.flushHistory).Methods(http.MethodPut, http.MethodDelete)
sr.HandleFunc("/icons/{iconID}", handler.getIconByIconID).Methods(http.MethodGet)
+ sr.HandleFunc("/enclosures/{enclosureID}", handler.getEnclosureById).Methods(http.MethodGet)
+ sr.HandleFunc("/enclosures/{enclosureID}", handler.updateEnclosureById).Methods(http.MethodPut)
sr.HandleFunc("/version", handler.versionHandler).Methods(http.MethodGet)
}