mirror of
https://github.com/trafficlunar/api.git
synced 2026-06-27 22:24:08 +00:00
feat: github projects route
This commit is contained in:
parent
a1f22391e9
commit
a3eb6c6e32
7 changed files with 115 additions and 0 deletions
12
internal/handler/github.go
Normal file
12
internal/handler/github.go
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
package handler
|
||||
|
||||
import (
|
||||
"api/internal/worker"
|
||||
"encoding/json"
|
||||
"net/http"
|
||||
)
|
||||
|
||||
func HandleGetProjects(w http.ResponseWriter, r *http.Request) {
|
||||
w.Header().Set("Content-Type", "application/json")
|
||||
json.NewEncoder(w).Encode(worker.GitHubData)
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue