fern-api 0.15.3 → 0.15.4

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 (2) hide show
  1. package/bundle.cjs +320 -96
  2. package/package.json +1 -1
package/bundle.cjs CHANGED
@@ -108192,7 +108192,7 @@ var require_third_party = __commonJS({
108192
108192
  }
108193
108193
  }
108194
108194
  });
108195
- var require_lib21 = __commonJS2({
108195
+ var require_lib22 = __commonJS2({
108196
108196
  "node_modules/@babel/helper-validator-identifier/lib/index.js"(exports22) {
108197
108197
  "use strict";
108198
108198
  Object.defineProperty(exports22, "__esModule", {
@@ -109805,7 +109805,7 @@ var require_third_party = __commonJS({
109805
109805
  module22.exports.default = module22.exports;
109806
109806
  }
109807
109807
  });
109808
- var require_lib22 = __commonJS2({
109808
+ var require_lib23 = __commonJS2({
109809
109809
  "node_modules/@babel/highlight/lib/index.js"(exports22) {
109810
109810
  "use strict";
109811
109811
  Object.defineProperty(exports22, "__esModule", {
@@ -109815,7 +109815,7 @@ var require_third_party = __commonJS({
109815
109815
  exports22.getChalk = getChalk2;
109816
109816
  exports22.shouldHighlight = shouldHighlight2;
109817
109817
  var _jsTokens2 = require_js_tokens();
109818
- var _helperValidatorIdentifier2 = require_lib21();
109818
+ var _helperValidatorIdentifier2 = require_lib22();
109819
109819
  var _chalk2 = require_chalk();
109820
109820
  var sometimesKeywords2 = /* @__PURE__ */ new Set(["as", "async", "from", "get", "of", "set"]);
109821
109821
  function getDefs2(chalk4) {
@@ -109910,7 +109910,7 @@ var require_third_party = __commonJS({
109910
109910
  });
109911
109911
  exports22.codeFrameColumns = codeFrameColumns2;
109912
109912
  exports22.default = _default3;
109913
- var _highlight2 = require_lib22();
109913
+ var _highlight2 = require_lib23();
109914
109914
  var deprecationWarningShown2 = false;
109915
109915
  function getDefs2(chalk4) {
109916
109916
  return {
@@ -294653,7 +294653,7 @@ var require_prettier = __commonJS({
294653
294653
  }, value));
294654
294654
  }
294655
294655
  });
294656
- var require_lib21 = __commonJS22({
294656
+ var require_lib22 = __commonJS22({
294657
294657
  "node_modules/outdent/lib/index.js"(exports22, module22) {
294658
294658
  "use strict";
294659
294659
  Object.defineProperty(exports22, "__esModule", {
@@ -294802,7 +294802,7 @@ var require_prettier = __commonJS({
294802
294802
  "use strict";
294803
294803
  var {
294804
294804
  outdent
294805
- } = require_lib21();
294805
+ } = require_lib22();
294806
294806
  var CATEGORY_CONFIG = "Config";
294807
294807
  var CATEGORY_EDITOR = "Editor";
294808
294808
  var CATEGORY_FORMAT = "Format";
@@ -298572,7 +298572,7 @@ var require_prettier = __commonJS({
298572
298572
  exports22.Normalizer = Normalizer;
298573
298573
  }
298574
298574
  });
298575
- var require_lib22 = __commonJS22({
298575
+ var require_lib23 = __commonJS22({
298576
298576
  "node_modules/vnopts/lib/index.js"(exports22) {
298577
298577
  "use strict";
298578
298578
  Object.defineProperty(exports22, "__esModule", {
@@ -298589,7 +298589,7 @@ var require_prettier = __commonJS({
298589
298589
  var require_options_normalizer = __commonJS22({
298590
298590
  "src/main/options-normalizer.js"(exports22, module22) {
298591
298591
  "use strict";
298592
- var vnopts = require_lib22();
298592
+ var vnopts = require_lib23();
298593
298593
  var getLast = require_get_last();
298594
298594
  var cliDescriptor = {
298595
298595
  key: (key2) => key2.length === 1 ? `-${key2}` : `--${key2}`,
@@ -695906,6 +695906,287 @@ var require_markdown_extensions2 = __commonJS({
695906
695906
  }
695907
695907
  });
695908
695908
 
695909
+ // pnp:/home/circleci/project/.yarn/cache/vary-npm-1.1.2-b49f70ae63-ae0123222c.zip/node_modules/vary/index.js
695910
+ var require_vary = __commonJS({
695911
+ "pnp:/home/circleci/project/.yarn/cache/vary-npm-1.1.2-b49f70ae63-ae0123222c.zip/node_modules/vary/index.js"(exports2, module2) {
695912
+ "use strict";
695913
+ module2.exports = vary;
695914
+ module2.exports.append = append;
695915
+ var FIELD_NAME_REGEXP = /^[!#$%&'*+\-.^_`|~0-9A-Za-z]+$/;
695916
+ function append(header, field) {
695917
+ if (typeof header !== "string") {
695918
+ throw new TypeError("header argument is required");
695919
+ }
695920
+ if (!field) {
695921
+ throw new TypeError("field argument is required");
695922
+ }
695923
+ var fields = !Array.isArray(field) ? parse6(String(field)) : field;
695924
+ for (var j2 = 0; j2 < fields.length; j2++) {
695925
+ if (!FIELD_NAME_REGEXP.test(fields[j2])) {
695926
+ throw new TypeError("field argument contains an invalid header name");
695927
+ }
695928
+ }
695929
+ if (header === "*") {
695930
+ return header;
695931
+ }
695932
+ var val = header;
695933
+ var vals = parse6(header.toLowerCase());
695934
+ if (fields.indexOf("*") !== -1 || vals.indexOf("*") !== -1) {
695935
+ return "*";
695936
+ }
695937
+ for (var i2 = 0; i2 < fields.length; i2++) {
695938
+ var fld = fields[i2].toLowerCase();
695939
+ if (vals.indexOf(fld) === -1) {
695940
+ vals.push(fld);
695941
+ val = val ? val + ", " + fields[i2] : fields[i2];
695942
+ }
695943
+ }
695944
+ return val;
695945
+ }
695946
+ function parse6(header) {
695947
+ var end = 0;
695948
+ var list3 = [];
695949
+ var start3 = 0;
695950
+ for (var i2 = 0, len = header.length; i2 < len; i2++) {
695951
+ switch (header.charCodeAt(i2)) {
695952
+ case 32:
695953
+ if (start3 === end) {
695954
+ start3 = end = i2 + 1;
695955
+ }
695956
+ break;
695957
+ case 44:
695958
+ list3.push(header.substring(start3, end));
695959
+ start3 = end = i2 + 1;
695960
+ break;
695961
+ default:
695962
+ end = i2 + 1;
695963
+ break;
695964
+ }
695965
+ }
695966
+ list3.push(header.substring(start3, end));
695967
+ return list3;
695968
+ }
695969
+ function vary(res, field) {
695970
+ if (!res || !res.getHeader || !res.setHeader) {
695971
+ throw new TypeError("res argument is required");
695972
+ }
695973
+ var val = res.getHeader("Vary") || "";
695974
+ var header = Array.isArray(val) ? val.join(", ") : String(val);
695975
+ if (val = append(header, field)) {
695976
+ res.setHeader("Vary", val);
695977
+ }
695978
+ }
695979
+ }
695980
+ });
695981
+
695982
+ // pnp:/home/circleci/project/.yarn/cache/cors-npm-2.8.5-c9935a2d12-ced838404c.zip/node_modules/cors/lib/index.js
695983
+ var require_lib20 = __commonJS({
695984
+ "pnp:/home/circleci/project/.yarn/cache/cors-npm-2.8.5-c9935a2d12-ced838404c.zip/node_modules/cors/lib/index.js"(exports2, module2) {
695985
+ (function() {
695986
+ "use strict";
695987
+ var assign2 = require_object_assign();
695988
+ var vary = require_vary();
695989
+ var defaults4 = {
695990
+ origin: "*",
695991
+ methods: "GET,HEAD,PUT,PATCH,POST,DELETE",
695992
+ preflightContinue: false,
695993
+ optionsSuccessStatus: 204
695994
+ };
695995
+ function isString2(s2) {
695996
+ return typeof s2 === "string" || s2 instanceof String;
695997
+ }
695998
+ function isOriginAllowed(origin, allowedOrigin) {
695999
+ if (Array.isArray(allowedOrigin)) {
696000
+ for (var i2 = 0; i2 < allowedOrigin.length; ++i2) {
696001
+ if (isOriginAllowed(origin, allowedOrigin[i2])) {
696002
+ return true;
696003
+ }
696004
+ }
696005
+ return false;
696006
+ } else if (isString2(allowedOrigin)) {
696007
+ return origin === allowedOrigin;
696008
+ } else if (allowedOrigin instanceof RegExp) {
696009
+ return allowedOrigin.test(origin);
696010
+ } else {
696011
+ return !!allowedOrigin;
696012
+ }
696013
+ }
696014
+ function configureOrigin(options, req) {
696015
+ var requestOrigin = req.headers.origin, headers = [], isAllowed;
696016
+ if (!options.origin || options.origin === "*") {
696017
+ headers.push([{
696018
+ key: "Access-Control-Allow-Origin",
696019
+ value: "*"
696020
+ }]);
696021
+ } else if (isString2(options.origin)) {
696022
+ headers.push([{
696023
+ key: "Access-Control-Allow-Origin",
696024
+ value: options.origin
696025
+ }]);
696026
+ headers.push([{
696027
+ key: "Vary",
696028
+ value: "Origin"
696029
+ }]);
696030
+ } else {
696031
+ isAllowed = isOriginAllowed(requestOrigin, options.origin);
696032
+ headers.push([{
696033
+ key: "Access-Control-Allow-Origin",
696034
+ value: isAllowed ? requestOrigin : false
696035
+ }]);
696036
+ headers.push([{
696037
+ key: "Vary",
696038
+ value: "Origin"
696039
+ }]);
696040
+ }
696041
+ return headers;
696042
+ }
696043
+ function configureMethods(options) {
696044
+ var methods = options.methods;
696045
+ if (methods.join) {
696046
+ methods = options.methods.join(",");
696047
+ }
696048
+ return {
696049
+ key: "Access-Control-Allow-Methods",
696050
+ value: methods
696051
+ };
696052
+ }
696053
+ function configureCredentials(options) {
696054
+ if (options.credentials === true) {
696055
+ return {
696056
+ key: "Access-Control-Allow-Credentials",
696057
+ value: "true"
696058
+ };
696059
+ }
696060
+ return null;
696061
+ }
696062
+ function configureAllowedHeaders(options, req) {
696063
+ var allowedHeaders = options.allowedHeaders || options.headers;
696064
+ var headers = [];
696065
+ if (!allowedHeaders) {
696066
+ allowedHeaders = req.headers["access-control-request-headers"];
696067
+ headers.push([{
696068
+ key: "Vary",
696069
+ value: "Access-Control-Request-Headers"
696070
+ }]);
696071
+ } else if (allowedHeaders.join) {
696072
+ allowedHeaders = allowedHeaders.join(",");
696073
+ }
696074
+ if (allowedHeaders && allowedHeaders.length) {
696075
+ headers.push([{
696076
+ key: "Access-Control-Allow-Headers",
696077
+ value: allowedHeaders
696078
+ }]);
696079
+ }
696080
+ return headers;
696081
+ }
696082
+ function configureExposedHeaders(options) {
696083
+ var headers = options.exposedHeaders;
696084
+ if (!headers) {
696085
+ return null;
696086
+ } else if (headers.join) {
696087
+ headers = headers.join(",");
696088
+ }
696089
+ if (headers && headers.length) {
696090
+ return {
696091
+ key: "Access-Control-Expose-Headers",
696092
+ value: headers
696093
+ };
696094
+ }
696095
+ return null;
696096
+ }
696097
+ function configureMaxAge(options) {
696098
+ var maxAge = (typeof options.maxAge === "number" || options.maxAge) && options.maxAge.toString();
696099
+ if (maxAge && maxAge.length) {
696100
+ return {
696101
+ key: "Access-Control-Max-Age",
696102
+ value: maxAge
696103
+ };
696104
+ }
696105
+ return null;
696106
+ }
696107
+ function applyHeaders(headers, res) {
696108
+ for (var i2 = 0, n2 = headers.length; i2 < n2; i2++) {
696109
+ var header = headers[i2];
696110
+ if (header) {
696111
+ if (Array.isArray(header)) {
696112
+ applyHeaders(header, res);
696113
+ } else if (header.key === "Vary" && header.value) {
696114
+ vary(res, header.value);
696115
+ } else if (header.value) {
696116
+ res.setHeader(header.key, header.value);
696117
+ }
696118
+ }
696119
+ }
696120
+ }
696121
+ function cors2(options, req, res, next) {
696122
+ var headers = [], method2 = req.method && req.method.toUpperCase && req.method.toUpperCase();
696123
+ if (method2 === "OPTIONS") {
696124
+ headers.push(configureOrigin(options, req));
696125
+ headers.push(configureCredentials(options, req));
696126
+ headers.push(configureMethods(options, req));
696127
+ headers.push(configureAllowedHeaders(options, req));
696128
+ headers.push(configureMaxAge(options, req));
696129
+ headers.push(configureExposedHeaders(options, req));
696130
+ applyHeaders(headers, res);
696131
+ if (options.preflightContinue) {
696132
+ next();
696133
+ } else {
696134
+ res.statusCode = options.optionsSuccessStatus;
696135
+ res.setHeader("Content-Length", "0");
696136
+ res.end();
696137
+ }
696138
+ } else {
696139
+ headers.push(configureOrigin(options, req));
696140
+ headers.push(configureCredentials(options, req));
696141
+ headers.push(configureExposedHeaders(options, req));
696142
+ applyHeaders(headers, res);
696143
+ next();
696144
+ }
696145
+ }
696146
+ function middlewareWrapper(o2) {
696147
+ var optionsCallback = null;
696148
+ if (typeof o2 === "function") {
696149
+ optionsCallback = o2;
696150
+ } else {
696151
+ optionsCallback = function(req, cb) {
696152
+ cb(null, o2);
696153
+ };
696154
+ }
696155
+ return function corsMiddleware(req, res, next) {
696156
+ optionsCallback(req, function(err, options) {
696157
+ if (err) {
696158
+ next(err);
696159
+ } else {
696160
+ var corsOptions = assign2({}, defaults4, options);
696161
+ var originCallback = null;
696162
+ if (corsOptions.origin && typeof corsOptions.origin === "function") {
696163
+ originCallback = corsOptions.origin;
696164
+ } else if (corsOptions.origin) {
696165
+ originCallback = function(origin, cb) {
696166
+ cb(null, corsOptions.origin);
696167
+ };
696168
+ }
696169
+ if (originCallback) {
696170
+ originCallback(req.headers.origin, function(err2, origin) {
696171
+ if (err2 || !origin) {
696172
+ next(err2);
696173
+ } else {
696174
+ corsOptions.origin = origin;
696175
+ cors2(corsOptions, req, res, next);
696176
+ }
696177
+ });
696178
+ } else {
696179
+ next();
696180
+ }
696181
+ }
696182
+ });
696183
+ };
696184
+ }
696185
+ module2.exports = middlewareWrapper;
696186
+ })();
696187
+ }
696188
+ });
696189
+
695909
696190
  // pnp:/home/circleci/project/.yarn/cache/depd-npm-2.0.0-b6c51a4b43-abbe19c768.zip/node_modules/depd/index.js
695910
696191
  var require_depd = __commonJS({
695911
696192
  "pnp:/home/circleci/project/.yarn/cache/depd-npm-2.0.0-b6c51a4b43-abbe19c768.zip/node_modules/depd/index.js"(exports2, module2) {
@@ -698946,7 +699227,7 @@ var require_parse7 = __commonJS({
698946
699227
  });
698947
699228
 
698948
699229
  // pnp:/home/circleci/project/.yarn/cache/qs-npm-6.11.0-caf1bc9dea-6e1f29dd53.zip/node_modules/qs/lib/index.js
698949
- var require_lib20 = __commonJS({
699230
+ var require_lib21 = __commonJS({
698950
699231
  "pnp:/home/circleci/project/.yarn/cache/qs-npm-6.11.0-caf1bc9dea-6e1f29dd53.zip/node_modules/qs/lib/index.js"(exports2, module2) {
698951
699232
  "use strict";
698952
699233
  var stringify5 = require_stringify4();
@@ -699080,7 +699361,7 @@ var require_urlencoded = __commonJS({
699080
699361
  }
699081
699362
  switch (name2) {
699082
699363
  case "qs":
699083
- mod = require_lib20();
699364
+ mod = require_lib21();
699084
699365
  break;
699085
699366
  case "querystring":
699086
699367
  mod = require("querystring");
@@ -700299,7 +700580,7 @@ var require_query = __commonJS({
700299
700580
  "use strict";
700300
700581
  var merge4 = require_utils_merge();
700301
700582
  var parseUrl = require_parseurl();
700302
- var qs2 = require_lib20();
700583
+ var qs2 = require_lib21();
700303
700584
  module2.exports = function query(options) {
700304
700585
  var opts = merge4({}, options);
700305
700586
  var queryparse = qs2.parse;
@@ -702218,7 +702499,7 @@ var require_utils17 = __commonJS({
702218
702499
  var mime2 = require_send().mime;
702219
702500
  var etag = require_etag();
702220
702501
  var proxyaddr = require_proxy_addr();
702221
- var qs2 = require_lib20();
702502
+ var qs2 = require_lib21();
702222
702503
  var querystring = require("querystring");
702223
702504
  exports2.etag = createETagGenerator({ weak: false });
702224
702505
  exports2.wetag = createETagGenerator({ weak: true });
@@ -703547,79 +703828,6 @@ var require_cookie = __commonJS({
703547
703828
  }
703548
703829
  });
703549
703830
 
703550
- // pnp:/home/circleci/project/.yarn/cache/vary-npm-1.1.2-b49f70ae63-ae0123222c.zip/node_modules/vary/index.js
703551
- var require_vary = __commonJS({
703552
- "pnp:/home/circleci/project/.yarn/cache/vary-npm-1.1.2-b49f70ae63-ae0123222c.zip/node_modules/vary/index.js"(exports2, module2) {
703553
- "use strict";
703554
- module2.exports = vary;
703555
- module2.exports.append = append;
703556
- var FIELD_NAME_REGEXP = /^[!#$%&'*+\-.^_`|~0-9A-Za-z]+$/;
703557
- function append(header, field) {
703558
- if (typeof header !== "string") {
703559
- throw new TypeError("header argument is required");
703560
- }
703561
- if (!field) {
703562
- throw new TypeError("field argument is required");
703563
- }
703564
- var fields = !Array.isArray(field) ? parse6(String(field)) : field;
703565
- for (var j2 = 0; j2 < fields.length; j2++) {
703566
- if (!FIELD_NAME_REGEXP.test(fields[j2])) {
703567
- throw new TypeError("field argument contains an invalid header name");
703568
- }
703569
- }
703570
- if (header === "*") {
703571
- return header;
703572
- }
703573
- var val = header;
703574
- var vals = parse6(header.toLowerCase());
703575
- if (fields.indexOf("*") !== -1 || vals.indexOf("*") !== -1) {
703576
- return "*";
703577
- }
703578
- for (var i2 = 0; i2 < fields.length; i2++) {
703579
- var fld = fields[i2].toLowerCase();
703580
- if (vals.indexOf(fld) === -1) {
703581
- vals.push(fld);
703582
- val = val ? val + ", " + fields[i2] : fields[i2];
703583
- }
703584
- }
703585
- return val;
703586
- }
703587
- function parse6(header) {
703588
- var end = 0;
703589
- var list3 = [];
703590
- var start3 = 0;
703591
- for (var i2 = 0, len = header.length; i2 < len; i2++) {
703592
- switch (header.charCodeAt(i2)) {
703593
- case 32:
703594
- if (start3 === end) {
703595
- start3 = end = i2 + 1;
703596
- }
703597
- break;
703598
- case 44:
703599
- list3.push(header.substring(start3, end));
703600
- start3 = end = i2 + 1;
703601
- break;
703602
- default:
703603
- end = i2 + 1;
703604
- break;
703605
- }
703606
- }
703607
- list3.push(header.substring(start3, end));
703608
- return list3;
703609
- }
703610
- function vary(res, field) {
703611
- if (!res || !res.getHeader || !res.setHeader) {
703612
- throw new TypeError("res argument is required");
703613
- }
703614
- var val = res.getHeader("Vary") || "";
703615
- var header = Array.isArray(val) ? val.join(", ") : String(val);
703616
- if (val = append(header, field)) {
703617
- res.setHeader("Vary", val);
703618
- }
703619
- }
703620
- }
703621
- });
703622
-
703623
703831
  // pnp:/home/circleci/project/.yarn/cache/express-npm-4.18.2-bb15ff679a-3c4b9b0768.zip/node_modules/express/lib/response.js
703624
703832
  var require_response = __commonJS({
703625
703833
  "pnp:/home/circleci/project/.yarn/cache/express-npm-4.18.2-bb15ff679a-3c4b9b0768.zip/node_modules/express/lib/response.js"(exports2, module2) {
@@ -718733,7 +718941,7 @@ var AccessTokenPosthogManager = class {
718733
718941
  properties: {
718734
718942
  ...event,
718735
718943
  ...event.properties,
718736
- version: "0.15.3",
718944
+ version: "0.15.4",
718737
718945
  usingAccessToken: true
718738
718946
  }
718739
718947
  });
@@ -718795,7 +719003,7 @@ var UserPosthogManager = class {
718795
719003
  distinctId: this.userId ?? await this.getPersistedDistinctId(),
718796
719004
  event: "CLI",
718797
719005
  properties: {
718798
- version: "0.15.3",
719006
+ version: "0.15.4",
718799
719007
  ...event,
718800
719008
  ...event.properties
718801
719009
  }
@@ -743041,10 +743249,10 @@ var CliContext = class {
743041
743249
  return "fern-api";
743042
743250
  }
743043
743251
  getPackageVersion() {
743044
- if ("0.15.3" == null) {
743252
+ if ("0.15.4" == null) {
743045
743253
  this.logger.error("CLI_VERSION is not defined");
743046
743254
  }
743047
- return "0.15.3";
743255
+ return "0.15.4";
743048
743256
  }
743049
743257
  getCliName() {
743050
743258
  if ("fern" == null) {
@@ -745333,11 +745541,20 @@ function convertSingleUnionType({ rawValueType, rawSingleUnionType, fileContaini
745333
745541
 
745334
745542
  // pnp:/home/circleci/project/packages/cli/generation/ir-generator/lib/converters/services/convertExampleEndpointCall.js
745335
745543
  function convertExampleEndpointCall2({ service, endpoint, example, typeResolver, errorResolver, exampleResolver, variableResolver, file }) {
745544
+ const convertedPathParameters = convertPathParameters({
745545
+ service,
745546
+ endpoint,
745547
+ example,
745548
+ typeResolver,
745549
+ exampleResolver,
745550
+ variableResolver,
745551
+ file
745552
+ });
745336
745553
  return {
745337
745554
  name: example.name != null ? file.casingsGenerator.generateName(example.name) : void 0,
745338
745555
  docs: example.docs,
745339
- url: buildUrl({ service, endpoint, example }),
745340
- ...convertPathParameters({ service, endpoint, example, typeResolver, exampleResolver, variableResolver, file }),
745556
+ url: buildUrl({ service, endpoint, example, pathParams: convertedPathParameters }),
745557
+ ...convertedPathParameters,
745341
745558
  ...convertHeaders({ service, endpoint, example, typeResolver, exampleResolver, file }),
745342
745559
  queryParameters: example["query-parameters"] != null ? Object.entries(example["query-parameters"]).map(([wireKey, value]) => {
745343
745560
  var _a2, _b2;
@@ -745580,11 +745797,15 @@ function convertExampleResponseBody({ endpoint, example, typeResolver, exampleRe
745580
745797
  fileContainingExample: file
745581
745798
  });
745582
745799
  }
745583
- function buildUrl({ service, endpoint, example }) {
745800
+ function buildUrl({ service, endpoint, example, pathParams }) {
745584
745801
  let url = service["base-path"] + endpoint.path;
745585
745802
  if (example["path-parameters"] != null) {
745586
- for (const [key2, value] of Object.entries(example["path-parameters"])) {
745587
- url = url.replaceAll(`{${key2}}`, `${value}`);
745803
+ for (const parameter of [
745804
+ ...pathParams.endpointPathParameters,
745805
+ ...pathParams.servicePathParameters,
745806
+ ...pathParams.rootPathParameters
745807
+ ]) {
745808
+ url = url.replaceAll(`{${parameter.name.originalName}}`, `${parameter.value.jsonExample}`);
745588
745809
  }
745589
745810
  }
745590
745811
  return url;
@@ -783351,6 +783572,7 @@ async function generateDocsWorkspace({
783351
783572
  }
783352
783573
 
783353
783574
  // pnp:/home/circleci/project/packages/cli/docs-preview/lib/runPreviewServer.js
783575
+ var import_cors = __toESM(require_lib20());
783354
783576
  var import_express = __toESM(require_express3());
783355
783577
 
783356
783578
  // pnp:/home/circleci/project/packages/cli/docs-preview/lib/previewDocs.js
@@ -783617,6 +783839,7 @@ async function convertNavigationItem3({ item, parsedDocsConfig, context, apiColl
783617
783839
  // pnp:/home/circleci/project/packages/cli/docs-preview/lib/runPreviewServer.js
783618
783840
  async function runPreviewServer({ docsWorkspace, apiWorkspaces, context }) {
783619
783841
  const app = (0, import_express.default)();
783842
+ app.use((0, import_cors.default)());
783620
783843
  const docsDefinition = await getPreviewDocsDefinition({
783621
783844
  docsWorkspace,
783622
783845
  apiWorkspaces,
@@ -783624,16 +783847,17 @@ async function runPreviewServer({ docsWorkspace, apiWorkspaces, context }) {
783624
783847
  });
783625
783848
  const response = {
783626
783849
  baseUrl: {
783627
- domain: "localhost",
783850
+ domain: "localhost:3000",
783628
783851
  basePath: ""
783629
783852
  },
783630
783853
  definition: docsDefinition,
783631
783854
  lightModeEnabled: docsDefinition.config.colorsV3.type !== "dark"
783632
783855
  };
783633
- app.post("/docs/preview/load", async (_4, res) => {
783856
+ app.post("/v2/registry/docs/load-with-url", async (_4, res) => {
783634
783857
  res.send(response);
783635
783858
  });
783636
783859
  app.listen(3e3);
783860
+ context.logger.info("Running server on https://localhost:3000");
783637
783861
  await new Promise(() => {
783638
783862
  });
783639
783863
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fern-api",
3
- "version": "0.15.3",
3
+ "version": "0.15.4",
4
4
  "repository": {
5
5
  "type": "git",
6
6
  "url": "https://github.com/fern-api/fern.git",