@remixhq/mcp 0.1.9 → 0.1.11

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/dist/index.js CHANGED
@@ -202,7 +202,7 @@ function normalizeByMessage(err) {
202
202
  category: "local_state"
203
203
  });
204
204
  }
205
- if (code === ERROR_CODES.PREFERRED_BRANCH_MISMATCH || message.includes("preferred branch")) {
205
+ if (code === ERROR_CODES.PREFERRED_BRANCH_MISMATCH || message.includes("preferred branch") || message.includes("bound branch")) {
206
206
  return makeNormalized({
207
207
  code: ERROR_CODES.PREFERRED_BRANCH_MISMATCH,
208
208
  message,
@@ -460,6 +460,9 @@ var initInputSchema = {
460
460
  var listInputSchema = {
461
461
  requestId: z2.string().trim().min(1).optional(),
462
462
  outputMode: z2.enum(["summary", "full"]).optional(),
463
+ ownership: z2.enum(["mine", "shared", "all"]).optional(),
464
+ accessScope: z2.enum(["all_readable", "explicit_member"]).optional(),
465
+ createdBy: z2.string().trim().min(1).optional(),
463
466
  forked: z2.enum(["only", "exclude", "all"]).optional(),
464
467
  limit: z2.number().int().positive().max(50).optional(),
465
468
  offset: z2.number().int().nonnegative().optional()
@@ -777,7 +780,7 @@ function getRiskLevel(status) {
777
780
  function getRecommendedNextActions(status) {
778
781
  if (status.repo.branchMismatch) {
779
782
  return [
780
- `Switch to the preferred branch (${status.binding.preferredBranch ?? "configured in the binding"}) before using Remix mutation tools, or rerun with allowBranchMismatch=true if this deviation is intentional.`
783
+ `Switch to the bound branch (${status.binding.branchName ?? "configured in the binding"}) before using Remix mutation tools, or rerun with allowBranchMismatch=true if this deviation is intentional.`
781
784
  ];
782
785
  }
783
786
  switch (status.recommendedAction) {
@@ -857,6 +860,9 @@ async function listApps(params) {
857
860
  const api = await createCollabApiClient();
858
861
  const result = await coreCollabList({
859
862
  api,
863
+ ownership: params.ownership,
864
+ accessScope: params.accessScope,
865
+ createdBy: params.createdBy,
860
866
  forked: params.forked,
861
867
  limit: params.limit,
862
868
  offset: params.offset
@@ -1815,13 +1821,16 @@ function registerCollabTools(server, context) {
1815
1821
  });
1816
1822
  registerTool(server, context, {
1817
1823
  name: "remix_collab_list",
1818
- description: "List Remix apps visible to the current authenticated user.",
1824
+ description: "List Remix apps visible to the current authenticated user. Defaults to membership-oriented discovery; pass accessScope=all_readable explicitly for broader readable discovery.",
1819
1825
  access: "read",
1820
1826
  inputSchema: listInputSchema,
1821
1827
  outputSchema: listSuccessSchema,
1822
1828
  run: async (args) => {
1823
1829
  const input = z3.object(listInputSchema).parse(args);
1824
1830
  return listApps({
1831
+ ownership: input.ownership,
1832
+ accessScope: input.accessScope,
1833
+ createdBy: input.createdBy,
1825
1834
  forked: input.forked,
1826
1835
  limit: input.limit,
1827
1836
  offset: input.offset
@@ -2248,6 +2257,9 @@ var directoryListAppsInputSchema = {
2248
2257
  ...commonRequestFieldsSchema,
2249
2258
  projectId: z4.string().trim().min(1).optional(),
2250
2259
  organizationId: z4.string().trim().min(1).optional(),
2260
+ ownership: z4.enum(["mine", "shared", "all"]).optional(),
2261
+ accessScope: z4.enum(["all_readable", "explicit_member"]).optional(),
2262
+ createdBy: z4.string().trim().min(1).optional(),
2251
2263
  forked: z4.enum(["only", "exclude", "all"]).optional(),
2252
2264
  limit: z4.number().int().positive().max(50).optional(),
2253
2265
  offset: z4.number().int().nonnegative().optional()
@@ -2283,6 +2295,9 @@ var listAppsDataSchema = z4.object({
2283
2295
  filters: z4.object({
2284
2296
  projectId: z4.string().nullable(),
2285
2297
  organizationId: z4.string().nullable(),
2298
+ ownership: z4.enum(["mine", "shared", "all"]),
2299
+ accessScope: z4.enum(["all_readable", "explicit_member"]),
2300
+ createdBy: z4.string().nullable(),
2286
2301
  forked: z4.enum(["only", "exclude", "all"])
2287
2302
  })
2288
2303
  });
@@ -2539,6 +2554,9 @@ async function listApps2(params) {
2539
2554
  await api.listApps({
2540
2555
  projectId: params.projectId,
2541
2556
  organizationId: params.organizationId,
2557
+ ownership: params.ownership ?? "all",
2558
+ accessScope: params.accessScope ?? "explicit_member",
2559
+ createdBy: params.createdBy,
2542
2560
  forked: params.forked,
2543
2561
  limit: pagination.limit + 1,
2544
2562
  offset: pagination.offset
@@ -2555,6 +2573,9 @@ async function listApps2(params) {
2555
2573
  filters: {
2556
2574
  projectId: params.projectId ?? null,
2557
2575
  organizationId: params.organizationId ?? null,
2576
+ ownership: params.ownership ?? "all",
2577
+ accessScope: params.accessScope ?? "explicit_member",
2578
+ createdBy: params.createdBy ?? null,
2558
2579
  forked: params.forked ?? "all"
2559
2580
  }
2560
2581
  },
@@ -2738,7 +2759,7 @@ function registerIdentityTools(server, context) {
2738
2759
  });
2739
2760
  registerTool2(server, context, {
2740
2761
  name: "remix_directory_list_apps",
2741
- description: "List apps visible to the authenticated user, with optional organization or project filters and built-in pagination.",
2762
+ description: "List apps visible to the authenticated user, with optional organization, project, ownership, and access-scope filters. Defaults to membership-oriented discovery unless accessScope=all_readable is passed explicitly.",
2742
2763
  access: "read",
2743
2764
  inputSchema: directoryListAppsInputSchema,
2744
2765
  outputSchema: listAppsSuccessSchema,
@@ -2748,6 +2769,9 @@ function registerIdentityTools(server, context) {
2748
2769
  return listApps2({
2749
2770
  projectId: input.projectId,
2750
2771
  organizationId: input.organizationId,
2772
+ ownership: input.ownership,
2773
+ accessScope: input.accessScope,
2774
+ createdBy: input.createdBy,
2751
2775
  forked: input.forked,
2752
2776
  limit: input.limit,
2753
2777
  offset: input.offset,