GeoDB Cities ACTION
Find Cities
Find cities, filtering by optional criteria. If no criteria are set, you will get back all known cities with a population of at least 1000. See the docs.
- Action
- Read only
- API key
- SDK
- MCP
IMPLEMENTATION
Call this tool
Connect a user's GeoDB Cities account once, then configure and run Find Cities from your backend or agent.
import { PipedreamClient } from "@pipedream/sdk"
const pd = new PipedreamClient({
projectId: process.env.PIPEDREAM_PROJECT_ID!,
clientId: process.env.PIPEDREAM_CLIENT_ID!,
clientSecret: process.env.PIPEDREAM_CLIENT_SECRET!,
projectEnvironment: "production",
})
const result = await pd.actions.run({
id: "geodb_cities-find-cities",
externalUserId: "{external_user_id}", // any stable ID for this user in your system
configuredProps: {
geodb_cities: { authProvisionId: "apn_xxxxxxx" },
types: ["City Types"],
location: "Location",
},
})
console.log(result)curl -X POST https://api.pipedream.com/v1/connect/{project_id}/actions/run \
-H "Content-Type: application/json" \
-H "X-PD-Environment: production" \
-H "Authorization: Bearer {access_token}" \
-d '{
"external_user_id": "{external_user_id}",
"id": "geodb_cities-find-cities",
"configured_props": {
"geodb_cities": { "authProvisionId": "apn_xxxxxxx" },
"types": ["City Types"],
"location": "Location"
}
}'// accessToken: mint a short-lived token with the Connect SDK — see the MCP guide
const transport = new StreamableHTTPClientTransport(
new URL("https://remote.mcp.pipedream.net/v3"),
{
requestInit: {
headers: {
Authorization: `Bearer ${accessToken}`,
"x-pd-project-id": "{project_id}",
"x-pd-environment": "production",
"x-pd-external-user-id": "{external_user_id}", // any stable ID for this user in your system
"x-pd-app-slug": "geodb_cities",
},
},
},
)
const mcp = new Client({ name: "my-agent", version: "1.0.0" })
await mcp.connect(transport)
const { tools } = await mcp.listTools()
// listTools() hands your model this tool's input schema, so it can
// fill the arguments itself:
const result = await mcp.callTool({
name: "geodb_cities-find-cities",
arguments: {
types: ["City Types"],
location: "Location",
},
})SCHEMA
Inputs
Pipedream supplies the connected account. Your application provides the operation-specific values below. Dynamic inputs are resolved against that user's account.
| Property | Type | Description |
|---|---|---|
types City Types | string[] | The type of city. Possible values are: CITY and ADM2. Optional |
location Location | string | Only cities near this location. Latitude/Longitude in ISO-6709 format: ±DD.DDDD±DD.DDDD. For example: +51.5008-0.1247. Optional |
minPopulation Minimum Population | integer | Only cities having at least this population. Optional |
maxPopulation Maximum Population | integer | Only cities having no more than this population. Optional |
languageCode Language Code | string | The language to use for the name property. If not set, the name will be in English. Possible values are: en, de, es, fr, it, pt, ru, zh. Optional |
namePrefix Name Prefix | string | Only cities whose names start with this prefix. If Language Code is set, the prefix will be matched on the name as it appears in that language. Optional |
max Max Records | integer | Max number of records in the whole pagination Optional |
REFERENCE
Tool details
Behavior hints are published with the component in the Pipedream registry and surface as MCP tool annotations, so an agent can reason about a tool before it calls it.
- Registry key
- geodb_cities-find-cities
- Version
- 0.0.3
- App
- GeoDB Cities
- Authentication
- API key
- Read-only
- Yes
- Destructive
- No
- Open world
- Yes
- Source
- View on GitHub ↗