Skip to content

Search pages with optional keyword, range, country, language, technology, and sorting filters. Returned page records include appUrl, a direct link to open that page in the AfterLib web app.

ParameterLocationTypeDefaultAllowed valuesDescription
searchJSON bodystringnoneup to 200 charsKeyword search across public page fields.
limitJSON bodynumber201 to 100Maximum pages returned.
cursorJSON bodystringnonevalue from previous responseFetch the next cursor page.
sortByJSON bodystringperformanceperformance, trend, audienceReach, pageLikes, pageIgFollowers, adsTotalDuplicates, adsAmount, averageDuplicates, pageCreatedAt, audienceReachChangeP14, totalAdsChangeP14, uniqueAdsChangeP14Sort field.
sortDirectionJSON bodystringdescasc, descSort direction.
textSearchJSON bodystring or objectnonetext string or field include/exclude objectMatch text in specific public fields.
performance, audienceReach, pageLikes, adsJSON bodyobjectnone{ "gte": number, "lte": number }Numeric range filters.
creationDateJSON bodyobjectnone{ "gte": "YYYY-MM-DD", "lte": "YYYY-MM-DD" }Page creation date range.
countries, languages, technologiesJSON bodyobjectnone{ "include": [], "exclude": [], "operator": "or" }Include/exclude filters.
Terminal window
curl https://api.afterlib.com/v1/pages/search \
-H "Authorization: Bearer $AFTERLIB_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"search": "running",
"limit": 10,
"sortBy": "performance",
"sortDirection": "desc"
}'

Response:

{
"items": [
{
"pageId": "9000000000500",
"metaPageExternalId": "9000000000500",
"appUrl": "https://app.afterlib.com/pages/9000000000500",
"pageName": "Drift Wellness Company",
"pageLikes": 2778360,
"pageIgFollowers": 992229,
"pageCreatedAt": "2021-01-13T09:04:49.640Z",
"adsAmount": 4,
"adsTotalDuplicates": 1538,
"audienceReach": 15436615,
"averageDuplicates": 385,
"performance": 84,
"trend": 1,
"countries": ["US", "CA"],
"languages": ["eng"],
"technologySlugs": ["shopify", "klaviyo"]
}
],
"cursor": null,
"hasMore": false,
"totalHits": 1
}

Use page-level filters when you want accounts with enough audience scale and a specific commerce stack.

Terminal window
curl https://api.afterlib.com/v1/pages/search \
-H "Authorization: Bearer $AFTERLIB_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"search": "running",
"countries": {"include": ["US"], "operator": "or"},
"technologies": {"include": ["shopify"], "operator": "or"},
"audienceReach": {"gte": 1000000},
"creationDate": {"gte": "2021-01-01"},
"limit": 25
}'

Fetch one page by Meta page ID.

ParameterLocationTypeDefaultAllowed valuesDescription
pageIdpathstringrequiredpositive page ID stringThe page to fetch.
Terminal window
curl https://api.afterlib.com/v1/pages/9000000000500 \
-H "Authorization: Bearer $AFTERLIB_API_KEY"

Response:

{
"pageId": "9000000000500",
"appUrl": "https://app.afterlib.com/pages/9000000000500",
"pageName": "Drift Wellness Company",
"pageLikes": 2778360,
"pageIgFollowers": 992229,
"adsAmount": 4,
"performance": 84,
"countries": ["US", "CA"],
"technologySlugs": ["shopify", "klaviyo"]
}

POST /v1/pages/search and GET /v1/pages/{pageId} can charge credits for returned unique pages. Save X-Afterlib-Request-Id when debugging unexpected results or credit charges.