SocialToAIStart freeConsole

Viral finder (viral_finder)

POST /v1/tools/viral_finder runs Viral finder, a ready-made tool that returns posts on a subject that did clearly better than their authors usually do, on one platform. It reads 6 platforms and costs from 24 credits a run. Send max_cost_credits and a run that would cost more is refused for free, with the quote. A run that fetches nothing is not charged.

POSThttps://api.socialtoai.com/v1/tools/viral_finder

To fill it in on the site, or to see what its result looks like, open Viral finder.

Request

A JSON body with the tool's own inputs. The key goes in the Authorization header, as on every call.

NameTypeRequiredWhat it is
querystringYesThe subject, as keywords.
platformstringYesOne platform.
windowstringNoHow far back to look. Values: 7d, 30d (default 7d).
scalestringNosmall searches 3 pages; medium adds the usual level of the top 10 authors; large searches 5 pages and adds the top 30 authors. Values: small, medium, large (default small).
max_cost_creditsintegerNoRefused, free, with the quote, if the run would cost more.
confirmbooleanNotrue: run it whatever it costs. false: answer the plan and its price, and run nothing. Left out: a costly run, and one that runs in the background, answers its price first.
curl https://api.socialtoai.com/v1/tools/viral_finder \  -H "Authorization: Bearer $SOCIALTOAI_KEY" \  -H "Content-Type: application/json" \  -d '{    "query": "air fryer recipes",    "platform": "tiktok",    "window": "7d",    "scale": "small"  }'
import osimport requestsresponse = requests.post(    "https://api.socialtoai.com/v1/tools/viral_finder",    headers={"Authorization": f"Bearer {os.environ['SOCIALTOAI_KEY']}"},    json={        "query": "air fryer recipes",        "platform": "tiktok",        "window": "7d",        "scale": "small",    },)print(response.json())

Depths and credits

scale picks the depth. A depth has one price on each platform, stated before the run.

DepthscaleWhat it readsFrom (credits)How it runsOn the 100 free credits
SmallsmallSearches 3 pages.24runs while you waitYes
MediummediumSearches 3 pages and checks the usual level of the top 10 authors.54runs while you waitOn 4 of 5 platforms
LargelargeSearches 5 pages and checks the usual level of the top 30 authors.130runs while you waitAfter your first purchase

Credits by platform

The table is for one subject on one platform.

PlatformSmallMediumLarge
TikTok3676178
X2454130
YouTube24——
Xiaohongshu54294810
Douyin4888192
Bilibili2464160

What a result holds

PartWhat it holds
Viral postsPosts that did clearly better than their authors usually do, and by how much.
Main numberViral posts

Quote or run: confirm

The same request either runs or comes back as a quote. confirm, a boolean beside the tool's inputs, decides which:

confirmWhat comes back
falseThe quote, always. Free: nothing is reserved, fetched or charged.
left outThe run, when it costs at most 100 credits and is answered within the request. Above that, or when the plan runs in the background (quote.mode is background), the quote first.
trueThe run, charged at most what the quote states. A run that cannot be made is refused for free with not_supported; it is never answered with a quote you did not ask for.

A run's answer carries a handle: for 24 hours the whole result can be read again with it, for free. Results and handles has the details. The same request sent again under its Idempotency-Key returns the first run's answer and costs 0.

The quote

A quote is the plan of exactly this request and the most a run of it is charged. Nothing is reserved, fetched or charged for it. status is quote.

FieldTypeWhat it is
request_idstringThe id of this request.
schema_version"v1"The version of the response format.
toolstringThe tool the quote is for.
scale"small" | "medium" | "large" | nullThe depth the quote is for; null for a tool priced by the row.
status"quote"quote: nothing was reserved, fetched or charged.
quote.creditsintegerThe most the run is charged.
quote.parts.data_firstintegerThe first half of the fetching price.
quote.parts.data_secondintegerThe second half of the fetching price. Not charged when less than half of the planned reading comes back.
quote.parts.analysisintegerThe price of the AI analysis. Charged only when at least nine in ten of the delivered rows were analysed.
quote.mode"sync" | "background"sync: answered within the request. background: answered with a handle, and run in waves.
quote.wavesintegerHow many waves a background run is made of; 1 for a run answered within the request.
quote.estimated_secondsintegerAbout how long the run takes.
quote.free_tier.runnablebooleanWhether an account that has not bought credits may run it.
quote.free_tier.reasonsstring[]When it may not, why: cost, duration or paid_only.
quote.planarrayEvery step in the order it runs: the platform, the action, how many targets and pages or how many batches of analysis, and its credits.
quote.price_versionstringThe price version the quote was made from.
billingobjectAs in every answer: see Credits and billing.

How a run is charged

  • You see the price first: The total is stated before anything starts. It does not grow if there is more to read.
  • Nothing fetched, nothing charged: If nothing could be fetched, the run is not charged. If it stops partway, you are charged only for the part that finished.
  • Each depth is one price: A depth has a fixed price on each platform. It is not reduced when there turns out to be less to read, so start small and go deeper when you need more.
  • If nothing could be fetched, the run is not charged. If content was fetched but the conditions you set filtered all of it out, only the first half of the fetching price is charged. If a run stops partway, you are charged only for the part that finished.
  • The run goes on with what could be read, and the result says how much of the plan that was. The price has three parts: two for fetching and one for the AI analysis. When less than half of the planned reading came back, the second fetching part is not charged. The analysis part is charged only when at least nine in ten of the delivered rows were analysed. A call whose outcome is unknown is never retried on our own.

Over MCP

The MCP tool is research, called with tool set to viral_finder. It takes the same inputs and costs the same. The tool list has the description your AI is given.

Last updated: