api: Add osbuild-composer's cloudapi

This commit is contained in:
Sanne Raymaekers 2025-02-05 14:05:59 +01:00 committed by Klara Simickova
parent 76044ddccd
commit a65d17ba4e
4 changed files with 2538 additions and 0 deletions

View file

@ -7,6 +7,7 @@ npx @rtk-query/codegen-openapi ./api/config/contentSources.ts &
npx @rtk-query/codegen-openapi ./api/config/provisioning.ts &
npx @rtk-query/codegen-openapi ./api/config/edge.ts &
npx @rtk-query/codegen-openapi ./api/config/compliance.ts &
npx @rtk-query/codegen-openapi ./api/config/composerCloudApi.ts &
# Wait for all background jobs to finish
wait

View file

@ -0,0 +1,17 @@
import type { ConfigFile } from '@rtk-query/codegen-openapi';
const config: ConfigFile = {
schemaFile: '../schema/composerCloudApi.v2.yaml',
apiFile: '../../src/store/cockpit/emptyComposerCloudApi.ts',
apiImport: 'emptyComposerCloudApi',
outputFile: '../../src/store/cockpit/composerCloudApi.ts',
exportName: 'composerCloudApi',
hooks: false,
unionUndefined: true,
filterEndpoints: [
'postCompose',
'getComposeStatus',
],
};
export default config;

View file

@ -6,3 +6,5 @@ curl https://raw.githubusercontent.com/osbuild/image-builder/main/internal/v1/ap
curl https://console.redhat.com/api/compliance/v2/openapi.json -o ./api/schema/compliance.json
curl https://console.redhat.com/api/content-sources/v1/openapi.json -o ./api/schema/contentSources.json
curl https://raw.githubusercontent.com/osbuild/osbuild-composer/main/internal/cloudapi/v2/openapi.v2.yml -o ./api/schema/composerCloudApi.v2.yaml

File diff suppressed because it is too large Load diff