code:
info, code, err := c.service.GetInfoFromURL("https://imgur.com/gallery/t6l1GiW")
fmt.Printf("info[%d]: %+v err: %+v\n", code, info, err)
output:
[22/Apr/2020:19:13:45 +0000] INFO 2020/04/22 19:13:45 Debug: Detected imgur gallery ID t6l1GiW. Was going down the imgur.com/gallery/ path.
[22/Apr/2020:19:13:45 +0000] INFO 2020/04/22 19:13:45 Info: Requesting URL https://api.imgur.com/3/gallery/image/t6l1GiW
info[-1]: &{Image:<nil> Album:<nil> GImage:<nil> GAlbum:<nil> Limit:<nil>} err: Problem getting URL for gallery image info ID t6l1GiW - HTTP status indicates an error for https://api.imgur.com/3/gallery/image/t6l1GiW - 404 Not Found
code:
giinfo, code, err := c.service.GetGalleryImageInfo("t6l1GiW")
fmt.Printf("giinfo[%d]: %+v err: %+v\n", code, giinfo, err)
output:
[22/Apr/2020:19:13:45 +0000] INFO 2020/04/22 19:13:45 Info: Requesting URL https://api.imgur.com/3/gallery/image/t6l1GiW
giinfo[-1]: <nil> err: Problem getting URL for gallery image info ID t6l1GiW - HTTP status indicates an error for https://api.imgur.com/3/gallery/image/t6l1GiW - 404 Not Found
code:
gainfo, code, err := c.service.GetGalleryAlbumInfo("t6l1GiW")
fmt.Printf("gainfo[%d]: %+v err: %+v\n", code, gainfo, err)
output:
[22/Apr/2020:19:13:45 +0000] INFO 2020/04/22 19:13:45 Info: Requesting URL https://api.imgur.com/3/gallery/album/t6l1GiW
gainfo[200]: &{ID:t6l1GiW Title:Funny Random Meme and Twitter Dump Description: DateTime:1587558857 Cover:60wTouU CoverWidth:1242 CoverHeight:1512 AccountURL:anlyin AccountID:10047121 Privacy:hidden Layout:blog
... snipped for brevity ...
err: <nil>