# Tiktok Place / Location Search Scraper (`romy/tiktok-place-location-search-scraper`) Actor

Search TikTok Places by keyword and location — extract place names, categories, addresses, and coordinates at scale

- **URL**: https://apify.com/romy/tiktok-place-location-search-scraper.md
- **Developed by:** [Romy](https://apify.com/romy) (community)
- **Categories:** Social media, Developer tools, Automation
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.50 / 1,000 place scrapeds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).


# README

## TikTok Place Search Scraper

Search TikTok Places by keyword and location — extract place names, categories, addresses, and coordinates at scale.

### What does TikTok Place Search Scraper do?

This Actor queries the **TikTok Places search API** to find places matching a keyword near a given location. It returns structured data including place names, categories (Food & Drink, Hotel, etc.), coordinates, and direct TikTok place URLs.

Unlike browser-based scrapers, this Actor calls the native mobile API directly — no browser overhead, no JavaScript rendering, no rate-limiting from page loads.

### Why use TikTok Place Search Scraper?

- **Competitor research** — find all coffee shops or restaurants of a brand in an area
- **Local market analysis** — discover what categories dominate a neighborhood
- **Lead generation** — build lists of local businesses with their TikTok presence
- **Location intelligence** — map business density by category for any region

### How to use TikTok Place Search Scraper

#### Step 1: Configure the Actor

Fill in the Actor input:

- **keyword** (required): Any search keyword — generated on-the-fly, no pre-registration needed
- **region**: Country code (`ID`, `US`, `SG`, `MY`, ...)
- **latitude / longitude**: Search center coordinates (optional — omit for region-wide search)
- **radius**: Search radius in meters (default 500)
- **maxPages**: Pages to fetch, 20 places each (default 5 = up to 100 places)

#### Step 3: Run and download results

Click **Start** and download results as **JSON, CSV, or Excel** from the Output tab.

### Input

```json
{
    "keyword": "warteg",
    "region": "ID",
    "latitude": -6.2088,
    "longitude": 106.8456,
    "radius": 500,
    "maxPages": 5
}
````

| Field | Type | Required | Default | Description |
|-------|------|----------|---------|-------------|
| `keyword` | string | Yes | — | Search keyword (must be pre-cached via enc\_gen.py) |
| `region` | string | No | `ID` | Country code |
| `latitude` | number | No | — | Center latitude |
| `longitude` | number | No | — | Center longitude |
| `radius` | integer | No | `500` | Search radius in meters |
| `maxPages` | integer | No | `5` | Max pages (20 places/page) |

### Output

Raw API response per place, with embedded JSON strings automatically parsed into objects:

```json
{
  "id": "21568226305357335",
  "name": "Warteg Bahari",
  "latitude": -6.959311,
  "longitude": 106.250609,
  "address": "Indonesia",
  "formatted_address": "Indonesia",
  "district": "",
  "city": "",
  "province": "",
  "country": "",
  "distance": "",
  "display_category": "Indonesian Restaurant",
  "details": {
    "city_name": "Lebak Regency",
    "tt_type_name_super": "Food and Drink",
    "tt_type_name_medium": "Specialty Dining",
    "tt_type_name_tiny": "Indonesian Restaurant",
    "collect_info": {
      "tt_poi_type_name_level0": "Food and Drink",
      "poi_detail_type": "store"
    },
    "geo_name_ids": {
      "l0_geoname_id": "1643084",
      "l1_geoname_id": "1923045"
    }
  },
  "hight_positions": [{ "begin": 6, "end": 12 }]
}
```

You can download the dataset in JSON, CSV, or Excel formats.

### Pricing

This Actor uses Pay-Per-Event pricing:

| Event | Price |
|-------|-------|
| Actor start | $0.05 |
| Per place scraped | $0.0015 |

Scraping 100 places costs approximately **$0.20**.

### Proxy & International Results

TikTok's place search ranks results by **server-side IP geolocation**, not by the latitude/longitude in the request. Without a proxy, all requests come from the same datacenter IP and return globally ranked results (often dominated by Indonesian content for generic keywords like "burger").

To get accurate country-filtered results:

1. Enable **Apify Residential Proxies** in the `proxyConfiguration` field
2. Set the correct `region` code (e.g. `AU` for Australia, `US` for United States)

The actor will automatically route requests through a proxy IP in the target country, making TikTok return locally relevant places.

**Without proxy:** Unique or landmark keywords work fine globally (e.g. "eiffel tower" returns Paris, "burj khalifa" returns Dubai). Generic keywords return globally ranked results.

**With proxy:** Generic keywords like "burger" + `region=AU` return Australian burger places.

### Tips

- **Larger radius + fewer pages**: use `radius=5000` with `maxPages=3` for broad area coverage (up to ~60 places)
- **Precise location search**: drop radius to 200-500m for specific neighborhood results
- **Any keyword works** — no pre-registration or emulator required, tokens generated on the fly
- **International search**: enable residential proxies + set `region` to the target country code

### FAQ

**Do I need an emulator or special setup?**
No. The actor generates `enc_data` tokens on-the-fly using a pure Python implementation. Any keyword works out of the box — no emulator, no pre-registration, no cache files needed.

**Is this legal?**
This Actor accesses publicly available place data through TikTok's mobile API. Use responsibly and in accordance with TikTok's Terms of Service. Do not use for prohibited purposes or at excessive rates.

**Issues or feature requests?**
Open an issue in the [Issues tab](../../issues).

# Actor input Schema

## `keyword` (type: `string`):

Search keyword — any keyword works (e.g. 'burger', 'coffee shop', 'warteg'). Token generated on the fly.

## `region` (type: `string`):

Country code for the search (e.g. ID, US, AU, SG, MY, JP). Also used to select a matching proxy country when proxyConfiguration is set.

## `latitude` (type: `string`):

Search center latitude in decimal degrees (e.g. -6.2088). Optional.

## `longitude` (type: `string`):

Search center longitude in decimal degrees (e.g. 106.8456). Optional.

## `radius` (type: `integer`):

Search radius around the center point in meters

## `maxPages` (type: `integer`):

Maximum number of result pages to fetch (20 places per page)

## `proxyConfiguration` (type: `object`):

Proxy settings. For accurate country-filtered results, enable Apify residential proxies — the actor will automatically route through a proxy matching the region code.

## Actor input object example

```json
{
  "region": "ID",
  "radius": 500,
  "maxPages": 5,
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}
```

# Actor output Schema

## `dataset` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "proxyConfiguration": {
        "useApifyProxy": true
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("romy/tiktok-place-location-search-scraper").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = { "proxyConfiguration": { "useApifyProxy": True } }

# Run the Actor and wait for it to finish
run = client.actor("romy/tiktok-place-location-search-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "proxyConfiguration": {
    "useApifyProxy": true
  }
}' |
apify call romy/tiktok-place-location-search-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=romy/tiktok-place-location-search-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Tiktok Place / Location Search Scraper",
        "description": "Search TikTok Places by keyword and location — extract place names, categories, addresses, and coordinates at scale",
        "version": "0.0",
        "x-build-id": "qhDOBZBfy2GBj9UZG"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/romy~tiktok-place-location-search-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-romy-tiktok-place-location-search-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/romy~tiktok-place-location-search-scraper/runs": {
            "post": {
                "operationId": "runs-sync-romy-tiktok-place-location-search-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/romy~tiktok-place-location-search-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-romy-tiktok-place-location-search-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "keyword"
                ],
                "properties": {
                    "keyword": {
                        "title": "Keyword",
                        "type": "string",
                        "description": "Search keyword — any keyword works (e.g. 'burger', 'coffee shop', 'warteg'). Token generated on the fly."
                    },
                    "region": {
                        "title": "Region",
                        "type": "string",
                        "description": "Country code for the search (e.g. ID, US, AU, SG, MY, JP). Also used to select a matching proxy country when proxyConfiguration is set.",
                        "default": "ID"
                    },
                    "latitude": {
                        "title": "Latitude",
                        "type": "string",
                        "description": "Search center latitude in decimal degrees (e.g. -6.2088). Optional."
                    },
                    "longitude": {
                        "title": "Longitude",
                        "type": "string",
                        "description": "Search center longitude in decimal degrees (e.g. 106.8456). Optional."
                    },
                    "radius": {
                        "title": "Search Radius (meters)",
                        "minimum": 1,
                        "maximum": 50000,
                        "type": "integer",
                        "description": "Search radius around the center point in meters",
                        "default": 500
                    },
                    "maxPages": {
                        "title": "Max Pages",
                        "minimum": 1,
                        "maximum": 50,
                        "type": "integer",
                        "description": "Maximum number of result pages to fetch (20 places per page)",
                        "default": 5
                    },
                    "proxyConfiguration": {
                        "title": "Proxy Configuration",
                        "type": "object",
                        "description": "Proxy settings. For accurate country-filtered results, enable Apify residential proxies — the actor will automatically route through a proxy matching the region code."
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
