diff --git a/src/api.ts b/src/api.ts index f4c56b3..ccfd8bf 100644 --- a/src/api.ts +++ b/src/api.ts @@ -126,10 +126,10 @@ export interface ApplicationCreationResponse { 'credentials'?: ApplicationCreationResponseCredentials; /** * - * @type {AuthStrategy} + * @type {PortalAuthStrategy} * @memberof ApplicationCreationResponse */ - 'auth_strategy': AuthStrategy; + 'auth_strategy': PortalAuthStrategy; /** * An ISO-8601 timestamp representation of entity creation date. * @type {string} @@ -232,10 +232,10 @@ export interface ApplicationUpdateResponse { 'redirect_uri'?: string | null; /** * - * @type {AuthStrategy} + * @type {PortalAuthStrategy} * @memberof ApplicationUpdateResponse */ - 'auth_strategy'?: AuthStrategy; + 'auth_strategy'?: PortalAuthStrategy; /** * An ISO-8601 timestamp representation of entity creation date. * @type {string} @@ -249,98 +249,6 @@ export interface ApplicationUpdateResponse { */ 'updated_at': string; } -/** - * @type AuthStrategy - * @export - */ -export type AuthStrategy = AuthStrategyClientCredentials | AuthStrategyKeyAuth; - -/** - * Client Credential Auth strategy that the application uses. - * @export - * @interface AuthStrategyClientCredentials - */ -export interface AuthStrategyClientCredentials { - /** - * The Application Auth Strategy ID. - * @type {string} - * @memberof AuthStrategyClientCredentials - */ - 'id': string; - /** - * - * @type {string} - * @memberof AuthStrategyClientCredentials - */ - 'name': string; - /** - * - * @type {string} - * @memberof AuthStrategyClientCredentials - */ - 'credential_type': AuthStrategyClientCredentialsCredentialTypeEnum; - /** - * - * @type {Array} - * @memberof AuthStrategyClientCredentials - */ - 'auth_methods': Array; -} - -export const AuthStrategyClientCredentialsCredentialTypeEnum = { - ClientCredentials: 'client_credentials', - SelfManagedClientCredentials: 'self_managed_client_credentials' -} as const; - -export type AuthStrategyClientCredentialsCredentialTypeEnum = typeof AuthStrategyClientCredentialsCredentialTypeEnum[keyof typeof AuthStrategyClientCredentialsCredentialTypeEnum]; - -/** - * - * @export - * @enum {string} - */ - -export const AuthStrategyCredentialType = { - ClientCredentials: 'client_credentials', - SelfManagedClientCredentials: 'self_managed_client_credentials', - KeyAuth: 'key_auth' -} as const; - -export type AuthStrategyCredentialType = typeof AuthStrategyCredentialType[keyof typeof AuthStrategyCredentialType]; - - -/** - * KeyAuth Auth strategy that the application uses. - * @export - * @interface AuthStrategyKeyAuth - */ -export interface AuthStrategyKeyAuth { - /** - * The Application Auth Strategy ID. - * @type {string} - * @memberof AuthStrategyKeyAuth - */ - 'id': string; - /** - * - * @type {string} - * @memberof AuthStrategyKeyAuth - */ - 'name': string; - /** - * - * @type {string} - * @memberof AuthStrategyKeyAuth - */ - 'credential_type': AuthStrategyKeyAuthCredentialTypeEnum; -} - -export const AuthStrategyKeyAuthCredentialTypeEnum = { - KeyAuth: 'key_auth' -} as const; - -export type AuthStrategyKeyAuthCredentialTypeEnum = typeof AuthStrategyKeyAuthCredentialTypeEnum[keyof typeof AuthStrategyKeyAuthCredentialTypeEnum]; - /** * The request schema for the authenticate endpoint. * @export @@ -792,8 +700,9 @@ export type DocumentContentTypeEnum = typeof DocumentContentTypeEnum[keyof typeo */ export const DocumentFormatContentTypeEnum = { - Json: 'application/json', - VndKonnectDocumentNodesjson: 'application/vnd.konnect.document-nodes+json' + TextMarkdown: 'text/markdown', + ApplicationJson: 'application/json', + ApplicationVndKonnectDocumentNodesjson: 'application/vnd.konnect.document-nodes+json' } as const; export type DocumentFormatContentTypeEnum = typeof DocumentFormatContentTypeEnum[keyof typeof DocumentFormatContentTypeEnum]; @@ -994,10 +903,10 @@ export interface GetApplicationResponse { 'redirect_uri'?: string | null; /** * - * @type {AuthStrategy} + * @type {PortalAuthStrategy} * @memberof GetApplicationResponse */ - 'auth_strategy'?: AuthStrategy; + 'auth_strategy'?: PortalAuthStrategy; /** * An ISO-8601 timestamp representation of entity creation date. * @type {string} @@ -1399,37 +1308,6 @@ export interface ListApplicationsResponse { */ 'data': Array; } -/** - * - * @export - * @interface ListAuthStrategiesItem - */ -export interface ListAuthStrategiesItem { - /** - * ID of the auth strategy to use for the application. If null or not included, the default application auth strategy will be used. - * @type {string} - * @memberof ListAuthStrategiesItem - */ - 'id': string | null; - /** - * - * @type {string} - * @memberof ListAuthStrategiesItem - */ - 'name': string; - /** - * - * @type {AuthStrategyCredentialType} - * @memberof ListAuthStrategiesItem - */ - 'credential_type': AuthStrategyCredentialType; - /** - * - * @type {Array} - * @memberof ListAuthStrategiesItem - */ - 'auth_methods'?: Array; -} /** * * @export @@ -1444,10 +1322,10 @@ export interface ListAuthStrategiesResponse { 'meta': PaginatedMeta; /** * - * @type {Array} + * @type {Array} * @memberof ListAuthStrategiesResponse */ - 'data': Array; + 'data': Array; } /** * @@ -1868,6 +1746,95 @@ export interface PortalAppearanceVariablesCatalogPrimaryHeader { */ 'text'?: string; } +/** + * @type PortalAuthStrategy + * @export + */ +export type PortalAuthStrategy = PortalAuthStrategyOneOf | object; + +/** + * Client Credential Auth strategy that the application uses. + * @export + * @interface PortalAuthStrategyClientCredentials + */ +export interface PortalAuthStrategyClientCredentials { + /** + * The Application Auth Strategy ID. + * @type {string} + * @memberof PortalAuthStrategyClientCredentials + */ + 'id': string; + /** + * + * @type {string} + * @memberof PortalAuthStrategyClientCredentials + */ + 'name': string; + /** + * + * @type {string} + * @memberof PortalAuthStrategyClientCredentials + */ + 'credential_type': PortalAuthStrategyClientCredentialsCredentialTypeEnum; + /** + * + * @type {Array} + * @memberof PortalAuthStrategyClientCredentials + */ + 'auth_methods': Array; +} + +export const PortalAuthStrategyClientCredentialsCredentialTypeEnum = { + ClientCredentials: 'client_credentials', + SelfManagedClientCredentials: 'self_managed_client_credentials' +} as const; + +export type PortalAuthStrategyClientCredentialsCredentialTypeEnum = typeof PortalAuthStrategyClientCredentialsCredentialTypeEnum[keyof typeof PortalAuthStrategyClientCredentialsCredentialTypeEnum]; + +/** + * KeyAuth Auth strategy that the application uses. + * @export + * @interface PortalAuthStrategyKeyAuth + */ +export interface PortalAuthStrategyKeyAuth { + /** + * The Application Auth Strategy ID. + * @type {string} + * @memberof PortalAuthStrategyKeyAuth + */ + 'id': string; + /** + * + * @type {string} + * @memberof PortalAuthStrategyKeyAuth + */ + 'name': string; + /** + * + * @type {string} + * @memberof PortalAuthStrategyKeyAuth + */ + 'credential_type': PortalAuthStrategyKeyAuthCredentialTypeEnum; + /** + * + * @type {Array} + * @memberof PortalAuthStrategyKeyAuth + */ + 'key_names': Array; +} + +export const PortalAuthStrategyKeyAuthCredentialTypeEnum = { + KeyAuth: 'key_auth' +} as const; + +export type PortalAuthStrategyKeyAuthCredentialTypeEnum = typeof PortalAuthStrategyKeyAuthCredentialTypeEnum[keyof typeof PortalAuthStrategyKeyAuthCredentialTypeEnum]; + +/** + * @type PortalAuthStrategyOneOf + * @export + */ +export type PortalAuthStrategyOneOf = PortalAuthStrategyClientCredentials | PortalAuthStrategyKeyAuth; + /** * describe the portal execution context * @export