> **For coding agents and LLMs:** This is one Social Fetch marketing page (markdown export). For API orientation start with [`/llms.txt`](https://www.socialfetch.dev/llms.txt); for auth and crawl rules use [`/agents.txt`](https://www.socialfetch.dev/agents.txt); for every operation use [`/llms-endpoints.txt`](https://www.socialfetch.dev/llms-endpoints.txt).

## This page

- **On-site (HTML):** <https://www.socialfetch.dev/use-cases/social-data-api-for-agencies>
- **Markdown (.mdx) URL:** <https://www.socialfetch.dev/use-cases/social-data-api-for-agencies.mdx>

---

# Social data API for agencies

Profiles, posts, ad library creative, and metrics across client networks — one schema, prepaid credits per account.

Agency reporting fails on procurement: multiple vendors, JSON shapes, and invoices per network. A new platform mid-retainer means another integration before the monthly report ships.

Prepaid credits (no expiry) fit bursty QBR work. One envelope keeps Looker models and client portals stable when platform fields rename.

## Endpoints

| Method | Path | What it does |
| --- | --- | --- |
| GET | `/v2/instagram/profiles/{profile}/media` | Paginated posts for client content calendars and monthly engagement snapshots. |
| GET | `/v1/tiktok/profiles/{handle}/videos` | Recent TikTok videos with view and engagement counts for campaign wrap-ups. |
| GET | `/v1/youtube/channel` | YouTube channel stats from a URL or handle when clients expand beyond short-form. |
| GET | `/v1/linkedin/companies` | LinkedIn company profile for B2B client audits and employer-brand reports. |
| GET | `/v1/facebook/ad-library/ads/search` | Live Meta ad creative and copy for competitive audits and new-business pitches. |
| GET | `/v2/instagram/profiles/{profile}` | Follower counts, bio, and verification status when onboarding new client handles. |

## Workflow

1. **Pull competitors for the pitch.** Before the new-business meeting, search the Meta Ad Library and pull recent posts from the prospect's rivals. Same API key, same response envelope. Your pitch deck template does not fork per platform.
2. **Onboard handles into your client database.** When the SOW is signed, store each client's social accounts with a client_id foreign key. Profile endpoints return lookupStatus so you can flag typos or renamed handles before the first live report runs.
3. **Map report templates to endpoints once.** Your monthly PDF, client portal tile, and Looker dashboard all read from normalized JSON. Instagram posts and TikTok videos land in the same engagement table because field names stay consistent even when platforms change.
4. **Batch refresh on your cadence.** Run weekly cron jobs for active clients and monthly jobs for retainers. No published rate cap beyond your credit balance. Burst hard the night before a QBR without calling sales to bump a subscription tier.
5. **Allocate credits per client for margin.** Tag each request with a client identifier in your own logging layer. Pay-as-you-go credits are prepaid and never expire, so you can bill clients a flat reporting fee and keep the spread between your API cost and the retainer line item.
6. **Ship white-label deliverables.** Drop JSON into Google Slides automation, a custom portal, or a CSV export for account managers who still work in Sheets. Your brand stays on the cover; the data layer stays boring underneath.

## Example: competitive ad audit before a pitch

```bash
curl -sS \
  -H "x-api-key: YOUR_API_KEY" \
  -G "https://api.socialfetch.dev/v1/facebook/ad-library/ads/search" \
  --data-urlencode "query=competitor brand name"
```

## Why agencies standardize on Social Fetch

- 25 platforms on one key means fewer vendor reviews and one line item in your agency P&L.
- Prepaid credits with no expiry: allocate spend per client instead of paying a flat subscription while dormant accounts sit idle.
- No per-seat API tax. Interns, freelancers, and overnight cron jobs share the same key without seat math.
- Same data envelope on Instagram, TikTok, YouTube, LinkedIn, and the rest. Your ETL code does not fork per network.
- Schema stability as an operational promise: when Meta renames a field, your client dashboards keep working.
- Completed lookups charge credits; infrastructure failures (lookup_failed, 503) do not. Predictable cost for margin planning.
- Social Freak Ltd is a registered UK company when procurement asks who operates the API and how data is handled.
