@thinkai/tai-api-contract 2.38.0 → 2.40.0-pr.844.c1288a26
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/dist/generated/openapi.d.ts +89 -2
- package/dist/generated/openapi.d.ts.map +1 -1
- package/dist/index.d.ts +12 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js.map +1 -1
- package/openapi/openapi.yaml +83 -3
- package/package.json +1 -1
- package/src/generated/openapi.ts +89 -2
- package/src/index.ts +13 -1
|
@@ -2055,6 +2055,26 @@ export interface paths {
|
|
|
2055
2055
|
patch?: never;
|
|
2056
2056
|
trace?: never;
|
|
2057
2057
|
};
|
|
2058
|
+
"/workspaces/{workspaceId}/integrations/zenhr/reconnect": {
|
|
2059
|
+
parameters: {
|
|
2060
|
+
query?: never;
|
|
2061
|
+
header?: never;
|
|
2062
|
+
path?: never;
|
|
2063
|
+
cookie?: never;
|
|
2064
|
+
};
|
|
2065
|
+
get?: never;
|
|
2066
|
+
put?: never;
|
|
2067
|
+
/**
|
|
2068
|
+
* Attempt silent ZenHR reconnect
|
|
2069
|
+
* @description Attempts a silent token refresh and branch ping using stored ZenHR OAuth credentials. Returns `{ ok: true }` when the connection is restored without user interaction. Returns `{ ok: false, oauthRequired: true }` when stored credentials exist but refresh failed with an OAuth re-authorization error (e.g. `invalid_grant`); the SPA should start ZenHR OAuth next. Returns `502` for other upstream failures (same semantics as `GET .../integrations/zenhr/branches`).
|
|
2070
|
+
*/
|
|
2071
|
+
post: operations["reconnectWorkspaceZenHr"];
|
|
2072
|
+
delete?: never;
|
|
2073
|
+
options?: never;
|
|
2074
|
+
head?: never;
|
|
2075
|
+
patch?: never;
|
|
2076
|
+
trace?: never;
|
|
2077
|
+
};
|
|
2058
2078
|
"/workspaces/{workspaceId}/hris/status": {
|
|
2059
2079
|
parameters: {
|
|
2060
2080
|
query?: never;
|
|
@@ -2488,6 +2508,8 @@ export interface components {
|
|
|
2488
2508
|
/** @description Canonical person identifier (matches org chart person_id / employeeId). */
|
|
2489
2509
|
personId: string;
|
|
2490
2510
|
personName: string;
|
|
2511
|
+
/** @description Leaf team id from the scoring org chart (stable productivity team filter key). */
|
|
2512
|
+
teamId?: string;
|
|
2491
2513
|
teamName?: string;
|
|
2492
2514
|
/** @description True when the contributor GitHub login is not mapped in the org chart. */
|
|
2493
2515
|
notInOrgChart?: boolean;
|
|
@@ -2502,7 +2524,7 @@ export interface components {
|
|
|
2502
2524
|
scope: components["schemas"]["ProductivityInsightsAggregatedTeamsScopeDto"];
|
|
2503
2525
|
/** Format: date-time */
|
|
2504
2526
|
generatedAt: string;
|
|
2505
|
-
/** @description
|
|
2527
|
+
/** @description Sum of contributor weekly merged PR counts (matches the contributors table). Not deduplicated org-wide unique PRs when the same PR appears on multiple rows. */
|
|
2506
2528
|
weeks: components["schemas"]["ProductivityInsightsMergedPrTrendWeekDto"][];
|
|
2507
2529
|
contributors: components["schemas"]["ProductivityInsightsMergedPrContributorRowDto"][];
|
|
2508
2530
|
};
|
|
@@ -2538,9 +2560,11 @@ export interface components {
|
|
|
2538
2560
|
notInOrgChart?: boolean;
|
|
2539
2561
|
/** @description Present when the request included `year` — calendar-year heatmap mode. */
|
|
2540
2562
|
year?: number;
|
|
2541
|
-
/** @description Daily buckets aggregated
|
|
2563
|
+
/** @description Daily buckets aggregated from ingested person-level merged PR events for the selected period range or calendar year (same source as memberContributors). */
|
|
2542
2564
|
heatmapWeeks?: components["schemas"]["ProductivityInsightsContributorActivityWeekDto"][];
|
|
2543
2565
|
heatmapSummary?: components["schemas"]["ProductivityInsightsContributorActivitySummaryDto"];
|
|
2566
|
+
/** @description Per-member merged PR weekly series for the selected period or year — person-level source aligned with heatmapWeeks and the team roster table. */
|
|
2567
|
+
memberContributors?: components["schemas"]["ProductivityInsightsMergedPrContributorRowDto"][];
|
|
2544
2568
|
weeks: components["schemas"]["ProductivityInsightsAggregatedTeamWeekDto"][];
|
|
2545
2569
|
summary: components["schemas"]["ProductivityInsightsTeamSummaryDto"];
|
|
2546
2570
|
};
|
|
@@ -4189,6 +4213,16 @@ export interface components {
|
|
|
4189
4213
|
HrisSyncStatusListDto: {
|
|
4190
4214
|
statuses: components["schemas"]["HrisSyncStatusDto"][];
|
|
4191
4215
|
};
|
|
4216
|
+
ZenHrReconnectResultDto: {
|
|
4217
|
+
ok: boolean;
|
|
4218
|
+
/** @description When true with ok=false, stored credentials exist but refresh failed with an OAuth re-authorization error; the SPA should start ZenHR OAuth next. */
|
|
4219
|
+
oauthRequired?: boolean;
|
|
4220
|
+
/**
|
|
4221
|
+
* @description Machine-readable code when ok=false and oauthRequired=true.
|
|
4222
|
+
* @enum {string}
|
|
4223
|
+
*/
|
|
4224
|
+
error?: "zenhr_oauth_required";
|
|
4225
|
+
};
|
|
4192
4226
|
HrisTriggerSyncResultDto: {
|
|
4193
4227
|
/** @enum {string} */
|
|
4194
4228
|
status: "ok" | "skipped" | "error" | "partial";
|
|
@@ -4600,6 +4634,7 @@ export type WorkspaceAbsenceDto = components['schemas']['WorkspaceAbsenceDto'];
|
|
|
4600
4634
|
export type WorkspaceAbsenceListDto = components['schemas']['WorkspaceAbsenceListDto'];
|
|
4601
4635
|
export type HrisSyncStatusDto = components['schemas']['HrisSyncStatusDto'];
|
|
4602
4636
|
export type HrisSyncStatusListDto = components['schemas']['HrisSyncStatusListDto'];
|
|
4637
|
+
export type ZenHrReconnectResultDto = components['schemas']['ZenHrReconnectResultDto'];
|
|
4603
4638
|
export type HrisTriggerSyncResultDto = components['schemas']['HrisTriggerSyncResultDto'];
|
|
4604
4639
|
export type HrisProviderSyncResultDto = components['schemas']['HrisProviderSyncResultDto'];
|
|
4605
4640
|
export type ActivityLogPageDto = components['schemas']['ActivityLogPageDto'];
|
|
@@ -9812,6 +9847,58 @@ export interface operations {
|
|
|
9812
9847
|
403: components["responses"]["Forbidden"];
|
|
9813
9848
|
};
|
|
9814
9849
|
};
|
|
9850
|
+
reconnectWorkspaceZenHr: {
|
|
9851
|
+
parameters: {
|
|
9852
|
+
query?: never;
|
|
9853
|
+
header?: never;
|
|
9854
|
+
path: {
|
|
9855
|
+
workspaceId: components["parameters"]["WorkspaceId"];
|
|
9856
|
+
};
|
|
9857
|
+
cookie?: never;
|
|
9858
|
+
};
|
|
9859
|
+
requestBody?: never;
|
|
9860
|
+
responses: {
|
|
9861
|
+
/** @description Silent reconnect succeeded or OAuth is required */
|
|
9862
|
+
200: {
|
|
9863
|
+
headers: {
|
|
9864
|
+
[name: string]: unknown;
|
|
9865
|
+
};
|
|
9866
|
+
content: {
|
|
9867
|
+
"application/json": components["schemas"]["ZenHrReconnectResultDto"];
|
|
9868
|
+
};
|
|
9869
|
+
};
|
|
9870
|
+
401: components["responses"]["Unauthorized"];
|
|
9871
|
+
403: components["responses"]["Forbidden"];
|
|
9872
|
+
/** @description ZenHR is not connected for this workspace */
|
|
9873
|
+
404: {
|
|
9874
|
+
headers: {
|
|
9875
|
+
[name: string]: unknown;
|
|
9876
|
+
};
|
|
9877
|
+
content: {
|
|
9878
|
+
/**
|
|
9879
|
+
* @example {
|
|
9880
|
+
* "error": "zenhr_not_connected"
|
|
9881
|
+
* }
|
|
9882
|
+
*/
|
|
9883
|
+
"application/json": components["schemas"]["ErrorMessageDto"];
|
|
9884
|
+
};
|
|
9885
|
+
};
|
|
9886
|
+
/** @description ZenHR refresh or branch ping failed for a non-OAuth reason */
|
|
9887
|
+
502: {
|
|
9888
|
+
headers: {
|
|
9889
|
+
[name: string]: unknown;
|
|
9890
|
+
};
|
|
9891
|
+
content: {
|
|
9892
|
+
/**
|
|
9893
|
+
* @example {
|
|
9894
|
+
* "error": "zenhr_reconnect_failed"
|
|
9895
|
+
* }
|
|
9896
|
+
*/
|
|
9897
|
+
"application/json": components["schemas"]["ErrorMessageDto"];
|
|
9898
|
+
};
|
|
9899
|
+
};
|
|
9900
|
+
};
|
|
9901
|
+
};
|
|
9815
9902
|
getHrisSyncStatus: {
|
|
9816
9903
|
parameters: {
|
|
9817
9904
|
query?: never;
|