package controllers import ( "encoding/json" "github.com/geplauder/lithium/pipelines" "github.com/geplauder/lithium/storage" "net/http" ) func PipelineHandler(pipeline pipelines.IPipeline, storageProvider storage.IStorageProvider, w http.ResponseWriter, r *http.Request) { w.Header().Set("Content-Type", "application/json") err := json.NewEncoder(w).Encode(pipeline) if err != nil { w.WriteHeader(http.StatusInternalServerError) } }