mirror of
https://github.com/kevin-DL/services.git
synced 2026-01-15 04:24:44 +00:00
19 lines
301 B
Go
Executable File
19 lines
301 B
Go
Executable File
package example
|
|
|
|
import (
|
|
"fmt"
|
|
"os"
|
|
|
|
"github.com/micro/services/clients/go/gifs"
|
|
)
|
|
|
|
// Search for a GIF
|
|
func Search() {
|
|
gifsService := gifs.NewGifsService(os.Getenv("MICRO_API_TOKEN"))
|
|
rsp, err := gifsService.Search(&gifs.SearchRequest{
|
|
Limit: 2,
|
|
Query: "dogs",
|
|
})
|
|
fmt.Println(rsp, err)
|
|
}
|