summaryrefslogtreecommitdiff
path: root/system/api/server.go
blob: f8c9ba9036a9545295c1bf60f86a94174a6be08d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
package api

import "net/http"

// Run adds Handlers to default http listener for API
func Run() {
	http.HandleFunc("/api/types", Record((CORS(typesHandler))))

	http.HandleFunc("/api/contents", Record((CORS(contentsHandler))))

	http.HandleFunc("/api/content", Record((CORS(contentHandler))))

	http.HandleFunc("/api/content/external", Record((CORS(externalContentHandler))))
}