Go tutorials for social data
572 step-by-step Go tutorials (net/http and encoding/json): scrape posts, comments, profiles, search results and reviews from 76 platforms with working code and real sample responses.
A first call
Set up with go mod init example, export GROUNDSOCIAL_API_KEY, then:
package main
import (
"encoding/json"
"fmt"
"log"
"net/http"
"os"
"time"
)
// The fields this program reads, as the recorded response has them.
type Page struct {
CaptionTracks []struct {
Name string `json:"name"`
} `json:"captionTracks"`
}
var client = &http.Client{Timeout: 60 * time.Second}
func fetch() (*Page, error) {
req, err := http.NewRequest("GET", "https://api.groundsocial.dev/v1/youtube/videos/dQw4w9WgXcQ", nil)
if err != nil {
return nil, err
}
req.Header.Set("Authorization", "Bearer "+os.Getenv("GROUNDSOCIAL_API_KEY"))
res, err := client.Do(req)
if err != nil {
return nil, err
}
defer res.Body.Close()
if res.StatusCode != http.StatusOK {
var e struct {
Error struct {
Code string `json:"code"`
Hint string `json:"hint"`
Retryable bool `json:"retryable"`
} `json:"error"`
}
json.NewDecoder(res.Body).Decode(&e)
return nil, fmt.Errorf("%s: %s", e.Error.Code, e.Error.Hint)
}
var page Page
if err := json.NewDecoder(res.Body).Decode(&page); err != nil {
return nil, err
}
return &page, nil
}
func main() {
page, err := fetch()
if err != nil {
log.Fatal(err)
}
for _, item := range page.CaptionTracks {
fmt.Println(item.Name)
}
}- Reddit subreddit
- Reddit subreddit posts
- Reddit thread and comments
- Reddit “load more comments”
- Reddit user profile
- Reddit user posts
- Reddit user comments
- Reddit search
- Reddit subreddit search
- Reddit subreddit rules
- Reddit subreddit sidebar widgets
- Reddit subreddit wiki
- Reddit subreddit comment stream
- Reddit batch subreddit lookup
- Reddit popular and new subreddits
- Reddit other discussions (duplicates)
- Reddit video transcript
- Reddit full comment tree
- Reddit post visibility (shadow removal) check
- Reddit posts by id (batch)
- Reddit comment by id
- Reddit comment status (verify)
- Reddit user overview
- Reddit user trophies
- Reddit comment search
- Reddit user search
- Reddit image and video search
- Reddit search autocomplete
- Reddit keyword sweep API (posts, top comments, communities)
- Reddit political ads disclosure
Bluesky
- Bluesky profile
- Bluesky bulk profiles
- Bluesky user posts
- Bluesky followers
- Bluesky following
- Bluesky user custom feeds
- Bluesky user lists
- Bluesky user starter packs
- Bluesky similar accounts
- Bluesky handle to DID
- Bluesky post
- Bluesky bulk posts
- Bluesky post replies (thread)
- Bluesky post likes
- Bluesky post reposts
- Bluesky post quotes
- Bluesky post search
- Bluesky user search
- Bluesky starter pack search
- Bluesky custom feed
- Bluesky custom feed posts
- Bluesky popular feeds
- Bluesky list
- Bluesky list feed
- Bluesky starter pack
- Bluesky trending
- Bluesky trending topics
- Facebook Ad Library search
- Facebook Ad Library company ads
- Facebook Ad Library advertiser search
- Facebook Ad Library advertiser profile
- Facebook Ad Library ad details
- Facebook Marketplace location search
- Facebook Marketplace search
- Facebook Marketplace listing
- Facebook Page
- Facebook event search
- Facebook city events
- Facebook event
- Facebook Page events
- Facebook Page photos
- Facebook post
- Facebook post comments
- Facebook comment replies
TikTok
- TikTok profile
- TikTok user videos
- TikTok followers
- TikTok following
- TikTok video
- TikTok comments
- TikTok comment replies
- TikTok transcript
- TikTok hashtag
- TikTok hashtag videos
- TikTok sound
- TikTok sound videos
- TikTok search suggestions
- TikTok search
- TikTok trending feed
- TikTok similar accounts
- TikTok playlists
- TikTok liked videos
- TikTok live status
- TikTok profile country
- TikTok profile analytics
- TikTok live room
- TikTok playlist videos
- TikTok place videos
- TikTok effects
- TikTok effect videos
- TikTok comment
- TikTok trending hashtags
- TikTok top videos
- TikTok Shop product
- TikTok Shop reviews
- TikTok Shop store products
- TikTok Shop search
- TikTok collection videos
- TikTok Shop sales estimate
YouTube
- YouTube video
- YouTube bulk videos
- YouTube related videos
- YouTube transcript
- YouTube bulk transcripts
- YouTube subtitles download
- YouTube thumbnail
- YouTube video sponsors
- YouTube comments
- YouTube comment replies
- YouTube channel
- YouTube bulk channels
- YouTube channel analytics
- YouTube channel videos
- YouTube channel Shorts
- YouTube channel live streams
- YouTube channel playlists
- YouTube channel podcasts
- YouTube community posts
- YouTube channel search
- YouTube community post
- YouTube playlist
- YouTube search
- YouTube hashtag
- YouTube trending Shorts
- YouTube trending videos
US Congress trades
- Congress stock trades
- Latest Congress trades
- Recent Congress trades
- Congress members who trade
- Congress member trading profile
- Congress member trades
- Congress trading by ticker
- Congress trades in a stock
- Congress trades by state
- Congress trading statistics
- Congress trading by party
- Congress trading by sector
- Most traded stocks by Congress
- Top trading members of Congress
- Most bought and sold stocks by Congress
- Congress trading volume over time
- Unusual Congress trades
- Congress buy/sell ratio
- Congress late trade disclosures
- Instagram profile
- Instagram profile by user id
- Instagram post count
- Instagram user posts
- Instagram reels
- Instagram post and reel
- Instagram comments
- Instagram similar accounts
- Instagram highlights
- Instagram highlight stories
- Instagram trending reels
- Instagram reels by audio
- Instagram popular search
- Instagram reels search
- Instagram hashtag search
- Instagram profile search
- Instagram search
- Instagram engagement rate
- Instagram profile analytics
- Instagram posts with views
- Instagram reels with captions
- Instagram comment lookup
- Instagram mentions
- Instagram location
- Instagram location posts
Tripadvisor
- Search Tripadvisor
- Tripadvisor place suggestions
- Get a Tripadvisor place
- Reviews of a Tripadvisor place
- Hotels in a destination
- Get a Tripadvisor hotel
- Restaurants in a destination
- Get a Tripadvisor restaurant
- Reviews of a Tripadvisor restaurant
- Things to do in a destination
- Get a Tripadvisor attraction
- Reviews of a Tripadvisor attraction
- Kinds of experiences in a destination
- Get a Tripadvisor cruise ship
- Reviews of a Tripadvisor cruise ship
GitHub
- GitHub user
- GitHub user repositories
- GitHub user activity
- GitHub contributions
- GitHub followers
- GitHub following
- GitHub user pull requests
- GitHub profile velocity
- GitHub repository
- GitHub README
- GitHub releases
- GitHub repository issues
- GitHub top issues
- GitHub repository dossier
- GitHub issue
- GitHub issue comments
- GitHub issue search
- GitHub repository search
- GitHub trending repositories
- GitHub trending developers
Naver
- Naver Blog search
- Naver News search
- Naver Cafe search
- Naver KnowledgeiN search
- Naver blog profile
- Naver blog posts
- Naver image search
- Naver web document search
- Naver local search
- Naver cross-corpus search
- Naver Korean typo correction
- Naver adult query check
- Naver Map place search
- Naver Place rank checker
- Naver Place details
- Naver Place reviews
Prism composites
- Look up any social media link
- Get every comment on a post
- Video detail, transcript and comments in one call
- Engagement for many post links at once
- Comments of many posts at once
- Re-check known comments
- One handle on every platform
- Audit a handle across platforms
- Many social profiles in one call
- One account’s posts across X, Threads, Bluesky and Truth Social
- New comments on a profile’s posts
- Which post format works for a creator
- Vet a creator before a partnership
- What languages a creator’s audience writes in
- How much two creators’ audiences overlap
- A Truth Social account’s pulse
- Who mentions a handle or brand
- Brand mention volume and sentiment
- Share of voice across brands
- People switching from a competitor
- Buyer leads in comments
- The questions your audience asks
- Campaign lift for a hashtag
- Brand crisis radar
- Crisis post-mortem timeline
- How early a trend appeared on each platform
- What is trending in a country today
- What people say about working at a company
- Find creators for a niche
- Discover social posts with filters
- Find a company’s social accounts
- Store an author or exclude list
- One app on the App Store and Google Play
- App reviews on both stores
- A brand’s reputation score
- A product’s reviews across marketplaces
- Are a product’s reviews trustworthy
- Reviews for many businesses at once
- How a developer tool is doing
- How a launch landed
- A GitHub organization’s footprint
- Check a sponsored post against its brief
- Is demand for something rising