Spaces:
Build error
Build error
Colab User commited on
Commit ·
1b9b278
1
Parent(s): 3d54be7
Initial commit: Deploy rasa-engine API server
Browse files- lib/api-spec/orval.config.ts +2 -27
lib/api-spec/orval.config.ts
CHANGED
|
@@ -2,7 +2,7 @@ import { defineConfig, InputTransformerFn } from "orval";
|
|
| 2 |
import path from "path";
|
| 3 |
|
| 4 |
const root = path.resolve(__dirname, "..", "..");
|
| 5 |
-
const apiClientReactSrc = path.resolve(root, "lib", "api-client-react", "src");
|
| 6 |
const apiZodSrc = path.resolve(root, "lib", "api-zod", "src");
|
| 7 |
|
| 8 |
// Our exports make assumptions about the title of the API being "Api" (i.e. generated output is `api.ts`).
|
|
@@ -14,32 +14,7 @@ const titleTransformer: InputTransformerFn = (config) => {
|
|
| 14 |
};
|
| 15 |
|
| 16 |
export default defineConfig({
|
| 17 |
-
"api-client-react"
|
| 18 |
-
input: {
|
| 19 |
-
target: "./openapi.yaml",
|
| 20 |
-
override: {
|
| 21 |
-
transformer: titleTransformer,
|
| 22 |
-
},
|
| 23 |
-
},
|
| 24 |
-
output: {
|
| 25 |
-
workspace: apiClientReactSrc,
|
| 26 |
-
target: "generated",
|
| 27 |
-
client: "react-query",
|
| 28 |
-
mode: "split",
|
| 29 |
-
baseUrl: "/api",
|
| 30 |
-
clean: true,
|
| 31 |
-
prettier: true,
|
| 32 |
-
override: {
|
| 33 |
-
fetch: {
|
| 34 |
-
includeHttpResponseReturnType: false,
|
| 35 |
-
},
|
| 36 |
-
mutator: {
|
| 37 |
-
path: path.resolve(apiClientReactSrc, "custom-fetch.ts"),
|
| 38 |
-
name: "customFetch",
|
| 39 |
-
},
|
| 40 |
-
},
|
| 41 |
-
},
|
| 42 |
-
},
|
| 43 |
zod: {
|
| 44 |
input: {
|
| 45 |
target: "./openapi.yaml",
|
|
|
|
| 2 |
import path from "path";
|
| 3 |
|
| 4 |
const root = path.resolve(__dirname, "..", "..");
|
| 5 |
+
// const apiClientReactSrc = path.resolve(root, "lib", "api-client-react", "src"); // This client is not used for API server deployment
|
| 6 |
const apiZodSrc = path.resolve(root, "lib", "api-zod", "src");
|
| 7 |
|
| 8 |
// Our exports make assumptions about the title of the API being "Api" (i.e. generated output is `api.ts`).
|
|
|
|
| 14 |
};
|
| 15 |
|
| 16 |
export default defineConfig({
|
| 17 |
+
// Removed "api-client-react" configuration as it's not needed for API server and causes build failures.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 18 |
zod: {
|
| 19 |
input: {
|
| 20 |
target: "./openapi.yaml",
|