Open source alternative to Semrush and Ahrefs
TypeScript backlink-analysisgoogle-search-console-mcpkeyword-researchmcpseoseo-agentseo-auditseo-automationseo-skillsseo-toolssite-audit
Show up to 50 location matches so same-named towns aren't cut off (#727)
Ben Senescu9a84c694e3ab
diff --git a/AGENTS.md b/AGENTS.mdindex bb69c56e..9e7a88d4 100644--- a/AGENTS.md+++ b/AGENTS.md@@ -32,6 +32,7 @@## Plugin versions- When a PR adds, edits, or removes an MCP tool (including its schema, description, or behavior), a shipped skill, or plugin configuration, bump the OpenSEO plugin version in the same PR. Internal-only skills, tests, and website-only changes do not require a bump.+- A bump is routine and cheap, never a reason to hold back an MCP change. The plugin only points at the hosted MCP server, so tool changes reach users on deploy either way. When a fix applies to both the app and an MCP tool, ship it to both; the MCP should be as good as the app.- Keep `plugins/openseo/.codex-plugin/plugin.json`, `plugins/openseo/.claude-plugin/plugin.json`, and `plugins/openseo/.cursor-plugin/plugin.json` on the same version. Default to a patch bump unless the maintainer requests a minor or major bump.- Bump once per PR relative to `origin/main`, not once per edit or tool. If main advances the plugin version before merge, update the branch to a version newer than main. The app's `package.json` version follows its separate release process.- Run `pnpm sync-plugin-skills` after changing a shipped skill and include the updated plugin copy. Call out plugin version and instruction changes for maintainer review.diff --git a/plugins/openseo/.claude-plugin/plugin.json b/plugins/openseo/.claude-plugin/plugin.jsonindex cb50a8da..d1fef445 100644--- a/plugins/openseo/.claude-plugin/plugin.json+++ b/plugins/openseo/.claude-plugin/plugin.json@@ -1,7 +1,7 @@{"name": "openseo","displayName": "OpenSEO",- "version": "1.0.4",+ "version": "1.0.5","description": "Without good data, your agent gives generic advice. Keyword research, competitor research, backlinks, and site audits. All for $10/month.","author": {"name": "OpenSEO",diff --git a/plugins/openseo/.codex-plugin/plugin.json b/plugins/openseo/.codex-plugin/plugin.jsonindex 90a46665..a4c926a2 100644--- a/plugins/openseo/.codex-plugin/plugin.json+++ b/plugins/openseo/.codex-plugin/plugin.json@@ -1,6 +1,6 @@{"name": "openseo",- "version": "1.0.4",+ "version": "1.0.5","description": "Without good data, your agent gives generic advice. Keyword research, competitor research, backlinks, and site audits. All for $10/month.","author": {"name": "OpenSEO",diff --git a/plugins/openseo/.cursor-plugin/plugin.json b/plugins/openseo/.cursor-plugin/plugin.jsonindex 19f234f8..f37d5a3b 100644--- a/plugins/openseo/.cursor-plugin/plugin.json+++ b/plugins/openseo/.cursor-plugin/plugin.json@@ -1,6 +1,6 @@{"name": "openseo",- "version": "1.0.4",+ "version": "1.0.5","description": "SEO made simple. Research keywords and competitors, audit sites, track rankings, and use Search Console data from your agent.","author": {"name": "Every App, Inc",diff --git a/src/server/mcp/tools/search-serp-locations.ts b/src/server/mcp/tools/search-serp-locations.tsindex f847f883..bceaa4a5 100644--- a/src/server/mcp/tools/search-serp-locations.ts+++ b/src/server/mcp/tools/search-serp-locations.ts@@ -23,7 +23,7 @@ export const searchSerpLocationsTool = {config: {title: "Search SERP locations",description:- "Find the exact DataForSEO location name of a city, county, or region. Returns up to 10 matches; pass the chosen `locationName` verbatim to create_rank_tracker for local rank tracking, or to research_keywords for local search volume. Uses no credits.",+ "Find the exact DataForSEO location name of a city, county, or region. Returns up to 50 matches; pass the chosen `locationName` verbatim to create_rank_tracker for local rank tracking, or to research_keywords for local search volume. Uses no credits.",inputSchema,outputSchema: z.looseObject({locations: z.array(diff --git a/src/shared/serp-location-search.test.ts b/src/shared/serp-location-search.test.tsindex 53406e4f..97fea8ab 100644--- a/src/shared/serp-location-search.test.ts+++ b/src/shared/serp-location-search.test.ts@@ -51,4 +51,13 @@ describe("rankSerpLocations", () => {rankSerpLocations("La Crosse", locations, "us")[0]?.locationName,).toBe("La Crosse,Wisconsin,United States");});++ it("returns every same-named town across many states", () => {+ const arlingtons = Array.from({ length: 20 }, (_, index) => ({+ locationName: `Arlington,State ${index},United States`,+ locationType: "City",+ }));++ expect(rankSerpLocations("Arlington", arlingtons)).toHaveLength(20);+ });});diff --git a/src/shared/serp-location-search.ts b/src/shared/serp-location-search.tsindex ab5aa46c..dc184db1 100644--- a/src/shared/serp-location-search.ts+++ b/src/shared/serp-location-search.ts@@ -181,5 +181,7 @@ export function rankSerpLocations<T extends RankableSerpLocation>((LOCATION_TYPE_RANK[b.location.locationType] ?? 9) ||(a.folded < b.folded ? -1 : a.folded > b.folded ? 1 : 0),);- return scored.slice(0, 10).map((entry) => entry.location);+ // Town names repeat across dozens of states and ties sort by state, so a+ // short list cuts whole states off ("Arlington" never reached Virginia).+ return scored.slice(0, 50).map((entry) => entry.location);}