generate new models

This commit is contained in:
Jacob Overgaard
2023-01-25 12:56:29 +01:00
parent 43e9514dbf
commit 2e53a4cd8a
26 changed files with 440 additions and 142 deletions

View File

@@ -7,13 +7,9 @@ export { OpenAPI } from './core/OpenAPI';
export type { OpenAPIConfig } from './core/OpenAPI';
export type { Assembly } from './models/Assembly';
export type { BackOfficeNotification } from './models/BackOfficeNotification';
export { CallingConventions } from './models/CallingConventions';
export type { ConsentLevel } from './models/ConsentLevel';
export type { ConstructorInfo } from './models/ConstructorInfo';
export type { ContentApp } from './models/ContentApp';
export type { ContentAppBadge } from './models/ContentAppBadge';
export { ContentAppBadgeType } from './models/ContentAppBadgeType';
export type { ContentResult } from './models/ContentResult';
export type { ContentTreeItem } from './models/ContentTreeItem';
export type { CreatedResult } from './models/CreatedResult';
@@ -29,13 +25,15 @@ export type { DataTypeProperty } from './models/DataTypeProperty';
export type { DataTypePropertyReference } from './models/DataTypePropertyReference';
export type { DataTypeReference } from './models/DataTypeReference';
export type { DataTypeUpdateModel } from './models/DataTypeUpdateModel';
export type { Dictionary } from './models/Dictionary';
export type { DictionaryImport } from './models/DictionaryImport';
export type { DictionaryItem } from './models/DictionaryItem';
export type { DictionaryItemCreateModel } from './models/DictionaryItemCreateModel';
export type { DictionaryItemsImport } from './models/DictionaryItemsImport';
export type { DictionaryItemTranslationModel } from './models/DictionaryItemTranslationModel';
export type { DictionaryItemUpdateModel } from './models/DictionaryItemUpdateModel';
export type { DictionaryOverview } from './models/DictionaryOverview';
export type { DictionaryTranslation } from './models/DictionaryTranslation';
export type { DictionaryTranslationOverview } from './models/DictionaryTranslationOverview';
export { Direction } from './models/Direction';
export type { DocumentBlueprintTreeItem } from './models/DocumentBlueprintTreeItem';
export type { DocumentTreeItem } from './models/DocumentTreeItem';
export type { DocumentTypeTreeItem } from './models/DocumentTypeTreeItem';
@@ -65,9 +63,13 @@ export type { Install } from './models/Install';
export type { InstallSettings } from './models/InstallSettings';
export type { IntPtr } from './models/IntPtr';
export type { IOutputFormatter } from './models/IOutputFormatter';
export type { JsonPatch } from './models/JsonPatch';
export type { Language } from './models/Language';
export { LayoutKind } from './models/LayoutKind';
export type { Logger } from './models/Logger';
export { LogLevel } from './models/LogLevel';
export type { LogMessage } from './models/LogMessage';
export type { LogMessageProperty } from './models/LogMessageProperty';
export type { LogTemplate } from './models/LogTemplate';
export type { MemberInfo } from './models/MemberInfo';
export { MemberTypes } from './models/MemberTypes';
export { MethodAttributes } from './models/MethodAttributes';
@@ -79,7 +81,6 @@ export { ModelsMode } from './models/ModelsMode';
export type { Module } from './models/Module';
export type { ModuleHandle } from './models/ModuleHandle';
export type { NotFoundResult } from './models/NotFoundResult';
export { NotificationStyle } from './models/NotificationStyle';
export type { OkResult } from './models/OkResult';
export { Operator } from './models/Operator';
export type { OutOfDateStatus } from './models/OutOfDateStatus';
@@ -97,10 +98,14 @@ export type { PagedHealthCheckGroup } from './models/PagedHealthCheckGroup';
export type { PagedHelpPage } from './models/PagedHelpPage';
export type { PagedIndex } from './models/PagedIndex';
export type { PagedLanguage } from './models/PagedLanguage';
export type { PagedLogger } from './models/PagedLogger';
export type { PagedLogMessage } from './models/PagedLogMessage';
export type { PagedLogTemplate } from './models/PagedLogTemplate';
export type { PagedRecycleBinItem } from './models/PagedRecycleBinItem';
export type { PagedRedirectUrl } from './models/PagedRedirectUrl';
export type { PagedRelation } from './models/PagedRelation';
export type { PagedRelationItem } from './models/PagedRelationItem';
export type { PagedSavedLogSearch } from './models/PagedSavedLogSearch';
export type { PagedSearcher } from './models/PagedSearcher';
export type { PagedSearchResult } from './models/PagedSearchResult';
export type { PagedTelemetry } from './models/PagedTelemetry';
@@ -120,6 +125,7 @@ export type { RuntimeFieldHandle } from './models/RuntimeFieldHandle';
export { RuntimeLevel } from './models/RuntimeLevel';
export type { RuntimeMethodHandle } from './models/RuntimeMethodHandle';
export type { RuntimeTypeHandle } from './models/RuntimeTypeHandle';
export type { SavedLogSearch } from './models/SavedLogSearch';
export type { Searcher } from './models/Searcher';
export type { SearchResult } from './models/SearchResult';
export { SecurityRuleSet } from './models/SecurityRuleSet';
@@ -160,6 +166,7 @@ export { HelpResource } from './services/HelpResource';
export { IndexerResource } from './services/IndexerResource';
export { InstallResource } from './services/InstallResource';
export { LanguageResource } from './services/LanguageResource';
export { LogViewerResource } from './services/LogViewerResource';
export { MediaResource } from './services/MediaResource';
export { MediaTypeResource } from './services/MediaTypeResource';
export { MemberGroupResource } from './services/MemberGroupResource';

View File

@@ -1,12 +0,0 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { NotificationStyle } from './NotificationStyle';
export type BackOfficeNotification = {
header?: string | null;
message?: string | null;
notificationType?: NotificationStyle;
};

View File

@@ -1,17 +0,0 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { ContentAppBadge } from './ContentAppBadge';
export type ContentApp = {
name?: string | null;
alias?: string | null;
weight?: number;
icon?: string | null;
view?: string | null;
viewModel?: any;
active?: boolean;
badge?: ContentAppBadge;
};

View File

@@ -1,11 +0,0 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { ContentAppBadgeType } from './ContentAppBadgeType';
export type ContentAppBadge = {
count?: number;
type?: ContentAppBadgeType;
};

View File

@@ -1,9 +0,0 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export enum ContentAppBadgeType {
DEFAULT = 'default',
WARNING = 'warning',
ALERT = 'alert',
}

View File

@@ -1,18 +0,0 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { BackOfficeNotification } from './BackOfficeNotification';
import type { ContentApp } from './ContentApp';
import type { DictionaryTranslation } from './DictionaryTranslation';
export type Dictionary = {
parentId?: string | null;
translations?: Array<DictionaryTranslation>;
contentApps?: Array<ContentApp>;
readonly notifications?: Array<BackOfficeNotification>;
name: string;
key?: string;
path?: string;
};

View File

@@ -2,8 +2,11 @@
/* tslint:disable */
/* eslint-disable */
import type { DictionaryItemTranslationModel } from './DictionaryItemTranslationModel';
export type DictionaryItem = {
parentId?: string | null;
name?: string;
translations?: Array<DictionaryItemTranslationModel>;
key?: string;
};

View File

@@ -0,0 +1,12 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { DictionaryItemTranslationModel } from './DictionaryItemTranslationModel';
export type DictionaryItemCreateModel = {
name?: string;
translations?: Array<DictionaryItemTranslationModel>;
parentKey?: string | null;
};

View File

@@ -0,0 +1,9 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export type DictionaryItemTranslationModel = {
isoCode?: string;
translation?: string;
};

View File

@@ -0,0 +1,11 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { DictionaryItemTranslationModel } from './DictionaryItemTranslationModel';
export type DictionaryItemUpdateModel = {
name?: string;
translations?: Array<DictionaryItemTranslationModel>;
};

View File

@@ -1,13 +0,0 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export type DictionaryTranslation = {
id?: number;
key?: string;
displayName?: string | null;
isoCode?: string | null;
translation?: string;
languageId?: number;
};

View File

@@ -0,0 +1,8 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export enum Direction {
ASCENDING = 'Ascending',
DESCENDING = 'Descending',
}

View File

@@ -1,10 +0,0 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export type JsonPatch = {
op?: string;
path?: string;
value?: any;
};

View File

@@ -0,0 +1,12 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export enum LogLevel {
VERBOSE = 'Verbose',
DEBUG = 'Debug',
INFORMATION = 'Information',
WARNING = 'Warning',
ERROR = 'Error',
FATAL = 'Fatal',
}

View File

@@ -0,0 +1,16 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { LogLevel } from './LogLevel';
import type { LogMessageProperty } from './LogMessageProperty';
export type LogMessage = {
timestamp?: string;
level?: LogLevel;
messageTemplate?: string | null;
renderedMessage?: string | null;
properties?: Array<LogMessageProperty>;
exception?: string | null;
};

View File

@@ -0,0 +1,9 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export type LogMessageProperty = {
name?: string;
value?: string | null;
};

View File

@@ -0,0 +1,9 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export type LogTemplate = {
messageTemplate?: string | null;
count?: number;
};

View File

@@ -0,0 +1,11 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { LogLevel } from './LogLevel';
export type Logger = {
name?: string;
level?: LogLevel;
};

View File

@@ -1,11 +0,0 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export enum NotificationStyle {
SAVE = 'Save',
INFO = 'Info',
ERROR = 'Error',
SUCCESS = 'Success',
WARNING = 'Warning',
}

View File

@@ -0,0 +1,11 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { LogMessage } from './LogMessage';
export type PagedLogMessage = {
total: number;
items: Array<LogMessage>;
};

View File

@@ -0,0 +1,11 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { LogTemplate } from './LogTemplate';
export type PagedLogTemplate = {
total: number;
items: Array<LogTemplate>;
};

View File

@@ -0,0 +1,11 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { Logger } from './Logger';
export type PagedLogger = {
total: number;
items: Array<Logger>;
};

View File

@@ -0,0 +1,11 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { SavedLogSearch } from './SavedLogSearch';
export type PagedSavedLogSearch = {
total: number;
items: Array<SavedLogSearch>;
};

View File

@@ -0,0 +1,9 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
export type SavedLogSearch = {
name?: string;
query?: string;
};

View File

@@ -2,12 +2,11 @@
/* tslint:disable */
/* eslint-disable */
import type { ContentResult } from '../models/ContentResult';
import type { CreatedResult } from '../models/CreatedResult';
import type { Dictionary } from '../models/Dictionary';
import type { DictionaryImport } from '../models/DictionaryImport';
import type { DictionaryItem } from '../models/DictionaryItem';
import type { DictionaryItemCreateModel } from '../models/DictionaryItemCreateModel';
import type { DictionaryItemUpdateModel } from '../models/DictionaryItemUpdateModel';
import type { FolderTreeItem } from '../models/FolderTreeItem';
import type { JsonPatch } from '../models/JsonPatch';
import type { PagedDictionaryOverview } from '../models/PagedDictionaryOverview';
import type { PagedEntityTreeItem } from '../models/PagedEntityTreeItem';
@@ -39,14 +38,14 @@ export class DictionaryResource {
}
/**
* @returns CreatedResult Created
* @returns any Created
* @throws ApiError
*/
public static postDictionary({
requestBody,
}: {
requestBody?: DictionaryItem,
}): CancelablePromise<CreatedResult> {
requestBody?: DictionaryItemCreateModel,
}): CancelablePromise<any> {
return __request(OpenAPI, {
method: 'POST',
url: '/umbraco/management/api/v1/dictionary',
@@ -54,44 +53,21 @@ export class DictionaryResource {
mediaType: 'application/json',
errors: {
400: `Bad Request`,
},
});
}
/**
* @returns ContentResult Success
* @throws ApiError
*/
public static patchDictionaryById({
id,
requestBody,
}: {
id: string,
requestBody?: Array<JsonPatch>,
}): CancelablePromise<ContentResult> {
return __request(OpenAPI, {
method: 'PATCH',
url: '/umbraco/management/api/v1/dictionary/{id}',
path: {
'id': id,
},
body: requestBody,
mediaType: 'application/json',
errors: {
404: `Not Found`,
409: `Conflict`,
},
});
}
/**
* @returns Dictionary Success
* @returns DictionaryItem Success
* @throws ApiError
*/
public static getDictionaryByKey({
key,
}: {
key: string,
}): CancelablePromise<Dictionary> {
}): CancelablePromise<DictionaryItem> {
return __request(OpenAPI, {
method: 'GET',
url: '/umbraco/management/api/v1/dictionary/{key}',
@@ -120,6 +96,33 @@ export class DictionaryResource {
'key': key,
},
errors: {
400: `Bad Request`,
404: `Not Found`,
},
});
}
/**
* @returns any Success
* @throws ApiError
*/
public static putDictionaryByKey({
key,
requestBody,
}: {
key: string,
requestBody?: DictionaryItemUpdateModel,
}): CancelablePromise<any> {
return __request(OpenAPI, {
method: 'PUT',
url: '/umbraco/management/api/v1/dictionary/{key}',
path: {
'key': key,
},
body: requestBody,
mediaType: 'application/json',
errors: {
400: `Bad Request`,
404: `Not Found`,
},
});

View File

@@ -0,0 +1,236 @@
/* istanbul ignore file */
/* tslint:disable */
/* eslint-disable */
import type { Direction } from '../models/Direction';
import type { LogLevel } from '../models/LogLevel';
import type { PagedLogger } from '../models/PagedLogger';
import type { PagedLogMessage } from '../models/PagedLogMessage';
import type { PagedLogTemplate } from '../models/PagedLogTemplate';
import type { PagedSavedLogSearch } from '../models/PagedSavedLogSearch';
import type { SavedLogSearch } from '../models/SavedLogSearch';
import type { CancelablePromise } from '../core/CancelablePromise';
import { OpenAPI } from '../core/OpenAPI';
import { request as __request } from '../core/request';
export class LogViewerResource {
/**
* @returns PagedLogger Success
* @throws ApiError
*/
public static getLogViewerLevel({
skip,
take = 100,
}: {
skip?: number,
take?: number,
}): CancelablePromise<PagedLogger> {
return __request(OpenAPI, {
method: 'GET',
url: '/umbraco/management/api/v1/log-viewer/level',
query: {
'skip': skip,
'take': take,
},
});
}
/**
* @returns any Success
* @throws ApiError
*/
public static getLogViewerLevelCount({
startDate,
endDate,
}: {
startDate?: string,
endDate?: string,
}): CancelablePromise<any> {
return __request(OpenAPI, {
method: 'GET',
url: '/umbraco/management/api/v1/log-viewer/level-count',
query: {
'startDate': startDate,
'endDate': endDate,
},
errors: {
400: `Bad Request`,
},
});
}
/**
* @returns PagedLogMessage Success
* @throws ApiError
*/
public static getLogViewerLog({
skip,
take = 100,
orderDirection,
filterExpression,
logLevel,
startDate,
endDate,
}: {
skip?: number,
take?: number,
orderDirection?: Direction,
filterExpression?: string,
logLevel?: Array<LogLevel>,
startDate?: string,
endDate?: string,
}): CancelablePromise<PagedLogMessage> {
return __request(OpenAPI, {
method: 'GET',
url: '/umbraco/management/api/v1/log-viewer/log',
query: {
'skip': skip,
'take': take,
'orderDirection': orderDirection,
'filterExpression': filterExpression,
'logLevel': logLevel,
'startDate': startDate,
'endDate': endDate,
},
});
}
/**
* @returns PagedLogTemplate Success
* @throws ApiError
*/
public static getLogViewerMessageTemplate({
skip,
take = 100,
startDate,
endDate,
}: {
skip?: number,
take?: number,
startDate?: string,
endDate?: string,
}): CancelablePromise<PagedLogTemplate> {
return __request(OpenAPI, {
method: 'GET',
url: '/umbraco/management/api/v1/log-viewer/message-template',
query: {
'skip': skip,
'take': take,
'startDate': startDate,
'endDate': endDate,
},
errors: {
400: `Bad Request`,
},
});
}
/**
* @returns PagedSavedLogSearch Success
* @throws ApiError
*/
public static getLogViewerSavedSearch({
skip,
take = 100,
}: {
skip?: number,
take?: number,
}): CancelablePromise<PagedSavedLogSearch> {
return __request(OpenAPI, {
method: 'GET',
url: '/umbraco/management/api/v1/log-viewer/saved-search',
query: {
'skip': skip,
'take': take,
},
});
}
/**
* @returns any Created
* @throws ApiError
*/
public static postLogViewerSavedSearch({
requestBody,
}: {
requestBody?: SavedLogSearch,
}): CancelablePromise<any> {
return __request(OpenAPI, {
method: 'POST',
url: '/umbraco/management/api/v1/log-viewer/saved-search',
body: requestBody,
mediaType: 'application/json',
errors: {
400: `Bad Request`,
},
});
}
/**
* @returns SavedLogSearch Success
* @throws ApiError
*/
public static getLogViewerSavedSearchByName({
name,
}: {
name: string,
}): CancelablePromise<SavedLogSearch> {
return __request(OpenAPI, {
method: 'GET',
url: '/umbraco/management/api/v1/log-viewer/saved-search/{name}',
path: {
'name': name,
},
errors: {
404: `Not Found`,
},
});
}
/**
* @returns any Success
* @throws ApiError
*/
public static deleteLogViewerSavedSearchByName({
name,
}: {
name: string,
}): CancelablePromise<any> {
return __request(OpenAPI, {
method: 'DELETE',
url: '/umbraco/management/api/v1/log-viewer/saved-search/{name}',
path: {
'name': name,
},
errors: {
404: `Not Found`,
},
});
}
/**
* @returns any Success
* @throws ApiError
*/
public static getLogViewerValidateLogsSize({
startDate,
endDate,
}: {
startDate?: string,
endDate?: string,
}): CancelablePromise<any> {
return __request(OpenAPI, {
method: 'GET',
url: '/umbraco/management/api/v1/log-viewer/validate-logs-size',
query: {
'startDate': startDate,
'endDate': endDate,
},
errors: {
400: `Bad Request`,
},
});
}
}