Creator engagement scoring
Fetch creator profiles and recent posts, then compute your own engagement score from public metrics
Social Fetch returns per-item metrics (views, likes, comments, followers). It does not ship a black-box "engagement score." Pull a profile, pull recent content, score in your warehouse with a formula you can explain to a client.
You'll need an API key and the TypeScript SDK. Start from Competitor profile tracking if you do not have handles yet.
Credit budget
What this costs
Profile get is typically 1 credit. TikTok / Instagram / YouTube content pages are typically 1 credit each. Twitter profile tweets are 2 credits per page. Two content pages after a profile ≈ 3 credits per creator on TikTok (1 + 1 + 1). Budget before scoring a large roster.
Suggested pipeline
- Resolve the profile (
lookupStatusmust befound). - Fetch one or two pages of recent posts/videos.
- Compute median views (or likes) in your code.
- Optionally normalize by follower count for cross-creator ranking.
| Platform | Profile | Recent content |
|---|---|---|
| TikTok | getProfile | getProfileVideos |
getProfile | getProfilePosts / getProfileReels | |
| YouTube | getChannel | getChannelVideos |
| X/Twitter | getProfile | getProfileTweets (2 credits/page) |
Call the profile route before trusting an empty video/post list — some list routes omit private / not_found the way profile routes do. See the capability matrix.
TikTok example
import { SocialFetchClient } from "@socialfetch/sdk";
const client = new SocialFetchClient({
apiKey: process.env.SOCIALFETCH_API_KEY!,
});
function median(nums: number[]): number {
if (nums.length === 0) return 0;
const sorted = [...nums].sort((a, b) => a - b);
return sorted[Math.floor(sorted.length / 2)] ?? 0;
}
async function scoreTikTokCreator(handle: string) {
const profile = await client.tiktok.getProfile({ handle });
if (!profile.ok) {
return { ok: false as const, error: profile.error };
}
if (profile.value.data.lookupStatus !== "found") {
return {
ok: true as const,
handle,
lookupStatus: profile.value.data.lookupStatus,
score: null,
};
}
const followers = profile.value.data.metrics?.followers ?? 0;
const videos = await client.tiktok.getProfileVideos({
handle,
sortBy: "latest",
});
if (!videos.ok) {
return { ok: false as const, error: videos.error };
}
const views = (videos.value.data.videos ?? [])
.map((v) => v.metrics?.views ?? 0)
.filter((n) => n > 0);
const medianViews = median(views);
const engagementRate =
followers > 0 ? medianViews / followers : null;
return {
ok: true as const,
handle,
lookupStatus: "found" as const,
followers,
sampleSize: views.length,
medianViews,
engagementRate,
creditsCharged:
profile.value.meta.creditsCharged + videos.value.meta.creditsCharged,
requestIds: [
profile.value.meta.requestId,
videos.value.meta.requestId,
],
};
}Pick your own formula. Median views beats average when one viral clip skews the feed. Document the rule in code — clients will ask.
Discovery seed
When the roster is empty, seed with GET /v1/tiktok/users/search (client.tiktok.searchUsers) or Instagram profile search, then run the scoring pass.
Longer identity + engagement walkthrough: Cross-platform creator profiles.
Related
- Credits · SDK · MCP · Capability matrix