Files
services/examples/twitter/trends/go/getTheCurrentGlobalTrendingTopics.go
2021-09-21 16:36:39 +01:00

15 lines
336 B
Go
Executable File

package example
import (
"fmt"
"github.com/micro/services/clients/go/twitter"
"os"
)
// Get the current global trending topics
func GetTheCurrentGlobalTrendingTopics() {
twitterService := twitter.NewTwitterService(os.Getenv("MICRO_API_TOKEN"))
rsp, err := twitterService.Trends(&twitter.TrendsRequest{})
fmt.Println(rsp, err)
}