39 lines
1.1 KiB
JavaScript
39 lines
1.1 KiB
JavaScript
import { defineConfig } from 'orval';
|
|
import * as dotenv from 'dotenv';
|
|
|
|
dotenv.config();
|
|
|
|
export default defineConfig({
|
|
'mp3-composer': {
|
|
input: {
|
|
target: 'http://localhost:8080/v3/api-docs',
|
|
parserOptions: {
|
|
resolve: {
|
|
http: {
|
|
headers: {
|
|
Authorization:
|
|
'Basic ' + Buffer.from(`${process.env.API_USERNAME}:${process.env.API_PASSWORD}`).toString('base64'),
|
|
},
|
|
},
|
|
},
|
|
},
|
|
},
|
|
output: {
|
|
target: './app/composeables/api/composer.ts',
|
|
schemas: './app/composeables/api/models',
|
|
mode: 'tags-split',
|
|
client: 'vue-query',
|
|
override: {
|
|
mutator: {
|
|
path: './app/composeables/api/axios-instance.ts',
|
|
},
|
|
operations: {
|
|
streamProgress: {
|
|
mutator: './app/composeables/api/event-source.ts',
|
|
}
|
|
}
|
|
},
|
|
}
|
|
},
|
|
});
|