diff --git a/.changeset/lovely-cloths-sin.md b/.changeset/lovely-cloths-sin.md new file mode 100644 index 0000000000..fc7d9fae80 --- /dev/null +++ b/.changeset/lovely-cloths-sin.md @@ -0,0 +1,7 @@ +--- +'@forgerock/journey-client': minor +'@forgerock/device-client': minor +'@forgerock/oidc-client': minor +--- + +Expose return types for clients diff --git a/packages/device-client/src/lib/types/index.ts b/packages/device-client/src/lib/types/index.ts index 2571e8cc4e..884c2a1d05 100644 --- a/packages/device-client/src/lib/types/index.ts +++ b/packages/device-client/src/lib/types/index.ts @@ -4,6 +4,9 @@ * This software may be modified and distributed under the terms * of the MIT license. See the LICENSE file for details. */ +import { deviceClient } from '../device.store.js'; + +export type DeviceClient = ReturnType; // Re-export types from external dependencies that consumers need export type { ConfigOptions } from '@forgerock/javascript-sdk'; diff --git a/packages/journey-client/src/lib/client.types.ts b/packages/journey-client/src/lib/client.types.ts new file mode 100644 index 0000000000..a6337c5150 --- /dev/null +++ b/packages/journey-client/src/lib/client.types.ts @@ -0,0 +1,9 @@ +/* + * Copyright (c) 2025 Ping Identity Corporation. All rights reserved. + * + * This software may be modified and distributed under the terms + * of the MIT license. See the LICENSE file for details. + */ +import { journey } from './client.store.js'; + +export type JourneyClient = Awaited>; diff --git a/packages/journey-client/src/types.ts b/packages/journey-client/src/types.ts index 5ec9b606c9..edf39abb6f 100644 --- a/packages/journey-client/src/types.ts +++ b/packages/journey-client/src/types.ts @@ -19,6 +19,7 @@ export type { } from '@forgerock/sdk-types'; // Re-export local types +export * from './lib/client.types.js'; export * from './lib/config.types.js'; export * from './lib/interfaces.js'; export * from './lib/step.types.js'; diff --git a/packages/oidc-client/src/lib/client.types.ts b/packages/oidc-client/src/lib/client.types.ts index ed2ea08274..6a04c919b3 100644 --- a/packages/oidc-client/src/lib/client.types.ts +++ b/packages/oidc-client/src/lib/client.types.ts @@ -7,6 +7,9 @@ import type { GenericError, GetAuthorizationUrlOptions } from '@forgerock/sdk-types'; import type { StorageConfig } from '@forgerock/storage'; import { createClientStore } from './client.store.utils.js'; +import { oidc } from './client.store.js'; + +export type OidcClient = Awaited>; export type ClientStore = ReturnType;