@equinor/fusion-framework-module-services 7.2.2-next.0 → 8.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +20 -5
- package/README.md +125 -0
- package/dist/esm/bookmarks/api-version.js +3 -0
- package/dist/esm/bookmarks/api-version.js.map +1 -1
- package/dist/esm/bookmarks/index.js +13 -0
- package/dist/esm/bookmarks/index.js.map +1 -1
- package/dist/esm/bookmarks/schemas.js +10 -0
- package/dist/esm/bookmarks/schemas.js.map +1 -1
- package/dist/esm/bookmarks/types.js +5 -0
- package/dist/esm/bookmarks/types.js.map +1 -1
- package/dist/esm/configurator.js +7 -0
- package/dist/esm/configurator.js.map +1 -1
- package/dist/esm/context/client.js +32 -6
- package/dist/esm/context/client.js.map +1 -1
- package/dist/esm/context/get/client.js +9 -4
- package/dist/esm/context/get/client.js.map +1 -1
- package/dist/esm/context/index.js +13 -0
- package/dist/esm/context/index.js.map +1 -1
- package/dist/esm/context/query/client.js +9 -1
- package/dist/esm/context/query/client.js.map +1 -1
- package/dist/esm/context/related/client.js +9 -1
- package/dist/esm/context/related/client.js.map +1 -1
- package/dist/esm/context/static.js +3 -2
- package/dist/esm/context/static.js.map +1 -1
- package/dist/esm/errors.js +14 -0
- package/dist/esm/errors.js.map +1 -1
- package/dist/esm/index.js +14 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/module.js +39 -7
- package/dist/esm/module.js.map +1 -1
- package/dist/esm/notification/client.js +56 -14
- package/dist/esm/notification/client.js.map +1 -1
- package/dist/esm/notification/index.js +14 -0
- package/dist/esm/notification/index.js.map +1 -1
- package/dist/esm/notification/static.js +3 -2
- package/dist/esm/notification/static.js.map +1 -1
- package/dist/esm/people/client.js +58 -5
- package/dist/esm/people/client.js.map +1 -1
- package/dist/esm/people/index.js +13 -0
- package/dist/esm/people/index.js.map +1 -1
- package/dist/esm/people/person-details/client.js +10 -4
- package/dist/esm/people/person-details/client.js.map +1 -1
- package/dist/esm/people/person-photo/client.js +10 -4
- package/dist/esm/people/person-photo/client.js.map +1 -1
- package/dist/esm/people/query/client.js +10 -4
- package/dist/esm/people/query/client.js.map +1 -1
- package/dist/esm/people/static.js +3 -0
- package/dist/esm/people/static.js.map +1 -1
- package/dist/esm/people/utils.js +19 -0
- package/dist/esm/people/utils.js.map +1 -1
- package/dist/esm/provider.js +37 -2
- package/dist/esm/provider.js.map +1 -1
- package/dist/esm/utils.js +2 -11
- package/dist/esm/utils.js.map +1 -1
- package/dist/esm/version.js +1 -1
- package/dist/esm/version.js.map +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/dist/types/bookmarks/api-version.d.ts +3 -0
- package/dist/types/bookmarks/index.d.ts +13 -0
- package/dist/types/bookmarks/schemas.d.ts +10 -0
- package/dist/types/bookmarks/types.d.ts +17 -0
- package/dist/types/configurator.d.ts +15 -1
- package/dist/types/context/api-models.d.ts +16 -0
- package/dist/types/context/client.d.ts +32 -6
- package/dist/types/context/get/client.d.ts +9 -4
- package/dist/types/context/get/types.d.ts +27 -0
- package/dist/types/context/index.d.ts +13 -0
- package/dist/types/context/query/client.d.ts +9 -1
- package/dist/types/context/query/types.d.ts +35 -0
- package/dist/types/context/related/client.d.ts +9 -1
- package/dist/types/context/related/types.d.ts +36 -0
- package/dist/types/context/static.d.ts +3 -2
- package/dist/types/errors.d.ts +14 -0
- package/dist/types/index.d.ts +14 -0
- package/dist/types/module.d.ts +41 -6
- package/dist/types/notification/api-models.d.ts +20 -1
- package/dist/types/notification/client.d.ts +56 -14
- package/dist/types/notification/index.d.ts +14 -0
- package/dist/types/notification/static.d.ts +3 -2
- package/dist/types/people/api-models.d.ts +26 -0
- package/dist/types/people/api-models.v2.d.ts +1 -0
- package/dist/types/people/api-models.v4.d.ts +24 -0
- package/dist/types/people/client.d.ts +58 -5
- package/dist/types/people/index.d.ts +13 -0
- package/dist/types/people/person-details/client.d.ts +10 -4
- package/dist/types/people/person-details/types.d.ts +21 -0
- package/dist/types/people/person-photo/client.d.ts +10 -4
- package/dist/types/people/person-photo/types.d.ts +17 -0
- package/dist/types/people/query/client.d.ts +10 -4
- package/dist/types/people/query/types.d.ts +19 -0
- package/dist/types/people/resolve/types.d.ts +7 -0
- package/dist/types/people/static.d.ts +3 -0
- package/dist/types/people/suggest/types.d.ts +7 -0
- package/dist/types/people/utils.d.ts +19 -0
- package/dist/types/provider.d.ts +69 -4
- package/dist/types/types.d.ts +40 -15
- package/dist/types/utils.d.ts +2 -11
- package/dist/types/version.d.ts +1 -1
- package/package.json +9 -9
- package/src/bookmarks/api-version.ts +3 -0
- package/src/bookmarks/index.ts +14 -0
- package/src/bookmarks/schemas.ts +10 -0
- package/src/bookmarks/types.ts +18 -0
- package/src/configurator.ts +15 -1
- package/src/context/api-models.ts +16 -0
- package/src/context/client.ts +32 -6
- package/src/context/get/client.ts +9 -4
- package/src/context/get/types.ts +27 -0
- package/src/context/index.ts +14 -0
- package/src/context/query/client.ts +9 -1
- package/src/context/query/types.ts +35 -0
- package/src/context/related/client.ts +9 -1
- package/src/context/related/types.ts +36 -0
- package/src/context/static.ts +3 -2
- package/src/errors.ts +14 -0
- package/src/index.ts +15 -0
- package/src/module.ts +47 -7
- package/src/notification/api-models.ts +20 -1
- package/src/notification/client.ts +56 -14
- package/src/notification/index.ts +15 -0
- package/src/notification/static.ts +3 -2
- package/src/people/api-models.ts +26 -1
- package/src/people/api-models.v2.ts +1 -0
- package/src/people/api-models.v4.ts +24 -0
- package/src/people/client.ts +58 -5
- package/src/people/index.ts +14 -0
- package/src/people/person-details/client.ts +10 -4
- package/src/people/person-details/types.ts +21 -0
- package/src/people/person-photo/client.ts +10 -4
- package/src/people/person-photo/types.ts +17 -0
- package/src/people/query/client.ts +10 -4
- package/src/people/query/types.ts +19 -0
- package/src/people/resolve/types.ts +7 -0
- package/src/people/static.ts +3 -0
- package/src/people/suggest/types.ts +7 -0
- package/src/people/utils.ts +19 -0
- package/src/provider.ts +79 -8
- package/src/types.ts +40 -15
- package/src/utils.ts +2 -11
- package/src/version.ts +1 -1
|
@@ -8,44 +8,86 @@ import type { PostNotificationResult, PostNotificationFn } from './notification/
|
|
|
8
8
|
import type { DeleteNotificationFn, DeleteNotificationResult } from './notification/delete';
|
|
9
9
|
import { type PutUserNotificationSettingsFn, type PutUserNotificationSettingsResult } from './settings/put';
|
|
10
10
|
import { type GetUserNotificationSettingsFn, type GetUserNotificationsSettingsResult } from './settings/get';
|
|
11
|
+
/**
|
|
12
|
+
* Typed API client for the Fusion notification service.
|
|
13
|
+
*
|
|
14
|
+
* Provides methods for notification CRUD operations, marking notifications
|
|
15
|
+
* as seen, and managing user notification settings.
|
|
16
|
+
*
|
|
17
|
+
* @template TMethod - The client execution method (`'json'` or `'json$'`).
|
|
18
|
+
* @template TClient - The underlying HTTP client type.
|
|
19
|
+
*/
|
|
11
20
|
export declare class NotificationApiClient<TMethod extends keyof ClientMethod<unknown> = keyof ClientMethod<unknown>, TClient extends IHttpClient = IHttpClient> {
|
|
12
21
|
protected _client: TClient;
|
|
13
22
|
protected _method: TMethod;
|
|
23
|
+
/** Returns the {@link ApiVersion} enum for version-constant access. */
|
|
14
24
|
get Version(): typeof ApiVersion;
|
|
25
|
+
/**
|
|
26
|
+
* @param _client - The HTTP client used to execute requests.
|
|
27
|
+
* @param _method - The execution method (`'json'` or `'json$'`).
|
|
28
|
+
*/
|
|
15
29
|
constructor(_client: TClient, _method: TMethod);
|
|
16
30
|
/**
|
|
17
|
-
* Fetch all notifications
|
|
18
|
-
*
|
|
31
|
+
* Fetch all notifications for the current user.
|
|
32
|
+
*
|
|
33
|
+
* @template TVersion - The API version key.
|
|
34
|
+
* @template TResult - The expected response type.
|
|
35
|
+
* @param version - API version to use.
|
|
36
|
+
* @returns All notifications matching the query.
|
|
19
37
|
*/
|
|
20
38
|
getAll<TVersion extends string = keyof typeof ApiVersion, TResult = GetNotificationsResult<TVersion>>(version: TVersion, ...args: Parameters<GetNotificationsFn<TVersion, TMethod, TClient, TResult>>): GetNotificationsResult<TVersion, TMethod, TResult>;
|
|
21
39
|
/**
|
|
22
|
-
* Fetch notification by
|
|
23
|
-
*
|
|
40
|
+
* Fetch a single notification by its identifier.
|
|
41
|
+
*
|
|
42
|
+
* @template TVersion - The API version key.
|
|
43
|
+
* @template TResult - The expected response type.
|
|
44
|
+
* @param version - API version to use.
|
|
45
|
+
* @returns The notification with the specified ID.
|
|
24
46
|
*/
|
|
25
47
|
getById<TVersion extends string = keyof typeof ApiVersion, TResult = GetNotificationResult<TVersion>>(version: TVersion, ...args: Parameters<GetNotificationFn<TVersion, TMethod, TClient, TResult>>): GetNotificationResult<TVersion, TMethod, TResult>;
|
|
26
48
|
/**
|
|
27
|
-
*
|
|
28
|
-
*
|
|
49
|
+
* Mark a notification as seen by the current user.
|
|
50
|
+
*
|
|
51
|
+
* @template TVersion - The API version key.
|
|
52
|
+
* @template TResult - The expected response type.
|
|
53
|
+
* @param version - API version to use.
|
|
54
|
+
* @returns The updated notification.
|
|
29
55
|
*/
|
|
30
56
|
setSeenByUser<TVersion extends string = keyof typeof ApiVersion, TResult = PatchNotificationResult<TVersion>>(version: TVersion, ...args: Parameters<PatchNotificationFn<TVersion, TMethod, TClient, TResult>>): PatchNotificationResult<TVersion, TMethod, TResult>;
|
|
31
57
|
/**
|
|
32
|
-
* Create a notification
|
|
33
|
-
*
|
|
58
|
+
* Create a new notification.
|
|
59
|
+
*
|
|
60
|
+
* @template TVersion - The API version key.
|
|
61
|
+
* @template TResult - The expected response type.
|
|
62
|
+
* @param version - API version to use.
|
|
63
|
+
* @returns The created notification.
|
|
34
64
|
*/
|
|
35
65
|
create<TVersion extends string = keyof typeof ApiVersion, TResult = PostNotificationResult<TVersion>>(version: TVersion, ...args: Parameters<PostNotificationFn<TVersion, TMethod, TClient, TResult>>): PostNotificationResult<TVersion, TMethod, TResult>;
|
|
36
66
|
/**
|
|
37
|
-
* Delete a notification
|
|
38
|
-
*
|
|
67
|
+
* Delete a notification by its identifier.
|
|
68
|
+
*
|
|
69
|
+
* @template TVersion - The API version key.
|
|
70
|
+
* @template TResult - The expected response type.
|
|
71
|
+
* @param version - API version to use.
|
|
72
|
+
* @returns The deletion result.
|
|
39
73
|
*/
|
|
40
74
|
delete<TVersion extends string = keyof typeof ApiVersion, TResult = PostNotificationResult<TVersion>>(version: TVersion, ...args: Parameters<DeleteNotificationFn<TVersion, TMethod, TClient, TResult>>): DeleteNotificationResult<TVersion, TMethod, TResult>;
|
|
41
75
|
/**
|
|
42
|
-
*
|
|
43
|
-
*
|
|
76
|
+
* Retrieve the current user's notification settings.
|
|
77
|
+
*
|
|
78
|
+
* @template TVersion - The API version key.
|
|
79
|
+
* @template TResult - The expected response type.
|
|
80
|
+
* @param version - API version to use.
|
|
81
|
+
* @returns The user's notification settings.
|
|
44
82
|
*/
|
|
45
83
|
getSettings<TVersion extends string = keyof typeof ApiVersion, TResult = PostNotificationResult<TVersion>>(version: TVersion, ...args: Parameters<GetUserNotificationSettingsFn<TVersion, TMethod, TClient, TResult>>): GetUserNotificationsSettingsResult<TVersion, TMethod, TResult>;
|
|
46
84
|
/**
|
|
47
|
-
* Update user notification settings
|
|
48
|
-
*
|
|
85
|
+
* Update the current user's notification settings.
|
|
86
|
+
*
|
|
87
|
+
* @template TVersion - The API version key.
|
|
88
|
+
* @template TResult - The expected response type.
|
|
89
|
+
* @param version - API version to use.
|
|
90
|
+
* @returns The updated notification settings.
|
|
49
91
|
*/
|
|
50
92
|
updateSettings<TVersion extends string = keyof typeof ApiVersion, TResult = PostNotificationResult<TVersion>>(version: TVersion, ...args: Parameters<PutUserNotificationSettingsFn<TVersion, TMethod, TClient, TResult>>): PutUserNotificationSettingsResult<TVersion, TMethod, TResult>;
|
|
51
93
|
}
|
|
@@ -1,3 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @packageDocumentation
|
|
3
|
+
*
|
|
4
|
+
* Notification API client and types.
|
|
5
|
+
*
|
|
6
|
+
* Provides {@link NotificationApiClient} for creating, fetching, deleting
|
|
7
|
+
* notifications, marking them as seen, and managing user notification
|
|
8
|
+
* settings, with versioned endpoints (`v1`, `v2`).
|
|
9
|
+
*
|
|
10
|
+
* @example
|
|
11
|
+
* ```ts
|
|
12
|
+
* import { NotificationApiClient } from '@equinor/fusion-framework-module-services/notification';
|
|
13
|
+
* ```
|
|
14
|
+
*/
|
|
1
15
|
export { NotificationApiClient, default } from './client';
|
|
2
16
|
export { ApiVersion } from './static';
|
|
3
17
|
export * from './api-models';
|
|
@@ -1,6 +1,7 @@
|
|
|
1
|
-
/**
|
|
1
|
+
/** Supported API versions for the notification service. */
|
|
2
2
|
export declare enum ApiVersion {
|
|
3
|
+
/** Notification API version 1.0. */
|
|
3
4
|
v1 = "1.0",
|
|
4
|
-
/** not in use
|
|
5
|
+
/** Notification API version 2.0 (not currently in use). */
|
|
5
6
|
v2 = "2.0"
|
|
6
7
|
}
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import type { ApiPerson_v2 } from './api-models.v2';
|
|
2
2
|
import type { ApiPerson_v4 } from './api-models.v4';
|
|
3
3
|
import { ApiVersion } from './static';
|
|
4
|
+
/** Project master reference attached to a person's contract. */
|
|
4
5
|
export type ApiProjectMaster = {
|
|
5
6
|
id: string;
|
|
6
7
|
name?: string;
|
|
7
8
|
};
|
|
9
|
+
/** Manager information with contact details and classification. */
|
|
8
10
|
export type ApiManager = {
|
|
9
11
|
azureUniqueId: string;
|
|
10
12
|
name?: string;
|
|
@@ -16,9 +18,13 @@ export type ApiManager = {
|
|
|
16
18
|
accountType: ApiProfileAccountType;
|
|
17
19
|
accountClassification: ApiAccountClassification;
|
|
18
20
|
};
|
|
21
|
+
/** Invitation status for a person's account. */
|
|
19
22
|
export type ApiInvitationStatus = 'Accepted' | 'Pending' | 'NotSent';
|
|
23
|
+
/** Account type classification for a person profile. */
|
|
20
24
|
export type ApiProfileAccountType = 'Employee' | 'Consultant' | 'Enterprise' | 'External' | 'External Hire';
|
|
25
|
+
/** Account classification tier for access control. */
|
|
21
26
|
export type ApiAccountClassification = 'Unclassified' | 'Internal' | 'External';
|
|
27
|
+
/** Linked account reference for a person profile. */
|
|
22
28
|
export type ApiProfileAccountLink = {
|
|
23
29
|
azureUniqueId: string;
|
|
24
30
|
mail?: string;
|
|
@@ -27,11 +33,26 @@ export type ApiProfileAccountLink = {
|
|
|
27
33
|
isExpired?: boolean;
|
|
28
34
|
upn?: string;
|
|
29
35
|
};
|
|
36
|
+
/**
|
|
37
|
+
* Map from API version to the corresponding person entity type.
|
|
38
|
+
*
|
|
39
|
+
* @see {@link ApiPerson_v2}
|
|
40
|
+
* @see {@link ApiPerson_v4}
|
|
41
|
+
*/
|
|
30
42
|
export type ApiPersonMap = {
|
|
31
43
|
[ApiVersion.v2]: ApiPerson_v2;
|
|
32
44
|
[ApiVersion.v4]: ApiPerson_v4;
|
|
33
45
|
};
|
|
46
|
+
/**
|
|
47
|
+
* Version-aware person entity type.
|
|
48
|
+
*
|
|
49
|
+
* Resolves to the concrete person shape for a given {@link ApiVersion}
|
|
50
|
+
* key or value.
|
|
51
|
+
*
|
|
52
|
+
* @template T - An `ApiVersion` key or value.
|
|
53
|
+
*/
|
|
34
54
|
export type ApiPerson<T extends keyof typeof ApiVersion | ApiVersion> = T extends ApiVersion ? ApiPersonMap[T] : T extends keyof typeof ApiVersion ? ApiPersonMap[(typeof ApiVersion)[T]] : unknown;
|
|
55
|
+
/** Person suggestion result with account type and department detail. */
|
|
35
56
|
export type ApiSuggestionPerson = {
|
|
36
57
|
accountType?: 'Unknown' | 'Employee' | 'Consultant' | 'Enterprise' | 'EnterpriseExternal' | 'External' | 'Local' | 'TemporaryEmployee' | 'System' | 'Admin' | 'MeetingRoom';
|
|
37
58
|
jobTitle?: string;
|
|
@@ -42,11 +63,13 @@ export type ApiSuggestionPerson = {
|
|
|
42
63
|
upn?: string;
|
|
43
64
|
mobilePhone?: string;
|
|
44
65
|
};
|
|
66
|
+
/** Application entity in a person suggestion result. */
|
|
45
67
|
export type ApiSuggestionApplication = {
|
|
46
68
|
applicationId: string;
|
|
47
69
|
applicationName?: string;
|
|
48
70
|
servicePrincipalType: 'Application' | 'ManagedIdentity' | 'ServicePrincipal';
|
|
49
71
|
};
|
|
72
|
+
/** Single suggestion value representing a person or system account. */
|
|
50
73
|
export type ApiSuggestionValue = {
|
|
51
74
|
azureUniqueId: string;
|
|
52
75
|
name?: string;
|
|
@@ -58,12 +81,14 @@ export type ApiSuggestionValue = {
|
|
|
58
81
|
avatarUrl: string;
|
|
59
82
|
isExpired: boolean;
|
|
60
83
|
};
|
|
84
|
+
/** Paginated suggestion response from the people suggest endpoint. */
|
|
61
85
|
export type ApiSuggestions = {
|
|
62
86
|
totalCount: number;
|
|
63
87
|
count: number;
|
|
64
88
|
'@nextPage': string | null;
|
|
65
89
|
value: Array<ApiSuggestionValue>;
|
|
66
90
|
};
|
|
91
|
+
/** Single resolved item from the people resolve endpoint. */
|
|
67
92
|
export type ApiResolveItem = {
|
|
68
93
|
success: boolean;
|
|
69
94
|
statusCode: number;
|
|
@@ -71,4 +96,5 @@ export type ApiResolveItem = {
|
|
|
71
96
|
identifier: string;
|
|
72
97
|
account: ApiSuggestionValue | null;
|
|
73
98
|
};
|
|
99
|
+
/** Array of resolved person lookup results. */
|
|
74
100
|
export type ApiResolved = Array<ApiResolveItem>;
|
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
import type { ApiAccountClassification, ApiInvitationStatus, ApiManager, ApiProfileAccountLink, ApiProfileAccountType, ApiProjectMaster } from './api-models';
|
|
2
|
+
/**
|
|
3
|
+
* Map of expandable properties available on a v4 person entity.
|
|
4
|
+
*
|
|
5
|
+
* Use the `expand` parameter in API requests to include these
|
|
6
|
+
* nested collections alongside the core person data.
|
|
7
|
+
*/
|
|
2
8
|
export type ApiPersonExpandMap_v4 = {
|
|
3
9
|
roles: Array<ApiPersonRole_v4>;
|
|
4
10
|
positions: Array<ApiPersonPosition_v4>;
|
|
@@ -6,7 +12,17 @@ export type ApiPersonExpandMap_v4 = {
|
|
|
6
12
|
manager: ApiManager;
|
|
7
13
|
companies: Array<ApiCompanyInfo_v4>;
|
|
8
14
|
};
|
|
15
|
+
/** Union of valid expand property keys for the v4 person entity. */
|
|
9
16
|
export type ApiPersonExpandProps_v4 = keyof ApiPersonExpandMap_v4;
|
|
17
|
+
/**
|
|
18
|
+
* Person entity returned by the v4 people API.
|
|
19
|
+
*
|
|
20
|
+
* Includes only the expanded properties specified by `TExpand`.
|
|
21
|
+
* Non-expanded properties from {@link ApiPersonExpandMap_v4} remain
|
|
22
|
+
* `Partial` (i.e. `undefined` at runtime).
|
|
23
|
+
*
|
|
24
|
+
* @template TExpand - Array of expand property keys to include.
|
|
25
|
+
*/
|
|
10
26
|
export type ApiPerson_v4<TExpand extends Array<ApiPersonExpandProps_v4> = []> = {
|
|
11
27
|
azureUniqueId: string;
|
|
12
28
|
mail?: string;
|
|
@@ -30,10 +46,12 @@ export type ApiPerson_v4<TExpand extends Array<ApiPersonExpandProps_v4> = []> =
|
|
|
30
46
|
} & /** expanded */ Partial<ApiPersonExpandMap_v4> & {
|
|
31
47
|
[K in TExpand[number]]: ApiPersonExpandMap_v4[K];
|
|
32
48
|
};
|
|
49
|
+
/** Company information associated with a v4 person entity. */
|
|
33
50
|
export type ApiCompanyInfo_v4 = {
|
|
34
51
|
id: string;
|
|
35
52
|
name?: string;
|
|
36
53
|
};
|
|
54
|
+
/** Role assigned to a person in the v4 API. */
|
|
37
55
|
export type ApiPersonRole_v4 = {
|
|
38
56
|
name?: string;
|
|
39
57
|
displayName?: string;
|
|
@@ -44,11 +62,13 @@ export type ApiPersonRole_v4 = {
|
|
|
44
62
|
onDemandSupport?: boolean;
|
|
45
63
|
scopes?: Array<ApiPersonRoleScope_v4>;
|
|
46
64
|
};
|
|
65
|
+
/** Scope constraint on a person role. */
|
|
47
66
|
export type ApiPersonRoleScope_v4 = {
|
|
48
67
|
type?: string;
|
|
49
68
|
values?: string[];
|
|
50
69
|
valueType?: string;
|
|
51
70
|
};
|
|
71
|
+
/** Position instance held by a person in the v4 API. */
|
|
52
72
|
export type ApiPersonPosition_v4 = {
|
|
53
73
|
positionId: string;
|
|
54
74
|
positionExternalId?: string;
|
|
@@ -63,18 +83,21 @@ export type ApiPersonPosition_v4 = {
|
|
|
63
83
|
appliesTo: string;
|
|
64
84
|
workload?: number;
|
|
65
85
|
};
|
|
86
|
+
/** Base position reference for a person position. */
|
|
66
87
|
export type ApiPersonBasePosition_v4 = {
|
|
67
88
|
id: string;
|
|
68
89
|
name?: string;
|
|
69
90
|
type?: string;
|
|
70
91
|
discipline?: string;
|
|
71
92
|
};
|
|
93
|
+
/** Project reference for a person position or contract. */
|
|
72
94
|
export type ApiPersonProject_v4 = {
|
|
73
95
|
id: string;
|
|
74
96
|
name?: string;
|
|
75
97
|
domainId?: string;
|
|
76
98
|
type?: string;
|
|
77
99
|
};
|
|
100
|
+
/** Contract associated with a person in the v4 API. */
|
|
78
101
|
export type ApiPersonContract_v4 = {
|
|
79
102
|
id: string;
|
|
80
103
|
name?: string;
|
|
@@ -85,6 +108,7 @@ export type ApiPersonContract_v4 = {
|
|
|
85
108
|
projectMaster: ApiProjectMaster;
|
|
86
109
|
positions: Array<ApiPersonPosition_v4>;
|
|
87
110
|
};
|
|
111
|
+
/** @deprecated Use {@link ApiCompanyInfo_v4} instead. */
|
|
88
112
|
export type ApiCompanyInfoV4 = {
|
|
89
113
|
id: string;
|
|
90
114
|
name?: string;
|
|
@@ -6,28 +6,81 @@ import { type ApiResponse as PersonQueryApiResponse, type ApiResult as PersonQue
|
|
|
6
6
|
import { type ApiResponse as PersonPhotoApiResponse, type ApiResult as PersonPhotoResult, type SupportedApiVersion as PersonPhotoSupportedApiVersion, type ApiRequestArgs as PersonPhotoApiRequestArgs } from './person-photo';
|
|
7
7
|
import { type ApiResponse as PersonSuggestApiResponse, type ApiResult as PersonSuggestResult } from './suggest';
|
|
8
8
|
import { type ApiResponse as PersonResolveApiResponse, type ApiResult as PersonResolveResult } from './resolve';
|
|
9
|
+
/**
|
|
10
|
+
* Typed API client for the Fusion people service.
|
|
11
|
+
*
|
|
12
|
+
* Provides methods for fetching person details, querying persons,
|
|
13
|
+
* retrieving profile photos, getting suggestions, and resolving
|
|
14
|
+
* person identifiers.
|
|
15
|
+
*
|
|
16
|
+
* @template TClient - The underlying HTTP client type.
|
|
17
|
+
*/
|
|
9
18
|
export declare class PeopleApiClient<TClient extends IHttpClient = IHttpClient> {
|
|
10
19
|
protected _client: TClient;
|
|
20
|
+
/** Returns the {@link ApiVersion} enum for version-constant access. */
|
|
11
21
|
get Version(): typeof ApiVersion;
|
|
22
|
+
/** @param _client - The HTTP client used to execute people requests. */
|
|
12
23
|
constructor(_client: TClient);
|
|
13
24
|
/**
|
|
14
|
-
* Fetch person by
|
|
25
|
+
* Fetch detailed information about a person by their Azure unique ID.
|
|
26
|
+
*
|
|
27
|
+
* @template TVersion - The API version key (e.g. `'v4'`).
|
|
28
|
+
* @template TArgs - Request argument type.
|
|
29
|
+
* @template TResult - Expected response type.
|
|
30
|
+
* @template TMethod - Client execution method (`'json'` or `'json$'`).
|
|
31
|
+
* @param version - API version to use.
|
|
32
|
+
* @param method - Client execution method.
|
|
33
|
+
* @param args - Request arguments including `azureId`.
|
|
34
|
+
* @param init - Optional request init overrides.
|
|
35
|
+
* @returns The person details.
|
|
15
36
|
*/
|
|
16
37
|
get<TVersion extends PersonDetailSupportedApiVersion, TArgs extends PersonDetailApiRequestArgs<TVersion>, TResult extends PersonDetailApiResponse<TVersion, TArgs>, TMethod extends keyof ClientMethod<TResult>>(version: TVersion, method: TMethod, args: TArgs, init?: ClientRequestInit<TClient, TResult>): PersonDetailResult<TVersion, TArgs, TMethod, TResult>;
|
|
17
38
|
/**
|
|
18
|
-
*
|
|
39
|
+
* Search for persons matching query criteria.
|
|
40
|
+
*
|
|
41
|
+
* @template TVersion - The API version key (e.g. `'v2'`).
|
|
42
|
+
* @template TArgs - Request argument type.
|
|
43
|
+
* @template TResult - Expected response type.
|
|
44
|
+
* @template TMethod - Client execution method.
|
|
45
|
+
* @param version - API version to use.
|
|
46
|
+
* @param method - Client execution method.
|
|
47
|
+
* @param args - Request arguments including `search` string.
|
|
48
|
+
* @param init - Optional request init overrides.
|
|
49
|
+
* @returns An array of matching person entities.
|
|
19
50
|
*/
|
|
20
51
|
query<TVersion extends PersonQuerySupportedApiVersion, TArgs extends PersonQueryApiRequestArgs<TVersion>, TResult = PersonQueryApiResponse<TVersion>, TMethod extends keyof ClientMethod<TResult> = keyof ClientMethod<TResult>>(version: TVersion, method: TMethod, args: TArgs, init?: ClientRequestInit<TClient, TResult>): PersonQueryResult<TVersion, TMethod, TResult>;
|
|
21
52
|
/**
|
|
22
|
-
*
|
|
53
|
+
* Fetch a person's profile photo as binary blob data.
|
|
54
|
+
*
|
|
55
|
+
* @template TVersion - The API version key (e.g. `'v2'`).
|
|
56
|
+
* @template TArgs - Request argument type.
|
|
57
|
+
* @template TResult - Expected response type.
|
|
58
|
+
* @template TMethod - Client execution method (`'blob'` or `'blob$'`).
|
|
59
|
+
* @param version - API version to use.
|
|
60
|
+
* @param method - Client execution method.
|
|
61
|
+
* @param args - Request arguments including `azureId`.
|
|
62
|
+
* @param init - Optional request init overrides.
|
|
63
|
+
* @returns The person's photo as a blob.
|
|
23
64
|
*/
|
|
24
65
|
photo<TVersion extends PersonPhotoSupportedApiVersion, TArgs extends PersonPhotoApiRequestArgs<TVersion>, TResult extends PersonPhotoApiResponse<TVersion> = PersonPhotoApiResponse<TVersion>, TMethod extends keyof ClientDataMethod = keyof ClientDataMethod>(version: TVersion, method: TMethod, args: TArgs, init?: ClientRequestInit<TClient, TResult>): PersonPhotoResult<TMethod>;
|
|
25
66
|
/**
|
|
26
|
-
*
|
|
67
|
+
* Fetch person suggestions (type-ahead / autocomplete).
|
|
68
|
+
*
|
|
69
|
+
* @template TResult - Expected response type.
|
|
70
|
+
* @template TMethod - Client execution method.
|
|
71
|
+
* @param method - Client execution method.
|
|
72
|
+
* @param init - Optional request init overrides.
|
|
73
|
+
* @returns Paginated suggestion results.
|
|
27
74
|
*/
|
|
28
75
|
suggest<TResult = PersonSuggestApiResponse, TMethod extends keyof ClientMethod<TResult> = keyof ClientMethod<TResult>>(method: TMethod, init?: ClientRequestInit<TClient, TResult>): PersonSuggestResult<TMethod, TResult>;
|
|
29
76
|
/**
|
|
30
|
-
* Resolve person
|
|
77
|
+
* Resolve person identifiers to account information.
|
|
78
|
+
*
|
|
79
|
+
* @template TResult - Expected response type.
|
|
80
|
+
* @template TMethod - Client execution method.
|
|
81
|
+
* @param method - Client execution method.
|
|
82
|
+
* @param init - Optional request init overrides.
|
|
83
|
+
* @returns Array of resolved person results.
|
|
31
84
|
*/
|
|
32
85
|
resolve<TResult = PersonResolveApiResponse, TMethod extends keyof ClientMethod<TResult> = keyof ClientMethod<TResult>>(method: TMethod, init?: ClientRequestInit<TClient, TResult>): PersonResolveResult<TMethod, TResult>;
|
|
33
86
|
}
|
|
@@ -1,3 +1,16 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @packageDocumentation
|
|
3
|
+
*
|
|
4
|
+
* People API client and types.
|
|
5
|
+
*
|
|
6
|
+
* Provides {@link PeopleApiClient} for person lookups, search, photo retrieval,
|
|
7
|
+
* suggestions, and identifier resolution, with versioned endpoints (`v2`, `v4`).
|
|
8
|
+
*
|
|
9
|
+
* @example
|
|
10
|
+
* ```ts
|
|
11
|
+
* import { PeopleApiClient } from '@equinor/fusion-framework-module-services/people';
|
|
12
|
+
* ```
|
|
13
|
+
*/
|
|
1
14
|
export { PeopleApiClient, default } from './client';
|
|
2
15
|
export { ApiVersion } from './static';
|
|
3
16
|
export * from './api-models';
|
|
@@ -2,10 +2,16 @@ import type { ClientRequestInit, IHttpClient } from '@equinor/fusion-framework-m
|
|
|
2
2
|
import type { ClientMethod } from '../../types';
|
|
3
3
|
import type { ApiResponse, ApiResult, ApiRequestArgs, SupportedApiVersion } from './types';
|
|
4
4
|
/**
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
* @
|
|
8
|
-
* @
|
|
5
|
+
* Creates a curried function that fetches detailed person information.
|
|
6
|
+
*
|
|
7
|
+
* @template TVersion - Supported API version (e.g. `'v4'`).
|
|
8
|
+
* @template TMethod - Client execution method (`'json'` or `'json$'`).
|
|
9
|
+
* @template TClient - The underlying HTTP client type.
|
|
10
|
+
* @template TArgs - Request argument type.
|
|
11
|
+
* @param client - HTTP client used to execute the request.
|
|
12
|
+
* @param version - API version to call.
|
|
13
|
+
* @param method - Client method to use (defaults to `'json'`).
|
|
14
|
+
* @returns A function that accepts person detail args and returns the result.
|
|
9
15
|
*/
|
|
10
16
|
export declare const client: <TVersion extends SupportedApiVersion, TMethod extends keyof ClientMethod = keyof ClientMethod, TClient extends IHttpClient = IHttpClient, TArgs extends ApiRequestArgs<TVersion> = ApiRequestArgs<TVersion>>(client: TClient, version: TVersion, method?: TMethod) => <T = ApiResponse<TVersion, TArgs>>(args: TArgs, init?: ClientRequestInit<TClient, T>) => ApiResult<TVersion, TArgs, TMethod, T>;
|
|
11
17
|
export default client;
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { ApiVersion } from '../static';
|
|
2
2
|
import type { ApiPerson_v4, ApiPersonExpandProps_v4 } from '../api-models.v4';
|
|
3
3
|
import type { ClientMethod } from '../../types';
|
|
4
|
+
/** API versions that support the person-details endpoint. */
|
|
4
5
|
export type SupportedApiVersion = Extract<keyof typeof ApiVersion, 'v4'>;
|
|
5
6
|
type ApiRequestArgsMap = {
|
|
6
7
|
[ApiVersion.v4]: {
|
|
@@ -8,11 +9,31 @@ type ApiRequestArgsMap = {
|
|
|
8
9
|
expand?: Array<ApiPersonExpandProps_v4>;
|
|
9
10
|
};
|
|
10
11
|
};
|
|
12
|
+
/** Union of all valid request argument shapes across supported versions. */
|
|
11
13
|
export type AllowedArgs = ApiRequestArgsMap[keyof ApiRequestArgsMap];
|
|
14
|
+
/**
|
|
15
|
+
* Version-aware request argument type for the person-details endpoint.
|
|
16
|
+
*
|
|
17
|
+
* @template T - Supported API version key.
|
|
18
|
+
*/
|
|
12
19
|
export type ApiRequestArgs<T extends SupportedApiVersion> = ApiRequestArgsMap[(typeof ApiVersion)[T]];
|
|
13
20
|
type ApiResponseTypes<TArgs extends AllowedArgs> = {
|
|
14
21
|
[ApiVersion.v4]: ApiPerson_v4<TArgs['expand'] extends [] ? TArgs['expand'] : []>;
|
|
15
22
|
};
|
|
23
|
+
/**
|
|
24
|
+
* Version-aware response type for the person-details endpoint.
|
|
25
|
+
*
|
|
26
|
+
* @template T - Supported API version key.
|
|
27
|
+
* @template TArgs - Request argument type.
|
|
28
|
+
*/
|
|
16
29
|
export type ApiResponse<T extends SupportedApiVersion, TArgs extends AllowedArgs> = ApiResponseTypes<TArgs>[(typeof ApiVersion)[T]];
|
|
30
|
+
/**
|
|
31
|
+
* Result type for the person-details endpoint.
|
|
32
|
+
*
|
|
33
|
+
* @template TVersion - Supported API version key.
|
|
34
|
+
* @template TArgs - Request argument type.
|
|
35
|
+
* @template TMethod - Client execution method.
|
|
36
|
+
* @template TResult - Expected response type.
|
|
37
|
+
*/
|
|
17
38
|
export type ApiResult<TVersion extends SupportedApiVersion, TArgs extends ApiRequestArgs<TVersion>, TMethod extends keyof ClientMethod<unknown> = keyof ClientMethod<unknown>, TResult = ApiResponse<TVersion, TArgs>> = ClientMethod<TResult>[TMethod];
|
|
18
39
|
export {};
|
|
@@ -2,10 +2,16 @@ import type { ClientRequestInit, IHttpClient } from '@equinor/fusion-framework-m
|
|
|
2
2
|
import type { ClientDataMethod } from '../../types';
|
|
3
3
|
import type { ApiResponse, ApiRequestArgs, SupportedApiVersion } from './types';
|
|
4
4
|
/**
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
* @
|
|
8
|
-
* @
|
|
5
|
+
* Creates a curried function that fetches a person's profile photo.
|
|
6
|
+
*
|
|
7
|
+
* @template TVersion - Supported API version (e.g. `'v2'`).
|
|
8
|
+
* @template TMethod - Client execution method (`'blob'` or `'blob$'`).
|
|
9
|
+
* @template TClient - The underlying HTTP client type.
|
|
10
|
+
* @template TArgs - Request argument type.
|
|
11
|
+
* @param client - HTTP client used to execute the request.
|
|
12
|
+
* @param version - API version to call.
|
|
13
|
+
* @param method - Client method to use (defaults to `'blob'`).
|
|
14
|
+
* @returns A function that accepts photo args and returns blob data.
|
|
9
15
|
*/
|
|
10
16
|
export declare const client: <TVersion extends SupportedApiVersion, TMethod extends keyof ClientDataMethod = keyof ClientDataMethod, TClient extends IHttpClient = IHttpClient, TArgs extends ApiRequestArgs<TVersion> = ApiRequestArgs<TVersion>>(client: TClient, version: TVersion, method?: TMethod) => <T extends ApiResponse<TVersion> = ApiResponse<TVersion>>(args: TArgs, init?: ClientRequestInit<TClient, T>) => ClientDataMethod<T>[TMethod];
|
|
11
17
|
export default client;
|
|
@@ -1,17 +1,34 @@
|
|
|
1
1
|
import type { BlobResult } from '@equinor/fusion-framework-module-http/client';
|
|
2
2
|
import { ApiVersion } from '../static';
|
|
3
3
|
import type { ClientDataMethod } from '../../types';
|
|
4
|
+
/** API versions that support the person photo endpoint. */
|
|
4
5
|
export type SupportedApiVersion = Extract<keyof typeof ApiVersion, 'v2'>;
|
|
5
6
|
type ApiRequestArgsMap = {
|
|
6
7
|
[ApiVersion.v2]: {
|
|
7
8
|
azureId: string;
|
|
8
9
|
};
|
|
9
10
|
};
|
|
11
|
+
/** Union of all valid request argument shapes across supported versions. */
|
|
10
12
|
export type AllowedArgs = ApiRequestArgsMap[keyof ApiRequestArgsMap];
|
|
13
|
+
/**
|
|
14
|
+
* Version-aware request argument type for the person photo endpoint.
|
|
15
|
+
*
|
|
16
|
+
* @template T - Supported API version key.
|
|
17
|
+
*/
|
|
11
18
|
export type ApiRequestArgs<T extends SupportedApiVersion> = ApiRequestArgsMap[(typeof ApiVersion)[T]];
|
|
12
19
|
type ApiResponseTypes = {
|
|
13
20
|
[ApiVersion.v2]: BlobResult;
|
|
14
21
|
};
|
|
22
|
+
/**
|
|
23
|
+
* Version-aware response type for the person photo endpoint.
|
|
24
|
+
*
|
|
25
|
+
* @template T - Supported API version key.
|
|
26
|
+
*/
|
|
15
27
|
export type ApiResponse<T extends SupportedApiVersion> = ApiResponseTypes[(typeof ApiVersion)[T]];
|
|
28
|
+
/**
|
|
29
|
+
* Result type for the person photo endpoint.
|
|
30
|
+
*
|
|
31
|
+
* @template TMethod - Client execution method (`'blob'` or `'blob$'`).
|
|
32
|
+
*/
|
|
16
33
|
export type ApiResult<TMethod extends keyof ClientDataMethod = keyof ClientDataMethod> = ClientDataMethod[TMethod];
|
|
17
34
|
export {};
|
|
@@ -2,10 +2,16 @@ import type { ClientRequestInit, IHttpClient } from '@equinor/fusion-framework-m
|
|
|
2
2
|
import type { ClientMethod } from '../../types';
|
|
3
3
|
import type { ApiResponse, ApiResult, ApiRequestArgs, SupportedApiVersion } from './types';
|
|
4
4
|
/**
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
* @
|
|
8
|
-
* @
|
|
5
|
+
* Creates a curried function that queries the people service.
|
|
6
|
+
*
|
|
7
|
+
* @template TVersion - Supported API version (e.g. `'v2'`).
|
|
8
|
+
* @template TMethod - Client execution method.
|
|
9
|
+
* @template TClient - The underlying HTTP client type.
|
|
10
|
+
* @template TArgs - Request argument type.
|
|
11
|
+
* @param client - HTTP client used to execute the request.
|
|
12
|
+
* @param version - API version to call.
|
|
13
|
+
* @param method - Client method to use (defaults to `'json'`).
|
|
14
|
+
* @returns A function that accepts query args and returns person results.
|
|
9
15
|
*/
|
|
10
16
|
export declare const client: <TVersion extends SupportedApiVersion, TMethod extends keyof ClientMethod = keyof ClientMethod, TClient extends IHttpClient = IHttpClient, TArgs extends ApiRequestArgs<TVersion> = ApiRequestArgs<TVersion>>(client: TClient, version: TVersion, method?: TMethod) => <T = ApiResponse<TVersion>>(args: TArgs, init?: ClientRequestInit<TClient, T>) => ApiResult<TVersion, TMethod, T>;
|
|
11
17
|
export default client;
|
|
@@ -1,17 +1,36 @@
|
|
|
1
1
|
import { ApiVersion } from '../static';
|
|
2
2
|
import type { ApiPerson_v2 } from '../api-models.v2';
|
|
3
3
|
import type { ClientMethod } from '../../types';
|
|
4
|
+
/** API versions that support the people query endpoint. */
|
|
4
5
|
export type SupportedApiVersion = Extract<keyof typeof ApiVersion, 'v2'>;
|
|
5
6
|
type ApiRequestArgsMap = {
|
|
6
7
|
[ApiVersion.v2]: {
|
|
7
8
|
search: string;
|
|
8
9
|
};
|
|
9
10
|
};
|
|
11
|
+
/** Union of all valid request argument shapes across supported versions. */
|
|
10
12
|
export type AllowedArgs = ApiRequestArgsMap[keyof ApiRequestArgsMap];
|
|
13
|
+
/**
|
|
14
|
+
* Version-aware request argument type for the people query endpoint.
|
|
15
|
+
*
|
|
16
|
+
* @template T - Supported API version key.
|
|
17
|
+
*/
|
|
11
18
|
export type ApiRequestArgs<T extends SupportedApiVersion> = ApiRequestArgsMap[(typeof ApiVersion)[T]];
|
|
12
19
|
type ApiResponseTypes = {
|
|
13
20
|
[ApiVersion.v2]: Array<ApiPerson_v2>;
|
|
14
21
|
};
|
|
22
|
+
/**
|
|
23
|
+
* Version-aware response type for the people query endpoint.
|
|
24
|
+
*
|
|
25
|
+
* @template T - Supported API version key.
|
|
26
|
+
*/
|
|
15
27
|
export type ApiResponse<T extends SupportedApiVersion> = ApiResponseTypes[(typeof ApiVersion)[T]];
|
|
28
|
+
/**
|
|
29
|
+
* Result type for the people query endpoint.
|
|
30
|
+
*
|
|
31
|
+
* @template TVersion - Supported API version key.
|
|
32
|
+
* @template TMethod - Client execution method.
|
|
33
|
+
* @template TResult - Expected response type.
|
|
34
|
+
*/
|
|
16
35
|
export type ApiResult<TVersion extends SupportedApiVersion, TMethod extends keyof ClientMethod<unknown> = keyof ClientMethod<unknown>, TResult = ApiResponse<TVersion>> = ClientMethod<TResult>[TMethod];
|
|
17
36
|
export {};
|
|
@@ -1,4 +1,11 @@
|
|
|
1
1
|
import type { ApiResolved } from '../api-models';
|
|
2
2
|
import type { ClientMethod } from '../../types';
|
|
3
|
+
/** Response type for the people resolve endpoint. */
|
|
3
4
|
export type ApiResponse = ApiResolved;
|
|
5
|
+
/**
|
|
6
|
+
* Result type for the people resolve endpoint.
|
|
7
|
+
*
|
|
8
|
+
* @template TMethod - Client execution method.
|
|
9
|
+
* @template TResult - Expected response type.
|
|
10
|
+
*/
|
|
4
11
|
export type ApiResult<TMethod extends keyof ClientMethod<unknown> = keyof ClientMethod<unknown>, TResult = ApiResponse> = ClientMethod<TResult>[TMethod];
|
|
@@ -1,4 +1,11 @@
|
|
|
1
1
|
import type { ApiSuggestions } from '../api-models';
|
|
2
2
|
import type { ClientMethod } from '../../types';
|
|
3
|
+
/** Response type for the people suggest endpoint. */
|
|
3
4
|
export type ApiResponse = ApiSuggestions;
|
|
5
|
+
/**
|
|
6
|
+
* Result type for the people suggest endpoint.
|
|
7
|
+
*
|
|
8
|
+
* @template TMethod - Client execution method.
|
|
9
|
+
* @template TResult - Expected response type.
|
|
10
|
+
*/
|
|
4
11
|
export type ApiResult<TMethod extends keyof ClientMethod<unknown> = keyof ClientMethod<unknown>, TResult = ApiResponse> = ClientMethod<TResult>[TMethod];
|
|
@@ -1,3 +1,22 @@
|
|
|
1
1
|
import type { ApiPerson } from './api-models';
|
|
2
2
|
import { ApiVersion } from './static';
|
|
3
|
+
/**
|
|
4
|
+
* Creates a type-guard function that validates whether a value conforms
|
|
5
|
+
* to the {@link ApiPerson} shape for a given API version.
|
|
6
|
+
*
|
|
7
|
+
* The guard checks that the value contains all required attributes
|
|
8
|
+
* defined for the specified version.
|
|
9
|
+
*
|
|
10
|
+
* @template V - API version key (e.g. `'v2'` or `'v4'`).
|
|
11
|
+
* @param version - The API version to validate against.
|
|
12
|
+
* @returns A type-guard function that narrows `T` to `ApiPerson<V>`.
|
|
13
|
+
*
|
|
14
|
+
* @example
|
|
15
|
+
* ```ts
|
|
16
|
+
* const isV4Person = isApiPerson('v4');
|
|
17
|
+
* if (isV4Person(data)) {
|
|
18
|
+
* console.log(data.azureUniqueId);
|
|
19
|
+
* }
|
|
20
|
+
* ```
|
|
21
|
+
*/
|
|
3
22
|
export declare const isApiPerson: <V extends keyof typeof ApiVersion>(version: V) => <T>(value: T) => value is T extends ApiPerson<V> ? T : never;
|