serpkin 0.2.17 → 0.2.19
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +3 -3
- package/package.json +1 -1
- package/plugin/serpkin/.claude-plugin/plugin.json +1 -1
- package/plugin/serpkin/.mcp.json +1 -1
- package/plugin/serpkin/commands/check.md +2 -2
- package/plugin/serpkin/commands/manager.md +3 -1
- package/plugin/serpkin/commands/ship.md +1 -1
- package/plugin/serpkin/commands/status.md +2 -2
- package/plugin/serpkin/skills/serpkin-seo/SKILL.md +14 -2
- package/templates/github-action.yml +1 -1
- package/templates/weekly-mission.yml +8 -0
package/README.md
CHANGED
|
@@ -39,7 +39,7 @@ Requires Node 22 or newer. No dependencies. Builder and Pro start with a 7-day f
|
|
|
39
39
|
- **Cursor**: merges into `.cursor/mcp.json` and writes the project rule `.cursor/rules/serpkin.mdc` with the SEO loop.
|
|
40
40
|
- **Codex**: appends `[mcp_servers.serpkin]` to `~/.codex/config.toml` once and adds a short "Serpkin SEO" section to the project's `AGENTS.md` (it asks first, and creates the file if it's missing).
|
|
41
41
|
|
|
42
|
-
All three configs run a small local MCP bridge, `npx -y serpkin@0.2.
|
|
42
|
+
All three configs run a small local MCP bridge, `npx -y serpkin@0.2.19 mcp`, which reads the key saved at sign-in and forwards requests to `https://serpkin.com/api/mcp` (a self-hosted server adds `--server <origin>` to the args). The configs hold no key and no environment variable, so there is nothing to export.
|
|
43
43
|
|
|
44
44
|
The rule and the `AGENTS.md` section sit between `<!-- serpkin:start -->` and `<!-- serpkin:end -->`. Re-running init refreshes only that block and keeps everything else.
|
|
45
45
|
4. **Registers the site**, which queues its initial audit on the server, and uploads a route map (URL path → source file), so missions can name the files to change.
|
|
@@ -61,7 +61,7 @@ Inside a session you can run `/plugin marketplace add apwn/serpkin`, then `/plug
|
|
|
61
61
|
|
|
62
62
|
- the **`serpkin-seo` skill**, which runs the loop: next mission → implement → run checks → check the preview → submit → verify the preview → verify production after you deploy. It treats page text and search data as untrusted and never deploys.
|
|
63
63
|
- **commands**: `/serpkin:next` gets the next mission and implements it. `/serpkin:ship <preview-url>` submits it, checks the preview and verifies. `/serpkin:check <preview-url>` runs `serpkin check` (the pinned CLI version from the public npm registry). `/serpkin:status` shows the site status. `/serpkin:manager` sets up a weekly SEO manager for one site, or `/serpkin:manager all` for one check-in across every site, and runs the first check-in.
|
|
64
|
-
- the **Serpkin MCP server**, run as the same stdio bridge (`npx -y serpkin@0.2.
|
|
64
|
+
- the **Serpkin MCP server**, run as the same stdio bridge (`npx -y serpkin@0.2.19 mcp`). It uses the key saved at sign-in, so there is nothing to export. `SERPKIN_API_KEY` is an optional override, and `SERPKIN_SERVER` picks a self-hosted or local server (default `https://serpkin.com`).
|
|
65
65
|
|
|
66
66
|
- **hooks** (quiet by design, only in repositories with `.serpkin.json`):
|
|
67
67
|
- **Session start**: one line with the next mission and "run /serpkin:next". It is fetched with a 2.5-second timeout and cached for 6 hours per site (failures for 30 minutes), and it says nothing when you are offline, signed out or the project isn't linked.
|
|
@@ -77,7 +77,7 @@ Clients without plugins get the same loop as MCP prompts: `next_mission`, `ship_
|
|
|
77
77
|
|
|
78
78
|
### Where the key goes
|
|
79
79
|
|
|
80
|
-
The key is **never written into your repository.** It is stored in `~/.config/serpkin/credentials.json` (mode 600, keyed by server). Agent configs run `npx -y serpkin@0.2.
|
|
80
|
+
The key is **never written into your repository.** It is stored in `~/.config/serpkin/credentials.json` (mode 600, keyed by server). Agent configs run `npx -y serpkin@0.2.19 mcp`, which reads it from there, so they hold no key and no environment variable, and you don't need to export anything.
|
|
81
81
|
|
|
82
82
|
`SERPKIN_API_KEY` still works and takes precedence over the saved key: use it in CI and GitHub Actions, or if you prefer it. Configs written by older versions (`${SERPKIN_API_KEY}` / `${env:SERPKIN_API_KEY}` / `bearer_token_env_var`) keep working while the variable is set. Re-running `npx serpkin` switches `.mcp.json` and `.cursor/mcp.json` to the bridge; an existing Codex table that reads the variable is left alone and the CLI prints the new block to replace it. A Codex bridge entry pinned to an older CLI version gets just that version updated.
|
|
83
83
|
|
package/package.json
CHANGED
package/plugin/serpkin/.mcp.json
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: Check a preview deployment for SEO regressions against production
|
|
3
3
|
argument-hint: "<preview-url>"
|
|
4
|
-
allowed-tools: Bash(npx -y --registry=https://registry.npmjs.org serpkin@0.2.
|
|
4
|
+
allowed-tools: Bash(npx -y --registry=https://registry.npmjs.org serpkin@0.2.19 check:*)
|
|
5
5
|
---
|
|
6
6
|
|
|
7
|
-
Run `npx -y --registry=https://registry.npmjs.org serpkin@0.2.
|
|
7
|
+
Run `npx -y --registry=https://registry.npmjs.org serpkin@0.2.19 check $ARGUMENTS` from the repository root. If no URL was given, ask for the preview URL.
|
|
8
8
|
|
|
9
9
|
Summarize the result: regressions (path, check, production vs preview) and warnings. For each regression, find the code that causes it and propose a fix. Header-level noindex on preview hosts is expected and only a warning.
|
|
@@ -33,7 +33,8 @@ Each run:
|
|
|
33
33
|
- Not connected: anything the summary says is missing (Search Console, ownership, scans).
|
|
34
34
|
- If launch_plan is set (a site new to search): the day of its first 90 days, milestones reached this week and launch_plan.next_step.
|
|
35
35
|
3. If you can work in this site's repository: call serpkin_next_mission, then serpkin_update_mission with action "start", implement its steps, run the tests, open ONE pull request, and call serpkin_submit_result with the pull request URL.
|
|
36
|
-
If
|
|
36
|
+
If there is no mission but saved_idea is set (my saved keyword ideas): call serpkin_explore with its input (action "adopt", no credits; it adds the search to an open mission on that page or makes one mission), then work that mission the same way. At most one saved idea per run.
|
|
37
|
+
If you can't: end the check-in with the next mission's prompt from the summary, or name the saved idea and its plan and ask me whether to make it a mission.
|
|
37
38
|
|
|
38
39
|
Rules:
|
|
39
40
|
- Never merge, deploy or publish. I review and ship.
|
|
@@ -58,6 +59,7 @@ Each run:
|
|
|
58
59
|
- Do this week: 1 to 3 items across all sites from the overview's needs list, most urgent first, each naming its site.
|
|
59
60
|
- Not connected: anything the summary says is missing, with the site it's for.
|
|
60
61
|
3. If you are working in a site's repository: read site_id from its .serpkin.json, call serpkin_next_mission with that site_id, then serpkin_update_mission with action "start", implement its steps, run the tests, open ONE pull request, and call serpkin_submit_result with the pull request URL. One pull request per repository, at most 3 per run.
|
|
62
|
+
If that site has no mission but caught_up.saved_idea is set (my saved keyword ideas): call serpkin_explore with its input (action "adopt", no credits), then work the mission it returns the same way.
|
|
61
63
|
For every other site: end the check-in with its next mission's prompt from the summary, so I can paste it into my coding agent.
|
|
62
64
|
|
|
63
65
|
Rules:
|
|
@@ -5,7 +5,7 @@ argument-hint: "<preview-url> [mission-id]"
|
|
|
5
5
|
|
|
6
6
|
Use the serpkin-seo skill to ship the mission you just implemented (mission id from the arguments, otherwise the one in progress from `serpkin_next_mission`). Arguments: $ARGUMENTS
|
|
7
7
|
|
|
8
|
-
1. Run `npx -y --registry=https://registry.npmjs.org serpkin@0.2.
|
|
8
|
+
1. Run `npx -y --registry=https://registry.npmjs.org serpkin@0.2.19 check <preview-url>`. If it exits 1, fix the regressions, push and run it again.
|
|
9
9
|
2. Call `serpkin_submit_result` with the PR URL, the preview URL and a short summary of the tests you ran.
|
|
10
10
|
3. Call `serpkin_verify_mission`: `environment: "preview"` with the preview_url for technical missions, `environment: "evidence"` for content and research missions.
|
|
11
11
|
4. Report the verification status and tier. After I deploy, verify with `environment: "production"` (Serpkin does this by itself if deploy checks are on in Settings → Automation). Don't merge or deploy.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
description: Show the Serpkin site status, next mission and credits
|
|
3
|
-
allowed-tools: Bash(npx -y --registry=https://registry.npmjs.org serpkin@0.2.
|
|
3
|
+
allowed-tools: Bash(npx -y --registry=https://registry.npmjs.org serpkin@0.2.19 status:*)
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
Run `npx -y --registry=https://registry.npmjs.org serpkin@0.2.
|
|
6
|
+
Run `npx -y --registry=https://registry.npmjs.org serpkin@0.2.19 status` from the repository root and show the output. If it fails because the repository isn't set up, tell me to run `npx serpkin`.
|
|
@@ -26,10 +26,11 @@ An unverified site gets a 6-page preview. To verify it:
|
|
|
26
26
|
|
|
27
27
|
1. **Next mission.** Call `serpkin_next_mission`. If it returns no mission:
|
|
28
28
|
- With `caught_up`: tell the user plainly they're caught up (its `message`), verify anything in `to_verify`, and offer its first suggestion. A suggestion with `credits` above 0 needs the user's yes first. Don't invent work.
|
|
29
|
+
- With `caught_up.saved_idea`: the user saved that search for later. Say what it would do (its `plan` and `why`) and, with their yes, call `serpkin_explore` with its `input` (action `adopt`, no credits). It extends the open mission on that page or creates one; then continue from step 2 with that mission.
|
|
29
30
|
- Otherwise do the `suggested_action` (usually `serpkin_scan_site`) and stop.
|
|
30
31
|
2. **Implement.** First call `serpkin_update_mission` with `action: "start"` so the user and other agents see it is in progress. Research missions are a tool call (`serpkin_research_keywords`), not a code change. Then follow `mission.implementation.steps` in order. Each step names a `file` (from the route map), an `action` (edit, create or run) and an `intent`. Adapt each `snippet` to the existing code; don't paste blindly. Use `recipe` and `acceptance_criteria` for anything the steps don't cover. Keep the change focused on this one mission.
|
|
31
32
|
3. **Run checks.** Run the project's tests, type check and build.
|
|
32
|
-
4. **Check the preview.** Once the branch has a preview deployment, run `npx -y --registry=https://registry.npmjs.org serpkin@0.2.
|
|
33
|
+
4. **Check the preview.** Once the branch has a preview deployment, run `npx -y --registry=https://registry.npmjs.org serpkin@0.2.19 check <preview-url>`. Exit code 1 means regressions; fix them and re-run.
|
|
33
34
|
5. **Submit.** Call `serpkin_submit_result` with the PR URL, preview URL and a short test summary.
|
|
34
35
|
6. **Verify the preview.** Technical missions: `serpkin_verify_mission` with `environment: "preview"` and `preview_url`. Content and research missions: `environment: "evidence"`.
|
|
35
36
|
7. **Verify production.** Only after the human has merged and deployed, call `serpkin_verify_mission` with `environment: "production"`. If deploy checks are on (Settings → Automation), Serpkin does this by itself after the deploy.
|
|
@@ -51,13 +52,24 @@ For "what should I research?", "who are my competitors?" or "what should my site
|
|
|
51
52
|
|
|
52
53
|
## Skipping a mission
|
|
53
54
|
|
|
54
|
-
If the user says a mission isn't relevant, is already done or isn't worth it now, call `serpkin_update_mission` with `action: "dismiss"` and the matching `reason` (`not_relevant`, `already_done`, `too_much_work`, `disagree`, `other`), plus their words as `note`. Two "not relevant" dismissals of one kind make Serpkin rank that kind lower for the site. `action: "restore"` brings a mission back.
|
|
55
|
+
If the user says a mission isn't relevant, is already done or isn't worth it now, call `serpkin_update_mission` with `action: "dismiss"` and the matching `reason` (`not_relevant`, `already_done`, `too_much_work`, `disagree`, `other`), plus their words as `note`. Two "not relevant" dismissals of one kind make Serpkin rank that kind lower for the site. `action: "restore"` brings a mission back. Mission ids from lists (8 characters) work in every tool.
|
|
56
|
+
|
|
57
|
+
## Outreach and waiting on others
|
|
58
|
+
|
|
59
|
+
For missions that end with someone else deciding (`brand_mentions`, `directory_listing`, `link_outreach`, `tool_links`): draft the pitches or the listing kit; the user sends or submits them. Log each contact with `serpkin_update_mission` `action: "log_outreach"` and `outreach: [{target, contact, channel, sent_at?, kind: "first"|"follow_up"}]`, then `action: "wait"` (optional `follow_up_days`, 7–30, default 10). The mission leaves the queue and comes back with `follow_up_due: true` and a follow-up step: draft one short, polite follow-up per contact without a reply, nothing more. `outreach_status` lists targets still not contacted. When a mention goes live, record its URL with `serpkin_submit_result` (works from waiting).
|
|
55
60
|
|
|
56
61
|
## Free tools, comparison pages and directories
|
|
57
62
|
|
|
58
63
|
- **`new_tool`** (a calculator, generator, checker, converter, template or quiz): put the logic in a pure function with unit tests, render labelled inputs in the server HTML with a sensible default result, then write the explanation (how it works, a worked example, limits; at least 300 words). Offer an embed with a credit link: free tools earn links.
|
|
59
64
|
- **`new_comparison`** ("x vs y", "x alternatives", "best x"): a sourced comparison table, the date the facts were checked, a plain statement that you make one of the products, and who each option fits. No invented ratings or reviews, no borrowed logos, no Review markup about other products.
|
|
60
65
|
- **`directory_listing`**: draft one listing kit in the repository (`marketing/listing-kit.md`) from the site's real copy and hand `growth.directories` to the user. Never submit listings or create accounts yourself.
|
|
66
|
+
- **`landing_page`** (a search naming a product or use case, "invoicing software for freelancers"): first confirm the product really serves it, otherwise dismiss as not relevant. Build it in the marketing section with the site's own components: the use case in the searcher's words, the problem, the features that solve it, proof you can source, pricing, a call to action and an FAQ. No invented customers, quotes or numbers.
|
|
67
|
+
- **`brand_search`**: lead the homepage title with the product name, add Organization JSON-LD (name, url, logo, sameAs with the official profiles) and WebSite JSON-LD with the same name.
|
|
68
|
+
- **`topic_hub`**, **`prune_content`**, **`rss_feed`** (blogs): a hub page that adds an overview and a reading order, not just links; each old post is refreshed, merged with a 301 or retired (410 or noindex), with keepers listed in `artifacts.excluded_pages`; a feed at a stable address announced with `<link rel="alternate" type="application/rss+xml">`.
|
|
69
|
+
|
|
70
|
+
## Sites built in a hosted CMS
|
|
71
|
+
|
|
72
|
+
When a mission has `cms` (WordPress, Ghost, Webflow, Wix, Squarespace, Framer, Shopify, HubSpot), there is usually no repository to change: its first step says where the setting lives in that dashboard. Prepare the exact change (copy, settings, any snippet) for the user to apply, unless you have access to the CMS's admin or API. If a repository does render the site (a headless front end), work there.
|
|
61
73
|
|
|
62
74
|
## Content decay missions
|
|
63
75
|
|
|
@@ -37,4 +37,4 @@ jobs:
|
|
|
37
37
|
# Passed through env, not interpolated into the script, so the URL can't inject shell.
|
|
38
38
|
PREVIEW_URL: ${{ github.event.deployment_status.target_url }}
|
|
39
39
|
# Pinned version and registry; update the version deliberately.
|
|
40
|
-
run: npx --yes --registry=https://registry.npmjs.org serpkin@0.2.
|
|
40
|
+
run: npx --yes --registry=https://registry.npmjs.org serpkin@0.2.19 check "$PREVIEW_URL" --site "$SERPKIN_SITE_ID"
|
|
@@ -89,6 +89,14 @@ jobs:
|
|
|
89
89
|
}
|
|
90
90
|
tool "$(jq -nc --arg s "$SERPKIN_SITE_ID" '{tool:"serpkin_next_mission",input:{site_id:$s}}')" > "$RUNNER_TEMP/next.json"
|
|
91
91
|
id=$(jq -r '.result.mission.id // empty' "$RUNNER_TEMP/next.json")
|
|
92
|
+
# Nothing in the queue: act on the owner's saved keyword idea (no credits), then ask for the mission again.
|
|
93
|
+
idea=$(jq -r '.result.caught_up.saved_idea.phrase // empty' "$RUNNER_TEMP/next.json")
|
|
94
|
+
if [ -z "$id" ] && [ -n "$idea" ]; then
|
|
95
|
+
tool "$(jq -nc --arg s "$SERPKIN_SITE_ID" --arg p "$idea" --arg k "weekly-adopt-$GITHUB_RUN_ID" \
|
|
96
|
+
'{tool:"serpkin_explore",input:{site_id:$s,action:"adopt",phrase:$p,idempotency_key:$k}}')" > /dev/null || echo "::notice::Couldn't act on the saved idea."
|
|
97
|
+
tool "$(jq -nc --arg s "$SERPKIN_SITE_ID" '{tool:"serpkin_next_mission",input:{site_id:$s}}')" > "$RUNNER_TEMP/next.json"
|
|
98
|
+
id=$(jq -r '.result.mission.id // empty' "$RUNNER_TEMP/next.json")
|
|
99
|
+
fi
|
|
92
100
|
if [ -z "$id" ]; then
|
|
93
101
|
echo "::notice::No open mission. $(jq -r '.result.suggested_action // ""' "$RUNNER_TEMP/next.json")"
|
|
94
102
|
echo "found=false" >> "$GITHUB_OUTPUT"; exit 0
|