@fload-ai/mcp 0.9.0 → 0.10.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.
@@ -1 +1 @@
1
- {"version":3,"file":"actions.d.ts","sourceRoot":"","sources":["../../src/tools/actions.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAsCvD,eAAO,MAAM,wBAAwB;;;;;;;iBAenC,CAAC;AAEH,eAAO,MAAM,mBAAmB;;iBAI9B,CAAC;AAEH,eAAO,MAAM,kBAAkB;;;iBAa7B,CAAC;AAGH,eAAO,MAAM,oBAAoB;;iBAM/B,CAAC;AAGH,eAAO,MAAM,4BAA4B;;;iBAcvC,CAAC;AAiCH,wBAAsB,kBAAkB,CACtC,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,EAC/C,MAAM,EAAE,cAAc;;;;;;GAgBvB;AA0DD,wBAAsB,aAAa,CACjC,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,EAC1C,MAAM,EAAE,cAAc;;;;;;GA6BvB;AAGD,wBAAsB,YAAY,CAChC,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,EACzC,MAAM,EAAE,cAAc;;;;;;GA8BvB;AAOD,wBAAsB,cAAc,CAClC,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,EAC3C,MAAM,EAAE,cAAc;;;;;;GAqCvB;AAyED,wBAAsB,sBAAsB,CAC1C,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,4BAA4B,CAAC,EACnD,MAAM,EAAE,cAAc;;;;;;GAwDvB"}
1
+ {"version":3,"file":"actions.d.ts","sourceRoot":"","sources":["../../src/tools/actions.ts"],"names":[],"mappings":"AAaA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AA2CvD,eAAO,MAAM,wBAAwB;;;;;;;iBAenC,CAAC;AAEH,eAAO,MAAM,mBAAmB;;iBAI9B,CAAC;AAEH,eAAO,MAAM,kBAAkB;;;iBAa7B,CAAC;AAGH,eAAO,MAAM,oBAAoB;;iBAM/B,CAAC;AAGH,eAAO,MAAM,4BAA4B;;;iBAcvC,CAAC;AAiCH,wBAAsB,kBAAkB,CACtC,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,EAC/C,MAAM,EAAE,cAAc;;;;;;GAgBvB;AAoED,wBAAsB,aAAa,CACjC,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,EAC1C,MAAM,EAAE,cAAc;;;;;;GA6BvB;AAGD,wBAAsB,YAAY,CAChC,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,EACzC,MAAM,EAAE,cAAc;;;;;;GA8BvB;AAOD,wBAAsB,cAAc,CAClC,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,EAC3C,MAAM,EAAE,cAAc;;;;;;GAqCvB;AAyED,wBAAsB,sBAAsB,CAC1C,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,4BAA4B,CAAC,EACnD,MAAM,EAAE,cAAc;;;;;;GAwDvB"}
@@ -0,0 +1,27 @@
1
+ import { z } from 'zod';
2
+ import type { FloadApiClient } from '../api-client.js';
3
+ export declare const getDownloadImpactSchema: z.ZodObject<{
4
+ assetId: z.ZodString;
5
+ from: z.ZodOptional<z.ZodString>;
6
+ to: z.ZodOptional<z.ZodString>;
7
+ beforeFrom: z.ZodOptional<z.ZodString>;
8
+ beforeTo: z.ZodOptional<z.ZodString>;
9
+ afterFrom: z.ZodOptional<z.ZodString>;
10
+ afterTo: z.ZodOptional<z.ZodString>;
11
+ country: z.ZodOptional<z.ZodString>;
12
+ includeDays: z.ZodOptional<z.ZodBoolean>;
13
+ }, z.core.$strip>;
14
+ export declare function getDownloadImpact(input: z.input<typeof getDownloadImpactSchema>, client: FloadApiClient): Promise<{
15
+ content: {
16
+ type: "text";
17
+ text: string;
18
+ }[];
19
+ isError?: undefined;
20
+ } | {
21
+ content: {
22
+ type: "text";
23
+ text: string;
24
+ }[];
25
+ isError: boolean;
26
+ }>;
27
+ //# sourceMappingURL=download-impact.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"download-impact.d.ts","sourceRoot":"","sources":["../../src/tools/download-impact.ts"],"names":[],"mappings":"AAOA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AAQvD,eAAO,MAAM,uBAAuB;;;;;;;;;;iBA2BlC,CAAC;AAQH,wBAAsB,iBAAiB,CACrC,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,EAC9C,MAAM,EAAE,cAAc;;;;;;;;;;;;GAyBvB"}
@@ -4,6 +4,7 @@ import { RateLimiter } from '../rate-limiter.js';
4
4
  export * from './apps.js';
5
5
  export * from './reviews.js';
6
6
  export * from './analytics.js';
7
+ export * from './download-impact.js';
7
8
  export * from './agents.js';
8
9
  export * from './ads.js';
9
10
  export * from './dashboard.js';
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/tools/index.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EACV,SAAS,EAEV,MAAM,yCAAyC,CAAC;AAGjD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AACvD,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAEjD,cAAc,WAAW,CAAC;AAC1B,cAAc,cAAc,CAAC;AAC7B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,aAAa,CAAC;AAC5B,cAAc,UAAU,CAAC;AACzB,cAAc,gBAAgB,CAAC;AAC/B,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAoF1B,MAAM,WAAW,oBAAoB;IAMnC,WAAW,CAAC,EAAE,WAAW,CAAC;CAC3B;AAoBD,wBAAgB,aAAa,CAC3B,MAAM,EAAE,SAAS,EACjB,MAAM,EAAE,cAAc,EACtB,OAAO,GAAE,oBAAyB,GACjC,IAAI,CAmVN"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/tools/index.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EACV,SAAS,EAEV,MAAM,yCAAyC,CAAC;AAGjD,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kBAAkB,CAAC;AACvD,OAAO,EAAE,WAAW,EAAE,MAAM,oBAAoB,CAAC;AAEjD,cAAc,WAAW,CAAC;AAC1B,cAAc,cAAc,CAAC;AAC7B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,sBAAsB,CAAC;AACrC,cAAc,aAAa,CAAC;AAC5B,cAAc,UAAU,CAAC;AACzB,cAAc,gBAAgB,CAAC;AAC/B,cAAc,cAAc,CAAC;AAC7B,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC;AAwF1B,MAAM,WAAW,oBAAoB;IAMnC,WAAW,CAAC,EAAE,WAAW,CAAC;CAC3B;AAoBD,wBAAgB,aAAa,CAC3B,MAAM,EAAE,SAAS,EACjB,MAAM,EAAE,cAAc,EACtB,OAAO,GAAE,oBAAyB,GACjC,IAAI,CA4VN"}
@@ -704,8 +704,58 @@ async function discoverDimensions(input, client) {
704
704
  }
705
705
  }
706
706
 
707
- // src/tools/agents.ts
707
+ // src/tools/download-impact.ts
708
708
  import { z as z4 } from "zod";
709
+ var Day = z4.string().regex(/^\d{4}-\d{2}-\d{2}$/).optional();
710
+ var getDownloadImpactSchema = z4.object({
711
+ assetId: z4.string().uuid().describe("App UUID (App Store apps)"),
712
+ from: Day.describe(
713
+ "First day drawn (YYYY-MM-DD); default 20 weeks before `to`"
714
+ ),
715
+ to: Day.describe(
716
+ "Last day drawn (YYYY-MM-DD); default the newest day with data"
717
+ ),
718
+ beforeFrom: Day.describe(
719
+ 'Start of the "before" window compared (needs beforeTo; all windows within 400 days of each other)'
720
+ ),
721
+ beforeTo: Day.describe('End of the "before" window compared'),
722
+ afterFrom: Day.describe(
723
+ 'Start of the "after" window compared (needs afterTo)'
724
+ ),
725
+ afterTo: Day.describe('End of the "after" window compared'),
726
+ country: z4.string().regex(/^[a-zA-Z]{2}$/).optional().describe(
727
+ 'One storefront, two-letter code (e.g. "us"): narrows countries and keywords'
728
+ ),
729
+ includeDays: z4.boolean().optional().describe("Also return every day (long). Weeks carry the same downloads.")
730
+ });
731
+ async function getDownloadImpact(input, client) {
732
+ try {
733
+ const { assetId, includeDays, ...query } = input;
734
+ const impact = await client.get(
735
+ `/api/assets/${assetId}/metrics/download-impact`,
736
+ query
737
+ );
738
+ const { days, lastYearDays, ...rest } = impact;
739
+ return {
740
+ content: [
741
+ {
742
+ type: "text",
743
+ text: formatAsJson(
744
+ includeDays ? { ...rest, days, lastYearDays } : rest
745
+ )
746
+ }
747
+ ]
748
+ };
749
+ } catch (error) {
750
+ return {
751
+ content: [{ type: "text", text: formatError(error) }],
752
+ isError: true
753
+ };
754
+ }
755
+ }
756
+
757
+ // src/tools/agents.ts
758
+ import { z as z5 } from "zod";
709
759
  function asRecord(value) {
710
760
  return value && typeof value === "object" && !Array.isArray(value) ? value : {};
711
761
  }
@@ -714,28 +764,28 @@ var AGENT_DESCRIPTIONS = {
714
764
  review: "AI-powered review management \u2014 drafts and sends replies to app store reviews",
715
765
  aso: "App Store Optimization \u2014 listing optimization suggestions for better visibility"
716
766
  };
717
- var listAgentsSchema = z4.object({});
718
- var getAgentDetailsSchema = z4.object({
719
- agentType: z4.enum(AGENT_TYPES).describe("The type of agent to get details for"),
720
- assetId: z4.string().uuid().optional().describe("App UUID to get agent config for (when agent is per-asset)")
767
+ var listAgentsSchema = z5.object({});
768
+ var getAgentDetailsSchema = z5.object({
769
+ agentType: z5.enum(AGENT_TYPES).describe("The type of agent to get details for"),
770
+ assetId: z5.string().uuid().optional().describe("App UUID to get agent config for (when agent is per-asset)")
721
771
  });
722
- var getAgentRunHistorySchema = z4.object({
723
- agentType: z4.enum(AGENT_TYPES).describe("The type of agent to get run history for"),
724
- assetId: z4.string().uuid().optional().describe("App UUID to filter runs"),
725
- limit: z4.number().int().min(1).max(100).default(20).describe("Maximum number of runs to return")
772
+ var getAgentRunHistorySchema = z5.object({
773
+ agentType: z5.enum(AGENT_TYPES).describe("The type of agent to get run history for"),
774
+ assetId: z5.string().uuid().optional().describe("App UUID to filter runs"),
775
+ limit: z5.number().int().min(1).max(100).default(20).describe("Maximum number of runs to return")
726
776
  });
727
- var triggerAgentRunSchema = z4.object({
728
- agentId: z4.string().describe("The agent ID to trigger a run for (the `id` from list_agents)"),
729
- assetId: z4.string().uuid().optional().describe("Optional app UUID to run the agent against")
777
+ var triggerAgentRunSchema = z5.object({
778
+ agentId: z5.string().describe("The agent ID to trigger a run for (the `id` from list_agents)"),
779
+ assetId: z5.string().uuid().optional().describe("Optional app UUID to run the agent against")
730
780
  });
731
- var pauseAgentSchema = z4.object({
732
- agentId: z4.string().describe("The agent ID to pause (the `id` from list_agents)")
781
+ var pauseAgentSchema = z5.object({
782
+ agentId: z5.string().describe("The agent ID to pause (the `id` from list_agents)")
733
783
  });
734
- var resumeAgentSchema = z4.object({
735
- agentId: z4.string().describe("The agent ID to resume (the `id` from list_agents)")
784
+ var resumeAgentSchema = z5.object({
785
+ agentId: z5.string().describe("The agent ID to resume (the `id` from list_agents)")
736
786
  });
737
- var getAgentActivitySchema = z4.object({
738
- agentId: z4.string().describe("The agent ID to get activity for (the `id` from list_agents)")
787
+ var getAgentActivitySchema = z5.object({
788
+ agentId: z5.string().describe("The agent ID to get activity for (the `id` from list_agents)")
739
789
  });
740
790
  async function listAgents(_input, client) {
741
791
  try {
@@ -993,13 +1043,13 @@ async function getAgentActivity(input, client) {
993
1043
  }
994
1044
 
995
1045
  // src/tools/ads.ts
996
- import { z as z5 } from "zod";
997
- var getAdsPerformanceSchema = z5.object({
998
- assetId: z5.string().uuid().optional().describe("Filter by app UUID"),
999
- platform: z5.enum(["apple_search_ads", "google_ads", "meta_ads", "tiktok_ads"]).optional().describe("Filter by ad platform"),
1000
- fromDate: z5.string().optional().describe("Start date for performance data (YYYY-MM-DD)"),
1001
- toDate: z5.string().optional().describe("End date for performance data (YYYY-MM-DD)"),
1002
- limit: z5.number().int().min(1).max(100).default(50).describe("Maximum number of campaigns to return")
1046
+ import { z as z6 } from "zod";
1047
+ var getAdsPerformanceSchema = z6.object({
1048
+ assetId: z6.string().uuid().optional().describe("Filter by app UUID"),
1049
+ platform: z6.enum(["apple_search_ads", "google_ads", "meta_ads", "tiktok_ads"]).optional().describe("Filter by ad platform"),
1050
+ fromDate: z6.string().optional().describe("Start date for performance data (YYYY-MM-DD)"),
1051
+ toDate: z6.string().optional().describe("End date for performance data (YYYY-MM-DD)"),
1052
+ limit: z6.number().int().min(1).max(100).default(50).describe("Maximum number of campaigns to return")
1003
1053
  });
1004
1054
  async function getAdsPerformance(input, client) {
1005
1055
  try {
@@ -1065,7 +1115,7 @@ async function getAdsPerformance(input, client) {
1065
1115
  }
1066
1116
 
1067
1117
  // src/tools/dashboard.ts
1068
- import { z as z6 } from "zod";
1118
+ import { z as z7 } from "zod";
1069
1119
  function parseDashboardNumber(value) {
1070
1120
  if (value === null || value === void 0 || value === "") return null;
1071
1121
  const parsed = typeof value === "number" ? value : Number.parseFloat(value);
@@ -1076,7 +1126,7 @@ function getSidebarAssets(response) {
1076
1126
  if (Array.isArray(response)) return response;
1077
1127
  return response.data ?? [];
1078
1128
  }
1079
- var getDashboardOverviewSchema = z6.object({});
1129
+ var getDashboardOverviewSchema = z7.object({});
1080
1130
  async function getDashboardOverview(_input, client) {
1081
1131
  try {
1082
1132
  const overviewPromise = client.get("/api/dashboard/overview-metrics").catch(() => null);
@@ -1132,7 +1182,7 @@ async function getDashboardOverview(_input, client) {
1132
1182
 
1133
1183
  // src/tools/actions.ts
1134
1184
  import { randomUUID } from "node:crypto";
1135
- import { z as z7 } from "zod";
1185
+ import { z as z8 } from "zod";
1136
1186
 
1137
1187
  // src/public-errors.ts
1138
1188
  var INTERNAL_ERROR_PATTERNS = [
@@ -1158,32 +1208,32 @@ function publicMcpErrorMessage(message, fallbackMessage = "Fload could not compl
1158
1208
  }
1159
1209
 
1160
1210
  // src/tools/actions.ts
1161
- var listPendingActionsSchema = z7.object({
1162
- assetId: z7.string().uuid().optional().describe("Filter by app UUID"),
1163
- view: z7.enum(["open", "queued"]).default("open").describe(
1211
+ var listPendingActionsSchema = z8.object({
1212
+ assetId: z8.string().uuid().optional().describe("Filter by app UUID"),
1213
+ view: z8.enum(["open", "queued"]).default("open").describe(
1164
1214
  "open (default): items waiting on the user. queued: approved work Fload is sending or checking in the store (an item being checked offers check_now)."
1165
1215
  ),
1166
- limit: z7.number().int().min(1).max(100).default(50).describe("Maximum number of actions to return")
1216
+ limit: z8.number().int().min(1).max(100).default(50).describe("Maximum number of actions to return")
1167
1217
  });
1168
- var approveActionSchema = z7.object({
1169
- actionId: z7.string().describe("The inbox item ID to approve (from list_pending_actions)")
1218
+ var approveActionSchema = z8.object({
1219
+ actionId: z8.string().describe("The inbox item ID to approve (from list_pending_actions)")
1170
1220
  });
1171
- var rejectActionSchema = z7.object({
1172
- actionId: z7.string().describe("The inbox item ID to reject (from list_pending_actions)"),
1173
- reason: z7.string().trim().min(1).max(1e3).optional().describe(
1221
+ var rejectActionSchema = z8.object({
1222
+ actionId: z8.string().describe("The inbox item ID to reject (from list_pending_actions)"),
1223
+ reason: z8.string().trim().min(1).max(1e3).optional().describe(
1174
1224
  "Why, in the user's words. Kept with the rejection so the agents do not propose the same thing again."
1175
1225
  )
1176
1226
  });
1177
- var checkActionNowSchema = z7.object({
1178
- actionId: z7.string().describe(
1227
+ var checkActionNowSchema = z8.object({
1228
+ actionId: z8.string().describe(
1179
1229
  'The inbox item ID to check now (from list_pending_actions with view "queued", or an approve_action result; its commands include check_now)'
1180
1230
  )
1181
1231
  });
1182
- var renameCustomPageActionSchema = z7.object({
1183
- actionId: z7.string().describe(
1232
+ var renameCustomPageActionSchema = z8.object({
1233
+ actionId: z8.string().describe(
1184
1234
  'The inbox item ID of the "Create custom product page" request (from list_pending_actions; it failed because App Store Connect already has a page of that name, or it waits for approval)'
1185
1235
  ),
1186
- name: z7.string().trim().min(1).max(100).describe(
1236
+ name: z8.string().trim().min(1).max(100).describe(
1187
1237
  "The new page name: at most 100 characters (UTF-16 units), not its current name, not a page the app already has"
1188
1238
  )
1189
1239
  });
@@ -1257,6 +1307,11 @@ async function commandItem(client, itemId, intent, reason) {
1257
1307
  }
1258
1308
  };
1259
1309
  }
1310
+ function refusedMessage(result) {
1311
+ const said = result?.error ?? "The approval could not be recorded.";
1312
+ const check = result?.policyRefusal?.check;
1313
+ return check ? `Stopped by the ${check}: ${said}` : said;
1314
+ }
1260
1315
  async function approveAction(input, client) {
1261
1316
  try {
1262
1317
  const { command, result } = await commandItem(
@@ -1272,7 +1327,7 @@ async function approveAction(input, client) {
1272
1327
  command,
1273
1328
  result: result?.result ?? "unknown",
1274
1329
  ...result?.error ? { error: result.error } : {},
1275
- message: applied2 ? command === "acknowledge" ? "Acknowledged." : "Approved. Fload delivers it after a short undo window; the inbox shows where it is." : result?.error ?? "The approval could not be recorded.",
1330
+ message: applied2 ? command === "acknowledge" ? "Acknowledged." : "Approved. Fload delivers it after a short undo window; the inbox shows where it is." : refusedMessage(result),
1276
1331
  item: result?.item
1277
1332
  },
1278
1333
  !applied2
@@ -1422,22 +1477,22 @@ async function renameCustomPageAction(input, client) {
1422
1477
  }
1423
1478
 
1424
1479
  // src/tools/aso.ts
1425
- import { z as z8 } from "zod";
1426
- var getAsoSummarySchema = z8.object({
1427
- assetId: z8.string().uuid().describe("App UUID to get ASO summary for")
1480
+ import { z as z9 } from "zod";
1481
+ var getAsoSummarySchema = z9.object({
1482
+ assetId: z9.string().uuid().describe("App UUID to get ASO summary for")
1428
1483
  });
1429
- var getAsoRecommendationsSchema = z8.object({
1430
- assetId: z8.string().uuid().describe("App UUID to get ASO recommendations for")
1484
+ var getAsoRecommendationsSchema = z9.object({
1485
+ assetId: z9.string().uuid().describe("App UUID to get ASO recommendations for")
1431
1486
  });
1432
- var getAsoKeywordsSchema = z8.object({
1433
- assetId: z8.string().uuid().describe("App UUID to get keyword intelligence for"),
1434
- locale: z8.string().optional().describe(
1487
+ var getAsoKeywordsSchema = z9.object({
1488
+ assetId: z9.string().uuid().describe("App UUID to get keyword intelligence for"),
1489
+ locale: z9.string().optional().describe(
1435
1490
  'Locale code to filter keywords (e.g., "en-US", "de-DE"). Returns all locales if omitted.'
1436
1491
  )
1437
1492
  });
1438
- var getAsoExperimentsSchema = z8.object({
1439
- assetId: z8.string().uuid().describe("App UUID to list ASO experiments for"),
1440
- status: z8.enum([
1493
+ var getAsoExperimentsSchema = z9.object({
1494
+ assetId: z9.string().uuid().describe("App UUID to list ASO experiments for"),
1495
+ status: z9.enum([
1441
1496
  "proposed",
1442
1497
  "approved",
1443
1498
  "applied",
@@ -1445,22 +1500,22 @@ var getAsoExperimentsSchema = z8.object({
1445
1500
  "completed",
1446
1501
  "reverted"
1447
1502
  ]).optional().describe("Filter experiments by status"),
1448
- limit: z8.number().int().min(1).max(100).default(20).describe("Maximum number of experiments to return"),
1449
- cursor: z8.string().optional().describe("Pagination cursor from a previous response (meta.nextCursor)")
1503
+ limit: z9.number().int().min(1).max(100).default(20).describe("Maximum number of experiments to return"),
1504
+ cursor: z9.string().optional().describe("Pagination cursor from a previous response (meta.nextCursor)")
1450
1505
  });
1451
- var getAsoLocaleSnapshotsSchema = z8.object({
1452
- assetId: z8.string().uuid().describe("App UUID to get locale snapshots for"),
1453
- store: z8.enum(["ios", "android"]).default("ios").describe("Which store listing to read"),
1454
- locale: z8.string().optional().describe(
1506
+ var getAsoLocaleSnapshotsSchema = z9.object({
1507
+ assetId: z9.string().uuid().describe("App UUID to get locale snapshots for"),
1508
+ store: z9.enum(["ios", "android"]).default("ios").describe("Which store listing to read"),
1509
+ locale: z9.string().optional().describe(
1455
1510
  'Filter to a single locale (e.g. "en-US"). Returns all locales if omitted.'
1456
1511
  ),
1457
- view: z8.enum(["latest", "history"]).default("latest").describe(
1512
+ view: z9.enum(["latest", "history"]).default("latest").describe(
1458
1513
  '"latest" (default) = newest snapshot per (locale, type); "history" = raw revisions newest first'
1459
1514
  ),
1460
- limit: z8.number().int().min(1).max(500).optional().describe("Maximum snapshot rows to return (newest first)")
1515
+ limit: z9.number().int().min(1).max(500).optional().describe("Maximum snapshot rows to return (newest first)")
1461
1516
  });
1462
- var triggerAsoAnalysisSchema = z8.object({
1463
- assetId: z8.string().uuid().describe("App UUID to trigger ASO analysis for")
1517
+ var triggerAsoAnalysisSchema = z9.object({
1518
+ assetId: z9.string().uuid().describe("App UUID to trigger ASO analysis for")
1464
1519
  });
1465
1520
  async function getAsoSummary(input, client) {
1466
1521
  try {
@@ -1628,7 +1683,7 @@ async function triggerAsoAnalysis(input, client) {
1628
1683
  };
1629
1684
  }
1630
1685
  }
1631
- var getAsoEvidenceSchema = z8.object({ assetId: z8.string().uuid() });
1686
+ var getAsoEvidenceSchema = z9.object({ assetId: z9.string().uuid() });
1632
1687
  async function getAsoEvidence(input, client) {
1633
1688
  try {
1634
1689
  const response = await client.get(
@@ -1647,19 +1702,19 @@ async function getAsoEvidence(input, client) {
1647
1702
 
1648
1703
  // src/tools/chat.ts
1649
1704
  import { randomUUID as randomUUID2 } from "node:crypto";
1650
- import { z as z9 } from "zod";
1651
- var listConversationsSchema = z9.object({
1652
- limit: z9.number().int().min(1).max(100).default(20).describe("Maximum number of conversations to return")
1705
+ import { z as z10 } from "zod";
1706
+ var listConversationsSchema = z10.object({
1707
+ limit: z10.number().int().min(1).max(100).default(20).describe("Maximum number of conversations to return")
1653
1708
  });
1654
- var getConversationMessagesSchema = z9.object({
1655
- conversationId: z9.string().uuid().describe("The conversation UUID to get messages for")
1709
+ var getConversationMessagesSchema = z10.object({
1710
+ conversationId: z10.string().uuid().describe("The conversation UUID to get messages for")
1656
1711
  });
1657
- var sendChatMessageSchema = z9.object({
1658
- message: z9.string().describe("The message to send to the AI chat"),
1659
- conversationId: z9.string().uuid().optional().describe(
1712
+ var sendChatMessageSchema = z10.object({
1713
+ message: z10.string().describe("The message to send to the AI chat"),
1714
+ conversationId: z10.string().uuid().optional().describe(
1660
1715
  "Existing conversation UUID to continue. Starts a new conversation if omitted."
1661
1716
  ),
1662
- agentType: z9.string().optional().describe(
1717
+ agentType: z10.string().optional().describe(
1663
1718
  "Agent type to use for the conversation (e.g., review, monitoring)"
1664
1719
  )
1665
1720
  });
@@ -1915,6 +1970,14 @@ function registerTools(server, client, options = {}) {
1915
1970
  discoverDimensions,
1916
1971
  { readOnlyHint: true, openWorldHint: false }
1917
1972
  );
1973
+ tool(
1974
+ "get_download_impact",
1975
+ "Get what Fload changed on downloads",
1976
+ "Did Fload's listing changes move downloads, overall or in one country? For an App Store app: downloads by source a week (organicSearch = App Store search minus Apple Ads, appleAds, browse, appReferrer, webReferrer, other, total) with the same days last year (364 days back) and an index of each year to its own first four weeks; markers for releases, each Fload listing change on the day written and the day live (with the storefronts that read its locales) and the iOS launch week; the 21 days before Fload's first change against the latest 21 days; storefronts by role (changed: a changed localization is its own language; reads_changed: it also reads one, e.g. the US reads es-MX; control: reads nothing changed) with organic downloads a day before and after, this year and last; and each touched keyword's median rank before and after. Listing changes can only move organic App Store search: judge them on organicSearch against last year, never on total, paid or browse. Null means unknown, never 0.",
1977
+ getDownloadImpactSchema,
1978
+ getDownloadImpact,
1979
+ { readOnlyHint: true, openWorldHint: false }
1980
+ );
1918
1981
  tool(
1919
1982
  "list_agents",
1920
1983
  "List agents",
@@ -2155,6 +2218,8 @@ export {
2155
2218
  getConversationMessagesSchema,
2156
2219
  getDashboardOverview,
2157
2220
  getDashboardOverviewSchema,
2221
+ getDownloadImpact,
2222
+ getDownloadImpactSchema,
2158
2223
  getMetrics,
2159
2224
  getMetricsSchema,
2160
2225
  getReviews,