swoop-common 2.1.59 → 2.1.61

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "swoop-common",
3
- "version": "2.1.59",
3
+ "version": "2.1.61",
4
4
  "main": "dist/api/index.js",
5
5
  "types": "dist/api/index.d.ts",
6
6
  "exports": {
@@ -25,11 +25,10 @@
25
25
  "build-core-sdk": "npx openapi-typescript-codegen --input ./openapi/generated/core_bundled.yaml --output ./src/api/generated/core --client fetch",
26
26
  "build-itinerary-sdk": "npx openapi-typescript-codegen --input ./openapi/generated/itinerary_bundled.yaml --output ./src/api/generated/itinerary --client fetch",
27
27
  "build-swoop-sdk": "npx openapi-typescript-codegen --input ./openapi/swoop_service.yaml --output ./src/api/generated/swoop --client fetch --postfixModels Swoop --request ./src/api/templates/request.ts",
28
- "prebuild": "npm run build-imports && npm run fetch-specs && npm run bundle && npm run build-sdk",
28
+ "prebuild": "npm run build-imports && npm run bundle && npm run build-sdk",
29
29
  "build-sdk-exports": "tsx ./src/api/gen.ts",
30
30
  "bundle": "tsx ./src/api/bundler.ts",
31
- "build-sdk": "npm run build-core-sdk && npm run build-itinerary-sdk && npm run build-swoop-sdk && npm run build-sdk-exports",
32
- "fetch-specs": "tsx ./src/api/fetch.ts"
31
+ "build-sdk": "npm run build-core-sdk && npm run build-itinerary-sdk && npm run build-swoop-sdk && npm run build-sdk-exports"
33
32
  },
34
33
  "author": "",
35
34
  "license": "ISC",
@@ -1 +0,0 @@
1
- export {};
package/dist/api/fetch.js DELETED
@@ -1,20 +0,0 @@
1
- var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
2
- function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
3
- return new (P || (P = Promise))(function (resolve, reject) {
4
- function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
5
- function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
6
- function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
7
- step((generator = generator.apply(thisArg, _arguments || [])).next());
8
- });
9
- };
10
- import fs from "fs";
11
- const getSpec = (file) => __awaiter(void 0, void 0, void 0, function* () {
12
- const gotted = yield fetch("https://openapi-specs.vercel.app/" + file);
13
- return gotted.text();
14
- });
15
- const saveSpec = (file, specs) => {
16
- fs.writeFileSync("./openapi/" + file, specs);
17
- };
18
- getSpec("models.yaml").then(spec => saveSpec("models.yaml", spec));
19
- getSpec("core_data_service.yaml").then(spec => saveSpec("core_service.yaml", spec));
20
- getSpec("itinerary_service.yaml").then(spec => saveSpec("itinerary_service.yaml", spec));