PeumeAPI

Ads

Search targeting options

Finds targeting options by name, such as locations, interests or behaviors, and returns the ids to use in ad targeting.

$0.002 per callRuns on an account you connect

Call it

curl https://api.peume.com/v1/call/search-targeting-options \
  -H "Authorization: Bearer $PEUME_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "input": {
    "accountId": "your accountId",
    "q": "your q",
    "dimension": "interest",
    "geoType": "city",
    "limit": 25
  }
}'

Answer: {"id": "run_…", "status": "completed", "cost_usd": …, "output": {…}}. Long jobs answer 202 with a run id to read later. From an AI agent, connect the MCP server and ask for this by name: search-targeting-options.

Parameters

accountIdRequiredstring

Account ID (a connected account on the target ad platform).

qRequiredstring

Search query. For geo, the locality name only (no region/country suffix). For `interestSuggestion`, the interest names: comma-separated, or a JSON array of strings when a name contains a comma (a `q` starting with `[` is read as JSON).

dimensionstring

What to search. Defaults to `interest` for backward compatibility with the deprecated /v1/ads/interests alias. - `geo`: resolves locations (scope further with `geoType`). - `interest`/`behavior`: resolve audience entities (`behavior` on Meta, TikTok and LinkedIn). - `interestSuggestion`: suggests interests related to the names in `q` (Meta only). - `interestKeyword`/`hashtag`: resolve TikTok additional interests and hashtags (TikTok only). - `income`: resolves the normalized income tiers. - `language`: resolves Google's targetable language_constant table (Google only). - `workPosition`/`workE

geo · interest · interestSuggestion · interestKeyword · behavior · hashtag · income · language · workPosition · workEmployer · workIndustry · industry …

Example: interest

geoTypestring

Only used when `dimension=geo`. The kind of location to resolve. `all` searches every type in one relevance-ranked call. Defaults to `city`.

all · country · country_group · region · city · subcity · neighborhood · place · zip · metro_area · geo_market

Example: city

countryCodestring

ISO 3166-1 alpha-2 country code (e.g. NL) to scope a geo search.

adAccountIdstring

TikTok only: the advertiser to search as, when the connection holds several. Each TikTok advertiser has its own targetable regions and catalogs. Defaults to the connection's first advertiser; an advertiser the connection does not hold returns 400.

localestring

Meta only (ignored on other platforms). The language Meta matches `q` against and names results and `path` in, as language_TERRITORY (e.g. `pl_PL`, `en_US`). Applies to `geo`, `interest`, `interestSuggestion`, `behavior`, `workPosition`, `workEmployer` and `workIndustry`. **Without it:** `behavior`, `workIndustry` and `interestSuggestion` use `en_US`; other searches use the language of the Facebook user who connected the account. `income` always uses `en_US`.

limitinteger

Maximum results to return.

Example: 25

Start free · $1 of calls included

Every API your product needs. One key.

7,267 endpoints, one bill, and you only pay for calls that work.