Name an account or a post
The links, handles, and ids that the tools take.
A ref names one account or one post. lookup, track, and the account filter of search_posts take refs. A ref has one of these forms:
| Form | Example |
|---|---|
| A profile link | https://www.tiktok.com/@acme_studio |
| A post link | https://x.com/AcmeStudio/status/1830000000000000001 |
platform:@handle | instagram:@acme.co |
platform:account:ID | instagram:account:1789456123 |
platform:post:ID | tiktok:post:7431852096741258240 |
platform is one of instagram, tiktok, youtube, threads, facebook, x, linkedin, and snapchat.
Ids
account_history, post_history, and untrack take an id, never a handle or a link. The id of an account is platform:account:ID, and the id of a post is platform:post:ID. Build it from platform and platform_account_id or platform_post_id of any answer. To turn a handle or a link into an id, call lookup with it. An account in a watchlist that socialdata has not found yet has the id platform:pending:N from watchlist_items, which only untrack takes.
Links on each platform
| Platform | An account | A post |
|---|---|---|
https://www.instagram.com/acme.co/ | https://www.instagram.com/reel/C0dE1234567/ or /p/ | |
| TikTok | https://www.tiktok.com/@acme_studio | https://www.tiktok.com/@acme_studio/video/7431852096741258240 |
| YouTube | https://www.youtube.com/@acme.co | https://www.youtube.com/shorts/aBcD1234EfG |
| Threads | https://www.threads.net/@acme.co | https://www.threads.net/@acme.co/post/DAbC123xYz9 |
https://www.facebook.com/AcmeStudio | https://www.facebook.com/AcmeStudio/videos/1234567890123456/ | |
| X | https://x.com/acmestudio | https://x.com/AcmeStudio/status/1830000000000000001 |
https://www.linkedin.com/company/acme-studio/ | https://www.linkedin.com/posts/acme-studio_launch-day-activity-7400000000000000001-AbCd | |
| Snapchat | https://www.snapchat.com/add/acme.co | https://www.snapchat.com/spotlight/AbCdEf123456 |
Some links need more than the link itself:
- Short links. socialdata follows the redirect of a short link, such as
https://vm.tiktok.com/ZMabc123/,https://t.snapchat.com/AbCdEf12, orhttps://t.co/AbCdEf123. A short link that leads off the platform is refused. - Facebook links with only a number. socialdata reads the platform to place a link such as
https://www.facebook.com/100012345678901, or a Facebook video link, solookupandtrackof it can cost credits. - LinkedIn. Only company pages and their posts are refs. A personal profile, such as
https://www.linkedin.com/in/someone/, isinvalid_ref. - Long YouTube videos. A
watch?v=oryoutu.belink does not say whether the video is a Short. If it is a long video,lookupanswersunsupported_media_typeafter it spent 1 credit to learn the length.
A link to any other site, such as https://pinterest.com/acmestudio/, is unsupported_platform.