@thinkai/tai-api-contract 2.54.0 → 2.55.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.
@@ -1,7 +1,7 @@
1
1
  openapi: 3.0.3
2
2
  info:
3
3
  title: ThinkAI API
4
- version: 2.54.0
4
+ version: 2.55.0
5
5
  description: >
6
6
  Contract surface for the AI Driven SDLC backend used by ThinkAI.
7
7
  Workspace-scoped routes use `/workspaces/{workspaceId}/...`.
@@ -1099,6 +1099,48 @@ paths:
1099
1099
  "403":
1100
1100
  $ref: "#/components/responses/Forbidden"
1101
1101
 
1102
+ /workspaces/{workspaceId}/org-chart/members/me:
1103
+ patch:
1104
+ tags: [Workspace]
1105
+ summary: Update current user's org chart member row
1106
+ description: >
1107
+ Updates the signed-in user's row in the workspace org chart snapshot (`thinkai_org_structure`),
1108
+ matched by work email. Any workspace member may update their own row; workspace editor role is not required.
1109
+ operationId: patchMyOrgChartMember
1110
+ parameters:
1111
+ - $ref: "#/components/parameters/WorkspaceId"
1112
+ requestBody:
1113
+ required: true
1114
+ content:
1115
+ application/json:
1116
+ schema:
1117
+ $ref: "#/components/schemas/UpdateMyOrgChartMemberBodyDto"
1118
+ responses:
1119
+ "200":
1120
+ description: Updated org chart member row
1121
+ content:
1122
+ application/json:
1123
+ schema:
1124
+ $ref: "#/components/schemas/OrgChartPersonDto"
1125
+ "400":
1126
+ description: Invalid request body
1127
+ content:
1128
+ application/json:
1129
+ schema:
1130
+ $ref: "#/components/schemas/ErrorMessageDto"
1131
+ "401":
1132
+ $ref: "#/components/responses/Unauthorized"
1133
+ "403":
1134
+ $ref: "#/components/responses/Forbidden"
1135
+ "404":
1136
+ description: >
1137
+ Org chart not found (no persisted chart for the workspace), or the caller's email
1138
+ is not present in the org chart roster.
1139
+ content:
1140
+ application/json:
1141
+ schema:
1142
+ $ref: "#/components/schemas/ErrorMessageDto"
1143
+
1102
1144
  /workspaces/{workspaceId}/config:
1103
1145
  get:
1104
1146
  tags: [TechStack]
@@ -6774,6 +6816,27 @@ components:
6774
6816
  type: string
6775
6817
  description: Bitbucket account UUID (e.g. "{aeefb6b0-...}") to attribute merged PRs and reviews to this person in productivity ingest. Preferred over bitbucketNickname — Bitbucket PR payloads expose a stable uuid but not nickname. Resolves to the same person_id (email) as githubUsername.
6776
6818
 
6819
+ UpdateMyOrgChartMemberBodyDto:
6820
+ type: object
6821
+ additionalProperties: false
6822
+ properties:
6823
+ name:
6824
+ type: string
6825
+ title:
6826
+ type: string
6827
+ department:
6828
+ type: string
6829
+ team:
6830
+ type: string
6831
+ location:
6832
+ type: string
6833
+ githubUsername:
6834
+ type: string
6835
+ bitbucketNickname:
6836
+ type: string
6837
+ bitbucketUuid:
6838
+ type: string
6839
+
6777
6840
  OrgChartImportResultDto:
6778
6841
  type: object
6779
6842
  additionalProperties: false
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thinkai/tai-api-contract",
3
- "version": "2.54.0",
3
+ "version": "2.55.0",
4
4
  "private": false,
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -21,7 +21,7 @@
21
21
  "dependencies": {},
22
22
  "devDependencies": {
23
23
  "@stoplight/spectral-cli": "^6.16.1",
24
- "@types/node": "^26.0.1",
24
+ "@types/node": "^26.1.1",
25
25
  "jsonpath-plus": "^10.3.0",
26
26
  "openapi-typescript": "^7.13.0",
27
27
  "typescript": "~6.0.3"
@@ -400,6 +400,26 @@ export interface paths {
400
400
  patch?: never;
401
401
  trace?: never;
402
402
  };
403
+ "/workspaces/{workspaceId}/org-chart/members/me": {
404
+ parameters: {
405
+ query?: never;
406
+ header?: never;
407
+ path?: never;
408
+ cookie?: never;
409
+ };
410
+ get?: never;
411
+ put?: never;
412
+ post?: never;
413
+ delete?: never;
414
+ options?: never;
415
+ head?: never;
416
+ /**
417
+ * Update current user's org chart member row
418
+ * @description Updates the signed-in user's row in the workspace org chart snapshot (`thinkai_org_structure`), matched by work email. Any workspace member may update their own row; workspace editor role is not required.
419
+ */
420
+ patch: operations["patchMyOrgChartMember"];
421
+ trace?: never;
422
+ };
403
423
  "/workspaces/{workspaceId}/config": {
404
424
  parameters: {
405
425
  query?: never;
@@ -2587,6 +2607,16 @@ export interface components {
2587
2607
  /** @description Bitbucket account UUID (e.g. "{aeefb6b0-...}") to attribute merged PRs and reviews to this person in productivity ingest. Preferred over bitbucketNickname — Bitbucket PR payloads expose a stable uuid but not nickname. Resolves to the same person_id (email) as githubUsername. */
2588
2608
  bitbucketUuid?: string;
2589
2609
  };
2610
+ UpdateMyOrgChartMemberBodyDto: {
2611
+ name?: string;
2612
+ title?: string;
2613
+ department?: string;
2614
+ team?: string;
2615
+ location?: string;
2616
+ githubUsername?: string;
2617
+ bitbucketNickname?: string;
2618
+ bitbucketUuid?: string;
2619
+ };
2590
2620
  OrgChartImportResultDto: {
2591
2621
  persons: components["schemas"]["OrgChartPersonDto"][];
2592
2622
  errors: string[];
@@ -5550,6 +5580,7 @@ export type OrgChartTreeNodeDto = components['schemas']['OrgChartTreeNodeDto'];
5550
5580
  export type ScoringOrgChartDto = components['schemas']['ScoringOrgChartDto'];
5551
5581
  export type OrgChartDto = components['schemas']['OrgChartDto'];
5552
5582
  export type OrgChartPersonDto = components['schemas']['OrgChartPersonDto'];
5583
+ export type UpdateMyOrgChartMemberBodyDto = components['schemas']['UpdateMyOrgChartMemberBodyDto'];
5553
5584
  export type OrgChartImportResultDto = components['schemas']['OrgChartImportResultDto'];
5554
5585
  export type OrgChartSaveResultDto = components['schemas']['OrgChartSaveResultDto'];
5555
5586
  export type OrgStructureSourceBodyDto = components['schemas']['OrgStructureSourceBodyDto'];
@@ -6989,6 +7020,52 @@ export interface operations {
6989
7020
  403: components["responses"]["Forbidden"];
6990
7021
  };
6991
7022
  };
7023
+ patchMyOrgChartMember: {
7024
+ parameters: {
7025
+ query?: never;
7026
+ header?: never;
7027
+ path: {
7028
+ workspaceId: components["parameters"]["WorkspaceId"];
7029
+ };
7030
+ cookie?: never;
7031
+ };
7032
+ requestBody: {
7033
+ content: {
7034
+ "application/json": components["schemas"]["UpdateMyOrgChartMemberBodyDto"];
7035
+ };
7036
+ };
7037
+ responses: {
7038
+ /** @description Updated org chart member row */
7039
+ 200: {
7040
+ headers: {
7041
+ [name: string]: unknown;
7042
+ };
7043
+ content: {
7044
+ "application/json": components["schemas"]["OrgChartPersonDto"];
7045
+ };
7046
+ };
7047
+ /** @description Invalid request body */
7048
+ 400: {
7049
+ headers: {
7050
+ [name: string]: unknown;
7051
+ };
7052
+ content: {
7053
+ "application/json": components["schemas"]["ErrorMessageDto"];
7054
+ };
7055
+ };
7056
+ 401: components["responses"]["Unauthorized"];
7057
+ 403: components["responses"]["Forbidden"];
7058
+ /** @description Org chart not found (no persisted chart for the workspace), or the caller's email is not present in the org chart roster. */
7059
+ 404: {
7060
+ headers: {
7061
+ [name: string]: unknown;
7062
+ };
7063
+ content: {
7064
+ "application/json": components["schemas"]["ErrorMessageDto"];
7065
+ };
7066
+ };
7067
+ };
7068
+ };
6992
7069
  getWorkspaceConfig: {
6993
7070
  parameters: {
6994
7071
  query?: never;