autumn-js 1.2.8 → 1.2.10

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 (60) hide show
  1. package/dist/backend/adapters/express.js +14 -26
  2. package/dist/backend/adapters/express.mjs +5 -5
  3. package/dist/backend/adapters/fetch.js +14 -26
  4. package/dist/backend/adapters/fetch.mjs +5 -5
  5. package/dist/backend/adapters/hono.js +14 -26
  6. package/dist/backend/adapters/hono.mjs +5 -5
  7. package/dist/backend/adapters/index.js +14 -26
  8. package/dist/backend/adapters/index.mjs +8 -8
  9. package/dist/backend/adapters/next.js +14 -26
  10. package/dist/backend/adapters/next.mjs +5 -5
  11. package/dist/backend/{chunk-EHOQ52YN.mjs → chunk-67LO3DQD.mjs} +1 -1
  12. package/dist/backend/{chunk-2SJN2D5K.mjs → chunk-747OIE4V.mjs} +1 -1
  13. package/dist/backend/{chunk-3KJVXSBT.mjs → chunk-GEUMIITE.mjs} +1 -1
  14. package/dist/backend/{chunk-5J2AJ3AR.mjs → chunk-HGGHOITQ.mjs} +14 -26
  15. package/dist/backend/{chunk-OI6KS2W5.mjs → chunk-IH7B2HKV.mjs} +1 -1
  16. package/dist/backend/{chunk-EJFVGOSH.mjs → chunk-OMSCIF6B.mjs} +1 -1
  17. package/dist/backend/{chunk-RVNL4DSW.mjs → chunk-SFSDLM6X.mjs} +1 -1
  18. package/dist/backend/core/handlers/coreHandler.js +14 -26
  19. package/dist/backend/core/handlers/coreHandler.mjs +3 -3
  20. package/dist/backend/core/handlers/executeRoute.mjs +1 -1
  21. package/dist/backend/core/handlers/handleRouteByName.js +14 -26
  22. package/dist/backend/core/handlers/handleRouteByName.mjs +3 -3
  23. package/dist/backend/core/handlers/index.js +14 -26
  24. package/dist/backend/core/handlers/index.mjs +4 -4
  25. package/dist/backend/core/index.js +14 -26
  26. package/dist/backend/core/index.mjs +6 -6
  27. package/dist/backend/core/routes/index.mjs +1 -1
  28. package/dist/backend/core/routes/routeConfigs.mjs +1 -1
  29. package/dist/backend/core/utils/index.mjs +3 -3
  30. package/dist/backend/index.js +14 -26
  31. package/dist/backend/index.mjs +6 -6
  32. package/dist/better-auth/{chunk-LRULDM7S.mjs → chunk-7ACCRQYY.mjs} +1 -1
  33. package/dist/better-auth/{chunk-JV57X7GG.mjs → chunk-XNZJ7YIW.mjs} +14 -26
  34. package/dist/better-auth/client.d.mts +7 -2
  35. package/dist/better-auth/client.d.ts +7 -2
  36. package/dist/better-auth/createAutumnEndpoint-D9Plymvy.d.mts +309 -0
  37. package/dist/better-auth/createAutumnEndpoint-D9Plymvy.d.ts +309 -0
  38. package/dist/better-auth/index.d.mts +7 -2
  39. package/dist/better-auth/index.d.ts +7 -2
  40. package/dist/better-auth/index.js +18 -30
  41. package/dist/better-auth/index.mjs +2 -2
  42. package/dist/better-auth/utils/createAutumnEndpoint.d.mts +7 -2
  43. package/dist/better-auth/utils/createAutumnEndpoint.d.ts +7 -2
  44. package/dist/better-auth/utils/createAutumnEndpoint.js +2 -2
  45. package/dist/better-auth/utils/createAutumnEndpoint.mjs +1 -1
  46. package/dist/better-auth/utils/handleBetterAuthRoute.d.mts +7 -2
  47. package/dist/better-auth/utils/handleBetterAuthRoute.d.ts +7 -2
  48. package/dist/better-auth/utils/handleBetterAuthRoute.js +14 -26
  49. package/dist/better-auth/utils/handleBetterAuthRoute.mjs +1 -1
  50. package/dist/better-auth/utils/index.d.mts +7 -2
  51. package/dist/better-auth/utils/index.d.ts +7 -2
  52. package/dist/better-auth/utils/index.js +18 -30
  53. package/dist/better-auth/utils/index.mjs +2 -2
  54. package/dist/sdk/index.d.mts +3 -17
  55. package/dist/sdk/index.d.ts +3 -17
  56. package/dist/sdk/index.js +12 -25
  57. package/dist/sdk/index.mjs +12 -25
  58. package/package.json +142 -142
  59. package/dist/better-auth/createAutumnEndpoint-p1QlSPE4.d.mts +0 -42
  60. package/dist/better-auth/createAutumnEndpoint-p1QlSPE4.d.ts +0 -42
@@ -50,7 +50,7 @@ function pathToFunc(pathPattern, options) {
50
50
  );
51
51
  }
52
52
  return options?.charEncoding === "percent" ? encodeURIComponent(`${value}`) : `${value}`;
53
- }).replace(/^\/+/, "");
53
+ });
54
54
  };
55
55
  }
56
56
 
@@ -78,8 +78,8 @@ var SDK_METADATA = {
78
78
  language: "typescript",
79
79
  openapiDocVersion: "2.2.0",
80
80
  sdkVersion: "0.10.17",
81
- genVersion: "2.879.6",
82
- userAgent: "speakeasy-sdk/typescript 0.10.17 2.879.6 2.2.0 @useautumn/sdk"
81
+ genVersion: "2.824.1",
82
+ userAgent: "speakeasy-sdk/typescript 0.10.17 2.824.1 2.2.0 @useautumn/sdk"
83
83
  };
84
84
 
85
85
  // ../sdk/src/lib/http.ts
@@ -713,9 +713,8 @@ function match(...matchers) {
713
713
  raw = body;
714
714
  break;
715
715
  default:
716
- throw new Error(
717
- `Unsupported response type: ${encoding}`
718
- );
716
+ encoding;
717
+ throw new Error(`Unsupported response type: ${encoding}`);
719
718
  }
720
719
  if (matcher.enc === "fail") {
721
720
  return [{
@@ -978,7 +977,8 @@ function resolveSecurity(...options) {
978
977
  applyBearer(state, spec);
979
978
  break;
980
979
  default:
981
- throw SecurityError.unrecognizedType((spec, type));
980
+ spec;
981
+ throw SecurityError.unrecognizedType(type);
982
982
  }
983
983
  });
984
984
  return state;
@@ -1001,8 +1001,8 @@ function applyBearer(state, spec) {
1001
1001
  state.headers[spec.fieldName] = value;
1002
1002
  }
1003
1003
  }
1004
- function resolveGlobalSecurity(security, allowedFields) {
1005
- let inputs = [
1004
+ function resolveGlobalSecurity(security) {
1005
+ return resolveSecurity(
1006
1006
  [
1007
1007
  {
1008
1008
  fieldName: "Authorization",
@@ -1010,16 +1010,7 @@ function resolveGlobalSecurity(security, allowedFields) {
1010
1010
  value: security?.secretKey ?? env().AUTUMN_SECRET_KEY
1011
1011
  }
1012
1012
  ]
1013
- ];
1014
- if (allowedFields) {
1015
- inputs = allowedFields.map((i) => {
1016
- if (i < 0 || i >= inputs.length) {
1017
- throw new RangeError(`invalid allowedFields index ${i}`);
1018
- }
1019
- return inputs[i];
1020
- });
1021
- }
1022
- return resolveSecurity(...inputs);
1013
+ );
1023
1014
  }
1024
1015
  async function extractSecurity(sec) {
1025
1016
  if (sec == null) {
@@ -10404,15 +10395,12 @@ var ClientSDK = class {
10404
10395
  if (!base) {
10405
10396
  return ERR(new InvalidRequestError("No base URL provided for operation"));
10406
10397
  }
10407
- const baseURL = new URL(base);
10408
- let reqURL;
10398
+ const reqURL = new URL(base);
10399
+ const inputURL = new URL(path, reqURL);
10409
10400
  if (path) {
10410
- baseURL.pathname = baseURL.pathname.replace(/\/+$/, "") + "/";
10411
- reqURL = new URL(path, baseURL);
10412
- } else {
10413
- reqURL = baseURL;
10401
+ reqURL.pathname += reqURL.pathname.endsWith("/") ? "" : "/";
10402
+ reqURL.pathname += inputURL.pathname.replace(/^\/+/, "");
10414
10403
  }
10415
- reqURL.hash = "";
10416
10404
  let finalQuery = query || "";
10417
10405
  const secQuery = [];
10418
10406
  for (const [k, v] of Object.entries(security?.queryParams || {})) {
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  autumnHandler
3
- } from "../chunk-2SJN2D5K.mjs";
3
+ } from "../chunk-747OIE4V.mjs";
4
4
  import "../chunk-WYDGEDEU.mjs";
5
5
  import "../chunk-VXND2UDT.mjs";
6
- import "../chunk-OI6KS2W5.mjs";
7
- import "../chunk-EJFVGOSH.mjs";
8
- import "../chunk-5J2AJ3AR.mjs";
6
+ import "../chunk-IH7B2HKV.mjs";
7
+ import "../chunk-OMSCIF6B.mjs";
8
+ import "../chunk-HGGHOITQ.mjs";
9
9
  import "../chunk-55C2WWXQ.mjs";
10
10
  import "../chunk-TBQ27LIK.mjs";
11
11
  import "../chunk-J44WR3QZ.mjs";
@@ -13,8 +13,8 @@ import "../chunk-TSF4YCUO.mjs";
13
13
  import "../chunk-UAR3TMWI.mjs";
14
14
  import "../chunk-2NIBKIZV.mjs";
15
15
  import "../chunk-OTXV5FY7.mjs";
16
- import "../chunk-VZIMT7AO.mjs";
17
16
  import "../chunk-Z6QP3YEA.mjs";
17
+ import "../chunk-VZIMT7AO.mjs";
18
18
  import "../chunk-N7NFYY54.mjs";
19
19
  export {
20
20
  autumnHandler
@@ -50,7 +50,7 @@ function pathToFunc(pathPattern, options) {
50
50
  );
51
51
  }
52
52
  return options?.charEncoding === "percent" ? encodeURIComponent(`${value}`) : `${value}`;
53
- }).replace(/^\/+/, "");
53
+ });
54
54
  };
55
55
  }
56
56
 
@@ -78,8 +78,8 @@ var SDK_METADATA = {
78
78
  language: "typescript",
79
79
  openapiDocVersion: "2.2.0",
80
80
  sdkVersion: "0.10.17",
81
- genVersion: "2.879.6",
82
- userAgent: "speakeasy-sdk/typescript 0.10.17 2.879.6 2.2.0 @useautumn/sdk"
81
+ genVersion: "2.824.1",
82
+ userAgent: "speakeasy-sdk/typescript 0.10.17 2.824.1 2.2.0 @useautumn/sdk"
83
83
  };
84
84
 
85
85
  // ../sdk/src/lib/http.ts
@@ -713,9 +713,8 @@ function match(...matchers) {
713
713
  raw = body;
714
714
  break;
715
715
  default:
716
- throw new Error(
717
- `Unsupported response type: ${encoding}`
718
- );
716
+ encoding;
717
+ throw new Error(`Unsupported response type: ${encoding}`);
719
718
  }
720
719
  if (matcher.enc === "fail") {
721
720
  return [{
@@ -978,7 +977,8 @@ function resolveSecurity(...options) {
978
977
  applyBearer(state, spec);
979
978
  break;
980
979
  default:
981
- throw SecurityError.unrecognizedType((spec, type));
980
+ spec;
981
+ throw SecurityError.unrecognizedType(type);
982
982
  }
983
983
  });
984
984
  return state;
@@ -1001,8 +1001,8 @@ function applyBearer(state, spec) {
1001
1001
  state.headers[spec.fieldName] = value;
1002
1002
  }
1003
1003
  }
1004
- function resolveGlobalSecurity(security, allowedFields) {
1005
- let inputs = [
1004
+ function resolveGlobalSecurity(security) {
1005
+ return resolveSecurity(
1006
1006
  [
1007
1007
  {
1008
1008
  fieldName: "Authorization",
@@ -1010,16 +1010,7 @@ function resolveGlobalSecurity(security, allowedFields) {
1010
1010
  value: security?.secretKey ?? env().AUTUMN_SECRET_KEY
1011
1011
  }
1012
1012
  ]
1013
- ];
1014
- if (allowedFields) {
1015
- inputs = allowedFields.map((i) => {
1016
- if (i < 0 || i >= inputs.length) {
1017
- throw new RangeError(`invalid allowedFields index ${i}`);
1018
- }
1019
- return inputs[i];
1020
- });
1021
- }
1022
- return resolveSecurity(...inputs);
1013
+ );
1023
1014
  }
1024
1015
  async function extractSecurity(sec) {
1025
1016
  if (sec == null) {
@@ -10404,15 +10395,12 @@ var ClientSDK = class {
10404
10395
  if (!base) {
10405
10396
  return ERR(new InvalidRequestError("No base URL provided for operation"));
10406
10397
  }
10407
- const baseURL = new URL(base);
10408
- let reqURL;
10398
+ const reqURL = new URL(base);
10399
+ const inputURL = new URL(path, reqURL);
10409
10400
  if (path) {
10410
- baseURL.pathname = baseURL.pathname.replace(/\/+$/, "") + "/";
10411
- reqURL = new URL(path, baseURL);
10412
- } else {
10413
- reqURL = baseURL;
10401
+ reqURL.pathname += reqURL.pathname.endsWith("/") ? "" : "/";
10402
+ reqURL.pathname += inputURL.pathname.replace(/^\/+/, "");
10414
10403
  }
10415
- reqURL.hash = "";
10416
10404
  let finalQuery = query || "";
10417
10405
  const secQuery = [];
10418
10406
  for (const [k, v] of Object.entries(security?.queryParams || {})) {
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  autumnHandler
3
- } from "../chunk-RVNL4DSW.mjs";
3
+ } from "../chunk-SFSDLM6X.mjs";
4
4
  import "../chunk-WYDGEDEU.mjs";
5
5
  import "../chunk-VXND2UDT.mjs";
6
- import "../chunk-OI6KS2W5.mjs";
7
- import "../chunk-EJFVGOSH.mjs";
8
- import "../chunk-5J2AJ3AR.mjs";
6
+ import "../chunk-IH7B2HKV.mjs";
7
+ import "../chunk-OMSCIF6B.mjs";
8
+ import "../chunk-HGGHOITQ.mjs";
9
9
  import "../chunk-55C2WWXQ.mjs";
10
10
  import "../chunk-TBQ27LIK.mjs";
11
11
  import "../chunk-J44WR3QZ.mjs";
@@ -13,8 +13,8 @@ import "../chunk-TSF4YCUO.mjs";
13
13
  import "../chunk-UAR3TMWI.mjs";
14
14
  import "../chunk-2NIBKIZV.mjs";
15
15
  import "../chunk-OTXV5FY7.mjs";
16
- import "../chunk-VZIMT7AO.mjs";
17
16
  import "../chunk-Z6QP3YEA.mjs";
17
+ import "../chunk-VZIMT7AO.mjs";
18
18
  import "../chunk-N7NFYY54.mjs";
19
19
  export {
20
20
  autumnHandler
@@ -50,7 +50,7 @@ function pathToFunc(pathPattern, options) {
50
50
  );
51
51
  }
52
52
  return options?.charEncoding === "percent" ? encodeURIComponent(`${value}`) : `${value}`;
53
- }).replace(/^\/+/, "");
53
+ });
54
54
  };
55
55
  }
56
56
 
@@ -78,8 +78,8 @@ var SDK_METADATA = {
78
78
  language: "typescript",
79
79
  openapiDocVersion: "2.2.0",
80
80
  sdkVersion: "0.10.17",
81
- genVersion: "2.879.6",
82
- userAgent: "speakeasy-sdk/typescript 0.10.17 2.879.6 2.2.0 @useautumn/sdk"
81
+ genVersion: "2.824.1",
82
+ userAgent: "speakeasy-sdk/typescript 0.10.17 2.824.1 2.2.0 @useautumn/sdk"
83
83
  };
84
84
 
85
85
  // ../sdk/src/lib/http.ts
@@ -713,9 +713,8 @@ function match(...matchers) {
713
713
  raw = body;
714
714
  break;
715
715
  default:
716
- throw new Error(
717
- `Unsupported response type: ${encoding}`
718
- );
716
+ encoding;
717
+ throw new Error(`Unsupported response type: ${encoding}`);
719
718
  }
720
719
  if (matcher.enc === "fail") {
721
720
  return [{
@@ -978,7 +977,8 @@ function resolveSecurity(...options) {
978
977
  applyBearer(state, spec);
979
978
  break;
980
979
  default:
981
- throw SecurityError.unrecognizedType((spec, type));
980
+ spec;
981
+ throw SecurityError.unrecognizedType(type);
982
982
  }
983
983
  });
984
984
  return state;
@@ -1001,8 +1001,8 @@ function applyBearer(state, spec) {
1001
1001
  state.headers[spec.fieldName] = value;
1002
1002
  }
1003
1003
  }
1004
- function resolveGlobalSecurity(security, allowedFields) {
1005
- let inputs = [
1004
+ function resolveGlobalSecurity(security) {
1005
+ return resolveSecurity(
1006
1006
  [
1007
1007
  {
1008
1008
  fieldName: "Authorization",
@@ -1010,16 +1010,7 @@ function resolveGlobalSecurity(security, allowedFields) {
1010
1010
  value: security?.secretKey ?? env().AUTUMN_SECRET_KEY
1011
1011
  }
1012
1012
  ]
1013
- ];
1014
- if (allowedFields) {
1015
- inputs = allowedFields.map((i) => {
1016
- if (i < 0 || i >= inputs.length) {
1017
- throw new RangeError(`invalid allowedFields index ${i}`);
1018
- }
1019
- return inputs[i];
1020
- });
1021
- }
1022
- return resolveSecurity(...inputs);
1013
+ );
1023
1014
  }
1024
1015
  async function extractSecurity(sec) {
1025
1016
  if (sec == null) {
@@ -10404,15 +10395,12 @@ var ClientSDK = class {
10404
10395
  if (!base) {
10405
10396
  return ERR(new InvalidRequestError("No base URL provided for operation"));
10406
10397
  }
10407
- const baseURL = new URL(base);
10408
- let reqURL;
10398
+ const reqURL = new URL(base);
10399
+ const inputURL = new URL(path, reqURL);
10409
10400
  if (path) {
10410
- baseURL.pathname = baseURL.pathname.replace(/\/+$/, "") + "/";
10411
- reqURL = new URL(path, baseURL);
10412
- } else {
10413
- reqURL = baseURL;
10401
+ reqURL.pathname += reqURL.pathname.endsWith("/") ? "" : "/";
10402
+ reqURL.pathname += inputURL.pathname.replace(/^\/+/, "");
10414
10403
  }
10415
- reqURL.hash = "";
10416
10404
  let finalQuery = query || "";
10417
10405
  const secQuery = [];
10418
10406
  for (const [k, v] of Object.entries(security?.queryParams || {})) {
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  autumnHandler
3
- } from "../chunk-3KJVXSBT.mjs";
3
+ } from "../chunk-GEUMIITE.mjs";
4
4
  import "../chunk-WYDGEDEU.mjs";
5
5
  import "../chunk-VXND2UDT.mjs";
6
- import "../chunk-OI6KS2W5.mjs";
7
- import "../chunk-EJFVGOSH.mjs";
8
- import "../chunk-5J2AJ3AR.mjs";
6
+ import "../chunk-IH7B2HKV.mjs";
7
+ import "../chunk-OMSCIF6B.mjs";
8
+ import "../chunk-HGGHOITQ.mjs";
9
9
  import "../chunk-55C2WWXQ.mjs";
10
10
  import "../chunk-TBQ27LIK.mjs";
11
11
  import "../chunk-J44WR3QZ.mjs";
@@ -13,8 +13,8 @@ import "../chunk-TSF4YCUO.mjs";
13
13
  import "../chunk-UAR3TMWI.mjs";
14
14
  import "../chunk-2NIBKIZV.mjs";
15
15
  import "../chunk-OTXV5FY7.mjs";
16
- import "../chunk-VZIMT7AO.mjs";
17
16
  import "../chunk-Z6QP3YEA.mjs";
17
+ import "../chunk-VZIMT7AO.mjs";
18
18
  import "../chunk-N7NFYY54.mjs";
19
19
  export {
20
20
  autumnHandler
@@ -53,7 +53,7 @@ function pathToFunc(pathPattern, options) {
53
53
  );
54
54
  }
55
55
  return options?.charEncoding === "percent" ? encodeURIComponent(`${value}`) : `${value}`;
56
- }).replace(/^\/+/, "");
56
+ });
57
57
  };
58
58
  }
59
59
 
@@ -81,8 +81,8 @@ var SDK_METADATA = {
81
81
  language: "typescript",
82
82
  openapiDocVersion: "2.2.0",
83
83
  sdkVersion: "0.10.17",
84
- genVersion: "2.879.6",
85
- userAgent: "speakeasy-sdk/typescript 0.10.17 2.879.6 2.2.0 @useautumn/sdk"
84
+ genVersion: "2.824.1",
85
+ userAgent: "speakeasy-sdk/typescript 0.10.17 2.824.1 2.2.0 @useautumn/sdk"
86
86
  };
87
87
 
88
88
  // ../sdk/src/lib/http.ts
@@ -716,9 +716,8 @@ function match(...matchers) {
716
716
  raw = body;
717
717
  break;
718
718
  default:
719
- throw new Error(
720
- `Unsupported response type: ${encoding}`
721
- );
719
+ encoding;
720
+ throw new Error(`Unsupported response type: ${encoding}`);
722
721
  }
723
722
  if (matcher.enc === "fail") {
724
723
  return [{
@@ -981,7 +980,8 @@ function resolveSecurity(...options) {
981
980
  applyBearer(state, spec);
982
981
  break;
983
982
  default:
984
- throw SecurityError.unrecognizedType((spec, type));
983
+ spec;
984
+ throw SecurityError.unrecognizedType(type);
985
985
  }
986
986
  });
987
987
  return state;
@@ -1004,8 +1004,8 @@ function applyBearer(state, spec) {
1004
1004
  state.headers[spec.fieldName] = value;
1005
1005
  }
1006
1006
  }
1007
- function resolveGlobalSecurity(security, allowedFields) {
1008
- let inputs = [
1007
+ function resolveGlobalSecurity(security) {
1008
+ return resolveSecurity(
1009
1009
  [
1010
1010
  {
1011
1011
  fieldName: "Authorization",
@@ -1013,16 +1013,7 @@ function resolveGlobalSecurity(security, allowedFields) {
1013
1013
  value: security?.secretKey ?? env().AUTUMN_SECRET_KEY
1014
1014
  }
1015
1015
  ]
1016
- ];
1017
- if (allowedFields) {
1018
- inputs = allowedFields.map((i) => {
1019
- if (i < 0 || i >= inputs.length) {
1020
- throw new RangeError(`invalid allowedFields index ${i}`);
1021
- }
1022
- return inputs[i];
1023
- });
1024
- }
1025
- return resolveSecurity(...inputs);
1016
+ );
1026
1017
  }
1027
1018
  async function extractSecurity(sec) {
1028
1019
  if (sec == null) {
@@ -10407,15 +10398,12 @@ var ClientSDK = class {
10407
10398
  if (!base) {
10408
10399
  return ERR(new InvalidRequestError("No base URL provided for operation"));
10409
10400
  }
10410
- const baseURL = new URL(base);
10411
- let reqURL;
10401
+ const reqURL = new URL(base);
10402
+ const inputURL = new URL(path, reqURL);
10412
10403
  if (path) {
10413
- baseURL.pathname = baseURL.pathname.replace(/\/+$/, "") + "/";
10414
- reqURL = new URL(path, baseURL);
10415
- } else {
10416
- reqURL = baseURL;
10404
+ reqURL.pathname += reqURL.pathname.endsWith("/") ? "" : "/";
10405
+ reqURL.pathname += inputURL.pathname.replace(/^\/+/, "");
10417
10406
  }
10418
- reqURL.hash = "";
10419
10407
  let finalQuery = query || "";
10420
10408
  const secQuery = [];
10421
10409
  for (const [k, v] of Object.entries(security?.queryParams || {})) {
@@ -1,20 +1,20 @@
1
1
  import {
2
2
  autumnHandler
3
- } from "../chunk-2SJN2D5K.mjs";
3
+ } from "../chunk-747OIE4V.mjs";
4
4
  import {
5
5
  autumnHandler as autumnHandler2
6
- } from "../chunk-RVNL4DSW.mjs";
6
+ } from "../chunk-SFSDLM6X.mjs";
7
7
  import {
8
8
  autumnHandler as autumnHandler3
9
- } from "../chunk-3KJVXSBT.mjs";
9
+ } from "../chunk-GEUMIITE.mjs";
10
10
  import {
11
11
  autumnHandler as autumnHandler4
12
- } from "../chunk-EHOQ52YN.mjs";
12
+ } from "../chunk-67LO3DQD.mjs";
13
13
  import "../chunk-WYDGEDEU.mjs";
14
14
  import "../chunk-VXND2UDT.mjs";
15
- import "../chunk-OI6KS2W5.mjs";
16
- import "../chunk-EJFVGOSH.mjs";
17
- import "../chunk-5J2AJ3AR.mjs";
15
+ import "../chunk-IH7B2HKV.mjs";
16
+ import "../chunk-OMSCIF6B.mjs";
17
+ import "../chunk-HGGHOITQ.mjs";
18
18
  import "../chunk-55C2WWXQ.mjs";
19
19
  import "../chunk-TBQ27LIK.mjs";
20
20
  import "../chunk-J44WR3QZ.mjs";
@@ -22,8 +22,8 @@ import "../chunk-TSF4YCUO.mjs";
22
22
  import "../chunk-UAR3TMWI.mjs";
23
23
  import "../chunk-2NIBKIZV.mjs";
24
24
  import "../chunk-OTXV5FY7.mjs";
25
- import "../chunk-VZIMT7AO.mjs";
26
25
  import "../chunk-Z6QP3YEA.mjs";
26
+ import "../chunk-VZIMT7AO.mjs";
27
27
  import "../chunk-N7NFYY54.mjs";
28
28
  export {
29
29
  autumnHandler as expressAutumnHandler,
@@ -51,7 +51,7 @@ function pathToFunc(pathPattern, options) {
51
51
  );
52
52
  }
53
53
  return options?.charEncoding === "percent" ? encodeURIComponent(`${value}`) : `${value}`;
54
- }).replace(/^\/+/, "");
54
+ });
55
55
  };
56
56
  }
57
57
 
@@ -79,8 +79,8 @@ var SDK_METADATA = {
79
79
  language: "typescript",
80
80
  openapiDocVersion: "2.2.0",
81
81
  sdkVersion: "0.10.17",
82
- genVersion: "2.879.6",
83
- userAgent: "speakeasy-sdk/typescript 0.10.17 2.879.6 2.2.0 @useautumn/sdk"
82
+ genVersion: "2.824.1",
83
+ userAgent: "speakeasy-sdk/typescript 0.10.17 2.824.1 2.2.0 @useautumn/sdk"
84
84
  };
85
85
 
86
86
  // ../sdk/src/lib/http.ts
@@ -714,9 +714,8 @@ function match(...matchers) {
714
714
  raw = body;
715
715
  break;
716
716
  default:
717
- throw new Error(
718
- `Unsupported response type: ${encoding}`
719
- );
717
+ encoding;
718
+ throw new Error(`Unsupported response type: ${encoding}`);
720
719
  }
721
720
  if (matcher.enc === "fail") {
722
721
  return [{
@@ -979,7 +978,8 @@ function resolveSecurity(...options) {
979
978
  applyBearer(state, spec);
980
979
  break;
981
980
  default:
982
- throw SecurityError.unrecognizedType((spec, type));
981
+ spec;
982
+ throw SecurityError.unrecognizedType(type);
983
983
  }
984
984
  });
985
985
  return state;
@@ -1002,8 +1002,8 @@ function applyBearer(state, spec) {
1002
1002
  state.headers[spec.fieldName] = value;
1003
1003
  }
1004
1004
  }
1005
- function resolveGlobalSecurity(security, allowedFields) {
1006
- let inputs = [
1005
+ function resolveGlobalSecurity(security) {
1006
+ return resolveSecurity(
1007
1007
  [
1008
1008
  {
1009
1009
  fieldName: "Authorization",
@@ -1011,16 +1011,7 @@ function resolveGlobalSecurity(security, allowedFields) {
1011
1011
  value: security?.secretKey ?? env().AUTUMN_SECRET_KEY
1012
1012
  }
1013
1013
  ]
1014
- ];
1015
- if (allowedFields) {
1016
- inputs = allowedFields.map((i) => {
1017
- if (i < 0 || i >= inputs.length) {
1018
- throw new RangeError(`invalid allowedFields index ${i}`);
1019
- }
1020
- return inputs[i];
1021
- });
1022
- }
1023
- return resolveSecurity(...inputs);
1014
+ );
1024
1015
  }
1025
1016
  async function extractSecurity(sec) {
1026
1017
  if (sec == null) {
@@ -10405,15 +10396,12 @@ var ClientSDK = class {
10405
10396
  if (!base) {
10406
10397
  return ERR(new InvalidRequestError("No base URL provided for operation"));
10407
10398
  }
10408
- const baseURL = new URL(base);
10409
- let reqURL;
10399
+ const reqURL = new URL(base);
10400
+ const inputURL = new URL(path, reqURL);
10410
10401
  if (path) {
10411
- baseURL.pathname = baseURL.pathname.replace(/\/+$/, "") + "/";
10412
- reqURL = new URL(path, baseURL);
10413
- } else {
10414
- reqURL = baseURL;
10402
+ reqURL.pathname += reqURL.pathname.endsWith("/") ? "" : "/";
10403
+ reqURL.pathname += inputURL.pathname.replace(/^\/+/, "");
10415
10404
  }
10416
- reqURL.hash = "";
10417
10405
  let finalQuery = query || "";
10418
10406
  const secQuery = [];
10419
10407
  for (const [k, v] of Object.entries(security?.queryParams || {})) {
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  autumnHandler
3
- } from "../chunk-EHOQ52YN.mjs";
3
+ } from "../chunk-67LO3DQD.mjs";
4
4
  import "../chunk-WYDGEDEU.mjs";
5
5
  import "../chunk-VXND2UDT.mjs";
6
- import "../chunk-OI6KS2W5.mjs";
7
- import "../chunk-EJFVGOSH.mjs";
8
- import "../chunk-5J2AJ3AR.mjs";
6
+ import "../chunk-IH7B2HKV.mjs";
7
+ import "../chunk-OMSCIF6B.mjs";
8
+ import "../chunk-HGGHOITQ.mjs";
9
9
  import "../chunk-55C2WWXQ.mjs";
10
10
  import "../chunk-TBQ27LIK.mjs";
11
11
  import "../chunk-J44WR3QZ.mjs";
@@ -13,8 +13,8 @@ import "../chunk-TSF4YCUO.mjs";
13
13
  import "../chunk-UAR3TMWI.mjs";
14
14
  import "../chunk-2NIBKIZV.mjs";
15
15
  import "../chunk-OTXV5FY7.mjs";
16
- import "../chunk-VZIMT7AO.mjs";
17
16
  import "../chunk-Z6QP3YEA.mjs";
17
+ import "../chunk-VZIMT7AO.mjs";
18
18
  import "../chunk-N7NFYY54.mjs";
19
19
  export {
20
20
  autumnHandler
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  createCoreHandler
3
- } from "./chunk-EJFVGOSH.mjs";
3
+ } from "./chunk-OMSCIF6B.mjs";
4
4
 
5
5
  // src/backend/adapters/next.ts
6
6
  import { NextResponse } from "next/server";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  createCoreHandler
3
- } from "./chunk-EJFVGOSH.mjs";
3
+ } from "./chunk-OMSCIF6B.mjs";
4
4
 
5
5
  // src/backend/adapters/express.ts
6
6
  function autumnHandler(options) {
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  createCoreHandler
3
- } from "./chunk-EJFVGOSH.mjs";
3
+ } from "./chunk-OMSCIF6B.mjs";
4
4
 
5
5
  // src/backend/adapters/hono.ts
6
6
  function autumnHandler(options) {