Identify the platform behind a URL
Exacturls_platform_classifyDeterministic and authoritative — the canonical answer for this input.
Classify a URL by social/professional platform and extract structured IDs. Recognizes Twitter/X, LinkedIn, GitHub, YouTube, Facebook, Instagram, TikTok, Reddit, Stack Overflow, Medium, Substack, Bluesky, Threads. Extracts tweet ID, repo owner/name, video ID, profile slug where the path is deterministic. UNLIKE the sibling URL tools, scheme-less input is accepted BY DESIGN — people paste 'twitter.com/jack' without https:// — so any plausible bare hostname parses; plausible requires a dot, so a scheme-less bare word ('not-a-url') is rejected as is_valid:false (an explicit scheme lifts that requirement). An unknown but well-formed host returns platform:null at confidence 0.0; input that is not a URL at all (malformed host) is rejected as is_valid:false. Processing multiple inputs? Use `urls_platform_classify_batch` to do up to 1000 in one call.
Parameters
urlstringrequiredThe URL to classify by platform.
Call it
curl -X POST https://api.snipget.ai/v1/urls/platform-classify \
-H "Authorization: Bearer sk_live_..." \
-H "Content-Type: application/json" \
-d '{"url":"https://github.com/python/cpython"}'The Batch tab sends up to 1000 inputs in one call via /v1/urls/platform-classify/batch.
Example response
{
"input": "https://github.com/python/cpython",
"is_valid": true,
"platform": "GitHub",
"entity_type": "repo",
"extracted_ids": {
"owner": "python",
"repo": "cpython"
},
"host": "github.com",
"path": "/python/cpython"
}FAQ
What does this actually tell me?
It names the platform behind a link (Twitter/X, LinkedIn, GitHub, YouTube, Facebook, Instagram, TikTok, Reddit, Stack Overflow, Medium, Substack, Bluesky, Threads) and pulls out the meaningful IDs from the path, like a repo's owner and name, a tweet ID, or a YouTube video ID. That saves you writing fragile rules to recognize each site by hand.
Does it open the link or look up the account?
No. It reads the link's structure only and never visits the page, so it does not confirm the profile, video, or repo still exists. It just tells you what the URL points at.
What happens with a site it doesn't know?
You still get a clean answer for a real link: platform is null, confidence is 0, and the host and path are returned so you can handle it yourself. Unknown links are reported, not rejected. Input that is not a URL at all (a malformed host like text with spaces, or a scheme-less bare word with no dot like 'not-a-url') does get rejected, with is_valid false and a reason.
Do I need to include https:// on the link?
No. Unlike the other URL tools, this one accepts scheme-less input by design, because people paste handles like twitter.com/jack without a scheme. Any plausible bare hostname parses, where plausible means the host contains a dot; a scheme-less bare word like 'not-a-url' is rejected rather than reported as an unknown site. Add an explicit scheme if you really mean a single-label host. The stricter parse and validate tools will reject any scheme-less input as missing its scheme.
Why does confidence sometimes come back lower than 1?
When it recognizes the platform but the link doesn't match a known shape (for example a LinkedIn search page or a YouTube playlist), it reports the platform with empty IDs and a lower confidence. A fully matched link (a repo, a tweet, a profile) comes back at full confidence.
Is the result reliable enough to depend on?
Yes for the known platforms. The matching is exact and rule-based, so the same URL always classifies the same way; just read the confidence to know whether the specific IDs were extracted.