@rankcli/mcp-server 0.0.5 → 0.0.6

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.
Files changed (2) hide show
  1. package/dist/index.js +9 -16
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -525,20 +525,6 @@ async function pollConnectStatus(connectId, timeoutMs) {
525
525
  }
526
526
  return null;
527
527
  }
528
- function backgroundAwaitConnect(connectId) {
529
- pollConnectStatus(connectId, 5 * 6e4).then(async (claimed) => {
530
- if (claimed) {
531
- localConfig.set("apiKey", claimed.apiKey);
532
- localConfig.set("apiKeyName", claimed.apiKeyName);
533
- localConfig.set("email", claimed.email);
534
- if (localConfig.get("pendingConnectId") === connectId) clearPendingConnect();
535
- }
536
- await server.createElicitationCompletionNotifier(connectId)().catch(() => {
537
- });
538
- }).catch((err) => {
539
- console.error("rankcli_connect: background poll failed:", err);
540
- });
541
- }
542
528
  function clearPendingConnect() {
543
529
  localConfig.delete("pendingConnectId");
544
530
  localConfig.delete("pendingConnectUrl");
@@ -601,8 +587,15 @@ Expires in ${minutesLeft} minute${minutesLeft === 1 ? "" : "s"}.`
601
587
  elicitationId: connectId
602
588
  });
603
589
  if (result.action === "accept") {
604
- backgroundAwaitConnect(connectId);
605
- return { text: "Opening rankcli.dev to connect your account - I'll let you know as soon as it's done." };
590
+ const claimed = await pollConnectStatus(connectId, 1e4);
591
+ if (claimed) {
592
+ localConfig.set("apiKey", claimed.apiKey);
593
+ localConfig.set("apiKeyName", claimed.apiKeyName);
594
+ localConfig.set("email", claimed.email);
595
+ clearPendingConnect();
596
+ return { text: `Connected as ${claimed.email}! Your dashboard, GitHub auto-fix PRs, and audit history are now linked to this AI assistant.` };
597
+ }
598
+ return { text: `Opened rankcli.dev in your browser. Still waiting for approval - run rankcli_connect again once you've approved it (expires in ${expiresMinutes} minutes).` };
606
599
  }
607
600
  clearPendingConnect();
608
601
  return { text: "Connection cancelled." };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@rankcli/mcp-server",
3
- "version": "0.0.5",
3
+ "version": "0.0.6",
4
4
  "mcpName": "io.github.integrallis/rankcli-mcp-server",
5
5
  "description": "Free, local SEO + GEO (AI-search-citation) analysis for AI assistants - audits GEO/AI-crawler access, Core Web Vitals, structured data, security headers, mobile, and images with no signup or API key.",
6
6
  "type": "module",