@fload-ai/mcp 0.9.0 → 0.11.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;AAgDvD,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;AAkFD,wBAAsB,aAAa,CACjC,KAAK,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,EAC1C,MAAM,EAAE,cAAc;;;;;;GAyBvB;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"}
@@ -279,7 +279,9 @@ async function getReviews(input, client) {
279
279
  hasReply: hasReply(review),
280
280
  replySource: review.replySource ?? null,
281
281
  hasDraft: review.hasDraft ?? false,
282
- reply: review.developerResponse ? typeof review.developerResponse === "object" ? review.developerResponse.response : review.developerResponse : review.reply || null
282
+ reply: review.developerResponse ? typeof review.developerResponse === "object" ? review.developerResponse.response : review.developerResponse : review.reply || null,
283
+ // FLO-2571: where an App Store reply stands at Apple.
284
+ replyPublication: typeof review.developerResponse === "object" ? review.developerResponse?.publication ?? null : null
283
285
  }))
284
286
  })
285
287
  }
@@ -704,8 +706,58 @@ async function discoverDimensions(input, client) {
704
706
  }
705
707
  }
706
708
 
707
- // src/tools/agents.ts
709
+ // src/tools/download-impact.ts
708
710
  import { z as z4 } from "zod";
711
+ var Day = z4.string().regex(/^\d{4}-\d{2}-\d{2}$/).optional();
712
+ var getDownloadImpactSchema = z4.object({
713
+ assetId: z4.string().uuid().describe("App UUID (App Store apps)"),
714
+ from: Day.describe(
715
+ "First day drawn (YYYY-MM-DD); default 20 weeks before `to`"
716
+ ),
717
+ to: Day.describe(
718
+ "Last day drawn (YYYY-MM-DD); default the newest day with data"
719
+ ),
720
+ beforeFrom: Day.describe(
721
+ 'Start of the "before" window compared (needs beforeTo; all windows within 400 days of each other)'
722
+ ),
723
+ beforeTo: Day.describe('End of the "before" window compared'),
724
+ afterFrom: Day.describe(
725
+ 'Start of the "after" window compared (needs afterTo)'
726
+ ),
727
+ afterTo: Day.describe('End of the "after" window compared'),
728
+ country: z4.string().regex(/^[a-zA-Z]{2}$/).optional().describe(
729
+ 'One storefront, two-letter code (e.g. "us"): narrows countries and keywords'
730
+ ),
731
+ includeDays: z4.boolean().optional().describe("Also return every day (long). Weeks carry the same downloads.")
732
+ });
733
+ async function getDownloadImpact(input, client) {
734
+ try {
735
+ const { assetId, includeDays, ...query } = input;
736
+ const impact = await client.get(
737
+ `/api/assets/${assetId}/metrics/download-impact`,
738
+ query
739
+ );
740
+ const { days, lastYearDays, ...rest } = impact;
741
+ return {
742
+ content: [
743
+ {
744
+ type: "text",
745
+ text: formatAsJson(
746
+ includeDays ? { ...rest, days, lastYearDays } : rest
747
+ )
748
+ }
749
+ ]
750
+ };
751
+ } catch (error) {
752
+ return {
753
+ content: [{ type: "text", text: formatError(error) }],
754
+ isError: true
755
+ };
756
+ }
757
+ }
758
+
759
+ // src/tools/agents.ts
760
+ import { z as z5 } from "zod";
709
761
  function asRecord(value) {
710
762
  return value && typeof value === "object" && !Array.isArray(value) ? value : {};
711
763
  }
@@ -714,28 +766,28 @@ var AGENT_DESCRIPTIONS = {
714
766
  review: "AI-powered review management \u2014 drafts and sends replies to app store reviews",
715
767
  aso: "App Store Optimization \u2014 listing optimization suggestions for better visibility"
716
768
  };
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)")
769
+ var listAgentsSchema = z5.object({});
770
+ var getAgentDetailsSchema = z5.object({
771
+ agentType: z5.enum(AGENT_TYPES).describe("The type of agent to get details for"),
772
+ assetId: z5.string().uuid().optional().describe("App UUID to get agent config for (when agent is per-asset)")
721
773
  });
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")
774
+ var getAgentRunHistorySchema = z5.object({
775
+ agentType: z5.enum(AGENT_TYPES).describe("The type of agent to get run history for"),
776
+ assetId: z5.string().uuid().optional().describe("App UUID to filter runs"),
777
+ limit: z5.number().int().min(1).max(100).default(20).describe("Maximum number of runs to return")
726
778
  });
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")
779
+ var triggerAgentRunSchema = z5.object({
780
+ agentId: z5.string().describe("The agent ID to trigger a run for (the `id` from list_agents)"),
781
+ assetId: z5.string().uuid().optional().describe("Optional app UUID to run the agent against")
730
782
  });
731
- var pauseAgentSchema = z4.object({
732
- agentId: z4.string().describe("The agent ID to pause (the `id` from list_agents)")
783
+ var pauseAgentSchema = z5.object({
784
+ agentId: z5.string().describe("The agent ID to pause (the `id` from list_agents)")
733
785
  });
734
- var resumeAgentSchema = z4.object({
735
- agentId: z4.string().describe("The agent ID to resume (the `id` from list_agents)")
786
+ var resumeAgentSchema = z5.object({
787
+ agentId: z5.string().describe("The agent ID to resume (the `id` from list_agents)")
736
788
  });
737
- var getAgentActivitySchema = z4.object({
738
- agentId: z4.string().describe("The agent ID to get activity for (the `id` from list_agents)")
789
+ var getAgentActivitySchema = z5.object({
790
+ agentId: z5.string().describe("The agent ID to get activity for (the `id` from list_agents)")
739
791
  });
740
792
  async function listAgents(_input, client) {
741
793
  try {
@@ -993,13 +1045,13 @@ async function getAgentActivity(input, client) {
993
1045
  }
994
1046
 
995
1047
  // 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")
1048
+ import { z as z6 } from "zod";
1049
+ var getAdsPerformanceSchema = z6.object({
1050
+ assetId: z6.string().uuid().optional().describe("Filter by app UUID"),
1051
+ platform: z6.enum(["apple_search_ads", "google_ads", "meta_ads", "tiktok_ads"]).optional().describe("Filter by ad platform"),
1052
+ fromDate: z6.string().optional().describe("Start date for performance data (YYYY-MM-DD)"),
1053
+ toDate: z6.string().optional().describe("End date for performance data (YYYY-MM-DD)"),
1054
+ limit: z6.number().int().min(1).max(100).default(50).describe("Maximum number of campaigns to return")
1003
1055
  });
1004
1056
  async function getAdsPerformance(input, client) {
1005
1057
  try {
@@ -1065,7 +1117,7 @@ async function getAdsPerformance(input, client) {
1065
1117
  }
1066
1118
 
1067
1119
  // src/tools/dashboard.ts
1068
- import { z as z6 } from "zod";
1120
+ import { z as z7 } from "zod";
1069
1121
  function parseDashboardNumber(value) {
1070
1122
  if (value === null || value === void 0 || value === "") return null;
1071
1123
  const parsed = typeof value === "number" ? value : Number.parseFloat(value);
@@ -1076,7 +1128,7 @@ function getSidebarAssets(response) {
1076
1128
  if (Array.isArray(response)) return response;
1077
1129
  return response.data ?? [];
1078
1130
  }
1079
- var getDashboardOverviewSchema = z6.object({});
1131
+ var getDashboardOverviewSchema = z7.object({});
1080
1132
  async function getDashboardOverview(_input, client) {
1081
1133
  try {
1082
1134
  const overviewPromise = client.get("/api/dashboard/overview-metrics").catch(() => null);
@@ -1132,7 +1184,7 @@ async function getDashboardOverview(_input, client) {
1132
1184
 
1133
1185
  // src/tools/actions.ts
1134
1186
  import { randomUUID } from "node:crypto";
1135
- import { z as z7 } from "zod";
1187
+ import { z as z8 } from "zod";
1136
1188
 
1137
1189
  // src/public-errors.ts
1138
1190
  var INTERNAL_ERROR_PATTERNS = [
@@ -1158,32 +1210,32 @@ function publicMcpErrorMessage(message, fallbackMessage = "Fload could not compl
1158
1210
  }
1159
1211
 
1160
1212
  // 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(
1213
+ var listPendingActionsSchema = z8.object({
1214
+ assetId: z8.string().uuid().optional().describe("Filter by app UUID"),
1215
+ view: z8.enum(["open", "queued"]).default("open").describe(
1164
1216
  "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
1217
  ),
1166
- limit: z7.number().int().min(1).max(100).default(50).describe("Maximum number of actions to return")
1218
+ limit: z8.number().int().min(1).max(100).default(50).describe("Maximum number of actions to return")
1167
1219
  });
1168
- var approveActionSchema = z7.object({
1169
- actionId: z7.string().describe("The inbox item ID to approve (from list_pending_actions)")
1220
+ var approveActionSchema = z8.object({
1221
+ actionId: z8.string().describe("The inbox item ID to approve (from list_pending_actions)")
1170
1222
  });
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(
1223
+ var rejectActionSchema = z8.object({
1224
+ actionId: z8.string().describe("The inbox item ID to reject (from list_pending_actions)"),
1225
+ reason: z8.string().trim().min(1).max(1e3).optional().describe(
1174
1226
  "Why, in the user's words. Kept with the rejection so the agents do not propose the same thing again."
1175
1227
  )
1176
1228
  });
1177
- var checkActionNowSchema = z7.object({
1178
- actionId: z7.string().describe(
1229
+ var checkActionNowSchema = z8.object({
1230
+ actionId: z8.string().describe(
1179
1231
  '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
1232
  )
1181
1233
  });
1182
- var renameCustomPageActionSchema = z7.object({
1183
- actionId: z7.string().describe(
1234
+ var renameCustomPageActionSchema = z8.object({
1235
+ actionId: z8.string().describe(
1184
1236
  '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
1237
  ),
1186
- name: z7.string().trim().min(1).max(100).describe(
1238
+ name: z8.string().trim().min(1).max(100).describe(
1187
1239
  "The new page name: at most 100 characters (UTF-16 units), not its current name, not a page the app already has"
1188
1240
  )
1189
1241
  });
@@ -1257,6 +1309,18 @@ async function commandItem(client, itemId, intent, reason) {
1257
1309
  }
1258
1310
  };
1259
1311
  }
1312
+ function approveMessage(command, applied2, result) {
1313
+ if (!applied2) return refusedMessage(result);
1314
+ if (command === "acknowledge") return "Acknowledged.";
1315
+ if (result?.alreadyLive)
1316
+ return "Already live: the store already shows this change, so nothing was sent. The item is done.";
1317
+ return "Approved. Fload delivers it after a short undo window; the inbox shows where it is.";
1318
+ }
1319
+ function refusedMessage(result) {
1320
+ const said = result?.error ?? "The approval could not be recorded.";
1321
+ const check = result?.policyRefusal?.check;
1322
+ return check ? `Stopped by the ${check}: ${said}` : said;
1323
+ }
1260
1324
  async function approveAction(input, client) {
1261
1325
  try {
1262
1326
  const { command, result } = await commandItem(
@@ -1272,7 +1336,7 @@ async function approveAction(input, client) {
1272
1336
  command,
1273
1337
  result: result?.result ?? "unknown",
1274
1338
  ...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.",
1339
+ message: approveMessage(command, applied2, result),
1276
1340
  item: result?.item
1277
1341
  },
1278
1342
  !applied2
@@ -1422,22 +1486,22 @@ async function renameCustomPageAction(input, client) {
1422
1486
  }
1423
1487
 
1424
1488
  // 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")
1489
+ import { z as z9 } from "zod";
1490
+ var getAsoSummarySchema = z9.object({
1491
+ assetId: z9.string().uuid().describe("App UUID to get ASO summary for")
1428
1492
  });
1429
- var getAsoRecommendationsSchema = z8.object({
1430
- assetId: z8.string().uuid().describe("App UUID to get ASO recommendations for")
1493
+ var getAsoRecommendationsSchema = z9.object({
1494
+ assetId: z9.string().uuid().describe("App UUID to get ASO recommendations for")
1431
1495
  });
1432
- var getAsoKeywordsSchema = z8.object({
1433
- assetId: z8.string().uuid().describe("App UUID to get keyword intelligence for"),
1434
- locale: z8.string().optional().describe(
1496
+ var getAsoKeywordsSchema = z9.object({
1497
+ assetId: z9.string().uuid().describe("App UUID to get keyword intelligence for"),
1498
+ locale: z9.string().optional().describe(
1435
1499
  'Locale code to filter keywords (e.g., "en-US", "de-DE"). Returns all locales if omitted.'
1436
1500
  )
1437
1501
  });
1438
- var getAsoExperimentsSchema = z8.object({
1439
- assetId: z8.string().uuid().describe("App UUID to list ASO experiments for"),
1440
- status: z8.enum([
1502
+ var getAsoExperimentsSchema = z9.object({
1503
+ assetId: z9.string().uuid().describe("App UUID to list ASO experiments for"),
1504
+ status: z9.enum([
1441
1505
  "proposed",
1442
1506
  "approved",
1443
1507
  "applied",
@@ -1445,22 +1509,22 @@ var getAsoExperimentsSchema = z8.object({
1445
1509
  "completed",
1446
1510
  "reverted"
1447
1511
  ]).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)")
1512
+ limit: z9.number().int().min(1).max(100).default(20).describe("Maximum number of experiments to return"),
1513
+ cursor: z9.string().optional().describe("Pagination cursor from a previous response (meta.nextCursor)")
1450
1514
  });
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(
1515
+ var getAsoLocaleSnapshotsSchema = z9.object({
1516
+ assetId: z9.string().uuid().describe("App UUID to get locale snapshots for"),
1517
+ store: z9.enum(["ios", "android"]).default("ios").describe("Which store listing to read"),
1518
+ locale: z9.string().optional().describe(
1455
1519
  'Filter to a single locale (e.g. "en-US"). Returns all locales if omitted.'
1456
1520
  ),
1457
- view: z8.enum(["latest", "history"]).default("latest").describe(
1521
+ view: z9.enum(["latest", "history"]).default("latest").describe(
1458
1522
  '"latest" (default) = newest snapshot per (locale, type); "history" = raw revisions newest first'
1459
1523
  ),
1460
- limit: z8.number().int().min(1).max(500).optional().describe("Maximum snapshot rows to return (newest first)")
1524
+ limit: z9.number().int().min(1).max(500).optional().describe("Maximum snapshot rows to return (newest first)")
1461
1525
  });
1462
- var triggerAsoAnalysisSchema = z8.object({
1463
- assetId: z8.string().uuid().describe("App UUID to trigger ASO analysis for")
1526
+ var triggerAsoAnalysisSchema = z9.object({
1527
+ assetId: z9.string().uuid().describe("App UUID to trigger ASO analysis for")
1464
1528
  });
1465
1529
  async function getAsoSummary(input, client) {
1466
1530
  try {
@@ -1628,7 +1692,7 @@ async function triggerAsoAnalysis(input, client) {
1628
1692
  };
1629
1693
  }
1630
1694
  }
1631
- var getAsoEvidenceSchema = z8.object({ assetId: z8.string().uuid() });
1695
+ var getAsoEvidenceSchema = z9.object({ assetId: z9.string().uuid() });
1632
1696
  async function getAsoEvidence(input, client) {
1633
1697
  try {
1634
1698
  const response = await client.get(
@@ -1647,19 +1711,19 @@ async function getAsoEvidence(input, client) {
1647
1711
 
1648
1712
  // src/tools/chat.ts
1649
1713
  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")
1714
+ import { z as z10 } from "zod";
1715
+ var listConversationsSchema = z10.object({
1716
+ limit: z10.number().int().min(1).max(100).default(20).describe("Maximum number of conversations to return")
1653
1717
  });
1654
- var getConversationMessagesSchema = z9.object({
1655
- conversationId: z9.string().uuid().describe("The conversation UUID to get messages for")
1718
+ var getConversationMessagesSchema = z10.object({
1719
+ conversationId: z10.string().uuid().describe("The conversation UUID to get messages for")
1656
1720
  });
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(
1721
+ var sendChatMessageSchema = z10.object({
1722
+ message: z10.string().describe("The message to send to the AI chat"),
1723
+ conversationId: z10.string().uuid().optional().describe(
1660
1724
  "Existing conversation UUID to continue. Starts a new conversation if omitted."
1661
1725
  ),
1662
- agentType: z9.string().optional().describe(
1726
+ agentType: z10.string().optional().describe(
1663
1727
  "Agent type to use for the conversation (e.g., review, monitoring)"
1664
1728
  )
1665
1729
  });
@@ -1862,7 +1926,7 @@ function registerTools(server, client, options = {}) {
1862
1926
  tool(
1863
1927
  "get_reviews",
1864
1928
  "Get reviews",
1865
- "Get app reviews with flexible filtering. Filter by app (assetId or bundleId), platform, rating (1-5 stars), replied status, and date range. Returns reviews with metadata, author, body text, and reply status. Useful for sentiment analysis, support workflows, and review management.",
1929
+ 'Get app reviews with flexible filtering. Filter by app (assetId or bundleId), platform, rating (1-5 stars), replied status, and date range. Returns reviews with metadata, author, body text, and reply status. For an App Store reply, replyPublication says where it stands at Apple: "publishing" (sent; Apple has not published it yet, usually within a day), "live" (live on the App Store), "removed" (Apple no longer shows it), or null (not known: never call it live). Useful for sentiment analysis, support workflows, and review management.',
1866
1930
  getReviewsSchema,
1867
1931
  getReviews,
1868
1932
  { readOnlyHint: true, openWorldHint: false }
@@ -1915,6 +1979,14 @@ function registerTools(server, client, options = {}) {
1915
1979
  discoverDimensions,
1916
1980
  { readOnlyHint: true, openWorldHint: false }
1917
1981
  );
1982
+ tool(
1983
+ "get_download_impact",
1984
+ "Get what Fload changed on downloads",
1985
+ "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.",
1986
+ getDownloadImpactSchema,
1987
+ getDownloadImpact,
1988
+ { readOnlyHint: true, openWorldHint: false }
1989
+ );
1918
1990
  tool(
1919
1991
  "list_agents",
1920
1992
  "List agents",
@@ -2155,6 +2227,8 @@ export {
2155
2227
  getConversationMessagesSchema,
2156
2228
  getDashboardOverview,
2157
2229
  getDashboardOverviewSchema,
2230
+ getDownloadImpact,
2231
+ getDownloadImpactSchema,
2158
2232
  getMetrics,
2159
2233
  getMetricsSchema,
2160
2234
  getReviews,