@moovio/sdk 0.5.4 → 0.6.1

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 (80) hide show
  1. package/README.md +19 -8
  2. package/bin/mcp-server.js +488 -106
  3. package/bin/mcp-server.js.map +18 -12
  4. package/docs/sdks/transfers/README.md +185 -0
  5. package/funcs/transfersCreateCancellation.d.ts +17 -0
  6. package/funcs/transfersCreateCancellation.d.ts.map +1 -0
  7. package/funcs/transfersCreateCancellation.js +128 -0
  8. package/funcs/transfersCreateCancellation.js.map +1 -0
  9. package/funcs/transfersGetCancellation.d.ts +16 -0
  10. package/funcs/transfersGetCancellation.d.ts.map +1 -0
  11. package/funcs/transfersGetCancellation.js +131 -0
  12. package/funcs/transfersGetCancellation.js.map +1 -0
  13. package/jsr.json +1 -1
  14. package/lib/config.d.ts +3 -3
  15. package/lib/config.js +3 -3
  16. package/mcp-server/cli/start/command.d.ts.map +1 -1
  17. package/mcp-server/cli/start/command.js +9 -0
  18. package/mcp-server/cli/start/command.js.map +1 -1
  19. package/mcp-server/cli/start/impl.d.ts +1 -0
  20. package/mcp-server/cli/start/impl.d.ts.map +1 -1
  21. package/mcp-server/cli/start/impl.js +2 -0
  22. package/mcp-server/cli/start/impl.js.map +1 -1
  23. package/mcp-server/mcp-server.js +1 -1
  24. package/mcp-server/server.d.ts +1 -0
  25. package/mcp-server/server.d.ts.map +1 -1
  26. package/mcp-server/server.js +7 -2
  27. package/mcp-server/server.js.map +1 -1
  28. package/mcp-server/tools/transfersCreateCancellation.d.ts +8 -0
  29. package/mcp-server/tools/transfersCreateCancellation.d.ts.map +1 -0
  30. package/mcp-server/tools/transfersCreateCancellation.js +65 -0
  31. package/mcp-server/tools/transfersCreateCancellation.js.map +1 -0
  32. package/mcp-server/tools/transfersGetCancellation.d.ts +8 -0
  33. package/mcp-server/tools/transfersGetCancellation.d.ts.map +1 -0
  34. package/mcp-server/tools/transfersGetCancellation.js +65 -0
  35. package/mcp-server/tools/transfersGetCancellation.js.map +1 -0
  36. package/mcp-server/tools.d.ts +1 -1
  37. package/mcp-server/tools.d.ts.map +1 -1
  38. package/mcp-server/tools.js +4 -1
  39. package/mcp-server/tools.js.map +1 -1
  40. package/models/components/transfer.d.ts +3 -0
  41. package/models/components/transfer.d.ts.map +1 -1
  42. package/models/components/transfer.js +3 -0
  43. package/models/components/transfer.js.map +1 -1
  44. package/models/errors/transfer.d.ts +3 -0
  45. package/models/errors/transfer.d.ts.map +1 -1
  46. package/models/errors/transfer.js +4 -0
  47. package/models/errors/transfer.js.map +1 -1
  48. package/models/operations/createcancellation.d.ts +107 -0
  49. package/models/operations/createcancellation.d.ts.map +1 -0
  50. package/models/operations/createcancellation.js +147 -0
  51. package/models/operations/createcancellation.js.map +1 -0
  52. package/models/operations/getcancellation.d.ts +112 -0
  53. package/models/operations/getcancellation.d.ts.map +1 -0
  54. package/models/operations/getcancellation.js +149 -0
  55. package/models/operations/getcancellation.js.map +1 -0
  56. package/models/operations/index.d.ts +2 -0
  57. package/models/operations/index.d.ts.map +1 -1
  58. package/models/operations/index.js +2 -0
  59. package/models/operations/index.js.map +1 -1
  60. package/package.json +1 -1
  61. package/sdk/transfers.d.ts +14 -0
  62. package/sdk/transfers.d.ts.map +1 -1
  63. package/sdk/transfers.js +20 -0
  64. package/sdk/transfers.js.map +1 -1
  65. package/src/funcs/transfersCreateCancellation.ts +184 -0
  66. package/src/funcs/transfersGetCancellation.ts +183 -0
  67. package/src/lib/config.ts +3 -3
  68. package/src/mcp-server/cli/start/command.ts +9 -0
  69. package/src/mcp-server/cli/start/impl.ts +3 -0
  70. package/src/mcp-server/mcp-server.ts +1 -1
  71. package/src/mcp-server/server.ts +14 -2
  72. package/src/mcp-server/tools/transfersCreateCancellation.ts +38 -0
  73. package/src/mcp-server/tools/transfersGetCancellation.ts +38 -0
  74. package/src/mcp-server/tools.ts +5 -0
  75. package/src/models/components/transfer.ts +10 -0
  76. package/src/models/errors/transfer.ts +6 -0
  77. package/src/models/operations/createcancellation.ts +229 -0
  78. package/src/models/operations/getcancellation.ts +236 -0
  79. package/src/models/operations/index.ts +2 -0
  80. package/src/sdk/transfers.ts +36 -0
package/bin/mcp-server.js CHANGED
@@ -34213,9 +34213,9 @@ var init_config = __esm(() => {
34213
34213
  SDK_METADATA = {
34214
34214
  language: "typescript",
34215
34215
  openapiDocVersion: "latest",
34216
- sdkVersion: "0.5.4",
34217
- genVersion: "2.536.0",
34218
- userAgent: "speakeasy-sdk/typescript 0.5.4 2.536.0 latest @moovio/sdk"
34216
+ sdkVersion: "0.6.1",
34217
+ genVersion: "2.539.1",
34218
+ userAgent: "speakeasy-sdk/typescript 0.6.1 2.539.1 latest @moovio/sdk"
34219
34219
  };
34220
34220
  });
34221
34221
 
@@ -35085,8 +35085,11 @@ async function consumeSSE(value) {
35085
35085
  }
35086
35086
  return content;
35087
35087
  }
35088
- function createRegisterTool(logger, server, sdk, allowedScopes) {
35088
+ function createRegisterTool(logger, server, sdk, allowedScopes, allowedTools) {
35089
35089
  return (tool) => {
35090
+ if (allowedTools && !allowedTools.has(tool.name)) {
35091
+ return;
35092
+ }
35090
35093
  const toolScopes = tool.scopes ?? [];
35091
35094
  if (!toolScopes.every((s) => allowedScopes.has(s))) {
35092
35095
  return;
@@ -43479,6 +43482,7 @@ var Transfer$inboundSchema, Transfer$outboundSchema, Transfer$;
43479
43482
  var init_transfer = __esm(() => {
43480
43483
  init_lib();
43481
43484
  init_amount();
43485
+ init_cancellation();
43482
43486
  init_cardacquiringdispute();
43483
43487
  init_cardacquiringrefund();
43484
43488
  init_facilitatorfee();
@@ -43503,6 +43507,7 @@ var init_transfer = __esm(() => {
43503
43507
  moovFeeDecimal: stringType().optional(),
43504
43508
  moovFeeDetails: MoovFeeDetails$inboundSchema.optional(),
43505
43509
  groupID: stringType().optional(),
43510
+ cancellations: arrayType(Cancellation$inboundSchema).optional(),
43506
43511
  refundedAmount: Amount$inboundSchema.optional(),
43507
43512
  refunds: arrayType(CardAcquiringRefund$inboundSchema).optional(),
43508
43513
  disputedAmount: Amount$inboundSchema.optional(),
@@ -43527,6 +43532,7 @@ var init_transfer = __esm(() => {
43527
43532
  moovFeeDecimal: stringType().optional(),
43528
43533
  moovFeeDetails: MoovFeeDetails$outboundSchema.optional(),
43529
43534
  groupID: stringType().optional(),
43535
+ cancellations: arrayType(Cancellation$outboundSchema).optional(),
43530
43536
  refundedAmount: Amount$outboundSchema.optional(),
43531
43537
  refunds: arrayType(CardAcquiringRefund$outboundSchema).optional(),
43532
43538
  disputedAmount: Amount$outboundSchema.optional(),
@@ -45736,6 +45742,7 @@ var init_transfer2 = __esm(() => {
45736
45742
  moovFeeDecimal;
45737
45743
  moovFeeDetails;
45738
45744
  groupID;
45745
+ cancellations;
45739
45746
  refundedAmount;
45740
45747
  refunds;
45741
45748
  disputedAmount;
@@ -45772,6 +45779,8 @@ var init_transfer2 = __esm(() => {
45772
45779
  this.moovFeeDetails = err.moovFeeDetails;
45773
45780
  if (err.groupID != null)
45774
45781
  this.groupID = err.groupID;
45782
+ if (err.cancellations != null)
45783
+ this.cancellations = err.cancellations;
45775
45784
  if (err.refundedAmount != null)
45776
45785
  this.refundedAmount = err.refundedAmount;
45777
45786
  if (err.refunds != null)
@@ -45805,6 +45814,7 @@ var init_transfer2 = __esm(() => {
45805
45814
  moovFeeDecimal: stringType().optional(),
45806
45815
  moovFeeDetails: MoovFeeDetails$inboundSchema.optional(),
45807
45816
  groupID: stringType().optional(),
45817
+ cancellations: arrayType(Cancellation$inboundSchema).optional(),
45808
45818
  refundedAmount: Amount$inboundSchema.optional(),
45809
45819
  refunds: arrayType(CardAcquiringRefund$inboundSchema).optional(),
45810
45820
  disputedAmount: Amount$inboundSchema.optional(),
@@ -45831,6 +45841,7 @@ var init_transfer2 = __esm(() => {
45831
45841
  moovFeeDecimal: stringType().optional(),
45832
45842
  moovFeeDetails: MoovFeeDetails$outboundSchema.optional(),
45833
45843
  groupID: stringType().optional(),
45844
+ cancellations: arrayType(Cancellation$outboundSchema).optional(),
45834
45845
  refundedAmount: Amount$outboundSchema.optional(),
45835
45846
  refunds: arrayType(CardAcquiringRefund$outboundSchema).optional(),
45836
45847
  disputedAmount: Amount$outboundSchema.optional(),
@@ -46810,6 +46821,66 @@ var init_createbrand = __esm(() => {
46810
46821
  })(CreateBrandResponse$ ||= {});
46811
46822
  });
46812
46823
 
46824
+ // src/models/operations/createcancellation.ts
46825
+ var CreateCancellationGlobals$inboundSchema, CreateCancellationGlobals$outboundSchema, CreateCancellationGlobals$, CreateCancellationRequest$inboundSchema, CreateCancellationRequest$outboundSchema, CreateCancellationRequest$, CreateCancellationResponse$inboundSchema, CreateCancellationResponse$outboundSchema, CreateCancellationResponse$;
46826
+ var init_createcancellation = __esm(() => {
46827
+ init_lib();
46828
+ init_primitives();
46829
+ init_components();
46830
+ CreateCancellationGlobals$inboundSchema = objectType({
46831
+ "x-moov-version": stringType().default("v2024.01.00")
46832
+ }).transform((v2) => {
46833
+ return remap(v2, {
46834
+ "x-moov-version": "xMoovVersion"
46835
+ });
46836
+ });
46837
+ CreateCancellationGlobals$outboundSchema = objectType({
46838
+ xMoovVersion: stringType().default("v2024.01.00")
46839
+ }).transform((v2) => {
46840
+ return remap(v2, {
46841
+ xMoovVersion: "x-moov-version"
46842
+ });
46843
+ });
46844
+ ((CreateCancellationGlobals$) => {
46845
+ CreateCancellationGlobals$.inboundSchema = CreateCancellationGlobals$inboundSchema;
46846
+ CreateCancellationGlobals$.outboundSchema = CreateCancellationGlobals$outboundSchema;
46847
+ })(CreateCancellationGlobals$ ||= {});
46848
+ CreateCancellationRequest$inboundSchema = objectType({
46849
+ accountID: stringType(),
46850
+ transferID: stringType()
46851
+ });
46852
+ CreateCancellationRequest$outboundSchema = objectType({
46853
+ accountID: stringType(),
46854
+ transferID: stringType()
46855
+ });
46856
+ ((CreateCancellationRequest$) => {
46857
+ CreateCancellationRequest$.inboundSchema = CreateCancellationRequest$inboundSchema;
46858
+ CreateCancellationRequest$.outboundSchema = CreateCancellationRequest$outboundSchema;
46859
+ })(CreateCancellationRequest$ ||= {});
46860
+ CreateCancellationResponse$inboundSchema = objectType({
46861
+ Headers: recordType(arrayType(stringType())),
46862
+ Result: Cancellation$inboundSchema
46863
+ }).transform((v2) => {
46864
+ return remap(v2, {
46865
+ Headers: "headers",
46866
+ Result: "result"
46867
+ });
46868
+ });
46869
+ CreateCancellationResponse$outboundSchema = objectType({
46870
+ headers: recordType(arrayType(stringType())),
46871
+ result: Cancellation$outboundSchema
46872
+ }).transform((v2) => {
46873
+ return remap(v2, {
46874
+ headers: "Headers",
46875
+ result: "Result"
46876
+ });
46877
+ });
46878
+ ((CreateCancellationResponse$) => {
46879
+ CreateCancellationResponse$.inboundSchema = CreateCancellationResponse$inboundSchema;
46880
+ CreateCancellationResponse$.outboundSchema = CreateCancellationResponse$outboundSchema;
46881
+ })(CreateCancellationResponse$ ||= {});
46882
+ });
46883
+
46813
46884
  // src/models/operations/createfeeplanagreements.ts
46814
46885
  var CreateFeePlanAgreementsGlobals$inboundSchema, CreateFeePlanAgreementsGlobals$outboundSchema, CreateFeePlanAgreementsGlobals$, CreateFeePlanAgreementsRequest$inboundSchema, CreateFeePlanAgreementsRequest$outboundSchema, CreateFeePlanAgreementsRequest$, CreateFeePlanAgreementsResponse$inboundSchema, CreateFeePlanAgreementsResponse$outboundSchema, CreateFeePlanAgreementsResponse$;
46815
46886
  var init_createfeeplanagreements = __esm(() => {
@@ -48428,6 +48499,68 @@ var init_getbrand = __esm(() => {
48428
48499
  })(GetBrandResponse$ ||= {});
48429
48500
  });
48430
48501
 
48502
+ // src/models/operations/getcancellation.ts
48503
+ var GetCancellationGlobals$inboundSchema, GetCancellationGlobals$outboundSchema, GetCancellationGlobals$, GetCancellationRequest$inboundSchema, GetCancellationRequest$outboundSchema, GetCancellationRequest$, GetCancellationResponse$inboundSchema, GetCancellationResponse$outboundSchema, GetCancellationResponse$;
48504
+ var init_getcancellation = __esm(() => {
48505
+ init_lib();
48506
+ init_primitives();
48507
+ init_components();
48508
+ GetCancellationGlobals$inboundSchema = objectType({
48509
+ "x-moov-version": stringType().default("v2024.01.00")
48510
+ }).transform((v2) => {
48511
+ return remap(v2, {
48512
+ "x-moov-version": "xMoovVersion"
48513
+ });
48514
+ });
48515
+ GetCancellationGlobals$outboundSchema = objectType({
48516
+ xMoovVersion: stringType().default("v2024.01.00")
48517
+ }).transform((v2) => {
48518
+ return remap(v2, {
48519
+ xMoovVersion: "x-moov-version"
48520
+ });
48521
+ });
48522
+ ((GetCancellationGlobals$) => {
48523
+ GetCancellationGlobals$.inboundSchema = GetCancellationGlobals$inboundSchema;
48524
+ GetCancellationGlobals$.outboundSchema = GetCancellationGlobals$outboundSchema;
48525
+ })(GetCancellationGlobals$ ||= {});
48526
+ GetCancellationRequest$inboundSchema = objectType({
48527
+ accountID: stringType(),
48528
+ transferID: stringType(),
48529
+ cancellationID: stringType()
48530
+ });
48531
+ GetCancellationRequest$outboundSchema = objectType({
48532
+ accountID: stringType(),
48533
+ transferID: stringType(),
48534
+ cancellationID: stringType()
48535
+ });
48536
+ ((GetCancellationRequest$) => {
48537
+ GetCancellationRequest$.inboundSchema = GetCancellationRequest$inboundSchema;
48538
+ GetCancellationRequest$.outboundSchema = GetCancellationRequest$outboundSchema;
48539
+ })(GetCancellationRequest$ ||= {});
48540
+ GetCancellationResponse$inboundSchema = objectType({
48541
+ Headers: recordType(arrayType(stringType())),
48542
+ Result: Cancellation$inboundSchema
48543
+ }).transform((v2) => {
48544
+ return remap(v2, {
48545
+ Headers: "headers",
48546
+ Result: "result"
48547
+ });
48548
+ });
48549
+ GetCancellationResponse$outboundSchema = objectType({
48550
+ headers: recordType(arrayType(stringType())),
48551
+ result: Cancellation$outboundSchema
48552
+ }).transform((v2) => {
48553
+ return remap(v2, {
48554
+ headers: "Headers",
48555
+ result: "Result"
48556
+ });
48557
+ });
48558
+ ((GetCancellationResponse$) => {
48559
+ GetCancellationResponse$.inboundSchema = GetCancellationResponse$inboundSchema;
48560
+ GetCancellationResponse$.outboundSchema = GetCancellationResponse$outboundSchema;
48561
+ })(GetCancellationResponse$ ||= {});
48562
+ });
48563
+
48431
48564
  // src/models/operations/getcapability.ts
48432
48565
  var GetCapabilityGlobals$inboundSchema, GetCapabilityGlobals$outboundSchema, GetCapabilityGlobals$, GetCapabilityRequest$inboundSchema, GetCapabilityRequest$outboundSchema, GetCapabilityRequest$, GetCapabilityResponse$inboundSchema, GetCapabilityResponse$outboundSchema, GetCapabilityResponse$;
48433
48566
  var init_getcapability = __esm(() => {
@@ -54262,6 +54395,7 @@ var init_operations = __esm(() => {
54262
54395
  init_createaccount3();
54263
54396
  init_createapplepaysession2();
54264
54397
  init_createbrand();
54398
+ init_createcancellation();
54265
54399
  init_createfeeplanagreements();
54266
54400
  init_createonboardinginvite();
54267
54401
  init_createpaymentlink2();
@@ -54289,6 +54423,7 @@ var init_operations = __esm(() => {
54289
54423
  init_getbankaccount();
54290
54424
  init_getbankaccountverification();
54291
54425
  init_getbrand();
54426
+ init_getcancellation();
54292
54427
  init_getcapability();
54293
54428
  init_getcard();
54294
54429
  init_getdispute();
@@ -67767,11 +67902,125 @@ you'll need to specify the \`/accounts/{accountID}/transfers.write\` scope.`,
67767
67902
  };
67768
67903
  });
67769
67904
 
67770
- // src/funcs/transfersCreateReversal.ts
67771
- function transfersCreateReversal(client, request, options) {
67905
+ // src/funcs/transfersCreateCancellation.ts
67906
+ function transfersCreateCancellation(client, request, options) {
67772
67907
  return new APIPromise($do114(client, request, options));
67773
67908
  }
67774
67909
  async function $do114(client, request, options) {
67910
+ const parsed = safeParse(request, (value) => CreateCancellationRequest$outboundSchema.parse(value), "Input validation failed");
67911
+ if (!parsed.ok) {
67912
+ return [parsed, { status: "invalid" }];
67913
+ }
67914
+ const payload = parsed.value;
67915
+ const body = null;
67916
+ const pathParams = {
67917
+ accountID: encodeSimple("accountID", payload.accountID, {
67918
+ explode: false,
67919
+ charEncoding: "percent"
67920
+ }),
67921
+ transferID: encodeSimple("transferID", payload.transferID, {
67922
+ explode: false,
67923
+ charEncoding: "percent"
67924
+ })
67925
+ };
67926
+ const path = pathToFunc("/accounts/{accountID}/transfers/{transferID}/cancellations")(pathParams);
67927
+ const headers = new Headers(compactMap({
67928
+ Accept: "application/json",
67929
+ "x-moov-version": encodeSimple("x-moov-version", client._options.xMoovVersion, { explode: false, charEncoding: "none" })
67930
+ }));
67931
+ const securityInput = await extractSecurity(client._options.security);
67932
+ const requestSecurity = resolveGlobalSecurity(securityInput);
67933
+ const context = {
67934
+ baseURL: options?.serverURL ?? client._baseURL ?? "",
67935
+ operationID: "createCancellation",
67936
+ oAuth2Scopes: [],
67937
+ resolvedSecurity: requestSecurity,
67938
+ securitySource: client._options.security,
67939
+ retryConfig: options?.retries || client._options.retryConfig || { strategy: "none" },
67940
+ retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"]
67941
+ };
67942
+ const requestRes = client._createRequest(context, {
67943
+ security: requestSecurity,
67944
+ method: "POST",
67945
+ baseURL: options?.serverURL,
67946
+ path,
67947
+ headers,
67948
+ body,
67949
+ timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1
67950
+ }, options);
67951
+ if (!requestRes.ok) {
67952
+ return [requestRes, { status: "invalid" }];
67953
+ }
67954
+ const req = requestRes.value;
67955
+ const doResult = await client._do(req, {
67956
+ context,
67957
+ errorCodes: ["400", "401", "403", "404", "429", "4XX", "500", "504", "5XX"],
67958
+ retryConfig: context.retryConfig,
67959
+ retryCodes: context.retryCodes
67960
+ });
67961
+ if (!doResult.ok) {
67962
+ return [doResult, { status: "request-error", request: req }];
67963
+ }
67964
+ const response = doResult.value;
67965
+ const responseFields = {
67966
+ HttpMeta: { Response: response, Request: req }
67967
+ };
67968
+ const [result] = await match(json([200, 202], CreateCancellationResponse$inboundSchema, {
67969
+ hdrs: true,
67970
+ key: "Result"
67971
+ }), jsonErr(400, GenericError$inboundSchema, { hdrs: true }), fail([401, 403, 404, 429]), fail([500, 504]), fail("4XX"), fail("5XX"))(response, { extraFields: responseFields });
67972
+ if (!result.ok) {
67973
+ return [result, { status: "complete", request: req, response }];
67974
+ }
67975
+ return [result, { status: "complete", request: req, response }];
67976
+ }
67977
+ var init_transfersCreateCancellation = __esm(() => {
67978
+ init_encodings();
67979
+ init_matchers();
67980
+ init_primitives();
67981
+ init_schemas();
67982
+ init_security();
67983
+ init_url();
67984
+ init_errors();
67985
+ init_operations();
67986
+ init_async();
67987
+ });
67988
+
67989
+ // src/mcp-server/tools/transfersCreateCancellation.ts
67990
+ var args114, tool$transfersCreateCancellation;
67991
+ var init_transfersCreateCancellation2 = __esm(() => {
67992
+ init_transfersCreateCancellation();
67993
+ init_operations();
67994
+ init_tools();
67995
+ args114 = {
67996
+ request: CreateCancellationRequest$inboundSchema
67997
+ };
67998
+ tool$transfersCreateCancellation = {
67999
+ name: "transfers_create-cancellation",
68000
+ description: ` Initiate a cancellation for a card, ACH, or queued transfer.
68001
+
68002
+ To access this endpoint using a [token](https://docs.moov.io/api/authentication/access-tokens/) you'll need
68003
+ to specify the \`/accounts/{accountID}/transfers.write\` scope.`,
68004
+ args: args114,
68005
+ tool: async (client, args115, ctx) => {
68006
+ const [result, apiCall] = await transfersCreateCancellation(client, args115.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68007
+ if (!result.ok) {
68008
+ return {
68009
+ content: [{ type: "text", text: result.error.message }],
68010
+ isError: true
68011
+ };
68012
+ }
68013
+ const value = result.value.result;
68014
+ return formatResult(value, apiCall);
68015
+ }
68016
+ };
68017
+ });
68018
+
68019
+ // src/funcs/transfersCreateReversal.ts
68020
+ function transfersCreateReversal(client, request, options) {
68021
+ return new APIPromise($do115(client, request, options));
68022
+ }
68023
+ async function $do115(client, request, options) {
67775
68024
  const parsed = safeParse(request, (value) => CreateReversalRequest$outboundSchema.parse(value), "Input validation failed");
67776
68025
  if (!parsed.ok) {
67777
68026
  return [parsed, { status: "invalid" }];
@@ -67868,12 +68117,12 @@ var init_transfersCreateReversal = __esm(() => {
67868
68117
  });
67869
68118
 
67870
68119
  // src/mcp-server/tools/transfersCreateReversal.ts
67871
- var args114, tool$transfersCreateReversal;
68120
+ var args115, tool$transfersCreateReversal;
67872
68121
  var init_transfersCreateReversal2 = __esm(() => {
67873
68122
  init_transfersCreateReversal();
67874
68123
  init_operations();
67875
68124
  init_tools();
67876
- args114 = {
68125
+ args115 = {
67877
68126
  request: CreateReversalRequest$inboundSchema
67878
68127
  };
67879
68128
  tool$transfersCreateReversal = {
@@ -67884,9 +68133,9 @@ to learn more.
67884
68133
 
67885
68134
  To access this endpoint using a [token](https://docs.moov.io/api/authentication/access-tokens/) you'll need
67886
68135
  to specify the \`/accounts/{accountID}/transfers.write\` scope.`,
67887
- args: args114,
67888
- tool: async (client, args115, ctx) => {
67889
- const [result, apiCall] = await transfersCreateReversal(client, args115.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68136
+ args: args115,
68137
+ tool: async (client, args116, ctx) => {
68138
+ const [result, apiCall] = await transfersCreateReversal(client, args116.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
67890
68139
  if (!result.ok) {
67891
68140
  return {
67892
68141
  content: [{ type: "text", text: result.error.message }],
@@ -67901,9 +68150,9 @@ to specify the \`/accounts/{accountID}/transfers.write\` scope.`,
67901
68150
 
67902
68151
  // src/funcs/transfersGenerateOptions.ts
67903
68152
  function transfersGenerateOptions(client, request, options) {
67904
- return new APIPromise($do115(client, request, options));
68153
+ return new APIPromise($do116(client, request, options));
67905
68154
  }
67906
- async function $do115(client, request, options) {
68155
+ async function $do116(client, request, options) {
67907
68156
  const parsed = safeParse(request, (value) => CreateTransferOptions$outboundSchema.parse(value), "Input validation failed");
67908
68157
  if (!parsed.ok) {
67909
68158
  return [parsed, { status: "invalid" }];
@@ -67978,12 +68227,12 @@ var init_transfersGenerateOptions = __esm(() => {
67978
68227
  });
67979
68228
 
67980
68229
  // src/mcp-server/tools/transfersGenerateOptions.ts
67981
- var args115, tool$transfersGenerateOptions;
68230
+ var args116, tool$transfersGenerateOptions;
67982
68231
  var init_transfersGenerateOptions2 = __esm(() => {
67983
68232
  init_transfersGenerateOptions();
67984
68233
  init_components();
67985
68234
  init_tools();
67986
- args115 = {
68235
+ args116 = {
67987
68236
  request: CreateTransferOptions$inboundSchema
67988
68237
  };
67989
68238
  tool$transfersGenerateOptions = {
@@ -67995,9 +68244,9 @@ Read our [transfers overview guide](https://docs.moov.io/guides/money-movement/o
67995
68244
 
67996
68245
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
67997
68246
  you'll need to specify the \`/accounts/{accountID}/transfers.read\` scope.`,
67998
- args: args115,
67999
- tool: async (client, args116, ctx) => {
68000
- const [result, apiCall] = await transfersGenerateOptions(client, args116.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68247
+ args: args116,
68248
+ tool: async (client, args117, ctx) => {
68249
+ const [result, apiCall] = await transfersGenerateOptions(client, args117.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68001
68250
  if (!result.ok) {
68002
68251
  return {
68003
68252
  content: [{ type: "text", text: result.error.message }],
@@ -68012,9 +68261,9 @@ you'll need to specify the \`/accounts/{accountID}/transfers.read\` scope.`,
68012
68261
 
68013
68262
  // src/funcs/transfersGet.ts
68014
68263
  function transfersGet(client, request, options) {
68015
- return new APIPromise($do116(client, request, options));
68264
+ return new APIPromise($do117(client, request, options));
68016
68265
  }
68017
- async function $do116(client, request, options) {
68266
+ async function $do117(client, request, options) {
68018
68267
  const parsed = safeParse(request, (value) => GetTransferRequest$outboundSchema.parse(value), "Input validation failed");
68019
68268
  if (!parsed.ok) {
68020
68269
  return [parsed, { status: "invalid" }];
@@ -68094,12 +68343,12 @@ var init_transfersGet = __esm(() => {
68094
68343
  });
68095
68344
 
68096
68345
  // src/mcp-server/tools/transfersGet.ts
68097
- var args116, tool$transfersGet;
68346
+ var args117, tool$transfersGet;
68098
68347
  var init_transfersGet2 = __esm(() => {
68099
68348
  init_transfersGet();
68100
68349
  init_operations();
68101
68350
  init_tools();
68102
- args116 = {
68351
+ args117 = {
68103
68352
  request: GetTransferRequest$inboundSchema
68104
68353
  };
68105
68354
  tool$transfersGet = {
@@ -68111,9 +68360,126 @@ to learn more.
68111
68360
 
68112
68361
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
68113
68362
  you'll need to specify the \`/accounts/{accountID}/transfers.read\` scope.`,
68114
- args: args116,
68115
- tool: async (client, args117, ctx) => {
68116
- const [result, apiCall] = await transfersGet(client, args117.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68363
+ args: args117,
68364
+ tool: async (client, args118, ctx) => {
68365
+ const [result, apiCall] = await transfersGet(client, args118.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68366
+ if (!result.ok) {
68367
+ return {
68368
+ content: [{ type: "text", text: result.error.message }],
68369
+ isError: true
68370
+ };
68371
+ }
68372
+ const value = result.value.result;
68373
+ return formatResult(value, apiCall);
68374
+ }
68375
+ };
68376
+ });
68377
+
68378
+ // src/funcs/transfersGetCancellation.ts
68379
+ function transfersGetCancellation(client, request, options) {
68380
+ return new APIPromise($do118(client, request, options));
68381
+ }
68382
+ async function $do118(client, request, options) {
68383
+ const parsed = safeParse(request, (value) => GetCancellationRequest$outboundSchema.parse(value), "Input validation failed");
68384
+ if (!parsed.ok) {
68385
+ return [parsed, { status: "invalid" }];
68386
+ }
68387
+ const payload = parsed.value;
68388
+ const body = null;
68389
+ const pathParams = {
68390
+ accountID: encodeSimple("accountID", payload.accountID, {
68391
+ explode: false,
68392
+ charEncoding: "percent"
68393
+ }),
68394
+ cancellationID: encodeSimple("cancellationID", payload.cancellationID, {
68395
+ explode: false,
68396
+ charEncoding: "percent"
68397
+ }),
68398
+ transferID: encodeSimple("transferID", payload.transferID, {
68399
+ explode: false,
68400
+ charEncoding: "percent"
68401
+ })
68402
+ };
68403
+ const path = pathToFunc("/accounts/{accountID}/transfers/{transferID}/cancellations/{cancellationID}")(pathParams);
68404
+ const headers = new Headers(compactMap({
68405
+ Accept: "application/json",
68406
+ "x-moov-version": encodeSimple("x-moov-version", client._options.xMoovVersion, { explode: false, charEncoding: "none" })
68407
+ }));
68408
+ const securityInput = await extractSecurity(client._options.security);
68409
+ const requestSecurity = resolveGlobalSecurity(securityInput);
68410
+ const context = {
68411
+ baseURL: options?.serverURL ?? client._baseURL ?? "",
68412
+ operationID: "getCancellation",
68413
+ oAuth2Scopes: [],
68414
+ resolvedSecurity: requestSecurity,
68415
+ securitySource: client._options.security,
68416
+ retryConfig: options?.retries || client._options.retryConfig || { strategy: "none" },
68417
+ retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"]
68418
+ };
68419
+ const requestRes = client._createRequest(context, {
68420
+ security: requestSecurity,
68421
+ method: "GET",
68422
+ baseURL: options?.serverURL,
68423
+ path,
68424
+ headers,
68425
+ body,
68426
+ timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1
68427
+ }, options);
68428
+ if (!requestRes.ok) {
68429
+ return [requestRes, { status: "invalid" }];
68430
+ }
68431
+ const req = requestRes.value;
68432
+ const doResult = await client._do(req, {
68433
+ context,
68434
+ errorCodes: ["401", "403", "404", "429", "4XX", "500", "504", "5XX"],
68435
+ retryConfig: context.retryConfig,
68436
+ retryCodes: context.retryCodes
68437
+ });
68438
+ if (!doResult.ok) {
68439
+ return [doResult, { status: "request-error", request: req }];
68440
+ }
68441
+ const response = doResult.value;
68442
+ const responseFields = {
68443
+ HttpMeta: { Response: response, Request: req }
68444
+ };
68445
+ const [result] = await match(json(200, GetCancellationResponse$inboundSchema, {
68446
+ hdrs: true,
68447
+ key: "Result"
68448
+ }), fail([401, 403, 404, 429]), fail([500, 504]), fail("4XX"), fail("5XX"))(response, { extraFields: responseFields });
68449
+ if (!result.ok) {
68450
+ return [result, { status: "complete", request: req, response }];
68451
+ }
68452
+ return [result, { status: "complete", request: req, response }];
68453
+ }
68454
+ var init_transfersGetCancellation = __esm(() => {
68455
+ init_encodings();
68456
+ init_matchers();
68457
+ init_primitives();
68458
+ init_schemas();
68459
+ init_security();
68460
+ init_url();
68461
+ init_operations();
68462
+ init_async();
68463
+ });
68464
+
68465
+ // src/mcp-server/tools/transfersGetCancellation.ts
68466
+ var args118, tool$transfersGetCancellation;
68467
+ var init_transfersGetCancellation2 = __esm(() => {
68468
+ init_transfersGetCancellation();
68469
+ init_operations();
68470
+ init_tools();
68471
+ args118 = {
68472
+ request: GetCancellationRequest$inboundSchema
68473
+ };
68474
+ tool$transfersGetCancellation = {
68475
+ name: "transfers_get-cancellation",
68476
+ description: ` Get details of a cancellation for a transfer.
68477
+
68478
+ To access this endpoint using a [token](https://docs.moov.io/api/authentication/access-tokens/) you'll need
68479
+ to specify the \`/accounts/{accountID}/transfers.read\` scope.`,
68480
+ args: args118,
68481
+ tool: async (client, args119, ctx) => {
68482
+ const [result, apiCall] = await transfersGetCancellation(client, args119.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68117
68483
  if (!result.ok) {
68118
68484
  return {
68119
68485
  content: [{ type: "text", text: result.error.message }],
@@ -68128,9 +68494,9 @@ you'll need to specify the \`/accounts/{accountID}/transfers.read\` scope.`,
68128
68494
 
68129
68495
  // src/funcs/transfersGetRefund.ts
68130
68496
  function transfersGetRefund(client, request, options) {
68131
- return new APIPromise($do117(client, request, options));
68497
+ return new APIPromise($do119(client, request, options));
68132
68498
  }
68133
- async function $do117(client, request, options) {
68499
+ async function $do119(client, request, options) {
68134
68500
  const parsed = safeParse(request, (value) => GetRefundRequest$outboundSchema.parse(value), "Input validation failed");
68135
68501
  if (!parsed.ok) {
68136
68502
  return [parsed, { status: "invalid" }];
@@ -68214,12 +68580,12 @@ var init_transfersGetRefund = __esm(() => {
68214
68580
  });
68215
68581
 
68216
68582
  // src/mcp-server/tools/transfersGetRefund.ts
68217
- var args117, tool$transfersGetRefund;
68583
+ var args119, tool$transfersGetRefund;
68218
68584
  var init_transfersGetRefund2 = __esm(() => {
68219
68585
  init_transfersGetRefund();
68220
68586
  init_operations();
68221
68587
  init_tools();
68222
- args117 = {
68588
+ args119 = {
68223
68589
  request: GetRefundRequest$inboundSchema
68224
68590
  };
68225
68591
  tool$transfersGetRefund = {
@@ -68228,9 +68594,9 @@ var init_transfersGetRefund2 = __esm(() => {
68228
68594
 
68229
68595
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
68230
68596
  you'll need to specify the \`/accounts/{accountID}/transfers.read\` scope.`,
68231
- args: args117,
68232
- tool: async (client, args118, ctx) => {
68233
- const [result, apiCall] = await transfersGetRefund(client, args118.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68597
+ args: args119,
68598
+ tool: async (client, args120, ctx) => {
68599
+ const [result, apiCall] = await transfersGetRefund(client, args120.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68234
68600
  if (!result.ok) {
68235
68601
  return {
68236
68602
  content: [{ type: "text", text: result.error.message }],
@@ -68245,9 +68611,9 @@ you'll need to specify the \`/accounts/{accountID}/transfers.read\` scope.`,
68245
68611
 
68246
68612
  // src/funcs/transfersInitiateRefund.ts
68247
68613
  function transfersInitiateRefund(client, request, options) {
68248
- return new APIPromise($do118(client, request, options));
68614
+ return new APIPromise($do120(client, request, options));
68249
68615
  }
68250
- async function $do118(client, request, options) {
68616
+ async function $do120(client, request, options) {
68251
68617
  const parsed = safeParse(request, (value) => InitiateRefundRequest$outboundSchema.parse(value), "Input validation failed");
68252
68618
  if (!parsed.ok) {
68253
68619
  return [parsed, { status: "invalid" }];
@@ -68337,12 +68703,12 @@ var init_transfersInitiateRefund = __esm(() => {
68337
68703
  });
68338
68704
 
68339
68705
  // src/mcp-server/tools/transfersInitiateRefund.ts
68340
- var args118, tool$transfersInitiateRefund;
68706
+ var args120, tool$transfersInitiateRefund;
68341
68707
  var init_transfersInitiateRefund2 = __esm(() => {
68342
68708
  init_transfersInitiateRefund();
68343
68709
  init_operations();
68344
68710
  init_tools();
68345
- args118 = {
68711
+ args120 = {
68346
68712
  request: InitiateRefundRequest$inboundSchema
68347
68713
  };
68348
68714
  tool$transfersInitiateRefund = {
@@ -68354,9 +68720,9 @@ See the [reversals](https://docs.moov.io/guides/money-movement/accept-payments/c
68354
68720
 
68355
68721
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
68356
68722
  you'll need to specify the \`/accounts/{accountID}/transfers.write\` scope.`,
68357
- args: args118,
68358
- tool: async (client, args119, ctx) => {
68359
- const [result, apiCall] = await transfersInitiateRefund(client, args119.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68723
+ args: args120,
68724
+ tool: async (client, args121, ctx) => {
68725
+ const [result, apiCall] = await transfersInitiateRefund(client, args121.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68360
68726
  if (!result.ok) {
68361
68727
  return {
68362
68728
  content: [{ type: "text", text: result.error.message }],
@@ -68371,9 +68737,9 @@ you'll need to specify the \`/accounts/{accountID}/transfers.write\` scope.`,
68371
68737
 
68372
68738
  // src/funcs/transfersList.ts
68373
68739
  function transfersList(client, request, options) {
68374
- return new APIPromise($do119(client, request, options));
68740
+ return new APIPromise($do121(client, request, options));
68375
68741
  }
68376
- async function $do119(client, request, options) {
68742
+ async function $do121(client, request, options) {
68377
68743
  const parsed = safeParse(request, (value) => ListTransfersRequest$outboundSchema.parse(value), "Input validation failed");
68378
68744
  if (!parsed.ok) {
68379
68745
  return [parsed, { status: "invalid" }];
@@ -68461,12 +68827,12 @@ var init_transfersList = __esm(() => {
68461
68827
  });
68462
68828
 
68463
68829
  // src/mcp-server/tools/transfersList.ts
68464
- var args119, tool$transfersList;
68830
+ var args121, tool$transfersList;
68465
68831
  var init_transfersList2 = __esm(() => {
68466
68832
  init_transfersList();
68467
68833
  init_operations();
68468
68834
  init_tools();
68469
- args119 = {
68835
+ args121 = {
68470
68836
  request: ListTransfersRequest$inboundSchema
68471
68837
  };
68472
68838
  tool$transfersList = {
@@ -68482,9 +68848,9 @@ period of time. You can run multiple requests in smaller time window increments
68482
68848
 
68483
68849
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
68484
68850
  you'll need to specify the \`/accounts/{accountID}/transfers.read\` scope.`,
68485
- args: args119,
68486
- tool: async (client, args120, ctx) => {
68487
- const [result, apiCall] = await transfersList(client, args120.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68851
+ args: args121,
68852
+ tool: async (client, args122, ctx) => {
68853
+ const [result, apiCall] = await transfersList(client, args122.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68488
68854
  if (!result.ok) {
68489
68855
  return {
68490
68856
  content: [{ type: "text", text: result.error.message }],
@@ -68499,9 +68865,9 @@ you'll need to specify the \`/accounts/{accountID}/transfers.read\` scope.`,
68499
68865
 
68500
68866
  // src/funcs/transfersListRefunds.ts
68501
68867
  function transfersListRefunds(client, request, options) {
68502
- return new APIPromise($do120(client, request, options));
68868
+ return new APIPromise($do122(client, request, options));
68503
68869
  }
68504
- async function $do120(client, request, options) {
68870
+ async function $do122(client, request, options) {
68505
68871
  const parsed = safeParse(request, (value) => ListRefundsRequest$outboundSchema.parse(value), "Input validation failed");
68506
68872
  if (!parsed.ok) {
68507
68873
  return [parsed, { status: "invalid" }];
@@ -68581,12 +68947,12 @@ var init_transfersListRefunds = __esm(() => {
68581
68947
  });
68582
68948
 
68583
68949
  // src/mcp-server/tools/transfersListRefunds.ts
68584
- var args120, tool$transfersListRefunds;
68950
+ var args122, tool$transfersListRefunds;
68585
68951
  var init_transfersListRefunds2 = __esm(() => {
68586
68952
  init_transfersListRefunds();
68587
68953
  init_operations();
68588
68954
  init_tools();
68589
- args120 = {
68955
+ args122 = {
68590
68956
  request: ListRefundsRequest$inboundSchema
68591
68957
  };
68592
68958
  tool$transfersListRefunds = {
@@ -68595,9 +68961,9 @@ var init_transfersListRefunds2 = __esm(() => {
68595
68961
 
68596
68962
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
68597
68963
  you'll need to specify the \`/accounts/{accountID}/transfers.read\` scope.`,
68598
- args: args120,
68599
- tool: async (client, args121, ctx) => {
68600
- const [result, apiCall] = await transfersListRefunds(client, args121.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68964
+ args: args122,
68965
+ tool: async (client, args123, ctx) => {
68966
+ const [result, apiCall] = await transfersListRefunds(client, args123.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68601
68967
  if (!result.ok) {
68602
68968
  return {
68603
68969
  content: [{ type: "text", text: result.error.message }],
@@ -68612,9 +68978,9 @@ you'll need to specify the \`/accounts/{accountID}/transfers.read\` scope.`,
68612
68978
 
68613
68979
  // src/funcs/transfersUpdate.ts
68614
68980
  function transfersUpdate(client, request, options) {
68615
- return new APIPromise($do121(client, request, options));
68981
+ return new APIPromise($do123(client, request, options));
68616
68982
  }
68617
- async function $do121(client, request, options) {
68983
+ async function $do123(client, request, options) {
68618
68984
  const parsed = safeParse(request, (value) => UpdateTransferRequest$outboundSchema.parse(value), "Input validation failed");
68619
68985
  if (!parsed.ok) {
68620
68986
  return [parsed, { status: "invalid" }];
@@ -68695,12 +69061,12 @@ var init_transfersUpdate = __esm(() => {
68695
69061
  });
68696
69062
 
68697
69063
  // src/mcp-server/tools/transfersUpdate.ts
68698
- var args121, tool$transfersUpdate;
69064
+ var args123, tool$transfersUpdate;
68699
69065
  var init_transfersUpdate2 = __esm(() => {
68700
69066
  init_transfersUpdate();
68701
69067
  init_operations();
68702
69068
  init_tools();
68703
- args121 = {
69069
+ args123 = {
68704
69070
  request: UpdateTransferRequest$inboundSchema
68705
69071
  };
68706
69072
  tool$transfersUpdate = {
@@ -68711,9 +69077,9 @@ Read our [transfers overview guide](https://docs.moov.io/guides/money-movement/o
68711
69077
 
68712
69078
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
68713
69079
  you'll need to specify the \`/accounts/{accountID}/transfers.write\` scope.`,
68714
- args: args121,
68715
- tool: async (client, args122, ctx) => {
68716
- const [result, apiCall] = await transfersUpdate(client, args122.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
69080
+ args: args123,
69081
+ tool: async (client, args124, ctx) => {
69082
+ const [result, apiCall] = await transfersUpdate(client, args124.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68717
69083
  if (!result.ok) {
68718
69084
  return {
68719
69085
  content: [{ type: "text", text: result.error.message }],
@@ -68728,9 +69094,9 @@ you'll need to specify the \`/accounts/{accountID}/transfers.write\` scope.`,
68728
69094
 
68729
69095
  // src/funcs/underwritingGet.ts
68730
69096
  function underwritingGet(client, request, options) {
68731
- return new APIPromise($do122(client, request, options));
69097
+ return new APIPromise($do124(client, request, options));
68732
69098
  }
68733
- async function $do122(client, request, options) {
69099
+ async function $do124(client, request, options) {
68734
69100
  const parsed = safeParse(request, (value) => GetUnderwritingRequest$outboundSchema.parse(value), "Input validation failed");
68735
69101
  if (!parsed.ok) {
68736
69102
  return [parsed, { status: "invalid" }];
@@ -68806,12 +69172,12 @@ var init_underwritingGet = __esm(() => {
68806
69172
  });
68807
69173
 
68808
69174
  // src/mcp-server/tools/underwritingGet.ts
68809
- var args122, tool$underwritingGet;
69175
+ var args124, tool$underwritingGet;
68810
69176
  var init_underwritingGet2 = __esm(() => {
68811
69177
  init_underwritingGet();
68812
69178
  init_operations();
68813
69179
  init_tools();
68814
- args122 = {
69180
+ args124 = {
68815
69181
  request: GetUnderwritingRequest$inboundSchema
68816
69182
  };
68817
69183
  tool$underwritingGet = {
@@ -68822,9 +69188,9 @@ Read our [underwriting guide](https://docs.moov.io/guides/accounts/requirements/
68822
69188
 
68823
69189
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
68824
69190
  you'll need to specify the \`/accounts/{accountID}/profile.read\` scope.`,
68825
- args: args122,
68826
- tool: async (client, args123, ctx) => {
68827
- const [result, apiCall] = await underwritingGet(client, args123.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
69191
+ args: args124,
69192
+ tool: async (client, args125, ctx) => {
69193
+ const [result, apiCall] = await underwritingGet(client, args125.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68828
69194
  if (!result.ok) {
68829
69195
  return {
68830
69196
  content: [{ type: "text", text: result.error.message }],
@@ -68839,9 +69205,9 @@ you'll need to specify the \`/accounts/{accountID}/profile.read\` scope.`,
68839
69205
 
68840
69206
  // src/funcs/underwritingUpsert.ts
68841
69207
  function underwritingUpsert(client, request, options) {
68842
- return new APIPromise($do123(client, request, options));
69208
+ return new APIPromise($do125(client, request, options));
68843
69209
  }
68844
- async function $do123(client, request, options) {
69210
+ async function $do125(client, request, options) {
68845
69211
  const parsed = safeParse(request, (value) => UpsertUnderwritingRequest$outboundSchema.parse(value), "Input validation failed");
68846
69212
  if (!parsed.ok) {
68847
69213
  return [parsed, { status: "invalid" }];
@@ -68935,12 +69301,12 @@ var init_underwritingUpsert = __esm(() => {
68935
69301
  });
68936
69302
 
68937
69303
  // src/mcp-server/tools/underwritingUpsert.ts
68938
- var args123, tool$underwritingUpsert;
69304
+ var args125, tool$underwritingUpsert;
68939
69305
  var init_underwritingUpsert2 = __esm(() => {
68940
69306
  init_underwritingUpsert();
68941
69307
  init_operations();
68942
69308
  init_tools();
68943
- args123 = {
69309
+ args125 = {
68944
69310
  request: UpsertUnderwritingRequest$inboundSchema
68945
69311
  };
68946
69312
  tool$underwritingUpsert = {
@@ -68951,9 +69317,9 @@ Read our [underwriting guide](https://docs.moov.io/guides/accounts/requirements/
68951
69317
 
68952
69318
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
68953
69319
  you'll need to specify the \`/accounts/{accountID}/profile.write\` scope.`,
68954
- args: args123,
68955
- tool: async (client, args124, ctx) => {
68956
- const [result, apiCall] = await underwritingUpsert(client, args124.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
69320
+ args: args125,
69321
+ tool: async (client, args126, ctx) => {
69322
+ const [result, apiCall] = await underwritingUpsert(client, args126.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
68957
69323
  if (!result.ok) {
68958
69324
  return {
68959
69325
  content: [{ type: "text", text: result.error.message }],
@@ -68968,9 +69334,9 @@ you'll need to specify the \`/accounts/{accountID}/profile.write\` scope.`,
68968
69334
 
68969
69335
  // src/funcs/walletsGet.ts
68970
69336
  function walletsGet(client, request, options) {
68971
- return new APIPromise($do124(client, request, options));
69337
+ return new APIPromise($do126(client, request, options));
68972
69338
  }
68973
- async function $do124(client, request, options) {
69339
+ async function $do126(client, request, options) {
68974
69340
  const parsed = safeParse(request, (value) => GetWalletRequest$outboundSchema.parse(value), "Input validation failed");
68975
69341
  if (!parsed.ok) {
68976
69342
  return [parsed, { status: "invalid" }];
@@ -69050,12 +69416,12 @@ var init_walletsGet = __esm(() => {
69050
69416
  });
69051
69417
 
69052
69418
  // src/mcp-server/tools/walletsGet.ts
69053
- var args124, tool$walletsGet;
69419
+ var args126, tool$walletsGet;
69054
69420
  var init_walletsGet2 = __esm(() => {
69055
69421
  init_walletsGet();
69056
69422
  init_operations();
69057
69423
  init_tools();
69058
- args124 = {
69424
+ args126 = {
69059
69425
  request: GetWalletRequest$inboundSchema
69060
69426
  };
69061
69427
  tool$walletsGet = {
@@ -69066,9 +69432,9 @@ Read our [Moov wallets guide](https://docs.moov.io/guides/sources/wallets/) to l
69066
69432
 
69067
69433
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
69068
69434
  you'll need to specify the \`/accounts/{accountID}/wallets.read\` scope.`,
69069
- args: args124,
69070
- tool: async (client, args125, ctx) => {
69071
- const [result, apiCall] = await walletsGet(client, args125.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
69435
+ args: args126,
69436
+ tool: async (client, args127, ctx) => {
69437
+ const [result, apiCall] = await walletsGet(client, args127.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
69072
69438
  if (!result.ok) {
69073
69439
  return {
69074
69440
  content: [{ type: "text", text: result.error.message }],
@@ -69083,9 +69449,9 @@ you'll need to specify the \`/accounts/{accountID}/wallets.read\` scope.`,
69083
69449
 
69084
69450
  // src/funcs/walletsList.ts
69085
69451
  function walletsList(client, request, options) {
69086
- return new APIPromise($do125(client, request, options));
69452
+ return new APIPromise($do127(client, request, options));
69087
69453
  }
69088
- async function $do125(client, request, options) {
69454
+ async function $do127(client, request, options) {
69089
69455
  const parsed = safeParse(request, (value) => ListWalletsRequest$outboundSchema.parse(value), "Input validation failed");
69090
69456
  if (!parsed.ok) {
69091
69457
  return [parsed, { status: "invalid" }];
@@ -69161,12 +69527,12 @@ var init_walletsList = __esm(() => {
69161
69527
  });
69162
69528
 
69163
69529
  // src/mcp-server/tools/walletsList.ts
69164
- var args125, tool$walletsList;
69530
+ var args127, tool$walletsList;
69165
69531
  var init_walletsList2 = __esm(() => {
69166
69532
  init_walletsList();
69167
69533
  init_operations();
69168
69534
  init_tools();
69169
- args125 = {
69535
+ args127 = {
69170
69536
  request: ListWalletsRequest$inboundSchema
69171
69537
  };
69172
69538
  tool$walletsList = {
@@ -69177,9 +69543,9 @@ Read our [Moov wallets guide](https://docs.moov.io/guides/sources/wallets/) to l
69177
69543
 
69178
69544
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
69179
69545
  you'll need to specify the \`/accounts/{accountID}/wallets.read\` scope.`,
69180
- args: args125,
69181
- tool: async (client, args126, ctx) => {
69182
- const [result, apiCall] = await walletsList(client, args126.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
69546
+ args: args127,
69547
+ tool: async (client, args128, ctx) => {
69548
+ const [result, apiCall] = await walletsList(client, args128.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
69183
69549
  if (!result.ok) {
69184
69550
  return {
69185
69551
  content: [{ type: "text", text: result.error.message }],
@@ -69194,9 +69560,9 @@ you'll need to specify the \`/accounts/{accountID}/wallets.read\` scope.`,
69194
69560
 
69195
69561
  // src/funcs/walletTransactionsGet.ts
69196
69562
  function walletTransactionsGet(client, request, options) {
69197
- return new APIPromise($do126(client, request, options));
69563
+ return new APIPromise($do128(client, request, options));
69198
69564
  }
69199
- async function $do126(client, request, options) {
69565
+ async function $do128(client, request, options) {
69200
69566
  const parsed = safeParse(request, (value) => GetWalletTransactionRequest$outboundSchema.parse(value), "Input validation failed");
69201
69567
  if (!parsed.ok) {
69202
69568
  return [parsed, { status: "invalid" }];
@@ -69280,12 +69646,12 @@ var init_walletTransactionsGet = __esm(() => {
69280
69646
  });
69281
69647
 
69282
69648
  // src/mcp-server/tools/walletTransactionsGet.ts
69283
- var args126, tool$walletTransactionsGet;
69649
+ var args128, tool$walletTransactionsGet;
69284
69650
  var init_walletTransactionsGet2 = __esm(() => {
69285
69651
  init_walletTransactionsGet();
69286
69652
  init_operations();
69287
69653
  init_tools();
69288
- args126 = {
69654
+ args128 = {
69289
69655
  request: GetWalletTransactionRequest$inboundSchema
69290
69656
  };
69291
69657
  tool$walletTransactionsGet = {
@@ -69296,9 +69662,9 @@ Read our [wallet transactions guide](https://docs.moov.io/guides/sources/wallets
69296
69662
 
69297
69663
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
69298
69664
  you'll need to specify the \`/accounts/{accountID}/wallets.read\` scope.`,
69299
- args: args126,
69300
- tool: async (client, args127, ctx) => {
69301
- const [result, apiCall] = await walletTransactionsGet(client, args127.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
69665
+ args: args128,
69666
+ tool: async (client, args129, ctx) => {
69667
+ const [result, apiCall] = await walletTransactionsGet(client, args129.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
69302
69668
  if (!result.ok) {
69303
69669
  return {
69304
69670
  content: [{ type: "text", text: result.error.message }],
@@ -69313,9 +69679,9 @@ you'll need to specify the \`/accounts/{accountID}/wallets.read\` scope.`,
69313
69679
 
69314
69680
  // src/funcs/walletTransactionsList.ts
69315
69681
  function walletTransactionsList(client, request, options) {
69316
- return new APIPromise($do127(client, request, options));
69682
+ return new APIPromise($do129(client, request, options));
69317
69683
  }
69318
- async function $do127(client, request, options) {
69684
+ async function $do129(client, request, options) {
69319
69685
  const parsed = safeParse(request, (value) => ListWalletTransactionsRequest$outboundSchema.parse(value), "Input validation failed");
69320
69686
  if (!parsed.ok) {
69321
69687
  return [parsed, { status: "invalid" }];
@@ -69410,12 +69776,12 @@ var init_walletTransactionsList = __esm(() => {
69410
69776
  });
69411
69777
 
69412
69778
  // src/mcp-server/tools/walletTransactionsList.ts
69413
- var args127, tool$walletTransactionsList;
69779
+ var args129, tool$walletTransactionsList;
69414
69780
  var init_walletTransactionsList2 = __esm(() => {
69415
69781
  init_walletTransactionsList();
69416
69782
  init_operations();
69417
69783
  init_tools();
69418
- args127 = {
69784
+ args129 = {
69419
69785
  request: ListWalletTransactionsRequest$inboundSchema
69420
69786
  };
69421
69787
  tool$walletTransactionsList = {
@@ -69426,9 +69792,9 @@ Read our [wallet transactions guide](https://docs.moov.io/guides/sources/wallets
69426
69792
 
69427
69793
  To access this endpoint using an [access token](https://docs.moov.io/api/authentication/access-tokens/)
69428
69794
  you'll need to specify the \`/accounts/{accountID}/wallets.read\` scope.`,
69429
- args: args127,
69430
- tool: async (client, args128, ctx) => {
69431
- const [result, apiCall] = await walletTransactionsList(client, args128.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
69795
+ args: args129,
69796
+ tool: async (client, args130, ctx) => {
69797
+ const [result, apiCall] = await walletTransactionsList(client, args130.request, { fetchOptions: { signal: ctx.signal } }).$inspect();
69432
69798
  if (!result.ok) {
69433
69799
  return {
69434
69800
  content: [{ type: "text", text: result.error.message }],
@@ -69445,7 +69811,7 @@ you'll need to specify the \`/accounts/{accountID}/wallets.read\` scope.`,
69445
69811
  function createMCPServer(deps) {
69446
69812
  const server = new McpServer({
69447
69813
  name: "Moov",
69448
- version: "0.5.4"
69814
+ version: "0.6.1"
69449
69815
  });
69450
69816
  const client = new MoovCore({
69451
69817
  security: deps.security,
@@ -69454,7 +69820,8 @@ function createMCPServer(deps) {
69454
69820
  serverIdx: deps.serverIdx
69455
69821
  });
69456
69822
  const scopes = new Set(deps.scopes ?? mcpScopes);
69457
- const tool = createRegisterTool(deps.logger, server, client, scopes);
69823
+ const allowedTools = deps.allowedTools && new Set(deps.allowedTools);
69824
+ const tool = createRegisterTool(deps.logger, server, client, scopes, allowedTools);
69458
69825
  tool(tool$accountsCreate);
69459
69826
  tool(tool$accountsList);
69460
69827
  tool(tool$accountsGet);
@@ -69543,6 +69910,8 @@ function createMCPServer(deps) {
69543
69910
  tool(tool$transfersList);
69544
69911
  tool(tool$transfersGet);
69545
69912
  tool(tool$transfersUpdate);
69913
+ tool(tool$transfersCreateCancellation);
69914
+ tool(tool$transfersGetCancellation);
69546
69915
  tool(tool$transfersInitiateRefund);
69547
69916
  tool(tool$transfersListRefunds);
69548
69917
  tool(tool$transfersGetRefund);
@@ -69702,9 +70071,11 @@ var init_server2 = __esm(() => {
69702
70071
  init_terminalApplicationsGet2();
69703
70072
  init_terminalApplicationsList2();
69704
70073
  init_transfersCreate2();
70074
+ init_transfersCreateCancellation2();
69705
70075
  init_transfersCreateReversal2();
69706
70076
  init_transfersGenerateOptions2();
69707
70077
  init_transfersGet2();
70078
+ init_transfersGetCancellation2();
69708
70079
  init_transfersGetRefund2();
69709
70080
  init_transfersInitiateRefund2();
69710
70081
  init_transfersList2();
@@ -69743,6 +70114,7 @@ async function startStdio(flags) {
69743
70114
  const transport = new StdioServerTransport;
69744
70115
  const server = createMCPServer({
69745
70116
  logger,
70117
+ allowedTools: flags.tool,
69746
70118
  scopes: flags.scope,
69747
70119
  security: allRequired({
69748
70120
  username: flags.username,
@@ -69765,6 +70137,7 @@ async function startSSE(flags) {
69765
70137
  const app = import_express.default();
69766
70138
  const mcpServer = createMCPServer({
69767
70139
  logger,
70140
+ allowedTools: flags.tool,
69768
70141
  scopes: flags.scope,
69769
70142
  security: allRequired({
69770
70143
  username: flags.username,
@@ -70827,6 +71200,15 @@ var startCommand = tn({
70827
71200
  default: "2718",
70828
71201
  parse: (val) => coerce.number().int().gte(0).lt(65536).parse(val)
70829
71202
  },
71203
+ tool: {
71204
+ kind: "parsed",
71205
+ brief: "Specify tools to mount on the server",
71206
+ optional: true,
71207
+ variadic: true,
71208
+ parse: (value) => {
71209
+ return stringType().parse(value);
71210
+ }
71211
+ },
70830
71212
  ...mcpScopes.length ? {
70831
71213
  scope: {
70832
71214
  kind: "enum",
@@ -70919,7 +71301,7 @@ var routes = rn({
70919
71301
  var app = Ve(routes, {
70920
71302
  name: "mcp",
70921
71303
  versionInfo: {
70922
- currentVersion: "0.5.4"
71304
+ currentVersion: "0.6.1"
70923
71305
  }
70924
71306
  });
70925
71307
  _t(app, process3.argv.slice(2), buildContext(process3));
@@ -70927,5 +71309,5 @@ export {
70927
71309
  app
70928
71310
  };
70929
71311
 
70930
- //# debugId=EA4CBA0C0735281D64756E2164756E21
71312
+ //# debugId=A177DDA8F2BF43C064756E2164756E21
70931
71313
  //# sourceMappingURL=mcp-server.js.map