@canonry/canonry 4.132.0 → 4.133.0

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 (25) hide show
  1. package/assets/assets/{AuditHistoryPanel-Carj_FCP.js → AuditHistoryPanel-CVDg3GXg.js} +1 -1
  2. package/assets/assets/{BacklinksPage-CqOTDVIn.js → BacklinksPage-Dh4RIvS7.js} +1 -1
  3. package/assets/assets/{ChartPrimitives-EuQ82l0S.js → ChartPrimitives-BK89G5H_.js} +1 -1
  4. package/assets/assets/{HistoryPage-D6XQfiLX.js → HistoryPage-D8rMu_Js.js} +1 -1
  5. package/assets/assets/{ProjectPage-Dswa9Ah6.js → ProjectPage-CiTDveNK.js} +1 -1
  6. package/assets/assets/{RunRow-ThryEZFR.js → RunRow-DVOwbmTp.js} +1 -1
  7. package/assets/assets/{RunsPage-RFs2WkTC.js → RunsPage-tz3Oil7N.js} +1 -1
  8. package/assets/assets/{SettingsPage-DoUccn9s.js → SettingsPage-C698YidM.js} +1 -1
  9. package/assets/assets/{TrafficPage-CVvSDZPY.js → TrafficPage-XDXWMtey.js} +1 -1
  10. package/assets/assets/{TrafficSourceDetailPage-BTUQUBeS.js → TrafficSourceDetailPage-Clz8kOR8.js} +1 -1
  11. package/assets/assets/{arrow-left-BoCNqusn.js → arrow-left-GWLbh0pE.js} +1 -1
  12. package/assets/assets/{extract-error-message-BsfOVrKi.js → extract-error-message-Dk8w-sb1.js} +1 -1
  13. package/assets/assets/index-jTshRRh0.js +210 -0
  14. package/assets/assets/{trash-2-BPb4368K.js → trash-2-DwnzsuH1.js} +1 -1
  15. package/assets/index.html +1 -1
  16. package/dist/{chunk-RWTOEEG3.js → chunk-42P7POVS.js} +4 -4
  17. package/dist/{chunk-5FWAPJFX.js → chunk-P4MIG7V5.js} +37 -1
  18. package/dist/{chunk-QIJKS5KN.js → chunk-VPY3PZXV.js} +1745 -1233
  19. package/dist/{chunk-7BD2ZOPV.js → chunk-ZPQX5ZQ2.js} +654 -555
  20. package/dist/cli.js +76 -10
  21. package/dist/index.js +4 -4
  22. package/dist/{intelligence-service-RU2ACYPY.js → intelligence-service-2K7GVEQM.js} +2 -2
  23. package/dist/mcp.js +2 -2
  24. package/package.json +9 -9
  25. package/assets/assets/index-jJurRky0.js +0 -210
package/dist/cli.js CHANGED
@@ -29,7 +29,7 @@ import {
29
29
  setTelemetrySource,
30
30
  showFirstRunNotice,
31
31
  trackEvent
32
- } from "./chunk-RWTOEEG3.js";
32
+ } from "./chunk-42P7POVS.js";
33
33
  import {
34
34
  CliError,
35
35
  EXIT_SYSTEM_ERROR,
@@ -46,7 +46,7 @@ import {
46
46
  saveConfig,
47
47
  saveConfigPatch,
48
48
  usageError
49
- } from "./chunk-5FWAPJFX.js";
49
+ } from "./chunk-P4MIG7V5.js";
50
50
  import {
51
51
  apiKeys,
52
52
  createClient,
@@ -54,7 +54,7 @@ import {
54
54
  projects,
55
55
  queries,
56
56
  renderReportHtml
57
- } from "./chunk-QIJKS5KN.js";
57
+ } from "./chunk-VPY3PZXV.js";
58
58
  import {
59
59
  AdsOperationKinds,
60
60
  AdsOperationStates,
@@ -97,7 +97,7 @@ import {
97
97
  providerQuotaPolicySchema,
98
98
  resolveProviderInput,
99
99
  winnabilityClassSchema
100
- } from "./chunk-7BD2ZOPV.js";
100
+ } from "./chunk-ZPQX5ZQ2.js";
101
101
 
102
102
  // src/cli.ts
103
103
  import { pathToFileURL } from "url";
@@ -9405,6 +9405,70 @@ var REPORT_CLI_COMMANDS = [
9405
9405
  }
9406
9406
  ];
9407
9407
 
9408
+ // src/commands/organic-evidence.ts
9409
+ async function showOrganicEvidence(project, opts) {
9410
+ const data = await createApiClient().getOrganicEvidence(project, opts.period);
9411
+ if (isMachineFormat(opts.format)) {
9412
+ console.log(JSON.stringify(data, null, 2));
9413
+ return;
9414
+ }
9415
+ printOrganicEvidence(project, data);
9416
+ }
9417
+ function formatCounts(clicks, impressions) {
9418
+ return `${clicks} clicks / ${impressions} impressions`;
9419
+ }
9420
+ function printOrganicEvidence(project, data) {
9421
+ const asOf = data.asOfDate ? ` through ${data.asOfDate}` : "";
9422
+ console.log(`Organic evidence: ${project} (${data.periodDays} days${asOf})`);
9423
+ console.log(`Coverage: GSC ${data.coverage.gsc ? "yes" : "no"} \xB7 GA4 ${data.coverage.ga4 ? "yes" : "no"} \xB7 server ${data.coverage.server ? "yes" : "no"} \xB7 AI visibility ${data.coverage.visibility ? "yes" : "no"}`);
9424
+ if (data.gsc) {
9425
+ console.log(`Google Search: ${formatCounts(data.gsc.propertyTotals.clicks, data.gsc.propertyTotals.impressions)} (named non-brand: ${formatCounts(data.gsc.namedNonBrand.clicks, data.gsc.namedNonBrand.impressions)})`);
9426
+ }
9427
+ if (data.ga4) console.log(`GA4 organic: ${data.ga4.organicSessions} sessions`);
9428
+ if (data.gaAiReferrals) console.log(`GA4 AI referrals: ${data.gaAiReferrals.organicSessions} organic, ${data.gaAiReferrals.paidSessions} paid sessions`);
9429
+ if (data.server) {
9430
+ const s = data.server;
9431
+ const fetchTotal = s.userFetchHits.verified + s.userFetchHits.claimedUnverified + s.userFetchHits.unknownAiLike;
9432
+ console.log(`Server AI: ${s.crawlerHits.verified} verified + ${s.crawlerHits.claimedUnverified} claimed + ${s.crawlerHits.unknownAiLike} heuristic crawls; ${fetchTotal} user-agent fetches (${s.userFetchHits.verified} verified, ${s.userFetchHits.claimedUnverified} claimed, ${s.userFetchHits.unknownAiLike} heuristic); ${s.referralSessions.organic} organic referrals, ${s.referralSessions.paid} paid, ${s.referralSessions.unknown} unclassified`);
9433
+ }
9434
+ if (data.visibility) {
9435
+ const v = data.visibility;
9436
+ console.log(`Latest AI visibility: ${v.mentionedPairs}/${v.answerPairs} mentioned, ${v.citedPairs}/${v.answerPairs} cited (${Math.floor(v.ageDays)}d old)`);
9437
+ }
9438
+ if (data.findings.length > 0) {
9439
+ console.log("\nFindings:");
9440
+ for (const finding of data.findings) console.log(`- ${finding.title}: ${finding.detail}`);
9441
+ }
9442
+ if (data.limitations.length > 0) {
9443
+ console.log("\nLimitations:");
9444
+ for (const limitation of data.limitations) console.log(`- ${limitation.detail}`);
9445
+ }
9446
+ }
9447
+
9448
+ // src/cli-commands/organic-evidence.ts
9449
+ var USAGE4 = "canonry organic-evidence <project> [--period 60|90] [--format json|jsonl]";
9450
+ function parsePeriod2(value) {
9451
+ if (value === void 0) return void 0;
9452
+ if (value === "60" || value === "90") return Number(value);
9453
+ throw usageError(`Error: --period must be 60 or 90
9454
+
9455
+ Usage: ${USAGE4}`);
9456
+ }
9457
+ var ORGANIC_EVIDENCE_CLI_COMMANDS = [
9458
+ {
9459
+ path: ["organic-evidence"],
9460
+ usage: USAGE4,
9461
+ options: { period: stringOption() },
9462
+ run: async (input) => {
9463
+ const project = requireProject(input, "organic-evidence", USAGE4);
9464
+ await showOrganicEvidence(project, {
9465
+ period: parsePeriod2(getString(input.values, "period")),
9466
+ format: input.format
9467
+ });
9468
+ }
9469
+ }
9470
+ ];
9471
+
9408
9472
  // src/commands/run.ts
9409
9473
  function getClient22() {
9410
9474
  return createApiClient();
@@ -13304,12 +13368,12 @@ function printVisibilityStats(data) {
13304
13368
  }
13305
13369
 
13306
13370
  // src/cli-commands/visibility-stats.ts
13307
- var USAGE4 = "canonry visibility-stats <project> [--since <iso>] [--until <iso>] [--month <YYYY-MM>] [--last-runs <n>] [--by-provider] [--share-of-voice] [--format json|jsonl]";
13371
+ var USAGE5 = "canonry visibility-stats <project> [--since <iso>] [--until <iso>] [--month <YYYY-MM>] [--last-runs <n>] [--by-provider] [--share-of-voice] [--format json|jsonl]";
13308
13372
  var COMPARE_USAGE = "canonry visibility-compare <project> --from <YYYY-MM> --to <YYYY-MM> [--format json]";
13309
13373
  var VISIBILITY_STATS_CLI_COMMANDS = [
13310
13374
  {
13311
13375
  path: ["visibility-stats"],
13312
- usage: USAGE4,
13376
+ usage: USAGE5,
13313
13377
  options: {
13314
13378
  since: stringOption(),
13315
13379
  until: stringOption(),
@@ -13319,14 +13383,14 @@ var VISIBILITY_STATS_CLI_COMMANDS = [
13319
13383
  "share-of-voice": { type: "boolean", default: false }
13320
13384
  },
13321
13385
  run: async (input) => {
13322
- const project = requireProject(input, "visibility-stats", USAGE4);
13386
+ const project = requireProject(input, "visibility-stats", USAGE5);
13323
13387
  await showVisibilityStats(project, {
13324
13388
  since: getString(input.values, "since"),
13325
13389
  until: getString(input.values, "until"),
13326
13390
  month: getString(input.values, "month"),
13327
13391
  lastRuns: parseIntegerOption(input, "last-runs", {
13328
13392
  command: "visibility-stats",
13329
- usage: USAGE4,
13393
+ usage: USAGE5,
13330
13394
  message: "--last-runs must be an integer"
13331
13395
  }),
13332
13396
  byProvider: getBoolean(input.values, "by-provider"),
@@ -14933,6 +14997,7 @@ var REGISTERED_CLI_COMMANDS = [
14933
14997
  ...SYSTEM_CLI_COMMANDS,
14934
14998
  ...PROJECT_CLI_COMMANDS,
14935
14999
  ...REPORT_CLI_COMMANDS,
15000
+ ...ORGANIC_EVIDENCE_CLI_COMMANDS,
14936
15001
  ...QUERY_CLI_COMMANDS,
14937
15002
  ...KEYWORD_CLI_COMMANDS,
14938
15003
  ...KEYS_CLI_COMMANDS,
@@ -14966,7 +15031,7 @@ var REGISTERED_CLI_COMMANDS = [
14966
15031
 
14967
15032
  // src/cli.ts
14968
15033
  import { createRequire as createRequire2 } from "module";
14969
- var USAGE5 = `
15034
+ var USAGE6 = `
14970
15035
  cnry \u2014 AEO monitoring CLI ('canonry' also works)
14971
15036
 
14972
15037
  Usage: cnry <command> [options]
@@ -14989,6 +15054,7 @@ Monitoring:
14989
15054
  status <project> Show project summary
14990
15055
  evidence <project> Show per-query results
14991
15056
  analytics <project> Show analytics (metrics, gaps, sources)
15057
+ organic-evidence Reconcile 60/90d search, GA4, and server AI evidence
14992
15058
  insights <project> Show intelligence insights
14993
15059
  health <project> Show citation health
14994
15060
 
@@ -15031,7 +15097,7 @@ function extractFormat(cmdArgs) {
15031
15097
  }
15032
15098
  async function runCli(args = process.argv.slice(2)) {
15033
15099
  if (args.length === 0 || args[0] === "--help" || args[0] === "-h") {
15034
- console.log(USAGE5);
15100
+ console.log(USAGE6);
15035
15101
  return 0;
15036
15102
  }
15037
15103
  if (args.includes("--version") || args.includes("-v")) {
package/dist/index.js CHANGED
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  createServer
3
- } from "./chunk-RWTOEEG3.js";
3
+ } from "./chunk-42P7POVS.js";
4
4
  import {
5
5
  loadConfig
6
- } from "./chunk-5FWAPJFX.js";
7
- import "./chunk-QIJKS5KN.js";
8
- import "./chunk-7BD2ZOPV.js";
6
+ } from "./chunk-P4MIG7V5.js";
7
+ import "./chunk-VPY3PZXV.js";
8
+ import "./chunk-ZPQX5ZQ2.js";
9
9
  export {
10
10
  createServer,
11
11
  loadConfig
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  IntelligenceService
3
- } from "./chunk-QIJKS5KN.js";
4
- import "./chunk-7BD2ZOPV.js";
3
+ } from "./chunk-VPY3PZXV.js";
4
+ import "./chunk-ZPQX5ZQ2.js";
5
5
  export {
6
6
  IntelligenceService
7
7
  };
package/dist/mcp.js CHANGED
@@ -3,10 +3,10 @@ import {
3
3
  PACKAGE_VERSION,
4
4
  canonryMcpTools,
5
5
  createApiClient
6
- } from "./chunk-5FWAPJFX.js";
6
+ } from "./chunk-P4MIG7V5.js";
7
7
  import {
8
8
  isReadOnlyKey
9
- } from "./chunk-7BD2ZOPV.js";
9
+ } from "./chunk-ZPQX5ZQ2.js";
10
10
 
11
11
  // src/mcp/cli.ts
12
12
  import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@canonry/canonry",
3
- "version": "4.132.0",
3
+ "version": "4.133.0",
4
4
  "type": "module",
5
5
  "description": "Agent-first open-source AEO operating platform - track how answer engines cite your domain",
6
6
  "license": "FSL-1.1-ALv2",
@@ -67,25 +67,25 @@
67
67
  "tsx": "^4.19.0",
68
68
  "@ainyc/canonry-api-client": "0.0.0",
69
69
  "@ainyc/canonry-api-routes": "0.0.0",
70
- "@ainyc/canonry-db": "0.0.0",
71
70
  "@ainyc/canonry-config": "0.0.0",
72
71
  "@ainyc/canonry-contracts": "0.0.0",
72
+ "@ainyc/canonry-db": "0.0.0",
73
73
  "@ainyc/canonry-integration-bing": "0.0.0",
74
74
  "@ainyc/canonry-integration-openai-ads": "0.0.0",
75
- "@ainyc/canonry-integration-commoncrawl": "0.0.0",
75
+ "@ainyc/canonry-integration-cloud-run": "0.0.0",
76
76
  "@ainyc/canonry-integration-google": "0.0.0",
77
+ "@ainyc/canonry-integration-commoncrawl": "0.0.0",
77
78
  "@ainyc/canonry-integration-google-business-profile": "0.0.0",
78
- "@ainyc/canonry-integration-cloud-run": "0.0.0",
79
+ "@ainyc/canonry-integration-google-places": "0.0.0",
79
80
  "@ainyc/canonry-integration-traffic": "0.0.0",
80
- "@ainyc/canonry-integration-wordpress": "0.0.0",
81
81
  "@ainyc/canonry-intelligence": "0.0.0",
82
- "@ainyc/canonry-integration-google-places": "0.0.0",
83
82
  "@ainyc/canonry-provider-cdp": "0.0.0",
84
83
  "@ainyc/canonry-provider-claude": "0.0.0",
85
- "@ainyc/canonry-provider-gemini": "0.0.0",
84
+ "@ainyc/canonry-integration-wordpress": "0.0.0",
86
85
  "@ainyc/canonry-provider-local": "0.0.0",
87
- "@ainyc/canonry-provider-perplexity": "0.0.0",
88
- "@ainyc/canonry-provider-openai": "0.0.0"
86
+ "@ainyc/canonry-provider-gemini": "0.0.0",
87
+ "@ainyc/canonry-provider-openai": "0.0.0",
88
+ "@ainyc/canonry-provider-perplexity": "0.0.0"
89
89
  },
90
90
  "scripts": {
91
91
  "build": "tsx scripts/copy-agent-assets.ts && tsup && tsx build-web.ts",