Skip to content

Updating from 26.2.0 to 26.2.1 breaks ts based apps because of the change to KeycloakConfig #186

@johalternate

Description

@johalternate

The KeycloakConfig type has been refactored into a union type to support both Keycloak and generic OpenID Connect configurations. Typescript applications that rely on KeycloakConfig wont compile if they dont replace current usages of KeycloakConfig with KeycloakConfigServer.

Before:

export interface KeycloakConfig {
	/**
	 * URL to the Keycloak server, for example: http://keycloak-server/auth
	 */
	url: string;
	/**
	 * Name of the realm, for example: 'myrealm'
	 */
	realm: string;
	/**
	 * Client identifier, example: 'myapp'
	 */
	clientId: string;
}

After 3a26e5b :

export interface KeycloakServerConfig {
	/**
	 * URL to the Keycloak server, for example: http://keycloak-server/auth
	 */
	url: string;
	/**
	 * Name of the realm, for example: 'myrealm'
	 */
	realm: string;
	/**
	 * Client identifier, example: 'myapp'
	 */
	clientId: string;
}

export interface GenericOidcConfig {
	/**
	 * Client identifier, example: 'myapp'
	 */
	clientId: string;
	/** Generic OpenID Connect configuration, can be a URL to the discovery metadata endpoint, or the metadata itself. */
	oidcProvider: string | OpenIdProviderMetadata;
}

export type KeycloakConfig = KeycloakServerConfig | GenericOidcConfig;

Version

26.2.1

Expected behavior

No response

Actual behavior

No response

How to Reproduce?

No response

Anything else?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions