@moovio/sdk 24.1.4 → 24.1.6

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/README.md CHANGED
@@ -2340,19 +2340,23 @@ The `HTTPClient` constructor takes an optional `fetcher` argument that can be
2340
2340
  used to integrate a third-party HTTP client or when writing tests to mock out
2341
2341
  the HTTP client and feed in fixtures.
2342
2342
 
2343
- The following example shows how to use the `"beforeRequest"` hook to to add a
2344
- custom header and a timeout to requests and how to use the `"requestError"` hook
2345
- to log errors:
2343
+ The following example shows how to:
2344
+ - route requests through a proxy server using [undici](https://www.npmjs.com/package/undici)'s ProxyAgent
2345
+ - use the `"beforeRequest"` hook to add a custom header and a timeout to requests
2346
+ - use the `"requestError"` hook to log errors
2346
2347
 
2347
2348
  ```typescript
2348
2349
  import { Moov } from "@moovio/sdk";
2350
+ import { ProxyAgent } from "undici";
2349
2351
  import { HTTPClient } from "@moovio/sdk/lib/http";
2350
2352
 
2353
+ const dispatcher = new ProxyAgent("http://proxy.example.com:8080");
2354
+
2351
2355
  const httpClient = new HTTPClient({
2352
- // fetcher takes a function that has the same signature as native `fetch`.
2353
- fetcher: (request) => {
2354
- return fetch(request);
2355
- }
2356
+ // 'fetcher' takes a function that has the same signature as native 'fetch'.
2357
+ fetcher: (input, init) =>
2358
+ // 'dispatcher' is specific to undici and not part of the standard Fetch API.
2359
+ fetch(input, { ...init, dispatcher } as RequestInit),
2356
2360
  });
2357
2361
 
2358
2362
  httpClient.addHook("beforeRequest", (request) => {
package/bin/mcp-server.js CHANGED
@@ -52879,9 +52879,9 @@ var init_config = __esm(() => {
52879
52879
  SDK_METADATA = {
52880
52880
  language: "typescript",
52881
52881
  openapiDocVersion: "v2024.01.00",
52882
- sdkVersion: "24.1.4",
52883
- genVersion: "2.816.0",
52884
- userAgent: "speakeasy-sdk/typescript 24.1.4 2.816.0 v2024.01.00 @moovio/sdk"
52882
+ sdkVersion: "24.1.6",
52883
+ genVersion: "2.821.8",
52884
+ userAgent: "speakeasy-sdk/typescript 24.1.6 2.821.8 v2024.01.00 @moovio/sdk"
52885
52885
  };
52886
52886
  });
52887
52887
 
@@ -62758,14 +62758,16 @@ var init_generatedby = __esm(() => {
62758
62758
  cardID: stringType().optional(),
62759
62759
  disputeID: stringType().optional(),
62760
62760
  accountID: stringType().optional(),
62761
- bankAccountID: stringType().optional()
62761
+ bankAccountID: stringType().optional(),
62762
+ invoiceID: stringType().optional()
62762
62763
  });
62763
62764
  GeneratedBy$outboundSchema = objectType({
62764
62765
  transferID: stringType().optional(),
62765
62766
  cardID: stringType().optional(),
62766
62767
  disputeID: stringType().optional(),
62767
62768
  accountID: stringType().optional(),
62768
- bankAccountID: stringType().optional()
62769
+ bankAccountID: stringType().optional(),
62770
+ invoiceID: stringType().optional()
62769
62771
  });
62770
62772
  });
62771
62773
 
@@ -98388,7 +98390,7 @@ var init_webhooksUpdate2 = __esm(() => {
98388
98390
  function createMCPServer(deps) {
98389
98391
  const server = new McpServer({
98390
98392
  name: "Moov",
98391
- version: "24.1.4"
98393
+ version: "24.1.6"
98392
98394
  });
98393
98395
  const client = new MoovCore({
98394
98396
  security: deps.security,
@@ -99942,7 +99944,7 @@ var routes = rn({
99942
99944
  var app = Ve(routes, {
99943
99945
  name: "mcp",
99944
99946
  versionInfo: {
99945
- currentVersion: "24.1.4"
99947
+ currentVersion: "24.1.6"
99946
99948
  }
99947
99949
  });
99948
99950
  _t(app, process3.argv.slice(2), buildContext(process3));
@@ -99950,5 +99952,5 @@ export {
99950
99952
  app
99951
99953
  };
99952
99954
 
99953
- //# debugId=C09FFA158B02DFAB64756E2164756E21
99955
+ //# debugId=C92541FCED3C347C64756E2164756E21
99954
99956
  //# sourceMappingURL=mcp-server.js.map