mirror of
https://github.com/grafana/grafana.git
synced 2024-11-22 08:56:43 -06:00
1635a3cd67
* CloudMigrations: create snapshots of Library Elements * CloudMigrations: render library element resource in resources table * CloudMigrations: create newtype with necessary fields for library element creation
43 lines
1.2 KiB
TypeScript
43 lines
1.2 KiB
TypeScript
// Generates Redux Toolkit API slices for certain APIs from the OpenAPI spec
|
|
import type { ConfigFile } from '@rtk-query/codegen-openapi';
|
|
|
|
const config: ConfigFile = {
|
|
schemaFile: '../public/openapi3.json',
|
|
apiFile: '', // leave this empty, and instead populate the outputFiles object below
|
|
hooks: true,
|
|
exportName: 'generatedAPI',
|
|
|
|
outputFiles: {
|
|
'../public/app/features/migrate-to-cloud/api/endpoints.gen.ts': {
|
|
apiFile: '../public/app/features/migrate-to-cloud/api/baseAPI.ts',
|
|
apiImport: 'baseAPI',
|
|
filterEndpoints: [
|
|
'getSessionList',
|
|
'getSession',
|
|
'deleteSession',
|
|
'createSession',
|
|
|
|
'getShapshotList',
|
|
'getSnapshot',
|
|
'uploadSnapshot',
|
|
'createSnapshot',
|
|
'cancelSnapshot',
|
|
|
|
'createCloudMigrationToken',
|
|
'deleteCloudMigrationToken',
|
|
'getCloudMigrationToken',
|
|
|
|
'getDashboardByUid',
|
|
'getLibraryElementByUid',
|
|
],
|
|
},
|
|
'../public/app/features/preferences/api/user/endpoints.gen.ts': {
|
|
apiFile: '../public/app/features/preferences/api/user/baseAPI.ts',
|
|
apiImport: 'baseAPI',
|
|
filterEndpoints: ['getUserPreferences', 'updateUserPreferences', 'patchUserPreferences'],
|
|
},
|
|
},
|
|
};
|
|
|
|
export default config;
|