diff options
Diffstat (limited to 'main.go')
-rw-r--r-- | main.go | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/main.go b/main.go index 9cc1337..453426a 100644 --- a/main.go +++ b/main.go @@ -22,7 +22,9 @@ func main() { index.HandleFunc("/", indexHandler) api.HandleFunc("/", apiBaseHandler) api.HandleFunc("/{format:(?:plain)}", apiFormatHandler) - api.HandleFunc("/{format:(?:plain)}/{endpoint:(?:mentions|users|tweets)}", apiEndpointHandler) + api.Path("/{format:(?:plain)}/{endpoint:(?:mentions|users|tweets)}"). + Queries("url", "{url}", "q", "{query}", "nickname", "{nickname}"). + HandlerFunc(apiEndpointHandler) api.HandleFunc("/{format:(?:plain)}/tags", apiTagsBaseHandler) api.HandleFunc("/{format:(?:plain)}/tags/{tags:[a-zA-Z0-9]+}", apiTagsHandler) |